itrm-tools 1.1.12 → 1.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -6,13 +6,13 @@ export declare class MongooseModelManager<S> {
|
|
|
6
6
|
create(datum: S): Promise<(import("mongoose").Document<unknown, {}, S> & {
|
|
7
7
|
_id: import("mongoose").Types.ObjectId;
|
|
8
8
|
} & {
|
|
9
|
-
__v
|
|
9
|
+
__v: number;
|
|
10
10
|
}) | (import("mongoose").Document<unknown, {}, S> & {
|
|
11
11
|
_id?: unknown;
|
|
12
12
|
} & Required<{
|
|
13
13
|
_id: unknown;
|
|
14
14
|
}> & {
|
|
15
|
-
__v
|
|
15
|
+
__v: number;
|
|
16
16
|
})>;
|
|
17
17
|
createMany(data: S[]): Promise<any>;
|
|
18
18
|
exists(filter: FilterQuery<S>): import("mongoose").Query<{
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ModelAttributes, ModelOptions, Options, Sequelize } from "@sequelize/core";
|
|
1
|
+
import { AbstractDialect, ModelAttributes, ModelOptions, Options, Sequelize } from "@sequelize/core";
|
|
2
2
|
export declare interface SequelizeConnectionConfig {
|
|
3
3
|
host: string;
|
|
4
4
|
username: string;
|
|
@@ -8,11 +8,12 @@ export declare interface SequelizeConnectionConfig {
|
|
|
8
8
|
}
|
|
9
9
|
export declare class SequelizeConnection {
|
|
10
10
|
private connection;
|
|
11
|
-
constructor(config: Options);
|
|
11
|
+
constructor(config: Options<any>);
|
|
12
12
|
connect(): Promise<void>;
|
|
13
13
|
define(name: string, attributes: ModelAttributes, options?: ModelOptions): import("@sequelize/core").ModelStatic<import("@sequelize/core").Model<any, any>>;
|
|
14
|
-
sync(syncOptions?: any): Promise<Sequelize
|
|
14
|
+
sync(syncOptions?: any): Promise<Sequelize<AbstractDialect<object, object>>>;
|
|
15
15
|
transaction<T>(callback: (response: any) => Promise<T>): Promise<T>;
|
|
16
16
|
query(query: string, options?: any): Promise<[undefined, number]>;
|
|
17
17
|
disconnect(): Promise<void>;
|
|
18
|
+
disconnectAll(): Promise<void>;
|
|
18
19
|
}
|
|
@@ -24,6 +24,9 @@ class SequelizeConnection {
|
|
|
24
24
|
disconnect() {
|
|
25
25
|
return this.connection.close();
|
|
26
26
|
}
|
|
27
|
+
disconnectAll() {
|
|
28
|
+
return this.connection.pool.destroyAllNow();
|
|
29
|
+
}
|
|
27
30
|
}
|
|
28
31
|
exports.SequelizeConnection = SequelizeConnection;
|
|
29
32
|
//# sourceMappingURL=SequelizeConnection.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SequelizeConnection.js","sourceRoot":"","sources":["../../../src/database/sequelize/SequelizeConnection.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"SequelizeConnection.js","sourceRoot":"","sources":["../../../src/database/sequelize/SequelizeConnection.ts"],"names":[],"mappings":";;;AAAA,0CAAqG;AAUrG,MAAa,mBAAmB;IAG5B,YAAY,MAAoB;QAC5B,IAAI,CAAC,UAAU,GAAG,IAAI,gBAAS,CAAC,MAAM,CAAC,CAAC;IAC5C,CAAC;IAEM,OAAO;QACV,OAAO,IAAI,CAAC,UAAU,CAAC,YAAY,EAAE,CAAC;IAC1C,CAAC;IAEM,MAAM,CAAC,IAAY,EAAE,UAA2B,EAAE,OAAsB;QAC3E,OAAO,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,IAAI,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;IAC7D,CAAC;IAEM,IAAI,CAAC,WAAiB;QACzB,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAC7C,CAAC;IAEM,WAAW,CAAI,QAAuC;QACzD,OAAO,IAAI,CAAC,UAAU,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;IACjD,CAAC;IAEM,KAAK,CAAC,KAAa,EAAE,OAAa;QACrC,OAAO,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;IACjD,CAAC;IAEM,UAAU;QACb,OAAO,IAAI,CAAC,UAAU,CAAC,KAAK,EAAE,CAAC;IACnC,CAAC;IAEM,aAAa;QAChB,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,aAAa,EAAE,CAAC;IAChD,CAAC;CACJ;AAlCD,kDAkCC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "itrm-tools",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.14",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -31,6 +31,7 @@
|
|
|
31
31
|
},
|
|
32
32
|
"homepage": "https://github.com/ITRMachines/itrm-tools#readme",
|
|
33
33
|
"devDependencies": {
|
|
34
|
+
"@sequelize/sqlite3": "^7.0.0-alpha.43",
|
|
34
35
|
"@types/jest": "^29.5.6",
|
|
35
36
|
"@types/multer": "^1.4.9",
|
|
36
37
|
"@types/node": "^22.7.4",
|
|
@@ -49,7 +50,7 @@
|
|
|
49
50
|
"uuid": "^10.0.0"
|
|
50
51
|
},
|
|
51
52
|
"dependencies": {
|
|
52
|
-
"@sequelize/core": "^7.0.0-alpha.
|
|
53
|
+
"@sequelize/core": "^7.0.0-alpha.43",
|
|
53
54
|
"@types/cors": "^2.8.15",
|
|
54
55
|
"@types/express": "^4.17.20",
|
|
55
56
|
"@types/morgan": "^1.9.9",
|
|
@@ -66,6 +67,7 @@
|
|
|
66
67
|
"multer": "^1.4.5-lts.1",
|
|
67
68
|
"pg": "^8.11.5",
|
|
68
69
|
"pg-hstore": "^2.3.4",
|
|
70
|
+
"sequelize": "^6.37.4",
|
|
69
71
|
"swagger-ui-express": "^5.0.0",
|
|
70
72
|
"ws": "^8.14.2"
|
|
71
73
|
}
|