@stamhoofd/models 2.118.1 → 2.120.0

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 (1025) hide show
  1. package/dist/factories/AddressFactory.d.ts.map +1 -0
  2. package/dist/factories/AddressFactory.js +38 -0
  3. package/dist/factories/AddressFactory.js.map +1 -0
  4. package/dist/factories/BalanceItemFactory.d.ts +29 -0
  5. package/dist/factories/BalanceItemFactory.d.ts.map +1 -0
  6. package/dist/factories/BalanceItemFactory.js +56 -0
  7. package/dist/factories/BalanceItemFactory.js.map +1 -0
  8. package/dist/factories/DocumentTemplateFactory.d.ts +22 -0
  9. package/dist/factories/DocumentTemplateFactory.d.ts.map +1 -0
  10. package/dist/factories/DocumentTemplateFactory.js +145 -0
  11. package/dist/factories/DocumentTemplateFactory.js.map +1 -0
  12. package/dist/factories/EmailTemplateFactory.d.ts +18 -0
  13. package/dist/factories/EmailTemplateFactory.d.ts.map +1 -0
  14. package/dist/factories/EmailTemplateFactory.js +39 -0
  15. package/dist/factories/EmailTemplateFactory.js.map +1 -0
  16. package/dist/factories/EmergencyContactFactory.d.ts.map +1 -0
  17. package/dist/factories/EmergencyContactFactory.js +38 -0
  18. package/dist/factories/EmergencyContactFactory.js.map +1 -0
  19. package/dist/factories/EventFactory.d.ts +19 -0
  20. package/dist/factories/EventFactory.d.ts.map +1 -0
  21. package/dist/factories/EventFactory.js +31 -0
  22. package/dist/factories/EventFactory.js.map +1 -0
  23. package/dist/factories/EventNotificationFactory.d.ts +23 -0
  24. package/dist/factories/EventNotificationFactory.d.ts.map +1 -0
  25. package/dist/factories/EventNotificationFactory.js +40 -0
  26. package/dist/factories/EventNotificationFactory.js.map +1 -0
  27. package/dist/factories/EventNotificationTypeFactory.d.ts +12 -0
  28. package/dist/factories/EventNotificationTypeFactory.d.ts.map +1 -0
  29. package/dist/factories/EventNotificationTypeFactory.js +21 -0
  30. package/dist/factories/EventNotificationTypeFactory.js.map +1 -0
  31. package/dist/factories/GroupFactory.d.ts +27 -0
  32. package/dist/factories/GroupFactory.d.ts.map +1 -0
  33. package/dist/factories/GroupFactory.js +88 -0
  34. package/dist/factories/GroupFactory.js.map +1 -0
  35. package/dist/factories/MemberFactory.d.ts +26 -0
  36. package/dist/factories/MemberFactory.d.ts.map +1 -0
  37. package/dist/factories/MemberFactory.js +131 -0
  38. package/dist/factories/MemberFactory.js.map +1 -0
  39. package/dist/factories/MemberResponsibilityRecordFactory.d.ts +15 -0
  40. package/dist/factories/MemberResponsibilityRecordFactory.d.ts.map +1 -0
  41. package/dist/factories/MemberResponsibilityRecordFactory.js +30 -0
  42. package/dist/factories/MemberResponsibilityRecordFactory.js.map +1 -0
  43. package/dist/factories/OrganizationFactory.d.ts +20 -0
  44. package/dist/factories/OrganizationFactory.d.ts.map +1 -0
  45. package/dist/factories/OrganizationFactory.js +61 -0
  46. package/dist/factories/OrganizationFactory.js.map +1 -0
  47. package/dist/factories/OrganizationRegistrationPeriodFactory.d.ts +13 -0
  48. package/dist/factories/OrganizationRegistrationPeriodFactory.d.ts.map +1 -0
  49. package/dist/factories/OrganizationRegistrationPeriodFactory.js +16 -0
  50. package/dist/factories/OrganizationRegistrationPeriodFactory.js.map +1 -0
  51. package/dist/factories/OrganizationTagFactory.d.ts.map +1 -0
  52. package/dist/factories/OrganizationTagFactory.js +19 -0
  53. package/dist/factories/OrganizationTagFactory.js.map +1 -0
  54. package/dist/factories/ParentFactory.d.ts.map +1 -0
  55. package/dist/factories/ParentFactory.js +39 -0
  56. package/dist/factories/ParentFactory.js.map +1 -0
  57. package/dist/factories/PlatformEventTypeFactory.d.ts.map +1 -0
  58. package/dist/factories/PlatformEventTypeFactory.js +23 -0
  59. package/dist/factories/PlatformEventTypeFactory.js.map +1 -0
  60. package/dist/factories/PlatformResponsibilityFactory.d.ts.map +1 -0
  61. package/dist/factories/PlatformResponsibilityFactory.js +21 -0
  62. package/dist/factories/PlatformResponsibilityFactory.js.map +1 -0
  63. package/dist/factories/RecordAnswerFactory.d.ts +18 -0
  64. package/dist/factories/RecordAnswerFactory.d.ts.map +1 -0
  65. package/dist/factories/RecordAnswerFactory.js +91 -0
  66. package/dist/factories/RecordAnswerFactory.js.map +1 -0
  67. package/dist/factories/RecordCategoryFactory.d.ts +11 -0
  68. package/dist/factories/RecordCategoryFactory.d.ts.map +1 -0
  69. package/dist/factories/RecordCategoryFactory.js +19 -0
  70. package/dist/factories/RecordCategoryFactory.js.map +1 -0
  71. package/dist/factories/RecordFactory.d.ts.map +1 -0
  72. package/dist/factories/RecordFactory.js +16 -0
  73. package/dist/factories/RecordFactory.js.map +1 -0
  74. package/dist/factories/RegisterCodeFactory.d.ts.map +1 -0
  75. package/dist/factories/RegisterCodeFactory.js +14 -0
  76. package/dist/factories/RegisterCodeFactory.js.map +1 -0
  77. package/dist/factories/RegistrationFactory.d.ts +21 -0
  78. package/dist/factories/RegistrationFactory.d.ts.map +1 -0
  79. package/dist/factories/RegistrationFactory.js +21 -0
  80. package/dist/factories/RegistrationFactory.js.map +1 -0
  81. package/dist/factories/RegistrationPeriodFactory.d.ts +16 -0
  82. package/dist/factories/RegistrationPeriodFactory.d.ts.map +1 -0
  83. package/dist/factories/RegistrationPeriodFactory.js +30 -0
  84. package/dist/factories/RegistrationPeriodFactory.js.map +1 -0
  85. package/dist/factories/STPackageFactory.d.ts +15 -0
  86. package/dist/factories/STPackageFactory.d.ts.map +1 -0
  87. package/dist/factories/STPackageFactory.js +34 -0
  88. package/dist/factories/STPackageFactory.js.map +1 -0
  89. package/dist/factories/UserFactory.d.ts +22 -0
  90. package/dist/factories/UserFactory.d.ts.map +1 -0
  91. package/dist/factories/UserFactory.js +63 -0
  92. package/dist/factories/UserFactory.js.map +1 -0
  93. package/dist/factories/WebshopFactory.d.ts +17 -0
  94. package/dist/factories/WebshopFactory.d.ts.map +1 -0
  95. package/dist/factories/WebshopFactory.js +35 -0
  96. package/dist/factories/WebshopFactory.js.map +1 -0
  97. package/dist/factories/index.d.ts.map +1 -0
  98. package/dist/factories/index.js +27 -0
  99. package/dist/factories/index.js.map +1 -0
  100. package/dist/helpers/DNSValidator.d.ts +6 -0
  101. package/dist/helpers/DNSValidator.d.ts.map +1 -0
  102. package/dist/helpers/DNSValidator.js +142 -0
  103. package/dist/helpers/DNSValidator.js.map +1 -0
  104. package/dist/helpers/EmailBuilder.d.ts +88 -0
  105. package/dist/helpers/EmailBuilder.d.ts.map +1 -0
  106. package/dist/helpers/EmailBuilder.js +603 -0
  107. package/dist/helpers/EmailBuilder.js.map +1 -0
  108. package/dist/helpers/Handlebars.d.ts.map +1 -0
  109. package/dist/helpers/Handlebars.js +244 -0
  110. package/dist/helpers/Handlebars.js.map +1 -0
  111. package/dist/helpers/MemberMerger.d.ts.map +1 -0
  112. package/dist/helpers/MemberMerger.js +364 -0
  113. package/dist/helpers/MemberMerger.js.map +1 -0
  114. package/dist/helpers/RateLimiter.d.ts.map +1 -0
  115. package/dist/helpers/RateLimiter.js +64 -0
  116. package/dist/helpers/RateLimiter.js.map +1 -0
  117. package/dist/helpers/WebshopCounter.d.ts +8 -0
  118. package/dist/helpers/WebshopCounter.d.ts.map +1 -0
  119. package/dist/helpers/WebshopCounter.js +46 -0
  120. package/dist/helpers/WebshopCounter.js.map +1 -0
  121. package/dist/index.d.ts.map +1 -0
  122. package/dist/index.js +11 -0
  123. package/dist/index.js.map +1 -0
  124. package/dist/migrations/1605262045-import-postcodes.d.ts.map +1 -0
  125. package/dist/migrations/1605262045-import-postcodes.js +117 -0
  126. package/dist/migrations/1605262045-import-postcodes.js.map +1 -0
  127. package/dist/migrations/1605262046-import-postcodes-nl.d.ts.map +1 -0
  128. package/dist/migrations/1605262046-import-postcodes-nl.js +80 -0
  129. package/dist/migrations/1605262046-import-postcodes-nl.js.map +1 -0
  130. package/dist/migrations/1720080976-convert-charset-leads.d.ts +10 -0
  131. package/dist/migrations/1720080976-convert-charset-leads.d.ts.map +1 -0
  132. package/dist/migrations/1720080976-convert-charset-leads.js +41 -0
  133. package/dist/migrations/1720080976-convert-charset-leads.js.map +1 -0
  134. package/dist/models/AuditLog.d.ts.map +1 -0
  135. package/dist/models/AuditLog.js +94 -0
  136. package/dist/models/AuditLog.js.map +1 -0
  137. package/dist/models/BalanceItem.d.ts +218 -0
  138. package/dist/models/BalanceItem.d.ts.map +1 -0
  139. package/dist/models/BalanceItem.js +626 -0
  140. package/dist/models/BalanceItem.js.map +1 -0
  141. package/dist/models/BalanceItemPayment.d.ts +24 -0
  142. package/dist/models/BalanceItemPayment.d.ts.map +1 -0
  143. package/dist/models/BalanceItemPayment.js +65 -0
  144. package/dist/models/BalanceItemPayment.js.map +1 -0
  145. package/dist/models/BuckarooPayment.d.ts.map +1 -0
  146. package/dist/models/BuckarooPayment.js +24 -0
  147. package/dist/models/BuckarooPayment.js.map +1 -0
  148. package/dist/models/CachedBalance.d.ts +51 -0
  149. package/dist/models/CachedBalance.d.ts.map +1 -0
  150. package/dist/models/CachedBalance.js +390 -0
  151. package/dist/models/CachedBalance.js.map +1 -0
  152. package/dist/models/Document.d.ts +41 -0
  153. package/dist/models/Document.d.ts.map +1 -0
  154. package/dist/models/Document.js +251 -0
  155. package/dist/models/Document.js.map +1 -0
  156. package/dist/models/DocumentTemplate.d.ts +56 -0
  157. package/dist/models/DocumentTemplate.d.ts.map +1 -0
  158. package/dist/models/DocumentTemplate.js +719 -0
  159. package/dist/models/DocumentTemplate.js.map +1 -0
  160. package/dist/models/Email.d.ts +141 -0
  161. package/dist/models/Email.d.ts.map +1 -0
  162. package/dist/models/Email.js +1341 -0
  163. package/dist/models/Email.js.map +1 -0
  164. package/dist/models/EmailRecipient.d.ts.map +1 -0
  165. package/dist/models/EmailRecipient.js +194 -0
  166. package/dist/models/EmailRecipient.js.map +1 -0
  167. package/dist/models/EmailTemplate.d.ts +24 -0
  168. package/dist/models/EmailTemplate.d.ts.map +1 -0
  169. package/dist/models/EmailTemplate.js +79 -0
  170. package/dist/models/EmailTemplate.js.map +1 -0
  171. package/dist/models/EmailVerificationCode.d.ts +61 -0
  172. package/dist/models/EmailVerificationCode.d.ts.map +1 -0
  173. package/dist/models/EmailVerificationCode.js +339 -0
  174. package/dist/models/EmailVerificationCode.js.map +1 -0
  175. package/dist/models/Event.d.ts.map +1 -0
  176. package/dist/models/Event.js +132 -0
  177. package/dist/models/Event.js.map +1 -0
  178. package/dist/models/EventNotification.d.ts +32 -0
  179. package/dist/models/EventNotification.d.ts.map +1 -0
  180. package/dist/models/EventNotification.js +98 -0
  181. package/dist/models/EventNotification.js.map +1 -0
  182. package/dist/models/Group.d.ts +46 -0
  183. package/dist/models/Group.d.ts.map +1 -0
  184. package/dist/models/Group.js +213 -0
  185. package/dist/models/Group.js.map +1 -0
  186. package/dist/models/Image.d.ts +17 -0
  187. package/dist/models/Image.d.ts.map +1 -0
  188. package/dist/models/Image.js +169 -0
  189. package/dist/models/Image.js.map +1 -0
  190. package/dist/models/Invoice.d.ts.map +1 -0
  191. package/dist/models/Invoice.js +186 -0
  192. package/dist/models/Invoice.js.map +1 -0
  193. package/dist/models/InvoicedBalanceItem.d.ts +66 -0
  194. package/dist/models/InvoicedBalanceItem.d.ts.map +1 -0
  195. package/dist/models/InvoicedBalanceItem.js +130 -0
  196. package/dist/models/InvoicedBalanceItem.js.map +1 -0
  197. package/dist/models/Member.d.ts +114 -0
  198. package/dist/models/Member.d.ts.map +1 -0
  199. package/dist/models/Member.js +415 -0
  200. package/dist/models/Member.js.map +1 -0
  201. package/dist/models/MemberPlatformMembership.d.ts +48 -0
  202. package/dist/models/MemberPlatformMembership.d.ts.map +1 -0
  203. package/dist/models/MemberPlatformMembership.js +377 -0
  204. package/dist/models/MemberPlatformMembership.js.map +1 -0
  205. package/dist/models/MemberResponsibilityRecord.d.ts +17 -0
  206. package/dist/models/MemberResponsibilityRecord.d.ts.map +1 -0
  207. package/dist/models/MemberResponsibilityRecord.js +65 -0
  208. package/dist/models/MemberResponsibilityRecord.js.map +1 -0
  209. package/dist/models/MemberUser.d.ts.map +1 -0
  210. package/dist/models/MemberUser.js +22 -0
  211. package/dist/models/MemberUser.js.map +1 -0
  212. package/dist/models/MergedMember.d.ts +23 -0
  213. package/dist/models/MergedMember.d.ts.map +1 -0
  214. package/dist/models/MergedMember.js +123 -0
  215. package/dist/models/MergedMember.js.map +1 -0
  216. package/dist/models/MolliePayment.d.ts.map +1 -0
  217. package/dist/models/MolliePayment.js +24 -0
  218. package/dist/models/MolliePayment.js.map +1 -0
  219. package/dist/models/MollieToken.d.ts +45 -0
  220. package/dist/models/MollieToken.d.ts.map +1 -0
  221. package/dist/models/MollieToken.js +330 -0
  222. package/dist/models/MollieToken.js.map +1 -0
  223. package/dist/models/OneTimeToken.d.ts +38 -0
  224. package/dist/models/OneTimeToken.d.ts.map +1 -0
  225. package/dist/models/OneTimeToken.js +125 -0
  226. package/dist/models/OneTimeToken.js.map +1 -0
  227. package/dist/models/Order.d.ts +115 -0
  228. package/dist/models/Order.d.ts.map +1 -0
  229. package/dist/models/Order.js +908 -0
  230. package/dist/models/Order.js.map +1 -0
  231. package/dist/models/Organization.d.ts +128 -0
  232. package/dist/models/Organization.d.ts.map +1 -0
  233. package/dist/models/Organization.js +846 -0
  234. package/dist/models/Organization.js.map +1 -0
  235. package/dist/models/OrganizationRegistrationPeriod.d.ts +22 -0
  236. package/dist/models/OrganizationRegistrationPeriod.d.ts.map +1 -0
  237. package/dist/models/OrganizationRegistrationPeriod.js +129 -0
  238. package/dist/models/OrganizationRegistrationPeriod.js.map +1 -0
  239. package/dist/models/PasswordToken.d.ts +31 -0
  240. package/dist/models/PasswordToken.d.ts.map +1 -0
  241. package/dist/models/PasswordToken.js +129 -0
  242. package/dist/models/PasswordToken.js.map +1 -0
  243. package/dist/models/PayconiqPayment.d.ts +24 -0
  244. package/dist/models/PayconiqPayment.d.ts.map +1 -0
  245. package/dist/models/PayconiqPayment.js +272 -0
  246. package/dist/models/PayconiqPayment.js.map +1 -0
  247. package/dist/models/Payment.d.ts +120 -0
  248. package/dist/models/Payment.d.ts.map +1 -0
  249. package/dist/models/Payment.js +289 -0
  250. package/dist/models/Payment.js.map +1 -0
  251. package/dist/models/Platform.d.ts.map +1 -0
  252. package/dist/models/Platform.js +178 -0
  253. package/dist/models/Platform.js.map +1 -0
  254. package/dist/models/RegisterCode.d.ts.map +1 -0
  255. package/dist/models/RegisterCode.js +76 -0
  256. package/dist/models/RegisterCode.js.map +1 -0
  257. package/dist/models/Registration.d.ts +85 -0
  258. package/dist/models/Registration.d.ts.map +1 -0
  259. package/dist/models/Registration.js +190 -0
  260. package/dist/models/Registration.js.map +1 -0
  261. package/dist/models/RegistrationPeriod.d.ts.map +1 -0
  262. package/dist/models/RegistrationPeriod.js +140 -0
  263. package/dist/models/RegistrationPeriod.js.map +1 -0
  264. package/dist/models/STCredit.d.ts.map +1 -0
  265. package/dist/models/STCredit.js +61 -0
  266. package/dist/models/STCredit.js.map +1 -0
  267. package/dist/models/STInvoice.d.ts +37 -0
  268. package/dist/models/STInvoice.d.ts.map +1 -0
  269. package/dist/models/STInvoice.js +139 -0
  270. package/dist/models/STInvoice.js.map +1 -0
  271. package/dist/models/STPackage.d.ts.map +1 -0
  272. package/dist/models/STPackage.js +276 -0
  273. package/dist/models/STPackage.js.map +1 -0
  274. package/dist/models/STPendingInvoice.d.ts +26 -0
  275. package/dist/models/STPendingInvoice.d.ts.map +1 -0
  276. package/dist/models/STPendingInvoice.js +68 -0
  277. package/dist/models/STPendingInvoice.js.map +1 -0
  278. package/dist/models/StripeAccount.d.ts.map +1 -0
  279. package/dist/models/StripeAccount.js +81 -0
  280. package/dist/models/StripeAccount.js.map +1 -0
  281. package/dist/models/StripeCheckoutSession.d.ts.map +1 -0
  282. package/dist/models/StripeCheckoutSession.js +35 -0
  283. package/dist/models/StripeCheckoutSession.js.map +1 -0
  284. package/dist/models/StripePaymentIntent.d.ts.map +1 -0
  285. package/dist/models/StripePaymentIntent.js +35 -0
  286. package/dist/models/StripePaymentIntent.js.map +1 -0
  287. package/dist/models/Ticket.d.ts +65 -0
  288. package/dist/models/Ticket.d.ts.map +1 -0
  289. package/dist/models/Ticket.js +157 -0
  290. package/dist/models/Ticket.js.map +1 -0
  291. package/dist/models/Token.d.ts +48 -0
  292. package/dist/models/Token.d.ts.map +1 -0
  293. package/dist/models/Token.js +208 -0
  294. package/dist/models/Token.js.map +1 -0
  295. package/dist/models/UitpasClientCredential.d.ts.map +1 -0
  296. package/dist/models/UitpasClientCredential.js +62 -0
  297. package/dist/models/UitpasClientCredential.js.map +1 -0
  298. package/dist/models/UsedRegisterCode.d.ts.map +1 -0
  299. package/dist/models/UsedRegisterCode.js +58 -0
  300. package/dist/models/UsedRegisterCode.js.map +1 -0
  301. package/dist/models/User.d.ts +76 -0
  302. package/dist/models/User.d.ts.map +1 -0
  303. package/dist/models/User.js +484 -0
  304. package/dist/models/User.js.map +1 -0
  305. package/dist/models/UserPermissions.d.ts +16 -0
  306. package/dist/models/UserPermissions.d.ts.map +1 -0
  307. package/dist/models/UserPermissions.js +56 -0
  308. package/dist/models/UserPermissions.js.map +1 -0
  309. package/dist/models/Webshop.d.ts +45 -0
  310. package/dist/models/Webshop.d.ts.map +1 -0
  311. package/dist/models/Webshop.js +187 -0
  312. package/dist/models/Webshop.js.map +1 -0
  313. package/dist/models/WebshopDiscountCode.d.ts.map +1 -0
  314. package/dist/models/WebshopDiscountCode.js +89 -0
  315. package/dist/models/WebshopDiscountCode.js.map +1 -0
  316. package/dist/models/WebshopUitpasNumber.d.ts.map +1 -0
  317. package/dist/models/WebshopUitpasNumber.js +91 -0
  318. package/dist/models/WebshopUitpasNumber.js.map +1 -0
  319. package/dist/models/_relations.d.ts +8 -0
  320. package/dist/models/_relations.d.ts.map +1 -0
  321. package/dist/models/_relations.js +110 -0
  322. package/dist/models/_relations.js.map +1 -0
  323. package/dist/models/addresses/City.d.ts +15 -0
  324. package/dist/models/addresses/City.d.ts.map +1 -0
  325. package/dist/models/addresses/City.js +35 -0
  326. package/dist/models/addresses/City.js.map +1 -0
  327. package/dist/models/addresses/PostalCode.d.ts +21 -0
  328. package/dist/models/addresses/PostalCode.d.ts.map +1 -0
  329. package/dist/models/addresses/PostalCode.js +139 -0
  330. package/dist/models/addresses/PostalCode.js.map +1 -0
  331. package/dist/models/addresses/Province.d.ts +9 -0
  332. package/dist/models/addresses/Province.d.ts.map +1 -0
  333. package/dist/models/addresses/Province.js +24 -0
  334. package/dist/models/addresses/Province.js.map +1 -0
  335. package/dist/models/addresses/Street.d.ts.map +1 -0
  336. package/dist/models/addresses/Street.js +26 -0
  337. package/dist/models/addresses/Street.js.map +1 -0
  338. package/dist/models/index.d.ts +55 -0
  339. package/dist/models/index.d.ts.map +1 -0
  340. package/dist/models/index.js +55 -0
  341. package/dist/models/index.js.map +1 -0
  342. package/dist/structures/OrganizationServerMetaData.d.ts.map +1 -0
  343. package/dist/structures/OrganizationServerMetaData.js +130 -0
  344. package/dist/structures/OrganizationServerMetaData.js.map +1 -0
  345. package/package.json +13 -10
  346. package/src/factories/AddressFactory.ts +3 -2
  347. package/src/factories/BalanceItemFactory.ts +2 -1
  348. package/src/factories/DocumentTemplateFactory.ts +2 -1
  349. package/src/factories/EmailTemplateFactory.ts +3 -2
  350. package/src/factories/EmergencyContactFactory.ts +1 -1
  351. package/src/factories/EventFactory.ts +2 -2
  352. package/src/factories/EventNotificationFactory.ts +6 -4
  353. package/src/factories/EventNotificationTypeFactory.ts +3 -2
  354. package/src/factories/GroupFactory.ts +4 -3
  355. package/src/factories/MemberFactory.ts +6 -5
  356. package/src/factories/MemberResponsibilityRecordFactory.ts +3 -2
  357. package/src/factories/OrganizationFactory.ts +4 -2
  358. package/src/factories/OrganizationRegistrationPeriodFactory.ts +2 -2
  359. package/src/factories/ParentFactory.ts +1 -1
  360. package/src/factories/RecordAnswerFactory.ts +2 -1
  361. package/src/factories/RecordCategoryFactory.ts +4 -2
  362. package/src/factories/RegistrationFactory.ts +5 -4
  363. package/src/factories/RegistrationPeriodFactory.ts +2 -1
  364. package/src/factories/STPackageFactory.ts +1 -1
  365. package/src/factories/UserFactory.ts +3 -2
  366. package/src/factories/WebshopFactory.ts +3 -2
  367. package/src/helpers/DNSValidator.ts +10 -9
  368. package/src/helpers/EmailBuilder.ts +21 -12
  369. package/src/helpers/Handlebars.ts +3 -3
  370. package/src/helpers/MemberMerger.test.ts +1 -1
  371. package/src/helpers/MemberMerger.ts +5 -4
  372. package/src/helpers/WebshopCounter.ts +1 -1
  373. package/src/migrations/1605262045-import-postcodes.ts +1 -1
  374. package/src/migrations/1605262046-import-postcodes-nl.ts +2 -2
  375. package/src/migrations/1720080976-convert-charset-leads.ts +53 -0
  376. package/src/models/AuditLog.ts +2 -1
  377. package/src/models/BalanceItem.ts +4 -3
  378. package/src/models/BalanceItemPayment.ts +9 -6
  379. package/src/models/CachedBalance.test.ts +331 -0
  380. package/src/models/CachedBalance.ts +3 -2
  381. package/src/models/Document.ts +2 -2
  382. package/src/models/DocumentTemplate.ts +5 -3
  383. package/src/models/Email.test.ts +40 -39
  384. package/src/models/Email.ts +27 -24
  385. package/src/models/EmailTemplate.ts +2 -1
  386. package/src/models/EmailVerificationCode.ts +9 -7
  387. package/src/models/EventNotification.ts +3 -2
  388. package/src/models/Group.ts +5 -15
  389. package/src/models/Image.ts +3 -2
  390. package/src/models/InvoicedBalanceItem.ts +9 -8
  391. package/src/models/Member.ts +8 -4
  392. package/src/models/MemberPlatformMembership.ts +6 -6
  393. package/src/models/MemberResponsibilityRecord.ts +2 -1
  394. package/src/models/MergedMember.ts +1 -1
  395. package/src/models/MollieToken.ts +4 -4
  396. package/src/models/OneTimeToken.ts +1 -1
  397. package/src/models/Order.ts +20 -12
  398. package/src/models/Organization.ts +45 -17
  399. package/src/models/OrganizationRegistrationPeriod.ts +2 -2
  400. package/src/models/PasswordToken.ts +7 -5
  401. package/src/models/PayconiqPayment.ts +8 -5
  402. package/src/models/Payment.ts +8 -5
  403. package/src/models/Platform.ts +1 -1
  404. package/src/models/Registration.ts +9 -97
  405. package/src/models/STInvoice.ts +1 -4
  406. package/src/models/STPackage.ts +2 -2
  407. package/src/models/STPendingInvoice.ts +5 -4
  408. package/src/models/Ticket.ts +11 -9
  409. package/src/models/Token.test.ts +2 -2
  410. package/src/models/Token.ts +6 -6
  411. package/src/models/User.ts +9 -10
  412. package/src/models/UserPermissions.ts +7 -6
  413. package/src/models/Webshop.ts +5 -5
  414. package/src/models/_relations.ts +133 -0
  415. package/src/models/addresses/City.ts +1 -1
  416. package/src/models/addresses/PostalCode.test.ts +1 -1
  417. package/src/models/addresses/PostalCode.ts +2 -2
  418. package/src/models/addresses/Province.ts +1 -1
  419. package/src/models/index.ts +22 -20
  420. package/src/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -0
  421. package/dist/src/factories/AddressFactory.d.ts.map +0 -1
  422. package/dist/src/factories/AddressFactory.js +0 -42
  423. package/dist/src/factories/AddressFactory.js.map +0 -1
  424. package/dist/src/factories/BalanceItemFactory.d.ts +0 -28
  425. package/dist/src/factories/BalanceItemFactory.d.ts.map +0 -1
  426. package/dist/src/factories/BalanceItemFactory.js +0 -60
  427. package/dist/src/factories/BalanceItemFactory.js.map +0 -1
  428. package/dist/src/factories/DocumentTemplateFactory.d.ts +0 -21
  429. package/dist/src/factories/DocumentTemplateFactory.d.ts.map +0 -1
  430. package/dist/src/factories/DocumentTemplateFactory.js +0 -149
  431. package/dist/src/factories/DocumentTemplateFactory.js.map +0 -1
  432. package/dist/src/factories/EmailTemplateFactory.d.ts +0 -18
  433. package/dist/src/factories/EmailTemplateFactory.d.ts.map +0 -1
  434. package/dist/src/factories/EmailTemplateFactory.js +0 -43
  435. package/dist/src/factories/EmailTemplateFactory.js.map +0 -1
  436. package/dist/src/factories/EmergencyContactFactory.d.ts.map +0 -1
  437. package/dist/src/factories/EmergencyContactFactory.js +0 -42
  438. package/dist/src/factories/EmergencyContactFactory.js.map +0 -1
  439. package/dist/src/factories/EventFactory.d.ts +0 -19
  440. package/dist/src/factories/EventFactory.d.ts.map +0 -1
  441. package/dist/src/factories/EventFactory.js +0 -35
  442. package/dist/src/factories/EventFactory.js.map +0 -1
  443. package/dist/src/factories/EventNotificationFactory.d.ts +0 -21
  444. package/dist/src/factories/EventNotificationFactory.d.ts.map +0 -1
  445. package/dist/src/factories/EventNotificationFactory.js +0 -44
  446. package/dist/src/factories/EventNotificationFactory.js.map +0 -1
  447. package/dist/src/factories/EventNotificationTypeFactory.d.ts +0 -11
  448. package/dist/src/factories/EventNotificationTypeFactory.d.ts.map +0 -1
  449. package/dist/src/factories/EventNotificationTypeFactory.js +0 -25
  450. package/dist/src/factories/EventNotificationTypeFactory.js.map +0 -1
  451. package/dist/src/factories/GroupFactory.d.ts +0 -26
  452. package/dist/src/factories/GroupFactory.d.ts.map +0 -1
  453. package/dist/src/factories/GroupFactory.js +0 -92
  454. package/dist/src/factories/GroupFactory.js.map +0 -1
  455. package/dist/src/factories/MemberFactory.d.ts +0 -26
  456. package/dist/src/factories/MemberFactory.d.ts.map +0 -1
  457. package/dist/src/factories/MemberFactory.js +0 -135
  458. package/dist/src/factories/MemberFactory.js.map +0 -1
  459. package/dist/src/factories/MemberResponsibilityRecordFactory.d.ts +0 -14
  460. package/dist/src/factories/MemberResponsibilityRecordFactory.d.ts.map +0 -1
  461. package/dist/src/factories/MemberResponsibilityRecordFactory.js +0 -34
  462. package/dist/src/factories/MemberResponsibilityRecordFactory.js.map +0 -1
  463. package/dist/src/factories/OrganizationFactory.d.ts +0 -19
  464. package/dist/src/factories/OrganizationFactory.d.ts.map +0 -1
  465. package/dist/src/factories/OrganizationFactory.js +0 -64
  466. package/dist/src/factories/OrganizationFactory.js.map +0 -1
  467. package/dist/src/factories/OrganizationRegistrationPeriodFactory.d.ts +0 -13
  468. package/dist/src/factories/OrganizationRegistrationPeriodFactory.d.ts.map +0 -1
  469. package/dist/src/factories/OrganizationRegistrationPeriodFactory.js +0 -20
  470. package/dist/src/factories/OrganizationRegistrationPeriodFactory.js.map +0 -1
  471. package/dist/src/factories/OrganizationTagFactory.d.ts.map +0 -1
  472. package/dist/src/factories/OrganizationTagFactory.js +0 -23
  473. package/dist/src/factories/OrganizationTagFactory.js.map +0 -1
  474. package/dist/src/factories/ParentFactory.d.ts.map +0 -1
  475. package/dist/src/factories/ParentFactory.js +0 -43
  476. package/dist/src/factories/ParentFactory.js.map +0 -1
  477. package/dist/src/factories/PlatformEventTypeFactory.d.ts.map +0 -1
  478. package/dist/src/factories/PlatformEventTypeFactory.js +0 -27
  479. package/dist/src/factories/PlatformEventTypeFactory.js.map +0 -1
  480. package/dist/src/factories/PlatformResponsibilityFactory.d.ts.map +0 -1
  481. package/dist/src/factories/PlatformResponsibilityFactory.js +0 -25
  482. package/dist/src/factories/PlatformResponsibilityFactory.js.map +0 -1
  483. package/dist/src/factories/RecordAnswerFactory.d.ts +0 -17
  484. package/dist/src/factories/RecordAnswerFactory.d.ts.map +0 -1
  485. package/dist/src/factories/RecordAnswerFactory.js +0 -95
  486. package/dist/src/factories/RecordAnswerFactory.js.map +0 -1
  487. package/dist/src/factories/RecordCategoryFactory.d.ts +0 -11
  488. package/dist/src/factories/RecordCategoryFactory.d.ts.map +0 -1
  489. package/dist/src/factories/RecordCategoryFactory.js +0 -23
  490. package/dist/src/factories/RecordCategoryFactory.js.map +0 -1
  491. package/dist/src/factories/RecordFactory.d.ts.map +0 -1
  492. package/dist/src/factories/RecordFactory.js +0 -21
  493. package/dist/src/factories/RecordFactory.js.map +0 -1
  494. package/dist/src/factories/RegisterCodeFactory.d.ts.map +0 -1
  495. package/dist/src/factories/RegisterCodeFactory.js +0 -18
  496. package/dist/src/factories/RegisterCodeFactory.js.map +0 -1
  497. package/dist/src/factories/RegistrationFactory.d.ts +0 -21
  498. package/dist/src/factories/RegistrationFactory.d.ts.map +0 -1
  499. package/dist/src/factories/RegistrationFactory.js +0 -25
  500. package/dist/src/factories/RegistrationFactory.js.map +0 -1
  501. package/dist/src/factories/RegistrationPeriodFactory.d.ts +0 -15
  502. package/dist/src/factories/RegistrationPeriodFactory.d.ts.map +0 -1
  503. package/dist/src/factories/RegistrationPeriodFactory.js +0 -34
  504. package/dist/src/factories/RegistrationPeriodFactory.js.map +0 -1
  505. package/dist/src/factories/STPackageFactory.d.ts +0 -15
  506. package/dist/src/factories/STPackageFactory.d.ts.map +0 -1
  507. package/dist/src/factories/STPackageFactory.js +0 -38
  508. package/dist/src/factories/STPackageFactory.js.map +0 -1
  509. package/dist/src/factories/UserFactory.d.ts +0 -22
  510. package/dist/src/factories/UserFactory.d.ts.map +0 -1
  511. package/dist/src/factories/UserFactory.js +0 -67
  512. package/dist/src/factories/UserFactory.js.map +0 -1
  513. package/dist/src/factories/WebshopFactory.d.ts +0 -16
  514. package/dist/src/factories/WebshopFactory.d.ts.map +0 -1
  515. package/dist/src/factories/WebshopFactory.js +0 -39
  516. package/dist/src/factories/WebshopFactory.js.map +0 -1
  517. package/dist/src/factories/index.d.ts.map +0 -1
  518. package/dist/src/factories/index.js +0 -30
  519. package/dist/src/factories/index.js.map +0 -1
  520. package/dist/src/helpers/DNSValidator.d.ts +0 -6
  521. package/dist/src/helpers/DNSValidator.d.ts.map +0 -1
  522. package/dist/src/helpers/DNSValidator.js +0 -145
  523. package/dist/src/helpers/DNSValidator.js.map +0 -1
  524. package/dist/src/helpers/EmailBuilder.d.ts +0 -83
  525. package/dist/src/helpers/EmailBuilder.d.ts.map +0 -1
  526. package/dist/src/helpers/EmailBuilder.js +0 -646
  527. package/dist/src/helpers/EmailBuilder.js.map +0 -1
  528. package/dist/src/helpers/Handlebars.d.ts.map +0 -1
  529. package/dist/src/helpers/Handlebars.js +0 -248
  530. package/dist/src/helpers/Handlebars.js.map +0 -1
  531. package/dist/src/helpers/MemberMerger.d.ts.map +0 -1
  532. package/dist/src/helpers/MemberMerger.js +0 -371
  533. package/dist/src/helpers/MemberMerger.js.map +0 -1
  534. package/dist/src/helpers/MemberMerger.test.d.ts +0 -2
  535. package/dist/src/helpers/MemberMerger.test.d.ts.map +0 -1
  536. package/dist/src/helpers/MemberMerger.test.js +0 -644
  537. package/dist/src/helpers/MemberMerger.test.js.map +0 -1
  538. package/dist/src/helpers/RateLimiter.d.ts.map +0 -1
  539. package/dist/src/helpers/RateLimiter.js +0 -69
  540. package/dist/src/helpers/RateLimiter.js.map +0 -1
  541. package/dist/src/helpers/WebshopCounter.d.ts +0 -8
  542. package/dist/src/helpers/WebshopCounter.d.ts.map +0 -1
  543. package/dist/src/helpers/WebshopCounter.js +0 -50
  544. package/dist/src/helpers/WebshopCounter.js.map +0 -1
  545. package/dist/src/index.d.ts.map +0 -1
  546. package/dist/src/index.js +0 -14
  547. package/dist/src/index.js.map +0 -1
  548. package/dist/src/migrations/1605262045-import-postcodes.js +0 -121
  549. package/dist/src/migrations/1605262046-import-postcodes-nl.js +0 -83
  550. package/dist/src/models/AuditLog.d.ts.map +0 -1
  551. package/dist/src/models/AuditLog.js +0 -98
  552. package/dist/src/models/AuditLog.js.map +0 -1
  553. package/dist/src/models/BalanceItem.d.ts +0 -217
  554. package/dist/src/models/BalanceItem.d.ts.map +0 -1
  555. package/dist/src/models/BalanceItem.js +0 -630
  556. package/dist/src/models/BalanceItem.js.map +0 -1
  557. package/dist/src/models/BalanceItemPayment.d.ts +0 -23
  558. package/dist/src/models/BalanceItemPayment.d.ts.map +0 -1
  559. package/dist/src/models/BalanceItemPayment.js +0 -70
  560. package/dist/src/models/BalanceItemPayment.js.map +0 -1
  561. package/dist/src/models/BuckarooPayment.d.ts.map +0 -1
  562. package/dist/src/models/BuckarooPayment.js +0 -28
  563. package/dist/src/models/BuckarooPayment.js.map +0 -1
  564. package/dist/src/models/CachedBalance.d.ts +0 -50
  565. package/dist/src/models/CachedBalance.d.ts.map +0 -1
  566. package/dist/src/models/CachedBalance.js +0 -394
  567. package/dist/src/models/CachedBalance.js.map +0 -1
  568. package/dist/src/models/Document.d.ts +0 -41
  569. package/dist/src/models/Document.d.ts.map +0 -1
  570. package/dist/src/models/Document.js +0 -255
  571. package/dist/src/models/Document.js.map +0 -1
  572. package/dist/src/models/DocumentTemplate.d.ts +0 -55
  573. package/dist/src/models/DocumentTemplate.d.ts.map +0 -1
  574. package/dist/src/models/DocumentTemplate.js +0 -723
  575. package/dist/src/models/DocumentTemplate.js.map +0 -1
  576. package/dist/src/models/DocumentTemplate.test.d.ts +0 -2
  577. package/dist/src/models/DocumentTemplate.test.d.ts.map +0 -1
  578. package/dist/src/models/DocumentTemplate.test.js +0 -57
  579. package/dist/src/models/DocumentTemplate.test.js.map +0 -1
  580. package/dist/src/models/Email.d.ts +0 -140
  581. package/dist/src/models/Email.d.ts.map +0 -1
  582. package/dist/src/models/Email.js +0 -1345
  583. package/dist/src/models/Email.js.map +0 -1
  584. package/dist/src/models/Email.test.d.ts +0 -2
  585. package/dist/src/models/Email.test.d.ts.map +0 -1
  586. package/dist/src/models/Email.test.js +0 -1036
  587. package/dist/src/models/Email.test.js.map +0 -1
  588. package/dist/src/models/EmailRecipient.d.ts.map +0 -1
  589. package/dist/src/models/EmailRecipient.js +0 -198
  590. package/dist/src/models/EmailRecipient.js.map +0 -1
  591. package/dist/src/models/EmailTemplate.d.ts +0 -23
  592. package/dist/src/models/EmailTemplate.d.ts.map +0 -1
  593. package/dist/src/models/EmailTemplate.js +0 -83
  594. package/dist/src/models/EmailTemplate.js.map +0 -1
  595. package/dist/src/models/EmailVerificationCode.d.ts +0 -59
  596. package/dist/src/models/EmailVerificationCode.d.ts.map +0 -1
  597. package/dist/src/models/EmailVerificationCode.js +0 -343
  598. package/dist/src/models/EmailVerificationCode.js.map +0 -1
  599. package/dist/src/models/Event.d.ts.map +0 -1
  600. package/dist/src/models/Event.js +0 -136
  601. package/dist/src/models/Event.js.map +0 -1
  602. package/dist/src/models/EventNotification.d.ts +0 -31
  603. package/dist/src/models/EventNotification.d.ts.map +0 -1
  604. package/dist/src/models/EventNotification.js +0 -102
  605. package/dist/src/models/EventNotification.js.map +0 -1
  606. package/dist/src/models/Group.d.ts +0 -45
  607. package/dist/src/models/Group.d.ts.map +0 -1
  608. package/dist/src/models/Group.js +0 -228
  609. package/dist/src/models/Group.js.map +0 -1
  610. package/dist/src/models/Image.d.ts +0 -16
  611. package/dist/src/models/Image.d.ts.map +0 -1
  612. package/dist/src/models/Image.js +0 -173
  613. package/dist/src/models/Image.js.map +0 -1
  614. package/dist/src/models/Invoice.d.ts.map +0 -1
  615. package/dist/src/models/Invoice.js +0 -190
  616. package/dist/src/models/Invoice.js.map +0 -1
  617. package/dist/src/models/InvoicedBalanceItem.d.ts +0 -66
  618. package/dist/src/models/InvoicedBalanceItem.d.ts.map +0 -1
  619. package/dist/src/models/InvoicedBalanceItem.js +0 -136
  620. package/dist/src/models/InvoicedBalanceItem.js.map +0 -1
  621. package/dist/src/models/Member.d.ts +0 -112
  622. package/dist/src/models/Member.d.ts.map +0 -1
  623. package/dist/src/models/Member.js +0 -415
  624. package/dist/src/models/Member.js.map +0 -1
  625. package/dist/src/models/MemberPlatformMembership.d.ts +0 -48
  626. package/dist/src/models/MemberPlatformMembership.d.ts.map +0 -1
  627. package/dist/src/models/MemberPlatformMembership.js +0 -381
  628. package/dist/src/models/MemberPlatformMembership.js.map +0 -1
  629. package/dist/src/models/MemberResponsibilityRecord.d.ts +0 -16
  630. package/dist/src/models/MemberResponsibilityRecord.d.ts.map +0 -1
  631. package/dist/src/models/MemberResponsibilityRecord.js +0 -69
  632. package/dist/src/models/MemberResponsibilityRecord.js.map +0 -1
  633. package/dist/src/models/MemberUser.d.ts.map +0 -1
  634. package/dist/src/models/MemberUser.js +0 -26
  635. package/dist/src/models/MemberUser.js.map +0 -1
  636. package/dist/src/models/MergedMember.d.ts +0 -23
  637. package/dist/src/models/MergedMember.d.ts.map +0 -1
  638. package/dist/src/models/MergedMember.js +0 -127
  639. package/dist/src/models/MergedMember.js.map +0 -1
  640. package/dist/src/models/MolliePayment.d.ts.map +0 -1
  641. package/dist/src/models/MolliePayment.js +0 -28
  642. package/dist/src/models/MolliePayment.js.map +0 -1
  643. package/dist/src/models/MollieToken.d.ts +0 -45
  644. package/dist/src/models/MollieToken.d.ts.map +0 -1
  645. package/dist/src/models/MollieToken.js +0 -334
  646. package/dist/src/models/MollieToken.js.map +0 -1
  647. package/dist/src/models/OneTimeToken.d.ts +0 -38
  648. package/dist/src/models/OneTimeToken.d.ts.map +0 -1
  649. package/dist/src/models/OneTimeToken.js +0 -129
  650. package/dist/src/models/OneTimeToken.js.map +0 -1
  651. package/dist/src/models/Order.d.ts +0 -112
  652. package/dist/src/models/Order.d.ts.map +0 -1
  653. package/dist/src/models/Order.js +0 -906
  654. package/dist/src/models/Order.js.map +0 -1
  655. package/dist/src/models/Organization.d.ts +0 -120
  656. package/dist/src/models/Organization.d.ts.map +0 -1
  657. package/dist/src/models/Organization.js +0 -828
  658. package/dist/src/models/Organization.js.map +0 -1
  659. package/dist/src/models/OrganizationRegistrationPeriod.d.ts +0 -22
  660. package/dist/src/models/OrganizationRegistrationPeriod.d.ts.map +0 -1
  661. package/dist/src/models/OrganizationRegistrationPeriod.js +0 -133
  662. package/dist/src/models/OrganizationRegistrationPeriod.js.map +0 -1
  663. package/dist/src/models/PasswordToken.d.ts +0 -30
  664. package/dist/src/models/PasswordToken.d.ts.map +0 -1
  665. package/dist/src/models/PasswordToken.js +0 -133
  666. package/dist/src/models/PasswordToken.js.map +0 -1
  667. package/dist/src/models/PayconiqPayment.d.ts +0 -22
  668. package/dist/src/models/PayconiqPayment.d.ts.map +0 -1
  669. package/dist/src/models/PayconiqPayment.js +0 -276
  670. package/dist/src/models/PayconiqPayment.js.map +0 -1
  671. package/dist/src/models/Payment.d.ts +0 -117
  672. package/dist/src/models/Payment.d.ts.map +0 -1
  673. package/dist/src/models/Payment.js +0 -293
  674. package/dist/src/models/Payment.js.map +0 -1
  675. package/dist/src/models/Platform.d.ts.map +0 -1
  676. package/dist/src/models/Platform.js +0 -182
  677. package/dist/src/models/Platform.js.map +0 -1
  678. package/dist/src/models/Platform.test.d.ts +0 -2
  679. package/dist/src/models/Platform.test.d.ts.map +0 -1
  680. package/dist/src/models/Platform.test.js +0 -90
  681. package/dist/src/models/Platform.test.js.map +0 -1
  682. package/dist/src/models/RegisterCode.d.ts.map +0 -1
  683. package/dist/src/models/RegisterCode.js +0 -80
  684. package/dist/src/models/RegisterCode.js.map +0 -1
  685. package/dist/src/models/Registration.d.ts +0 -93
  686. package/dist/src/models/Registration.d.ts.map +0 -1
  687. package/dist/src/models/Registration.js +0 -267
  688. package/dist/src/models/Registration.js.map +0 -1
  689. package/dist/src/models/RegistrationPeriod.d.ts.map +0 -1
  690. package/dist/src/models/RegistrationPeriod.js +0 -144
  691. package/dist/src/models/RegistrationPeriod.js.map +0 -1
  692. package/dist/src/models/STCredit.d.ts.map +0 -1
  693. package/dist/src/models/STCredit.js +0 -65
  694. package/dist/src/models/STCredit.js.map +0 -1
  695. package/dist/src/models/STInvoice.d.ts +0 -37
  696. package/dist/src/models/STInvoice.d.ts.map +0 -1
  697. package/dist/src/models/STInvoice.js +0 -145
  698. package/dist/src/models/STInvoice.js.map +0 -1
  699. package/dist/src/models/STPackage.d.ts.map +0 -1
  700. package/dist/src/models/STPackage.js +0 -280
  701. package/dist/src/models/STPackage.js.map +0 -1
  702. package/dist/src/models/STPendingInvoice.d.ts +0 -26
  703. package/dist/src/models/STPendingInvoice.d.ts.map +0 -1
  704. package/dist/src/models/STPendingInvoice.js +0 -73
  705. package/dist/src/models/STPendingInvoice.js.map +0 -1
  706. package/dist/src/models/StripeAccount.d.ts.map +0 -1
  707. package/dist/src/models/StripeAccount.js +0 -85
  708. package/dist/src/models/StripeAccount.js.map +0 -1
  709. package/dist/src/models/StripeCheckoutSession.d.ts.map +0 -1
  710. package/dist/src/models/StripeCheckoutSession.js +0 -39
  711. package/dist/src/models/StripeCheckoutSession.js.map +0 -1
  712. package/dist/src/models/StripePaymentIntent.d.ts.map +0 -1
  713. package/dist/src/models/StripePaymentIntent.js +0 -39
  714. package/dist/src/models/StripePaymentIntent.js.map +0 -1
  715. package/dist/src/models/Ticket.d.ts +0 -63
  716. package/dist/src/models/Ticket.d.ts.map +0 -1
  717. package/dist/src/models/Ticket.js +0 -162
  718. package/dist/src/models/Ticket.js.map +0 -1
  719. package/dist/src/models/Token.d.ts +0 -48
  720. package/dist/src/models/Token.d.ts.map +0 -1
  721. package/dist/src/models/Token.js +0 -212
  722. package/dist/src/models/Token.js.map +0 -1
  723. package/dist/src/models/Token.test.d.ts +0 -2
  724. package/dist/src/models/Token.test.d.ts.map +0 -1
  725. package/dist/src/models/Token.test.js +0 -60
  726. package/dist/src/models/Token.test.js.map +0 -1
  727. package/dist/src/models/UitpasClientCredential.d.ts.map +0 -1
  728. package/dist/src/models/UitpasClientCredential.js +0 -66
  729. package/dist/src/models/UitpasClientCredential.js.map +0 -1
  730. package/dist/src/models/UsedRegisterCode.d.ts.map +0 -1
  731. package/dist/src/models/UsedRegisterCode.js +0 -62
  732. package/dist/src/models/UsedRegisterCode.js.map +0 -1
  733. package/dist/src/models/User.d.ts +0 -77
  734. package/dist/src/models/User.d.ts.map +0 -1
  735. package/dist/src/models/User.js +0 -490
  736. package/dist/src/models/User.js.map +0 -1
  737. package/dist/src/models/UserPermissions.d.ts +0 -16
  738. package/dist/src/models/UserPermissions.d.ts.map +0 -1
  739. package/dist/src/models/UserPermissions.js +0 -61
  740. package/dist/src/models/UserPermissions.js.map +0 -1
  741. package/dist/src/models/Webshop.d.ts +0 -45
  742. package/dist/src/models/Webshop.d.ts.map +0 -1
  743. package/dist/src/models/Webshop.js +0 -192
  744. package/dist/src/models/Webshop.js.map +0 -1
  745. package/dist/src/models/WebshopDiscountCode.d.ts.map +0 -1
  746. package/dist/src/models/WebshopDiscountCode.js +0 -93
  747. package/dist/src/models/WebshopDiscountCode.js.map +0 -1
  748. package/dist/src/models/WebshopUitpasNumber.d.ts.map +0 -1
  749. package/dist/src/models/WebshopUitpasNumber.js +0 -95
  750. package/dist/src/models/WebshopUitpasNumber.js.map +0 -1
  751. package/dist/src/models/addresses/City.d.ts +0 -15
  752. package/dist/src/models/addresses/City.d.ts.map +0 -1
  753. package/dist/src/models/addresses/City.js +0 -39
  754. package/dist/src/models/addresses/City.js.map +0 -1
  755. package/dist/src/models/addresses/PostalCode.d.ts +0 -21
  756. package/dist/src/models/addresses/PostalCode.d.ts.map +0 -1
  757. package/dist/src/models/addresses/PostalCode.js +0 -143
  758. package/dist/src/models/addresses/PostalCode.js.map +0 -1
  759. package/dist/src/models/addresses/PostalCode.test.d.ts +0 -2
  760. package/dist/src/models/addresses/PostalCode.test.d.ts.map +0 -1
  761. package/dist/src/models/addresses/PostalCode.test.js +0 -98
  762. package/dist/src/models/addresses/PostalCode.test.js.map +0 -1
  763. package/dist/src/models/addresses/Province.d.ts +0 -9
  764. package/dist/src/models/addresses/Province.d.ts.map +0 -1
  765. package/dist/src/models/addresses/Province.js +0 -28
  766. package/dist/src/models/addresses/Province.js.map +0 -1
  767. package/dist/src/models/addresses/Street.d.ts.map +0 -1
  768. package/dist/src/models/addresses/Street.js +0 -30
  769. package/dist/src/models/addresses/Street.js.map +0 -1
  770. package/dist/src/models/index.d.ts +0 -54
  771. package/dist/src/models/index.d.ts.map +0 -1
  772. package/dist/src/models/index.js +0 -69
  773. package/dist/src/models/index.js.map +0 -1
  774. package/dist/src/structures/OrganizationServerMetaData.d.ts.map +0 -1
  775. package/dist/src/structures/OrganizationServerMetaData.js +0 -135
  776. package/dist/src/structures/OrganizationServerMetaData.js.map +0 -1
  777. package/dist/tests/jest.global.setup.d.ts +0 -3
  778. package/dist/tests/jest.global.setup.d.ts.map +0 -1
  779. package/dist/tests/jest.global.setup.js +0 -33
  780. package/dist/tests/jest.global.setup.js.map +0 -1
  781. package/dist/tests/jest.setup.d.ts +0 -2
  782. package/dist/tests/jest.setup.d.ts.map +0 -1
  783. package/dist/tests/jest.setup.js +0 -32
  784. package/dist/tests/jest.setup.js.map +0 -1
  785. package/dist/tsconfig.tsbuildinfo +0 -1
  786. /package/dist/{src/assets → assets}/Metropolis-Black.woff2 +0 -0
  787. /package/dist/{src/assets → assets}/Metropolis-BlackItalic.woff2 +0 -0
  788. /package/dist/{src/assets → assets}/Metropolis-Bold.woff2 +0 -0
  789. /package/dist/{src/assets → assets}/Metropolis-BoldItalic.woff2 +0 -0
  790. /package/dist/{src/assets → assets}/Metropolis-ExtraBold.woff2 +0 -0
  791. /package/dist/{src/assets → assets}/Metropolis-ExtraBoldItalic.woff2 +0 -0
  792. /package/dist/{src/assets → assets}/Metropolis-ExtraLight.woff2 +0 -0
  793. /package/dist/{src/assets → assets}/Metropolis-ExtraLightItalic.woff2 +0 -0
  794. /package/dist/{src/assets → assets}/Metropolis-Light.woff2 +0 -0
  795. /package/dist/{src/assets → assets}/Metropolis-LightItalic.woff2 +0 -0
  796. /package/dist/{src/assets → assets}/Metropolis-Medium.woff2 +0 -0
  797. /package/dist/{src/assets → assets}/Metropolis-MediumItalic.woff2 +0 -0
  798. /package/dist/{src/assets → assets}/Metropolis-Regular.woff2 +0 -0
  799. /package/dist/{src/assets → assets}/Metropolis-RegularItalic.woff2 +0 -0
  800. /package/dist/{src/assets → assets}/Metropolis-SemiBold.woff2 +0 -0
  801. /package/dist/{src/assets → assets}/Metropolis-SemiBoldItalic.woff2 +0 -0
  802. /package/dist/{src/assets → assets}/Metropolis-Thin.woff2 +0 -0
  803. /package/dist/{src/assets → assets}/Metropolis-ThinItalic.woff2 +0 -0
  804. /package/dist/{src/assets → assets}/logo.png +0 -0
  805. /package/dist/{src/factories → factories}/AddressFactory.d.ts +0 -0
  806. /package/dist/{src/factories → factories}/EmergencyContactFactory.d.ts +0 -0
  807. /package/dist/{src/factories → factories}/OrganizationTagFactory.d.ts +0 -0
  808. /package/dist/{src/factories → factories}/ParentFactory.d.ts +0 -0
  809. /package/dist/{src/factories → factories}/PlatformEventTypeFactory.d.ts +0 -0
  810. /package/dist/{src/factories → factories}/PlatformResponsibilityFactory.d.ts +0 -0
  811. /package/dist/{src/factories → factories}/RecordFactory.d.ts +0 -0
  812. /package/dist/{src/factories → factories}/RegisterCodeFactory.d.ts +0 -0
  813. /package/dist/{src/factories → factories}/index.d.ts +0 -0
  814. /package/dist/{src/helpers → helpers}/Handlebars.d.ts +0 -0
  815. /package/dist/{src/helpers → helpers}/MemberMerger.d.ts +0 -0
  816. /package/dist/{src/helpers → helpers}/RateLimiter.d.ts +0 -0
  817. /package/dist/{src/index.d.ts → index.d.ts} +0 -0
  818. /package/dist/{src/migrations → migrations}/1593773929-create-initial-tables.sql +0 -0
  819. /package/dist/{src/migrations → migrations}/1605261999-gemeenten-tmp.sql +0 -0
  820. /package/dist/{src/migrations → migrations}/1605262045-import-postcodes.d.ts +0 -0
  821. /package/dist/{src/migrations → migrations}/1605262046-import-postcodes-nl.d.ts +0 -0
  822. /package/dist/{src/migrations → migrations}/1605279038-drop-gemeenten-tmp.sql +0 -0
  823. /package/dist/{src/migrations → migrations}/1708607340-tickets-deleted-at.sql +0 -0
  824. /package/dist/{src/migrations → migrations}/1710459176-register-code-invoices.sql +0 -0
  825. /package/dist/{src/migrations → migrations}/1712158247-discount-codes.sql +0 -0
  826. /package/dist/{src/migrations → migrations}/1713178665-drop-invites.sql +0 -0
  827. /package/dist/{src/migrations → migrations}/1713178666-drop-keychain.sql +0 -0
  828. /package/dist/{src/migrations → migrations}/1713178667-drop-challenges.sql +0 -0
  829. /package/dist/{src/migrations → migrations}/1713178668-drop-user-keys.sql +0 -0
  830. /package/dist/{src/migrations → migrations}/1713178669-drop-organization-key.sql +0 -0
  831. /package/dist/{src/migrations → migrations}/1714985451-user-nullable-organization-id.sql +0 -0
  832. /package/dist/{src/migrations → migrations}/1714985452-email-verification-code-nullable-organization-id.sql +0 -0
  833. /package/dist/{src/migrations → migrations}/1714985453-user-organization-permissions.sql +0 -0
  834. /package/dist/{src/migrations → migrations}/1714985454-user-organization-permissions.sql +0 -0
  835. /package/dist/{src/migrations → migrations}/1715079362-platform.sql +0 -0
  836. /package/dist/{src/migrations → migrations}/1715181649-registrations-organization-id.sql +0 -0
  837. /package/dist/{src/migrations → migrations}/1715181650-registrations-organization-id-fill.sql +0 -0
  838. /package/dist/{src/migrations → migrations}/1715181651-registrations-organization-id-drop-null.sql +0 -0
  839. /package/dist/{src/migrations → migrations}/1716117067-members-nullable-organization-id.sql +0 -0
  840. /package/dist/{src/migrations → migrations}/1719567581-registration-periods.sql +0 -0
  841. /package/dist/{src/migrations → migrations}/1719567582-organization-registration-periods.sql +0 -0
  842. /package/dist/{src/migrations → migrations}/1719567881-organization-periodId.sql +0 -0
  843. /package/dist/{src/migrations → migrations}/1719567882-groups-periodId.sql +0 -0
  844. /package/dist/{src/migrations → migrations}/1719567883-platform-periodId.sql +0 -0
  845. /package/dist/{src/migrations → migrations}/1719568079-default-period.sql +0 -0
  846. /package/dist/{src/migrations → migrations}/1719568080-set-default-period-platform.sql +0 -0
  847. /package/dist/{src/migrations → migrations}/1719568081-set-default-period-organizations.sql +0 -0
  848. /package/dist/{src/migrations → migrations}/1719568082-set-default-period-groups.sql +0 -0
  849. /package/dist/{src/migrations → migrations}/1719580828-registrations-periodId.sql +0 -0
  850. /package/dist/{src/migrations → migrations}/1719580829-set-default-period-registrations.sql +0 -0
  851. /package/dist/{src/migrations → migrations}/1719931362-groups-default-age-group-id.sql +0 -0
  852. /package/dist/{src/migrations → migrations}/1720080975-convert-charset.sql +0 -0
  853. /package/dist/{src/migrations → migrations}/1720080976-responsibilities.sql +0 -0
  854. /package/dist/{src/migrations → migrations}/1720088136-member-membership-types.sql +0 -0
  855. /package/dist/{src/migrations → migrations}/1720088137-member-membership-types-expire-date.sql +0 -0
  856. /package/dist/{src/migrations → migrations}/1720444931-organization-active.sql +0 -0
  857. /package/dist/{src/migrations → migrations}/1721050380-email-table.sql +0 -0
  858. /package/dist/{src/migrations → migrations}/1721050381-email-recipients-table.sql +0 -0
  859. /package/dist/{src/migrations → migrations}/1721342679-responsibility-groupId.sql +0 -0
  860. /package/dist/{src/migrations → migrations}/1721342680-responsibility-groupId-foreign-key.sql +0 -0
  861. /package/dist/{src/migrations → migrations}/1721400546-users-memberId.sql +0 -0
  862. /package/dist/{src/migrations → migrations}/1721639159-membership-deleted-at.sql +0 -0
  863. /package/dist/{src/migrations → migrations}/1721639160-membership-generated.sql +0 -0
  864. /package/dist/{src/migrations → migrations}/1721841819-group-type.sql +0 -0
  865. /package/dist/{src/migrations → migrations}/1722090482-events.sql +0 -0
  866. /package/dist/{src/migrations → migrations}/1722269236-group-waitinglist-id.sql +0 -0
  867. /package/dist/{src/migrations → migrations}/1722525785-balance-item-paying-organization-id.sql +0 -0
  868. /package/dist/{src/migrations → migrations}/1722525787-depending-balance-item.sql +0 -0
  869. /package/dist/{src/migrations → migrations}/1722845608-registration-stock-reservations.sql +0 -0
  870. /package/dist/{src/migrations → migrations}/1722845609-group-stock-reservations.sql +0 -0
  871. /package/dist/{src/migrations → migrations}/1722852362-stripe-intents-account-id.sql +0 -0
  872. /package/dist/{src/migrations → migrations}/1722852363-stripe-checkout-sessions-account-id.sql +0 -0
  873. /package/dist/{src/migrations → migrations}/1722959111-allow-multiple-registrations.sql +0 -0
  874. /package/dist/{src/migrations → migrations}/1722963554-registration-group-price-and-options.sql +0 -0
  875. /package/dist/{src/migrations → migrations}/1723202125-member-number.sql +0 -0
  876. /package/dist/{src/migrations → migrations}/1723202126-member-number-index.sql +0 -0
  877. /package/dist/{src/migrations → migrations}/1723218160-balance-item-unit-price.sql +0 -0
  878. /package/dist/{src/migrations → migrations}/1723218161-balance-item-amount.sql +0 -0
  879. /package/dist/{src/migrations → migrations}/1723218162-balance-item-type.sql +0 -0
  880. /package/dist/{src/migrations → migrations}/1723218163-balance-item-type-defaults.sql +0 -0
  881. /package/dist/{src/migrations → migrations}/1723218164-balance-item-relations.sql +0 -0
  882. /package/dist/{src/migrations → migrations}/1723652795-payments-paying-user-id.sql +0 -0
  883. /package/dist/{src/migrations → migrations}/1723652796-payments-paying-organization-id.sql +0 -0
  884. /package/dist/{src/migrations → migrations}/1723652797-payments-paying-organization-id-fk.sql +0 -0
  885. /package/dist/{src/migrations → migrations}/1723652798-payments-customer.sql +0 -0
  886. /package/dist/{src/migrations → migrations}/1723736282-merged-members.sql +0 -0
  887. /package/dist/{src/migrations → migrations}/1724076162-setup-steps.sql +0 -0
  888. /package/dist/{src/migrations → migrations}/1724156666-member-indexes.sql +0 -0
  889. /package/dist/{src/migrations → migrations}/1724156667-organization-tag-index.sql +0 -0
  890. /package/dist/{src/migrations → migrations}/1724256125-membership-balance-item-id.sql +0 -0
  891. /package/dist/{src/migrations → migrations}/1724256126-membership-balance-item-fk.sql +0 -0
  892. /package/dist/{src/migrations → migrations}/1724258844-membershipOrganizationId.sql +0 -0
  893. /package/dist/{src/migrations → migrations}/1724258845-membershipOrganizationId-fk.sql +0 -0
  894. /package/dist/{src/migrations → migrations}/1726054851-balance-item-price-pending.sql +0 -0
  895. /package/dist/{src/migrations → migrations}/1726054852-cached-outstanding-balances.sql +0 -0
  896. /package/dist/{src/migrations → migrations}/1726668114-maximum-free-amount.sql +0 -0
  897. /package/dist/{src/migrations → migrations}/1726668115-free-amount.sql +0 -0
  898. /package/dist/{src/migrations → migrations}/1726668116-price-without-discount.sql +0 -0
  899. /package/dist/{src/migrations → migrations}/1727947041-registration-record-answers.sql +0 -0
  900. /package/dist/{src/migrations → migrations}/1729251385-order-extra-filter-columns.sql +0 -0
  901. /package/dist/{src/migrations → migrations}/1732285080-audit-logs.sql +0 -0
  902. /package/dist/{src/migrations → migrations}/1733129611-clear-audit-logs.sql +0 -0
  903. /package/dist/{src/migrations → migrations}/1733129612-audit-logs-source.sql +0 -0
  904. /package/dist/{src/migrations → migrations}/1733317908-added-missing-organization-fk-on-registrations.sql +0 -0
  905. /package/dist/{src/migrations → migrations}/1733317909-paying-organization-id-registrations.sql +0 -0
  906. /package/dist/{src/migrations → migrations}/1733317910-paying-organization-id-fk.sql +0 -0
  907. /package/dist/{src/migrations → migrations}/1733410641-audit-log-external-id.sql +0 -0
  908. /package/dist/{src/migrations → migrations}/1733418667-desc-audit-log-primary-key.sql +0 -0
  909. /package/dist/{src/migrations → migrations}/1733909398-balance-items-due-at.sql +0 -0
  910. /package/dist/{src/migrations → migrations}/1733909399-recalculate-at.sql +0 -0
  911. /package/dist/{src/migrations → migrations}/1733994454-balance-item-price-open.sql +0 -0
  912. /package/dist/{src/migrations → migrations}/1734084689-payment-type.sql +0 -0
  913. /package/dist/{src/migrations → migrations}/1734084690-move-payment-column-order.sql +0 -0
  914. /package/dist/{src/migrations → migrations}/1734084691-fill-payment-type-refunds.sql +0 -0
  915. /package/dist/{src/migrations → migrations}/1734084692-fill-payment-type-reallocations.sql +0 -0
  916. /package/dist/{src/migrations → migrations}/1734429094-registration-trial-until.sql +0 -0
  917. /package/dist/{src/migrations → migrations}/1734429095-membership-trial-until.sql +0 -0
  918. /package/dist/{src/migrations → migrations}/1734535120-registration-period-previous-period-id.sql +0 -0
  919. /package/dist/{src/migrations → migrations}/1734535121-platform-previous-period-id.sql +0 -0
  920. /package/dist/{src/migrations → migrations}/1734626607-cached-balance-amount-open.sql +0 -0
  921. /package/dist/{src/migrations → migrations}/1734698906-cached-balance-amount-paid.sql +0 -0
  922. /package/dist/{src/migrations → migrations}/1735573520-emails-email-type.sql +0 -0
  923. /package/dist/{src/migrations → migrations}/1735573521-email-recipients-email-type.sql +0 -0
  924. /package/dist/{src/migrations → migrations}/1735573522-emails-indexes.sql +0 -0
  925. /package/dist/{src/migrations → migrations}/1735982691-cached-balance-email-reminder-counts.sql +0 -0
  926. /package/dist/{src/migrations → migrations}/1736850097-audit-logs-meta.sql +0 -0
  927. /package/dist/{src/migrations → migrations}/1736947931-platform-server-config.sql +0 -0
  928. /package/dist/{src/migrations → migrations}/1738922428-membership-locked.sql +0 -0
  929. /package/dist/{src/migrations → migrations}/1739017508-event-notifications.sql +0 -0
  930. /package/dist/{src/migrations → migrations}/1739017509-event-notifications-link.sql +0 -0
  931. /package/dist/{src/migrations → migrations}/1739282590-event-notifications-submitted-at.sql +0 -0
  932. /package/dist/{src/migrations → migrations}/1741954610-event-notifications-accepted-record-answers.sql +0 -0
  933. /package/dist/{src/migrations → migrations}/1742579832-audit-log-longer-object-size.sql +0 -0
  934. /package/dist/{src/migrations → migrations}/1747913433-registration-discounts.sql +0 -0
  935. /package/dist/{src/migrations → migrations}/1747996262-balance-items-paid-at.sql +0 -0
  936. /package/dist/{src/migrations → migrations}/1747996263-balance-items-paid-at-fill.sql +0 -0
  937. /package/dist/{src/migrations → migrations}/1751633220-create-uitpas-client-credentials.sql +0 -0
  938. /package/dist/{src/migrations → migrations}/1751970372-create-webshop-uitpas-numbers.sql +0 -0
  939. /package/dist/{src/migrations → migrations}/1752655335-events-webshop-id.sql +0 -0
  940. /package/dist/{src/migrations → migrations}/1752678047-confirmation-email.sql +0 -0
  941. /package/dist/{src/migrations → migrations}/1753363434-service-fees.sql +0 -0
  942. /package/dist/{src/migrations → migrations}/1753430415-update-webshop-uitpasnumbers.sql +0 -0
  943. /package/dist/{src/migrations → migrations}/1755529026-email-sender-id.sql +0 -0
  944. /package/dist/{src/migrations → migrations}/1755789797-email-counts-errors.sql +0 -0
  945. /package/dist/{src/migrations → migrations}/1755789798-email-recipient-errors.sql +0 -0
  946. /package/dist/{src/migrations → migrations}/1756115313-email-recipient-ids-and-errors.sql +0 -0
  947. /package/dist/{src/migrations → migrations}/1756115314-email-recipient-email-optional.sql +0 -0
  948. /package/dist/{src/migrations → migrations}/1756115315-email-recipients-count.sql +0 -0
  949. /package/dist/{src/migrations → migrations}/1756115316-email-cached-counts.sql +0 -0
  950. /package/dist/{src/migrations → migrations}/1756115317-email-deleted-at.sql +0 -0
  951. /package/dist/{src/migrations → migrations}/1756293494-registration-period-next-period-id.sql +0 -0
  952. /package/dist/{src/migrations → migrations}/1756293495-platform-next-period-id.sql +0 -0
  953. /package/dist/{src/migrations → migrations}/1756387016-registration-period-custom-name.sql +0 -0
  954. /package/dist/{src/migrations → migrations}/1756391212-email-recipients-duplicate.sql +0 -0
  955. /package/dist/{src/migrations → migrations}/1756821154-email-send-as-email.sql +0 -0
  956. /package/dist/{src/migrations → migrations}/1758034021-email-recipient-previous-error.sql +0 -0
  957. /package/dist/{src/migrations → migrations}/1760535508-update-cached-balances-object-id-unique-constraint.sql +0 -0
  958. /package/dist/{src/migrations → migrations}/1761750780-renamed-invoice-organization-id.sql +0 -0
  959. /package/dist/{src/migrations → migrations}/1761750781-rename-index.sql +0 -0
  960. /package/dist/{src/migrations → migrations}/1761750782-invoices-add-organization-id.sql +0 -0
  961. /package/dist/{src/migrations → migrations}/1761750783-invoices-organization-id-fk.sql +0 -0
  962. /package/dist/{src/migrations → migrations}/1762521336-did-send-peppol.sql +0 -0
  963. /package/dist/{src/migrations → migrations}/1763216321-multiply-balance-item-payments.sql +0 -0
  964. /package/dist/{src/migrations → migrations}/1763216322-multiply-balance-items.sql +0 -0
  965. /package/dist/{src/migrations → migrations}/1763216323-bigint-cached-balances.sql +0 -0
  966. /package/dist/{src/migrations → migrations}/1763216324-multiply-cached-balances.sql +0 -0
  967. /package/dist/{src/migrations → migrations}/1763216325-multiply-member-platform-memberships.sql +0 -0
  968. /package/dist/{src/migrations → migrations}/1763216326-multiply-payments.sql +0 -0
  969. /package/dist/{src/migrations → migrations}/1763216327-multiply-register-codes.sql +0 -0
  970. /package/dist/{src/migrations → migrations}/1763216328-multiply-credits.sql +0 -0
  971. /package/dist/{src/migrations → migrations}/1763216329-multiply-orders.sql +0 -0
  972. /package/dist/{src/migrations → migrations}/1763216330-multiply-uitpas-numbers.sql +0 -0
  973. /package/dist/{src/migrations → migrations}/1763216331-balance-item-vat-percentages.sql +0 -0
  974. /package/dist/{src/migrations → migrations}/1763216332-balance-item-price-total.sql +0 -0
  975. /package/dist/{src/migrations → migrations}/1763216333-balance-item-price-total-fill.sql +0 -0
  976. /package/dist/{src/migrations → migrations}/1765895470-document-year.sql +0 -0
  977. /package/dist/{src/migrations → migrations}/1766150401-document-published-at.sql +0 -0
  978. /package/dist/{src/migrations → migrations}/1766410598-registration-end-date.sql +0 -0
  979. /package/dist/{src/migrations → migrations}/1769087807-invoices-table.sql +0 -0
  980. /package/dist/{src/migrations → migrations}/1769087808-invoiced-balance-items-table.sql +0 -0
  981. /package/dist/{src/migrations → migrations}/1769087809-payments-invoice-id.sql +0 -0
  982. /package/dist/{src/migrations → migrations}/1769621227-payments-rounding-amount.sql +0 -0
  983. /package/dist/{src/migrations → migrations}/1770917406-create-cached-balances-global-index.sql +0 -0
  984. /package/dist/{src/migrations → migrations}/1770917407-create-member-name-ordering-index.sql +0 -0
  985. /package/dist/{src/migrations → migrations}/1770917408-create-member-name-ordering-index-desc.sql +0 -0
  986. /package/dist/{src/migrations → migrations}/1770917409-create-member-age-ordering-index.sql +0 -0
  987. /package/dist/{src/migrations → migrations}/1770917410-create-member-age-ordering-index-desc.sql +0 -0
  988. /package/dist/{src/migrations → migrations}/1770917411-drop-duplicate-member-indexes.sql +0 -0
  989. /package/dist/{src/migrations → migrations}/1771510518-events-index-organization-id-start-date.sql +0 -0
  990. /package/dist/{src/migrations → migrations}/1771918307-membership-active-filter-index.sql +0 -0
  991. /package/dist/{src/migrations → migrations}/1772033555-balance-item-package-id.sql +0 -0
  992. /package/dist/{src/migrations → migrations}/1772033715-balance-item-start-end-date.sql +0 -0
  993. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Drenthe +0 -0
  994. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Flevoland +0 -0
  995. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Friesland +0 -0
  996. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Gelderland +0 -0
  997. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Groningen +0 -0
  998. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Limburg +0 -0
  999. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Noord-Brabant +0 -0
  1000. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Noord-Holland +0 -0
  1001. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Overrijsel +0 -0
  1002. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Utrecht +0 -0
  1003. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Zeeland +0 -0
  1004. /package/dist/{src/migrations → migrations}/data/postcodes/nl/Zuid-Holland +0 -0
  1005. /package/dist/{src/models → models}/AuditLog.d.ts +0 -0
  1006. /package/dist/{src/models → models}/BuckarooPayment.d.ts +0 -0
  1007. /package/dist/{src/models → models}/EmailRecipient.d.ts +0 -0
  1008. /package/dist/{src/models → models}/Event.d.ts +0 -0
  1009. /package/dist/{src/models → models}/Invoice.d.ts +0 -0
  1010. /package/dist/{src/models → models}/MemberUser.d.ts +0 -0
  1011. /package/dist/{src/models → models}/MolliePayment.d.ts +0 -0
  1012. /package/dist/{src/models → models}/Platform.d.ts +0 -0
  1013. /package/dist/{src/models → models}/RegisterCode.d.ts +0 -0
  1014. /package/dist/{src/models → models}/RegistrationPeriod.d.ts +0 -0
  1015. /package/dist/{src/models → models}/STCredit.d.ts +0 -0
  1016. /package/dist/{src/models → models}/STPackage.d.ts +0 -0
  1017. /package/dist/{src/models → models}/StripeAccount.d.ts +0 -0
  1018. /package/dist/{src/models → models}/StripeCheckoutSession.d.ts +0 -0
  1019. /package/dist/{src/models → models}/StripePaymentIntent.d.ts +0 -0
  1020. /package/dist/{src/models → models}/UitpasClientCredential.d.ts +0 -0
  1021. /package/dist/{src/models → models}/UsedRegisterCode.d.ts +0 -0
  1022. /package/dist/{src/models → models}/WebshopDiscountCode.d.ts +0 -0
  1023. /package/dist/{src/models → models}/WebshopUitpasNumber.d.ts +0 -0
  1024. /package/dist/{src/models → models}/addresses/Street.d.ts +0 -0
  1025. /package/dist/{src/structures → structures}/OrganizationServerMetaData.d.ts +0 -0
@@ -1,65 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.STCredit = void 0;
4
- const tslib_1 = require("tslib");
5
- const simple_database_1 = require("@simonbackx/simple-database");
6
- const sql_1 = require("@stamhoofd/sql");
7
- const uuid_1 = require("uuid");
8
- class STCredit extends sql_1.QueryableModel {
9
- static table = 'stamhoofd_credits';
10
- // Columns
11
- id;
12
- organizationId;
13
- description;
14
- change;
15
- allowTransactions = false;
16
- createdAt;
17
- expireAt = null;
18
- updatedAt;
19
- }
20
- exports.STCredit = STCredit;
21
- tslib_1.__decorate([
22
- (0, simple_database_1.column)({
23
- primary: true, type: 'string', beforeSave(value) {
24
- return value ?? (0, uuid_1.v4)();
25
- },
26
- })
27
- ], STCredit.prototype, "id", void 0);
28
- tslib_1.__decorate([
29
- (0, simple_database_1.column)({ type: 'string' })
30
- ], STCredit.prototype, "organizationId", void 0);
31
- tslib_1.__decorate([
32
- (0, simple_database_1.column)({ type: 'string' })
33
- ], STCredit.prototype, "description", void 0);
34
- tslib_1.__decorate([
35
- (0, simple_database_1.column)({ type: 'integer' })
36
- ], STCredit.prototype, "change", void 0);
37
- tslib_1.__decorate([
38
- (0, simple_database_1.column)({ type: 'boolean' })
39
- ], STCredit.prototype, "allowTransactions", void 0);
40
- tslib_1.__decorate([
41
- (0, simple_database_1.column)({
42
- type: 'datetime', beforeSave(old) {
43
- if (old !== undefined) {
44
- return old;
45
- }
46
- const date = new Date();
47
- date.setMilliseconds(0);
48
- return date;
49
- },
50
- })
51
- ], STCredit.prototype, "createdAt", void 0);
52
- tslib_1.__decorate([
53
- (0, simple_database_1.column)({ type: 'datetime', nullable: true })
54
- ], STCredit.prototype, "expireAt", void 0);
55
- tslib_1.__decorate([
56
- (0, simple_database_1.column)({
57
- type: 'datetime', beforeSave() {
58
- const date = new Date();
59
- date.setMilliseconds(0);
60
- return date;
61
- },
62
- skipUpdate: true,
63
- })
64
- ], STCredit.prototype, "updatedAt", void 0);
65
- //# sourceMappingURL=STCredit.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"STCredit.js","sourceRoot":"","sources":["../../../src/models/STCredit.ts"],"names":[],"mappings":";;;;AAAA,iEAAqD;AACrD,wCAAgD;AAChD,+BAAoC;AAEpC,MAAa,QAAS,SAAQ,oB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AI,GAAG,IAAI,IAAI,EAAE,CAAC;YACxB,IAAI,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC;YACxB,OAAO,IAAI,CAAC;QAChB,CAAC;QACD,UAAU,EAAE,IAAI;KACnB,CAAC;2CACc"}
@@ -1,37 +0,0 @@
1
- import { QueryableModel } from '@stamhoofd/sql';
2
- import { OrganizationPaymentMandate, STInvoiceMeta } from '@stamhoofd/structures';
3
- import { Organization } from './index.js';
4
- export declare class STInvoice extends QueryableModel {
5
- static table: string;
6
- private static numberCache;
7
- id: string;
8
- /**
9
- * Organization that made the invoice. Can be null if the organization was deleted and for the migration from V1 -> V2
10
- */
11
- organizationId: string | null;
12
- /**
13
- * Organization that is associated with this invoice (can be null if deleted or unknown)
14
- */
15
- payingOrganizationId: string | null;
16
- /**
17
- * An associated STCredit, that was used to remove credits from the user's credits.
18
- * If the invoice is marked as failed, we need to delete this one
19
- */
20
- creditId: string | null;
21
- /**
22
- * Note: always create a new invoice for failed payments. We never create an actual invoice until we received the payment
23
- */
24
- paymentId: string | null;
25
- meta: STInvoiceMeta;
26
- /**
27
- * If the number is null, no invoice is generated yet. Its still a WIP invoice (not an official one!)
28
- */
29
- number: number | null;
30
- paidAt: Date | null;
31
- createdAt: Date;
32
- updatedAt: Date;
33
- reference: string | null;
34
- didSendPeppol: boolean;
35
- static getMollieMandates(organization: Organization): Promise<OrganizationPaymentMandate[]>;
36
- }
37
- //# sourceMappingURL=STInvoice.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"STInvoice.d.ts","sourceRoot":"","sources":["../../../src/models/STInvoice.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,0BAA0B,EAAqC,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAErH,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C,qBAAa,SAAU,SAAQ,cAAc;IACzC,MAAM,CAAC,KAAK,SAAwB;IAEpC,OAAO,CAAC,MAAM,CAAC,WAAW,CAAuB;IAQjD,EAAE,EAAG,MAAM,CAAC;IAEZ;;OAEG;IAEH,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;IAE9B;;OAEG;IAEH,oBAAoB,EAAE,MAAM,GAAG,IAAI,CAAC;IAEpC;;;OAGG;IAEH,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAQ;IAE/B;;OAEG;IAEH,SAAS,EAAE,MAAM,GAAG,IAAI,CAAQ;IAGhC,IAAI,EAAE,aAAa,CAAC;IAEpB;;OAEG;IAEH,MAAM,EAAE,MAAM,GAAG,IAAI,CAAQ;IAG7B,MAAM,EAAE,IAAI,GAAG,IAAI,CAAQ;IAY3B,SAAS,EAAE,IAAI,CAAC;IAUhB,SAAS,EAAE,IAAI,CAAC;IAGhB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAQ;IAGhC,aAAa,UAAS;WAKT,iBAAiB,CAAC,YAAY,EAAE,YAAY;CA6C5D"}
@@ -1,145 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.STInvoice = void 0;
4
- const tslib_1 = require("tslib");
5
- const api_client_1 = require("@mollie/api-client");
6
- const simple_database_1 = require("@simonbackx/simple-database");
7
- const simple_errors_1 = require("@simonbackx/simple-errors");
8
- const sql_1 = require("@stamhoofd/sql");
9
- const structures_1 = require("@stamhoofd/structures");
10
- const uuid_1 = require("uuid");
11
- class STInvoice extends sql_1.QueryableModel {
12
- static table = 'stamhoofd_invoices';
13
- static numberCache = null;
14
- // Columns
15
- id;
16
- /**
17
- * Organization that made the invoice. Can be null if the organization was deleted and for the migration from V1 -> V2
18
- */
19
- organizationId;
20
- /**
21
- * Organization that is associated with this invoice (can be null if deleted or unknown)
22
- */
23
- payingOrganizationId;
24
- /**
25
- * An associated STCredit, that was used to remove credits from the user's credits.
26
- * If the invoice is marked as failed, we need to delete this one
27
- */
28
- creditId = null;
29
- /**
30
- * Note: always create a new invoice for failed payments. We never create an actual invoice until we received the payment
31
- */
32
- paymentId = null;
33
- meta;
34
- /**
35
- * If the number is null, no invoice is generated yet. Its still a WIP invoice (not an official one!)
36
- */
37
- number = null;
38
- paidAt = null;
39
- createdAt;
40
- updatedAt;
41
- reference = null;
42
- didSendPeppol = false;
43
- // static organization = new ManyToOneRelation(Organization, 'organization');
44
- // static payment = new ManyToOneRelation(Payment, 'payment');
45
- static async getMollieMandates(organization) {
46
- // Poll mollie status
47
- // Mollie payment is required
48
- const mandates = [];
49
- try {
50
- const apiKey = STAMHOOFD.MOLLIE_API_KEY;
51
- if (!apiKey) {
52
- throw new simple_errors_1.SimpleError({
53
- code: '',
54
- message: 'Mollie niet correct gekoppeld',
55
- });
56
- }
57
- const mollieClient = (0, api_client_1.createMollieClient)({ apiKey });
58
- if (organization.serverMeta.mollieCustomerId) {
59
- const m = await mollieClient.customerMandates.page({ customerId: organization.serverMeta.mollieCustomerId, limit: 250 });
60
- for (const mandate of m) {
61
- try {
62
- const details = mandate.details;
63
- mandates.push(structures_1.OrganizationPaymentMandate.create({
64
- ...mandate,
65
- isDefault: mandate.id === organization.serverMeta.mollieMandateId,
66
- createdAt: new Date(mandate.createdAt),
67
- details: structures_1.OrganizationPaymentMandateDetails.create({
68
- consumerName: ('consumerName' in details ? details.consumerName : details.cardHolder) ?? undefined,
69
- consumerAccount: ('consumerAccount' in details ? details.consumerAccount : details.cardNumber) ?? undefined,
70
- consumerBic: ('consumerBic' in details ? details.consumerBic : details.cardExpiryDate) ?? undefined,
71
- cardExpiryDate: ('cardExpiryDate' in details ? details.cardExpiryDate : null),
72
- cardLabel: ('cardLabel' in details ? details.cardLabel : null),
73
- }),
74
- }));
75
- }
76
- catch (e) {
77
- console.error(e);
78
- }
79
- }
80
- }
81
- }
82
- catch (e) {
83
- console.error(e);
84
- }
85
- return mandates;
86
- }
87
- }
88
- exports.STInvoice = STInvoice;
89
- tslib_1.__decorate([
90
- (0, simple_database_1.column)({
91
- primary: true, type: 'string', beforeSave(value) {
92
- return value ?? (0, uuid_1.v4)();
93
- },
94
- })
95
- ], STInvoice.prototype, "id", void 0);
96
- tslib_1.__decorate([
97
- (0, simple_database_1.column)({ type: 'string', nullable: true })
98
- ], STInvoice.prototype, "organizationId", void 0);
99
- tslib_1.__decorate([
100
- (0, simple_database_1.column)({ type: 'string', nullable: true })
101
- ], STInvoice.prototype, "payingOrganizationId", void 0);
102
- tslib_1.__decorate([
103
- (0, simple_database_1.column)({ type: 'string', nullable: true })
104
- ], STInvoice.prototype, "creditId", void 0);
105
- tslib_1.__decorate([
106
- (0, simple_database_1.column)({ type: 'string', nullable: true })
107
- ], STInvoice.prototype, "paymentId", void 0);
108
- tslib_1.__decorate([
109
- (0, simple_database_1.column)({ type: 'json', decoder: structures_1.STInvoiceMeta })
110
- ], STInvoice.prototype, "meta", void 0);
111
- tslib_1.__decorate([
112
- (0, simple_database_1.column)({ type: 'integer', nullable: true })
113
- ], STInvoice.prototype, "number", void 0);
114
- tslib_1.__decorate([
115
- (0, simple_database_1.column)({ type: 'datetime', nullable: true })
116
- ], STInvoice.prototype, "paidAt", void 0);
117
- tslib_1.__decorate([
118
- (0, simple_database_1.column)({
119
- type: 'datetime', beforeSave(old) {
120
- if (old !== undefined) {
121
- return old;
122
- }
123
- const date = new Date();
124
- date.setMilliseconds(0);
125
- return date;
126
- },
127
- })
128
- ], STInvoice.prototype, "createdAt", void 0);
129
- tslib_1.__decorate([
130
- (0, simple_database_1.column)({
131
- type: 'datetime', beforeSave() {
132
- const date = new Date();
133
- date.setMilliseconds(0);
134
- return date;
135
- },
136
- skipUpdate: true,
137
- })
138
- ], STInvoice.prototype, "updatedAt", void 0);
139
- tslib_1.__decorate([
140
- (0, simple_database_1.column)({ type: 'string', nullable: true })
141
- ], STInvoice.prototype, "reference", void 0);
142
- tslib_1.__decorate([
143
- (0, simple_database_1.column)({ type: 'boolean' })
144
- ], STInvoice.prototype, "didSendPeppol", void 0);
145
- //# sourceMappingURL=STInvoice.js.map
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GAAG,IAAI,CAAQ;IAE1B,QAAQ;IAeR,QAAQ,CAAC,OAAO,EAAE,SAAS;IAM3B,UAAU;IAQhB;;OAEG;IACH,aAAa,IAAI,SAAS;IAmE1B,YAAY,IAAI,eAAe;IAuBzB,eAAe;IA2Df,iBAAiB,CAAC,IAAI,EAAE;QAC1B,IAAI,EAAE,iBAAiB,CAAC;QACxB,OAAO,CAAC,EAAE,MAAM,CAAC;KACpB;CAgDJ"}
@@ -1,280 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.STPackage = void 0;
4
- const tslib_1 = require("tslib");
5
- const simple_database_1 = require("@simonbackx/simple-database");
6
- const simple_errors_1 = require("@simonbackx/simple-errors");
7
- const structures_1 = require("@stamhoofd/structures");
8
- const utility_1 = require("@stamhoofd/utility");
9
- const uuid_1 = require("uuid");
10
- const sql_1 = require("@stamhoofd/sql");
11
- const EmailBuilder_js_1 = require("../helpers/EmailBuilder.js");
12
- const index_js_1 = require("./index.js");
13
- class STPackage extends sql_1.QueryableModel {
14
- static table = 'stamhoofd_packages';
15
- // Columns
16
- id;
17
- /**
18
- * We keep packages of deleted organizations for statistics, so this doesn't have a foreign key
19
- */
20
- organizationId;
21
- meta;
22
- createdAt;
23
- updatedAt;
24
- validAt = null;
25
- validUntil = null;
26
- removeAt = null;
27
- emailCount = 0;
28
- lastEmailAt = null;
29
- async activate() {
30
- if (this.validAt !== null) {
31
- return;
32
- }
33
- this.validAt = new Date();
34
- await this.save();
35
- if (this.meta.didRenewId) {
36
- const pack = await STPackage.getByID(this.meta.didRenewId);
37
- if (pack && pack.organizationId === this.organizationId) {
38
- await pack.didRenew(this);
39
- }
40
- }
41
- }
42
- async didRenew(renewed) {
43
- this.removeAt = renewed.meta.startDate ?? renewed.validAt ?? new Date();
44
- this.meta.allowRenew = false;
45
- await this.save();
46
- }
47
- async deactivate() {
48
- if (this.removeAt !== null && this.removeAt <= new Date()) {
49
- return;
50
- }
51
- this.removeAt = new Date();
52
- await this.save();
53
- }
54
- /**
55
- * Create a renewed package, but not yet saved!
56
- */
57
- createRenewed() {
58
- if (!this.meta.allowRenew) {
59
- throw new simple_errors_1.SimpleError({
60
- code: 'not_allowed',
61
- message: 'Not allowed',
62
- human: $t(`fcb50c02-7510-4e48-bfac-10bb584e3454`),
63
- });
64
- }
65
- const pack = new STPackage();
66
- pack.id = (0, uuid_1.v4)();
67
- pack.meta = this.meta;
68
- // Not yet valid / active (ignored until valid)
69
- pack.validAt = null;
70
- pack.organizationId = this.organizationId;
71
- pack.meta.startDate = new Date(Math.max(new Date().getTime(), this.validUntil?.getTime() ?? 0));
72
- pack.meta.paidAmount = 0;
73
- pack.meta.paidPrice = 0;
74
- pack.meta.firstFailedPayment = null;
75
- pack.meta.didRenewId = this.id;
76
- // Duration for renewals is always a year ATM
77
- pack.validUntil = new Date(pack.meta.startDate);
78
- pack.validUntil.setFullYear(pack.validUntil.getFullYear() + 1);
79
- // Remove (= not renewable) if not renewed after 3 months
80
- pack.removeAt = new Date(pack.validUntil);
81
- pack.removeAt.setMonth(pack.removeAt.getMonth() + 3);
82
- // Custom renewals for single webshop:
83
- /* if (this.meta.type === STPackageType.SingleWebshop) {
84
- // Disable functions after two months
85
- pack.validUntil = new Date(pack.meta.startDate)
86
- pack.validUntil.setMonth(pack.validUntil.getMonth() + 2)
87
- pack.removeAt = new Date(pack.validUntil)
88
- } */
89
- if (this.meta.type === structures_1.STPackageType.SingleWebshop) {
90
- pack.meta.type = structures_1.STPackageType.Webshops;
91
- }
92
- // Change prices
93
- if (pack.meta.type === structures_1.STPackageType.Webshops) {
94
- pack.meta.serviceFeeFixed = 0;
95
- pack.meta.serviceFeePercentage = 2_00;
96
- pack.meta.serviceFeeMinimum = 0;
97
- pack.meta.serviceFeeMaximum = 2000; // 20 cent
98
- pack.meta.unitPrice = 0;
99
- pack.meta.pricingType = structures_1.STPricingType.Fixed;
100
- pack.validUntil = null;
101
- pack.removeAt = null;
102
- }
103
- else if (pack.meta.type === structures_1.STPackageType.Members) {
104
- pack.meta.serviceFeeFixed = 0;
105
- pack.meta.serviceFeePercentage = 0;
106
- pack.meta.serviceFeeMinimum = 0;
107
- pack.meta.serviceFeeMaximum = 0;
108
- pack.meta.unitPrice = 1_0000; // 1 euro
109
- pack.meta.pricingType = structures_1.STPricingType.PerMember;
110
- }
111
- return pack;
112
- }
113
- createStatus() {
114
- // TODO: if payment failed: temporary set valid until to 2 weeks after last/first failed payment
115
- return structures_1.STPackageStatus.create({
116
- startDate: this.meta.startDate,
117
- validUntil: this.validUntil,
118
- removeAt: this.removeAt,
119
- firstFailedPayment: this.meta.firstFailedPayment,
120
- serviceFees: [
121
- structures_1.STPackageStatusServiceFee.create({
122
- fixed: this.meta.serviceFeeFixed,
123
- percentage: this.meta.serviceFeePercentage,
124
- minimum: this.meta.serviceFeeMinimum,
125
- maximum: this.meta.serviceFeeMaximum,
126
- startDate: this.meta.startDate,
127
- endDate: this.validUntil && this.removeAt
128
- ? new Date(Math.min(this.validUntil.getTime(), this.removeAt.getTime()))
129
- : (this.validUntil ?? this.removeAt),
130
- })
131
- ],
132
- });
133
- }
134
- async sendExpiryEmail() {
135
- if (this.validAt === null) {
136
- // never activated
137
- return;
138
- }
139
- if (this.removeAt && this.removeAt <= new Date()) {
140
- this.emailCount += 1;
141
- await this.save();
142
- return;
143
- }
144
- let allowDays = 0;
145
- let type = null;
146
- if (this.meta.type === structures_1.STPackageType.Members) {
147
- type = structures_1.EmailTemplateType.MembersExpirationReminder;
148
- allowDays = 32;
149
- }
150
- else if (this.meta.type === structures_1.STPackageType.Webshops) {
151
- type = structures_1.EmailTemplateType.WebshopsExpirationReminder;
152
- allowDays = 32;
153
- }
154
- else if (this.meta.type === structures_1.STPackageType.SingleWebshop) {
155
- type = structures_1.EmailTemplateType.SingleWebshopExpirationReminder;
156
- allowDays = 7;
157
- }
158
- else if (this.meta.type === structures_1.STPackageType.TrialMembers) {
159
- type = structures_1.EmailTemplateType.TrialMembersExpirationReminder;
160
- allowDays = 3;
161
- }
162
- else if (this.meta.type === structures_1.STPackageType.TrialWebshops) {
163
- type = structures_1.EmailTemplateType.TrialWebshopsExpirationReminder;
164
- allowDays = 3;
165
- }
166
- const allowFrom = new Date(Date.now() + 1000 * 60 * 60 * 24 * allowDays);
167
- if (type && (this.validUntil === null || this.validUntil < new Date() || this.validUntil > allowFrom)) {
168
- console.log('Skip sending expiration email for ' + this.id);
169
- return;
170
- }
171
- if (type) {
172
- console.log('Sending expiration email for ' + this.id, type);
173
- if (STAMHOOFD.environment === 'production') {
174
- await this.sendEmailTemplate({
175
- type,
176
- });
177
- }
178
- this.lastEmailAt = new Date();
179
- }
180
- else {
181
- console.log('Skip sending expiration email for ' + this.id + ' (no type)');
182
- }
183
- this.emailCount += 1;
184
- await this.save();
185
- }
186
- async sendEmailTemplate(data) {
187
- const organization = await index_js_1.Organization.getByID(this.organizationId);
188
- if (!organization) {
189
- console.error('Could not find package organization ' + this.id);
190
- return;
191
- }
192
- const admins = await organization.getFullAdmins();
193
- const recipients = admins.map(admin => structures_1.Recipient.create({
194
- firstName: admin.firstName,
195
- lastName: admin.lastName,
196
- email: admin.email,
197
- replacements: [
198
- structures_1.Replacement.create({
199
- token: 'organizationName',
200
- value: organization.name,
201
- }),
202
- structures_1.Replacement.create({
203
- token: 'packageName',
204
- value: this.meta.name ?? '',
205
- }),
206
- structures_1.Replacement.create({
207
- token: 'validUntil',
208
- value: this.validUntil ? utility_1.Formatter.dateTime(this.validUntil) : 'nooit',
209
- }),
210
- structures_1.Replacement.create({
211
- token: 'validUntilDate',
212
- value: this.validUntil ? utility_1.Formatter.date(this.validUntil) : 'nooit',
213
- }),
214
- structures_1.Replacement.create({
215
- token: 'renewUrl',
216
- value: 'https://' + (STAMHOOFD.domains.dashboard ?? 'stamhoofd.app') + '/' + organization.i18n.locale + '/settings/packages',
217
- }),
218
- ],
219
- }));
220
- // Create e-mail builder
221
- await (0, EmailBuilder_js_1.sendEmailTemplate)(null, {
222
- template: {
223
- type: data.type,
224
- },
225
- recipients,
226
- });
227
- }
228
- }
229
- exports.STPackage = STPackage;
230
- tslib_1.__decorate([
231
- (0, simple_database_1.column)({
232
- primary: true, type: 'string', beforeSave(value) {
233
- return value ?? (0, uuid_1.v4)();
234
- },
235
- })
236
- ], STPackage.prototype, "id", void 0);
237
- tslib_1.__decorate([
238
- (0, simple_database_1.column)({ type: 'string' })
239
- ], STPackage.prototype, "organizationId", void 0);
240
- tslib_1.__decorate([
241
- (0, simple_database_1.column)({ type: 'json', decoder: structures_1.STPackageMeta })
242
- ], STPackage.prototype, "meta", void 0);
243
- tslib_1.__decorate([
244
- (0, simple_database_1.column)({
245
- type: 'datetime', beforeSave(old) {
246
- if (old !== undefined) {
247
- return old;
248
- }
249
- const date = new Date();
250
- date.setMilliseconds(0);
251
- return date;
252
- },
253
- })
254
- ], STPackage.prototype, "createdAt", void 0);
255
- tslib_1.__decorate([
256
- (0, simple_database_1.column)({
257
- type: 'datetime', beforeSave() {
258
- const date = new Date();
259
- date.setMilliseconds(0);
260
- return date;
261
- },
262
- skipUpdate: true,
263
- })
264
- ], STPackage.prototype, "updatedAt", void 0);
265
- tslib_1.__decorate([
266
- (0, simple_database_1.column)({ type: 'datetime', nullable: true })
267
- ], STPackage.prototype, "validAt", void 0);
268
- tslib_1.__decorate([
269
- (0, simple_database_1.column)({ type: 'datetime', nullable: true })
270
- ], STPackage.prototype, "validUntil", void 0);
271
- tslib_1.__decorate([
272
- (0, simple_database_1.column)({ type: 'datetime', nullable: true })
273
- ], STPackage.prototype, "removeAt", void 0);
274
- tslib_1.__decorate([
275
- (0, simple_database_1.column)({ type: 'integer' })
276
- ], STPackage.prototype, "emailCount", void 0);
277
- tslib_1.__decorate([
278
- (0, simple_database_1.column)({ type: 'datetime', nullable: true })
279
- ], STPackage.prototype, "lastEmailAt", void 0);
280
- //# sourceMappingURL=STPackage.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"STPackage.js","sourceRoot":"","sources":["../../../src/models/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EAAE,CAAC;6CACd;AAG/B;IADC,IAAA,wBAAM,EAAC,EAAE,IAAI,EAAE,UAAU,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;2CAChB;AAG7B;IADC,IAAA,wBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;6CACb;AAGf;IADC,IAAA,wBAAM,EAAC,EAAE,IAAI,EAAE,UAAU,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8CACb"}
@@ -1,26 +0,0 @@
1
- import { ManyToOneRelation } from '@simonbackx/simple-database';
2
- import { QueryableModel } from '@stamhoofd/sql';
3
- import { STInvoiceMeta } from '@stamhoofd/structures';
4
- import { Organization } from './index.js';
5
- /**
6
- * Things that should get paid, but are not yet invoiced yet because:
7
- * - total price is too low
8
- * - auto renewals waiting for payment
9
- *
10
- * When they are about to get paid, we create a new invoice model
11
- * and if that model is marked as paid, it will remove the corresponding
12
- * items in this pending invoice.
13
- *
14
- * So please make sure you don't edit existing items, unless you change the id
15
- */
16
- export declare class STPendingInvoice extends QueryableModel {
17
- static table: string;
18
- id: string;
19
- organizationId: string | null;
20
- meta: STInvoiceMeta;
21
- invoiceId: string | null;
22
- createdAt: Date;
23
- updatedAt: Date;
24
- static organization: ManyToOneRelation<"organization", Organization>;
25
- }
26
- //# sourceMappingURL=STPendingInvoice.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"STPendingInvoice.d.ts","sourceRoot":"","sources":["../../../src/models/STPendingInvoice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAGtD,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C;;;;;;;;;;GAUG;AACH,qBAAa,gBAAiB,SAAQ,cAAc;IAChD,MAAM,CAAC,KAAK,SAAgC;IAQ5C,EAAE,EAAG,MAAM,CAAC;IAGZ,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;IAG9B,IAAI,EAAE,aAAa,CAAC;IAKpB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAQ;IAYhC,SAAS,EAAE,IAAI,CAAC;IAUhB,SAAS,EAAE,IAAI,CAAC;IAEhB,MAAM,CAAC,YAAY,kDAAuD;CAC7E"}