This commit is contained in:
Christopher Cookman 2025-09-01 02:45:19 -06:00
parent 98f6c6e87c
commit ee4e0d96a5
2 changed files with 5 additions and 3 deletions

View file

@ -31,8 +31,8 @@ const expressWs = require('express-ws')(app);
app.use(session({ app.use(session({
secret: process.env.SESSION_SECRET || "uhppoted-secret-change-me", secret: process.env.SESSION_SECRET || "uhppoted-secret-change-me",
cookie: { maxAge: 60000 }, cookie: { maxAge: 24 * 60 * 60 * 1000 }, // 1 day
resave: false, resave: true,
saveUninitialized: false, saveUninitialized: false,
store: new SQLiteStore({ db: 'sessions.db', dir: './' }) store: new SQLiteStore({ db: 'sessions.db', dir: './' })
})); }));

View file

@ -68,7 +68,9 @@
<td>${log.Controller}</td> <td>${log.Controller}</td>
<td>${log.Door}</td> <td>${log.Door}</td>
<td>${new Date(log.Timestamp).toLocaleString()}</td> <td>${new Date(log.Timestamp).toLocaleString()}</td>
<td>${log.Name || ''}</td> <td>
<input type="text" name="name" required value="${log.CardNumber}" />
</td>
<td><input type="date" value="${new Date().toISOString().slice(0, 10)}" /></td> <td><input type="date" value="${new Date().toISOString().slice(0, 10)}" /></td>
<td><input type="date" value="${new Date(Date.now() + 99 * 365.25 * 24 * 60 * 60 * 1000).toISOString().slice(0, 10)}" /></td> <td><input type="date" value="${new Date(Date.now() + 99 * 365.25 * 24 * 60 * 60 * 1000).toISOString().slice(0, 10)}" /></td>
<td> <td>