u
This commit is contained in:
@@ -413,6 +413,14 @@ export class BetterSqlite3Provider extends BetterSqlite3Executor {
|
||||
`ALTER TABLE warehouse ADD COLUMN sort INTEGER NOT NULL DEFAULT 0`,
|
||||
);
|
||||
}
|
||||
|
||||
const posterminalCols = this.db.pragma('table_info("posterminal")').map((c) => c.name);
|
||||
if (posterminalCols.length > 0 && !posterminalCols.includes('paired_at')) {
|
||||
this.db.exec(`ALTER TABLE posterminal ADD COLUMN paired_at TEXT`);
|
||||
}
|
||||
if (posterminalCols.length > 0 && !posterminalCols.includes('clientserial')) {
|
||||
this.db.exec(`ALTER TABLE posterminal ADD COLUMN clientserial TEXT`);
|
||||
}
|
||||
} catch {
|
||||
// ignore
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user