mirror of
https://github.com/Expand-sys/ccashfrontend
synced 2025-12-17 07:12:12 +11:00
quick patch fixing new user login
This commit is contained in:
parent
ec3ec448f2
commit
a1f37f44a6
1 changed files with 16 additions and 4 deletions
20
index.js
20
index.js
|
|
@ -210,7 +210,9 @@ app.get("/BankF", ensureAuthenticated, async function (req, res) {
|
|||
logsent = logsent.body.value;
|
||||
let logrec = logsent;
|
||||
let graphlog = logsent;
|
||||
graphlog = graphlog.reverse();
|
||||
if (graphlog != null) {
|
||||
graphlog = graphlog.reverse();
|
||||
}
|
||||
let graphdata = "";
|
||||
let currentbal = balance.value;
|
||||
if (graphlog) {
|
||||
|
|
@ -226,10 +228,14 @@ app.get("/BankF", ensureAuthenticated, async function (req, res) {
|
|||
} else {
|
||||
graphlog = undefined;
|
||||
}
|
||||
graphdata =
|
||||
", [" + parseInt(graphlog.length) + "," + balance.value + "]" + graphdata;
|
||||
if (graphdata != "") {
|
||||
graphdata =
|
||||
", [" + parseInt(graphlog.length) + "," + balance.value + "]" + graphdata;
|
||||
graphdata = '["transaction", "balance"]' + graphdata;
|
||||
}
|
||||
|
||||
console.log(balance);
|
||||
graphdata = '["transaction", "balance"]' + graphdata;
|
||||
|
||||
console.log(JSON.stringify(graphdata));
|
||||
if (logsent == 1 || logsent == -1 || logsent == null) {
|
||||
logsent = undefined;
|
||||
|
|
@ -251,6 +257,12 @@ app.get("/BankF", ensureAuthenticated, async function (req, res) {
|
|||
logsent[i].time = new Date(logsent[i].time);
|
||||
}
|
||||
}
|
||||
if (logrec != null) {
|
||||
logrec.reverse();
|
||||
}
|
||||
if (logsent != null) {
|
||||
logsent.reverse();
|
||||
}
|
||||
let maxgraph = balance + 1000;
|
||||
console.log("begin render " + Date.now());
|
||||
res.render("bankf", {
|
||||
|
|
|
|||
Loading…
Reference in a new issue