ashok 10 months ago
commit 93a2ce7f6f

@ -2717,11 +2717,12 @@ exports.getPumpsAndUsers = async (req, reply) => {
const username = user?.username || "";
// Include username at the beginning of staffNames and add "manual" at the end
const updatedStaffNames = [username, ...staffNames, "manual","user"];
const updatedStaffNames = ["All",username, ...staffNames, "manual","user"];
const updatedmotorIds = ["All",motorIds];
// Prepare response
const result = {
motorIds,
motorIds: updatedmotorIds,
staffNames: updatedStaffNames,
};
@ -2735,9 +2736,6 @@ exports.getPumpsAndUsers = async (req, reply) => {
const monitorWaterLevels = async () => {
try {
const tanks = await Tank.find({});

Loading…
Cancel
Save