@kipicore/dbcore 1.1.694 → 1.1.696

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 (310) hide show
  1. package/dist/commonValidator/commandValidator.d.ts +27 -0
  2. package/dist/commonValidator/commandValidator.js +225 -0
  3. package/dist/commonValidator/index.d.ts +3 -0
  4. package/dist/commonValidator/index.js +24 -0
  5. package/dist/commonValidator/joiCommonValidator.d.ts +12 -0
  6. package/dist/commonValidator/joiCommonValidator.js +47 -0
  7. package/dist/commonValidator/joiSchemaBuilder.d.ts +6 -0
  8. package/dist/commonValidator/joiSchemaBuilder.js +70 -0
  9. package/dist/configs/env.d.ts +2 -0
  10. package/dist/configs/env.js +4 -0
  11. package/dist/configs/index.d.ts +2 -0
  12. package/dist/configs/index.js +2 -0
  13. package/dist/configs/logger.d.ts +2 -0
  14. package/dist/configs/logger.js +44 -0
  15. package/dist/configs/redisConfig.d.ts +4 -0
  16. package/dist/configs/redisConfig.js +32 -0
  17. package/dist/constants/app.d.ts +30 -58
  18. package/dist/constants/app.js +37 -70
  19. package/dist/constants/defaultModelAttributes.js +2 -1
  20. package/dist/constants/errorMessages.d.ts +20 -1
  21. package/dist/constants/errorMessages.js +22 -1
  22. package/dist/constants/successMessages.d.ts +14 -0
  23. package/dist/constants/successMessages.js +17 -1
  24. package/dist/db/psql/migrations/20260714111425-change_status_enum_to_string_in_institutes.js +46 -0
  25. package/dist/db/psql/migrations/20260714131500-add_note_to_institutes.js +20 -0
  26. package/dist/db/psql/migrations/20260715150000-create-ai-model-keys.js +156 -0
  27. package/dist/db/psql/migrations/20260717071354-add_type_to_categories.d.ts +2 -0
  28. package/dist/db/psql/migrations/20260717071354-add_type_to_categories.js +19 -0
  29. package/dist/db/psql/migrations/20260717072745-add_type_to_sub_categories.d.ts +2 -0
  30. package/dist/db/psql/migrations/20260717072745-add_type_to_sub_categories.js +19 -0
  31. package/dist/db/psql/migrations/20260717095051-add_status_to_users.d.ts +2 -0
  32. package/dist/db/psql/migrations/20260717095051-add_status_to_users.js +19 -0
  33. package/dist/db/psql/migrations/20260721000001-add-deleted-at-to-rms-maintenance-activities.d.ts +2 -0
  34. package/dist/db/psql/migrations/20260721000001-add-deleted-at-to-rms-maintenance-activities.js +12 -0
  35. package/dist/db/psql/migrations/20260721000002-change-uploaded-from-enum-to-string-in-file-storage.d.ts +2 -0
  36. package/dist/db/psql/migrations/20260721000002-change-uploaded-from-enum-to-string-in-file-storage.js +42 -0
  37. package/dist/db/psql/migrations/20260722130134-add_portfolio_theme_to_users.d.ts +2 -0
  38. package/dist/db/psql/migrations/20260722130134-add_portfolio_theme_to_users.js +22 -0
  39. package/dist/db/psql/migrations/20260727123149-add_vendorCompanyId_to_institute_ownership_histories.js +23 -0
  40. package/dist/db/psql/migrations/20260727130802-add_vendorCompanyId_to_institute_partners.d.ts +2 -0
  41. package/dist/db/psql/migrations/20260727130802-add_vendorCompanyId_to_institute_partners.js +23 -0
  42. package/dist/db/psql/migrations/20260727132312-make_instituteId_and_vendorCompanyId_optional_in_institute_partners.d.ts +2 -0
  43. package/dist/db/psql/migrations/20260727132312-make_instituteId_and_vendorCompanyId_optional_in_institute_partners.js +28 -0
  44. package/dist/db/psql/migrations/20260727132747-make_instituteId_and_vendorCompanyId_optional_in_institute_ownership_histories.d.ts +2 -0
  45. package/dist/db/psql/migrations/20260727132747-make_instituteId_and_vendorCompanyId_optional_in_institute_ownership_histories.js +25 -0
  46. package/dist/db/psql/migrations/20260729055118-institutePartners.d.ts +2 -0
  47. package/dist/db/psql/migrations/20260729055118-institutePartners.js +28 -0
  48. package/dist/db/psql/migrations/20260729055121-instituteOwnershipHistory.d.ts +2 -0
  49. package/dist/db/psql/migrations/20260729055121-instituteOwnershipHistory.js +25 -0
  50. package/dist/helpers/index.d.ts +3 -0
  51. package/dist/helpers/index.js +3 -0
  52. package/dist/helpers/sendEmail.d.ts +3 -0
  53. package/dist/helpers/sendEmail.js +117 -0
  54. package/dist/helpers/sendNotification.d.ts +4 -0
  55. package/dist/helpers/sendNotification.js +34 -0
  56. package/dist/helpers/sendSMS.d.ts +5 -0
  57. package/dist/helpers/sendSMS.js +34 -0
  58. package/dist/helpers/utils.d.ts +5 -3
  59. package/dist/helpers/utils.js +58 -31
  60. package/dist/index.d.ts +4 -0
  61. package/dist/index.js +4 -0
  62. package/dist/interfaces/aiModelKeysInterface.d.ts +15 -0
  63. package/dist/interfaces/categoriesInterface.d.ts +2 -1
  64. package/dist/interfaces/index.d.ts +1 -18
  65. package/dist/interfaces/index.js +1 -19
  66. package/dist/interfaces/instituteInterface.d.ts +1 -0
  67. package/dist/interfaces/instituteOwnershipHistoryInterface.d.ts +2 -1
  68. package/dist/interfaces/institutePartnersInterface.d.ts +2 -1
  69. package/dist/interfaces/photosGalleryInterface.d.ts +1 -3
  70. package/dist/interfaces/sendNotificationInerface.d.ts +0 -2
  71. package/dist/interfaces/subCategoriesInterface.d.ts +2 -1
  72. package/dist/interfaces/subscriptionPlanInterface.d.ts +2 -1
  73. package/dist/interfaces/testimonialInterface.d.ts +0 -1
  74. package/dist/interfaces/userInstituteMetaInterface.d.ts +1 -1
  75. package/dist/interfaces/userInterface.d.ts +3 -1
  76. package/dist/interfaces/vendorCompanyMetaInterface.d.ts +5 -2
  77. package/dist/models/mongodb/additionalDetailsModel.js +1 -1
  78. package/dist/models/mongodb/advertisementModel.js +1 -1
  79. package/dist/models/mongodb/appAnalyticsEventModel.js +1 -1
  80. package/dist/models/mongodb/appointmentHistoryModel.js +1 -1
  81. package/dist/models/mongodb/appointmentModel.js +1 -1
  82. package/dist/models/mongodb/approvalRequestModel.js +1 -1
  83. package/dist/models/mongodb/assignFileModel.js +1 -1
  84. package/dist/models/mongodb/attendanceModel.js +1 -1
  85. package/dist/models/mongodb/bDayWishModel.js +1 -1
  86. package/dist/models/mongodb/blogModel.js +1 -1
  87. package/dist/models/mongodb/campusCarnivalModel.js +1 -1
  88. package/dist/models/mongodb/canteenModel.js +1 -1
  89. package/dist/models/mongodb/careerModel.js +1 -1
  90. package/dist/models/mongodb/certificatesHistoryModel.js +1 -1
  91. package/dist/models/mongodb/certificatesManagementModel.js +1 -1
  92. package/dist/models/mongodb/columnModel.js +1 -1
  93. package/dist/models/mongodb/communityGroupMemberModel.js +1 -1
  94. package/dist/models/mongodb/communityGroupModel.js +1 -1
  95. package/dist/models/mongodb/communityMessageModel.js +1 -1
  96. package/dist/models/mongodb/competitionGroupModel.js +1 -1
  97. package/dist/models/mongodb/competitionModel.js +1 -1
  98. package/dist/models/mongodb/competitionUsersModel.js +1 -1
  99. package/dist/models/mongodb/createPollModel.js +1 -1
  100. package/dist/models/mongodb/dailyBookModel.js +1 -1
  101. package/dist/models/mongodb/dashboardManagementModel.js +1 -1
  102. package/dist/models/mongodb/educationOfficerModel.js +1 -1
  103. package/dist/models/mongodb/eventModel.js +1 -1
  104. package/dist/models/mongodb/eventTemplatesModel.js +1 -1
  105. package/dist/models/mongodb/examGroupModel.js +1 -1
  106. package/dist/models/mongodb/examHasAnswerSheetModel.js +1 -1
  107. package/dist/models/mongodb/examModel.js +1 -1
  108. package/dist/models/mongodb/feeConfigModel.js +1 -1
  109. package/dist/models/mongodb/feeReminderTypeModel.js +1 -1
  110. package/dist/models/mongodb/feeSubmissionModel.js +1 -1
  111. package/dist/models/mongodb/feedBackModel.js +1 -1
  112. package/dist/models/mongodb/fileUploadUserDetailsModel.js +1 -1
  113. package/dist/models/mongodb/finalMarkSheetModel.js +1 -1
  114. package/dist/models/mongodb/generateIdCardModel.js +1 -1
  115. package/dist/models/mongodb/grantAndDonationModel.js +1 -1
  116. package/dist/models/mongodb/holidayModel.js +1 -1
  117. package/dist/models/mongodb/index.d.ts +0 -7
  118. package/dist/models/mongodb/index.js +1 -16
  119. package/dist/models/mongodb/informationSupportModel.js +1 -1
  120. package/dist/models/mongodb/inquiryModel.js +1 -1
  121. package/dist/models/mongodb/instituteFeeModel.js +1 -1
  122. package/dist/models/mongodb/invoiceModel.js +1 -1
  123. package/dist/models/mongodb/jobApplyModel.js +1 -1
  124. package/dist/models/mongodb/kipiverseContactFormModel.js +1 -1
  125. package/dist/models/mongodb/markSheetConfigurationModel.js +1 -1
  126. package/dist/models/mongodb/modulePriceModel.js +1 -1
  127. package/dist/models/mongodb/offerAndDiscountModel.js +1 -1
  128. package/dist/models/mongodb/onlineLectureModel.js +1 -1
  129. package/dist/models/mongodb/pastYearRecordTopperModel.js +1 -1
  130. package/dist/models/mongodb/pdcChequeConfigurationModel.js +1 -1
  131. package/dist/models/mongodb/photosGalleryModel.js +2 -6
  132. package/dist/models/mongodb/plannerModel.js +1 -1
  133. package/dist/models/mongodb/pollSelectionModel.js +1 -1
  134. package/dist/models/mongodb/productMetaModel.js +10 -2
  135. package/dist/models/mongodb/replaceTeacherModel.js +1 -1
  136. package/dist/models/mongodb/rmsAmcContractModel.js +1 -1
  137. package/dist/models/mongodb/rmsAuditLogModel.js +1 -1
  138. package/dist/models/mongodb/rmsDigitalResourceAccessModel.js +1 -1
  139. package/dist/models/mongodb/rmsDigitalResourceModel.js +1 -1
  140. package/dist/models/mongodb/rmsResourceDetailsModel.d.ts +1 -7
  141. package/dist/models/mongodb/rmsResourceDetailsModel.js +1 -1
  142. package/dist/models/mongodb/roleHasPermissionModel.js +1 -1
  143. package/dist/models/mongodb/schoolFee1Model.js +1 -1
  144. package/dist/models/mongodb/seatingArrangementModel.js +1 -1
  145. package/dist/models/mongodb/sheetFieldModel.js +1 -1
  146. package/dist/models/mongodb/subjectIndexModel.js +1 -1
  147. package/dist/models/mongodb/subscriptionConfigurationModel.js +1 -1
  148. package/dist/models/mongodb/subscriptionPlanModel.js +6 -1
  149. package/dist/models/mongodb/taskManagementModel.js +1 -1
  150. package/dist/models/mongodb/themeModel.js +1 -1
  151. package/dist/models/mongodb/ticketRaiseModel.js +1 -1
  152. package/dist/models/mongodb/uniqueNumberCounterModel.js +1 -1
  153. package/dist/models/mongodb/userDetailsModel.js +1 -1
  154. package/dist/models/mongodb/userFinalResultModel.js +1 -1
  155. package/dist/models/mongodb/userInstituteMetaModel.js +1 -5
  156. package/dist/models/mongodb/userSchoolMetaModel.d.ts +1 -6
  157. package/dist/models/mongodb/userSchoolMetaModel.js +36 -3
  158. package/dist/models/mongodb/vendorCompanyMetaModel.js +16 -2
  159. package/dist/models/mongodb/videoAnalystModel.js +1 -1
  160. package/dist/models/mongodb/walletTransactionModel.js +1 -1
  161. package/dist/models/psql/SubCategoriesModel.d.ts +2 -1
  162. package/dist/models/psql/SubCategoriesModel.js +5 -0
  163. package/dist/models/psql/aiModelKeysModel.d.ts +20 -0
  164. package/dist/models/psql/aiModelKeysModel.js +70 -0
  165. package/dist/models/psql/categoriesModel.d.ts +2 -1
  166. package/dist/models/psql/categoriesModel.js +5 -0
  167. package/dist/models/psql/fileStorageModel.js +3 -4
  168. package/dist/models/psql/index.d.ts +1 -11
  169. package/dist/models/psql/index.js +4 -25
  170. package/dist/models/psql/instituteModel.d.ts +1 -0
  171. package/dist/models/psql/instituteModel.js +5 -2
  172. package/dist/models/psql/instituteOwnershipHistoryModel.d.ts +2 -1
  173. package/dist/models/psql/instituteOwnershipHistoryModel.js +8 -3
  174. package/dist/models/psql/institutePartnersModel.d.ts +2 -1
  175. package/dist/models/psql/institutePartnersModel.js +8 -3
  176. package/dist/models/psql/sendNotificationModel.d.ts +0 -1
  177. package/dist/models/psql/sendNotificationModel.js +0 -5
  178. package/dist/models/psql/testimonialModel.d.ts +0 -1
  179. package/dist/models/psql/testimonialModel.js +7 -8
  180. package/dist/models/psql/userModel.d.ts +3 -1
  181. package/dist/models/psql/userModel.js +2 -2
  182. package/dist/queues/emailQueue.d.ts +3 -0
  183. package/dist/queues/emailQueue.js +22 -0
  184. package/dist/queues/emailWorker.d.ts +3 -0
  185. package/dist/queues/emailWorker.js +33 -0
  186. package/dist/queues/index.d.ts +2 -0
  187. package/dist/queues/index.js +18 -0
  188. package/dist/types/aiModelKeysType.d.ts +3 -0
  189. package/dist/types/commonType.d.ts +29 -1
  190. package/dist/types/index.d.ts +1 -18
  191. package/dist/types/index.js +1 -19
  192. package/package.json +10 -2
  193. package/dist/db/psql/migrations/20260714095754-create-arena-models.js +0 -642
  194. package/dist/db/psql/migrations/20260720092201-replace-facility-sports-with-sport-group-data.d.ts +0 -2
  195. package/dist/db/psql/migrations/20260720092201-replace-facility-sports-with-sport-group-data.js +0 -138
  196. package/dist/db/psql/migrations/20260722143500-create-school_has_sports.js +0 -71
  197. package/dist/db/psql/migrations/20260728170500-add_sports_academy_id_to_testimonials.js +0 -21
  198. package/dist/db/psql/migrations/20260729150700-add_sports_academy_id_to_notifications.js +0 -21
  199. package/dist/interfaces/ageGroupInterface.d.ts +0 -12
  200. package/dist/interfaces/assessmentTestInterface.d.ts +0 -23
  201. package/dist/interfaces/equipmentInterface.d.ts +0 -10
  202. package/dist/interfaces/equipmentInterface.js +0 -2
  203. package/dist/interfaces/facilityMasterInterface.d.ts +0 -9
  204. package/dist/interfaces/facilityMasterInterface.js +0 -2
  205. package/dist/interfaces/schoolHasSportInterface.d.ts +0 -7
  206. package/dist/interfaces/schoolHasSportInterface.js +0 -2
  207. package/dist/interfaces/skillInterface.d.ts +0 -19
  208. package/dist/interfaces/skillInterface.js +0 -2
  209. package/dist/interfaces/sportCategoryInterface.d.ts +0 -9
  210. package/dist/interfaces/sportCategoryInterface.js +0 -2
  211. package/dist/interfaces/sportDataApproveInterface.d.ts +0 -19
  212. package/dist/interfaces/sportDataApproveInterface.js +0 -2
  213. package/dist/interfaces/sportGroupDataInterface.d.ts +0 -7
  214. package/dist/interfaces/sportGroupDataInterface.js +0 -2
  215. package/dist/interfaces/sportInfoInterface.d.ts +0 -24
  216. package/dist/interfaces/sportInfoInterface.js +0 -2
  217. package/dist/interfaces/sportInterface.d.ts +0 -10
  218. package/dist/interfaces/sportInterface.js +0 -2
  219. package/dist/interfaces/sportRoleInterface.d.ts +0 -11
  220. package/dist/interfaces/sportRoleInterface.js +0 -2
  221. package/dist/interfaces/sportSubCategoryInterface.d.ts +0 -10
  222. package/dist/interfaces/sportSubCategoryInterface.js +0 -2
  223. package/dist/interfaces/sportsAcademyInterface.d.ts +0 -39
  224. package/dist/interfaces/sportsAcademyInterface.js +0 -2
  225. package/dist/interfaces/studentSportTestInterface.d.ts +0 -20
  226. package/dist/interfaces/studentSportTestInterface.js +0 -2
  227. package/dist/interfaces/unitInterface.d.ts +0 -10
  228. package/dist/interfaces/unitInterface.js +0 -2
  229. package/dist/interfaces/userAcademyMetaInterface.d.ts +0 -17
  230. package/dist/interfaces/userAcademyMetaInterface.js +0 -2
  231. package/dist/interfaces/userAmenityInterface.d.ts +0 -24
  232. package/dist/interfaces/userAmenityInterface.js +0 -2
  233. package/dist/models/mongodb/assessmentTestModel.d.ts +0 -4
  234. package/dist/models/mongodb/assessmentTestModel.js +0 -72
  235. package/dist/models/mongodb/sportDataApproveModel.d.ts +0 -4
  236. package/dist/models/mongodb/sportDataApproveModel.js +0 -117
  237. package/dist/models/mongodb/sportInfoModel.d.ts +0 -4
  238. package/dist/models/mongodb/sportInfoModel.js +0 -72
  239. package/dist/models/mongodb/sportsAcademyModel.d.ts +0 -4
  240. package/dist/models/mongodb/sportsAcademyModel.js +0 -89
  241. package/dist/models/mongodb/studentSportTestModel.d.ts +0 -4
  242. package/dist/models/mongodb/studentSportTestModel.js +0 -68
  243. package/dist/models/mongodb/userAcademyMetaModel.d.ts +0 -4
  244. package/dist/models/mongodb/userAcademyMetaModel.js +0 -109
  245. package/dist/models/mongodb/userAmenityModel.d.ts +0 -4
  246. package/dist/models/mongodb/userAmenityModel.js +0 -73
  247. package/dist/models/psql/ageGroupModel.d.ts +0 -22
  248. package/dist/models/psql/ageGroupModel.js +0 -76
  249. package/dist/models/psql/equipmentModel.d.ts +0 -20
  250. package/dist/models/psql/equipmentModel.js +0 -57
  251. package/dist/models/psql/facilityMasterModel.d.ts +0 -18
  252. package/dist/models/psql/facilityMasterModel.js +0 -64
  253. package/dist/models/psql/schoolHasSportModel.d.ts +0 -17
  254. package/dist/models/psql/schoolHasSportModel.js +0 -76
  255. package/dist/models/psql/skillModel.d.ts +0 -25
  256. package/dist/models/psql/skillModel.js +0 -99
  257. package/dist/models/psql/sportCategoryModel.d.ts +0 -19
  258. package/dist/models/psql/sportCategoryModel.js +0 -53
  259. package/dist/models/psql/sportGroupDataModel.d.ts +0 -13
  260. package/dist/models/psql/sportGroupDataModel.js +0 -64
  261. package/dist/models/psql/sportModel.d.ts +0 -20
  262. package/dist/models/psql/sportModel.js +0 -58
  263. package/dist/models/psql/sportRoleModel.d.ts +0 -21
  264. package/dist/models/psql/sportRoleModel.js +0 -71
  265. package/dist/models/psql/sportSubCategoryModel.d.ts +0 -20
  266. package/dist/models/psql/sportSubCategoryModel.js +0 -75
  267. package/dist/models/psql/unitModel.d.ts +0 -20
  268. package/dist/models/psql/unitModel.js +0 -57
  269. package/dist/types/ageGroupType.d.ts +0 -2
  270. package/dist/types/ageGroupType.js +0 -2
  271. package/dist/types/assessmentTestType.d.ts +0 -2
  272. package/dist/types/assessmentTestType.js +0 -2
  273. package/dist/types/equipmentType.d.ts +0 -2
  274. package/dist/types/equipmentType.js +0 -2
  275. package/dist/types/facilityMasterType.d.ts +0 -3
  276. package/dist/types/facilityMasterType.js +0 -2
  277. package/dist/types/schoolHasSportType.d.ts +0 -2
  278. package/dist/types/schoolHasSportType.js +0 -2
  279. package/dist/types/skillType.d.ts +0 -2
  280. package/dist/types/skillType.js +0 -2
  281. package/dist/types/sportCategoryType.d.ts +0 -2
  282. package/dist/types/sportCategoryType.js +0 -2
  283. package/dist/types/sportDataApproveType.d.ts +0 -2
  284. package/dist/types/sportDataApproveType.js +0 -2
  285. package/dist/types/sportGroupDataType.d.ts +0 -3
  286. package/dist/types/sportGroupDataType.js +0 -2
  287. package/dist/types/sportInfoType.d.ts +0 -2
  288. package/dist/types/sportInfoType.js +0 -2
  289. package/dist/types/sportRoleType.d.ts +0 -2
  290. package/dist/types/sportRoleType.js +0 -2
  291. package/dist/types/sportSubCategoryType.d.ts +0 -2
  292. package/dist/types/sportSubCategoryType.js +0 -2
  293. package/dist/types/sportType.d.ts +0 -2
  294. package/dist/types/sportType.js +0 -2
  295. package/dist/types/sportsAcademyType.d.ts +0 -2
  296. package/dist/types/sportsAcademyType.js +0 -2
  297. package/dist/types/studentSportTestType.d.ts +0 -2
  298. package/dist/types/studentSportTestType.js +0 -2
  299. package/dist/types/unitType.d.ts +0 -2
  300. package/dist/types/unitType.js +0 -2
  301. package/dist/types/userAcademyMetaType.d.ts +0 -2
  302. package/dist/types/userAcademyMetaType.js +0 -2
  303. package/dist/types/userAmenityType.d.ts +0 -2
  304. package/dist/types/userAmenityType.js +0 -2
  305. /package/dist/db/psql/migrations/{20260714095754-create-arena-models.d.ts → 20260714111425-change_status_enum_to_string_in_institutes.d.ts} +0 -0
  306. /package/dist/db/psql/migrations/{20260722143500-create-school_has_sports.d.ts → 20260714131500-add_note_to_institutes.d.ts} +0 -0
  307. /package/dist/db/psql/migrations/{20260728170500-add_sports_academy_id_to_testimonials.d.ts → 20260715150000-create-ai-model-keys.d.ts} +0 -0
  308. /package/dist/db/psql/migrations/{20260729150700-add_sports_academy_id_to_notifications.d.ts → 20260727123149-add_vendorCompanyId_to_institute_ownership_histories.d.ts} +0 -0
  309. /package/dist/interfaces/{ageGroupInterface.js → aiModelKeysInterface.js} +0 -0
  310. /package/dist/{interfaces/assessmentTestInterface.js → types/aiModelKeysType.js} +0 -0
@@ -1,58 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SportModel = void 0;
4
- const sequelize_1 = require("sequelize");
5
- const index_1 = require("./index");
6
- class SportModel extends sequelize_1.Model {
7
- static associate(models) {
8
- const { UserModel, FileStorageModel } = models;
9
- SportModel.belongsTo(FileStorageModel, { foreignKey: 'icon', as: 'iconFile' });
10
- SportModel.belongsTo(UserModel, {
11
- foreignKey: { name: 'createdBy', allowNull: true, field: 'created_by' },
12
- as: 'createdByUser',
13
- });
14
- SportModel.belongsTo(UserModel, {
15
- foreignKey: { name: 'updatedBy', allowNull: true, field: 'updated_by' },
16
- as: 'updatedByUser',
17
- });
18
- SportModel.belongsTo(UserModel, {
19
- foreignKey: { name: 'deletedBy', allowNull: true, field: 'deleted_by' },
20
- as: 'deletedByUser',
21
- });
22
- }
23
- }
24
- exports.SportModel = SportModel;
25
- SportModel.init({
26
- id: {
27
- type: sequelize_1.DataTypes.UUID,
28
- defaultValue: sequelize_1.DataTypes.UUIDV4,
29
- allowNull: false,
30
- primaryKey: true,
31
- },
32
- name: {
33
- type: sequelize_1.DataTypes.STRING,
34
- allowNull: true,
35
- },
36
- code: {
37
- type: sequelize_1.DataTypes.STRING,
38
- allowNull: true,
39
- },
40
- description: {
41
- type: sequelize_1.DataTypes.TEXT,
42
- allowNull: true,
43
- },
44
- icon: {
45
- type: sequelize_1.DataTypes.UUID,
46
- allowNull: true,
47
- },
48
- status: {
49
- type: sequelize_1.DataTypes.STRING,
50
- allowNull: true,
51
- },
52
- }, {
53
- modelName: 'SportModel',
54
- tableName: 'sports',
55
- timestamps: true,
56
- sequelize: index_1.sequelize,
57
- });
58
- exports.default = SportModel;
@@ -1,21 +0,0 @@
1
- import { Model } from 'sequelize';
2
- import { ISportRoleModelAttributes } from '../../interfaces/sportRoleInterface';
3
- import { TSportRoleModelCreationAttributes } from '../../types/sportRoleType';
4
- import { COMMAN_STATUS } from '../../constants/app';
5
- export declare class SportRoleModel extends Model<ISportRoleModelAttributes, TSportRoleModelCreationAttributes> {
6
- id: string;
7
- sportId: string;
8
- name: string;
9
- code: string;
10
- description?: string;
11
- icon?: string;
12
- status: COMMAN_STATUS;
13
- createdBy?: string;
14
- updatedBy?: string;
15
- deletedBy?: string;
16
- readonly createdAt: Date;
17
- readonly updatedAt: Date;
18
- readonly deletedAt?: string;
19
- static associate(models: any): void;
20
- }
21
- export default SportRoleModel;
@@ -1,71 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SportRoleModel = void 0;
4
- const sequelize_1 = require("sequelize");
5
- const index_1 = require("./index");
6
- class SportRoleModel extends sequelize_1.Model {
7
- static associate(models) {
8
- const { UserModel, SportModel, FileStorageModel } = models;
9
- SportRoleModel.belongsTo(FileStorageModel, { foreignKey: 'icon', as: 'iconFile' });
10
- SportRoleModel.belongsTo(UserModel, {
11
- foreignKey: { name: 'createdBy', allowNull: true, field: 'created_by' },
12
- as: 'createdByUser',
13
- });
14
- SportRoleModel.belongsTo(UserModel, {
15
- foreignKey: { name: 'updatedBy', allowNull: true, field: 'updated_by' },
16
- as: 'updatedByUser',
17
- });
18
- SportRoleModel.belongsTo(UserModel, {
19
- foreignKey: { name: 'deletedBy', allowNull: true, field: 'deleted_by' },
20
- as: 'deletedByUser',
21
- });
22
- SportRoleModel.belongsTo(SportModel, {
23
- foreignKey: { name: 'sportId', allowNull: true, field: 'sport_id' },
24
- as: 'sportRoleSport',
25
- });
26
- SportModel.hasMany(SportRoleModel, {
27
- foreignKey: { name: 'sportId', allowNull: true, field: 'sport_id' },
28
- as: 'sportHasSportRoleList',
29
- });
30
- }
31
- }
32
- exports.SportRoleModel = SportRoleModel;
33
- SportRoleModel.init({
34
- id: {
35
- type: sequelize_1.DataTypes.UUID,
36
- defaultValue: sequelize_1.DataTypes.UUIDV4,
37
- allowNull: false,
38
- primaryKey: true,
39
- },
40
- sportId: {
41
- type: sequelize_1.DataTypes.UUID,
42
- field: 'sport_id',
43
- allowNull: true,
44
- },
45
- name: {
46
- type: sequelize_1.DataTypes.STRING,
47
- allowNull: true,
48
- },
49
- code: {
50
- type: sequelize_1.DataTypes.STRING,
51
- allowNull: true,
52
- },
53
- description: {
54
- type: sequelize_1.DataTypes.TEXT,
55
- allowNull: true,
56
- },
57
- icon: {
58
- type: sequelize_1.DataTypes.UUID,
59
- allowNull: true,
60
- },
61
- status: {
62
- type: sequelize_1.DataTypes.STRING,
63
- allowNull: true,
64
- },
65
- }, {
66
- modelName: 'SportRoleModel',
67
- tableName: 'sport_roles',
68
- timestamps: true,
69
- sequelize: index_1.sequelize,
70
- });
71
- exports.default = SportRoleModel;
@@ -1,20 +0,0 @@
1
- import { Model } from 'sequelize';
2
- import { ISportSubCategoryModelAttributes } from '../../interfaces/sportSubCategoryInterface';
3
- import { TSportSubCategoryModelCreationAttributes } from '../../types/sportSubCategoryType';
4
- import { COMMAN_STATUS } from '../../constants/app';
5
- export declare class SportSubCategoryModel extends Model<ISportSubCategoryModelAttributes, TSportSubCategoryModelCreationAttributes> {
6
- id: string;
7
- sportId: string;
8
- categoryId: string;
9
- name: string;
10
- code: string;
11
- status: COMMAN_STATUS;
12
- createdBy?: string;
13
- updatedBy?: string;
14
- deletedBy?: string;
15
- readonly createdAt: Date;
16
- readonly updatedAt: Date;
17
- readonly deletedAt?: string;
18
- static associate(models: any): void;
19
- }
20
- export default SportSubCategoryModel;
@@ -1,75 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SportSubCategoryModel = void 0;
4
- const sequelize_1 = require("sequelize");
5
- const index_1 = require("./index");
6
- class SportSubCategoryModel extends sequelize_1.Model {
7
- static associate(models) {
8
- const { UserModel, SportModel, SportCategoryModel } = models;
9
- SportSubCategoryModel.belongsTo(UserModel, {
10
- foreignKey: { name: 'createdBy', allowNull: true, field: 'created_by' },
11
- as: 'createdByUser',
12
- });
13
- SportSubCategoryModel.belongsTo(UserModel, {
14
- foreignKey: { name: 'updatedBy', allowNull: true, field: 'updated_by' },
15
- as: 'updatedByUser',
16
- });
17
- SportSubCategoryModel.belongsTo(UserModel, {
18
- foreignKey: { name: 'deletedBy', allowNull: true, field: 'deleted_by' },
19
- as: 'deletedByUser',
20
- });
21
- SportSubCategoryModel.belongsTo(SportModel, {
22
- foreignKey: { name: 'sportId', allowNull: true, field: 'sport_id' },
23
- as: 'sportSubCategorySport',
24
- });
25
- SportModel.hasMany(SportSubCategoryModel, {
26
- foreignKey: { name: 'sportId', allowNull: true, field: 'sport_id' },
27
- as: 'sportHasSportSubCategoryList',
28
- });
29
- SportSubCategoryModel.belongsTo(SportCategoryModel, {
30
- foreignKey: { name: 'categoryId', allowNull: true, field: 'category_id' },
31
- as: 'sportSubCategoryCategory',
32
- });
33
- SportCategoryModel.hasMany(SportSubCategoryModel, {
34
- foreignKey: { name: 'categoryId', allowNull: true, field: 'category_id' },
35
- as: 'categoryHasSportSubCategoryList',
36
- });
37
- }
38
- }
39
- exports.SportSubCategoryModel = SportSubCategoryModel;
40
- SportSubCategoryModel.init({
41
- id: {
42
- type: sequelize_1.DataTypes.UUID,
43
- defaultValue: sequelize_1.DataTypes.UUIDV4,
44
- allowNull: false,
45
- primaryKey: true,
46
- },
47
- sportId: {
48
- type: sequelize_1.DataTypes.UUID,
49
- field: 'sport_id',
50
- allowNull: true,
51
- },
52
- categoryId: {
53
- type: sequelize_1.DataTypes.UUID,
54
- field: 'category_id',
55
- allowNull: true,
56
- },
57
- name: {
58
- type: sequelize_1.DataTypes.STRING,
59
- allowNull: true,
60
- },
61
- code: {
62
- type: sequelize_1.DataTypes.STRING,
63
- allowNull: true,
64
- },
65
- status: {
66
- type: sequelize_1.DataTypes.STRING,
67
- allowNull: true,
68
- },
69
- }, {
70
- modelName: 'SportSubCategoryModel',
71
- tableName: 'sport_sub_categories',
72
- timestamps: true,
73
- sequelize: index_1.sequelize,
74
- });
75
- exports.default = SportSubCategoryModel;
@@ -1,20 +0,0 @@
1
- import { Model } from 'sequelize';
2
- import { IUnitModelAttributes } from '../../interfaces/unitInterface';
3
- import { TUnitModelCreationAttributes } from '../../types/unitType';
4
- import { COMMAN_STATUS } from '../../constants/app';
5
- export declare class UnitModel extends Model<IUnitModelAttributes, TUnitModelCreationAttributes> {
6
- id: string;
7
- name: string;
8
- code: string;
9
- symbol: string;
10
- description?: string;
11
- status: COMMAN_STATUS;
12
- createdBy?: string;
13
- updatedBy?: string;
14
- deletedBy?: string;
15
- readonly createdAt: Date;
16
- readonly updatedAt: Date;
17
- readonly deletedAt?: string;
18
- static associate(models: any): void;
19
- }
20
- export default UnitModel;
@@ -1,57 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UnitModel = void 0;
4
- const sequelize_1 = require("sequelize");
5
- const index_1 = require("./index");
6
- class UnitModel extends sequelize_1.Model {
7
- static associate(models) {
8
- const { UserModel } = models;
9
- UnitModel.belongsTo(UserModel, {
10
- foreignKey: { name: 'createdBy', allowNull: true, field: 'created_by' },
11
- as: 'createdByUser',
12
- });
13
- UnitModel.belongsTo(UserModel, {
14
- foreignKey: { name: 'updatedBy', allowNull: true, field: 'updated_by' },
15
- as: 'updatedByUser',
16
- });
17
- UnitModel.belongsTo(UserModel, {
18
- foreignKey: { name: 'deletedBy', allowNull: true, field: 'deleted_by' },
19
- as: 'deletedByUser',
20
- });
21
- }
22
- }
23
- exports.UnitModel = UnitModel;
24
- UnitModel.init({
25
- id: {
26
- type: sequelize_1.DataTypes.UUID,
27
- defaultValue: sequelize_1.DataTypes.UUIDV4,
28
- allowNull: false,
29
- primaryKey: true,
30
- },
31
- name: {
32
- type: sequelize_1.DataTypes.STRING,
33
- allowNull: true,
34
- },
35
- code: {
36
- type: sequelize_1.DataTypes.STRING,
37
- allowNull: true,
38
- },
39
- symbol: {
40
- type: sequelize_1.DataTypes.STRING,
41
- allowNull: true,
42
- },
43
- description: {
44
- type: sequelize_1.DataTypes.TEXT,
45
- allowNull: true,
46
- },
47
- status: {
48
- type: sequelize_1.DataTypes.STRING,
49
- allowNull: true,
50
- },
51
- }, {
52
- modelName: 'UnitModel',
53
- tableName: 'units',
54
- timestamps: true,
55
- sequelize: index_1.sequelize,
56
- });
57
- exports.default = UnitModel;
@@ -1,2 +0,0 @@
1
- import { IAgeGroupModelAttributes } from '../interfaces/ageGroupInterface';
2
- export type TAgeGroupModelCreationAttributes = Partial<IAgeGroupModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { IAssessmentTestModelAttributes } from '../interfaces/assessmentTestInterface';
2
- export type TAssessmentTestModelCreationAttributes = Partial<IAssessmentTestModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { IEquipmentModelAttributes } from '../interfaces/equipmentInterface';
2
- export type TEquipmentModelCreationAttributes = Partial<IEquipmentModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +0,0 @@
1
- import { Optional } from 'sequelize';
2
- import { IFacilityMasterModelAttributes } from '../interfaces/facilityMasterInterface';
3
- export type TFacilityMasterModelCreationAttributes = Optional<IFacilityMasterModelAttributes, 'id' | 'createdBy' | 'updatedBy' | 'deletedBy' | 'createdAt' | 'updatedAt' | 'deletedAt'>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISchoolHasSportModelAttributes } from '../interfaces/schoolHasSportInterface';
2
- export type TSchoolHasSportModelCreationAttributes = Partial<ISchoolHasSportModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISkillModelAttributes } from '../interfaces/skillInterface';
2
- export type TSkillModelCreationAttributes = Partial<ISkillModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportCategoryModelAttributes } from '../interfaces/sportCategoryInterface';
2
- export type TSportCategoryModelCreationAttributes = Partial<ISportCategoryModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportDataApproveModelAttributes } from '../interfaces/sportDataApproveInterface';
2
- export type TSportDataApproveModelCreationAttributes = Partial<ISportDataApproveModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +0,0 @@
1
- import { Optional } from "sequelize";
2
- import { ISportGroupDataModelAttributes } from "../interfaces/sportGroupDataInterface";
3
- export type TSportGroupDataModelCreationAttributes = Optional<ISportGroupDataModelAttributes, "id" | "createdAt" | "updatedAt">;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportInfoModelAttributes } from '../interfaces/sportInfoInterface';
2
- export type TSportInfoModelCreationAttributes = Partial<ISportInfoModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportRoleModelAttributes } from '../interfaces/sportRoleInterface';
2
- export type TSportRoleModelCreationAttributes = Partial<ISportRoleModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportSubCategoryModelAttributes } from '../interfaces/sportSubCategoryInterface';
2
- export type TSportSubCategoryModelCreationAttributes = Partial<ISportSubCategoryModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportModelAttributes } from '../interfaces/sportInterface';
2
- export type TSportModelCreationAttributes = Partial<ISportModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { ISportsAcademyModelAttributes } from '../interfaces/sportsAcademyInterface';
2
- export type TSportsAcademyModelCreationAttributes = Partial<ISportsAcademyModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { IStudentSportTestModelAttributes } from '../interfaces/studentSportTestInterface';
2
- export type TStudentSportTestModelCreationAttributes = Partial<IStudentSportTestModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { IUnitModelAttributes } from '../interfaces/unitInterface';
2
- export type TUnitModelCreationAttributes = Partial<IUnitModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { IUserAcademyMetaAttributes } from '../interfaces/userAcademyMetaInterface';
2
- export type TUserAcademyMetaCreationAttributes = Partial<IUserAcademyMetaAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +0,0 @@
1
- import { IUserAmenityModelAttributes } from '../interfaces/userAmenityInterface';
2
- export type TUserAmenityModelCreationAttributes = Partial<IUserAmenityModelAttributes>;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });