7152-devToTest_2414 #2228

Merged
alexm merged 636 commits from 7152-devToTest_2414 into test 2024-03-28 08:26:34 +00:00
1 changed files with 2 additions and 2 deletions
Showing only changes of commit e354de4ff5 - Show all commits

View File

@ -42,7 +42,7 @@ module.exports = Self => {
const machineWorker = await models.MachineWorker.findOne({ const machineWorker = await models.MachineWorker.findOne({
where: { where: {
workerFk: userId, workerFk: userId,
inTime: {gte: new Date(Date.now() - maxHours * 60 * 60 * 1000)}, inTime: {gte: Date.vnNew() - (maxHours * 60 * 60 * 1000)},
outTimed: null, outTimed: null,
machineFk: machine.id, machineFk: machine.id,
} }
@ -50,7 +50,7 @@ module.exports = Self => {
}); });
if (machineWorker) { if (machineWorker) {
await machineWorker.updateAttributes({ await machineWorker.updateAttributes({
outTime: new Date(Date.now()) outTime: Date.now()
}, myOptions); }, myOptions);
} }