gina-sequelize 0.0.4 → 0.0.6
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/.env +5 -0
- package/dist/gina.d.ts +8 -0
- package/{lib/gina.ts → dist/gina.js} +22 -46
- package/dist/gina.js.map +1 -0
- package/gina/migrations/.gitkeep +0 -0
- package/gina/migrations/20240421140344.ts +133 -0
- package/gina/migrations/20240421140852.ts +13 -0
- package/gina/migrations/20240421141034.ts +30 -0
- package/gina/migrations/20240421141244.ts +17 -0
- package/gina/migrations/20240421141433.ts +17 -0
- package/gina/migrations/20240421142551.ts +17 -0
- package/gina/migrations/20240421142619.ts +17 -0
- package/gina/migrations/20240421142654.ts +17 -0
- package/gina/migrations/20240421142702.ts +17 -0
- package/gina/migrations/20240421142729.ts +17 -0
- package/gina/migrations/20240421142752.ts +17 -0
- package/gina/migrations/20240421142812.ts +17 -0
- package/gina/migrations/20240421142930.ts +17 -0
- package/gina/migrations/20240421143548.ts +17 -0
- package/gina/migrations/20240421143734.ts +17 -0
- package/gina/migrations/20240421144942.ts +17 -0
- package/gina/migrations/20240421151018.ts +17 -0
- package/package.json +1 -1
- package/tsconfig.json +0 -113
package/.env
ADDED
package/dist/gina.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Sequelize } from 'sequelize';
|
|
2
|
+
declare function runMigrations(): void;
|
|
3
|
+
declare function createMigration(sequelize: Sequelize): Promise<void>;
|
|
4
|
+
declare const gina: {
|
|
5
|
+
runMigrations: typeof runMigrations;
|
|
6
|
+
createMigration: typeof createMigration;
|
|
7
|
+
};
|
|
8
|
+
export default gina;
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const sequelize_1 = require("sequelize");
|
|
7
|
+
const promises_1 = __importDefault(require("fs/promises"));
|
|
8
|
+
const moment_1 = __importDefault(require("moment"));
|
|
5
9
|
function runMigrations() {
|
|
6
10
|
return;
|
|
7
11
|
}
|
|
8
|
-
|
|
9
|
-
async function createMigration(sequelize: Sequelize) {
|
|
12
|
+
async function createMigration(sequelize) {
|
|
10
13
|
const models = Object.keys(sequelize.models);
|
|
11
14
|
const queryInterface = sequelize.getQueryInterface();
|
|
12
15
|
const tables = await queryInterface.showAllTables();
|
|
13
|
-
|
|
14
|
-
const modelTables: string[] = [];
|
|
15
|
-
|
|
16
|
+
const modelTables = [];
|
|
16
17
|
let upTables = '';
|
|
17
18
|
let downTables = '';
|
|
18
19
|
let up = '';
|
|
19
20
|
let down = '';
|
|
20
21
|
const imports = ['QueryInterface'];
|
|
21
|
-
|
|
22
22
|
for (const model of models) {
|
|
23
|
-
const modelTable = sequelize.models[model].getTableName()
|
|
23
|
+
const modelTable = sequelize.models[model].getTableName();
|
|
24
24
|
modelTables.push(modelTable);
|
|
25
25
|
if (!tables.includes(modelTable)) {
|
|
26
26
|
// TODO: create proper logic to create table
|
|
@@ -29,68 +29,54 @@ async function createMigration(sequelize: Sequelize) {
|
|
|
29
29
|
upTables += `
|
|
30
30
|
await queryInterface.createTable('${modelTable}', {});
|
|
31
31
|
`;
|
|
32
|
-
|
|
33
32
|
downTables = `
|
|
34
33
|
await queryInterface.dropTable('${modelTable}');
|
|
35
34
|
` + downTables;
|
|
36
35
|
continue;
|
|
37
36
|
}
|
|
38
|
-
|
|
39
37
|
const modelAttrs = sequelize.models[model].getAttributes();
|
|
40
38
|
const attrs = await queryInterface.describeTable(modelTable);
|
|
41
|
-
|
|
42
|
-
const modelFields: string[] = [];
|
|
43
|
-
|
|
39
|
+
const modelFields = [];
|
|
44
40
|
for (const modelAttr of Object.keys(modelAttrs)) {
|
|
45
41
|
modelFields.push(modelAttrs[modelAttr].field || modelAttr);
|
|
46
|
-
if (!Object.keys(attrs).includes(modelAttrs[modelAttr].field || modelAttr) && !(modelAttrs[modelAttr].type instanceof DataTypes.VIRTUAL)) {
|
|
47
|
-
|
|
42
|
+
if (!Object.keys(attrs).includes(modelAttrs[modelAttr].field || modelAttr) && !(modelAttrs[modelAttr].type instanceof sequelize_1.DataTypes.VIRTUAL)) {
|
|
48
43
|
console.debug(`new column ${modelTable} ${modelAttr}`);
|
|
49
44
|
// console.debug(modelAttrs[modelAttr]);
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
let defaultValue: string;
|
|
53
|
-
|
|
45
|
+
const val = modelAttrs[modelAttr].defaultValue.val;
|
|
46
|
+
let defaultValue;
|
|
54
47
|
if (val) {
|
|
55
48
|
if (!imports.includes('Sequelize')) {
|
|
56
49
|
imports.push('Sequelize');
|
|
57
50
|
}
|
|
58
51
|
defaultValue = 'Sequelize.literal(\'CURRENT_TIMESTAMP\')';
|
|
59
|
-
} else {
|
|
60
|
-
defaultValue = modelAttrs[modelAttr].defaultValue as string;
|
|
61
52
|
}
|
|
62
|
-
|
|
53
|
+
else {
|
|
54
|
+
defaultValue = modelAttrs[modelAttr].defaultValue;
|
|
55
|
+
}
|
|
63
56
|
if (!imports.includes('DataTypes')) {
|
|
64
57
|
imports.push('DataTypes');
|
|
65
58
|
}
|
|
66
|
-
|
|
67
59
|
up += `
|
|
68
60
|
await queryInterface.addColumn('${modelTable}', '${modelAttrs[modelAttr].field}', {
|
|
69
|
-
type: DataTypes.${modelAttrs[modelAttr].type instanceof DataTypes.DATE ? 'DATE' : ''},
|
|
61
|
+
type: DataTypes.${modelAttrs[modelAttr].type instanceof sequelize_1.DataTypes.DATE ? 'DATE' : ''},
|
|
70
62
|
allowNull: ${modelAttrs[modelAttr].allowNull},
|
|
71
63
|
defaultValue: ${defaultValue}
|
|
72
64
|
});
|
|
73
65
|
`;
|
|
74
|
-
|
|
75
66
|
down = `
|
|
76
67
|
await queryInterface.removeColumn('${modelTable}', '${modelAttrs[modelAttr].field}');
|
|
77
68
|
` + down;
|
|
78
|
-
|
|
79
69
|
}
|
|
80
70
|
}
|
|
81
|
-
|
|
82
71
|
for (const attr of Object.keys(attrs)) {
|
|
83
72
|
if (!modelFields.includes(attr)) {
|
|
84
73
|
console.debug(`drop column ${modelTable} ${attr}`);
|
|
85
|
-
|
|
86
74
|
up += `
|
|
87
75
|
await queryInterface.removeColumn('${modelTable}', '${attr}');
|
|
88
76
|
`;
|
|
89
|
-
|
|
90
77
|
if (!imports.includes('DataTypes')) {
|
|
91
78
|
imports.push('DataTypes');
|
|
92
79
|
}
|
|
93
|
-
|
|
94
80
|
down = `
|
|
95
81
|
await queryInterface.addColumn('${modelTable}', '${attr}', {
|
|
96
82
|
type: DataTypes.${attrs[attr].type.replace('VARCHAR(', 'STRING(')},
|
|
@@ -100,14 +86,11 @@ async function createMigration(sequelize: Sequelize) {
|
|
|
100
86
|
` + down;
|
|
101
87
|
}
|
|
102
88
|
}
|
|
103
|
-
|
|
104
89
|
// TODO: add index and constraints
|
|
105
90
|
// sequelize.models[model].
|
|
106
91
|
// console.debug('sequelize.models.GinaVersion.options.indexes', sequelize.models.GinaVersion.options.indexes);
|
|
107
92
|
// console.log(sequelize.models[model]);
|
|
108
|
-
|
|
109
93
|
}
|
|
110
|
-
|
|
111
94
|
for (const table of tables) {
|
|
112
95
|
if (!modelTables.includes(table)) {
|
|
113
96
|
// TODO: create proper logic to delete table
|
|
@@ -115,13 +98,11 @@ async function createMigration(sequelize: Sequelize) {
|
|
|
115
98
|
upTables += `
|
|
116
99
|
await queryInterface.dropTable('${table}');
|
|
117
100
|
`;
|
|
118
|
-
|
|
119
101
|
downTables = `
|
|
120
102
|
await queryInterface.createTable('${table}', {});
|
|
121
103
|
` + downTables;
|
|
122
104
|
}
|
|
123
105
|
}
|
|
124
|
-
|
|
125
106
|
const migration = `import { ${imports.join(', ')} } from 'sequelize';
|
|
126
107
|
|
|
127
108
|
export const migration: Migration = {
|
|
@@ -135,16 +116,11 @@ ${down}
|
|
|
135
116
|
${downTables}
|
|
136
117
|
}
|
|
137
118
|
};`;
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
await fs.writeFile('./migrations/' + moment().format('YYYYMMDDHHmmss') + '.ts', migration);
|
|
141
|
-
|
|
142
|
-
|
|
119
|
+
await promises_1.default.writeFile('./migrations/' + (0, moment_1.default)().format('YYYYMMDDHHmmss') + '.ts', migration);
|
|
143
120
|
}
|
|
144
|
-
|
|
145
121
|
const gina = {
|
|
146
122
|
runMigrations,
|
|
147
123
|
createMigration,
|
|
148
124
|
};
|
|
149
|
-
|
|
150
|
-
|
|
125
|
+
exports.default = gina;
|
|
126
|
+
//# sourceMappingURL=gina.js.map
|
package/dist/gina.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gina.js","sourceRoot":"/","sources":["gina.ts"],"names":[],"mappings":"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","sourcesContent":["import { DataTypes, Sequelize } from 'sequelize';\nimport fs from 'fs/promises';\nimport moment from 'moment';\n\nfunction runMigrations() {\n return;\n}\n\nasync function createMigration(sequelize: Sequelize) {\n const models = Object.keys(sequelize.models);\n const queryInterface = sequelize.getQueryInterface();\n const tables = await queryInterface.showAllTables();\n\n const modelTables: string[] = [];\n\n let upTables = '';\n let downTables = '';\n let up = '';\n let down = '';\n const imports = ['QueryInterface'];\n\n for (const model of models) {\n const modelTable = sequelize.models[model].getTableName() as string;\n modelTables.push(modelTable);\n if (!tables.includes(modelTable)) {\n // TODO: create proper logic to create table\n console.debug(`new table ${modelTable}`);\n // console.debug('sequelize.models[model].getAttributes()', sequelize.models[model].getAttributes());\n upTables += `\n await queryInterface.createTable('${modelTable}', {});\n`;\n\n downTables = `\n await queryInterface.dropTable('${modelTable}');\n` + downTables;\n continue;\n }\n\n const modelAttrs = sequelize.models[model].getAttributes();\n const attrs = await queryInterface.describeTable(modelTable);\n\n const modelFields: string[] = [];\n\n for (const modelAttr of Object.keys(modelAttrs)) {\n modelFields.push(modelAttrs[modelAttr].field || modelAttr);\n if (!Object.keys(attrs).includes(modelAttrs[modelAttr].field || modelAttr) && !(modelAttrs[modelAttr].type instanceof DataTypes.VIRTUAL)) {\n\n console.debug(`new column ${modelTable} ${modelAttr}`);\n // console.debug(modelAttrs[modelAttr]);\n\n const val = (modelAttrs[modelAttr].defaultValue as { val?: string; }).val;\n let defaultValue: string;\n\n if (val) {\n if (!imports.includes('Sequelize')) {\n imports.push('Sequelize');\n }\n defaultValue = 'Sequelize.literal(\\'CURRENT_TIMESTAMP\\')';\n } else {\n defaultValue = modelAttrs[modelAttr].defaultValue as string;\n }\n\n if (!imports.includes('DataTypes')) {\n imports.push('DataTypes');\n }\n\n up += `\n await queryInterface.addColumn('${modelTable}', '${modelAttrs[modelAttr].field}', {\n type: DataTypes.${modelAttrs[modelAttr].type instanceof DataTypes.DATE ? 'DATE' : ''},\n allowNull: ${modelAttrs[modelAttr].allowNull},\n defaultValue: ${defaultValue}\n });\n`;\n\n down = `\n await queryInterface.removeColumn('${modelTable}', '${modelAttrs[modelAttr].field}');\n` + down;\n\n }\n }\n\n for (const attr of Object.keys(attrs)) {\n if (!modelFields.includes(attr)) {\n console.debug(`drop column ${modelTable} ${attr}`);\n\n up += `\n await queryInterface.removeColumn('${modelTable}', '${attr}');\n`;\n\n if (!imports.includes('DataTypes')) {\n imports.push('DataTypes');\n }\n\n down = `\n await queryInterface.addColumn('${modelTable}', '${attr}', {\n type: DataTypes.${attrs[attr].type.replace('VARCHAR(', 'STRING(')},\n allowNull: ${attrs[attr].allowNull ? 'true' : 'false'},\n defaultValue: ${attrs[attr].defaultValue},\n });\n` + down;\n }\n }\n\n // TODO: add index and constraints\n // sequelize.models[model].\n // console.debug('sequelize.models.GinaVersion.options.indexes', sequelize.models.GinaVersion.options.indexes);\n // console.log(sequelize.models[model]);\n\n }\n\n for (const table of tables) {\n if (!modelTables.includes(table)) {\n // TODO: create proper logic to delete table\n console.debug(`drop table ${table} `);\n upTables += `\n await queryInterface.dropTable('${table}');\n`;\n\n downTables = `\n await queryInterface.createTable('${table}', {});\n` + downTables;\n }\n }\n\n const migration = `import { ${imports.join(', ')} } from 'sequelize';\n\nexport const migration: Migration = {\n async up(queryInterface: QueryInterface) {\n${upTables}\n${up}\n },\n\n async down(queryInterface: QueryInterface) {\n${down}\n${downTables}\n }\n};`;\n\n\n await fs.writeFile('./migrations/' + moment().format('YYYYMMDDHHmmss') + '.ts', migration);\n\n\n}\n\nconst gina = {\n runMigrations,\n createMigration,\n};\n\nexport default gina;\n"]}
|
|
File without changes
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.dropTable('acting_bodies');
|
|
7
|
+
|
|
8
|
+
await queryInterface.dropTable('acting_regions');
|
|
9
|
+
|
|
10
|
+
await queryInterface.dropTable('camera_tags');
|
|
11
|
+
|
|
12
|
+
await queryInterface.dropTable('cameras');
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('cameras_metadata');
|
|
15
|
+
|
|
16
|
+
await queryInterface.dropTable('configuration');
|
|
17
|
+
|
|
18
|
+
await queryInterface.dropTable('dashboard');
|
|
19
|
+
|
|
20
|
+
await queryInterface.dropTable('dashboard_cameras');
|
|
21
|
+
|
|
22
|
+
await queryInterface.dropTable('equipment');
|
|
23
|
+
|
|
24
|
+
await queryInterface.dropTable('equipment_user');
|
|
25
|
+
|
|
26
|
+
await queryInterface.dropTable('equipment_vehicle');
|
|
27
|
+
|
|
28
|
+
await queryInterface.dropTable('group_camera');
|
|
29
|
+
|
|
30
|
+
await queryInterface.dropTable('group_permissions');
|
|
31
|
+
|
|
32
|
+
await queryInterface.dropTable('group_user');
|
|
33
|
+
|
|
34
|
+
await queryInterface.dropTable('groups');
|
|
35
|
+
|
|
36
|
+
await queryInterface.dropTable('installation_companies');
|
|
37
|
+
|
|
38
|
+
await queryInterface.dropTable('occurrence_reports');
|
|
39
|
+
|
|
40
|
+
await queryInterface.dropTable('occurrence_types');
|
|
41
|
+
|
|
42
|
+
await queryInterface.dropTable('occurrence_vehicles');
|
|
43
|
+
|
|
44
|
+
await queryInterface.dropTable('occurrences');
|
|
45
|
+
|
|
46
|
+
await queryInterface.dropTable('password_resets');
|
|
47
|
+
|
|
48
|
+
await queryInterface.dropTable('permission_level_user');
|
|
49
|
+
|
|
50
|
+
await queryInterface.dropTable('permission_levels');
|
|
51
|
+
|
|
52
|
+
await queryInterface.dropTable('permissions');
|
|
53
|
+
|
|
54
|
+
await queryInterface.dropTable('roles');
|
|
55
|
+
|
|
56
|
+
await queryInterface.dropTable('tabelo');
|
|
57
|
+
|
|
58
|
+
await queryInterface.dropTable('tags');
|
|
59
|
+
|
|
60
|
+
await queryInterface.dropTable('tokens');
|
|
61
|
+
|
|
62
|
+
await queryInterface.dropTable('users');
|
|
63
|
+
|
|
64
|
+
await queryInterface.dropTable('vehicles');
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
},
|
|
68
|
+
|
|
69
|
+
async down(queryInterface: QueryInterface) {
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
await queryInterface.createTable('vehicles', {});
|
|
73
|
+
|
|
74
|
+
await queryInterface.createTable('users', {});
|
|
75
|
+
|
|
76
|
+
await queryInterface.createTable('tokens', {});
|
|
77
|
+
|
|
78
|
+
await queryInterface.createTable('tags', {});
|
|
79
|
+
|
|
80
|
+
await queryInterface.createTable('tabelo', {});
|
|
81
|
+
|
|
82
|
+
await queryInterface.createTable('roles', {});
|
|
83
|
+
|
|
84
|
+
await queryInterface.createTable('permissions', {});
|
|
85
|
+
|
|
86
|
+
await queryInterface.createTable('permission_levels', {});
|
|
87
|
+
|
|
88
|
+
await queryInterface.createTable('permission_level_user', {});
|
|
89
|
+
|
|
90
|
+
await queryInterface.createTable('password_resets', {});
|
|
91
|
+
|
|
92
|
+
await queryInterface.createTable('occurrences', {});
|
|
93
|
+
|
|
94
|
+
await queryInterface.createTable('occurrence_vehicles', {});
|
|
95
|
+
|
|
96
|
+
await queryInterface.createTable('occurrence_types', {});
|
|
97
|
+
|
|
98
|
+
await queryInterface.createTable('occurrence_reports', {});
|
|
99
|
+
|
|
100
|
+
await queryInterface.createTable('installation_companies', {});
|
|
101
|
+
|
|
102
|
+
await queryInterface.createTable('groups', {});
|
|
103
|
+
|
|
104
|
+
await queryInterface.createTable('group_user', {});
|
|
105
|
+
|
|
106
|
+
await queryInterface.createTable('group_permissions', {});
|
|
107
|
+
|
|
108
|
+
await queryInterface.createTable('group_camera', {});
|
|
109
|
+
|
|
110
|
+
await queryInterface.createTable('equipment_vehicle', {});
|
|
111
|
+
|
|
112
|
+
await queryInterface.createTable('equipment_user', {});
|
|
113
|
+
|
|
114
|
+
await queryInterface.createTable('equipment', {});
|
|
115
|
+
|
|
116
|
+
await queryInterface.createTable('dashboard_cameras', {});
|
|
117
|
+
|
|
118
|
+
await queryInterface.createTable('dashboard', {});
|
|
119
|
+
|
|
120
|
+
await queryInterface.createTable('configuration', {});
|
|
121
|
+
|
|
122
|
+
await queryInterface.createTable('cameras_metadata', {});
|
|
123
|
+
|
|
124
|
+
await queryInterface.createTable('cameras', {});
|
|
125
|
+
|
|
126
|
+
await queryInterface.createTable('camera_tags', {});
|
|
127
|
+
|
|
128
|
+
await queryInterface.createTable('acting_regions', {});
|
|
129
|
+
|
|
130
|
+
await queryInterface.createTable('acting_bodies', {});
|
|
131
|
+
|
|
132
|
+
}
|
|
133
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { QueryInterface, DataTypes } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('db_version', {
|
|
7
|
+
id: {
|
|
8
|
+
type: DataTypes.INTEGER,
|
|
9
|
+
primaryKey: true,
|
|
10
|
+
autoIncrement: true,
|
|
11
|
+
},
|
|
12
|
+
version: {
|
|
13
|
+
type: DataTypes.STRING,
|
|
14
|
+
allowNull: false,
|
|
15
|
+
field: 'version'
|
|
16
|
+
},
|
|
17
|
+
createdAt: DataTypes.DATE,
|
|
18
|
+
updatedAt: DataTypes.DATE,
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
},
|
|
23
|
+
|
|
24
|
+
async down(queryInterface: QueryInterface) {
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
await queryInterface.dropTable('db_version');
|
|
28
|
+
|
|
29
|
+
}
|
|
30
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { QueryInterface } from 'sequelize';
|
|
2
|
+
|
|
3
|
+
export const migration: Migration = {
|
|
4
|
+
async up(queryInterface: QueryInterface) {
|
|
5
|
+
|
|
6
|
+
await queryInterface.createTable('gina_version', {});
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
},
|
|
10
|
+
|
|
11
|
+
async down(queryInterface: QueryInterface) {
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
await queryInterface.dropTable('gina_version');
|
|
15
|
+
|
|
16
|
+
}
|
|
17
|
+
};
|
package/package.json
CHANGED
package/tsconfig.json
DELETED
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
/* Visit https://aka.ms/tsconfig to read more about this file */
|
|
4
|
-
/* Projects */
|
|
5
|
-
// "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */
|
|
6
|
-
// "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */
|
|
7
|
-
// "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */
|
|
8
|
-
// "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */
|
|
9
|
-
// "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */
|
|
10
|
-
// "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
|
|
11
|
-
/* Language and Environment */
|
|
12
|
-
"target": "ES2021", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */
|
|
13
|
-
"lib": [
|
|
14
|
-
"ES2021",
|
|
15
|
-
"esnext.asynciterable"
|
|
16
|
-
], /* Specify a set of bundled library declaration files that describe the target runtime environment. */
|
|
17
|
-
// "jsx": "preserve", /* Specify what JSX code is generated. */
|
|
18
|
-
"experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */
|
|
19
|
-
"emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */
|
|
20
|
-
// "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */
|
|
21
|
-
// "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */
|
|
22
|
-
// "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */
|
|
23
|
-
// "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */
|
|
24
|
-
// "noLib": true, /* Disable including any library files, including the default lib.d.ts. */
|
|
25
|
-
// "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
|
|
26
|
-
// "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */
|
|
27
|
-
/* Modules */
|
|
28
|
-
"module": "commonjs", /* Specify what module code is generated. */
|
|
29
|
-
// "rootDir": "./", /* Specify the root folder within your source files. */
|
|
30
|
-
"moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */
|
|
31
|
-
// "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */
|
|
32
|
-
// "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */
|
|
33
|
-
// "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */
|
|
34
|
-
"pretty": true,
|
|
35
|
-
"typeRoots": [
|
|
36
|
-
"./node_modules/@types"
|
|
37
|
-
], /* Specify multiple folders that act like './node_modules/@types'. */
|
|
38
|
-
// "types": [], /* Specify type package names to be included without being referenced in a source file. */
|
|
39
|
-
// "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
|
|
40
|
-
// "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */
|
|
41
|
-
"resolveJsonModule": true, /* Enable importing .json files. */
|
|
42
|
-
// "noResolve": true, /* Disallow 'import's, 'require's or '<reference>'s from expanding the number of files TypeScript should add to a project. */
|
|
43
|
-
/* JavaScript Support */
|
|
44
|
-
"allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */
|
|
45
|
-
// "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */
|
|
46
|
-
// "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */
|
|
47
|
-
/* Emit */
|
|
48
|
-
"declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */
|
|
49
|
-
// "declarationMap": true, /* Create sourcemaps for d.ts files. */
|
|
50
|
-
// "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */
|
|
51
|
-
"sourceMap": true, /* Create source map files for emitted JavaScript files. */
|
|
52
|
-
// "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */
|
|
53
|
-
"outDir": "./dist", /* Specify an output folder for all emitted files. */
|
|
54
|
-
// "removeComments": true, /* Disable emitting comments. */
|
|
55
|
-
"noEmit": false, /* Disable emitting files from a compilation. */
|
|
56
|
-
// "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */
|
|
57
|
-
// "importsNotUsedAsValues": "remove", /* Specify emit/checking behavior for imports that are only used for types. */
|
|
58
|
-
// "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */
|
|
59
|
-
// "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */
|
|
60
|
-
// "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
|
|
61
|
-
// "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */
|
|
62
|
-
// "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */
|
|
63
|
-
// "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */
|
|
64
|
-
// "newLine": "crlf", /* Set the newline character for emitting files. */
|
|
65
|
-
// "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */
|
|
66
|
-
// "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */
|
|
67
|
-
// "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */
|
|
68
|
-
// "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */
|
|
69
|
-
// "declarationDir": "./", /* Specify the output directory for generated declaration files. */
|
|
70
|
-
// "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */
|
|
71
|
-
/* Interop Constraints */
|
|
72
|
-
// "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */
|
|
73
|
-
"allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */
|
|
74
|
-
"esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */
|
|
75
|
-
// "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */
|
|
76
|
-
"forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */
|
|
77
|
-
/* Type Checking */
|
|
78
|
-
"strict": true, /* Enable all strict type-checking options. */
|
|
79
|
-
"noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied 'any' type. */
|
|
80
|
-
"strictNullChecks": true, /* When type checking, take into account 'null' and 'undefined'. */
|
|
81
|
-
// "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */
|
|
82
|
-
// "strictBindCallApply": true, /* Check that the arguments for 'bind', 'call', and 'apply' methods match the original function. */
|
|
83
|
-
"strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */
|
|
84
|
-
"noImplicitThis": true, /* Enable error reporting when 'this' is given the type 'any'. */
|
|
85
|
-
"useUnknownInCatchVariables": true, /* Default catch clause variables as 'unknown' instead of 'any'. */
|
|
86
|
-
// "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */
|
|
87
|
-
// "noUnusedLocals": true, /* Enable error reporting when local variables aren't read. */
|
|
88
|
-
// "noUnusedParameters": true, /* Raise an error when a function parameter isn't read. */
|
|
89
|
-
// "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */
|
|
90
|
-
// "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */
|
|
91
|
-
// "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */
|
|
92
|
-
// "noUncheckedIndexedAccess": true, /* Add 'undefined' to a type when accessed using an index. */
|
|
93
|
-
// "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */
|
|
94
|
-
// "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type. */
|
|
95
|
-
// "allowUnusedLabels": true, /* Disable error reporting for unused labels. */
|
|
96
|
-
// "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */
|
|
97
|
-
/* Completeness */
|
|
98
|
-
// "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
|
|
99
|
-
"skipLibCheck": true /* Skip type checking all .d.ts files. */,
|
|
100
|
-
"inlineSources": true,
|
|
101
|
-
// Set `sourceRoot` to "/" to strip the build path prefix
|
|
102
|
-
// from generated source code references.
|
|
103
|
-
// This improves issue grouping in Sentry.
|
|
104
|
-
"sourceRoot": "/"
|
|
105
|
-
},
|
|
106
|
-
"include": [
|
|
107
|
-
"./lib/**/*"
|
|
108
|
-
],
|
|
109
|
-
"exclude": [
|
|
110
|
-
"node_modules",
|
|
111
|
-
"gina"
|
|
112
|
-
]
|
|
113
|
-
}
|