feat: add admin slip management pages and update navbar styles
This commit is contained in:
@@ -158,6 +158,10 @@ export const endgameArchive = endgame.table("sarchive", {
|
||||
price: integer().notNull(),
|
||||
slip: text().references(() => endgameSlips.id),
|
||||
round: integer().notNull(),
|
||||
service: text()
|
||||
.references(() => endgameTypes.id)
|
||||
.array()
|
||||
.notNull(),
|
||||
});
|
||||
|
||||
// expired submission
|
||||
|
||||
@@ -170,3 +170,13 @@ export function shortestPrefixes(values: readonly string[]) {
|
||||
|
||||
return res;
|
||||
}
|
||||
export function parseParamNumber(param: string | string[] | undefined) {
|
||||
if (Array.isArray(param)) {
|
||||
if (param.length < 1) return 0;
|
||||
return parseParamNumber(param[0]);
|
||||
}
|
||||
if (!param) return 0;
|
||||
const int = parseInt(param, 10);
|
||||
if (Number.isNaN(int)) return 0;
|
||||
return int;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user