90dc-core 1.19.2 → 1.19.4

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 (302) hide show
  1. package/dist/lib/dbmodels/index.d.ts +3 -2
  2. package/dist/lib/dbmodels/index.d.ts.map +1 -1
  3. package/dist/lib/dbmodels/{UserProgressPhoto.d.ts → user/UserProgressPhoto.d.ts} +1 -1
  4. package/dist/lib/dbmodels/user/UserProgressPhoto.d.ts.map +1 -0
  5. package/package.json +1 -1
  6. package/dist/index.js +0 -43
  7. package/dist/index.js.map +0 -1
  8. package/dist/lib/Errors/AppError.js +0 -104
  9. package/dist/lib/Errors/AppError.js.map +0 -1
  10. package/dist/lib/Errors/Errors.js +0 -42
  11. package/dist/lib/Errors/Errors.js.map +0 -1
  12. package/dist/lib/classes/Database.js +0 -154
  13. package/dist/lib/classes/Database.js.map +0 -1
  14. package/dist/lib/classes/Redis.js +0 -63
  15. package/dist/lib/classes/Redis.js.map +0 -1
  16. package/dist/lib/clients/EmailClient.js +0 -188
  17. package/dist/lib/clients/EmailClient.js.map +0 -1
  18. package/dist/lib/clients/FirebasePushNotificationClient.js +0 -688
  19. package/dist/lib/clients/FirebasePushNotificationClient.js.map +0 -1
  20. package/dist/lib/clients/ImagesClient.js +0 -271
  21. package/dist/lib/clients/ImagesClient.js.map +0 -1
  22. package/dist/lib/clients/MailingClient.js +0 -84
  23. package/dist/lib/clients/MailingClient.js.map +0 -1
  24. package/dist/lib/clients/PushNotificationClient.js +0 -478
  25. package/dist/lib/clients/PushNotificationClient.js.map +0 -1
  26. package/dist/lib/clients/types/email.types.js +0 -3
  27. package/dist/lib/clients/types/email.types.js.map +0 -1
  28. package/dist/lib/clients/types/images.types.js +0 -3
  29. package/dist/lib/clients/types/images.types.js.map +0 -1
  30. package/dist/lib/clients/types/mailing.types.js +0 -3
  31. package/dist/lib/clients/types/mailing.types.js.map +0 -1
  32. package/dist/lib/config/ConfigValidator.js +0 -162
  33. package/dist/lib/config/ConfigValidator.js.map +0 -1
  34. package/dist/lib/controllers/BaseController.js +0 -64
  35. package/dist/lib/controllers/BaseController.js.map +0 -1
  36. package/dist/lib/db/migrations/20260330000000-create-user-progress-photos.js +0 -60
  37. package/dist/lib/db/migrations/20260330000000-create-user-progress-photos.js.map +0 -1
  38. package/dist/lib/dbmodels/UserProgressPhoto.d.ts.map +0 -1
  39. package/dist/lib/dbmodels/UserProgressPhoto.js +0 -59
  40. package/dist/lib/dbmodels/UserProgressPhoto.js.map +0 -1
  41. package/dist/lib/dbmodels/coaching/Answer.js +0 -51
  42. package/dist/lib/dbmodels/coaching/Answer.js.map +0 -1
  43. package/dist/lib/dbmodels/coaching/ClientNote.js +0 -75
  44. package/dist/lib/dbmodels/coaching/ClientNote.js.map +0 -1
  45. package/dist/lib/dbmodels/coaching/ClientTag.js +0 -45
  46. package/dist/lib/dbmodels/coaching/ClientTag.js.map +0 -1
  47. package/dist/lib/dbmodels/coaching/Question.js +0 -60
  48. package/dist/lib/dbmodels/coaching/Question.js.map +0 -1
  49. package/dist/lib/dbmodels/coaching/Questionnaire.js +0 -39
  50. package/dist/lib/dbmodels/coaching/Questionnaire.js.map +0 -1
  51. package/dist/lib/dbmodels/coaching/QuestionnaireResponse.js +0 -42
  52. package/dist/lib/dbmodels/coaching/QuestionnaireResponse.js.map +0 -1
  53. package/dist/lib/dbmodels/coaching/WeeklyCheckIn.js +0 -69
  54. package/dist/lib/dbmodels/coaching/WeeklyCheckIn.js.map +0 -1
  55. package/dist/lib/dbmodels/coaching/WeightRecord.js +0 -49
  56. package/dist/lib/dbmodels/coaching/WeightRecord.js.map +0 -1
  57. package/dist/lib/dbmodels/diet/DietDay.js +0 -50
  58. package/dist/lib/dbmodels/diet/DietDay.js.map +0 -1
  59. package/dist/lib/dbmodels/diet/DietMeal.js +0 -74
  60. package/dist/lib/dbmodels/diet/DietMeal.js.map +0 -1
  61. package/dist/lib/dbmodels/diet/DietMealCompletion.js +0 -69
  62. package/dist/lib/dbmodels/diet/DietMealCompletion.js.map +0 -1
  63. package/dist/lib/dbmodels/diet/DietMealRecipe.js +0 -67
  64. package/dist/lib/dbmodels/diet/DietMealRecipe.js.map +0 -1
  65. package/dist/lib/dbmodels/diet/DietMealRecipeIngredient.js +0 -46
  66. package/dist/lib/dbmodels/diet/DietMealRecipeIngredient.js.map +0 -1
  67. package/dist/lib/dbmodels/diet/DietProgram.js +0 -98
  68. package/dist/lib/dbmodels/diet/DietProgram.js.map +0 -1
  69. package/dist/lib/dbmodels/diet/Ingredient.js +0 -88
  70. package/dist/lib/dbmodels/diet/Ingredient.js.map +0 -1
  71. package/dist/lib/dbmodels/diet/IngredientTag.js +0 -64
  72. package/dist/lib/dbmodels/diet/IngredientTag.js.map +0 -1
  73. package/dist/lib/dbmodels/diet/IngredientTags.js +0 -29
  74. package/dist/lib/dbmodels/diet/IngredientTags.js.map +0 -1
  75. package/dist/lib/dbmodels/diet/Recipe.js +0 -173
  76. package/dist/lib/dbmodels/diet/Recipe.js.map +0 -1
  77. package/dist/lib/dbmodels/diet/RecipeIngredient.js +0 -78
  78. package/dist/lib/dbmodels/diet/RecipeIngredient.js.map +0 -1
  79. package/dist/lib/dbmodels/diet/RecipeTag.js +0 -44
  80. package/dist/lib/dbmodels/diet/RecipeTag.js.map +0 -1
  81. package/dist/lib/dbmodels/diet/RecipeTags.js +0 -24
  82. package/dist/lib/dbmodels/diet/RecipeTags.js.map +0 -1
  83. package/dist/lib/dbmodels/diet/ShoppingList.js +0 -69
  84. package/dist/lib/dbmodels/diet/ShoppingList.js.map +0 -1
  85. package/dist/lib/dbmodels/diet/ShoppingListItem.js +0 -66
  86. package/dist/lib/dbmodels/diet/ShoppingListItem.js.map +0 -1
  87. package/dist/lib/dbmodels/diet/TranslatedRecipe.js +0 -122
  88. package/dist/lib/dbmodels/diet/TranslatedRecipe.js.map +0 -1
  89. package/dist/lib/dbmodels/diet/TranslatedRecipeTag.js +0 -47
  90. package/dist/lib/dbmodels/diet/TranslatedRecipeTag.js.map +0 -1
  91. package/dist/lib/dbmodels/diet/TranslatedRecipeTags.js +0 -24
  92. package/dist/lib/dbmodels/diet/TranslatedRecipeTags.js.map +0 -1
  93. package/dist/lib/dbmodels/diet/UserDietPreferences.js +0 -85
  94. package/dist/lib/dbmodels/diet/UserDietPreferences.js.map +0 -1
  95. package/dist/lib/dbmodels/gamification/Badge.js +0 -62
  96. package/dist/lib/dbmodels/gamification/Badge.js.map +0 -1
  97. package/dist/lib/dbmodels/gamification/StreaksLog.js +0 -37
  98. package/dist/lib/dbmodels/gamification/StreaksLog.js.map +0 -1
  99. package/dist/lib/dbmodels/gamification/TranslatedBadge.js +0 -45
  100. package/dist/lib/dbmodels/gamification/TranslatedBadge.js.map +0 -1
  101. package/dist/lib/dbmodels/gamification/xpAndLeaderboards/UserRankHistory.js +0 -48
  102. package/dist/lib/dbmodels/gamification/xpAndLeaderboards/UserRankHistory.js.map +0 -1
  103. package/dist/lib/dbmodels/gamification/xpAndLeaderboards/XpEvent.js +0 -53
  104. package/dist/lib/dbmodels/gamification/xpAndLeaderboards/XpEvent.js.map +0 -1
  105. package/dist/lib/dbmodels/gamification/xpAndLeaderboards/XpTransaction.js +0 -68
  106. package/dist/lib/dbmodels/gamification/xpAndLeaderboards/XpTransaction.js.map +0 -1
  107. package/dist/lib/dbmodels/index.js +0 -287
  108. package/dist/lib/dbmodels/index.js.map +0 -1
  109. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgram.d.ts +0 -32
  110. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgram.d.ts.map +0 -1
  111. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgram.js +0 -155
  112. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgram.js.map +0 -1
  113. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgramWebContent.d.ts +0 -22
  114. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgramWebContent.d.ts.map +0 -1
  115. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgramWebContent.js +0 -108
  116. package/dist/lib/dbmodels/nonconsprogram/NonConsumableProgramWebContent.js.map +0 -1
  117. package/dist/lib/dbmodels/nonconsprogram/TranslatedConsumableProgram.d.ts +0 -20
  118. package/dist/lib/dbmodels/nonconsprogram/TranslatedConsumableProgram.d.ts.map +0 -1
  119. package/dist/lib/dbmodels/nonconsprogram/TranslatedConsumableProgram.js +0 -97
  120. package/dist/lib/dbmodels/nonconsprogram/TranslatedConsumableProgram.js.map +0 -1
  121. package/dist/lib/dbmodels/nonconsprogram/TranslatedNonConsumableProgramWebContent.d.ts +0 -22
  122. package/dist/lib/dbmodels/nonconsprogram/TranslatedNonConsumableProgramWebContent.d.ts.map +0 -1
  123. package/dist/lib/dbmodels/nonconsprogram/TranslatedNonConsumableProgramWebContent.js +0 -115
  124. package/dist/lib/dbmodels/nonconsprogram/TranslatedNonConsumableProgramWebContent.js.map +0 -1
  125. package/dist/lib/dbmodels/nonconsprogram/UserNonConsumableProgram.d.ts +0 -7
  126. package/dist/lib/dbmodels/nonconsprogram/UserNonConsumableProgram.d.ts.map +0 -1
  127. package/dist/lib/dbmodels/nonconsprogram/UserNonConsumableProgram.js +0 -41
  128. package/dist/lib/dbmodels/nonconsprogram/UserNonConsumableProgram.js.map +0 -1
  129. package/dist/lib/dbmodels/notifications/NotificationModels.js +0 -38
  130. package/dist/lib/dbmodels/notifications/NotificationModels.js.map +0 -1
  131. package/dist/lib/dbmodels/notifications/TranslatedNotification.js +0 -45
  132. package/dist/lib/dbmodels/notifications/TranslatedNotification.js.map +0 -1
  133. package/dist/lib/dbmodels/program/Challenge.d.ts +0 -13
  134. package/dist/lib/dbmodels/program/Challenge.d.ts.map +0 -1
  135. package/dist/lib/dbmodels/program/Challenge.js +0 -63
  136. package/dist/lib/dbmodels/program/Challenge.js.map +0 -1
  137. package/dist/lib/dbmodels/program/ChallengeBlueprint.js +0 -75
  138. package/dist/lib/dbmodels/program/ChallengeBlueprint.js.map +0 -1
  139. package/dist/lib/dbmodels/program/CircularProgramDraft.js +0 -82
  140. package/dist/lib/dbmodels/program/CircularProgramDraft.js.map +0 -1
  141. package/dist/lib/dbmodels/program/CoachExerciseNote.js +0 -61
  142. package/dist/lib/dbmodels/program/CoachExerciseNote.js.map +0 -1
  143. package/dist/lib/dbmodels/program/CustomProgramBlueprint.js +0 -84
  144. package/dist/lib/dbmodels/program/CustomProgramBlueprint.js.map +0 -1
  145. package/dist/lib/dbmodels/program/CustomStrengthTest.js +0 -55
  146. package/dist/lib/dbmodels/program/CustomStrengthTest.js.map +0 -1
  147. package/dist/lib/dbmodels/program/CustomStrengthTestExercises.js +0 -69
  148. package/dist/lib/dbmodels/program/CustomStrengthTestExercises.js.map +0 -1
  149. package/dist/lib/dbmodels/program/CustomWorkoutBlueprint.js +0 -58
  150. package/dist/lib/dbmodels/program/CustomWorkoutBlueprint.js.map +0 -1
  151. package/dist/lib/dbmodels/program/Exercise.d.ts +0 -23
  152. package/dist/lib/dbmodels/program/Exercise.d.ts.map +0 -1
  153. package/dist/lib/dbmodels/program/Exercise.js +0 -101
  154. package/dist/lib/dbmodels/program/Exercise.js.map +0 -1
  155. package/dist/lib/dbmodels/program/ExerciseModels.d.ts +0 -28
  156. package/dist/lib/dbmodels/program/ExerciseModels.d.ts.map +0 -1
  157. package/dist/lib/dbmodels/program/ExerciseModels.js +0 -149
  158. package/dist/lib/dbmodels/program/ExerciseModels.js.map +0 -1
  159. package/dist/lib/dbmodels/program/Program.d.ts +0 -15
  160. package/dist/lib/dbmodels/program/Program.d.ts.map +0 -1
  161. package/dist/lib/dbmodels/program/Program.js +0 -76
  162. package/dist/lib/dbmodels/program/Program.js.map +0 -1
  163. package/dist/lib/dbmodels/program/ProgressEntry.d.ts +0 -26
  164. package/dist/lib/dbmodels/program/ProgressEntry.d.ts.map +0 -1
  165. package/dist/lib/dbmodels/program/ProgressEntry.js +0 -77
  166. package/dist/lib/dbmodels/program/ProgressEntry.js.map +0 -1
  167. package/dist/lib/dbmodels/program/RestDay.js +0 -33
  168. package/dist/lib/dbmodels/program/RestDay.js.map +0 -1
  169. package/dist/lib/dbmodels/program/StrengthTest.d.ts +0 -10
  170. package/dist/lib/dbmodels/program/StrengthTest.d.ts.map +0 -1
  171. package/dist/lib/dbmodels/program/StrengthTest.js +0 -39
  172. package/dist/lib/dbmodels/program/StrengthTest.js.map +0 -1
  173. package/dist/lib/dbmodels/program/StrengthTestExercise.d.ts +0 -15
  174. package/dist/lib/dbmodels/program/StrengthTestExercise.d.ts.map +0 -1
  175. package/dist/lib/dbmodels/program/StrengthTestExercise.js +0 -72
  176. package/dist/lib/dbmodels/program/StrengthTestExercise.js.map +0 -1
  177. package/dist/lib/dbmodels/program/StrengthTestSession.js +0 -73
  178. package/dist/lib/dbmodels/program/StrengthTestSession.js.map +0 -1
  179. package/dist/lib/dbmodels/program/Superset.d.ts +0 -13
  180. package/dist/lib/dbmodels/program/Superset.d.ts.map +0 -1
  181. package/dist/lib/dbmodels/program/Superset.js +0 -46
  182. package/dist/lib/dbmodels/program/Superset.js.map +0 -1
  183. package/dist/lib/dbmodels/program/ThirtyDayChallenge.js +0 -70
  184. package/dist/lib/dbmodels/program/ThirtyDayChallenge.js.map +0 -1
  185. package/dist/lib/dbmodels/program/ThirtyDayChallengeStrengthTest.js +0 -55
  186. package/dist/lib/dbmodels/program/ThirtyDayChallengeStrengthTest.js.map +0 -1
  187. package/dist/lib/dbmodels/program/TranslatedChallenge.d.ts +0 -15
  188. package/dist/lib/dbmodels/program/TranslatedChallenge.d.ts.map +0 -1
  189. package/dist/lib/dbmodels/program/TranslatedChallenge.js +0 -69
  190. package/dist/lib/dbmodels/program/TranslatedChallenge.js.map +0 -1
  191. package/dist/lib/dbmodels/program/TranslatedExerciseModel.d.ts +0 -25
  192. package/dist/lib/dbmodels/program/TranslatedExerciseModel.d.ts.map +0 -1
  193. package/dist/lib/dbmodels/program/TranslatedExerciseModel.js +0 -123
  194. package/dist/lib/dbmodels/program/TranslatedExerciseModel.js.map +0 -1
  195. package/dist/lib/dbmodels/program/TranslatedStrengthTest.d.ts +0 -12
  196. package/dist/lib/dbmodels/program/TranslatedStrengthTest.d.ts.map +0 -1
  197. package/dist/lib/dbmodels/program/TranslatedStrengthTest.js +0 -45
  198. package/dist/lib/dbmodels/program/TranslatedStrengthTest.js.map +0 -1
  199. package/dist/lib/dbmodels/program/TranslatedStrengthTestExercise.d.ts +0 -16
  200. package/dist/lib/dbmodels/program/TranslatedStrengthTestExercise.d.ts.map +0 -1
  201. package/dist/lib/dbmodels/program/TranslatedStrengthTestExercise.js +0 -78
  202. package/dist/lib/dbmodels/program/TranslatedStrengthTestExercise.js.map +0 -1
  203. package/dist/lib/dbmodels/program/UserChallenge.d.ts +0 -10
  204. package/dist/lib/dbmodels/program/UserChallenge.d.ts.map +0 -1
  205. package/dist/lib/dbmodels/program/UserChallenge.js +0 -47
  206. package/dist/lib/dbmodels/program/UserChallenge.js.map +0 -1
  207. package/dist/lib/dbmodels/program/UserExerciseNote.js +0 -61
  208. package/dist/lib/dbmodels/program/UserExerciseNote.js.map +0 -1
  209. package/dist/lib/dbmodels/program/UserStrengthTests.d.ts +0 -11
  210. package/dist/lib/dbmodels/program/UserStrengthTests.d.ts.map +0 -1
  211. package/dist/lib/dbmodels/program/UserStrengthTests.js +0 -54
  212. package/dist/lib/dbmodels/program/UserStrengthTests.js.map +0 -1
  213. package/dist/lib/dbmodels/program/Workout.d.ts +0 -14
  214. package/dist/lib/dbmodels/program/Workout.d.ts.map +0 -1
  215. package/dist/lib/dbmodels/program/Workout.js +0 -66
  216. package/dist/lib/dbmodels/program/Workout.js.map +0 -1
  217. package/dist/lib/dbmodels/program/WorkoutCompletion.js +0 -65
  218. package/dist/lib/dbmodels/program/WorkoutCompletion.js.map +0 -1
  219. package/dist/lib/dbmodels/program/WorkoutSession.js +0 -93
  220. package/dist/lib/dbmodels/program/WorkoutSession.js.map +0 -1
  221. package/dist/lib/dbmodels/subscription/Subscription.d.ts +0 -19
  222. package/dist/lib/dbmodels/subscription/Subscription.d.ts.map +0 -1
  223. package/dist/lib/dbmodels/subscription/Subscription.js +0 -91
  224. package/dist/lib/dbmodels/subscription/Subscription.js.map +0 -1
  225. package/dist/lib/dbmodels/subscription/SubscriptionEvent.js +0 -79
  226. package/dist/lib/dbmodels/subscription/SubscriptionEvent.js.map +0 -1
  227. package/dist/lib/dbmodels/subscription/SubscriptionLog.d.ts +0 -9
  228. package/dist/lib/dbmodels/subscription/SubscriptionLog.d.ts.map +0 -1
  229. package/dist/lib/dbmodels/subscription/SubscriptionLog.js +0 -42
  230. package/dist/lib/dbmodels/subscription/SubscriptionLog.js.map +0 -1
  231. package/dist/lib/dbmodels/subscription/SubscriptionRefund.js +0 -92
  232. package/dist/lib/dbmodels/subscription/SubscriptionRefund.js.map +0 -1
  233. package/dist/lib/dbmodels/user/DeviceTokens.js +0 -34
  234. package/dist/lib/dbmodels/user/DeviceTokens.js.map +0 -1
  235. package/dist/lib/dbmodels/user/PersistedUser.d.ts +0 -43
  236. package/dist/lib/dbmodels/user/PersistedUser.d.ts.map +0 -1
  237. package/dist/lib/dbmodels/user/PersistedUser.js +0 -237
  238. package/dist/lib/dbmodels/user/PersistedUser.js.map +0 -1
  239. package/dist/lib/dbmodels/user/UserAddons.js +0 -26
  240. package/dist/lib/dbmodels/user/UserAddons.js.map +0 -1
  241. package/dist/lib/dbmodels/user/UserBadges.js +0 -63
  242. package/dist/lib/dbmodels/user/UserBadges.js.map +0 -1
  243. package/dist/lib/dbmodels/user/UserCoach.js +0 -40
  244. package/dist/lib/dbmodels/user/UserCoach.js.map +0 -1
  245. package/dist/lib/dbmodels/user/UserDiscount.js +0 -24
  246. package/dist/lib/dbmodels/user/UserDiscount.js.map +0 -1
  247. package/dist/lib/dbmodels/user/UserOptions.js +0 -34
  248. package/dist/lib/dbmodels/user/UserOptions.js.map +0 -1
  249. package/dist/lib/dbmodels/user/UserStreaks.js +0 -64
  250. package/dist/lib/dbmodels/user/UserStreaks.js.map +0 -1
  251. package/dist/lib/dbmodels/user/UsersFriends.js +0 -46
  252. package/dist/lib/dbmodels/user/UsersFriends.js.map +0 -1
  253. package/dist/lib/enums/ProgramEnums.d.ts +0 -18
  254. package/dist/lib/enums/ProgramEnums.d.ts.map +0 -1
  255. package/dist/lib/enums/ProgramEnums.js +0 -22
  256. package/dist/lib/enums/ProgramEnums.js.map +0 -1
  257. package/dist/lib/enums/ProgramTemplates.js +0 -738
  258. package/dist/lib/enums/ProgramTemplates.js.map +0 -1
  259. package/dist/lib/middlewares/ErrorMiddleware.js +0 -141
  260. package/dist/lib/middlewares/ErrorMiddleware.js.map +0 -1
  261. package/dist/lib/middlewares/ValidationMiddleware.js +0 -24
  262. package/dist/lib/middlewares/ValidationMiddleware.js.map +0 -1
  263. package/dist/lib/models/BlueprintInterfaces.js +0 -3
  264. package/dist/lib/models/BlueprintInterfaces.js.map +0 -1
  265. package/dist/lib/models/ExerciseInterfaces.d.ts +0 -68
  266. package/dist/lib/models/ExerciseInterfaces.d.ts.map +0 -1
  267. package/dist/lib/models/ExerciseInterfaces.js +0 -3
  268. package/dist/lib/models/ExerciseInterfaces.js.map +0 -1
  269. package/dist/lib/models/NotificationInterfaces.js +0 -11
  270. package/dist/lib/models/NotificationInterfaces.js.map +0 -1
  271. package/dist/lib/models/ProgramInterfaces.js +0 -3
  272. package/dist/lib/models/ProgramInterfaces.js.map +0 -1
  273. package/dist/lib/models/UserInterfaces.js +0 -3
  274. package/dist/lib/models/UserInterfaces.js.map +0 -1
  275. package/dist/lib/models/WorkoutInterfaces.js +0 -3
  276. package/dist/lib/models/WorkoutInterfaces.js.map +0 -1
  277. package/dist/lib/scripts/cli.js +0 -82
  278. package/dist/lib/scripts/cli.js.map +0 -1
  279. package/dist/lib/scripts/populate-exercise-thumbnails.js +0 -64
  280. package/dist/lib/scripts/populate-exercise-thumbnails.js.map +0 -1
  281. package/dist/lib/scripts/setup-database.js +0 -43
  282. package/dist/lib/scripts/setup-database.js.map +0 -1
  283. package/dist/lib/scripts/verify-indexes.js +0 -94
  284. package/dist/lib/scripts/verify-indexes.js.map +0 -1
  285. package/dist/lib/testing/testFixtures.js +0 -520
  286. package/dist/lib/testing/testFixtures.js.map +0 -1
  287. package/dist/lib/testing/testHelpers.js +0 -149
  288. package/dist/lib/testing/testHelpers.js.map +0 -1
  289. package/dist/lib/utils/AuthenticationUtil.js +0 -481
  290. package/dist/lib/utils/AuthenticationUtil.js.map +0 -1
  291. package/dist/lib/utils/Logger.js +0 -242
  292. package/dist/lib/utils/Logger.js.map +0 -1
  293. package/dist/lib/utils/NotificationClient.js +0 -371
  294. package/dist/lib/utils/NotificationClient.js.map +0 -1
  295. package/dist/lib/utils/NotificationsUtil.js +0 -95
  296. package/dist/lib/utils/NotificationsUtil.js.map +0 -1
  297. package/dist/lib/utils/SecretManager.js +0 -107
  298. package/dist/lib/utils/SecretManager.js.map +0 -1
  299. package/dist/lib/utils/SentryUtil.js +0 -140
  300. package/dist/lib/utils/SentryUtil.js.map +0 -1
  301. package/dist/lib/utils/imageValidation.js +0 -31
  302. package/dist/lib/utils/imageValidation.js.map +0 -1
@@ -1,98 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { Column, DataType, Default, ForeignKey, HasMany, Model, PrimaryKey, Table } from "sequelize-typescript";
8
- import { PersistedUser } from "../user/PersistedUser.js";
9
- import { DietDay } from "./DietDay.js";
10
- import { ShoppingList } from "./ShoppingList.js";
11
- export class DietProgram extends Model {
12
- }
13
- _ts_decorate([
14
- PrimaryKey,
15
- Default(DataType.UUIDV4),
16
- Column(DataType.UUID)
17
- ], DietProgram.prototype, "uuid", void 0);
18
- _ts_decorate([
19
- ForeignKey(()=>PersistedUser),
20
- Column(DataType.UUID)
21
- ], DietProgram.prototype, "userUuid", void 0);
22
- _ts_decorate([
23
- Column({
24
- type: DataType.DATE,
25
- allowNull: false
26
- })
27
- ], DietProgram.prototype, "startDate", void 0);
28
- _ts_decorate([
29
- Column({
30
- type: DataType.STRING,
31
- allowNull: true
32
- })
33
- ], DietProgram.prototype, "title", void 0);
34
- _ts_decorate([
35
- Column({
36
- type: DataType.INTEGER,
37
- allowNull: true
38
- })
39
- ], DietProgram.prototype, "dailyCalories", void 0);
40
- _ts_decorate([
41
- Column({
42
- type: DataType.FLOAT,
43
- allowNull: true
44
- })
45
- ], DietProgram.prototype, "dailyProtein", void 0);
46
- _ts_decorate([
47
- Column({
48
- type: DataType.FLOAT,
49
- allowNull: true
50
- })
51
- ], DietProgram.prototype, "dailyCarbs", void 0);
52
- _ts_decorate([
53
- Column({
54
- type: DataType.FLOAT,
55
- allowNull: true
56
- })
57
- ], DietProgram.prototype, "dailyFats", void 0);
58
- _ts_decorate([
59
- Column({
60
- type: DataType.INTEGER,
61
- allowNull: true
62
- })
63
- ], DietProgram.prototype, "numberOfDays", void 0);
64
- _ts_decorate([
65
- Column({
66
- type: DataType.ENUM('pending', 'completed', 'failed'),
67
- allowNull: false,
68
- defaultValue: 'pending'
69
- })
70
- ], DietProgram.prototype, "status", void 0);
71
- _ts_decorate([
72
- HasMany(()=>DietDay, {
73
- foreignKey: "dietProgramUuid",
74
- onDelete: "CASCADE"
75
- })
76
- ], DietProgram.prototype, "days", void 0);
77
- _ts_decorate([
78
- HasMany(()=>ShoppingList, {
79
- foreignKey: "dietProgramUuid",
80
- onDelete: "CASCADE"
81
- })
82
- ], DietProgram.prototype, "shoppingLists", void 0);
83
- DietProgram = _ts_decorate([
84
- Table({
85
- timestamps: true,
86
- indexes: [
87
- {
88
- unique: true,
89
- fields: [
90
- "userUuid"
91
- ],
92
- name: "unique_user_diet_program"
93
- }
94
- ]
95
- })
96
- ], DietProgram);
97
-
98
- //# sourceMappingURL=DietProgram.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/DietProgram.ts"],"sourcesContent":["import {\n Column,\n DataType,\n Default,\n ForeignKey,\n HasMany,\n Model,\n PrimaryKey,\n Table,\n} from \"sequelize-typescript\";\nimport { PersistedUser } from \"../user/PersistedUser.js\";\nimport { DietDay } from \"./DietDay.js\";\nimport { ShoppingList } from \"./ShoppingList.js\";\n\n@Table({\n timestamps: true,\n indexes: [\n {\n unique: true,\n fields: [\"userUuid\"],\n name: \"unique_user_diet_program\",\n },\n ],\n})\nexport class DietProgram extends Model<DietProgram> {\n @PrimaryKey\n @Default(DataType.UUIDV4)\n @Column(DataType.UUID)\n declare uuid: string;\n\n @ForeignKey(() => PersistedUser)\n @Column(DataType.UUID)\n declare userUuid: string;\n\n @Column({ type: DataType.DATE, allowNull: false })\n declare startDate: Date;\n\n @Column({ type: DataType.STRING, allowNull: true })\n declare title: string;\n\n @Column({ type: DataType.INTEGER, allowNull: true })\n declare dailyCalories: number | null;\n\n @Column({ type: DataType.FLOAT, allowNull: true })\n declare dailyProtein: number | null;\n\n @Column({ type: DataType.FLOAT, allowNull: true })\n declare dailyCarbs: number | null;\n\n @Column({ type: DataType.FLOAT, allowNull: true })\n declare dailyFats: number | null;\n\n @Column({ type: DataType.INTEGER, allowNull: true })\n declare numberOfDays: number | null;\n\n @Column({\n type: DataType.ENUM('pending', 'completed', 'failed'),\n allowNull: false,\n defaultValue: 'pending'\n })\n declare status: 'pending' | 'completed' | 'failed';\n\n @HasMany(() => DietDay, {\n foreignKey: \"dietProgramUuid\",\n onDelete: \"CASCADE\",\n })\n declare days: DietDay[];\n\n @HasMany(() => ShoppingList, {\n foreignKey: \"dietProgramUuid\",\n onDelete: \"CASCADE\",\n })\n declare shoppingLists: ShoppingList[];\n}\n"],"names":["Column","DataType","Default","ForeignKey","HasMany","Model","PrimaryKey","Table","PersistedUser","DietDay","ShoppingList","DietProgram","UUIDV4","UUID","type","DATE","allowNull","STRING","INTEGER","FLOAT","ENUM","defaultValue","foreignKey","onDelete","timestamps","indexes","unique","fields","name"],"mappings":";;;;;;AAAA,SACEA,MAAM,EACNC,QAAQ,EACRC,OAAO,EACPC,UAAU,EACVC,OAAO,EACPC,KAAK,EACLC,UAAU,EACVC,KAAK,QACA,uBAAuB;AAC9B,SAASC,aAAa,QAAQ,2BAA2B;AACzD,SAASC,OAAO,QAAQ,eAAe;AACvC,SAASC,YAAY,QAAQ,oBAAoB;AAYjD,OAAO,MAAMC,oBAAoBN;AAiDjC;;;qBA/CoBO;oBACDC;;;mBAGCL;oBACDK;;;;QAGPC,MAAMb,SAASc,IAAI;QAAEC,WAAW;;;;;QAGhCF,MAAMb,SAASgB,MAAM;QAAED,WAAW;;;;;QAGlCF,MAAMb,SAASiB,OAAO;QAAEF,WAAW;;;;;QAGnCF,MAAMb,SAASkB,KAAK;QAAEH,WAAW;;;;;QAGjCF,MAAMb,SAASkB,KAAK;QAAEH,WAAW;;;;;QAGjCF,MAAMb,SAASkB,KAAK;QAAEH,WAAW;;;;;QAGjCF,MAAMb,SAASiB,OAAO;QAAEF,WAAW;;;;;QAI3CF,MAAMb,SAASmB,IAAI,CAAC,WAAW,aAAa;QAC5CJ,WAAW;QACXK,cAAc;;;;gBAIDZ;QACba,YAAY;QACZC,UAAU;;;;gBAIGb;QACbY,YAAY;QACZC,UAAU;;;;;QAvDZC,YAAY;QACZC,SAAS;YACP;gBACEC,QAAQ;gBACRC,QAAQ;oBAAC;iBAAW;gBACpBC,MAAM;YACR;SACD"}
@@ -1,88 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { Table, Model, Column, DataType, Default, PrimaryKey, HasMany, BelongsToMany } from "sequelize-typescript";
8
- import { RecipeIngredient } from "./RecipeIngredient.js";
9
- import { IngredientTag } from "./IngredientTag.js";
10
- import { IngredientTags } from "./IngredientTags.js";
11
- export class Ingredient extends Model {
12
- }
13
- _ts_decorate([
14
- PrimaryKey,
15
- Default(DataType.UUIDV4),
16
- Column(DataType.UUID)
17
- ], Ingredient.prototype, "uuid", void 0);
18
- _ts_decorate([
19
- Column({
20
- type: DataType.STRING,
21
- allowNull: false,
22
- unique: true
23
- })
24
- ], Ingredient.prototype, "name", void 0);
25
- _ts_decorate([
26
- Column({
27
- type: DataType.FLOAT,
28
- allowNull: false
29
- })
30
- ], Ingredient.prototype, "caloriesPer100g", void 0);
31
- _ts_decorate([
32
- Column({
33
- type: DataType.FLOAT,
34
- allowNull: false
35
- })
36
- ], Ingredient.prototype, "proteinPer100g", void 0);
37
- _ts_decorate([
38
- Column({
39
- type: DataType.FLOAT,
40
- allowNull: false
41
- })
42
- ], Ingredient.prototype, "carbsPer100g", void 0);
43
- _ts_decorate([
44
- Column({
45
- type: DataType.FLOAT,
46
- allowNull: false
47
- })
48
- ], Ingredient.prototype, "fatsPer100g", void 0);
49
- _ts_decorate([
50
- Column({
51
- type: DataType.STRING,
52
- allowNull: true
53
- })
54
- ], Ingredient.prototype, "category", void 0);
55
- _ts_decorate([
56
- HasMany(()=>RecipeIngredient, {
57
- foreignKey: "ingredientUuid",
58
- onDelete: "CASCADE"
59
- })
60
- ], Ingredient.prototype, "recipeIngredients", void 0);
61
- _ts_decorate([
62
- BelongsToMany(()=>IngredientTag, {
63
- through: ()=>IngredientTags,
64
- foreignKey: "ingredientUuid",
65
- otherKey: "ingredientTagUuid",
66
- as: "tags"
67
- })
68
- ], Ingredient.prototype, "tags", void 0);
69
- Ingredient = _ts_decorate([
70
- Table({
71
- timestamps: true,
72
- indexes: [
73
- {
74
- fields: [
75
- "name"
76
- ],
77
- unique: true
78
- },
79
- {
80
- fields: [
81
- "category"
82
- ]
83
- }
84
- ]
85
- })
86
- ], Ingredient);
87
-
88
- //# sourceMappingURL=Ingredient.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/Ingredient.ts"],"sourcesContent":["import {\n Table,\n Model,\n Column,\n DataType,\n Default,\n PrimaryKey,\n HasMany,\n BelongsToMany,\n} from \"sequelize-typescript\";\nimport type { Optional } from \"sequelize\";\nimport { RecipeIngredient } from \"./RecipeIngredient.js\";\nimport { IngredientTag } from \"./IngredientTag.js\";\nimport { IngredientTags } from \"./IngredientTags.js\";\n\ninterface IngredientAttributes {\n uuid: string;\n name: string;\n caloriesPer100g: number;\n proteinPer100g: number;\n carbsPer100g: number;\n fatsPer100g: number;\n category?: string;\n createdAt?: Date;\n updatedAt?: Date;\n}\n\ninterface IngredientCreationAttributes\n extends Optional<IngredientAttributes, \"uuid\" | \"category\" | \"createdAt\" | \"updatedAt\"> {}\n\n@Table({\n timestamps: true,\n indexes: [\n {\n fields: [\"name\"],\n unique: true,\n },\n {\n fields: [\"category\"],\n },\n ],\n})\nexport class Ingredient extends Model<IngredientAttributes, IngredientCreationAttributes> {\n @PrimaryKey\n @Default(DataType.UUIDV4)\n @Column(DataType.UUID)\n declare uuid: string;\n\n @Column({ type: DataType.STRING, allowNull: false, unique: true })\n declare name: string;\n\n @Column({ type: DataType.FLOAT, allowNull: false })\n declare caloriesPer100g: number;\n\n @Column({ type: DataType.FLOAT, allowNull: false })\n declare proteinPer100g: number;\n\n @Column({ type: DataType.FLOAT, allowNull: false })\n declare carbsPer100g: number;\n\n @Column({ type: DataType.FLOAT, allowNull: false })\n declare fatsPer100g: number;\n\n @Column({ type: DataType.STRING, allowNull: true })\n declare category: string;\n\n @HasMany(() => RecipeIngredient, { foreignKey: \"ingredientUuid\", onDelete: \"CASCADE\" })\n declare recipeIngredients: RecipeIngredient[];\n\n @BelongsToMany(() => IngredientTag, {\n through: () => IngredientTags,\n foreignKey: \"ingredientUuid\",\n otherKey: \"ingredientTagUuid\",\n as: \"tags\",\n })\n declare tags: IngredientTag[];\n}\n"],"names":["Table","Model","Column","DataType","Default","PrimaryKey","HasMany","BelongsToMany","RecipeIngredient","IngredientTag","IngredientTags","Ingredient","UUIDV4","UUID","type","STRING","allowNull","unique","FLOAT","foreignKey","onDelete","through","otherKey","as","timestamps","indexes","fields"],"mappings":";;;;;;AAAA,SACEA,KAAK,EACLC,KAAK,EACLC,MAAM,EACNC,QAAQ,EACRC,OAAO,EACPC,UAAU,EACVC,OAAO,EACPC,aAAa,QACR,uBAAuB;AAE9B,SAASC,gBAAgB,QAAQ,wBAAwB;AACzD,SAASC,aAAa,QAAQ,qBAAqB;AACnD,SAASC,cAAc,QAAQ,sBAAsB;AA6BrD,OAAO,MAAMC,mBAAmBV;AAkChC;;;qBAhCoBW;oBACDC;;;;QAGPC,MAAMX,SAASY,MAAM;QAAEC,WAAW;QAAOC,QAAQ;;;;;QAGjDH,MAAMX,SAASe,KAAK;QAAEF,WAAW;;;;;QAGjCF,MAAMX,SAASe,KAAK;QAAEF,WAAW;;;;;QAGjCF,MAAMX,SAASe,KAAK;QAAEF,WAAW;;;;;QAGjCF,MAAMX,SAASe,KAAK;QAAEF,WAAW;;;;;QAGjCF,MAAMX,SAASY,MAAM;QAAEC,WAAW;;;;gBAG7BR;QAAoBW,YAAY;QAAkBC,UAAU;;;;sBAGtDX;QACnBY,SAAS,IAAMX;QACfS,YAAY;QACZG,UAAU;QACVC,IAAI;;;;;QA1CNC,YAAY;QACZC,SAAS;YACP;gBACEC,QAAQ;oBAAC;iBAAO;gBAChBT,QAAQ;YACV;YACA;gBACES,QAAQ;oBAAC;iBAAW;YACtB;SACD"}
@@ -1,64 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { BelongsToMany, Column, DataType, Default, Model, PrimaryKey, Table } from "sequelize-typescript";
8
- import { Ingredient } from "./Ingredient.js";
9
- import { IngredientTags } from "./IngredientTags.js";
10
- export class IngredientTag extends Model {
11
- }
12
- _ts_decorate([
13
- PrimaryKey,
14
- Default(DataType.UUIDV4),
15
- Column(DataType.UUID)
16
- ], IngredientTag.prototype, "uuid", void 0);
17
- _ts_decorate([
18
- Column({
19
- type: DataType.TEXT,
20
- allowNull: false,
21
- unique: true
22
- })
23
- ], IngredientTag.prototype, "tag", void 0);
24
- _ts_decorate([
25
- Column({
26
- type: DataType.STRING,
27
- allowNull: false
28
- })
29
- ], IngredientTag.prototype, "category", void 0);
30
- _ts_decorate([
31
- Column({
32
- type: DataType.INTEGER,
33
- allowNull: false,
34
- defaultValue: 0
35
- })
36
- ], IngredientTag.prototype, "order", void 0);
37
- _ts_decorate([
38
- BelongsToMany(()=>Ingredient, {
39
- through: ()=>IngredientTags,
40
- foreignKey: "ingredientTagUuid",
41
- otherKey: "ingredientUuid"
42
- })
43
- ], IngredientTag.prototype, "ingredients", void 0);
44
- IngredientTag = _ts_decorate([
45
- Table({
46
- tableName: "IngredientTag",
47
- timestamps: true,
48
- indexes: [
49
- {
50
- fields: [
51
- "tag"
52
- ],
53
- unique: true
54
- },
55
- {
56
- fields: [
57
- "category"
58
- ]
59
- }
60
- ]
61
- })
62
- ], IngredientTag);
63
-
64
- //# sourceMappingURL=IngredientTag.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/IngredientTag.ts"],"sourcesContent":["import {\n BelongsToMany,\n Column,\n DataType,\n Default,\n Model,\n PrimaryKey,\n Table,\n} from \"sequelize-typescript\";\nimport type { Optional } from \"sequelize\";\nimport { Ingredient } from \"./Ingredient.js\";\nimport { IngredientTags } from \"./IngredientTags.js\";\n\ninterface IngredientTagAttributes {\n uuid: string;\n tag: string;\n category: string;\n order: number;\n createdAt?: Date;\n updatedAt?: Date;\n}\n\ninterface IngredientTagCreationAttributes\n extends Optional<IngredientTagAttributes, \"uuid\" | \"order\" | \"createdAt\" | \"updatedAt\"> {}\n\n@Table({\n tableName: \"IngredientTag\",\n timestamps: true,\n indexes: [\n {\n fields: [\"tag\"],\n unique: true,\n },\n {\n fields: [\"category\"],\n },\n ],\n})\nexport class IngredientTag extends Model<\n IngredientTagAttributes,\n IngredientTagCreationAttributes\n> {\n @PrimaryKey\n @Default(DataType.UUIDV4)\n @Column(DataType.UUID)\n declare uuid: string;\n\n @Column({ type: DataType.TEXT, allowNull: false, unique: true })\n declare tag: string;\n\n @Column({ type: DataType.STRING, allowNull: false })\n declare category: string;\n\n @Column({ type: DataType.INTEGER, allowNull: false, defaultValue: 0 })\n declare order: number;\n\n @BelongsToMany(() => Ingredient, {\n through: () => IngredientTags,\n foreignKey: \"ingredientTagUuid\",\n otherKey: \"ingredientUuid\",\n })\n declare ingredients: Ingredient[];\n}\n"],"names":["BelongsToMany","Column","DataType","Default","Model","PrimaryKey","Table","Ingredient","IngredientTags","IngredientTag","UUIDV4","UUID","type","TEXT","allowNull","unique","STRING","INTEGER","defaultValue","through","foreignKey","otherKey","tableName","timestamps","indexes","fields"],"mappings":";;;;;;AAAA,SACEA,aAAa,EACbC,MAAM,EACNC,QAAQ,EACRC,OAAO,EACPC,KAAK,EACLC,UAAU,EACVC,KAAK,QACA,uBAAuB;AAE9B,SAASC,UAAU,QAAQ,kBAAkB;AAC7C,SAASC,cAAc,QAAQ,sBAAsB;AA2BrD,OAAO,MAAMC,sBAAsBL;AAwBnC;;;qBAnBoBM;oBACDC;;;;QAGPC,MAAMV,SAASW,IAAI;QAAEC,WAAW;QAAOC,QAAQ;;;;;QAG/CH,MAAMV,SAASc,MAAM;QAAEF,WAAW;;;;;QAGlCF,MAAMV,SAASe,OAAO;QAAEH,WAAW;QAAOI,cAAc;;;;sBAG7CX;QACnBY,SAAS,IAAMX;QACfY,YAAY;QACZC,UAAU;;;;;QAjCZC,WAAW;QACXC,YAAY;QACZC,SAAS;YACP;gBACEC,QAAQ;oBAAC;iBAAM;gBACfV,QAAQ;YACV;YACA;gBACEU,QAAQ;oBAAC;iBAAW;YACtB;SACD"}
@@ -1,29 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { Column, DataType, ForeignKey, Model, Table, PrimaryKey } from "sequelize-typescript";
8
- import { Ingredient } from "./Ingredient.js";
9
- import { IngredientTag } from "./IngredientTag.js";
10
- export class IngredientTags extends Model {
11
- }
12
- _ts_decorate([
13
- PrimaryKey,
14
- ForeignKey(()=>Ingredient),
15
- Column(DataType.UUID)
16
- ], IngredientTags.prototype, "ingredientUuid", void 0);
17
- _ts_decorate([
18
- PrimaryKey,
19
- ForeignKey(()=>IngredientTag),
20
- Column(DataType.UUID)
21
- ], IngredientTags.prototype, "ingredientTagUuid", void 0);
22
- IngredientTags = _ts_decorate([
23
- Table({
24
- tableName: "IngredientTags",
25
- timestamps: false
26
- })
27
- ], IngredientTags);
28
-
29
- //# sourceMappingURL=IngredientTags.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/IngredientTags.ts"],"sourcesContent":["import {\n Column,\n DataType,\n ForeignKey,\n Model,\n Table,\n PrimaryKey,\n} from \"sequelize-typescript\";\nimport { Ingredient } from \"./Ingredient.js\";\nimport { IngredientTag } from \"./IngredientTag.js\";\n\n@Table({ tableName: \"IngredientTags\", timestamps: false })\nexport class IngredientTags extends Model<IngredientTags> {\n @PrimaryKey\n @ForeignKey(() => Ingredient)\n @Column(DataType.UUID)\n declare ingredientUuid: string;\n\n @PrimaryKey\n @ForeignKey(() => IngredientTag)\n @Column(DataType.UUID)\n declare ingredientTagUuid: string;\n}\n"],"names":["Column","DataType","ForeignKey","Model","Table","PrimaryKey","Ingredient","IngredientTag","IngredientTags","UUID","tableName","timestamps"],"mappings":";;;;;;AAAA,SACEA,MAAM,EACNC,QAAQ,EACRC,UAAU,EACVC,KAAK,EACLC,KAAK,EACLC,UAAU,QACL,uBAAuB;AAC9B,SAASC,UAAU,QAAQ,kBAAkB;AAC7C,SAASC,aAAa,QAAQ,qBAAqB;AAGnD,OAAO,MAAMC,uBAAuBL;AAUpC;;;mBARoBG;oBACDG;;;;mBAICF;oBACDE;;;;QATVC,WAAW;QAAkBC,YAAY"}
@@ -1,173 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { BelongsTo, BelongsToMany, Column, DataType, Default, ForeignKey, HasMany, Model, Table } from "sequelize-typescript";
8
- import { TranslatedRecipe } from "./TranslatedRecipe.js";
9
- import { RecipeTag } from "./RecipeTag.js";
10
- import { RecipeTags } from "./RecipeTags.js";
11
- import { RecipeIngredient } from "./RecipeIngredient.js";
12
- import { PersistedUser } from "../user/PersistedUser.js";
13
- export class Recipe extends Model {
14
- }
15
- _ts_decorate([
16
- Default(DataType.UUIDV4),
17
- Column({
18
- type: DataType.UUID,
19
- defaultValue: DataType.UUID,
20
- allowNull: false,
21
- primaryKey: true
22
- })
23
- ], Recipe.prototype, "uuid", void 0);
24
- _ts_decorate([
25
- ForeignKey(()=>PersistedUser),
26
- Column({
27
- type: DataType.UUID,
28
- allowNull: true
29
- })
30
- ], Recipe.prototype, "createdBy", void 0);
31
- _ts_decorate([
32
- Column({
33
- type: DataType.TEXT,
34
- allowNull: false
35
- })
36
- ], Recipe.prototype, "title", void 0);
37
- _ts_decorate([
38
- Column({
39
- type: DataType.TEXT,
40
- allowNull: false
41
- })
42
- ], Recipe.prototype, "duration", void 0);
43
- _ts_decorate([
44
- Column({
45
- type: DataType.TEXT,
46
- allowNull: false
47
- })
48
- ], Recipe.prototype, "content", void 0);
49
- _ts_decorate([
50
- Column({
51
- type: DataType.TEXT,
52
- allowNull: false
53
- })
54
- ], Recipe.prototype, "kcal", void 0);
55
- _ts_decorate([
56
- Column({
57
- type: DataType.TEXT,
58
- allowNull: false
59
- })
60
- ], Recipe.prototype, "fat", void 0);
61
- _ts_decorate([
62
- Column({
63
- type: DataType.TEXT,
64
- allowNull: false
65
- })
66
- ], Recipe.prototype, "carbs", void 0);
67
- _ts_decorate([
68
- Column({
69
- type: DataType.TEXT,
70
- allowNull: false
71
- })
72
- ], Recipe.prototype, "protein", void 0);
73
- _ts_decorate([
74
- Column({
75
- type: DataType.TEXT,
76
- allowNull: false
77
- })
78
- ], Recipe.prototype, "ingredients", void 0);
79
- _ts_decorate([
80
- Column({
81
- type: DataType.TEXT,
82
- allowNull: false
83
- })
84
- ], Recipe.prototype, "method", void 0);
85
- _ts_decorate([
86
- Column({
87
- type: DataType.TEXT,
88
- allowNull: false
89
- })
90
- ], Recipe.prototype, "tipsAndTricks", void 0);
91
- _ts_decorate([
92
- Column({
93
- type: DataType.BOOLEAN,
94
- allowNull: false,
95
- defaultValue: false
96
- })
97
- ], Recipe.prototype, "ShowForFreeVersion", void 0);
98
- _ts_decorate([
99
- Column({
100
- type: DataType.BOOLEAN,
101
- allowNull: false,
102
- defaultValue: false
103
- })
104
- ], Recipe.prototype, "LockForFreeVersion", void 0);
105
- _ts_decorate([
106
- Default(true),
107
- Column({
108
- type: DataType.BOOLEAN,
109
- allowNull: false,
110
- defaultValue: false
111
- })
112
- ], Recipe.prototype, "isCoachingRecipe", void 0);
113
- _ts_decorate([
114
- Column({
115
- type: DataType.BOOLEAN,
116
- allowNull: false,
117
- defaultValue: false
118
- })
119
- ], Recipe.prototype, "isPublic", void 0);
120
- _ts_decorate([
121
- BelongsToMany(()=>RecipeTag, {
122
- through: ()=>RecipeTags,
123
- as: "tags"
124
- })
125
- ], Recipe.prototype, "tags", void 0);
126
- _ts_decorate([
127
- Column({
128
- type: DataType.INTEGER,
129
- allowNull: false,
130
- defaultValue: 0
131
- })
132
- ], Recipe.prototype, "order", void 0);
133
- _ts_decorate([
134
- Column({
135
- type: DataType.STRING(500),
136
- allowNull: true
137
- })
138
- ], Recipe.prototype, "coverImageUrl", void 0);
139
- _ts_decorate([
140
- Column({
141
- type: DataType.STRING(500),
142
- allowNull: true
143
- })
144
- ], Recipe.prototype, "ingredientsImageUrl", void 0);
145
- _ts_decorate([
146
- Column({
147
- type: DataType.STRING(500),
148
- allowNull: true
149
- })
150
- ], Recipe.prototype, "methodImageUrl", void 0);
151
- _ts_decorate([
152
- Column({
153
- type: DataType.DATE,
154
- allowNull: true
155
- })
156
- ], Recipe.prototype, "imageUploadedAt", void 0);
157
- _ts_decorate([
158
- HasMany(()=>TranslatedRecipe)
159
- ], Recipe.prototype, "translatedRecipes", void 0);
160
- _ts_decorate([
161
- HasMany(()=>RecipeIngredient, {
162
- foreignKey: "recipeUuid",
163
- onDelete: "CASCADE"
164
- })
165
- ], Recipe.prototype, "recipeIngredients", void 0);
166
- _ts_decorate([
167
- BelongsTo(()=>PersistedUser)
168
- ], Recipe.prototype, "creator", void 0);
169
- Recipe = _ts_decorate([
170
- Table
171
- ], Recipe);
172
-
173
- //# sourceMappingURL=Recipe.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/Recipe.ts"],"sourcesContent":["import {\n BelongsTo,\n BelongsToMany,\n Column,\n DataType,\n Default,\n ForeignKey,\n HasMany,\n Model,\n Table,\n} from \"sequelize-typescript\";\nimport type { Optional } from \"sequelize\";\nimport { TranslatedRecipe } from \"./TranslatedRecipe.js\";\nimport { RecipeTag } from \"./RecipeTag.js\";\nimport { RecipeTags } from \"./RecipeTags.js\";\nimport { RecipeIngredient } from \"./RecipeIngredient.js\";\nimport { PersistedUser } from \"../user/PersistedUser.js\";\n\nexport interface RecipeAttributes {\n uuid: string;\n createdBy?: string | null;\n title: string;\n duration: string;\n content: string;\n kcal: string;\n fat: string;\n carbs: string;\n protein: string;\n ingredients: string;\n method: string;\n tipsAndTricks: string;\n ShowForFreeVersion: boolean;\n LockForFreeVersion: boolean;\n isCoachingRecipe: boolean;\n isPublic: boolean;\n order: number;\n coverImageUrl?: string | null;\n ingredientsImageUrl?: string | null;\n methodImageUrl?: string | null;\n imageUploadedAt?: Date | null;\n createdAt?: Date;\n updatedAt?: Date;\n translatedRecipes?: TranslatedRecipe[];\n tags?: RecipeTag[];\n}\n\nexport interface RecipeCreationAttributes extends Optional<RecipeAttributes, \"uuid\" | \"createdBy\" | \"createdAt\" | \"updatedAt\" | \"coverImageUrl\" | \"ingredientsImageUrl\" | \"methodImageUrl\" | \"imageUploadedAt\"> {\n}\n\n@Table\nexport class Recipe extends Model<RecipeAttributes, RecipeCreationAttributes> {\n @Default(DataType.UUIDV4)\n @Column({\n type: DataType.UUID,\n defaultValue: DataType.UUID,\n allowNull: false,\n primaryKey: true,\n })\n declare uuid: string;\n\n @ForeignKey(() => PersistedUser)\n @Column({\n type: DataType.UUID,\n allowNull: true,\n })\n declare createdBy: string | null;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare title: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare duration: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare content: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare kcal: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare fat: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare carbs: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare protein: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare ingredients: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare method: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare tipsAndTricks: string;\n\n @Column({ type: DataType.BOOLEAN, allowNull: false, defaultValue: false })\n declare ShowForFreeVersion: boolean;\n\n @Column({ type: DataType.BOOLEAN, allowNull: false, defaultValue: false })\n declare LockForFreeVersion: boolean;\n\n @Default(true)\n @Column({ type: DataType.BOOLEAN, allowNull: false, defaultValue: false })\n declare isCoachingRecipe: boolean;\n\n @Column({ type: DataType.BOOLEAN, allowNull: false, defaultValue: false })\n declare isPublic: boolean;\n\n @BelongsToMany(() => RecipeTag, { through: () => RecipeTags, as: \"tags\" })\n declare tags: RecipeTag[];\n\n @Column({ type: DataType.INTEGER, allowNull: false, defaultValue: 0 })\n declare order: number;\n\n @Column({ type: DataType.STRING(500), allowNull: true })\n declare coverImageUrl?: string | null;\n\n @Column({ type: DataType.STRING(500), allowNull: true })\n declare ingredientsImageUrl?: string | null;\n\n @Column({ type: DataType.STRING(500), allowNull: true })\n declare methodImageUrl?: string | null;\n\n @Column({ type: DataType.DATE, allowNull: true })\n declare imageUploadedAt?: Date | null;\n\n @HasMany(() => TranslatedRecipe)\n declare translatedRecipes: TranslatedRecipe[];\n\n @HasMany(() => RecipeIngredient, { foreignKey: \"recipeUuid\", onDelete: \"CASCADE\" })\n declare recipeIngredients: RecipeIngredient[];\n\n @BelongsTo(() => PersistedUser)\n declare creator: PersistedUser;\n}\n"],"names":["BelongsTo","BelongsToMany","Column","DataType","Default","ForeignKey","HasMany","Model","Table","TranslatedRecipe","RecipeTag","RecipeTags","RecipeIngredient","PersistedUser","Recipe","UUIDV4","type","UUID","defaultValue","allowNull","primaryKey","TEXT","BOOLEAN","through","as","INTEGER","STRING","DATE","foreignKey","onDelete"],"mappings":";;;;;;AAAA,SACEA,SAAS,EACTC,aAAa,EACbC,MAAM,EACNC,QAAQ,EACRC,OAAO,EACPC,UAAU,EACVC,OAAO,EACPC,KAAK,EACLC,KAAK,QACA,uBAAuB;AAE9B,SAASC,gBAAgB,QAAQ,wBAAwB;AACzD,SAASC,SAAS,QAAQ,iBAAiB;AAC3C,SAASC,UAAU,QAAQ,kBAAkB;AAC7C,SAASC,gBAAgB,QAAQ,wBAAwB;AACzD,SAASC,aAAa,QAAQ,2BAA2B;AAkCzD,OAAO,MAAMC,eAAeP;AAsF5B;;qBArFoBQ;;QAEhBC,MAAMb,SAASc,IAAI;QACnBC,cAAcf,SAASc,IAAI;QAC3BE,WAAW;QACXC,YAAY;;;;mBAIIP;;QAEhBG,MAAMb,SAASc,IAAI;QACnBE,WAAW;;;;;QAIHH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASkB,IAAI;QAAEF,WAAW;;;;;QAGhCH,MAAMb,SAASmB,OAAO;QAAEH,WAAW;QAAOD,cAAc;;;;;QAGxDF,MAAMb,SAASmB,OAAO;QAAEH,WAAW;QAAOD,cAAc;;;;;;QAIxDF,MAAMb,SAASmB,OAAO;QAAEH,WAAW;QAAOD,cAAc;;;;;QAGxDF,MAAMb,SAASmB,OAAO;QAAEH,WAAW;QAAOD,cAAc;;;;sBAG7CR;QAAaa,SAAS,IAAMZ;QAAYa,IAAI;;;;;QAGvDR,MAAMb,SAASsB,OAAO;QAAEN,WAAW;QAAOD,cAAc;;;;;QAGxDF,MAAMb,SAASuB,MAAM,CAAC;QAAMP,WAAW;;;;;QAGvCH,MAAMb,SAASuB,MAAM,CAAC;QAAMP,WAAW;;;;;QAGvCH,MAAMb,SAASuB,MAAM,CAAC;QAAMP,WAAW;;;;;QAGvCH,MAAMb,SAASwB,IAAI;QAAER,WAAW;;;;gBAG3BV;;;gBAGAG;QAAoBgB,YAAY;QAAcC,UAAU;;;;kBAGtDhB"}
@@ -1,78 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { Table, Model, Column, DataType, Default, PrimaryKey, ForeignKey, BelongsTo, Index } from "sequelize-typescript";
8
- import { Recipe } from "./Recipe.js";
9
- import { Ingredient } from "./Ingredient.js";
10
- export class RecipeIngredient extends Model {
11
- }
12
- _ts_decorate([
13
- PrimaryKey,
14
- Default(DataType.UUIDV4),
15
- Column(DataType.UUID)
16
- ], RecipeIngredient.prototype, "uuid", void 0);
17
- _ts_decorate([
18
- Index,
19
- ForeignKey(()=>Recipe),
20
- Column({
21
- type: DataType.UUID,
22
- allowNull: false
23
- })
24
- ], RecipeIngredient.prototype, "recipeUuid", void 0);
25
- _ts_decorate([
26
- BelongsTo(()=>Recipe, {
27
- foreignKey: "recipeUuid",
28
- onDelete: "CASCADE"
29
- })
30
- ], RecipeIngredient.prototype, "recipe", void 0);
31
- _ts_decorate([
32
- Index,
33
- ForeignKey(()=>Ingredient),
34
- Column({
35
- type: DataType.UUID,
36
- allowNull: false
37
- })
38
- ], RecipeIngredient.prototype, "ingredientUuid", void 0);
39
- _ts_decorate([
40
- BelongsTo(()=>Ingredient, {
41
- foreignKey: "ingredientUuid",
42
- onDelete: "RESTRICT"
43
- })
44
- ], RecipeIngredient.prototype, "ingredient", void 0);
45
- _ts_decorate([
46
- Column({
47
- type: DataType.FLOAT,
48
- allowNull: false
49
- })
50
- ], RecipeIngredient.prototype, "grams", void 0);
51
- _ts_decorate([
52
- Column({
53
- type: DataType.FLOAT,
54
- allowNull: true
55
- })
56
- ], RecipeIngredient.prototype, "displayAmount", void 0);
57
- _ts_decorate([
58
- Column({
59
- type: DataType.STRING(100),
60
- allowNull: true
61
- })
62
- ], RecipeIngredient.prototype, "displayUnit", void 0);
63
- RecipeIngredient = _ts_decorate([
64
- Table({
65
- timestamps: true,
66
- indexes: [
67
- {
68
- fields: [
69
- "recipeUuid",
70
- "ingredientUuid"
71
- ],
72
- unique: true
73
- }
74
- ]
75
- })
76
- ], RecipeIngredient);
77
-
78
- //# sourceMappingURL=RecipeIngredient.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/RecipeIngredient.ts"],"sourcesContent":["import {\n Table,\n Model,\n Column,\n DataType,\n Default,\n PrimaryKey,\n ForeignKey,\n BelongsTo,\n Index,\n} from \"sequelize-typescript\";\nimport type { Optional } from \"sequelize\";\nimport { Recipe } from \"./Recipe.js\";\nimport { Ingredient } from \"./Ingredient.js\";\n\nexport interface RecipeIngredientAttributes {\n uuid: string;\n recipeUuid: string;\n ingredientUuid: string;\n grams: number;\n displayAmount?: number;\n displayUnit?: string;\n createdAt?: Date;\n updatedAt?: Date;\n}\n\nexport interface RecipeIngredientCreationAttributes\n extends Optional<RecipeIngredientAttributes, \"uuid\" | \"createdAt\" | \"updatedAt\"> {}\n\n@Table({\n timestamps: true,\n indexes: [\n {\n fields: [\"recipeUuid\", \"ingredientUuid\"],\n unique: true,\n },\n ],\n})\nexport class RecipeIngredient extends Model<\n RecipeIngredientAttributes,\n RecipeIngredientCreationAttributes\n> {\n @PrimaryKey\n @Default(DataType.UUIDV4)\n @Column(DataType.UUID)\n declare uuid: string;\n\n @Index\n @ForeignKey(() => Recipe)\n @Column({ type: DataType.UUID, allowNull: false })\n declare recipeUuid: string;\n\n @BelongsTo(() => Recipe, { foreignKey: \"recipeUuid\", onDelete: \"CASCADE\" })\n declare recipe: Recipe;\n\n @Index\n @ForeignKey(() => Ingredient)\n @Column({ type: DataType.UUID, allowNull: false })\n declare ingredientUuid: string;\n\n @BelongsTo(() => Ingredient, { foreignKey: \"ingredientUuid\", onDelete: \"RESTRICT\" })\n declare ingredient: Ingredient;\n\n @Column({ type: DataType.FLOAT, allowNull: false })\n declare grams: number;\n\n @Column({ type: DataType.FLOAT, allowNull: true })\n declare displayAmount?: number;\n\n @Column({ type: DataType.STRING(100), allowNull: true })\n declare displayUnit?: string;\n}\n"],"names":["Table","Model","Column","DataType","Default","PrimaryKey","ForeignKey","BelongsTo","Index","Recipe","Ingredient","RecipeIngredient","UUIDV4","UUID","type","allowNull","foreignKey","onDelete","FLOAT","STRING","timestamps","indexes","fields","unique"],"mappings":";;;;;;AAAA,SACEA,KAAK,EACLC,KAAK,EACLC,MAAM,EACNC,QAAQ,EACRC,OAAO,EACPC,UAAU,EACVC,UAAU,EACVC,SAAS,EACTC,KAAK,QACA,uBAAuB;AAE9B,SAASC,MAAM,QAAQ,cAAc;AACrC,SAASC,UAAU,QAAQ,kBAAkB;AAyB7C,OAAO,MAAMC,yBAAyBV;AAiCtC;;;qBA5BoBW;oBACDC;;;;mBAICJ;;QACRK,MAAMX,SAASU,IAAI;QAAEE,WAAW;;;;kBAGzBN;QAAUO,YAAY;QAAcC,UAAU;;;;;mBAI7CP;;QACRI,MAAMX,SAASU,IAAI;QAAEE,WAAW;;;;kBAGzBL;QAAcM,YAAY;QAAkBC,UAAU;;;;;QAG7DH,MAAMX,SAASe,KAAK;QAAEH,WAAW;;;;;QAGjCD,MAAMX,SAASe,KAAK;QAAEH,WAAW;;;;;QAGjCD,MAAMX,SAASgB,MAAM,CAAC;QAAMJ,WAAW;;;;;QAvCjDK,YAAY;QACZC,SAAS;YACP;gBACEC,QAAQ;oBAAC;oBAAc;iBAAiB;gBACxCC,QAAQ;YACV;SACD"}
@@ -1,44 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { BelongsToMany, Column, DataType, Default, HasMany, Model, PrimaryKey, Table } from "sequelize-typescript";
8
- import { Recipe } from "./Recipe.js";
9
- import { RecipeTags } from "./RecipeTags.js";
10
- import { TranslatedRecipeTag } from "./TranslatedRecipeTag.js";
11
- export class RecipeTag extends Model {
12
- }
13
- _ts_decorate([
14
- PrimaryKey,
15
- Default(DataType.UUIDV4),
16
- Column(DataType.UUID)
17
- ], RecipeTag.prototype, "uuid", void 0);
18
- _ts_decorate([
19
- Column({
20
- type: DataType.TEXT,
21
- allowNull: false
22
- })
23
- ], RecipeTag.prototype, "tag", void 0);
24
- _ts_decorate([
25
- Column({
26
- type: DataType.INTEGER,
27
- allowNull: false
28
- })
29
- ], RecipeTag.prototype, "order", void 0);
30
- _ts_decorate([
31
- BelongsToMany(()=>Recipe, {
32
- through: ()=>RecipeTags
33
- })
34
- ], RecipeTag.prototype, "recipes", void 0);
35
- _ts_decorate([
36
- HasMany(()=>TranslatedRecipeTag)
37
- ], RecipeTag.prototype, "translatedRecipeTags", void 0);
38
- RecipeTag = _ts_decorate([
39
- Table({
40
- tableName: "RecipeTag"
41
- })
42
- ], RecipeTag);
43
-
44
- //# sourceMappingURL=RecipeTag.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/RecipeTag.ts"],"sourcesContent":["import {\n BelongsToMany,\n Column,\n DataType,\n Default,\n HasMany,\n Model,\n PrimaryKey,\n Table,\n} from \"sequelize-typescript\";\nimport { Recipe } from \"./Recipe.js\";\nimport { RecipeTags } from \"./RecipeTags.js\";\nimport { TranslatedRecipeTag } from \"./TranslatedRecipeTag.js\";\n\n@Table({ tableName: \"RecipeTag\" })\nexport class RecipeTag extends Model {\n @PrimaryKey\n @Default(DataType.UUIDV4)\n @Column(DataType.UUID)\n declare uuid: string;\n\n @Column({ type: DataType.TEXT, allowNull: false })\n declare tag: string;\n\n @Column({ type: DataType.INTEGER, allowNull: false })\n declare order: number;\n\n @BelongsToMany(() => Recipe, { through: () => RecipeTags })\n declare recipes: Recipe[];\n\n @HasMany(() => TranslatedRecipeTag)\n declare translatedRecipeTags: TranslatedRecipeTag[];\n}\n"],"names":["BelongsToMany","Column","DataType","Default","HasMany","Model","PrimaryKey","Table","Recipe","RecipeTags","TranslatedRecipeTag","RecipeTag","UUIDV4","UUID","type","TEXT","allowNull","INTEGER","through","tableName"],"mappings":";;;;;;AAAA,SACEA,aAAa,EACbC,MAAM,EACNC,QAAQ,EACRC,OAAO,EACPC,OAAO,EACPC,KAAK,EACLC,UAAU,EACVC,KAAK,QACA,uBAAuB;AAC9B,SAASC,MAAM,QAAQ,cAAc;AACrC,SAASC,UAAU,QAAQ,kBAAkB;AAC7C,SAASC,mBAAmB,QAAQ,2BAA2B;AAG/D,OAAO,MAAMC,kBAAkBN;AAiB/B;;;qBAfoBO;oBACDC;;;;QAGPC,MAAMZ,SAASa,IAAI;QAAEC,WAAW;;;;;QAGhCF,MAAMZ,SAASe,OAAO;QAAED,WAAW;;;;sBAGxBR;QAAUU,SAAS,IAAMT;;;;gBAG/BC;;;;QAhBRS,WAAW"}
@@ -1,24 +0,0 @@
1
- function _ts_decorate(decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- }
7
- import { Column, DataType, ForeignKey, Model, Table } from "sequelize-typescript";
8
- import { Recipe } from "./Recipe.js";
9
- import { RecipeTag } from "./RecipeTag.js";
10
- export class RecipeTags extends Model {
11
- }
12
- _ts_decorate([
13
- ForeignKey(()=>Recipe),
14
- Column(DataType.UUID)
15
- ], RecipeTags.prototype, "recipeUuid", void 0);
16
- _ts_decorate([
17
- ForeignKey(()=>RecipeTag),
18
- Column(DataType.UUID)
19
- ], RecipeTags.prototype, "recipeTagUuid", void 0);
20
- RecipeTags = _ts_decorate([
21
- Table
22
- ], RecipeTags);
23
-
24
- //# sourceMappingURL=RecipeTags.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/lib/dbmodels/diet/RecipeTags.ts"],"sourcesContent":["import {\n Column,\n DataType,\n ForeignKey,\n Model,\n Table,\n} from \"sequelize-typescript\";\nimport { Recipe } from \"./Recipe.js\";\nimport { RecipeTag } from \"./RecipeTag.js\";\n\n@Table\nexport class RecipeTags extends Model<RecipeTags> {\n @ForeignKey(() => Recipe)\n @Column(DataType.UUID)\n declare recipeUuid: string;\n\n @ForeignKey(() => RecipeTag)\n @Column(DataType.UUID)\n declare recipeTagUuid: string;\n}\n"],"names":["Column","DataType","ForeignKey","Model","Table","Recipe","RecipeTag","RecipeTags","UUID"],"mappings":";;;;;;AAAA,SACEA,MAAM,EACNC,QAAQ,EACRC,UAAU,EACVC,KAAK,EACLC,KAAK,QACA,uBAAuB;AAC9B,SAASC,MAAM,QAAQ,cAAc;AACrC,SAASC,SAAS,QAAQ,iBAAiB;AAG3C,OAAO,MAAMC,mBAAmBJ;AAQhC;;mBAPoBE;oBACDG;;;mBAGCF;oBACDE"}