diff --git a/api/controller_front/apply.js b/api/controller_front/apply.js index a437005..e28bb3d 100644 --- a/api/controller_front/apply.js +++ b/api/controller_front/apply.js @@ -152,6 +152,7 @@ module.exports = { const models = Framework.getModels(); const { apply_records, op } = models; const { sn_code, startTime, endTime } = ctx.query; + console.log(startTime, endTime); const final_sn_code = sn_code; if (!final_sn_code) { @@ -192,15 +193,7 @@ module.exports = { const monthStart = new Date(now.getFullYear(), now.getMonth(), 1); monthStart.setHours(0, 0, 0, 0); - // 构建统计查询条件 - const buildWhereWithTime = (additionalWhere = {}) => { - const where = { ...baseWhere, ...additionalWhere }; - // 如果提供了时间范围,则不再使用默认的今日、本周、本月时间 - if (startTime || endTime) { - return where; - } - return where; - }; + const [ totalCount,