changes in consumption

master^2
Varun 6 months ago
parent 0c063e321b
commit 8cd1c472cf

@ -6466,6 +6466,7 @@ exports.consumptionofparticulartank = async (request, reply) => {
// Convert input dates into proper JavaScript Date objects for comparison // Convert input dates into proper JavaScript Date objects for comparison
const start = moment(startDate, "DD-MMM-YYYY - HH:mm").toDate(); const start = moment(startDate, "DD-MMM-YYYY - HH:mm").toDate();
const end = moment(stopDate, "DD-MMM-YYYY - HH:mm").toDate(); const end = moment(stopDate, "DD-MMM-YYYY - HH:mm").toDate();
end.setHours(23, 59, 59, 999); // Ensure full day is included
// Find the tank by customerId, tankLocation, and tankName // Find the tank by customerId, tankLocation, and tankName
const tank = await Tank.findOne({ const tank = await Tank.findOne({

Loading…
Cancel
Save