@strapi/database 4.15.0-alpha.0 → 4.15.1
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.
- package/README.md +3 -0
- package/dist/connection.d.ts +3 -0
- package/dist/connection.d.ts.map +1 -0
- package/dist/dialects/dialect.d.ts +27 -0
- package/dist/dialects/dialect.d.ts.map +1 -0
- package/dist/dialects/index.d.ts +5 -0
- package/dist/dialects/index.d.ts.map +1 -0
- package/dist/dialects/mysql/constants.d.ts +3 -0
- package/dist/dialects/mysql/constants.d.ts.map +1 -0
- package/dist/dialects/mysql/database-inspector.d.ts +12 -0
- package/dist/dialects/mysql/database-inspector.d.ts.map +1 -0
- package/dist/dialects/mysql/index.d.ts +20 -0
- package/dist/dialects/mysql/index.d.ts.map +1 -0
- package/dist/dialects/mysql/schema-inspector.d.ts +13 -0
- package/dist/dialects/mysql/schema-inspector.d.ts.map +1 -0
- package/dist/dialects/postgresql/index.d.ts +14 -0
- package/dist/dialects/postgresql/index.d.ts.map +1 -0
- package/dist/dialects/postgresql/schema-inspector.d.ts +14 -0
- package/dist/dialects/postgresql/schema-inspector.d.ts.map +1 -0
- package/dist/dialects/sqlite/index.d.ts +19 -0
- package/dist/dialects/sqlite/index.d.ts.map +1 -0
- package/dist/dialects/sqlite/schema-inspector.d.ts +13 -0
- package/dist/dialects/sqlite/schema-inspector.d.ts.map +1 -0
- package/dist/entity-manager/entity-repository.d.ts +4 -0
- package/dist/entity-manager/entity-repository.d.ts.map +1 -0
- package/dist/entity-manager/index.d.ts +5 -0
- package/dist/entity-manager/index.d.ts.map +1 -0
- package/dist/entity-manager/morph-relations.d.ts +13 -0
- package/dist/entity-manager/morph-relations.d.ts.map +1 -0
- package/dist/entity-manager/regular-relations.d.ts +83 -0
- package/dist/entity-manager/regular-relations.d.ts.map +1 -0
- package/dist/entity-manager/relations/cloning/regular-relations.d.ts +17 -0
- package/dist/entity-manager/relations/cloning/regular-relations.d.ts.map +1 -0
- package/dist/entity-manager/relations-orderer.d.ts +73 -0
- package/dist/entity-manager/relations-orderer.d.ts.map +1 -0
- package/dist/entity-manager/types.d.ts +97 -0
- package/dist/entity-manager/types.d.ts.map +1 -0
- package/dist/errors/database.d.ts +5 -0
- package/dist/errors/database.d.ts.map +1 -0
- package/dist/errors/index.d.ts +8 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/invalid-date.d.ts +5 -0
- package/dist/errors/invalid-date.d.ts.map +1 -0
- package/dist/errors/invalid-datetime.d.ts +5 -0
- package/dist/errors/invalid-datetime.d.ts.map +1 -0
- package/dist/errors/invalid-relation.d.ts +5 -0
- package/dist/errors/invalid-relation.d.ts.map +1 -0
- package/dist/errors/invalid-time.d.ts +5 -0
- package/dist/errors/invalid-time.d.ts.map +1 -0
- package/dist/errors/not-null.d.ts +7 -0
- package/dist/errors/not-null.d.ts.map +1 -0
- package/dist/fields/biginteger.d.ts +4 -0
- package/dist/fields/biginteger.d.ts.map +1 -0
- package/dist/fields/boolean.d.ts +6 -0
- package/dist/fields/boolean.d.ts.map +1 -0
- package/dist/fields/date.d.ts +6 -0
- package/dist/fields/date.d.ts.map +1 -0
- package/dist/fields/datetime.d.ts +6 -0
- package/dist/fields/datetime.d.ts.map +1 -0
- package/dist/fields/field.d.ts +7 -0
- package/dist/fields/field.d.ts.map +1 -0
- package/dist/fields/index.d.ts +4 -0
- package/dist/fields/index.d.ts.map +1 -0
- package/dist/fields/json.d.ts +6 -0
- package/dist/fields/json.d.ts.map +1 -0
- package/dist/fields/number.d.ts +6 -0
- package/dist/fields/number.d.ts.map +1 -0
- package/dist/fields/shared/parsers.d.ts +4 -0
- package/dist/fields/shared/parsers.d.ts.map +1 -0
- package/dist/fields/string.d.ts +6 -0
- package/dist/fields/string.d.ts.map +1 -0
- package/dist/fields/time.d.ts +6 -0
- package/dist/fields/time.d.ts.map +1 -0
- package/dist/fields/timestamp.d.ts +6 -0
- package/dist/fields/timestamp.d.ts.map +1 -0
- package/dist/index.d.ts +46 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +6189 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +6157 -0
- package/dist/index.mjs.map +1 -0
- package/dist/lifecycles/index.d.ts +17 -0
- package/dist/lifecycles/index.d.ts.map +1 -0
- package/dist/lifecycles/subscribers/index.d.ts +5 -0
- package/dist/lifecycles/subscribers/index.d.ts.map +1 -0
- package/dist/lifecycles/subscribers/models-lifecycles.d.ts +6 -0
- package/dist/lifecycles/subscribers/models-lifecycles.d.ts.map +1 -0
- package/dist/lifecycles/subscribers/timestamps.d.ts +3 -0
- package/dist/lifecycles/subscribers/timestamps.d.ts.map +1 -0
- package/dist/lifecycles/types.d.ts +25 -0
- package/dist/lifecycles/types.d.ts.map +1 -0
- package/dist/metadata/index.d.ts +10 -0
- package/dist/metadata/index.d.ts.map +1 -0
- package/dist/metadata/metadata.d.ts +22 -0
- package/dist/metadata/metadata.d.ts.map +1 -0
- package/dist/metadata/relations.d.ts +16 -0
- package/dist/metadata/relations.d.ts.map +1 -0
- package/dist/migrations/index.d.ts +12 -0
- package/dist/migrations/index.d.ts.map +1 -0
- package/dist/migrations/storage.d.ts +15 -0
- package/dist/migrations/storage.d.ts.map +1 -0
- package/dist/query/helpers/index.d.ts +8 -0
- package/dist/query/helpers/index.d.ts.map +1 -0
- package/dist/query/helpers/join.d.ts +30 -0
- package/dist/query/helpers/join.d.ts.map +1 -0
- package/dist/query/helpers/order-by.d.ts +14 -0
- package/dist/query/helpers/order-by.d.ts.map +1 -0
- package/dist/query/helpers/populate/apply.d.ts +11 -0
- package/dist/query/helpers/populate/apply.d.ts.map +1 -0
- package/dist/query/helpers/populate/index.d.ts +4 -0
- package/dist/query/helpers/populate/index.d.ts.map +1 -0
- package/dist/query/helpers/populate/process.d.ts +24 -0
- package/dist/query/helpers/populate/process.d.ts.map +1 -0
- package/dist/query/helpers/search.d.ts +4 -0
- package/dist/query/helpers/search.d.ts.map +1 -0
- package/dist/query/helpers/streams/index.d.ts +2 -0
- package/dist/query/helpers/streams/index.d.ts.map +1 -0
- package/dist/query/helpers/streams/readable.d.ts +39 -0
- package/dist/query/helpers/streams/readable.d.ts.map +1 -0
- package/dist/query/helpers/transform.d.ts +8 -0
- package/dist/query/helpers/transform.d.ts.map +1 -0
- package/dist/query/helpers/where.d.ts +19 -0
- package/dist/query/helpers/where.d.ts.map +1 -0
- package/dist/query/index.d.ts +3 -0
- package/dist/query/index.d.ts.map +1 -0
- package/dist/query/query-builder.d.ts +79 -0
- package/dist/query/query-builder.d.ts.map +1 -0
- package/dist/query/types.d.ts +8 -0
- package/dist/query/types.d.ts.map +1 -0
- package/dist/schema/builder.d.ts +33 -0
- package/dist/schema/builder.d.ts.map +1 -0
- package/dist/schema/diff.d.ts +7 -0
- package/dist/schema/diff.d.ts.map +1 -0
- package/dist/schema/index.d.ts +20 -0
- package/dist/schema/index.d.ts.map +1 -0
- package/dist/schema/schema.d.ts +4 -0
- package/dist/schema/schema.d.ts.map +1 -0
- package/dist/schema/storage.d.ts +10 -0
- package/dist/schema/storage.d.ts.map +1 -0
- package/dist/schema/types.d.ts +103 -0
- package/dist/schema/types.d.ts.map +1 -0
- package/dist/transaction-context.d.ts +22 -0
- package/dist/transaction-context.d.ts.map +1 -0
- package/dist/types/index.d.ts +169 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/utils/content-types.d.ts +13 -0
- package/dist/utils/content-types.d.ts.map +1 -0
- package/dist/utils/knex.d.ts +12 -0
- package/dist/utils/knex.d.ts.map +1 -0
- package/dist/utils/types.d.ts +10 -0
- package/dist/utils/types.d.ts.map +1 -0
- package/dist/validations/index.d.ts +6 -0
- package/dist/validations/index.d.ts.map +1 -0
- package/dist/validations/relations/bidirectional.d.ts +12 -0
- package/dist/validations/relations/bidirectional.d.ts.map +1 -0
- package/dist/validations/relations/index.d.ts +7 -0
- package/dist/validations/relations/index.d.ts.map +1 -0
- package/package.json +21 -9
- package/.eslintignore +0 -2
- package/.eslintrc.js +0 -4
- package/jest.config.js +0 -6
- package/lib/__tests__/index.test.js +0 -93
- package/lib/__tests__/lifecycles.test.js +0 -55
- package/lib/connection.js +0 -64
- package/lib/dialects/dialect.js +0 -63
- package/lib/dialects/index.js +0 -53
- package/lib/dialects/mysql/constants.js +0 -6
- package/lib/dialects/mysql/database-inspector.js +0 -37
- package/lib/dialects/mysql/index.js +0 -92
- package/lib/dialects/mysql/schema-inspector.js +0 -234
- package/lib/dialects/postgresql/index.js +0 -65
- package/lib/dialects/postgresql/schema-inspector.js +0 -283
- package/lib/dialects/sqlite/index.js +0 -87
- package/lib/dialects/sqlite/schema-inspector.js +0 -151
- package/lib/entity-manager/__tests__/relations-orderer.test.js +0 -186
- package/lib/entity-manager/__tests__/sort-connect-array.test.js +0 -79
- package/lib/entity-manager/entity-repository.js +0 -164
- package/lib/entity-manager/index.js +0 -1385
- package/lib/entity-manager/morph-relations.js +0 -63
- package/lib/entity-manager/regular-relations.js +0 -506
- package/lib/entity-manager/relations/cloning/regular-relations.js +0 -76
- package/lib/entity-manager/relations-orderer.js +0 -225
- package/lib/errors/database.js +0 -12
- package/lib/errors/index.js +0 -17
- package/lib/errors/invalid-date.js +0 -14
- package/lib/errors/invalid-datetime.js +0 -14
- package/lib/errors/invalid-relation.js +0 -14
- package/lib/errors/invalid-time.js +0 -14
- package/lib/errors/not-null.js +0 -15
- package/lib/fields/biginteger.js +0 -17
- package/lib/fields/boolean.js +0 -39
- package/lib/fields/date.js +0 -16
- package/lib/fields/datetime.js +0 -19
- package/lib/fields/field.js +0 -17
- package/lib/fields/index.d.ts +0 -9
- package/lib/fields/index.js +0 -50
- package/lib/fields/json.js +0 -21
- package/lib/fields/number.js +0 -23
- package/lib/fields/shared/parsers.js +0 -71
- package/lib/fields/string.js +0 -17
- package/lib/fields/time.js +0 -17
- package/lib/fields/timestamp.js +0 -19
- package/lib/index.d.ts +0 -198
- package/lib/index.js +0 -129
- package/lib/lifecycles/index.d.ts +0 -51
- package/lib/lifecycles/index.js +0 -90
- package/lib/lifecycles/subscribers/index.d.ts +0 -11
- package/lib/lifecycles/subscribers/models-lifecycles.js +0 -19
- package/lib/lifecycles/subscribers/timestamps.js +0 -65
- package/lib/metadata/index.js +0 -244
- package/lib/metadata/relations.js +0 -578
- package/lib/migrations/index.d.ts +0 -9
- package/lib/migrations/index.js +0 -75
- package/lib/migrations/storage.js +0 -44
- package/lib/query/helpers/index.js +0 -11
- package/lib/query/helpers/join.js +0 -96
- package/lib/query/helpers/order-by.js +0 -70
- package/lib/query/helpers/populate/apply.js +0 -664
- package/lib/query/helpers/populate/index.js +0 -9
- package/lib/query/helpers/populate/process.js +0 -102
- package/lib/query/helpers/search.js +0 -84
- package/lib/query/helpers/streams/index.js +0 -5
- package/lib/query/helpers/streams/readable.js +0 -174
- package/lib/query/helpers/transform.js +0 -84
- package/lib/query/helpers/where.js +0 -365
- package/lib/query/index.js +0 -7
- package/lib/query/query-builder.js +0 -514
- package/lib/schema/__tests__/schema-diff.test.js +0 -231
- package/lib/schema/builder.js +0 -386
- package/lib/schema/diff.js +0 -399
- package/lib/schema/index.d.ts +0 -49
- package/lib/schema/index.js +0 -94
- package/lib/schema/schema.js +0 -202
- package/lib/schema/storage.js +0 -76
- package/lib/transaction-context.js +0 -68
- package/lib/types/index.d.ts +0 -6
- package/lib/types/index.js +0 -35
- package/lib/utils/content-types.js +0 -40
- package/lib/utils/knex.js +0 -22
- package/lib/validations/index.js +0 -20
- package/lib/validations/relations/bidirectional.js +0 -89
- package/lib/validations/relations/index.js +0 -14
package/README.md
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"connection.d.ts","sourceRoot":"","sources":["../src/connection.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAkDjC,eAAO,MAAM,gBAAgB,WAAY,KAAK,MAAM,yBASnD,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { Database } from '..';
|
|
2
|
+
import type { Schema } from '../schema';
|
|
3
|
+
export interface SchemaInspector {
|
|
4
|
+
getSchema(): Promise<Schema>;
|
|
5
|
+
}
|
|
6
|
+
export default class Dialect {
|
|
7
|
+
db: Database;
|
|
8
|
+
schemaInspector: SchemaInspector;
|
|
9
|
+
client: string;
|
|
10
|
+
constructor(db: Database, client: string);
|
|
11
|
+
configure(): void;
|
|
12
|
+
initialize(): void;
|
|
13
|
+
getSqlType(type: unknown): unknown;
|
|
14
|
+
canAlterConstraints(): boolean;
|
|
15
|
+
usesForeignKeys(): boolean;
|
|
16
|
+
useReturning(): boolean;
|
|
17
|
+
supportsUnsigned(): boolean;
|
|
18
|
+
supportsWindowFunctions(): boolean;
|
|
19
|
+
supportsOperator(operator?: string): boolean;
|
|
20
|
+
startSchemaUpdate(): Promise<void>;
|
|
21
|
+
endSchemaUpdate(): Promise<void>;
|
|
22
|
+
transformErrors(error: Error | {
|
|
23
|
+
message: string;
|
|
24
|
+
}): void;
|
|
25
|
+
canAddIncrements(): boolean;
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=dialect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dialect.d.ts","sourceRoot":"","sources":["../../src/dialects/dialect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AACnC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAExC,MAAM,WAAW,eAAe;IAC9B,SAAS,IAAI,OAAO,CAAC,MAAM,CAAC,CAAC;CAC9B;AAED,MAAM,CAAC,OAAO,OAAO,OAAO;IAC1B,EAAE,EAAE,QAAQ,CAAC;IAEb,eAAe,EAAE,eAAe,CAAyB;IAEzD,MAAM,EAAE,MAAM,CAAC;gBAEH,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM;IAKxC,SAAS;IAET,UAAU;IAEV,UAAU,CAAC,IAAI,EAAE,OAAO;IAIxB,mBAAmB;IAInB,eAAe;IAIf,YAAY;IAIZ,gBAAgB;IAIhB,uBAAuB;IAIvB,gBAAgB,CAAC,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO;IAKtC,iBAAiB;IAIjB,eAAe;IAIrB,eAAe,CAAC,KAAK,EAAE,KAAK,GAAG;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE;IAQlD,gBAAgB;CAGjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dialects/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AACnC,OAAO,OAAO,MAAM,WAAW,CAAC;AAuChC,QAAA,MAAM,UAAU,OAAQ,QAAQ,YAQ/B,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/dialects/mysql/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,KAAK,UAAU,CAAC;AAC7B,eAAO,MAAM,OAAO,YAAY,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { MARIADB, MYSQL } from './constants';
|
|
2
|
+
import type { Database } from '../..';
|
|
3
|
+
export interface Information {
|
|
4
|
+
database: typeof MARIADB | typeof MYSQL | null;
|
|
5
|
+
version: string | null;
|
|
6
|
+
}
|
|
7
|
+
export default class MysqlDatabaseInspector {
|
|
8
|
+
db: Database;
|
|
9
|
+
constructor(db: Database);
|
|
10
|
+
getInformation(): Promise<Information>;
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=database-inspector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"database-inspector.d.ts","sourceRoot":"","sources":["../../../src/dialects/mysql/database-inspector.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEtC,MAAM,WAAW,WAAW;IAC1B,QAAQ,EAAE,OAAO,OAAO,GAAG,OAAO,KAAK,GAAG,IAAI,CAAC;IAC/C,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;CACxB;AAMD,MAAM,CAAC,OAAO,OAAO,sBAAsB;IACzC,EAAE,EAAE,QAAQ,CAAC;gBAED,EAAE,EAAE,QAAQ;IAIlB,cAAc,IAAI,OAAO,CAAC,WAAW,CAAC;CAqB7C"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import Dialect from '../dialect';
|
|
2
|
+
import MysqlSchemaInspector from './schema-inspector';
|
|
3
|
+
import MysqlDatabaseInspector from './database-inspector';
|
|
4
|
+
import type { Database } from '../..';
|
|
5
|
+
import type { Information } from './database-inspector';
|
|
6
|
+
export default class MysqlDialect extends Dialect {
|
|
7
|
+
schemaInspector: MysqlSchemaInspector;
|
|
8
|
+
databaseInspector: MysqlDatabaseInspector;
|
|
9
|
+
info: Information | null;
|
|
10
|
+
constructor(db: Database);
|
|
11
|
+
configure(): void;
|
|
12
|
+
initialize(): Promise<void>;
|
|
13
|
+
startSchemaUpdate(): Promise<void>;
|
|
14
|
+
endSchemaUpdate(): Promise<void>;
|
|
15
|
+
supportsUnsigned(): boolean;
|
|
16
|
+
supportsWindowFunctions(): boolean;
|
|
17
|
+
usesForeignKeys(): boolean;
|
|
18
|
+
transformErrors(error: Error): void;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/dialects/mysql/index.ts"],"names":[],"mappings":"AAGA,OAAO,OAAO,MAAM,YAAY,CAAC;AACjC,OAAO,oBAAoB,MAAM,oBAAoB,CAAC;AACtD,OAAO,sBAAsB,MAAM,sBAAsB,CAAC;AAE1D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEtC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAExD,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,OAAO;IAC/C,eAAe,EAAE,oBAAoB,CAAC;IAEtC,iBAAiB,EAAE,sBAAsB,CAAC;IAE1C,IAAI,EAAE,WAAW,GAAG,IAAI,CAAQ;gBAEpB,EAAE,EAAE,QAAQ;IAOxB,SAAS;IA+BH,UAAU;IAUV,iBAAiB;IASjB,eAAe;IAIrB,gBAAgB;IAIhB,uBAAuB;IAYvB,eAAe;IAIf,eAAe,CAAC,KAAK,EAAE,KAAK;CAG7B"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Column, ForeignKey, Index, Schema } from '../../schema/types';
|
|
2
|
+
import type { SchemaInspector } from '../dialect';
|
|
3
|
+
import type { Database } from '../..';
|
|
4
|
+
export default class MysqlSchemaInspector implements SchemaInspector {
|
|
5
|
+
db: Database;
|
|
6
|
+
constructor(db: Database);
|
|
7
|
+
getSchema(): Promise<Schema>;
|
|
8
|
+
getTables(): Promise<string[]>;
|
|
9
|
+
getColumns(tableName: string): Promise<Column[]>;
|
|
10
|
+
getIndexes(tableName: string): Promise<Index[]>;
|
|
11
|
+
getForeignKeys(tableName: string): Promise<ForeignKey[]>;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=schema-inspector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema-inspector.d.ts","sourceRoot":"","sources":["../../../src/dialects/mysql/schema-inspector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAClD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAsItC,MAAM,CAAC,OAAO,OAAO,oBAAqB,YAAW,eAAe;IAClE,EAAE,EAAE,QAAQ,CAAC;gBAED,EAAE,EAAE,QAAQ;IAIlB,SAAS;IAuBT,SAAS,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;IAM9B,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;IAoBhD,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,KAAK,EAAE,CAAC;IA4B/C,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;CA+C/D"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import type { Database } from '../..';
|
|
3
|
+
import Dialect from '../dialect';
|
|
4
|
+
import PostgresqlSchemaInspector from './schema-inspector';
|
|
5
|
+
export default class PostgresDialect extends Dialect {
|
|
6
|
+
schemaInspector: PostgresqlSchemaInspector;
|
|
7
|
+
constructor(db: Database);
|
|
8
|
+
useReturning(): boolean;
|
|
9
|
+
initialize(): Promise<void>;
|
|
10
|
+
usesForeignKeys(): boolean;
|
|
11
|
+
getSqlType(type: string): string;
|
|
12
|
+
transformErrors(error: NodeJS.ErrnoException): void;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/dialects/postgresql/index.ts"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,OAAO,MAAM,YAAY,CAAC;AACjC,OAAO,yBAAyB,MAAM,oBAAoB,CAAC;AAE3D,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,OAAO;IAClD,eAAe,EAAE,yBAAyB,CAAC;gBAE/B,EAAE,EAAE,QAAQ;IAMxB,YAAY;IAIN,UAAU;IAoBhB,eAAe;IAIf,UAAU,CAAC,IAAI,EAAE,MAAM;IAWvB,eAAe,CAAC,KAAK,EAAE,MAAM,CAAC,cAAc;CAY7C"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Database } from '../..';
|
|
2
|
+
import type { Schema, Column, Index, ForeignKey } from '../../schema/types';
|
|
3
|
+
import type { SchemaInspector } from '../dialect';
|
|
4
|
+
export default class PostgresqlSchemaInspector implements SchemaInspector {
|
|
5
|
+
db: Database;
|
|
6
|
+
constructor(db: Database);
|
|
7
|
+
getSchema(): Promise<Schema>;
|
|
8
|
+
getDatabaseSchema(): string;
|
|
9
|
+
getTables(): Promise<string[]>;
|
|
10
|
+
getColumns(tableName: string): Promise<Column[]>;
|
|
11
|
+
getIndexes(tableName: string): Promise<Index[]>;
|
|
12
|
+
getForeignKeys(tableName: string): Promise<ForeignKey[]>;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=schema-inspector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema-inspector.d.ts","sourceRoot":"","sources":["../../../src/dialects/postgresql/schema-inspector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AA8JlD,MAAM,CAAC,OAAO,OAAO,yBAA0B,YAAW,eAAe;IACvE,EAAE,EAAE,QAAQ,CAAC;gBAED,EAAE,EAAE,QAAQ;IAIlB,SAAS;IAuBf,iBAAiB,IAAI,MAAM;IAIrB,SAAS,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;IAQ9B,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;IAwBhD,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,KAAK,EAAE,CAAC;IA2B/C,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;CAsD/D"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import Dialect from '../dialect';
|
|
3
|
+
import SqliteSchemaInspector from './schema-inspector';
|
|
4
|
+
import type { Database } from '../..';
|
|
5
|
+
export default class SqliteDialect extends Dialect {
|
|
6
|
+
schemaInspector: SqliteSchemaInspector;
|
|
7
|
+
constructor(db: Database);
|
|
8
|
+
configure(): void;
|
|
9
|
+
useReturning(): boolean;
|
|
10
|
+
initialize(): Promise<void>;
|
|
11
|
+
canAlterConstraints(): boolean;
|
|
12
|
+
getSqlType(type: string): string;
|
|
13
|
+
supportsOperator(operator: string): boolean;
|
|
14
|
+
startSchemaUpdate(): Promise<void>;
|
|
15
|
+
endSchemaUpdate(): Promise<void>;
|
|
16
|
+
transformErrors(error: NodeJS.ErrnoException): void;
|
|
17
|
+
canAddIncrements(): boolean;
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/dialects/sqlite/index.ts"],"names":[],"mappings":";AAKA,OAAO,OAAO,MAAM,YAAY,CAAC;AACjC,OAAO,qBAAqB,MAAM,oBAAoB,CAAC;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAItC,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,OAAO;IAChD,eAAe,EAAE,qBAAqB,CAAC;gBAE3B,EAAE,EAAE,QAAQ;IAMxB,SAAS;IAWT,YAAY;IAIN,UAAU;IAIhB,mBAAmB;IAInB,UAAU,CAAC,IAAI,EAAE,MAAM;IAkBvB,gBAAgB,CAAC,QAAQ,EAAE,MAAM;IAI3B,iBAAiB;IAIjB,eAAe;IAIrB,eAAe,CAAC,KAAK,EAAE,MAAM,CAAC,cAAc;IAW5C,gBAAgB;CAGjB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Database } from '../..';
|
|
2
|
+
import type { Schema, Column, Index, ForeignKey } from '../../schema/types';
|
|
3
|
+
import type { SchemaInspector } from '../dialect';
|
|
4
|
+
export default class SqliteSchemaInspector implements SchemaInspector {
|
|
5
|
+
db: Database;
|
|
6
|
+
constructor(db: Database);
|
|
7
|
+
getSchema(): Promise<Schema>;
|
|
8
|
+
getTables(): Promise<string[]>;
|
|
9
|
+
getColumns(tableName: string): Promise<Column[]>;
|
|
10
|
+
getIndexes(tableName: string): Promise<Index[]>;
|
|
11
|
+
getForeignKeys(tableName: string): Promise<ForeignKey[]>;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=schema-inspector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema-inspector.d.ts","sourceRoot":"","sources":["../../../src/dialects/sqlite/schema-inspector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAqGlD,MAAM,CAAC,OAAO,OAAO,qBAAsB,YAAW,eAAe;IACnE,EAAE,EAAE,QAAQ,CAAC;gBAED,EAAE,EAAE,QAAQ;IAIlB,SAAS;IAoBT,SAAS,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;IAM9B,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;IAkBhD,UAAU,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,KAAK,EAAE,CAAC;IAyB/C,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;CA0B/D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entity-repository.d.ts","sourceRoot":"","sources":["../../src/entity-manager/entity-repository.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AACnC,OAAO,KAAK,EAAE,UAAU,EAAU,MAAM,SAAS,CAAC;AAkClD,eAAO,MAAM,gBAAgB,QAAS,MAAM,MAAM,QAAQ,KAAG,UAsI5D,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/entity-manager/index.ts"],"names":[],"mappings":"AAoDA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AAGnC,OAAO,EAAE,aAAa,EAAsB,MAAM,SAAS,CAAC;AAE5D,cAAc,SAAS,CAAC;AAuLxB,eAAO,MAAM,mBAAmB,OAAQ,QAAQ,KAAG,aAysClD,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Knex } from 'knex';
|
|
2
|
+
import type { Database } from '..';
|
|
3
|
+
import type { MorphJoinTable } from '../types';
|
|
4
|
+
type Rows = Record<string, unknown>[];
|
|
5
|
+
export declare const deleteRelatedMorphOneRelationsAfterMorphToManyUpdate: (rows: Rows, { uid, attributeName, joinTable, db, transaction: trx, }: {
|
|
6
|
+
uid: string;
|
|
7
|
+
attributeName: string;
|
|
8
|
+
joinTable: MorphJoinTable;
|
|
9
|
+
db: Database;
|
|
10
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
11
|
+
}) => Promise<void>;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=morph-relations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"morph-relations.d.ts","sourceRoot":"","sources":["../../src/entity-manager/morph-relations.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAGjC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AACnC,OAAO,KAAK,EAAE,cAAc,EAAY,MAAM,UAAU,CAAC;AAEzD,KAAK,IAAI,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,CAAC;AA8BtC,eAAO,MAAM,oDAAoD;SASxD,MAAM;mBACI,MAAM;eACV,cAAc;QACrB,QAAQ;;mBAsCf,CAAC"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import type { Knex } from 'knex';
|
|
2
|
+
import type { Database } from '..';
|
|
3
|
+
import type { ID, Relation } from '../types';
|
|
4
|
+
declare module 'knex' {
|
|
5
|
+
namespace Knex {
|
|
6
|
+
interface ChainableInterface {
|
|
7
|
+
transacting(trx?: Knex.Transaction): this;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* If some relations currently exist for this oneToX relation, on the one side, this function removes them and update the inverse order if needed.
|
|
13
|
+
*/
|
|
14
|
+
declare const deletePreviousOneToAnyRelations: ({ id, attribute, relIdsToadd, db, transaction: trx, }: {
|
|
15
|
+
id: ID;
|
|
16
|
+
attribute: Relation.Bidirectional;
|
|
17
|
+
relIdsToadd: ID[];
|
|
18
|
+
db: Database;
|
|
19
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
20
|
+
}) => Promise<void>;
|
|
21
|
+
/**
|
|
22
|
+
* If a relation currently exists for this xToOne relations, this function removes it and update the inverse order if needed.
|
|
23
|
+
*/
|
|
24
|
+
declare const deletePreviousAnyToOneRelations: ({ id, attribute, relIdToadd, db, transaction: trx, }: {
|
|
25
|
+
id: ID;
|
|
26
|
+
attribute: Relation.Bidirectional;
|
|
27
|
+
relIdToadd: ID;
|
|
28
|
+
db: Database;
|
|
29
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
30
|
+
}) => Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
* Delete all or some relations of entity field
|
|
33
|
+
*/
|
|
34
|
+
declare const deleteRelations: ({ id, attribute, db, relIdsToNotDelete, relIdsToDelete, transaction: trx, }: {
|
|
35
|
+
id: ID;
|
|
36
|
+
attribute: Relation.Bidirectional;
|
|
37
|
+
db: Database;
|
|
38
|
+
relIdsToNotDelete?: ID[] | undefined;
|
|
39
|
+
relIdsToDelete?: ID[] | "all" | undefined;
|
|
40
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
41
|
+
}) => Promise<void>;
|
|
42
|
+
/**
|
|
43
|
+
* Clean the order columns by ensuring the order value are continuous (ex: 1, 2, 3 and not 1, 5, 10)
|
|
44
|
+
*/
|
|
45
|
+
declare const cleanOrderColumns: ({ id, attribute, db, inverseRelIds, transaction: trx, }: {
|
|
46
|
+
id?: ID | undefined;
|
|
47
|
+
attribute: Relation.Bidirectional;
|
|
48
|
+
db: Database;
|
|
49
|
+
inverseRelIds?: ID[] | undefined;
|
|
50
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
51
|
+
}) => Promise<[void, void] | undefined>;
|
|
52
|
+
/**
|
|
53
|
+
* Use this when a relation is added or removed and its inverse order column
|
|
54
|
+
* needs to be re-calculated
|
|
55
|
+
*
|
|
56
|
+
* Example: In this following table
|
|
57
|
+
*
|
|
58
|
+
* | joinColumn | inverseJoinColumn | order | inverseOrder |
|
|
59
|
+
* | --------------- | -------- | ----------- | ------------------ |
|
|
60
|
+
* | 1 | 1 | 1 | 1 |
|
|
61
|
+
* | 2 | 1 | 3 | 2 |
|
|
62
|
+
* | 2 | 2 | 3 | 1 |
|
|
63
|
+
*
|
|
64
|
+
* You add a new relation { joinColumn: 1, inverseJoinColumn: 2 }
|
|
65
|
+
*
|
|
66
|
+
* | joinColumn | inverseJoinColumn | order | inverseOrder |
|
|
67
|
+
* | --------------- | -------- | ----------- | ------------------ |
|
|
68
|
+
* | 1 | 1 | 1 | 1 |
|
|
69
|
+
* | 1 | 2 | 2 | 1 | <- inverseOrder should be 2
|
|
70
|
+
* | 2 | 1 | 3 | 2 |
|
|
71
|
+
* | 2 | 2 | 3 | 1 |
|
|
72
|
+
*
|
|
73
|
+
* This function would make such update, so all inverse order columns related
|
|
74
|
+
* to the given id (1 in this example) are following a 1, 2, 3 sequence, without gap.
|
|
75
|
+
*
|
|
76
|
+
*/
|
|
77
|
+
declare const cleanInverseOrderColumn: ({ id, attribute, trx, }: {
|
|
78
|
+
id: ID;
|
|
79
|
+
attribute: Relation.Bidirectional;
|
|
80
|
+
trx: Knex.Transaction;
|
|
81
|
+
}) => Promise<void>;
|
|
82
|
+
export { deletePreviousOneToAnyRelations, deletePreviousAnyToOneRelations, deleteRelations, cleanOrderColumns, cleanInverseOrderColumn, };
|
|
83
|
+
//# sourceMappingURL=regular-relations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"regular-relations.d.ts","sourceRoot":"","sources":["../../src/entity-manager/regular-relations.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAYjC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AACnC,OAAO,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAE7C,OAAO,QAAQ,MAAM,CAAC;IACpB,UAAU,IAAI,CAAC;QACb,UAAU,kBAAkB;YAC1B,WAAW,CAAC,GAAG,CAAC,EAAE,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;SAC3C;KACF;CACF;AAED;;GAEG;AACH,QAAA,MAAM,+BAA+B;QAO/B,EAAE;eACK,SAAS,aAAa;iBACpB,EAAE,EAAE;QACb,QAAQ;;mBAsBb,CAAC;AAEF;;GAEG;AACH,QAAA,MAAM,+BAA+B;QAO/B,EAAE;eACK,SAAS,aAAa;gBACrB,EAAE;QACV,QAAQ;;mBAgDb,CAAC;AAEF;;GAEG;AACH,QAAA,MAAM,eAAe;QAQf,EAAE;eACK,SAAS,aAAa;QAC7B,QAAQ;;;;mBA0Db,CAAC;AAEF;;GAEG;AACH,QAAA,MAAM,iBAAiB;;eAQV,SAAS,aAAa;QAC7B,QAAQ;;;uCA0Ib,CAAC;AAuFF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,QAAA,MAAM,uBAAuB;QAKvB,EAAE;eACK,SAAS,aAAa;SAC5B,KAAK,WAAW;mBA6DtB,CAAC;AAEF,OAAO,EACL,+BAA+B,EAC/B,+BAA+B,EAC/B,eAAe,EACf,iBAAiB,EACjB,uBAAuB,GACxB,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Knex } from 'knex';
|
|
2
|
+
import type { ID, Relation } from '../../../types';
|
|
3
|
+
declare const replaceRegularRelations: ({ targetId, sourceId, attribute, omitIds, transaction: trx, }: {
|
|
4
|
+
targetId: ID;
|
|
5
|
+
sourceId: ID;
|
|
6
|
+
attribute: Relation.Bidirectional;
|
|
7
|
+
omitIds: ID[];
|
|
8
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
9
|
+
}) => Promise<void>;
|
|
10
|
+
declare const cloneRegularRelations: ({ targetId, sourceId, attribute, transaction: trx, }: {
|
|
11
|
+
targetId: ID;
|
|
12
|
+
sourceId: ID;
|
|
13
|
+
attribute: Relation.Bidirectional;
|
|
14
|
+
transaction?: Knex.Transaction<any, any[]> | undefined;
|
|
15
|
+
}) => Promise<void>;
|
|
16
|
+
export { replaceRegularRelations, cloneRegularRelations };
|
|
17
|
+
//# sourceMappingURL=regular-relations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"regular-relations.d.ts","sourceRoot":"","sources":["../../../../src/entity-manager/relations/cloning/regular-relations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAG5B,OAAO,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAEnD,QAAA,MAAM,uBAAuB;cAOjB,EAAE;cACF,EAAE;eACD,SAAS,aAAa;aACxB,EAAE,EAAE;;mBAiBd,CAAC;AAEF,QAAA,MAAM,qBAAqB;cAMf,EAAE;cACF,EAAE;eACD,SAAS,aAAa;;mBAsDlC,CAAC;AAEF,OAAO,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,CAAC"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import type { ID } from '../types';
|
|
2
|
+
interface Link {
|
|
3
|
+
id: ID;
|
|
4
|
+
position?: {
|
|
5
|
+
before?: ID;
|
|
6
|
+
after?: ID;
|
|
7
|
+
start?: true;
|
|
8
|
+
end?: true;
|
|
9
|
+
};
|
|
10
|
+
order?: number;
|
|
11
|
+
}
|
|
12
|
+
interface OrderedLink extends Link {
|
|
13
|
+
init?: boolean;
|
|
14
|
+
order: number;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* When connecting relations, the order you connect them matters.
|
|
18
|
+
*
|
|
19
|
+
* Example, if you connect the following relations:
|
|
20
|
+
* { id: 5, position: { before: 1 } }
|
|
21
|
+
* { id: 1, position: { before: 2 } }
|
|
22
|
+
* { id: 2, position: { end: true } }
|
|
23
|
+
*
|
|
24
|
+
* Going through the connect array, id 5 has to be connected before id 1,
|
|
25
|
+
* so the order of id5 = id1 - 1. But the order value of id 1 is unknown.
|
|
26
|
+
* The only way to know the order of id 1 is to connect it first.
|
|
27
|
+
*
|
|
28
|
+
* This function makes sure the relations are connected in the right order:
|
|
29
|
+
* { id: 2, position: { end: true } }
|
|
30
|
+
* { id: 1, position: { before: 2 } }
|
|
31
|
+
* { id: 5, position: { before: 1 } }
|
|
32
|
+
*
|
|
33
|
+
*/
|
|
34
|
+
declare const sortConnectArray: (connectArr: Link[], initialArr?: Link[], strictSort?: boolean) => Link[];
|
|
35
|
+
/**
|
|
36
|
+
* Responsible for calculating the relations order when connecting them.
|
|
37
|
+
*
|
|
38
|
+
* The connect method takes an array of relations with positional attributes:
|
|
39
|
+
* - before: the id of the relation to connect before
|
|
40
|
+
* - after: the id of the relation to connect after
|
|
41
|
+
* - end: it should be at the end
|
|
42
|
+
* - start: it should be at the start
|
|
43
|
+
*
|
|
44
|
+
* Example:
|
|
45
|
+
* - Having a connect array like:
|
|
46
|
+
* [ { id: 4, before: 2 }, { id: 4, before: 3}, {id: 5, before: 4} ]
|
|
47
|
+
* - With the initial relations:
|
|
48
|
+
* [ { id: 2, order: 4 }, { id: 3, order: 10 } ]
|
|
49
|
+
* - Step by step, going through the connect array, the array of relations would be:
|
|
50
|
+
* [ { id: 4, order: 3.5 }, { id: 2, order: 4 }, { id: 3, order: 10 } ]
|
|
51
|
+
* [ { id: 2, order: 4 }, { id: 4, order: 3.5 }, { id: 3, order: 10 } ]
|
|
52
|
+
* [ { id: 2, order: 4 }, { id: 5, order: 3.5 }, { id: 4, order: 3.5 }, { id: 3, order: 10 } ]
|
|
53
|
+
* - The final step would be to recalculate fractional order values.
|
|
54
|
+
* [ { id: 2, order: 4 }, { id: 5, order: 3.33 }, { id: 4, order: 3.66 }, { id: 3, order: 10 } ]
|
|
55
|
+
*
|
|
56
|
+
* @param {Array<*>} initArr - array of relations to initialize the class with
|
|
57
|
+
* @param {string} idColumn - the column name of the id
|
|
58
|
+
* @param {string} orderColumn - the column name of the order
|
|
59
|
+
* @param {boolean} strict - if true, will throw an error if a relation is connected adjacent to
|
|
60
|
+
* another one that does not exist
|
|
61
|
+
* @return {*}
|
|
62
|
+
*/
|
|
63
|
+
declare const relationsOrderer: <TRelation extends Record<string, ID | null>>(initArr: TRelation[], idColumn: keyof TRelation, orderColumn: keyof TRelation, strict?: boolean) => {
|
|
64
|
+
disconnect(relations: Link | Link[]): any;
|
|
65
|
+
connect(relations: Link | Link[]): any;
|
|
66
|
+
get(): OrderedLink[];
|
|
67
|
+
/**
|
|
68
|
+
* Get a map between the relation id and its order
|
|
69
|
+
*/
|
|
70
|
+
getOrderMap(): Record<ID, number>;
|
|
71
|
+
};
|
|
72
|
+
export { relationsOrderer, sortConnectArray };
|
|
73
|
+
//# sourceMappingURL=relations-orderer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"relations-orderer.d.ts","sourceRoot":"","sources":["../../src/entity-manager/relations-orderer.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAEnC,UAAU,IAAI;IACZ,EAAE,EAAE,EAAE,CAAC;IACP,QAAQ,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE,EAAE,CAAC;QAAC,KAAK,CAAC,EAAE,EAAE,CAAC;QAAC,KAAK,CAAC,EAAE,IAAI,CAAC;QAAC,GAAG,CAAC,EAAE,IAAI,CAAA;KAAE,CAAC;IACjE,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,UAAU,WAAY,SAAQ,IAAI;IAChC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,QAAA,MAAM,gBAAgB,eAAgB,IAAI,EAAE,eAAc,IAAI,EAAE,iCAqF/D,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,QAAA,MAAM,gBAAgB,wIAIX,OAAO;0BAuDQ,IAAI,GAAG,IAAI,EAAE;uBAMhB,IAAI,GAAG,IAAI,EAAE;;IAqBhC;;OAEG;;CAaN,CAAC;AAEF,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import type { Knex } from 'knex';
|
|
2
|
+
import type { ID } from '../types';
|
|
3
|
+
import { QueryBuilder } from '../query/query-builder';
|
|
4
|
+
export type Data = Record<string, unknown>;
|
|
5
|
+
export type Params = {
|
|
6
|
+
where?: any;
|
|
7
|
+
filters?: any;
|
|
8
|
+
select?: any;
|
|
9
|
+
populate?: any;
|
|
10
|
+
orderBy?: any;
|
|
11
|
+
_q?: string;
|
|
12
|
+
data?: any;
|
|
13
|
+
page?: number;
|
|
14
|
+
pageSize?: number;
|
|
15
|
+
limit?: number;
|
|
16
|
+
offset?: number;
|
|
17
|
+
count?: boolean;
|
|
18
|
+
};
|
|
19
|
+
type FindOneParams = Pick<Params, 'where' | 'select' | 'populate' | '_q' | 'orderBy'>;
|
|
20
|
+
export interface Repository {
|
|
21
|
+
findOne(params?: FindOneParams): Promise<any>;
|
|
22
|
+
findMany(params?: Params): Promise<any[]>;
|
|
23
|
+
findWithCount(params?: Params): Promise<[any[], number]>;
|
|
24
|
+
findPage(params: Params): Promise<{
|
|
25
|
+
results: any[];
|
|
26
|
+
pagination: {
|
|
27
|
+
page: number;
|
|
28
|
+
pageSize: number;
|
|
29
|
+
pageCount: number;
|
|
30
|
+
total: number;
|
|
31
|
+
};
|
|
32
|
+
}>;
|
|
33
|
+
create(params: Params): Promise<any>;
|
|
34
|
+
createMany(params: Params): Promise<{
|
|
35
|
+
count: number;
|
|
36
|
+
ids: ID[];
|
|
37
|
+
}>;
|
|
38
|
+
update(params: Params): Promise<any>;
|
|
39
|
+
updateMany(params: Params): Promise<{
|
|
40
|
+
count: number;
|
|
41
|
+
}>;
|
|
42
|
+
clone(id: ID, params: Params): Promise<any>;
|
|
43
|
+
delete(params: Params): Promise<any>;
|
|
44
|
+
deleteMany(params?: Params): Promise<{
|
|
45
|
+
count: number;
|
|
46
|
+
}>;
|
|
47
|
+
count(params?: Params): Promise<number>;
|
|
48
|
+
attachRelations(id: ID, data: Data): Promise<any>;
|
|
49
|
+
updateRelations(id: ID, data: Data): Promise<any>;
|
|
50
|
+
deleteRelations(id: ID): Promise<any>;
|
|
51
|
+
cloneRelations(targetId: ID, sourceId: ID, params: Params): Promise<any>;
|
|
52
|
+
populate(entity: Entity, populate: Params['populate']): Promise<any>;
|
|
53
|
+
load(entity: any, field: string | string[], populate?: Params['populate']): Promise<any>;
|
|
54
|
+
loadPages<TField extends string>(entity: any, field: TField | TField[], populate?: Params['populate']): Promise<any>;
|
|
55
|
+
}
|
|
56
|
+
export type Entity = {
|
|
57
|
+
id: ID;
|
|
58
|
+
[key: string]: any;
|
|
59
|
+
};
|
|
60
|
+
export interface EntityManager {
|
|
61
|
+
findOne(uid: string, params: Params): Promise<any>;
|
|
62
|
+
findMany(uid: string, params: Params): Promise<any[]>;
|
|
63
|
+
count(uid: string, params?: Params): Promise<number>;
|
|
64
|
+
create(uid: string, params: Params): Promise<any>;
|
|
65
|
+
createMany(uid: string, params: Params): Promise<{
|
|
66
|
+
count: number;
|
|
67
|
+
ids: ID[];
|
|
68
|
+
}>;
|
|
69
|
+
update(uid: string, params: Params): Promise<any>;
|
|
70
|
+
updateMany(uid: string, params: Params): Promise<{
|
|
71
|
+
count: number;
|
|
72
|
+
}>;
|
|
73
|
+
delete(uid: string, params: Params): Promise<any>;
|
|
74
|
+
deleteMany(uid: string, params: Params): Promise<{
|
|
75
|
+
count: number;
|
|
76
|
+
}>;
|
|
77
|
+
clone(uid: string, cloneId: ID, params: Params): Promise<any>;
|
|
78
|
+
populate(uid: string, entity: Entity, populate: Params['populate']): Promise<Entity>;
|
|
79
|
+
load(uid: string, entity: Entity, field: string | string[], populate?: Params['populate']): Promise<any>;
|
|
80
|
+
attachRelations(uid: string, id: ID, data: any, options?: {
|
|
81
|
+
transaction?: Knex.Transaction;
|
|
82
|
+
}): Promise<any>;
|
|
83
|
+
updateRelations(uid: string, id: ID, data: any, options?: {
|
|
84
|
+
transaction?: Knex.Transaction;
|
|
85
|
+
}): Promise<any>;
|
|
86
|
+
deleteRelations(uid: string, id: ID, options?: {
|
|
87
|
+
transaction?: Knex.Transaction;
|
|
88
|
+
}): Promise<void>;
|
|
89
|
+
cloneRelations(uid: string, targetId: ID, sourceId: ID, data: any, options?: {
|
|
90
|
+
cloneAttrs?: string[];
|
|
91
|
+
transaction?: Knex.Transaction;
|
|
92
|
+
}): Promise<any>;
|
|
93
|
+
createQueryBuilder(uid: string): QueryBuilder;
|
|
94
|
+
getRepository(uid: string): Repository;
|
|
95
|
+
}
|
|
96
|
+
export {};
|
|
97
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/entity-manager/types.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"database.d.ts","sourceRoot":"","sources":["../../src/errors/database.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,KAAK;IAC9C,OAAO,EAAE,OAAO,CAAC;gBAEL,OAAO,SAA6B,EAAE,OAAO,KAAK;CAM/D"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import DatabaseError from './database';
|
|
2
|
+
import NotNullError from './not-null';
|
|
3
|
+
import InvalidTimeError from './invalid-time';
|
|
4
|
+
import InvalidDateError from './invalid-date';
|
|
5
|
+
import InvalidDateTimeError from './invalid-datetime';
|
|
6
|
+
import InvalidRelationError from './invalid-relation';
|
|
7
|
+
export { DatabaseError, NotNullError, InvalidTimeError, InvalidDateError, InvalidDateTimeError, InvalidRelationError, };
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,YAAY,CAAC;AACvC,OAAO,YAAY,MAAM,YAAY,CAAC;AACtC,OAAO,gBAAgB,MAAM,gBAAgB,CAAC;AAC9C,OAAO,gBAAgB,MAAM,gBAAgB,CAAC;AAC9C,OAAO,oBAAoB,MAAM,oBAAoB,CAAC;AACtD,OAAO,oBAAoB,MAAM,oBAAoB,CAAC;AAEtD,OAAO,EACL,aAAa,EACb,YAAY,EACZ,gBAAgB,EAChB,gBAAgB,EAChB,oBAAoB,EACpB,oBAAoB,GACrB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"invalid-date.d.ts","sourceRoot":"","sources":["../../src/errors/invalid-date.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,YAAY,CAAC;AAEvC,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,aAAa;gBAC7C,OAAO,SAA6C;CAIjE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"invalid-datetime.d.ts","sourceRoot":"","sources":["../../src/errors/invalid-datetime.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,YAAY,CAAC;AAEvC,MAAM,CAAC,OAAO,OAAO,oBAAqB,SAAQ,aAAa;gBACjD,OAAO,SAA4B;CAIhD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"invalid-relation.d.ts","sourceRoot":"","sources":["../../src/errors/invalid-relation.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,YAAY,CAAC;AAEvC,MAAM,CAAC,OAAO,OAAO,oBAAqB,SAAQ,aAAa;gBACjD,OAAO,SAA4B;CAIhD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"invalid-time.d.ts","sourceRoot":"","sources":["../../src/errors/invalid-time.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,YAAY,CAAC;AAEvC,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,aAAa;gBAC7C,OAAO,SAA+C;CAInE"}
|