diff --git a/src/controllers/tanksController.js b/src/controllers/tanksController.js index 7da84e2c..84df5da0 100644 --- a/src/controllers/tanksController.js +++ b/src/controllers/tanksController.js @@ -2201,7 +2201,7 @@ console.log(fcmToken) motorIntervals[motorId] = setTimeout(async () => { try { // Perform threshold time logic (e.g., notification, motor stop) - console.log(`Threshold time of ${manualThresholdTime} minutes reached for motor ${motorId}`); + console.log(`Threshold time of ${manual_threshold_time} minutes reached for motor ${motorId}`); await Tank.updateOne( { customerId, "connections.inputConnections.motor_id": motorId }, { $set: { "connections.inputConnections.$.motor_stop_status": "1" } } @@ -2248,8 +2248,8 @@ console.log(fcmToken) } ); - const startMessage = `Motor supplying water to '${tankName}' in block '${blockName}' started manually at ${startTime}.`; - eventEmitter.emit('sendMotorStartNotification', fcmToken, startMessage); + // const startMessage = `Motor supplying water to '${tankName}' in block '${blockName}' started manually at ${startTime}.`; + // eventEmitter.emit('sendMotorStartNotification', fcmToken, startMessage); // Schedule threshold check // const thresholdTimeMs = manual_threshold_time * 60 * 1000; @@ -2336,8 +2336,8 @@ console.log(fcmToken) } ); - const stopMessage = `Motor supplying water to '${tankName}' in block '${blockName}' stopped manually at ${stopTime}.`; - eventEmitter.emit('sendMotorStopNotification', fcmToken, stopMessage); + // const stopMessage = `Motor supplying water to '${tankName}' in block '${blockName}' stopped manually at ${stopTime}.`; + // eventEmitter.emit('sendMotorStopNotification', fcmToken, stopMessage); if (motorIntervals[motorId]) { clearTimeout(motorIntervals[motorId]);