fix checkedNotesAt issue
This commit is contained in:
parent
9eced2b334
commit
50f10550b8
@ -210,19 +210,22 @@ export default {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
const job = await models.item.findFirst({
|
const where = {
|
||||||
where: {
|
status: {
|
||||||
status: {
|
not: 'STOPPED'
|
||||||
not: 'STOPPED'
|
},
|
||||||
},
|
maxBid: {
|
||||||
maxBid: {
|
not: null
|
||||||
not: null
|
|
||||||
},
|
|
||||||
statusUpdatedAt: {
|
|
||||||
gt: user.checkedNotesAt
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
}
|
||||||
|
|
||||||
|
if (user.checkedNotesAt) {
|
||||||
|
where.statusUpdatedAt = {
|
||||||
|
gt: user.checkedNotesAt
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
const job = user.checkedNotesAt && await models.item.findFirst({ where })
|
||||||
if (job) {
|
if (job) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user