sync changes

This commit is contained in:
Enstrayed
2025-10-01 09:50:32 -07:00
parent 4de76c34c2
commit b1ac3d6f58
16 changed files with 114 additions and 60 deletions

View File

@@ -26,7 +26,14 @@ app.get("/helpdesk/ticket/new", (rreq,rres) => {
})
app.get("/api/helpdesk/forms/*", (rreq, rres) => {
rres.sendFile(process.cwd()+"/website/helpdesk/forms/"+rreq.url.replace("/api/helpdesk/forms/",""))
fs.readFile(process.cwd()+"/website/helpdesk/forms/"+rreq.url.replace("/api/helpdesk/forms/","")+".json","utf-8", (error, data) => {
if (error) {
rres.status(400).send("Unable to retrieve requested form")
} else {
rres.type('json').send(data)
}
})
})
app.get("/helpdesk/static/*", (rreq,rres) => {