@kipicore/dbcore 1.1.131 → 1.1.133
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/constants/app.d.ts +2 -1
- package/dist/constants/app.js +1 -0
- package/dist/constants/errorMessages.d.ts +2 -1
- package/dist/constants/errorMessages.js +1 -0
- package/dist/db/psql/migrations/20251125045339-income_expense_model.js +4 -4
- package/dist/db/psql/migrations/20251209061902-add-acl_id_feeTypeModel.d.ts +2 -0
- package/dist/db/psql/migrations/20251209061902-add-acl_id_feeTypeModel.js +21 -0
- package/dist/db/psql/migrations/20251210100917-id_add_typemanagement.d.ts +2 -0
- package/dist/db/psql/migrations/20251210100917-id_add_typemanagement.js +33 -0
- package/dist/db/psql/migrations/20251210101254-id_add_bankAccDetails.d.ts +2 -0
- package/dist/db/psql/migrations/20251210101254-id_add_bankAccDetails.js +22 -0
- package/dist/db/psql/migrations/20251210102112-id_add_accHasReceiptDetails.d.ts +2 -0
- package/dist/db/psql/migrations/20251210102112-id_add_accHasReceiptDetails.js +33 -0
- package/dist/db/psql/migrations/20251210102601-id_add_masterLeave.d.ts +2 -0
- package/dist/db/psql/migrations/20251210102601-id_add_masterLeave.js +22 -0
- package/dist/db/psql/migrations/20251210103020-id_add_slot.d.ts +2 -0
- package/dist/db/psql/migrations/20251210103020-id_add_slot.js +22 -0
- package/dist/db/psql/migrations/20251210103724-id_add_classRoom.d.ts +2 -0
- package/dist/db/psql/migrations/20251210103724-id_add_classRoom.js +22 -0
- package/dist/db/psql/migrations/20251210104353-id_add_floorManagement.d.ts +2 -0
- package/dist/db/psql/migrations/20251210104353-id_add_floorManagement.js +33 -0
- package/dist/db/psql/migrations/20251210105807-id_add_batch.d.ts +2 -0
- package/dist/db/psql/migrations/20251210105807-id_add_batch.js +22 -0
- package/dist/db/psql/migrations/20251210110340-id_add_workingshift.d.ts +2 -0
- package/dist/db/psql/migrations/20251210110340-id_add_workingshift.js +22 -0
- package/dist/db/psql/migrations/20251210110912-id_add_greetings.d.ts +2 -0
- package/dist/db/psql/migrations/20251210110912-id_add_greetings.js +22 -0
- package/dist/db/psql/migrations/20251210113530-id_add_role.d.ts +2 -0
- package/dist/db/psql/migrations/20251210113530-id_add_role.js +33 -0
- package/dist/db/psql/migrations/20251210122210-id_add_userHasRole.d.ts +2 -0
- package/dist/db/psql/migrations/20251210122210-id_add_userHasRole.js +33 -0
- package/dist/db/psql/migrations/20251210124921-id_add_subjectHFee.d.ts +2 -0
- package/dist/db/psql/migrations/20251210124921-id_add_subjectHFee.js +22 -0
- package/dist/db/psql/migrations/20251210130015-id_add_workingDay.d.ts +2 -0
- package/dist/db/psql/migrations/20251210130015-id_add_workingDay.js +22 -0
- package/dist/db/psql/migrations/20251210132959-id_add_reminderSetting.d.ts +2 -0
- package/dist/db/psql/migrations/20251210132959-id_add_reminderSetting.js +22 -0
- package/dist/interfaces/accountHasReceiptDetailsInterface.d.ts +2 -0
- package/dist/interfaces/bankAccountDetailsInterface.d.ts +1 -0
- package/dist/interfaces/batchInterface.d.ts +1 -0
- package/dist/interfaces/classRoomInterface.d.ts +1 -0
- package/dist/interfaces/feeReminderSettingInterface.d.ts +1 -0
- package/dist/interfaces/feeReminderTypeInterface.d.ts +1 -0
- package/dist/interfaces/floorManagementInterface.d.ts +2 -0
- package/dist/interfaces/greetingsInterface.d.ts +1 -0
- package/dist/interfaces/incomeExpenseInterface.d.ts +1 -1
- package/dist/interfaces/masterLeaveInterface.d.ts +1 -0
- package/dist/interfaces/roleInterface.d.ts +2 -0
- package/dist/interfaces/slotInterface.d.ts +1 -0
- package/dist/interfaces/subjectHasFeeInterface.d.ts +1 -0
- package/dist/interfaces/subjectIndexInterface.d.ts +2 -0
- package/dist/interfaces/typeManagementInterface.d.ts +2 -0
- package/dist/interfaces/userHasRoleInterface.d.ts +2 -0
- package/dist/interfaces/userInstituteMetaInterface.d.ts +2 -0
- package/dist/interfaces/workingDayInterface.d.ts +1 -0
- package/dist/interfaces/workingShiftInterface.d.ts +1 -0
- package/dist/models/mongodb/feeReminderTypeModel.js +4 -0
- package/dist/models/mongodb/subjectIndexModel.js +8 -0
- package/dist/models/mongodb/userInstituteMetaModel.js +8 -0
- package/dist/models/psql/accountHasReceiptDetailsModel.d.ts +2 -0
- package/dist/models/psql/accountHasReceiptDetailsModel.js +27 -1
- package/dist/models/psql/bankAccountDetailsModel.d.ts +1 -0
- package/dist/models/psql/bankAccountDetailsModel.js +13 -0
- package/dist/models/psql/batchModel.d.ts +1 -0
- package/dist/models/psql/batchModel.js +13 -0
- package/dist/models/psql/classRoomModel.d.ts +1 -0
- package/dist/models/psql/classRoomModel.js +13 -0
- package/dist/models/psql/feeHistoryModel.js +1 -0
- package/dist/models/psql/feeReminderSettingModel.d.ts +1 -0
- package/dist/models/psql/feeReminderSettingModel.js +12 -0
- package/dist/models/psql/floorManagementModel.d.ts +2 -0
- package/dist/models/psql/floorManagementModel.js +27 -1
- package/dist/models/psql/greetingsModel.d.ts +1 -0
- package/dist/models/psql/greetingsModel.js +13 -0
- package/dist/models/psql/incomeExpenseModel.d.ts +1 -1
- package/dist/models/psql/incomeExpenseModel.js +6 -6
- package/dist/models/psql/masterLeaveModel.d.ts +1 -0
- package/dist/models/psql/masterLeaveModel.js +13 -0
- package/dist/models/psql/roleModel.d.ts +2 -0
- package/dist/models/psql/roleModel.js +27 -1
- package/dist/models/psql/slotModel.d.ts +1 -0
- package/dist/models/psql/slotModel.js +13 -0
- package/dist/models/psql/subjectHasFeeModel.d.ts +2 -1
- package/dist/models/psql/subjectHasFeeModel.js +14 -1
- package/dist/models/psql/typeManagementModel.d.ts +2 -0
- package/dist/models/psql/typeManagementModel.js +39 -1
- package/dist/models/psql/userHasRoleModel.d.ts +2 -0
- package/dist/models/psql/userHasRoleModel.js +27 -1
- package/dist/models/psql/workingDayModel.d.ts +1 -0
- package/dist/models/psql/workingDayModel.js +13 -0
- package/dist/models/psql/workingShiftModel.d.ts +1 -0
- package/dist/models/psql/workingShiftModel.js +13 -0
- package/package.json +1 -1
package/dist/constants/app.d.ts
CHANGED
|
@@ -257,7 +257,8 @@ export declare enum USER_INSTITUTE_META_STATUS {
|
|
|
257
257
|
REJECTED = "REJECTED",
|
|
258
258
|
LEFT = "LEFT",
|
|
259
259
|
BLOCKED = "BLOCKED",
|
|
260
|
-
SUBSCRIPTION_PLAN_EXPIRED = "SUBSCRIPTION_PLAN_EXPIRED"
|
|
260
|
+
SUBSCRIPTION_PLAN_EXPIRED = "SUBSCRIPTION_PLAN_EXPIRED",
|
|
261
|
+
DRAFT = "DRAFT"
|
|
261
262
|
}
|
|
262
263
|
export declare enum EMPLOYMENT_TYPE {
|
|
263
264
|
PART_TIME = "PART_TIME",
|
package/dist/constants/app.js
CHANGED
|
@@ -318,6 +318,7 @@ var USER_INSTITUTE_META_STATUS;
|
|
|
318
318
|
USER_INSTITUTE_META_STATUS["LEFT"] = "LEFT";
|
|
319
319
|
USER_INSTITUTE_META_STATUS["BLOCKED"] = "BLOCKED";
|
|
320
320
|
USER_INSTITUTE_META_STATUS["SUBSCRIPTION_PLAN_EXPIRED"] = "SUBSCRIPTION_PLAN_EXPIRED";
|
|
321
|
+
USER_INSTITUTE_META_STATUS["DRAFT"] = "DRAFT";
|
|
321
322
|
})(USER_INSTITUTE_META_STATUS || (exports.USER_INSTITUTE_META_STATUS = USER_INSTITUTE_META_STATUS = {}));
|
|
322
323
|
var EMPLOYMENT_TYPE;
|
|
323
324
|
(function (EMPLOYMENT_TYPE) {
|
|
@@ -504,7 +504,8 @@ export declare enum USER_INSTITUTE_META_ERROR_MESSAGES {
|
|
|
504
504
|
CAN_NOT_UPDATE_BATCH_FOUND = "Cannot update institute data: dependency found between removed data and assigned batch",
|
|
505
505
|
CAN_NOT_UPDATE_LECTURE_FOUND = "Institute update failed: removed data is linked to an existing lectures",
|
|
506
506
|
USER_ALREADY_FIL_FROM = "User already filUp form",
|
|
507
|
-
CAN_NOT_UPDATE_ENTITY_FOUND = "Institute update failed: removed data is linked to an existing group"
|
|
507
|
+
CAN_NOT_UPDATE_ENTITY_FOUND = "Institute update failed: removed data is linked to an existing group",
|
|
508
|
+
CAN_NOT_LEFT = "User cannot be removed as they hold certain responsibilities."
|
|
508
509
|
}
|
|
509
510
|
export declare enum PARENTS_ERROR_MESSAGES {
|
|
510
511
|
CREATE_FAIL = "Unable to save parents data!",
|
|
@@ -553,6 +553,7 @@ var USER_INSTITUTE_META_ERROR_MESSAGES;
|
|
|
553
553
|
USER_INSTITUTE_META_ERROR_MESSAGES["CAN_NOT_UPDATE_LECTURE_FOUND"] = "Institute update failed: removed data is linked to an existing lectures";
|
|
554
554
|
USER_INSTITUTE_META_ERROR_MESSAGES["USER_ALREADY_FIL_FROM"] = "User already filUp form";
|
|
555
555
|
USER_INSTITUTE_META_ERROR_MESSAGES["CAN_NOT_UPDATE_ENTITY_FOUND"] = "Institute update failed: removed data is linked to an existing group";
|
|
556
|
+
USER_INSTITUTE_META_ERROR_MESSAGES["CAN_NOT_LEFT"] = "User cannot be removed as they hold certain responsibilities.";
|
|
556
557
|
})(USER_INSTITUTE_META_ERROR_MESSAGES || (exports.USER_INSTITUTE_META_ERROR_MESSAGES = USER_INSTITUTE_META_ERROR_MESSAGES = {}));
|
|
557
558
|
var PARENTS_ERROR_MESSAGES;
|
|
558
559
|
(function (PARENTS_ERROR_MESSAGES) {
|
|
@@ -18,9 +18,9 @@ const up = async (queryInterface, Sequelize) => {
|
|
|
18
18
|
field: 'institute_id',
|
|
19
19
|
allowNull: true,
|
|
20
20
|
},
|
|
21
|
-
|
|
21
|
+
academicCalendarId: {
|
|
22
22
|
type: Sequelize.UUID,
|
|
23
|
-
field: '
|
|
23
|
+
field: 'academic_calendar_id',
|
|
24
24
|
allowNull: true,
|
|
25
25
|
},
|
|
26
26
|
type: {
|
|
@@ -85,9 +85,9 @@ const up = async (queryInterface, Sequelize) => {
|
|
|
85
85
|
field: 'institute_id',
|
|
86
86
|
allowNull: true,
|
|
87
87
|
},
|
|
88
|
-
|
|
88
|
+
academicCalendarId: {
|
|
89
89
|
type: Sequelize.UUID,
|
|
90
|
-
field: '
|
|
90
|
+
field: 'academic_calendar_id',
|
|
91
91
|
allowNull: true,
|
|
92
92
|
},
|
|
93
93
|
type: {
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('fee_type');
|
|
4
|
+
if (!table.academic_calendar_id) {
|
|
5
|
+
await queryInterface.addColumn('fee_type', 'academic_calendar_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
allowNull: true,
|
|
8
|
+
field: 'academic_calendar_id',
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
const down = async (queryInterface, Sequelize) => {
|
|
13
|
+
const table = await queryInterface.describeTable('fee_type');
|
|
14
|
+
if (table.academic_calendar_id) {
|
|
15
|
+
await queryInterface.removeColumn('fee_type', 'academic_calendar_id');
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
module.exports = {
|
|
19
|
+
up,
|
|
20
|
+
down,
|
|
21
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('type_management');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('type_management', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
if (!table.academic_calendar_id) {
|
|
13
|
+
await queryInterface.addColumn('type_management', 'academic_calendar_id', {
|
|
14
|
+
type: Sequelize.UUID,
|
|
15
|
+
defaultValue: null,
|
|
16
|
+
allowNull: true,
|
|
17
|
+
field: 'academic_calendar_id',
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const down = async (queryInterface, Sequelize) => {
|
|
22
|
+
const table = await queryInterface.describeTable('type_management');
|
|
23
|
+
if (table.old_id) {
|
|
24
|
+
await queryInterface.removeColumn('type_management', 'old_id');
|
|
25
|
+
}
|
|
26
|
+
if (table.academic_calendar_id) {
|
|
27
|
+
await queryInterface.removeColumn('type_management', 'academic_calendar_id');
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
module.exports = {
|
|
31
|
+
up,
|
|
32
|
+
down,
|
|
33
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('bank_account_details');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('bank_account_details', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('bank_account_details');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('bank_account_details', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('account_has_receipt_details');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('account_has_receipt_details', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
if (!table.academic_calendar_id) {
|
|
13
|
+
await queryInterface.addColumn('account_has_receipt_details', 'academic_calendar_id', {
|
|
14
|
+
type: Sequelize.UUID,
|
|
15
|
+
defaultValue: null,
|
|
16
|
+
allowNull: true,
|
|
17
|
+
field: 'academic_calendar_id',
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const down = async (queryInterface, Sequelize) => {
|
|
22
|
+
const table = await queryInterface.describeTable('account_has_receipt_details');
|
|
23
|
+
if (table.old_id) {
|
|
24
|
+
await queryInterface.removeColumn('account_has_receipt_details', 'old_id');
|
|
25
|
+
}
|
|
26
|
+
if (table.academic_calendar_id) {
|
|
27
|
+
await queryInterface.removeColumn('account_has_receipt_details', 'academic_calendar_id');
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
module.exports = {
|
|
31
|
+
up,
|
|
32
|
+
down,
|
|
33
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('master_leaves');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('master_leaves', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('master_leaves');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('master_leaves', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('slots');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('slots', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('slots');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('slots', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('class_rooms');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('class_rooms', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('class_rooms');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('class_rooms', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('floor_management');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('floor_management', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
if (!table.academic_calendar_id) {
|
|
13
|
+
await queryInterface.addColumn('floor_management', 'academic_calendar_id', {
|
|
14
|
+
type: Sequelize.UUID,
|
|
15
|
+
defaultValue: null,
|
|
16
|
+
allowNull: true,
|
|
17
|
+
field: 'academic_calendar_id',
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const down = async (queryInterface, Sequelize) => {
|
|
22
|
+
const table = await queryInterface.describeTable('floor_management');
|
|
23
|
+
if (table.old_id) {
|
|
24
|
+
await queryInterface.removeColumn('floor_management', 'old_id');
|
|
25
|
+
}
|
|
26
|
+
if (table.academic_calendar_id) {
|
|
27
|
+
await queryInterface.removeColumn('floor_management', 'academic_calendar_id');
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
module.exports = {
|
|
31
|
+
up,
|
|
32
|
+
down,
|
|
33
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('batches');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('batches', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('batches');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('batches', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('working_shift_days');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('working_shift_days', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('working_shift_days');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('working_shift_days', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('greeting');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('greeting', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('greeting');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('greeting', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('roles');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('roles', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
if (!table.academic_calender_id) {
|
|
13
|
+
await queryInterface.addColumn('roles', 'academic_calender_id', {
|
|
14
|
+
type: Sequelize.UUID,
|
|
15
|
+
defaultValue: null,
|
|
16
|
+
allowNull: true,
|
|
17
|
+
field: 'academic_calender_id',
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const down = async (queryInterface, Sequelize) => {
|
|
22
|
+
const table = await queryInterface.describeTable('roles');
|
|
23
|
+
if (table.old_id) {
|
|
24
|
+
await queryInterface.removeColumn('roles', 'old_id');
|
|
25
|
+
}
|
|
26
|
+
if (table.academic_calender_id) {
|
|
27
|
+
await queryInterface.removeColumn('roles', 'academic_calender_id');
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
module.exports = {
|
|
31
|
+
up,
|
|
32
|
+
down,
|
|
33
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('user_has_roles');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('user_has_roles', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
if (!table.academic_calender_id) {
|
|
13
|
+
await queryInterface.addColumn('user_has_roles', 'academic_calender_id', {
|
|
14
|
+
type: Sequelize.UUID,
|
|
15
|
+
defaultValue: null,
|
|
16
|
+
allowNull: true,
|
|
17
|
+
field: 'academic_calender_id',
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const down = async (queryInterface, Sequelize) => {
|
|
22
|
+
const table = await queryInterface.describeTable('user_has_roles');
|
|
23
|
+
if (table.old_id) {
|
|
24
|
+
await queryInterface.removeColumn('user_has_roles', 'old_id');
|
|
25
|
+
}
|
|
26
|
+
if (table.academic_calender_id) {
|
|
27
|
+
await queryInterface.removeColumn('user_has_roles', 'academic_calender_id');
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
module.exports = {
|
|
31
|
+
up,
|
|
32
|
+
down,
|
|
33
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('subject_has_fee');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('subject_has_fee', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('subject_has_fee');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('subject_has_fee', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('working_days');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('working_days', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('working_days');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('working_days', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const up = async (queryInterface, Sequelize) => {
|
|
3
|
+
const table = await queryInterface.describeTable('fee_reminder_settings');
|
|
4
|
+
if (!table.old_id) {
|
|
5
|
+
await queryInterface.addColumn('fee_reminder_settings', 'old_id', {
|
|
6
|
+
type: Sequelize.UUID,
|
|
7
|
+
defaultValue: null,
|
|
8
|
+
allowNull: true,
|
|
9
|
+
field: 'old_id',
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const down = async (queryInterface, Sequelize) => {
|
|
14
|
+
const table = await queryInterface.describeTable('fee_reminder_settings');
|
|
15
|
+
if (table.old_id) {
|
|
16
|
+
await queryInterface.removeColumn('fee_reminder_settings', 'old_id');
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
module.exports = {
|
|
20
|
+
up,
|
|
21
|
+
down,
|
|
22
|
+
};
|
|
@@ -4,7 +4,7 @@ export interface IIncomeExpenseModelAttributes extends IDefaultAttributes {
|
|
|
4
4
|
id: string;
|
|
5
5
|
date: Date;
|
|
6
6
|
instituteId: string;
|
|
7
|
-
|
|
7
|
+
academicCalendarId: string;
|
|
8
8
|
amount: number;
|
|
9
9
|
type: INCOME_EXPENSE_TYPE;
|
|
10
10
|
source: INCOME_EXPENSE_SOURCE;
|
|
@@ -16,6 +16,8 @@ export interface IRoleAttributes extends IDefaultAttributes {
|
|
|
16
16
|
userType?: USER_TYPES;
|
|
17
17
|
appType: APP_TYPE;
|
|
18
18
|
isInstituteDefault?: boolean;
|
|
19
|
+
oldId?: string;
|
|
20
|
+
academicCalendarId?: string;
|
|
19
21
|
}
|
|
20
22
|
interface IRoleFeatureAction extends TModuleFeatureCreationAttributes {
|
|
21
23
|
actions: TFeatureActionCreationAttributes[];
|