feat: first add

This commit is contained in:
2025-01-19 13:22:58 +08:00
commit 7f53f82fd4
16 changed files with 2337 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
import {
getDb,
getResourceDb,
getBackupDb,
getLogDb
} from "./dbServer.mjs";
export default class DBHelper {
static baseDB = null;
static resourceDB = null;
static backupDB = null;
static logDB = null;
static async init() {
this.baseDB = await getDb();
this.resourceDB = await getResourceDb();
this.backupDB = await getBackupDb();
this.logDB = await getLogDb();
}
static getBackupDb() {
// return getBackupDb();
return this.backupDB;
}
static getLogDb() {
// return getLogDb();
return this.logDB;
}
}