【发布时间】:2021-03-06 23:55:15
【问题描述】:
我有以下疑问:
cors(request, response, async () => {
const connection = await connect();
const allAvailable = await connection
.createQueryBuilder(Topics, 'topics')
.select('topics.UID')
.where('topics.tickets = 0')
.andWhere('topics.chips = 0')
.andWhere('topics.masteredLevel <= 1')
.getRawMany();
response.send(allAvailable);
})
我的回答是:
[{"topics_UID":"T001"},{"topics_UID":"T002"}]
但我想要这样的回应:
["T001", "T002"]
【问题讨论】: