Browse Source

请假加班排序

master
deartibers 2 years ago
parent
commit
59faabde50
  1. 4
      api/app/lib/controllers/member/index.js

4
api/app/lib/controllers/member/index.js

@ -375,7 +375,7 @@ async function overTimeStatistics (ctx) {
let returnD = {
...(statisticRes.length ? statisticRes[0] : {}),
data: dataRes,
dayStatisticData: statisticDayRes
dayStatisticData: statisticDayRes.sort((a,b)=>moment(a.day)-moment(b.day))
}
ctx.status = 200;
ctx.body = returnD
@ -465,7 +465,7 @@ async function vacateStatistics (ctx) {
let returnD = {
statistic: statisticRes,
data: dataRes,
dayStatisticData: statisticDayRes
dayStatisticData: statisticDayRes.sort((a,b)=>moment(a.day)-moment(b.day))
}
ctx.status = 200;
ctx.body = returnD

Loading…
Cancel
Save