明树Git Lab

Commit 836d66af authored by zengfanpei's avatar zengfanpei

update

parent bfd1b08f
......@@ -50,7 +50,7 @@ async function updateDevice(req, res, next) {
const element = req.body.thresholds[i];
dbKeys.push(element.dbKey);
let {dbKey, deviceKey, name, _id} = attrMap[element.dbKey || element.attrId];
await DB.CollectThreshold.findOneAndUpdate({deviceNumber: ret.deviceNumber, dbKey}, {
await DB.CollectThreshold.findOneAndUpdate({deviceNumber: ret.deviceNumber, dbKey, del: 0}, {
max: element.max,
min: element.min,
attrId: _id || element.attrId,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment