fix: admin queue time
parent
5988a592ac
commit
c05af5c16b
|
@ -35,6 +35,24 @@ export class QueueDataService extends BaseReadService<QueueModel> {
|
|||
item_queue_id,
|
||||
status: 'waiting',
|
||||
},
|
||||
order: {
|
||||
time: 'ASC',
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
async doneQueue(item_queue_id: string) {
|
||||
const start = moment().startOf('day').valueOf();
|
||||
const end = moment().endOf('day').valueOf();
|
||||
return this.repo.find({
|
||||
where: {
|
||||
time: Between(start, end),
|
||||
item_queue_id,
|
||||
status: In(['done', 'called']),
|
||||
},
|
||||
order: {
|
||||
time: 'ASC',
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue