Browse Source

抽查优化

dev
wenlele 1 year ago
parent
commit
d0ff2a74bf
  1. 4
      api/app/lib/controllers/report/index.js

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

@ -550,7 +550,7 @@ async function roadSpotPrepare (ctx) {
let lastCounty = await models.RoadSpotCheckPreview.findAll({ let lastCounty = await models.RoadSpotCheckPreview.findAll({
where: { where: {
checked: true, checked: true,
id: { $lt: lastSpotRes.id } id: { $lte: lastSpotRes.id }
}, },
limit: 3, limit: 3,
order: [['date', 'DESC']], order: [['date', 'DESC']],
@ -566,7 +566,7 @@ async function roadSpotPrepare (ctx) {
let lastVillage = await models.RoadSpotCheckPreview.findAll({ let lastVillage = await models.RoadSpotCheckPreview.findAll({
where: { where: {
checked: true, checked: true,
id: { $lt: lastSpotRes.id } id: { $lte: lastSpotRes.id }
}, },
limit: 9, limit: 9,
order: [['date', 'DESC']], order: [['date', 'DESC']],

Loading…
Cancel
Save