mirror of
https://github.com/Expand-sys/ccashfrontend
synced 2025-12-18 07:32:14 +11:00
fixed times displaying incorrectly - forgot to use date constructer instead of date function
This commit is contained in:
parent
14561307b9
commit
8844d44577
2 changed files with 6 additions and 3 deletions
7
index.js
7
index.js
|
|
@ -210,6 +210,7 @@ app.get("/BankF", ensureAuthenticated, async function (req, res) {
|
|||
console.log(logrec.timings);
|
||||
console.log("query finished " + Date.now());
|
||||
logsent = logsent.body.value;
|
||||
console.log(logsent);
|
||||
|
||||
if (logsent == 1 || logsent == -1 || logsent == null) {
|
||||
logsent = undefined;
|
||||
|
|
@ -223,10 +224,12 @@ app.get("/BankF", ensureAuthenticated, async function (req, res) {
|
|||
logrec = await logrec.filter(({ to }) => to === req.session.user);
|
||||
}
|
||||
for (i in logrec) {
|
||||
logrec[i].time = Date(logrec[i].time);
|
||||
logrec[i].time = new Date(logrec[i].time);
|
||||
console.log(logrec[i].time);
|
||||
}
|
||||
for (i in logsent) {
|
||||
logsent[i].time = Date(logsent[i].time);
|
||||
logsent[i].time = new Date(logsent[i].time);
|
||||
console.log(logsent[i].time);
|
||||
}
|
||||
console.log("begin render " + Date.now());
|
||||
res.render("bankf", {
|
||||
|
|
|
|||
|
|
@ -140,7 +140,7 @@ router.post("/bal", checkAdmin, async function (req, res) {
|
|||
} catch (err) {
|
||||
console.log(err);
|
||||
}
|
||||
if (patch.body.value == true) {
|
||||
if ((await patch.body.value) == true) {
|
||||
successes.push({ msg: "Change Funds Successful" });
|
||||
}
|
||||
res.render("adminsettings", {
|
||||
|
|
|
|||
Loading…
Reference in a new issue