@autofleet/sadot 0.13.2-beta.6 → 0.13.2-beta.7
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/dist/models/index.d.ts +1 -1
- package/dist/models/index.js +1 -5
- package/package.json +1 -1
- package/dist/models/test.js +0 -9
package/dist/models/index.d.ts
CHANGED
|
@@ -13,6 +13,6 @@ interface InitTablesOptions {
|
|
|
13
13
|
schemaVersion?: string;
|
|
14
14
|
useCustomFieldsEntries?: boolean;
|
|
15
15
|
}
|
|
16
|
-
declare const initTables: (sequelize: Sequelize, getUser: CustomFieldOptions['getUser'], { schemaPrefix, schemaVersion, useCustomFieldsEntries, }
|
|
16
|
+
declare const initTables: (sequelize: Sequelize, getUser: CustomFieldOptions['getUser'], { schemaPrefix, schemaVersion, useCustomFieldsEntries, }: InitTablesOptions) => Promise<void>;
|
|
17
17
|
declare const initTestModels: (sequelize: Sequelize) => Promise<void>;
|
|
18
18
|
export { CustomFieldValue, CustomFieldDefinition, CustomFieldEntries, CustomValidator, TestModel, AssociatedTestModel, ContextAwareTestModel, ContextTestModel, initTables, initTestModels, };
|
package/dist/models/index.js
CHANGED
|
@@ -27,11 +27,7 @@ const productionModels = [CustomFieldDefinition_1.default, CustomFieldValue_1.de
|
|
|
27
27
|
const testModels = [TestModel_1.default, AssociatedTestModel_1.default, ContextAwareTestModel_1.default, ContextTestModel_1.default];
|
|
28
28
|
const SADOT_MIGRATION_PREFIX = 'sadot-migration';
|
|
29
29
|
const SCHEMA_VERSION = '49c9dd1d-b1cc-445b-a911-fd349d783110';
|
|
30
|
-
const initTables = async (sequelize, getUser, { schemaPrefix, schemaVersion, useCustomFieldsEntries, }
|
|
31
|
-
schemaPrefix: SADOT_MIGRATION_PREFIX,
|
|
32
|
-
schemaVersion: SCHEMA_VERSION,
|
|
33
|
-
useCustomFieldsEntries: false,
|
|
34
|
-
}) => {
|
|
30
|
+
const initTables = async (sequelize, getUser, { schemaPrefix = SADOT_MIGRATION_PREFIX, schemaVersion = SCHEMA_VERSION, useCustomFieldsEntries = false, }) => {
|
|
35
31
|
const CUSTOM_FIELDS_SCHEMA_VERSION = `${schemaPrefix}_${schemaVersion}${useCustomFieldsEntries ? '_withEntries' : ''}`;
|
|
36
32
|
logger_1.default.info('custom-fields: initialize custom-fields tables');
|
|
37
33
|
// Detect models and import them to the orm
|
package/package.json
CHANGED
package/dist/models/test.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
const SADOT_MIGRATION_PREFIX = 'sadot-migration';
|
|
2
|
-
const SCHEMA_VERSION = '49c9dd1d-b1cc-445b-a911-fd349d783110';
|
|
3
|
-
const initTables = async ({ schemaPrefix = SADOT_MIGRATION_PREFIX, schemaVersion = SCHEMA_VERSION, useCustomFieldsEntries = false }) => {
|
|
4
|
-
console.log('custom-fields: initialize custom-fields tables', {
|
|
5
|
-
schemaPrefix, schemaVersion, useCustomFieldsEntries,
|
|
6
|
-
});
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
initTables({useCustomFieldsEntries: true});
|