naming chnages

master^2
Bhaskar 3 months ago
parent 550dc2666a
commit 58b19e8564

@ -9728,7 +9728,7 @@ exports.updateHardwareList = async (req, reply) => {
if (!support) return reply.code(404).send({ error: "Support record not found" }); if (!support) return reply.code(404).send({ error: "Support record not found" });
const escalationIssue = (support.categorizedIssues || []).find(issue => const escalationIssue = (support.categorizedIssues || []).find(issue =>
issue.category === "Escalation" && issue.hardwareId === hardwareId issue.category === "OutDoor Escalation" && issue.hardwareId === hardwareId
); );
if (!escalationIssue) { if (!escalationIssue) {
@ -10120,7 +10120,7 @@ exports.resolvedIssuesForSupport = async (req, reply) => {
}); });
} }
if (!["Escalation", "Pending"].includes(category)) { if (!["OutDoor Escalation", "LongTerm Issues"].includes(category)) {
return reply.code(400).send({ return reply.code(400).send({
message: "Invalid category. Only 'Escalation' or 'Pending' are allowed", message: "Invalid category. Only 'Escalation' or 'Pending' are allowed",
}); });

@ -268,7 +268,7 @@ const installationschema = new mongoose.Schema({
}, },
category: { category: {
type: String, type: String,
enum: ["Power Outage", "Resolved", "Escalation","Pending"], enum: ["Power Outage", "Resolved", "OutDoor Escalation","LongTerm Issues"],
required: true required: true
}, },
// ticketId: String, // ticketId: String,

@ -842,8 +842,8 @@ module.exports = function (fastify, opts, next) {
type: 'string', type: 'string',
enum: ["Power Outage", enum: ["Power Outage",
"Resolved", "Resolved",
"Escalation", "OutDoor Escalation",
"Pending"] "LongTerm Issues"]
} }
} }
}, },

Loading…
Cancel
Save