@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.
Files changed (93) hide show
  1. package/dist/constants/app.d.ts +2 -1
  2. package/dist/constants/app.js +1 -0
  3. package/dist/constants/errorMessages.d.ts +2 -1
  4. package/dist/constants/errorMessages.js +1 -0
  5. package/dist/db/psql/migrations/20251125045339-income_expense_model.js +4 -4
  6. package/dist/db/psql/migrations/20251209061902-add-acl_id_feeTypeModel.d.ts +2 -0
  7. package/dist/db/psql/migrations/20251209061902-add-acl_id_feeTypeModel.js +21 -0
  8. package/dist/db/psql/migrations/20251210100917-id_add_typemanagement.d.ts +2 -0
  9. package/dist/db/psql/migrations/20251210100917-id_add_typemanagement.js +33 -0
  10. package/dist/db/psql/migrations/20251210101254-id_add_bankAccDetails.d.ts +2 -0
  11. package/dist/db/psql/migrations/20251210101254-id_add_bankAccDetails.js +22 -0
  12. package/dist/db/psql/migrations/20251210102112-id_add_accHasReceiptDetails.d.ts +2 -0
  13. package/dist/db/psql/migrations/20251210102112-id_add_accHasReceiptDetails.js +33 -0
  14. package/dist/db/psql/migrations/20251210102601-id_add_masterLeave.d.ts +2 -0
  15. package/dist/db/psql/migrations/20251210102601-id_add_masterLeave.js +22 -0
  16. package/dist/db/psql/migrations/20251210103020-id_add_slot.d.ts +2 -0
  17. package/dist/db/psql/migrations/20251210103020-id_add_slot.js +22 -0
  18. package/dist/db/psql/migrations/20251210103724-id_add_classRoom.d.ts +2 -0
  19. package/dist/db/psql/migrations/20251210103724-id_add_classRoom.js +22 -0
  20. package/dist/db/psql/migrations/20251210104353-id_add_floorManagement.d.ts +2 -0
  21. package/dist/db/psql/migrations/20251210104353-id_add_floorManagement.js +33 -0
  22. package/dist/db/psql/migrations/20251210105807-id_add_batch.d.ts +2 -0
  23. package/dist/db/psql/migrations/20251210105807-id_add_batch.js +22 -0
  24. package/dist/db/psql/migrations/20251210110340-id_add_workingshift.d.ts +2 -0
  25. package/dist/db/psql/migrations/20251210110340-id_add_workingshift.js +22 -0
  26. package/dist/db/psql/migrations/20251210110912-id_add_greetings.d.ts +2 -0
  27. package/dist/db/psql/migrations/20251210110912-id_add_greetings.js +22 -0
  28. package/dist/db/psql/migrations/20251210113530-id_add_role.d.ts +2 -0
  29. package/dist/db/psql/migrations/20251210113530-id_add_role.js +33 -0
  30. package/dist/db/psql/migrations/20251210122210-id_add_userHasRole.d.ts +2 -0
  31. package/dist/db/psql/migrations/20251210122210-id_add_userHasRole.js +33 -0
  32. package/dist/db/psql/migrations/20251210124921-id_add_subjectHFee.d.ts +2 -0
  33. package/dist/db/psql/migrations/20251210124921-id_add_subjectHFee.js +22 -0
  34. package/dist/db/psql/migrations/20251210130015-id_add_workingDay.d.ts +2 -0
  35. package/dist/db/psql/migrations/20251210130015-id_add_workingDay.js +22 -0
  36. package/dist/db/psql/migrations/20251210132959-id_add_reminderSetting.d.ts +2 -0
  37. package/dist/db/psql/migrations/20251210132959-id_add_reminderSetting.js +22 -0
  38. package/dist/interfaces/accountHasReceiptDetailsInterface.d.ts +2 -0
  39. package/dist/interfaces/bankAccountDetailsInterface.d.ts +1 -0
  40. package/dist/interfaces/batchInterface.d.ts +1 -0
  41. package/dist/interfaces/classRoomInterface.d.ts +1 -0
  42. package/dist/interfaces/feeReminderSettingInterface.d.ts +1 -0
  43. package/dist/interfaces/feeReminderTypeInterface.d.ts +1 -0
  44. package/dist/interfaces/floorManagementInterface.d.ts +2 -0
  45. package/dist/interfaces/greetingsInterface.d.ts +1 -0
  46. package/dist/interfaces/incomeExpenseInterface.d.ts +1 -1
  47. package/dist/interfaces/masterLeaveInterface.d.ts +1 -0
  48. package/dist/interfaces/roleInterface.d.ts +2 -0
  49. package/dist/interfaces/slotInterface.d.ts +1 -0
  50. package/dist/interfaces/subjectHasFeeInterface.d.ts +1 -0
  51. package/dist/interfaces/subjectIndexInterface.d.ts +2 -0
  52. package/dist/interfaces/typeManagementInterface.d.ts +2 -0
  53. package/dist/interfaces/userHasRoleInterface.d.ts +2 -0
  54. package/dist/interfaces/userInstituteMetaInterface.d.ts +2 -0
  55. package/dist/interfaces/workingDayInterface.d.ts +1 -0
  56. package/dist/interfaces/workingShiftInterface.d.ts +1 -0
  57. package/dist/models/mongodb/feeReminderTypeModel.js +4 -0
  58. package/dist/models/mongodb/subjectIndexModel.js +8 -0
  59. package/dist/models/mongodb/userInstituteMetaModel.js +8 -0
  60. package/dist/models/psql/accountHasReceiptDetailsModel.d.ts +2 -0
  61. package/dist/models/psql/accountHasReceiptDetailsModel.js +27 -1
  62. package/dist/models/psql/bankAccountDetailsModel.d.ts +1 -0
  63. package/dist/models/psql/bankAccountDetailsModel.js +13 -0
  64. package/dist/models/psql/batchModel.d.ts +1 -0
  65. package/dist/models/psql/batchModel.js +13 -0
  66. package/dist/models/psql/classRoomModel.d.ts +1 -0
  67. package/dist/models/psql/classRoomModel.js +13 -0
  68. package/dist/models/psql/feeHistoryModel.js +1 -0
  69. package/dist/models/psql/feeReminderSettingModel.d.ts +1 -0
  70. package/dist/models/psql/feeReminderSettingModel.js +12 -0
  71. package/dist/models/psql/floorManagementModel.d.ts +2 -0
  72. package/dist/models/psql/floorManagementModel.js +27 -1
  73. package/dist/models/psql/greetingsModel.d.ts +1 -0
  74. package/dist/models/psql/greetingsModel.js +13 -0
  75. package/dist/models/psql/incomeExpenseModel.d.ts +1 -1
  76. package/dist/models/psql/incomeExpenseModel.js +6 -6
  77. package/dist/models/psql/masterLeaveModel.d.ts +1 -0
  78. package/dist/models/psql/masterLeaveModel.js +13 -0
  79. package/dist/models/psql/roleModel.d.ts +2 -0
  80. package/dist/models/psql/roleModel.js +27 -1
  81. package/dist/models/psql/slotModel.d.ts +1 -0
  82. package/dist/models/psql/slotModel.js +13 -0
  83. package/dist/models/psql/subjectHasFeeModel.d.ts +2 -1
  84. package/dist/models/psql/subjectHasFeeModel.js +14 -1
  85. package/dist/models/psql/typeManagementModel.d.ts +2 -0
  86. package/dist/models/psql/typeManagementModel.js +39 -1
  87. package/dist/models/psql/userHasRoleModel.d.ts +2 -0
  88. package/dist/models/psql/userHasRoleModel.js +27 -1
  89. package/dist/models/psql/workingDayModel.d.ts +1 -0
  90. package/dist/models/psql/workingDayModel.js +13 -0
  91. package/dist/models/psql/workingShiftModel.d.ts +1 -0
  92. package/dist/models/psql/workingShiftModel.js +13 -0
  93. package/package.json +1 -1
@@ -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",
@@ -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
- academicCalenderId: {
21
+ academicCalendarId: {
22
22
  type: Sequelize.UUID,
23
- field: 'academic_calender_id',
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
- academicCalenderId: {
88
+ academicCalendarId: {
89
89
  type: Sequelize.UUID,
90
- field: 'academic_calender_id',
90
+ field: 'academic_calendar_id',
91
91
  allowNull: true,
92
92
  },
93
93
  type: {
@@ -0,0 +1,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any, Sequelize: any): Promise<void>;
@@ -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
+ };
@@ -14,4 +14,6 @@ export interface IAccountHasReceiptDetailsInterfaceModelAttributes extends IDefa
14
14
  name: string;
15
15
  landline: string;
16
16
  instituteId: string;
17
+ oldId?: string;
18
+ academicCalendarId?: string;
17
19
  }
@@ -12,4 +12,5 @@ export interface IBankAccountDetailsInterfaceModelAttributes extends IDefaultAtt
12
12
  isDefault: BOOLEAN_STATUS;
13
13
  isSelfAccount: BOOLEAN_STATUS;
14
14
  academicCalendarId?: string;
15
+ oldId?: string;
15
16
  }
@@ -15,4 +15,5 @@ export interface IBatchModelAttributes extends IDefaultAttributes {
15
15
  status: COMMAN_STATUS;
16
16
  plannerSyncStatus?: PLANNER_SYNC_STATUS;
17
17
  academicCalendarId?: string;
18
+ oldId?: string;
18
19
  }
@@ -11,4 +11,5 @@ export interface IClassRoomModelAttributes extends IDefaultAttributes {
11
11
  floorId?: string;
12
12
  typeManagementId?: string;
13
13
  academicCalendarId?: string;
14
+ oldId?: string;
14
15
  }
@@ -7,5 +7,6 @@ export interface IFeeReminderSettingModelAttributes extends IDefaultAttributes {
7
7
  status: FEE_REMINDER_SETTING_STATUS;
8
8
  typeId: string;
9
9
  default: BOOLEAN_STATUS;
10
+ oldId?: string;
10
11
  academicCalendarId?: string;
11
12
  }
@@ -8,4 +8,5 @@ export interface IFeeReminderTypeModelAttributes extends IDefaultAttributes, Doc
8
8
  frequency: FEE_REMINDER_SETTING_FREQUENCY;
9
9
  instituteId: string;
10
10
  academicCalendarId?: string;
11
+ oldId?: string;
11
12
  }
@@ -6,4 +6,6 @@ export interface IFloorManagementModelAttributes extends IDefaultAttributes {
6
6
  floorNumber: number;
7
7
  status: COMMAN_STATUS;
8
8
  instituteId: string;
9
+ oldId?: string;
10
+ academicCalendarId?: string;
9
11
  }
@@ -10,4 +10,5 @@ export interface IGreetingsModelAttributes extends IDefaultAttributes {
10
10
  title: string;
11
11
  image: string;
12
12
  academicCalendarId: string;
13
+ oldId?: string;
13
14
  }
@@ -4,7 +4,7 @@ export interface IIncomeExpenseModelAttributes extends IDefaultAttributes {
4
4
  id: string;
5
5
  date: Date;
6
6
  instituteId: string;
7
- academicCalenderId: string;
7
+ academicCalendarId: string;
8
8
  amount: number;
9
9
  type: INCOME_EXPENSE_TYPE;
10
10
  source: INCOME_EXPENSE_SOURCE;
@@ -11,4 +11,5 @@ export interface IMasterLeaveModelAttributes extends IDefaultAttributes {
11
11
  leave: LEAVE;
12
12
  status: COMMAN_STATUS;
13
13
  academicCalendarId?: string;
14
+ oldId?: string;
14
15
  }
@@ -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[];