do not re-create deleted incidents

This commit is contained in:
Bilal Catic
2019-12-06 06:04:45 +01:00
parent 988dd275ef
commit 9d142901df

View File

@@ -51,6 +51,7 @@ const insertUnscheduledIncidents = (incidents) => {
totalChargeFee, totalChargeFee,
unlockTimestamp, unlockTimestamp,
lockTimestamp, lockTimestamp,
deleted: false
}; };
asyncJobs.push(db.unscheduledIncident.findOrCreate({ asyncJobs.push(db.unscheduledIncident.findOrCreate({
@@ -62,7 +63,6 @@ const insertUnscheduledIncidents = (incidents) => {
bookingEnd: end, bookingEnd: end,
unlockTimestamp, unlockTimestamp,
lockTimestamp, lockTimestamp,
deleted: false
}, },
defaults: {...incidentForDB}, defaults: {...incidentForDB},
})); }));
@@ -95,6 +95,7 @@ const insertUnlockedIncidents = (incidents) => {
unlockTimestamp, unlockTimestamp,
incidentLevel, incidentLevel,
incidentLevelPrice, incidentLevelPrice,
deleted: false
}; };
asyncJobs.push(db.unlockedIncident.findOrCreate({ asyncJobs.push(db.unlockedIncident.findOrCreate({
@@ -106,7 +107,6 @@ const insertUnlockedIncidents = (incidents) => {
bookingEnd: end, bookingEnd: end,
unlockTimestamp, unlockTimestamp,
incidentLevel, incidentLevel,
deleted: false
}, },
defaults: {...incidentForDB}, defaults: {...incidentForDB},
})); }));