@stamhoofd/structures 1.12.8 → 2.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +661 -0
- package/dist/index.d.ts +122 -43
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +132 -43
- package/dist/index.js.map +1 -1
- package/dist/src/BalanceItem.d.ts +44 -0
- package/dist/src/BalanceItem.d.ts.map +1 -0
- package/dist/src/BalanceItem.js +102 -0
- package/dist/src/BalanceItem.js.map +1 -0
- package/dist/src/BalanceItemDetailed.d.ts +30 -0
- package/dist/src/BalanceItemDetailed.d.ts.map +1 -0
- package/dist/src/BalanceItemDetailed.js +81 -0
- package/dist/src/BalanceItemDetailed.js.map +1 -0
- package/dist/src/DNSRecord.js +10 -10
- package/dist/src/DNSRecord.js.map +1 -1
- package/dist/src/DefaultAgeGroup.d.ts +10 -0
- package/dist/src/DefaultAgeGroup.d.ts.map +1 -0
- package/dist/src/DefaultAgeGroup.js +36 -0
- package/dist/src/DefaultAgeGroup.js.map +1 -0
- package/dist/src/Document.d.ts +101 -0
- package/dist/src/Document.d.ts.map +1 -0
- package/dist/src/Document.js +314 -0
- package/dist/src/Document.js.map +1 -0
- package/dist/src/Graph.d.ts +10 -0
- package/dist/src/Graph.d.ts.map +1 -0
- package/dist/src/Graph.js +34 -0
- package/dist/src/Graph.js.map +1 -0
- package/dist/src/Group.d.ts +37 -13
- package/dist/src/Group.d.ts.map +1 -1
- package/dist/src/Group.js +127 -143
- package/dist/src/Group.js.map +1 -1
- package/dist/src/GroupCategory.d.ts +79 -0
- package/dist/src/GroupCategory.d.ts.map +1 -0
- package/dist/src/GroupCategory.js +285 -0
- package/dist/src/GroupCategory.js.map +1 -0
- package/dist/src/GroupGenderType.js +1 -1
- package/dist/src/GroupGenderType.js.map +1 -1
- package/dist/src/GroupPrices.d.ts +29 -4
- package/dist/src/GroupPrices.d.ts.map +1 -1
- package/dist/src/GroupPrices.js +82 -8
- package/dist/src/GroupPrices.js.map +1 -1
- package/dist/src/GroupPrivateSettings.d.ts +2 -0
- package/dist/src/GroupPrivateSettings.d.ts.map +1 -1
- package/dist/src/GroupPrivateSettings.js +7 -2
- package/dist/src/GroupPrivateSettings.js.map +1 -1
- package/dist/src/GroupSettings.d.ts +95 -6
- package/dist/src/GroupSettings.d.ts.map +1 -1
- package/dist/src/GroupSettings.js +413 -27
- package/dist/src/GroupSettings.js.map +1 -1
- package/dist/src/GroupSettings.test.d.ts +2 -0
- package/dist/src/GroupSettings.test.d.ts.map +1 -0
- package/dist/src/GroupSettings.test.js +36 -0
- package/dist/src/GroupSettings.test.js.map +1 -0
- package/dist/src/I18nInterface.d.ts +12 -0
- package/dist/src/I18nInterface.d.ts.map +1 -0
- package/dist/src/I18nInterface.js +3 -0
- package/dist/src/I18nInterface.js.map +1 -0
- package/dist/src/MemberResponsibility.d.ts +13 -0
- package/dist/src/MemberResponsibility.d.ts.map +1 -0
- package/dist/src/MemberResponsibility.js +39 -0
- package/dist/src/MemberResponsibility.js.map +1 -0
- package/dist/src/OpenID.d.ts +25 -0
- package/dist/src/OpenID.d.ts.map +1 -0
- package/dist/src/OpenID.js +53 -0
- package/dist/src/OpenID.js.map +1 -0
- package/dist/src/Organization.d.ts +84 -15
- package/dist/src/Organization.d.ts.map +1 -1
- package/dist/src/Organization.js +186 -49
- package/dist/src/Organization.js.map +1 -1
- package/dist/src/OrganizationEmail.js +6 -6
- package/dist/src/OrganizationEmail.js.map +1 -1
- package/dist/src/OrganizationGenderType.js +1 -1
- package/dist/src/OrganizationGenderType.js.map +1 -1
- package/dist/src/OrganizationMetaData.d.ts +139 -11
- package/dist/src/OrganizationMetaData.d.ts.map +1 -1
- package/dist/src/OrganizationMetaData.js +387 -35
- package/dist/src/OrganizationMetaData.js.map +1 -1
- package/dist/src/OrganizationPrivateMetaData.d.ts +78 -2
- package/dist/src/OrganizationPrivateMetaData.d.ts.map +1 -1
- package/dist/src/OrganizationPrivateMetaData.js +208 -21
- package/dist/src/OrganizationPrivateMetaData.js.map +1 -1
- package/dist/src/OrganizationSimple.d.ts +11 -0
- package/dist/src/OrganizationSimple.d.ts.map +1 -0
- package/dist/src/OrganizationSimple.js +19 -0
- package/dist/src/OrganizationSimple.js.map +1 -0
- package/dist/src/OrganizationType.d.ts +27 -0
- package/dist/src/OrganizationType.d.ts.map +1 -1
- package/dist/src/OrganizationType.js +292 -2
- package/dist/src/OrganizationType.js.map +1 -1
- package/dist/src/PaymentConfiguration.d.ts +46 -0
- package/dist/src/PaymentConfiguration.d.ts.map +1 -0
- package/dist/src/PaymentConfiguration.js +113 -0
- package/dist/src/PaymentConfiguration.js.map +1 -0
- package/dist/src/PaymentMethod.d.ts +20 -1
- package/dist/src/PaymentMethod.d.ts.map +1 -1
- package/dist/src/PaymentMethod.js +70 -2
- package/dist/src/PaymentMethod.js.map +1 -1
- package/dist/src/PaymentProvider.d.ts +7 -0
- package/dist/src/PaymentProvider.d.ts.map +1 -0
- package/dist/src/PaymentProvider.js +11 -0
- package/dist/src/PaymentProvider.js.map +1 -0
- package/dist/src/PaymentStatus.d.ts +4 -0
- package/dist/src/PaymentStatus.d.ts.map +1 -1
- package/dist/src/PaymentStatus.js +17 -2
- package/dist/src/PaymentStatus.js.map +1 -1
- package/dist/src/Permissions.d.ts +181 -11
- package/dist/src/Permissions.d.ts.map +1 -1
- package/dist/src/Permissions.js +730 -28
- package/dist/src/Permissions.js.map +1 -1
- package/dist/src/Platform.d.ts +71 -0
- package/dist/src/Platform.d.ts.map +1 -0
- package/dist/src/Platform.js +169 -0
- package/dist/src/Platform.js.map +1 -0
- package/dist/src/Policy.d.ts +13 -0
- package/dist/src/Policy.d.ts.map +1 -0
- package/dist/src/Policy.js +39 -0
- package/dist/src/Policy.js.map +1 -0
- package/dist/src/PriceBreakdown.d.ts +5 -0
- package/dist/src/PriceBreakdown.d.ts.map +1 -0
- package/dist/src/PriceBreakdown.js +3 -0
- package/dist/src/PriceBreakdown.js.map +1 -0
- package/dist/src/RegisterCodeStatus.d.ts +21 -0
- package/dist/src/RegisterCodeStatus.d.ts.map +1 -0
- package/dist/src/RegisterCodeStatus.js +69 -0
- package/dist/src/RegisterCodeStatus.js.map +1 -0
- package/dist/src/RegistrationPeriod.d.ts +62 -0
- package/dist/src/RegistrationPeriod.d.ts.map +1 -0
- package/dist/src/RegistrationPeriod.js +160 -0
- package/dist/src/RegistrationPeriod.js.map +1 -0
- package/dist/src/RichText.d.ts +7 -0
- package/dist/src/RichText.d.ts.map +1 -0
- package/dist/src/RichText.js +23 -0
- package/dist/src/RichText.js.map +1 -0
- package/dist/src/SeatingPlan.d.ts +144 -0
- package/dist/src/SeatingPlan.d.ts.map +1 -0
- package/dist/src/SeatingPlan.js +570 -0
- package/dist/src/SeatingPlan.js.map +1 -0
- package/dist/src/SeatingPlan.test.d.ts +2 -0
- package/dist/src/SeatingPlan.test.d.ts.map +1 -0
- package/dist/src/SeatingPlan.test.js +127 -0
- package/dist/src/SeatingPlan.test.js.map +1 -0
- package/dist/src/SponsorConfig.d.ts +14 -0
- package/dist/src/SponsorConfig.d.ts.map +1 -0
- package/dist/src/SponsorConfig.js +47 -0
- package/dist/src/SponsorConfig.js.map +1 -0
- package/dist/src/StripeAccount.d.ts +57 -0
- package/dist/src/StripeAccount.d.ts.map +1 -0
- package/dist/src/StripeAccount.js +307 -0
- package/dist/src/StripeAccount.js.map +1 -0
- package/dist/src/UmbrellaOrganization.d.ts +1 -0
- package/dist/src/UmbrellaOrganization.d.ts.map +1 -1
- package/dist/src/UmbrellaOrganization.js +4 -2
- package/dist/src/UmbrellaOrganization.js.map +1 -1
- package/dist/src/User.d.ts +42 -8
- package/dist/src/User.d.ts.map +1 -1
- package/dist/src/User.js +136 -20
- package/dist/src/User.js.map +1 -1
- package/dist/src/UserPermissions.d.ts +25 -0
- package/dist/src/UserPermissions.d.ts.map +1 -0
- package/dist/src/UserPermissions.js +142 -0
- package/dist/src/UserPermissions.js.map +1 -0
- package/dist/src/Version.d.ts +2 -0
- package/dist/src/Version.d.ts.map +1 -0
- package/dist/src/Version.js +5 -0
- package/dist/src/Version.js.map +1 -0
- package/dist/src/{Address.d.ts → addresses/Address.d.ts} +12 -1
- package/dist/src/addresses/Address.d.ts.map +1 -0
- package/dist/src/addresses/Address.js +186 -0
- package/dist/src/addresses/Address.js.map +1 -0
- package/dist/src/addresses/City.d.ts +11 -0
- package/dist/src/addresses/City.d.ts.map +1 -0
- package/dist/src/addresses/City.js +30 -0
- package/dist/src/addresses/City.js.map +1 -0
- package/dist/src/addresses/CountryDecoder.d.ts +17 -0
- package/dist/src/addresses/CountryDecoder.d.ts.map +1 -0
- package/dist/src/addresses/CountryDecoder.js +35 -0
- package/dist/src/addresses/CountryDecoder.js.map +1 -0
- package/dist/src/addresses/Province.d.ts +8 -0
- package/dist/src/addresses/Province.d.ts.map +1 -0
- package/dist/src/addresses/Province.js +19 -0
- package/dist/src/addresses/Province.js.map +1 -0
- package/dist/src/addresses/SearchRegions.d.ts +10 -0
- package/dist/src/addresses/SearchRegions.d.ts.map +1 -0
- package/dist/src/addresses/SearchRegions.js +27 -0
- package/dist/src/addresses/SearchRegions.js.map +1 -0
- package/dist/src/admin/Admin.d.ts +10 -0
- package/dist/src/admin/Admin.d.ts.map +1 -0
- package/dist/src/admin/Admin.js +24 -0
- package/dist/src/admin/Admin.js.map +1 -0
- package/dist/src/admin/MemberSummary.d.ts +25 -0
- package/dist/src/admin/MemberSummary.d.ts.map +1 -0
- package/dist/src/admin/MemberSummary.js +152 -0
- package/dist/src/admin/MemberSummary.js.map +1 -0
- package/dist/src/admin/OrganizationSummary.d.ts +67 -0
- package/dist/src/admin/OrganizationSummary.d.ts.map +1 -0
- package/dist/src/admin/OrganizationSummary.js +204 -0
- package/dist/src/admin/OrganizationSummary.js.map +1 -0
- package/dist/src/admin/StripePayoutExport.d.ts +50 -0
- package/dist/src/admin/StripePayoutExport.d.ts.map +1 -0
- package/dist/src/admin/StripePayoutExport.js +165 -0
- package/dist/src/admin/StripePayoutExport.js.map +1 -0
- package/dist/src/billing/STBillingStatus.d.ts +11 -0
- package/dist/src/billing/STBillingStatus.d.ts.map +1 -0
- package/dist/src/billing/STBillingStatus.js +24 -0
- package/dist/src/billing/STBillingStatus.js.map +1 -0
- package/dist/src/billing/STCredit.d.ts +14 -0
- package/dist/src/billing/STCredit.d.ts.map +1 -0
- package/dist/src/billing/STCredit.js +52 -0
- package/dist/src/billing/STCredit.js.map +1 -0
- package/dist/src/billing/STInvoice.d.ts +114 -0
- package/dist/src/billing/STInvoice.d.ts.map +1 -0
- package/dist/src/billing/STInvoice.js +372 -0
- package/dist/src/billing/STInvoice.js.map +1 -0
- package/dist/src/billing/STPackage.d.ts +89 -0
- package/dist/src/billing/STPackage.d.ts.map +1 -0
- package/dist/src/billing/STPackage.js +345 -0
- package/dist/src/billing/STPackage.js.map +1 -0
- package/dist/src/billing/STPackageBundle.d.ts +26 -0
- package/dist/src/billing/STPackageBundle.d.ts.map +1 -0
- package/dist/src/billing/STPackageBundle.js +209 -0
- package/dist/src/billing/STPackageBundle.js.map +1 -0
- package/dist/src/email/EmailAddressSettings.d.ts +9 -0
- package/dist/src/email/EmailAddressSettings.d.ts.map +1 -0
- package/dist/src/email/EmailAddressSettings.js +26 -0
- package/dist/src/email/EmailAddressSettings.js.map +1 -0
- package/dist/src/email/EmailTemplate.d.ts +67 -0
- package/dist/src/email/EmailTemplate.d.ts.map +1 -0
- package/dist/src/email/EmailTemplate.js +201 -0
- package/dist/src/email/EmailTemplate.js.map +1 -0
- package/dist/src/endpoints/CheckMollieResponse.d.ts +8 -0
- package/dist/src/endpoints/CheckMollieResponse.d.ts.map +1 -0
- package/dist/src/endpoints/CheckMollieResponse.js +21 -0
- package/dist/src/endpoints/CheckMollieResponse.js.map +1 -0
- package/dist/src/endpoints/CreateOrganization.d.ts +0 -9
- package/dist/src/endpoints/CreateOrganization.d.ts.map +1 -1
- package/dist/src/endpoints/CreateOrganization.js +4 -8
- package/dist/src/endpoints/CreateOrganization.js.map +1 -1
- package/dist/src/endpoints/EmailRequest.d.ts +27 -0
- package/dist/src/endpoints/EmailRequest.d.ts.map +1 -1
- package/dist/src/endpoints/EmailRequest.js +112 -19
- package/dist/src/endpoints/EmailRequest.js.map +1 -1
- package/dist/src/endpoints/ForgotPasswordRequest.js +2 -2
- package/dist/src/endpoints/ForgotPasswordRequest.js.map +1 -1
- package/dist/src/endpoints/OrganizationAdmins.d.ts +0 -2
- package/dist/src/endpoints/OrganizationAdmins.d.ts.map +1 -1
- package/dist/src/endpoints/OrganizationAdmins.js +2 -7
- package/dist/src/endpoints/OrganizationAdmins.js.map +1 -1
- package/dist/src/endpoints/OrganizationDomains.d.ts +7 -0
- package/dist/src/endpoints/OrganizationDomains.d.ts.map +1 -1
- package/dist/src/endpoints/OrganizationDomains.js +13 -3
- package/dist/src/endpoints/OrganizationDomains.js.map +1 -1
- package/dist/src/endpoints/RegisterMember.d.ts +6 -0
- package/dist/src/endpoints/RegisterMember.d.ts.map +1 -1
- package/dist/src/endpoints/RegisterMember.js +14 -8
- package/dist/src/endpoints/RegisterMember.js.map +1 -1
- package/dist/src/endpoints/RegisterResponse.d.ts +4 -4
- package/dist/src/endpoints/RegisterResponse.d.ts.map +1 -1
- package/dist/src/endpoints/RegisterResponse.js +7 -8
- package/dist/src/endpoints/RegisterResponse.js.map +1 -1
- package/dist/src/endpoints/SignupResponse.d.ts +8 -0
- package/dist/src/endpoints/SignupResponse.d.ts.map +1 -0
- package/dist/src/endpoints/SignupResponse.js +12 -0
- package/dist/src/endpoints/SignupResponse.js.map +1 -0
- package/dist/src/endpoints/VerifyEmailRequest.d.ts +21 -0
- package/dist/src/endpoints/VerifyEmailRequest.d.ts.map +1 -0
- package/dist/src/endpoints/VerifyEmailRequest.js +27 -0
- package/dist/src/endpoints/VerifyEmailRequest.js.map +1 -0
- package/dist/src/endpoints/WebshopOrdersQuery.d.ts +22 -0
- package/dist/src/endpoints/WebshopOrdersQuery.d.ts.map +1 -0
- package/dist/src/endpoints/WebshopOrdersQuery.js +23 -0
- package/dist/src/endpoints/WebshopOrdersQuery.js.map +1 -0
- package/dist/src/endpoints/WebshopTicketsQuery.d.ts +13 -0
- package/dist/src/endpoints/WebshopTicketsQuery.d.ts.map +1 -0
- package/dist/src/endpoints/WebshopTicketsQuery.js +15 -0
- package/dist/src/endpoints/WebshopTicketsQuery.js.map +1 -0
- package/dist/src/endpoints/WebshopUriAvailabilityResponse.d.ts +5 -0
- package/dist/src/endpoints/WebshopUriAvailabilityResponse.d.ts.map +1 -0
- package/dist/src/endpoints/WebshopUriAvailabilityResponse.js +12 -0
- package/dist/src/endpoints/WebshopUriAvailabilityResponse.js.map +1 -0
- package/dist/src/endpoints/tokens/CreateTokenStruct.d.ts +2 -1
- package/dist/src/endpoints/tokens/CreateTokenStruct.d.ts.map +1 -1
- package/dist/src/endpoints/tokens/CreateTokenStruct.js +4 -0
- package/dist/src/endpoints/tokens/CreateTokenStruct.js.map +1 -1
- package/dist/src/endpoints/tokens/PasswordGrantStruct.d.ts +8 -0
- package/dist/src/endpoints/tokens/PasswordGrantStruct.d.ts.map +1 -0
- package/dist/src/endpoints/tokens/PasswordGrantStruct.js +14 -0
- package/dist/src/endpoints/tokens/PasswordGrantStruct.js.map +1 -0
- package/dist/src/files/File.js.map +1 -1
- package/dist/src/files/Image.d.ts.map +1 -1
- package/dist/src/files/Image.js +12 -4
- package/dist/src/files/Image.js.map +1 -1
- package/dist/src/files/ResolutionRequest.d.ts.map +1 -1
- package/dist/src/files/ResolutionRequest.js +6 -6
- package/dist/src/files/ResolutionRequest.js.map +1 -1
- package/dist/src/filters/ChoicesFilter.d.ts +40 -0
- package/dist/src/filters/ChoicesFilter.d.ts.map +1 -0
- package/dist/src/filters/ChoicesFilter.js +131 -0
- package/dist/src/filters/ChoicesFilter.js.map +1 -0
- package/dist/src/filters/DateFilter.d.ts +41 -0
- package/dist/src/filters/DateFilter.d.ts.map +1 -0
- package/dist/src/filters/DateFilter.js +185 -0
- package/dist/src/filters/DateFilter.js.map +1 -0
- package/dist/src/filters/FilterDefinition.d.ts +51 -0
- package/dist/src/filters/FilterDefinition.d.ts.map +1 -0
- package/dist/src/filters/FilterDefinition.js +70 -0
- package/dist/src/filters/FilterDefinition.js.map +1 -0
- package/dist/src/filters/FilterGroup.d.ts +55 -0
- package/dist/src/filters/FilterGroup.d.ts.map +1 -0
- package/dist/src/filters/FilterGroup.js +194 -0
- package/dist/src/filters/FilterGroup.js.map +1 -0
- package/dist/src/filters/FilterGroup.test.d.ts +2 -0
- package/dist/src/filters/FilterGroup.test.d.ts.map +1 -0
- package/dist/src/filters/FilterGroup.test.js +80 -0
- package/dist/src/filters/FilterGroup.test.js.map +1 -0
- package/dist/src/filters/NumberFilter.d.ts +31 -0
- package/dist/src/filters/NumberFilter.d.ts.map +1 -0
- package/dist/src/filters/NumberFilter.js +167 -0
- package/dist/src/filters/NumberFilter.js.map +1 -0
- package/dist/src/filters/PropertyFilter.d.ts +23 -0
- package/dist/src/filters/PropertyFilter.d.ts.map +1 -0
- package/dist/src/filters/PropertyFilter.js +62 -0
- package/dist/src/filters/PropertyFilter.js.map +1 -0
- package/dist/src/filters/RegistrationsFilter.d.ts +44 -0
- package/dist/src/filters/RegistrationsFilter.d.ts.map +1 -0
- package/dist/src/filters/RegistrationsFilter.js +142 -0
- package/dist/src/filters/RegistrationsFilter.js.map +1 -0
- package/dist/src/filters/StringFilter.d.ts +24 -0
- package/dist/src/filters/StringFilter.d.ts.map +1 -0
- package/dist/src/filters/StringFilter.js +115 -0
- package/dist/src/filters/StringFilter.js.map +1 -0
- package/dist/src/filters/filterDefinitions.d.ts +3 -0
- package/dist/src/filters/filterDefinitions.d.ts.map +1 -0
- package/dist/src/filters/filterDefinitions.js +10 -0
- package/dist/src/filters/filterDefinitions.js.map +1 -0
- package/dist/src/filters/new/FilteredRequest.d.ts +45 -0
- package/dist/src/filters/new/FilteredRequest.d.ts.map +1 -0
- package/dist/src/filters/new/FilteredRequest.js +97 -0
- package/dist/src/filters/new/FilteredRequest.js.map +1 -0
- package/dist/src/filters/new/InMemoryFilter.d.ts +10 -0
- package/dist/src/filters/new/InMemoryFilter.d.ts.map +1 -0
- package/dist/src/filters/new/InMemoryFilter.js +216 -0
- package/dist/src/filters/new/InMemoryFilter.js.map +1 -0
- package/dist/src/filters/new/InMemorySorter.d.ts +12 -0
- package/dist/src/filters/new/InMemorySorter.d.ts.map +1 -0
- package/dist/src/filters/new/InMemorySorter.js +75 -0
- package/dist/src/filters/new/InMemorySorter.js.map +1 -0
- package/dist/src/filters/new/SortList.d.ts +15 -0
- package/dist/src/filters/new/SortList.d.ts.map +1 -0
- package/dist/src/filters/new/SortList.js +43 -0
- package/dist/src/filters/new/SortList.js.map +1 -0
- package/dist/src/filters/new/Sorters.d.ts +8 -0
- package/dist/src/filters/new/Sorters.d.ts.map +1 -0
- package/dist/src/filters/new/Sorters.js +54 -0
- package/dist/src/filters/new/Sorters.js.map +1 -0
- package/dist/src/filters/new/StamhoofdFilter.d.ts +31 -0
- package/dist/src/filters/new/StamhoofdFilter.d.ts.map +1 -0
- package/dist/src/filters/new/StamhoofdFilter.js +14 -0
- package/dist/src/filters/new/StamhoofdFilter.js.map +1 -0
- package/dist/src/grouping/PaginatedResponse.d.ts +6 -6
- package/dist/src/grouping/PaginatedResponse.d.ts.map +1 -1
- package/dist/src/grouping/PaginatedResponse.js +3 -2
- package/dist/src/grouping/PaginatedResponse.js.map +1 -1
- package/dist/src/members/EmergencyContact.d.ts +5 -0
- package/dist/src/members/EmergencyContact.d.ts.map +1 -1
- package/dist/src/members/EmergencyContact.js +26 -6
- package/dist/src/members/EmergencyContact.js.map +1 -1
- package/dist/src/members/Gender.js +1 -1
- package/dist/src/members/Gender.js.map +1 -1
- package/dist/src/members/Member.d.ts +5 -6
- package/dist/src/members/Member.d.ts.map +1 -1
- package/dist/src/members/Member.js +16 -25
- package/dist/src/members/Member.js.map +1 -1
- package/dist/src/members/MemberDetails.d.ts +64 -43
- package/dist/src/members/MemberDetails.d.ts.map +1 -1
- package/dist/src/members/MemberDetails.js +455 -111
- package/dist/src/members/MemberDetails.js.map +1 -1
- package/dist/src/members/MemberDetails.test.d.ts +2 -0
- package/dist/src/members/MemberDetails.test.d.ts.map +1 -0
- package/dist/src/members/MemberDetails.test.js +47 -0
- package/dist/src/members/MemberDetails.test.js.map +1 -0
- package/dist/src/members/MemberResponsibilityRecord.d.ts +10 -0
- package/dist/src/members/MemberResponsibilityRecord.d.ts.map +1 -0
- package/dist/src/members/MemberResponsibilityRecord.js +34 -0
- package/dist/src/members/MemberResponsibilityRecord.js.map +1 -0
- package/dist/src/members/MemberWithRegistrations.d.ts +26 -75
- package/dist/src/members/MemberWithRegistrations.d.ts.map +1 -1
- package/dist/src/members/MemberWithRegistrations.js +73 -248
- package/dist/src/members/MemberWithRegistrations.js.map +1 -1
- package/dist/src/members/MemberWithRegistrationsBlob.d.ts +20 -0
- package/dist/src/members/MemberWithRegistrationsBlob.d.ts.map +1 -0
- package/dist/src/members/MemberWithRegistrationsBlob.js +56 -0
- package/dist/src/members/MemberWithRegistrationsBlob.js.map +1 -0
- package/dist/src/members/ObjectWithRecords.d.ts +10 -0
- package/dist/src/members/ObjectWithRecords.d.ts.map +1 -0
- package/dist/src/members/ObjectWithRecords.js +3 -0
- package/dist/src/members/ObjectWithRecords.js.map +1 -0
- package/dist/src/members/OrganizationRecordsConfiguration.d.ts +80 -0
- package/dist/src/members/OrganizationRecordsConfiguration.d.ts.map +1 -0
- package/dist/src/members/OrganizationRecordsConfiguration.js +185 -0
- package/dist/src/members/OrganizationRecordsConfiguration.js.map +1 -0
- package/dist/src/members/Parent.d.ts +8 -1
- package/dist/src/members/Parent.d.ts.map +1 -1
- package/dist/src/members/Parent.js +85 -10
- package/dist/src/members/Parent.js.map +1 -1
- package/dist/src/members/ParentType.d.ts +5 -0
- package/dist/src/members/ParentType.d.ts.map +1 -1
- package/dist/src/members/ParentType.js +16 -1
- package/dist/src/members/ParentType.js.map +1 -1
- package/dist/src/members/Payment.d.ts +29 -1
- package/dist/src/members/Payment.d.ts.map +1 -1
- package/dist/src/members/Payment.js +159 -12
- package/dist/src/members/Payment.js.map +1 -1
- package/dist/src/members/PaymentDetailed.d.ts +5 -0
- package/dist/src/members/PaymentDetailed.d.ts.map +1 -1
- package/dist/src/members/PaymentDetailed.js +24 -5
- package/dist/src/members/PaymentDetailed.js.map +1 -1
- package/dist/src/members/PaymentGeneral.d.ts +27 -0
- package/dist/src/members/PaymentGeneral.d.ts.map +1 -0
- package/dist/src/members/PaymentGeneral.js +90 -0
- package/dist/src/members/PaymentGeneral.js.map +1 -0
- package/dist/src/members/PaymentPatch.d.ts +7 -0
- package/dist/src/members/PaymentPatch.d.ts.map +1 -1
- package/dist/src/members/PaymentPatch.js +20 -3
- package/dist/src/members/PaymentPatch.js.map +1 -1
- package/dist/src/members/PaymentWithRegistrations.d.ts +6 -0
- package/dist/src/members/PaymentWithRegistrations.d.ts.map +1 -0
- package/dist/src/members/PaymentWithRegistrations.js +14 -0
- package/dist/src/members/PaymentWithRegistrations.js.map +1 -0
- package/dist/src/members/PlatformMember.d.ts +147 -0
- package/dist/src/members/PlatformMember.d.ts.map +1 -0
- package/dist/src/members/PlatformMember.js +613 -0
- package/dist/src/members/PlatformMember.js.map +1 -0
- package/dist/src/members/Registration.d.ts +7 -3
- package/dist/src/members/Registration.d.ts.map +1 -1
- package/dist/src/members/Registration.js +34 -15
- package/dist/src/members/Registration.js.map +1 -1
- package/dist/src/members/RegistrationPatch.js +6 -6
- package/dist/src/members/RegistrationPatch.js.map +1 -1
- package/dist/src/members/RegistrationWithEncryptedMember.d.ts +2 -2
- package/dist/src/members/RegistrationWithEncryptedMember.d.ts.map +1 -1
- package/dist/src/members/RegistrationWithEncryptedMember.js +12 -12
- package/dist/src/members/RegistrationWithEncryptedMember.js.map +1 -1
- package/dist/src/members/RegistrationWithMember.d.ts +0 -2
- package/dist/src/members/RegistrationWithMember.d.ts.map +1 -1
- package/dist/src/members/RegistrationWithMember.js +2 -6
- package/dist/src/members/RegistrationWithMember.js.map +1 -1
- package/dist/src/members/ReviewTime.d.ts +20 -0
- package/dist/src/members/ReviewTime.d.ts.map +1 -0
- package/dist/src/members/ReviewTime.js +75 -0
- package/dist/src/members/ReviewTime.js.map +1 -0
- package/dist/src/members/checkout/OldRegisterCart.d.ts +49 -0
- package/dist/src/members/checkout/OldRegisterCart.d.ts.map +1 -0
- package/dist/src/members/checkout/OldRegisterCart.js +207 -0
- package/dist/src/members/checkout/OldRegisterCart.js.map +1 -0
- package/dist/src/members/checkout/OldRegisterCartPriceCalculator.d.ts +36 -0
- package/dist/src/members/checkout/OldRegisterCartPriceCalculator.d.ts.map +1 -0
- package/dist/src/members/checkout/OldRegisterCartPriceCalculator.js +339 -0
- package/dist/src/members/checkout/OldRegisterCartPriceCalculator.js.map +1 -0
- package/dist/src/members/checkout/OldRegisterCartValidator.d.ts +35 -0
- package/dist/src/members/checkout/OldRegisterCartValidator.d.ts.map +1 -0
- package/dist/src/members/checkout/OldRegisterCartValidator.js +345 -0
- package/dist/src/members/checkout/OldRegisterCartValidator.js.map +1 -0
- package/dist/src/members/checkout/OldRegisterCheckout.d.ts +22 -0
- package/dist/src/members/checkout/OldRegisterCheckout.d.ts.map +1 -0
- package/dist/src/members/checkout/OldRegisterCheckout.js +46 -0
- package/dist/src/members/checkout/OldRegisterCheckout.js.map +1 -0
- package/dist/src/members/checkout/OldRegisterItem.d.ts +59 -0
- package/dist/src/members/checkout/OldRegisterItem.d.ts.map +1 -0
- package/dist/src/members/checkout/OldRegisterItem.js +148 -0
- package/dist/src/members/checkout/OldRegisterItem.js.map +1 -0
- package/dist/src/members/checkout/RegisterCartPriceCalculator.test.d.ts +2 -0
- package/dist/src/members/checkout/RegisterCartPriceCalculator.test.d.ts.map +1 -0
- package/dist/src/members/checkout/RegisterCartPriceCalculator.test.js +1076 -0
- package/dist/src/members/checkout/RegisterCartPriceCalculator.test.js.map +1 -0
- package/dist/src/members/checkout/RegisterCheckout.d.ts +103 -0
- package/dist/src/members/checkout/RegisterCheckout.d.ts.map +1 -0
- package/dist/src/members/checkout/RegisterCheckout.js +569 -0
- package/dist/src/members/checkout/RegisterCheckout.js.map +1 -0
- package/dist/src/members/checkout/UnknownMemberWithRegistrations.d.ts +23 -0
- package/dist/src/members/checkout/UnknownMemberWithRegistrations.d.ts.map +1 -0
- package/dist/src/members/checkout/UnknownMemberWithRegistrations.js +3 -0
- package/dist/src/members/checkout/UnknownMemberWithRegistrations.js.map +1 -0
- package/dist/src/members/records/LegacyRecord.d.ts +20 -0
- package/dist/src/members/records/LegacyRecord.d.ts.map +1 -0
- package/dist/src/members/{Record.js → records/LegacyRecord.js} +28 -12
- package/dist/src/members/records/LegacyRecord.js.map +1 -0
- package/dist/src/members/records/LegacyRecordType.d.ts +74 -0
- package/dist/src/members/records/LegacyRecordType.d.ts.map +1 -0
- package/dist/src/members/records/LegacyRecordType.js +96 -0
- package/dist/src/members/records/LegacyRecordType.js.map +1 -0
- package/dist/src/members/records/RecordAnswer.d.ts +125 -0
- package/dist/src/members/records/RecordAnswer.d.ts.map +1 -0
- package/dist/src/members/records/RecordAnswer.js +516 -0
- package/dist/src/members/records/RecordAnswer.js.map +1 -0
- package/dist/src/members/records/RecordCategory.d.ts +50 -0
- package/dist/src/members/records/RecordCategory.d.ts.map +1 -0
- package/dist/src/members/records/RecordCategory.js +190 -0
- package/dist/src/members/records/RecordCategory.js.map +1 -0
- package/dist/src/members/records/RecordConfigurationFactory.d.ts +17 -0
- package/dist/src/members/records/RecordConfigurationFactory.d.ts.map +1 -0
- package/dist/src/members/records/RecordConfigurationFactory.js +134 -0
- package/dist/src/members/records/RecordConfigurationFactory.js.map +1 -0
- package/dist/src/members/records/RecordFactory.d.ts +12 -0
- package/dist/src/members/records/RecordFactory.d.ts.map +1 -0
- package/dist/src/members/records/RecordFactory.js +528 -0
- package/dist/src/members/records/RecordFactory.js.map +1 -0
- package/dist/src/members/records/RecordSettings.d.ts +120 -0
- package/dist/src/members/records/RecordSettings.d.ts.map +1 -0
- package/dist/src/members/records/RecordSettings.js +251 -0
- package/dist/src/members/records/RecordSettings.js.map +1 -0
- package/dist/src/webshops/Cart.d.ts +25 -0
- package/dist/src/webshops/Cart.d.ts.map +1 -0
- package/dist/src/webshops/Cart.js +135 -0
- package/dist/src/webshops/Cart.js.map +1 -0
- package/dist/src/webshops/CartItem.d.ts +139 -0
- package/dist/src/webshops/CartItem.d.ts.map +1 -0
- package/dist/src/webshops/CartItem.js +714 -0
- package/dist/src/webshops/CartItem.js.map +1 -0
- package/dist/src/webshops/CartItem.test.d.ts +2 -0
- package/dist/src/webshops/CartItem.test.d.ts.map +1 -0
- package/dist/src/webshops/CartItem.test.js +59 -0
- package/dist/src/webshops/CartItem.test.js.map +1 -0
- package/dist/src/webshops/CartStockHelper.d.ts +53 -0
- package/dist/src/webshops/CartStockHelper.d.ts.map +1 -0
- package/dist/src/webshops/CartStockHelper.js +329 -0
- package/dist/src/webshops/CartStockHelper.js.map +1 -0
- package/dist/src/webshops/Category.d.ts +9 -0
- package/dist/src/webshops/Category.d.ts.map +1 -0
- package/dist/src/webshops/Category.js +32 -0
- package/dist/src/webshops/Category.js.map +1 -0
- package/dist/src/webshops/Checkout.d.ts +81 -0
- package/dist/src/webshops/Checkout.d.ts.map +1 -0
- package/dist/src/webshops/Checkout.js +529 -0
- package/dist/src/webshops/Checkout.js.map +1 -0
- package/dist/src/webshops/Customer.d.ts +9 -0
- package/dist/src/webshops/Customer.d.ts.map +1 -0
- package/dist/src/webshops/Customer.js +37 -0
- package/dist/src/webshops/Customer.js.map +1 -0
- package/dist/src/webshops/Discount.d.ts +131 -0
- package/dist/src/webshops/Discount.d.ts.map +1 -0
- package/dist/src/webshops/Discount.js +541 -0
- package/dist/src/webshops/Discount.js.map +1 -0
- package/dist/src/webshops/DiscountCode.d.ts +18 -0
- package/dist/src/webshops/DiscountCode.d.ts.map +1 -0
- package/dist/src/webshops/DiscountCode.js +52 -0
- package/dist/src/webshops/DiscountCode.js.map +1 -0
- package/dist/src/webshops/Order.d.ts +93 -0
- package/dist/src/webshops/Order.d.ts.map +1 -0
- package/dist/src/webshops/Order.js +515 -0
- package/dist/src/webshops/Order.js.map +1 -0
- package/dist/src/webshops/Product.d.ts +139 -0
- package/dist/src/webshops/Product.d.ts.map +1 -0
- package/dist/src/webshops/Product.js +480 -0
- package/dist/src/webshops/Product.js.map +1 -0
- package/dist/src/webshops/Ticket.d.ts +75 -0
- package/dist/src/webshops/Ticket.d.ts.map +1 -0
- package/dist/src/webshops/Ticket.js +248 -0
- package/dist/src/webshops/Ticket.js.map +1 -0
- package/dist/src/webshops/TransferSettings.d.ts +21 -0
- package/dist/src/webshops/TransferSettings.d.ts.map +1 -0
- package/dist/src/webshops/TransferSettings.js +120 -0
- package/dist/src/webshops/TransferSettings.js.map +1 -0
- package/dist/src/webshops/Webshop.d.ts +72 -0
- package/dist/src/webshops/Webshop.d.ts.map +1 -0
- package/dist/src/webshops/Webshop.js +292 -0
- package/dist/src/webshops/Webshop.js.map +1 -0
- package/dist/src/webshops/WebshopField.d.ts +14 -0
- package/dist/src/webshops/WebshopField.d.ts.map +1 -0
- package/dist/src/webshops/WebshopField.js +56 -0
- package/dist/src/webshops/WebshopField.js.map +1 -0
- package/dist/src/webshops/WebshopMetaData.d.ts +247 -0
- package/dist/src/webshops/WebshopMetaData.d.ts.map +1 -0
- package/dist/src/webshops/WebshopMetaData.js +685 -0
- package/dist/src/webshops/WebshopMetaData.js.map +1 -0
- package/esm/dist/index.d.ts +122 -43
- package/esm/dist/index.d.ts.map +1 -1
- package/esm/dist/index.js +131 -43
- package/esm/dist/index.js.map +1 -1
- package/esm/dist/src/BalanceItem.d.ts +44 -0
- package/esm/dist/src/BalanceItem.d.ts.map +1 -0
- package/esm/dist/src/BalanceItem.js +93 -0
- package/esm/dist/src/BalanceItem.js.map +1 -0
- package/esm/dist/src/BalanceItemDetailed.d.ts +30 -0
- package/esm/dist/src/BalanceItemDetailed.d.ts.map +1 -0
- package/esm/dist/src/BalanceItemDetailed.js +75 -0
- package/esm/dist/src/BalanceItemDetailed.js.map +1 -0
- package/esm/dist/src/DefaultAgeGroup.d.ts +10 -0
- package/esm/dist/src/DefaultAgeGroup.d.ts.map +1 -0
- package/esm/dist/src/DefaultAgeGroup.js +32 -0
- package/esm/dist/src/DefaultAgeGroup.js.map +1 -0
- package/esm/dist/src/Document.d.ts +101 -0
- package/esm/dist/src/Document.d.ts.map +1 -0
- package/esm/dist/src/Document.js +303 -0
- package/esm/dist/src/Document.js.map +1 -0
- package/esm/dist/src/Graph.d.ts +10 -0
- package/esm/dist/src/Graph.d.ts.map +1 -0
- package/esm/dist/src/Graph.js +29 -0
- package/esm/dist/src/Graph.js.map +1 -0
- package/esm/dist/src/Group.d.ts +37 -13
- package/esm/dist/src/Group.d.ts.map +1 -1
- package/esm/dist/src/Group.js +123 -139
- package/esm/dist/src/Group.js.map +1 -1
- package/esm/dist/src/GroupCategory.d.ts +79 -0
- package/esm/dist/src/GroupCategory.d.ts.map +1 -0
- package/esm/dist/src/GroupCategory.js +278 -0
- package/esm/dist/src/GroupCategory.js.map +1 -0
- package/esm/dist/src/GroupPrices.d.ts +29 -4
- package/esm/dist/src/GroupPrices.d.ts.map +1 -1
- package/esm/dist/src/GroupPrices.js +74 -1
- package/esm/dist/src/GroupPrices.js.map +1 -1
- package/esm/dist/src/GroupPrivateSettings.d.ts +2 -0
- package/esm/dist/src/GroupPrivateSettings.d.ts.map +1 -1
- package/esm/dist/src/GroupPrivateSettings.js +5 -0
- package/esm/dist/src/GroupPrivateSettings.js.map +1 -1
- package/esm/dist/src/GroupSettings.d.ts +95 -6
- package/esm/dist/src/GroupSettings.d.ts.map +1 -1
- package/esm/dist/src/GroupSettings.js +395 -10
- package/esm/dist/src/GroupSettings.js.map +1 -1
- package/esm/dist/src/GroupSettings.test.d.ts +2 -0
- package/esm/dist/src/GroupSettings.test.d.ts.map +1 -0
- package/esm/dist/src/GroupSettings.test.js +34 -0
- package/esm/dist/src/GroupSettings.test.js.map +1 -0
- package/esm/dist/src/I18nInterface.d.ts +12 -0
- package/esm/dist/src/I18nInterface.d.ts.map +1 -0
- package/esm/dist/src/I18nInterface.js +2 -0
- package/esm/dist/src/I18nInterface.js.map +1 -0
- package/esm/dist/src/MemberResponsibility.d.ts +13 -0
- package/esm/dist/src/MemberResponsibility.d.ts.map +1 -0
- package/esm/dist/src/MemberResponsibility.js +35 -0
- package/esm/dist/src/MemberResponsibility.js.map +1 -0
- package/esm/dist/src/OpenID.d.ts +25 -0
- package/esm/dist/src/OpenID.d.ts.map +1 -0
- package/esm/dist/src/OpenID.js +48 -0
- package/esm/dist/src/OpenID.js.map +1 -0
- package/esm/dist/src/Organization.d.ts +84 -15
- package/esm/dist/src/Organization.d.ts.map +1 -1
- package/esm/dist/src/Organization.js +176 -38
- package/esm/dist/src/Organization.js.map +1 -1
- package/esm/dist/src/OrganizationMetaData.d.ts +139 -11
- package/esm/dist/src/OrganizationMetaData.d.ts.map +1 -1
- package/esm/dist/src/OrganizationMetaData.js +381 -31
- package/esm/dist/src/OrganizationMetaData.js.map +1 -1
- package/esm/dist/src/OrganizationPrivateMetaData.d.ts +78 -2
- package/esm/dist/src/OrganizationPrivateMetaData.d.ts.map +1 -1
- package/esm/dist/src/OrganizationPrivateMetaData.js +189 -4
- package/esm/dist/src/OrganizationPrivateMetaData.js.map +1 -1
- package/esm/dist/src/OrganizationSimple.d.ts +11 -0
- package/esm/dist/src/OrganizationSimple.d.ts.map +1 -0
- package/esm/dist/src/OrganizationSimple.js +15 -0
- package/esm/dist/src/OrganizationSimple.js.map +1 -0
- package/esm/dist/src/OrganizationType.d.ts +27 -0
- package/esm/dist/src/OrganizationType.d.ts.map +1 -1
- package/esm/dist/src/OrganizationType.js +291 -1
- package/esm/dist/src/OrganizationType.js.map +1 -1
- package/esm/dist/src/PaymentConfiguration.d.ts +46 -0
- package/esm/dist/src/PaymentConfiguration.d.ts.map +1 -0
- package/esm/dist/src/PaymentConfiguration.js +106 -0
- package/esm/dist/src/PaymentConfiguration.js.map +1 -0
- package/esm/dist/src/PaymentMethod.d.ts +20 -1
- package/esm/dist/src/PaymentMethod.d.ts.map +1 -1
- package/esm/dist/src/PaymentMethod.js +65 -0
- package/esm/dist/src/PaymentMethod.js.map +1 -1
- package/esm/dist/src/PaymentProvider.d.ts +7 -0
- package/esm/dist/src/PaymentProvider.d.ts.map +1 -0
- package/esm/dist/src/PaymentProvider.js +8 -0
- package/esm/dist/src/PaymentProvider.js.map +1 -0
- package/esm/dist/src/PaymentStatus.d.ts +4 -0
- package/esm/dist/src/PaymentStatus.d.ts.map +1 -1
- package/esm/dist/src/PaymentStatus.js +14 -0
- package/esm/dist/src/PaymentStatus.js.map +1 -1
- package/esm/dist/src/Permissions.d.ts +181 -11
- package/esm/dist/src/Permissions.d.ts.map +1 -1
- package/esm/dist/src/Permissions.js +718 -23
- package/esm/dist/src/Permissions.js.map +1 -1
- package/esm/dist/src/Platform.d.ts +71 -0
- package/esm/dist/src/Platform.d.ts.map +1 -0
- package/esm/dist/src/Platform.js +160 -0
- package/esm/dist/src/Platform.js.map +1 -0
- package/esm/dist/src/Policy.d.ts +13 -0
- package/esm/dist/src/Policy.d.ts.map +1 -0
- package/esm/dist/src/Policy.js +35 -0
- package/esm/dist/src/Policy.js.map +1 -0
- package/esm/dist/src/PriceBreakdown.d.ts +5 -0
- package/esm/dist/src/PriceBreakdown.d.ts.map +1 -0
- package/esm/dist/src/PriceBreakdown.js +2 -0
- package/esm/dist/src/PriceBreakdown.js.map +1 -0
- package/esm/dist/src/RegisterCodeStatus.d.ts +21 -0
- package/esm/dist/src/RegisterCodeStatus.d.ts.map +1 -0
- package/esm/dist/src/RegisterCodeStatus.js +63 -0
- package/esm/dist/src/RegisterCodeStatus.js.map +1 -0
- package/esm/dist/src/RegistrationPeriod.d.ts +62 -0
- package/esm/dist/src/RegistrationPeriod.d.ts.map +1 -0
- package/esm/dist/src/RegistrationPeriod.js +152 -0
- package/esm/dist/src/RegistrationPeriod.js.map +1 -0
- package/esm/dist/src/RichText.d.ts +7 -0
- package/esm/dist/src/RichText.d.ts.map +1 -0
- package/esm/dist/src/RichText.js +19 -0
- package/esm/dist/src/RichText.js.map +1 -0
- package/esm/dist/src/SeatingPlan.d.ts +144 -0
- package/esm/dist/src/SeatingPlan.d.ts.map +1 -0
- package/esm/dist/src/SeatingPlan.js +559 -0
- package/esm/dist/src/SeatingPlan.js.map +1 -0
- package/esm/dist/src/SeatingPlan.test.d.ts +2 -0
- package/esm/dist/src/SeatingPlan.test.d.ts.map +1 -0
- package/esm/dist/src/SeatingPlan.test.js +125 -0
- package/esm/dist/src/SeatingPlan.test.js.map +1 -0
- package/esm/dist/src/SponsorConfig.d.ts +14 -0
- package/esm/dist/src/SponsorConfig.d.ts.map +1 -0
- package/esm/dist/src/SponsorConfig.js +42 -0
- package/esm/dist/src/SponsorConfig.js.map +1 -0
- package/esm/dist/src/StripeAccount.d.ts +57 -0
- package/esm/dist/src/StripeAccount.d.ts.map +1 -0
- package/esm/dist/src/StripeAccount.js +296 -0
- package/esm/dist/src/StripeAccount.js.map +1 -0
- package/esm/dist/src/UmbrellaOrganization.d.ts +1 -0
- package/esm/dist/src/UmbrellaOrganization.d.ts.map +1 -1
- package/esm/dist/src/UmbrellaOrganization.js +3 -1
- package/esm/dist/src/UmbrellaOrganization.js.map +1 -1
- package/esm/dist/src/User.d.ts +42 -8
- package/esm/dist/src/User.d.ts.map +1 -1
- package/esm/dist/src/User.js +125 -13
- package/esm/dist/src/User.js.map +1 -1
- package/esm/dist/src/UserPermissions.d.ts +25 -0
- package/esm/dist/src/UserPermissions.d.ts.map +1 -0
- package/esm/dist/src/UserPermissions.js +138 -0
- package/esm/dist/src/UserPermissions.js.map +1 -0
- package/esm/dist/src/Version.d.ts +2 -0
- package/esm/dist/src/Version.d.ts.map +1 -0
- package/esm/dist/src/Version.js +2 -0
- package/esm/dist/src/Version.js.map +1 -0
- package/esm/dist/src/{Address.d.ts → addresses/Address.d.ts} +12 -1
- package/esm/dist/src/addresses/Address.d.ts.map +1 -0
- package/esm/dist/src/addresses/Address.js +181 -0
- package/esm/dist/src/addresses/Address.js.map +1 -0
- package/esm/dist/src/addresses/City.d.ts +11 -0
- package/esm/dist/src/addresses/City.d.ts.map +1 -0
- package/esm/dist/src/addresses/City.js +26 -0
- package/esm/dist/src/addresses/City.js.map +1 -0
- package/esm/dist/src/addresses/CountryDecoder.d.ts +17 -0
- package/esm/dist/src/addresses/CountryDecoder.d.ts.map +1 -0
- package/esm/dist/src/addresses/CountryDecoder.js +31 -0
- package/esm/dist/src/addresses/CountryDecoder.js.map +1 -0
- package/esm/dist/src/addresses/Province.d.ts +8 -0
- package/esm/dist/src/addresses/Province.d.ts.map +1 -0
- package/esm/dist/src/addresses/Province.js +15 -0
- package/esm/dist/src/addresses/Province.js.map +1 -0
- package/esm/dist/src/addresses/SearchRegions.d.ts +10 -0
- package/esm/dist/src/addresses/SearchRegions.d.ts.map +1 -0
- package/esm/dist/src/addresses/SearchRegions.js +23 -0
- package/esm/dist/src/addresses/SearchRegions.js.map +1 -0
- package/esm/dist/src/admin/Admin.d.ts +10 -0
- package/esm/dist/src/admin/Admin.d.ts.map +1 -0
- package/esm/dist/src/admin/Admin.js +19 -0
- package/esm/dist/src/admin/Admin.js.map +1 -0
- package/esm/dist/src/admin/MemberSummary.d.ts +25 -0
- package/esm/dist/src/admin/MemberSummary.d.ts.map +1 -0
- package/esm/dist/src/admin/MemberSummary.js +148 -0
- package/esm/dist/src/admin/MemberSummary.js.map +1 -0
- package/esm/dist/src/admin/OrganizationSummary.d.ts +67 -0
- package/esm/dist/src/admin/OrganizationSummary.d.ts.map +1 -0
- package/esm/dist/src/admin/OrganizationSummary.js +196 -0
- package/esm/dist/src/admin/OrganizationSummary.js.map +1 -0
- package/esm/dist/src/admin/StripePayoutExport.d.ts +50 -0
- package/esm/dist/src/admin/StripePayoutExport.d.ts.map +1 -0
- package/esm/dist/src/admin/StripePayoutExport.js +158 -0
- package/esm/dist/src/admin/StripePayoutExport.js.map +1 -0
- package/esm/dist/src/billing/STBillingStatus.d.ts +11 -0
- package/esm/dist/src/billing/STBillingStatus.d.ts.map +1 -0
- package/esm/dist/src/billing/STBillingStatus.js +20 -0
- package/esm/dist/src/billing/STBillingStatus.js.map +1 -0
- package/esm/dist/src/billing/STCredit.d.ts +14 -0
- package/esm/dist/src/billing/STCredit.d.ts.map +1 -0
- package/esm/dist/src/billing/STCredit.js +48 -0
- package/esm/dist/src/billing/STCredit.js.map +1 -0
- package/esm/dist/src/billing/STInvoice.d.ts +114 -0
- package/esm/dist/src/billing/STInvoice.d.ts.map +1 -0
- package/esm/dist/src/billing/STInvoice.js +362 -0
- package/esm/dist/src/billing/STInvoice.js.map +1 -0
- package/esm/dist/src/billing/STPackage.d.ts +89 -0
- package/esm/dist/src/billing/STPackage.d.ts.map +1 -0
- package/esm/dist/src/billing/STPackage.js +337 -0
- package/esm/dist/src/billing/STPackage.js.map +1 -0
- package/esm/dist/src/billing/STPackageBundle.d.ts +26 -0
- package/esm/dist/src/billing/STPackageBundle.d.ts.map +1 -0
- package/esm/dist/src/billing/STPackageBundle.js +205 -0
- package/esm/dist/src/billing/STPackageBundle.js.map +1 -0
- package/esm/dist/src/email/EmailAddressSettings.d.ts +9 -0
- package/esm/dist/src/email/EmailAddressSettings.d.ts.map +1 -0
- package/esm/dist/src/email/EmailAddressSettings.js +22 -0
- package/esm/dist/src/email/EmailAddressSettings.js.map +1 -0
- package/esm/dist/src/email/EmailTemplate.d.ts +67 -0
- package/esm/dist/src/email/EmailTemplate.d.ts.map +1 -0
- package/esm/dist/src/email/EmailTemplate.js +197 -0
- package/esm/dist/src/email/EmailTemplate.js.map +1 -0
- package/esm/dist/src/endpoints/CheckMollieResponse.d.ts +8 -0
- package/esm/dist/src/endpoints/CheckMollieResponse.d.ts.map +1 -0
- package/esm/dist/src/endpoints/CheckMollieResponse.js +17 -0
- package/esm/dist/src/endpoints/CheckMollieResponse.js.map +1 -0
- package/esm/dist/src/endpoints/CreateOrganization.d.ts +0 -9
- package/esm/dist/src/endpoints/CreateOrganization.d.ts.map +1 -1
- package/esm/dist/src/endpoints/CreateOrganization.js +1 -5
- package/esm/dist/src/endpoints/CreateOrganization.js.map +1 -1
- package/esm/dist/src/endpoints/EmailRequest.d.ts +27 -0
- package/esm/dist/src/endpoints/EmailRequest.d.ts.map +1 -1
- package/esm/dist/src/endpoints/EmailRequest.js +93 -1
- package/esm/dist/src/endpoints/EmailRequest.js.map +1 -1
- package/esm/dist/src/endpoints/OrganizationAdmins.d.ts +0 -2
- package/esm/dist/src/endpoints/OrganizationAdmins.d.ts.map +1 -1
- package/esm/dist/src/endpoints/OrganizationAdmins.js +0 -5
- package/esm/dist/src/endpoints/OrganizationAdmins.js.map +1 -1
- package/esm/dist/src/endpoints/OrganizationDomains.d.ts +7 -0
- package/esm/dist/src/endpoints/OrganizationDomains.d.ts.map +1 -1
- package/esm/dist/src/endpoints/OrganizationDomains.js +11 -1
- package/esm/dist/src/endpoints/OrganizationDomains.js.map +1 -1
- package/esm/dist/src/endpoints/RegisterMember.d.ts +6 -0
- package/esm/dist/src/endpoints/RegisterMember.d.ts.map +1 -1
- package/esm/dist/src/endpoints/RegisterMember.js +6 -0
- package/esm/dist/src/endpoints/RegisterMember.js.map +1 -1
- package/esm/dist/src/endpoints/RegisterResponse.d.ts +4 -4
- package/esm/dist/src/endpoints/RegisterResponse.d.ts.map +1 -1
- package/esm/dist/src/endpoints/RegisterResponse.js +4 -5
- package/esm/dist/src/endpoints/RegisterResponse.js.map +1 -1
- package/esm/dist/src/endpoints/SignupResponse.d.ts +8 -0
- package/esm/dist/src/endpoints/SignupResponse.d.ts.map +1 -0
- package/esm/dist/src/endpoints/SignupResponse.js +8 -0
- package/esm/dist/src/endpoints/SignupResponse.js.map +1 -0
- package/esm/dist/src/endpoints/VerifyEmailRequest.d.ts +21 -0
- package/esm/dist/src/endpoints/VerifyEmailRequest.d.ts.map +1 -0
- package/esm/dist/src/endpoints/VerifyEmailRequest.js +21 -0
- package/esm/dist/src/endpoints/VerifyEmailRequest.js.map +1 -0
- package/esm/dist/src/endpoints/WebshopOrdersQuery.d.ts +22 -0
- package/esm/dist/src/endpoints/WebshopOrdersQuery.d.ts.map +1 -0
- package/esm/dist/src/endpoints/WebshopOrdersQuery.js +19 -0
- package/esm/dist/src/endpoints/WebshopOrdersQuery.js.map +1 -0
- package/esm/dist/src/endpoints/WebshopTicketsQuery.d.ts +13 -0
- package/esm/dist/src/endpoints/WebshopTicketsQuery.d.ts.map +1 -0
- package/esm/dist/src/endpoints/WebshopTicketsQuery.js +11 -0
- package/esm/dist/src/endpoints/WebshopTicketsQuery.js.map +1 -0
- package/esm/dist/src/endpoints/WebshopUriAvailabilityResponse.d.ts +5 -0
- package/esm/dist/src/endpoints/WebshopUriAvailabilityResponse.d.ts.map +1 -0
- package/esm/dist/src/endpoints/WebshopUriAvailabilityResponse.js +8 -0
- package/esm/dist/src/endpoints/WebshopUriAvailabilityResponse.js.map +1 -0
- package/esm/dist/src/endpoints/tokens/CreateTokenStruct.d.ts +2 -1
- package/esm/dist/src/endpoints/tokens/CreateTokenStruct.d.ts.map +1 -1
- package/esm/dist/src/endpoints/tokens/CreateTokenStruct.js +4 -0
- package/esm/dist/src/endpoints/tokens/CreateTokenStruct.js.map +1 -1
- package/esm/dist/src/endpoints/tokens/PasswordGrantStruct.d.ts +8 -0
- package/esm/dist/src/endpoints/tokens/PasswordGrantStruct.d.ts.map +1 -0
- package/esm/dist/src/endpoints/tokens/PasswordGrantStruct.js +10 -0
- package/esm/dist/src/endpoints/tokens/PasswordGrantStruct.js.map +1 -0
- package/esm/dist/src/files/File.js.map +1 -1
- package/esm/dist/src/files/Image.d.ts.map +1 -1
- package/esm/dist/src/files/Image.js +8 -0
- package/esm/dist/src/files/Image.js.map +1 -1
- package/esm/dist/src/files/ResolutionRequest.d.ts.map +1 -1
- package/esm/dist/src/files/ResolutionRequest.js +1 -1
- package/esm/dist/src/files/ResolutionRequest.js.map +1 -1
- package/esm/dist/src/filters/ChoicesFilter.d.ts +40 -0
- package/esm/dist/src/filters/ChoicesFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/ChoicesFilter.js +125 -0
- package/esm/dist/src/filters/ChoicesFilter.js.map +1 -0
- package/esm/dist/src/filters/DateFilter.d.ts +41 -0
- package/esm/dist/src/filters/DateFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/DateFilter.js +180 -0
- package/esm/dist/src/filters/DateFilter.js.map +1 -0
- package/esm/dist/src/filters/FilterDefinition.d.ts +51 -0
- package/esm/dist/src/filters/FilterDefinition.d.ts.map +1 -0
- package/esm/dist/src/filters/FilterDefinition.js +63 -0
- package/esm/dist/src/filters/FilterDefinition.js.map +1 -0
- package/esm/dist/src/filters/FilterGroup.d.ts +55 -0
- package/esm/dist/src/filters/FilterGroup.d.ts.map +1 -0
- package/esm/dist/src/filters/FilterGroup.js +188 -0
- package/esm/dist/src/filters/FilterGroup.js.map +1 -0
- package/esm/dist/src/filters/FilterGroup.test.d.ts +2 -0
- package/esm/dist/src/filters/FilterGroup.test.d.ts.map +1 -0
- package/esm/dist/src/filters/FilterGroup.test.js +78 -0
- package/esm/dist/src/filters/FilterGroup.test.js.map +1 -0
- package/esm/dist/src/filters/NumberFilter.d.ts +31 -0
- package/esm/dist/src/filters/NumberFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/NumberFilter.js +162 -0
- package/esm/dist/src/filters/NumberFilter.js.map +1 -0
- package/esm/dist/src/filters/PropertyFilter.d.ts +23 -0
- package/esm/dist/src/filters/PropertyFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/PropertyFilter.js +58 -0
- package/esm/dist/src/filters/PropertyFilter.js.map +1 -0
- package/esm/dist/src/filters/RegistrationsFilter.d.ts +44 -0
- package/esm/dist/src/filters/RegistrationsFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/RegistrationsFilter.js +136 -0
- package/esm/dist/src/filters/RegistrationsFilter.js.map +1 -0
- package/esm/dist/src/filters/StringFilter.d.ts +24 -0
- package/esm/dist/src/filters/StringFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/StringFilter.js +110 -0
- package/esm/dist/src/filters/StringFilter.js.map +1 -0
- package/esm/dist/src/filters/filterDefinitions.d.ts +3 -0
- package/esm/dist/src/filters/filterDefinitions.d.ts.map +1 -0
- package/esm/dist/src/filters/filterDefinitions.js +7 -0
- package/esm/dist/src/filters/filterDefinitions.js.map +1 -0
- package/esm/dist/src/filters/new/FilteredRequest.d.ts +45 -0
- package/esm/dist/src/filters/new/FilteredRequest.d.ts.map +1 -0
- package/esm/dist/src/filters/new/FilteredRequest.js +89 -0
- package/esm/dist/src/filters/new/FilteredRequest.js.map +1 -0
- package/esm/dist/src/filters/new/InMemoryFilter.d.ts +10 -0
- package/esm/dist/src/filters/new/InMemoryFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/new/InMemoryFilter.js +212 -0
- package/esm/dist/src/filters/new/InMemoryFilter.js.map +1 -0
- package/esm/dist/src/filters/new/InMemorySorter.d.ts +12 -0
- package/esm/dist/src/filters/new/InMemorySorter.d.ts.map +1 -0
- package/esm/dist/src/filters/new/InMemorySorter.js +71 -0
- package/esm/dist/src/filters/new/InMemorySorter.js.map +1 -0
- package/esm/dist/src/filters/new/SortList.d.ts +15 -0
- package/esm/dist/src/filters/new/SortList.d.ts.map +1 -0
- package/esm/dist/src/filters/new/SortList.js +38 -0
- package/esm/dist/src/filters/new/SortList.js.map +1 -0
- package/esm/dist/src/filters/new/Sorters.d.ts +8 -0
- package/esm/dist/src/filters/new/Sorters.d.ts.map +1 -0
- package/esm/dist/src/filters/new/Sorters.js +50 -0
- package/esm/dist/src/filters/new/Sorters.js.map +1 -0
- package/esm/dist/src/filters/new/StamhoofdFilter.d.ts +31 -0
- package/esm/dist/src/filters/new/StamhoofdFilter.d.ts.map +1 -0
- package/esm/dist/src/filters/new/StamhoofdFilter.js +10 -0
- package/esm/dist/src/filters/new/StamhoofdFilter.js.map +1 -0
- package/esm/dist/src/grouping/PaginatedResponse.d.ts +6 -6
- package/esm/dist/src/grouping/PaginatedResponse.d.ts.map +1 -1
- package/esm/dist/src/grouping/PaginatedResponse.js +3 -2
- package/esm/dist/src/grouping/PaginatedResponse.js.map +1 -1
- package/esm/dist/src/members/EmergencyContact.d.ts +5 -0
- package/esm/dist/src/members/EmergencyContact.d.ts.map +1 -1
- package/esm/dist/src/members/EmergencyContact.js +21 -1
- package/esm/dist/src/members/EmergencyContact.js.map +1 -1
- package/esm/dist/src/members/Member.d.ts +5 -6
- package/esm/dist/src/members/Member.d.ts.map +1 -1
- package/esm/dist/src/members/Member.js +13 -22
- package/esm/dist/src/members/Member.js.map +1 -1
- package/esm/dist/src/members/MemberDetails.d.ts +64 -43
- package/esm/dist/src/members/MemberDetails.d.ts.map +1 -1
- package/esm/dist/src/members/MemberDetails.js +441 -96
- package/esm/dist/src/members/MemberDetails.js.map +1 -1
- package/esm/dist/src/members/MemberDetails.test.d.ts +2 -0
- package/esm/dist/src/members/MemberDetails.test.d.ts.map +1 -0
- package/esm/dist/src/members/MemberDetails.test.js +45 -0
- package/esm/dist/src/members/MemberDetails.test.js.map +1 -0
- package/esm/dist/src/members/MemberResponsibilityRecord.d.ts +10 -0
- package/esm/dist/src/members/MemberResponsibilityRecord.d.ts.map +1 -0
- package/esm/dist/src/members/MemberResponsibilityRecord.js +30 -0
- package/esm/dist/src/members/MemberResponsibilityRecord.js.map +1 -0
- package/esm/dist/src/members/MemberWithRegistrations.d.ts +26 -75
- package/esm/dist/src/members/MemberWithRegistrations.d.ts.map +1 -1
- package/esm/dist/src/members/MemberWithRegistrations.js +67 -240
- package/esm/dist/src/members/MemberWithRegistrations.js.map +1 -1
- package/esm/dist/src/members/MemberWithRegistrationsBlob.d.ts +20 -0
- package/esm/dist/src/members/MemberWithRegistrationsBlob.d.ts.map +1 -0
- package/esm/dist/src/members/MemberWithRegistrationsBlob.js +51 -0
- package/esm/dist/src/members/MemberWithRegistrationsBlob.js.map +1 -0
- package/esm/dist/src/members/ObjectWithRecords.d.ts +10 -0
- package/esm/dist/src/members/ObjectWithRecords.d.ts.map +1 -0
- package/esm/dist/src/members/ObjectWithRecords.js +2 -0
- package/esm/dist/src/members/ObjectWithRecords.js.map +1 -0
- package/esm/dist/src/members/OrganizationRecordsConfiguration.d.ts +80 -0
- package/esm/dist/src/members/OrganizationRecordsConfiguration.d.ts.map +1 -0
- package/esm/dist/src/members/OrganizationRecordsConfiguration.js +178 -0
- package/esm/dist/src/members/OrganizationRecordsConfiguration.js.map +1 -0
- package/esm/dist/src/members/Parent.d.ts +8 -1
- package/esm/dist/src/members/Parent.d.ts.map +1 -1
- package/esm/dist/src/members/Parent.js +76 -1
- package/esm/dist/src/members/Parent.js.map +1 -1
- package/esm/dist/src/members/ParentType.d.ts +5 -0
- package/esm/dist/src/members/ParentType.d.ts.map +1 -1
- package/esm/dist/src/members/ParentType.js +15 -0
- package/esm/dist/src/members/ParentType.js.map +1 -1
- package/esm/dist/src/members/Payment.d.ts +29 -1
- package/esm/dist/src/members/Payment.d.ts.map +1 -1
- package/esm/dist/src/members/Payment.js +150 -5
- package/esm/dist/src/members/Payment.js.map +1 -1
- package/esm/dist/src/members/PaymentDetailed.d.ts +5 -0
- package/esm/dist/src/members/PaymentDetailed.d.ts.map +1 -1
- package/esm/dist/src/members/PaymentDetailed.js +22 -3
- package/esm/dist/src/members/PaymentDetailed.js.map +1 -1
- package/esm/dist/src/members/PaymentGeneral.d.ts +27 -0
- package/esm/dist/src/members/PaymentGeneral.d.ts.map +1 -0
- package/esm/dist/src/members/PaymentGeneral.js +86 -0
- package/esm/dist/src/members/PaymentGeneral.js.map +1 -0
- package/esm/dist/src/members/PaymentPatch.d.ts +7 -0
- package/esm/dist/src/members/PaymentPatch.d.ts.map +1 -1
- package/esm/dist/src/members/PaymentPatch.js +18 -1
- package/esm/dist/src/members/PaymentPatch.js.map +1 -1
- package/esm/dist/src/members/PaymentWithRegistrations.d.ts +6 -0
- package/esm/dist/src/members/PaymentWithRegistrations.d.ts.map +1 -0
- package/esm/dist/src/members/PaymentWithRegistrations.js +10 -0
- package/esm/dist/src/members/PaymentWithRegistrations.js.map +1 -0
- package/esm/dist/src/members/PlatformMember.d.ts +147 -0
- package/esm/dist/src/members/PlatformMember.d.ts.map +1 -0
- package/esm/dist/src/members/PlatformMember.js +608 -0
- package/esm/dist/src/members/PlatformMember.js.map +1 -0
- package/esm/dist/src/members/Registration.d.ts +7 -3
- package/esm/dist/src/members/Registration.d.ts.map +1 -1
- package/esm/dist/src/members/Registration.js +25 -6
- package/esm/dist/src/members/Registration.js.map +1 -1
- package/esm/dist/src/members/RegistrationWithEncryptedMember.d.ts +2 -2
- package/esm/dist/src/members/RegistrationWithEncryptedMember.d.ts.map +1 -1
- package/esm/dist/src/members/RegistrationWithEncryptedMember.js +2 -2
- package/esm/dist/src/members/RegistrationWithEncryptedMember.js.map +1 -1
- package/esm/dist/src/members/RegistrationWithMember.d.ts +0 -2
- package/esm/dist/src/members/RegistrationWithMember.d.ts.map +1 -1
- package/esm/dist/src/members/RegistrationWithMember.js +0 -4
- package/esm/dist/src/members/RegistrationWithMember.js.map +1 -1
- package/esm/dist/src/members/ReviewTime.d.ts +20 -0
- package/esm/dist/src/members/ReviewTime.d.ts.map +1 -0
- package/esm/dist/src/members/ReviewTime.js +70 -0
- package/esm/dist/src/members/ReviewTime.js.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCart.d.ts +49 -0
- package/esm/dist/src/members/checkout/OldRegisterCart.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCart.js +202 -0
- package/esm/dist/src/members/checkout/OldRegisterCart.js.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCartPriceCalculator.d.ts +36 -0
- package/esm/dist/src/members/checkout/OldRegisterCartPriceCalculator.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCartPriceCalculator.js +334 -0
- package/esm/dist/src/members/checkout/OldRegisterCartPriceCalculator.js.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCartValidator.d.ts +35 -0
- package/esm/dist/src/members/checkout/OldRegisterCartValidator.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCartValidator.js +341 -0
- package/esm/dist/src/members/checkout/OldRegisterCartValidator.js.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCheckout.d.ts +22 -0
- package/esm/dist/src/members/checkout/OldRegisterCheckout.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterCheckout.js +41 -0
- package/esm/dist/src/members/checkout/OldRegisterCheckout.js.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterItem.d.ts +59 -0
- package/esm/dist/src/members/checkout/OldRegisterItem.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/OldRegisterItem.js +142 -0
- package/esm/dist/src/members/checkout/OldRegisterItem.js.map +1 -0
- package/esm/dist/src/members/checkout/RegisterCartPriceCalculator.test.d.ts +2 -0
- package/esm/dist/src/members/checkout/RegisterCartPriceCalculator.test.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/RegisterCartPriceCalculator.test.js +1074 -0
- package/esm/dist/src/members/checkout/RegisterCartPriceCalculator.test.js.map +1 -0
- package/esm/dist/src/members/checkout/RegisterCheckout.d.ts +103 -0
- package/esm/dist/src/members/checkout/RegisterCheckout.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/RegisterCheckout.js +560 -0
- package/esm/dist/src/members/checkout/RegisterCheckout.js.map +1 -0
- package/esm/dist/src/members/checkout/UnknownMemberWithRegistrations.d.ts +23 -0
- package/esm/dist/src/members/checkout/UnknownMemberWithRegistrations.d.ts.map +1 -0
- package/esm/dist/src/members/checkout/UnknownMemberWithRegistrations.js +2 -0
- package/esm/dist/src/members/checkout/UnknownMemberWithRegistrations.js.map +1 -0
- package/esm/dist/src/members/records/LegacyRecord.d.ts +20 -0
- package/esm/dist/src/members/records/LegacyRecord.d.ts.map +1 -0
- package/esm/dist/src/members/{Record.js → records/LegacyRecord.js} +24 -9
- package/esm/dist/src/members/records/LegacyRecord.js.map +1 -0
- package/esm/dist/src/members/records/LegacyRecordType.d.ts +74 -0
- package/esm/dist/src/members/records/LegacyRecordType.d.ts.map +1 -0
- package/esm/dist/src/members/records/LegacyRecordType.js +93 -0
- package/esm/dist/src/members/records/LegacyRecordType.js.map +1 -0
- package/esm/dist/src/members/records/RecordAnswer.d.ts +125 -0
- package/esm/dist/src/members/records/RecordAnswer.d.ts.map +1 -0
- package/esm/dist/src/members/records/RecordAnswer.js +502 -0
- package/esm/dist/src/members/records/RecordAnswer.js.map +1 -0
- package/esm/dist/src/members/records/RecordCategory.d.ts +50 -0
- package/esm/dist/src/members/records/RecordCategory.d.ts.map +1 -0
- package/esm/dist/src/members/records/RecordCategory.js +186 -0
- package/esm/dist/src/members/records/RecordCategory.js.map +1 -0
- package/esm/dist/src/members/records/RecordConfigurationFactory.d.ts +17 -0
- package/esm/dist/src/members/records/RecordConfigurationFactory.d.ts.map +1 -0
- package/esm/dist/src/members/records/RecordConfigurationFactory.js +130 -0
- package/esm/dist/src/members/records/RecordConfigurationFactory.js.map +1 -0
- package/esm/dist/src/members/records/RecordFactory.d.ts +12 -0
- package/esm/dist/src/members/records/RecordFactory.d.ts.map +1 -0
- package/esm/dist/src/members/records/RecordFactory.js +524 -0
- package/esm/dist/src/members/records/RecordFactory.js.map +1 -0
- package/esm/dist/src/members/records/RecordSettings.d.ts +120 -0
- package/esm/dist/src/members/records/RecordSettings.d.ts.map +1 -0
- package/esm/dist/src/members/records/RecordSettings.js +245 -0
- package/esm/dist/src/members/records/RecordSettings.js.map +1 -0
- package/esm/dist/src/webshops/Cart.d.ts +25 -0
- package/esm/dist/src/webshops/Cart.d.ts.map +1 -0
- package/esm/dist/src/webshops/Cart.js +131 -0
- package/esm/dist/src/webshops/Cart.js.map +1 -0
- package/esm/dist/src/webshops/CartItem.d.ts +139 -0
- package/esm/dist/src/webshops/CartItem.d.ts.map +1 -0
- package/esm/dist/src/webshops/CartItem.js +708 -0
- package/esm/dist/src/webshops/CartItem.js.map +1 -0
- package/esm/dist/src/webshops/CartItem.test.d.ts +2 -0
- package/esm/dist/src/webshops/CartItem.test.d.ts.map +1 -0
- package/esm/dist/src/webshops/CartItem.test.js +57 -0
- package/esm/dist/src/webshops/CartItem.test.js.map +1 -0
- package/esm/dist/src/webshops/CartStockHelper.d.ts +53 -0
- package/esm/dist/src/webshops/CartStockHelper.d.ts.map +1 -0
- package/esm/dist/src/webshops/CartStockHelper.js +325 -0
- package/esm/dist/src/webshops/CartStockHelper.js.map +1 -0
- package/esm/dist/src/webshops/Category.d.ts +9 -0
- package/esm/dist/src/webshops/Category.d.ts.map +1 -0
- package/esm/dist/src/webshops/Category.js +28 -0
- package/esm/dist/src/webshops/Category.js.map +1 -0
- package/esm/dist/src/webshops/Checkout.d.ts +81 -0
- package/esm/dist/src/webshops/Checkout.d.ts.map +1 -0
- package/esm/dist/src/webshops/Checkout.js +525 -0
- package/esm/dist/src/webshops/Checkout.js.map +1 -0
- package/esm/dist/src/webshops/Customer.d.ts +9 -0
- package/esm/dist/src/webshops/Customer.d.ts.map +1 -0
- package/esm/dist/src/webshops/Customer.js +33 -0
- package/esm/dist/src/webshops/Customer.js.map +1 -0
- package/esm/dist/src/webshops/Discount.d.ts +131 -0
- package/esm/dist/src/webshops/Discount.d.ts.map +1 -0
- package/esm/dist/src/webshops/Discount.js +530 -0
- package/esm/dist/src/webshops/Discount.js.map +1 -0
- package/esm/dist/src/webshops/DiscountCode.d.ts +18 -0
- package/esm/dist/src/webshops/DiscountCode.d.ts.map +1 -0
- package/esm/dist/src/webshops/DiscountCode.js +48 -0
- package/esm/dist/src/webshops/DiscountCode.js.map +1 -0
- package/esm/dist/src/webshops/Order.d.ts +93 -0
- package/esm/dist/src/webshops/Order.d.ts.map +1 -0
- package/esm/dist/src/webshops/Order.js +506 -0
- package/esm/dist/src/webshops/Order.js.map +1 -0
- package/esm/dist/src/webshops/Product.d.ts +139 -0
- package/esm/dist/src/webshops/Product.d.ts.map +1 -0
- package/esm/dist/src/webshops/Product.js +471 -0
- package/esm/dist/src/webshops/Product.js.map +1 -0
- package/esm/dist/src/webshops/Ticket.d.ts +75 -0
- package/esm/dist/src/webshops/Ticket.d.ts.map +1 -0
- package/esm/dist/src/webshops/Ticket.js +240 -0
- package/esm/dist/src/webshops/Ticket.js.map +1 -0
- package/esm/dist/src/webshops/TransferSettings.d.ts +21 -0
- package/esm/dist/src/webshops/TransferSettings.d.ts.map +1 -0
- package/esm/dist/src/webshops/TransferSettings.js +116 -0
- package/esm/dist/src/webshops/TransferSettings.js.map +1 -0
- package/esm/dist/src/webshops/Webshop.d.ts +72 -0
- package/esm/dist/src/webshops/Webshop.d.ts.map +1 -0
- package/esm/dist/src/webshops/Webshop.js +286 -0
- package/esm/dist/src/webshops/Webshop.js.map +1 -0
- package/esm/dist/src/webshops/WebshopField.d.ts +14 -0
- package/esm/dist/src/webshops/WebshopField.d.ts.map +1 -0
- package/esm/dist/src/webshops/WebshopField.js +51 -0
- package/esm/dist/src/webshops/WebshopField.js.map +1 -0
- package/esm/dist/src/webshops/WebshopMetaData.d.ts +247 -0
- package/esm/dist/src/webshops/WebshopMetaData.d.ts.map +1 -0
- package/esm/dist/src/webshops/WebshopMetaData.js +669 -0
- package/esm/dist/src/webshops/WebshopMetaData.js.map +1 -0
- package/package.json +16 -26
- package/dist/src/Address.d.ts.map +0 -1
- package/dist/src/Address.js +0 -94
- package/dist/src/Address.js.map +0 -1
- package/dist/src/CountryDecoder.d.ts +0 -15
- package/dist/src/CountryDecoder.d.ts.map +0 -1
- package/dist/src/CountryDecoder.js +0 -53
- package/dist/src/CountryDecoder.js.map +0 -1
- package/dist/src/Invite.d.ts +0 -65
- package/dist/src/Invite.d.ts.map +0 -1
- package/dist/src/Invite.js +0 -129
- package/dist/src/Invite.js.map +0 -1
- package/dist/src/InviteUserDetails.d.ts +0 -7
- package/dist/src/InviteUserDetails.d.ts.map +0 -1
- package/dist/src/InviteUserDetails.js +0 -24
- package/dist/src/InviteUserDetails.js.map +0 -1
- package/dist/src/KeyConstants.d.ts +0 -20
- package/dist/src/KeyConstants.d.ts.map +0 -1
- package/dist/src/KeyConstants.js +0 -22
- package/dist/src/KeyConstants.js.map +0 -1
- package/dist/src/KeychainItem.d.ts +0 -12
- package/dist/src/KeychainItem.d.ts.map +0 -1
- package/dist/src/KeychainItem.js +0 -15
- package/dist/src/KeychainItem.js.map +0 -1
- package/dist/src/endpoints/ChangeOrganizationKeyRequest.d.ts +0 -14
- package/dist/src/endpoints/ChangeOrganizationKeyRequest.d.ts.map +0 -1
- package/dist/src/endpoints/ChangeOrganizationKeyRequest.js +0 -16
- package/dist/src/endpoints/ChangeOrganizationKeyRequest.js.map +0 -1
- package/dist/src/endpoints/GroupSizeResponse.d.ts +0 -6
- package/dist/src/endpoints/GroupSizeResponse.d.ts.map +0 -1
- package/dist/src/endpoints/GroupSizeResponse.js +0 -15
- package/dist/src/endpoints/GroupSizeResponse.js.map +0 -1
- package/dist/src/endpoints/PatchMembers.d.ts +0 -12
- package/dist/src/endpoints/PatchMembers.d.ts.map +0 -1
- package/dist/src/endpoints/PatchMembers.js +0 -20
- package/dist/src/endpoints/PatchMembers.js.map +0 -1
- package/dist/src/endpoints/tokens/ChallengeResponseStruct.d.ts +0 -7
- package/dist/src/endpoints/tokens/ChallengeResponseStruct.d.ts.map +0 -1
- package/dist/src/endpoints/tokens/ChallengeResponseStruct.js +0 -17
- package/dist/src/endpoints/tokens/ChallengeResponseStruct.js.map +0 -1
- package/dist/src/grouping/KeychainedResponse.d.ts +0 -26
- package/dist/src/grouping/KeychainedResponse.d.ts.map +0 -1
- package/dist/src/grouping/KeychainedResponse.js +0 -39
- package/dist/src/grouping/KeychainedResponse.js.map +0 -1
- package/dist/src/members/EncryptedMember.d.ts +0 -14
- package/dist/src/members/EncryptedMember.d.ts.map +0 -1
- package/dist/src/members/EncryptedMember.js +0 -45
- package/dist/src/members/EncryptedMember.js.map +0 -1
- package/dist/src/members/EncryptedMemberWithRegistrations.d.ts +0 -9
- package/dist/src/members/EncryptedMemberWithRegistrations.d.ts.map +0 -1
- package/dist/src/members/EncryptedMemberWithRegistrations.js +0 -19
- package/dist/src/members/EncryptedMemberWithRegistrations.js.map +0 -1
- package/dist/src/members/EncryptedPaymentDetailed.d.ts +0 -6
- package/dist/src/members/EncryptedPaymentDetailed.d.ts.map +0 -1
- package/dist/src/members/EncryptedPaymentDetailed.js +0 -14
- package/dist/src/members/EncryptedPaymentDetailed.js.map +0 -1
- package/dist/src/members/Record.d.ts +0 -8
- package/dist/src/members/Record.d.ts.map +0 -1
- package/dist/src/members/Record.js.map +0 -1
- package/dist/src/members/RecordType.d.ts +0 -48
- package/dist/src/members/RecordType.d.ts.map +0 -1
- package/dist/src/members/RecordType.js +0 -302
- package/dist/src/members/RecordType.js.map +0 -1
- package/esm/dist/src/Address.d.ts.map +0 -1
- package/esm/dist/src/Address.js +0 -90
- package/esm/dist/src/Address.js.map +0 -1
- package/esm/dist/src/CountryDecoder.d.ts +0 -15
- package/esm/dist/src/CountryDecoder.d.ts.map +0 -1
- package/esm/dist/src/CountryDecoder.js +0 -49
- package/esm/dist/src/CountryDecoder.js.map +0 -1
- package/esm/dist/src/Invite.d.ts +0 -65
- package/esm/dist/src/Invite.d.ts.map +0 -1
- package/esm/dist/src/Invite.js +0 -121
- package/esm/dist/src/Invite.js.map +0 -1
- package/esm/dist/src/InviteUserDetails.d.ts +0 -7
- package/esm/dist/src/InviteUserDetails.d.ts.map +0 -1
- package/esm/dist/src/InviteUserDetails.js +0 -20
- package/esm/dist/src/InviteUserDetails.js.map +0 -1
- package/esm/dist/src/KeyConstants.d.ts +0 -20
- package/esm/dist/src/KeyConstants.d.ts.map +0 -1
- package/esm/dist/src/KeyConstants.js +0 -18
- package/esm/dist/src/KeyConstants.js.map +0 -1
- package/esm/dist/src/KeychainItem.d.ts +0 -12
- package/esm/dist/src/KeychainItem.d.ts.map +0 -1
- package/esm/dist/src/KeychainItem.js +0 -11
- package/esm/dist/src/KeychainItem.js.map +0 -1
- package/esm/dist/src/endpoints/ChangeOrganizationKeyRequest.d.ts +0 -14
- package/esm/dist/src/endpoints/ChangeOrganizationKeyRequest.d.ts.map +0 -1
- package/esm/dist/src/endpoints/ChangeOrganizationKeyRequest.js +0 -12
- package/esm/dist/src/endpoints/ChangeOrganizationKeyRequest.js.map +0 -1
- package/esm/dist/src/endpoints/GroupSizeResponse.d.ts +0 -6
- package/esm/dist/src/endpoints/GroupSizeResponse.d.ts.map +0 -1
- package/esm/dist/src/endpoints/GroupSizeResponse.js +0 -11
- package/esm/dist/src/endpoints/GroupSizeResponse.js.map +0 -1
- package/esm/dist/src/endpoints/PatchMembers.d.ts +0 -12
- package/esm/dist/src/endpoints/PatchMembers.d.ts.map +0 -1
- package/esm/dist/src/endpoints/PatchMembers.js +0 -16
- package/esm/dist/src/endpoints/PatchMembers.js.map +0 -1
- package/esm/dist/src/endpoints/tokens/ChallengeResponseStruct.d.ts +0 -7
- package/esm/dist/src/endpoints/tokens/ChallengeResponseStruct.d.ts.map +0 -1
- package/esm/dist/src/endpoints/tokens/ChallengeResponseStruct.js +0 -13
- package/esm/dist/src/endpoints/tokens/ChallengeResponseStruct.js.map +0 -1
- package/esm/dist/src/grouping/KeychainedResponse.d.ts +0 -26
- package/esm/dist/src/grouping/KeychainedResponse.d.ts.map +0 -1
- package/esm/dist/src/grouping/KeychainedResponse.js +0 -34
- package/esm/dist/src/grouping/KeychainedResponse.js.map +0 -1
- package/esm/dist/src/members/EncryptedMember.d.ts +0 -14
- package/esm/dist/src/members/EncryptedMember.d.ts.map +0 -1
- package/esm/dist/src/members/EncryptedMember.js +0 -41
- package/esm/dist/src/members/EncryptedMember.js.map +0 -1
- package/esm/dist/src/members/EncryptedMemberWithRegistrations.d.ts +0 -9
- package/esm/dist/src/members/EncryptedMemberWithRegistrations.d.ts.map +0 -1
- package/esm/dist/src/members/EncryptedMemberWithRegistrations.js +0 -15
- package/esm/dist/src/members/EncryptedMemberWithRegistrations.js.map +0 -1
- package/esm/dist/src/members/EncryptedPaymentDetailed.d.ts +0 -6
- package/esm/dist/src/members/EncryptedPaymentDetailed.d.ts.map +0 -1
- package/esm/dist/src/members/EncryptedPaymentDetailed.js +0 -10
- package/esm/dist/src/members/EncryptedPaymentDetailed.js.map +0 -1
- package/esm/dist/src/members/Record.d.ts +0 -8
- package/esm/dist/src/members/Record.d.ts.map +0 -1
- package/esm/dist/src/members/Record.js.map +0 -1
- package/esm/dist/src/members/RecordType.d.ts +0 -48
- package/esm/dist/src/members/RecordType.d.ts.map +0 -1
- package/esm/dist/src/members/RecordType.js +0 -298
- package/esm/dist/src/members/RecordType.js.map +0 -1
|
@@ -0,0 +1,708 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { ArrayDecoder, AutoEncoder, field, IntegerDecoder, MapDecoder, StringDecoder } from '@simonbackx/simple-encoding';
|
|
3
|
+
import { isSimpleError, isSimpleErrors, SimpleError, SimpleErrors } from '@simonbackx/simple-errors';
|
|
4
|
+
import { Formatter } from '@stamhoofd/utility';
|
|
5
|
+
import { v4 as uuidv4 } from "uuid";
|
|
6
|
+
import { CartReservedSeat } from '../SeatingPlan';
|
|
7
|
+
import { CartStockHelper } from './CartStockHelper';
|
|
8
|
+
import { Option, OptionMenu, Product, ProductPrice, ProductType } from './Product';
|
|
9
|
+
import { WebshopFieldAnswer } from './WebshopField';
|
|
10
|
+
import { ProductDiscountSettings } from './Discount';
|
|
11
|
+
export class CartItemPrice extends AutoEncoder {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
this.price = 0;
|
|
15
|
+
this.fixedDiscount = 0;
|
|
16
|
+
this.percentageDiscount = 0;
|
|
17
|
+
}
|
|
18
|
+
get discountedPrice() {
|
|
19
|
+
let price = this.price;
|
|
20
|
+
price = Math.min(price, Math.max(0, Math.round(price * (10000 - this.percentageDiscount) / 10000))); // Min is required to support negative prices: prices should never increase after applyign discounts
|
|
21
|
+
price = Math.min(price, Math.max(0, price - this.fixedDiscount)); // Min is required to support negative prices: prices should never increase after applyign discounts
|
|
22
|
+
return price;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
__decorate([
|
|
26
|
+
field({ decoder: IntegerDecoder })
|
|
27
|
+
], CartItemPrice.prototype, "price", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
field({ decoder: IntegerDecoder })
|
|
30
|
+
], CartItemPrice.prototype, "fixedDiscount", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
field({ decoder: IntegerDecoder })
|
|
33
|
+
], CartItemPrice.prototype, "percentageDiscount", void 0);
|
|
34
|
+
export class CartItemOption extends AutoEncoder {
|
|
35
|
+
}
|
|
36
|
+
__decorate([
|
|
37
|
+
field({ decoder: Option })
|
|
38
|
+
], CartItemOption.prototype, "option", void 0);
|
|
39
|
+
__decorate([
|
|
40
|
+
field({ decoder: OptionMenu })
|
|
41
|
+
], CartItemOption.prototype, "optionMenu", void 0);
|
|
42
|
+
export class CartItem extends AutoEncoder {
|
|
43
|
+
constructor() {
|
|
44
|
+
super(...arguments);
|
|
45
|
+
this.options = [];
|
|
46
|
+
this.fieldAnswers = [];
|
|
47
|
+
this.seats = [];
|
|
48
|
+
this.amount = 1;
|
|
49
|
+
/**
|
|
50
|
+
* Discounts that are actually applied
|
|
51
|
+
*/
|
|
52
|
+
this.discounts = [];
|
|
53
|
+
/**
|
|
54
|
+
* When an order is correctly placed, we store the reserved amount in the stock here.
|
|
55
|
+
* We need this to check the stock changes when an order is edited after placement.
|
|
56
|
+
*/
|
|
57
|
+
this.reservedAmount = 0;
|
|
58
|
+
/**
|
|
59
|
+
* Holds a list of what we reserved a stock for (which produce prices and which options specifically so we don't reserve the same thing multiple times or revert when it wasn't reserved earlier)
|
|
60
|
+
*/
|
|
61
|
+
this.reservedOptions = new Map();
|
|
62
|
+
/**
|
|
63
|
+
* Holds a list of what we reserved a stock for (which produce prices and which options specifically so we don't reserve the same thing multiple times or revert when it wasn't reserved earlier)
|
|
64
|
+
*/
|
|
65
|
+
this.reservedPrices = new Map();
|
|
66
|
+
/**
|
|
67
|
+
* When the seats are successfully reserved, we store them here
|
|
68
|
+
* This makes editing seats possible because we know we can still use these seats even if they are blocked normally
|
|
69
|
+
*/
|
|
70
|
+
this.reservedSeats = [];
|
|
71
|
+
/**
|
|
72
|
+
* @deprecated
|
|
73
|
+
* Saved unitPrice (migration needed)
|
|
74
|
+
*/
|
|
75
|
+
this.unitPrice = null;
|
|
76
|
+
/**
|
|
77
|
+
* Detailed list of prices
|
|
78
|
+
*/
|
|
79
|
+
this.calculatedPrices = [];
|
|
80
|
+
/**
|
|
81
|
+
* Show an error in the cart for recovery
|
|
82
|
+
*/
|
|
83
|
+
this.cartError = null;
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* @deprecated
|
|
87
|
+
*/
|
|
88
|
+
get price() {
|
|
89
|
+
return this.unitPrice ? (this.unitPrice * this.amount) : null;
|
|
90
|
+
}
|
|
91
|
+
getReservedAmountPrice(priceId) {
|
|
92
|
+
return this.reservedPrices.get(priceId) || 0;
|
|
93
|
+
}
|
|
94
|
+
getReservedAmountOption(optionId) {
|
|
95
|
+
return this.reservedOptions.get(optionId) || 0;
|
|
96
|
+
}
|
|
97
|
+
static createDefault(product, cart, webshop, data) {
|
|
98
|
+
// Return the first that still has stock or the first if none has stock
|
|
99
|
+
const options = [];
|
|
100
|
+
// Fill in all default options here
|
|
101
|
+
for (const optionMenu of product.optionMenus) {
|
|
102
|
+
if (optionMenu.multipleChoice) {
|
|
103
|
+
continue;
|
|
104
|
+
}
|
|
105
|
+
let cartItemOption = null;
|
|
106
|
+
// Add first option with remaining stock
|
|
107
|
+
for (const option of optionMenu.options) {
|
|
108
|
+
const stock = CartStockHelper.getOptionStock({ product, option, oldItem: null, cart, webshop, admin: data.admin });
|
|
109
|
+
if (!stock || stock.remaining === null || stock.remaining > 0) {
|
|
110
|
+
cartItemOption = CartItemOption.create({
|
|
111
|
+
option,
|
|
112
|
+
optionMenu
|
|
113
|
+
});
|
|
114
|
+
break;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
// Add (default if no stock for all)
|
|
118
|
+
options.push(cartItemOption !== null && cartItemOption !== void 0 ? cartItemOption : CartItemOption.create({
|
|
119
|
+
option: optionMenu.options[0],
|
|
120
|
+
optionMenu
|
|
121
|
+
}));
|
|
122
|
+
}
|
|
123
|
+
const prices = product.filteredPrices(data);
|
|
124
|
+
let chosenPrice = null;
|
|
125
|
+
for (const productPrice of prices) {
|
|
126
|
+
const stock = CartStockHelper.getPriceStock({ product, productPrice, oldItem: null, cart, webshop, admin: data.admin });
|
|
127
|
+
if (!stock || stock.remaining === null || stock.remaining > 0) {
|
|
128
|
+
chosenPrice = productPrice;
|
|
129
|
+
break;
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
// Default
|
|
133
|
+
return CartItem.create({
|
|
134
|
+
product: product,
|
|
135
|
+
productPrice: chosenPrice !== null && chosenPrice !== void 0 ? chosenPrice : product.filteredPrices(data)[0],
|
|
136
|
+
options
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
static create(object) {
|
|
140
|
+
const c = super.create(object);
|
|
141
|
+
// Fill in all default options here
|
|
142
|
+
for (const optionMenu of c.product.optionMenus) {
|
|
143
|
+
if (optionMenu.multipleChoice) {
|
|
144
|
+
continue;
|
|
145
|
+
}
|
|
146
|
+
if (c.options.find(o => o.optionMenu.id === optionMenu.id)) {
|
|
147
|
+
continue;
|
|
148
|
+
}
|
|
149
|
+
c.options.push(CartItemOption.create({
|
|
150
|
+
option: optionMenu.options[0],
|
|
151
|
+
optionMenu: optionMenu
|
|
152
|
+
}));
|
|
153
|
+
}
|
|
154
|
+
return c;
|
|
155
|
+
}
|
|
156
|
+
/**
|
|
157
|
+
* Unique identifier to check if two cart items are the same
|
|
158
|
+
*/
|
|
159
|
+
get code() {
|
|
160
|
+
return this.codeWithoutFields + "." + this.fieldAnswers.map(a => a.field.id + "-" + Formatter.slug(a.answer)).join(".");
|
|
161
|
+
}
|
|
162
|
+
get codeWithoutFields() {
|
|
163
|
+
return this.product.id + "." + this.productPrice.id + "." + this.options.map(o => o.option.id).join(".");
|
|
164
|
+
}
|
|
165
|
+
/**
|
|
166
|
+
* Return total amount of same product in the given cart. Always includes the current item, even when it isn't in the cart. Doesn't count it twice
|
|
167
|
+
*/
|
|
168
|
+
getTotalAmount(cart) {
|
|
169
|
+
return cart.items.reduce((c, item) => {
|
|
170
|
+
if (item.product.id !== this.product.id) {
|
|
171
|
+
return c;
|
|
172
|
+
}
|
|
173
|
+
if (item.id === this.id) {
|
|
174
|
+
return c;
|
|
175
|
+
}
|
|
176
|
+
return c + item.amount;
|
|
177
|
+
}, 0) + this.amount;
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* Note: this resets any discounts that are applied to the cart item
|
|
181
|
+
*/
|
|
182
|
+
calculatePrices(cart) {
|
|
183
|
+
const prices = [];
|
|
184
|
+
const unitPrice = this.calculateUnitPrice(cart);
|
|
185
|
+
for (const seat of this.seats) {
|
|
186
|
+
const seatPrice = unitPrice + seat.price;
|
|
187
|
+
prices.push(CartItemPrice.create({
|
|
188
|
+
price: seatPrice
|
|
189
|
+
}));
|
|
190
|
+
}
|
|
191
|
+
// Others (non seats)
|
|
192
|
+
const remaining = this.amount - this.seats.length;
|
|
193
|
+
if (remaining > 0) {
|
|
194
|
+
for (let index = 0; index < remaining; index++) {
|
|
195
|
+
prices.push(CartItemPrice.create({
|
|
196
|
+
price: unitPrice
|
|
197
|
+
}));
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
this.calculatedPrices = prices;
|
|
201
|
+
}
|
|
202
|
+
calculateUnitPrice(cart) {
|
|
203
|
+
const amount = this.getTotalAmount(cart);
|
|
204
|
+
let price = this.productPrice.price;
|
|
205
|
+
if (this.productPrice.discountPrice !== null && amount >= this.productPrice.discountAmount) {
|
|
206
|
+
price = this.productPrice.discountPrice;
|
|
207
|
+
}
|
|
208
|
+
for (const option of this.options) {
|
|
209
|
+
price += option.option.price;
|
|
210
|
+
}
|
|
211
|
+
if (this.productPrice.price >= 0) {
|
|
212
|
+
this.unitPrice = Math.max(0, price);
|
|
213
|
+
}
|
|
214
|
+
else {
|
|
215
|
+
// Allow negative
|
|
216
|
+
this.unitPrice = price;
|
|
217
|
+
}
|
|
218
|
+
return this.unitPrice;
|
|
219
|
+
}
|
|
220
|
+
/**
|
|
221
|
+
* @deprecated
|
|
222
|
+
* Use this method if you need temporary prices in case it is not yet calculated
|
|
223
|
+
*/
|
|
224
|
+
getUnitPrice(cart) {
|
|
225
|
+
if (this.unitPrice) {
|
|
226
|
+
return this.unitPrice;
|
|
227
|
+
}
|
|
228
|
+
return this.calculateUnitPrice(cart);
|
|
229
|
+
}
|
|
230
|
+
getPriceWithDiscounts() {
|
|
231
|
+
return this.calculatedPrices.reduce((a, b) => a + b.discountedPrice, 0);
|
|
232
|
+
}
|
|
233
|
+
getPriceWithoutDiscounts() {
|
|
234
|
+
return this.calculatedPrices.reduce((a, b) => a + b.price, 0);
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* @deprecated: use other systems
|
|
238
|
+
* Prices that are only applicable to some amount, but not all (e.g. seat extra prices)
|
|
239
|
+
*/
|
|
240
|
+
getPartialExtraPrice(cart) {
|
|
241
|
+
const unitPrice = this.getUnitPrice(cart);
|
|
242
|
+
const expectedPrice = unitPrice * this.amount;
|
|
243
|
+
const actualPrice = this.getPriceWithoutDiscounts();
|
|
244
|
+
return actualPrice - expectedPrice;
|
|
245
|
+
}
|
|
246
|
+
/**
|
|
247
|
+
* @deprecated use getPriceWithDiscounts instead for clarity
|
|
248
|
+
*/
|
|
249
|
+
getPrice() {
|
|
250
|
+
return this.getPriceWithDiscounts();
|
|
251
|
+
}
|
|
252
|
+
getUnitPriceCombinationsWithoutDiscount() {
|
|
253
|
+
const priceCombinations = new Map();
|
|
254
|
+
for (const calculatedPrice of this.calculatedPrices) {
|
|
255
|
+
const price = calculatedPrice.price;
|
|
256
|
+
priceCombinations.set(price, (priceCombinations.get(price) || 0) + 1);
|
|
257
|
+
}
|
|
258
|
+
return priceCombinations;
|
|
259
|
+
}
|
|
260
|
+
getUnitPriceCombinationsWithDiscount() {
|
|
261
|
+
const priceCombinations = new Map();
|
|
262
|
+
for (const calculatedPrice of this.calculatedPrices) {
|
|
263
|
+
const price = calculatedPrice.discountedPrice;
|
|
264
|
+
priceCombinations.set(price, (priceCombinations.get(price) || 0) + 1);
|
|
265
|
+
}
|
|
266
|
+
return priceCombinations;
|
|
267
|
+
}
|
|
268
|
+
get formattedAmount() {
|
|
269
|
+
if (!this.product.allowMultiple) {
|
|
270
|
+
return "";
|
|
271
|
+
}
|
|
272
|
+
return Formatter.integer(this.amount);
|
|
273
|
+
}
|
|
274
|
+
/**
|
|
275
|
+
* Without discounts
|
|
276
|
+
*/
|
|
277
|
+
getFormattedPriceWithoutDiscount() {
|
|
278
|
+
// Group by seats
|
|
279
|
+
const priceCombinations = this.getUnitPriceCombinationsWithoutDiscount();
|
|
280
|
+
return this.priceCombinationToString(priceCombinations);
|
|
281
|
+
}
|
|
282
|
+
getFormattedPriceWithDiscount() {
|
|
283
|
+
const price = this.getPriceWithDiscounts();
|
|
284
|
+
if (price === this.getPriceWithoutDiscounts()) {
|
|
285
|
+
return null;
|
|
286
|
+
}
|
|
287
|
+
const priceCombinations = this.getUnitPriceCombinationsWithDiscount();
|
|
288
|
+
return this.priceCombinationToString(priceCombinations);
|
|
289
|
+
}
|
|
290
|
+
priceCombinationToString(priceCombinations) {
|
|
291
|
+
// Sort by price
|
|
292
|
+
const sorted = [...priceCombinations.entries()].map(([price, amount]) => ({ price, amount })).sort((a, b) => b.price - a.price);
|
|
293
|
+
// Format
|
|
294
|
+
const parts = [];
|
|
295
|
+
for (const { price, amount } of sorted) {
|
|
296
|
+
if (parts.length > 0 || price < 0) {
|
|
297
|
+
if (price >= 0) {
|
|
298
|
+
parts.push("+");
|
|
299
|
+
}
|
|
300
|
+
else {
|
|
301
|
+
parts.push("-");
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
if (!this.product.allowMultiple && amount === 1) {
|
|
305
|
+
parts.push(Formatter.price(Math.abs(price)));
|
|
306
|
+
continue;
|
|
307
|
+
}
|
|
308
|
+
if (price === 0) {
|
|
309
|
+
if (sorted.length === 1) {
|
|
310
|
+
parts.push('Gratis');
|
|
311
|
+
}
|
|
312
|
+
else {
|
|
313
|
+
parts.push(amount + " gratis");
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
else {
|
|
317
|
+
if (sorted.length === 1 || amount === 1) {
|
|
318
|
+
if (amount > 1) {
|
|
319
|
+
parts.push(Formatter.price(Math.abs(price)) + ' / stuk');
|
|
320
|
+
}
|
|
321
|
+
else {
|
|
322
|
+
parts.push(Formatter.price(Math.abs(price)));
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
else {
|
|
326
|
+
parts.push(amount + " × " + Formatter.price(Math.abs(price)));
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
return parts.join(" ");
|
|
331
|
+
}
|
|
332
|
+
/**
|
|
333
|
+
* Used for statistics
|
|
334
|
+
*/
|
|
335
|
+
get descriptionWithoutFields() {
|
|
336
|
+
const descriptions = [];
|
|
337
|
+
if (this.product.prices.length > 1) {
|
|
338
|
+
descriptions.push(this.productPrice.name);
|
|
339
|
+
}
|
|
340
|
+
for (const option of this.options) {
|
|
341
|
+
descriptions.push(option.option.name);
|
|
342
|
+
}
|
|
343
|
+
if ((this.product.type === ProductType.Ticket || this.product.type === ProductType.Voucher) && this.product.dateRange) {
|
|
344
|
+
descriptions.unshift(Formatter.capitalizeFirstLetter(this.product.dateRange.toString()));
|
|
345
|
+
}
|
|
346
|
+
return descriptions.filter(d => !!d).join("\n");
|
|
347
|
+
}
|
|
348
|
+
get descriptionWithoutDate() {
|
|
349
|
+
const descriptions = [];
|
|
350
|
+
if (this.product.prices.length > 1) {
|
|
351
|
+
descriptions.push(this.productPrice.name);
|
|
352
|
+
}
|
|
353
|
+
for (const option of this.options) {
|
|
354
|
+
descriptions.push(option.option.name);
|
|
355
|
+
}
|
|
356
|
+
for (const a of this.fieldAnswers) {
|
|
357
|
+
if (!a.answer) {
|
|
358
|
+
continue;
|
|
359
|
+
}
|
|
360
|
+
descriptions.push(a.field.name + ": " + a.answer);
|
|
361
|
+
}
|
|
362
|
+
return descriptions.filter(d => !!d).join("\n");
|
|
363
|
+
}
|
|
364
|
+
get description() {
|
|
365
|
+
const descriptions = [this.descriptionWithoutDate];
|
|
366
|
+
if ((this.product.type === ProductType.Ticket || this.product.type === ProductType.Voucher) && this.product.dateRange) {
|
|
367
|
+
descriptions.unshift(Formatter.capitalizeFirstLetter(this.product.dateRange.toString()));
|
|
368
|
+
}
|
|
369
|
+
return descriptions.filter(d => !!d).join("\n");
|
|
370
|
+
}
|
|
371
|
+
validateAnswers() {
|
|
372
|
+
const newAnswers = [];
|
|
373
|
+
for (const field of this.product.customFields) {
|
|
374
|
+
const answer = this.fieldAnswers.find(a => a.field.id === field.id);
|
|
375
|
+
try {
|
|
376
|
+
if (!answer) {
|
|
377
|
+
const a = WebshopFieldAnswer.create({ field, answer: "" });
|
|
378
|
+
a.validate();
|
|
379
|
+
newAnswers.push(a);
|
|
380
|
+
}
|
|
381
|
+
else {
|
|
382
|
+
answer.field = field;
|
|
383
|
+
answer.validate();
|
|
384
|
+
newAnswers.push(answer);
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
catch (e) {
|
|
388
|
+
if (isSimpleError(e) || isSimpleErrors(e)) {
|
|
389
|
+
e.addNamespace("fieldAnswers." + field.id);
|
|
390
|
+
}
|
|
391
|
+
throw e;
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
this.fieldAnswers = newAnswers;
|
|
395
|
+
}
|
|
396
|
+
/**
|
|
397
|
+
* Update self to the newest available data, and throw error if something failed (only after refreshing other ones)
|
|
398
|
+
*/
|
|
399
|
+
refresh(webshop) {
|
|
400
|
+
const errors = new SimpleErrors();
|
|
401
|
+
const product = webshop.products.find(p => p.id == this.product.id);
|
|
402
|
+
if (!product) {
|
|
403
|
+
errors.addError(new SimpleError({
|
|
404
|
+
code: "product_unavailable",
|
|
405
|
+
message: "Product unavailable",
|
|
406
|
+
human: this.product.name + " is niet meer beschikbaar"
|
|
407
|
+
}));
|
|
408
|
+
}
|
|
409
|
+
else {
|
|
410
|
+
this.product = product;
|
|
411
|
+
const productPrice = product.prices.find(p => p.id === this.productPrice.id);
|
|
412
|
+
if (!productPrice) {
|
|
413
|
+
if (this.productPrice.name.length == 0 || this.product.prices.length <= 1 && product.prices.length > 1) {
|
|
414
|
+
errors.addError(new SimpleError({
|
|
415
|
+
code: "product_price_unavailable",
|
|
416
|
+
message: "Product price unavailable",
|
|
417
|
+
human: "Er werden keuzemogelijkheden toegevoegd aan " + this.product.name + ", waar je nu eerst moet uit kiezen."
|
|
418
|
+
}));
|
|
419
|
+
}
|
|
420
|
+
else {
|
|
421
|
+
errors.addError(new SimpleError({
|
|
422
|
+
code: "product_price_unavailable",
|
|
423
|
+
message: "Product price unavailable",
|
|
424
|
+
human: "De keuzemogelijkheid '" + this.productPrice.name + "' van " + this.product.name + " is niet meer beschikbaar. Kies een andere."
|
|
425
|
+
}));
|
|
426
|
+
}
|
|
427
|
+
}
|
|
428
|
+
else {
|
|
429
|
+
// Only set product if we did find our product price
|
|
430
|
+
this.productPrice = productPrice;
|
|
431
|
+
}
|
|
432
|
+
// Check all options
|
|
433
|
+
const remainingMenus = this.product.optionMenus.slice();
|
|
434
|
+
for (const o of this.options) {
|
|
435
|
+
let index = remainingMenus.findIndex(m => m.id === o.optionMenu.id);
|
|
436
|
+
if (index == -1) {
|
|
437
|
+
// Check if it has a multiple choice one
|
|
438
|
+
index = this.product.optionMenus.findIndex(m => m.id === o.optionMenu.id);
|
|
439
|
+
errors.addError(new SimpleError({
|
|
440
|
+
code: "option_menu_unavailable",
|
|
441
|
+
message: "Option menu unavailable",
|
|
442
|
+
human: "Eén of meerdere keuzemogelijkheden van " + this.product.name + " zijn niet meer beschikbaar"
|
|
443
|
+
}));
|
|
444
|
+
continue;
|
|
445
|
+
}
|
|
446
|
+
const menu = remainingMenus[index];
|
|
447
|
+
if (!menu.multipleChoice) {
|
|
448
|
+
// Already used: not possible to add another
|
|
449
|
+
remainingMenus.splice(index, 1)[0];
|
|
450
|
+
}
|
|
451
|
+
const option = menu.options.find(m => m.id === o.option.id);
|
|
452
|
+
if (!option) {
|
|
453
|
+
errors.addError(new SimpleError({
|
|
454
|
+
code: "option_unavailable",
|
|
455
|
+
message: "Option unavailable",
|
|
456
|
+
human: "Eén of meerdere keuzemogelijkheden van " + this.product.name + " zijn niet meer beschikbaar"
|
|
457
|
+
}));
|
|
458
|
+
continue;
|
|
459
|
+
}
|
|
460
|
+
// Update to latest data
|
|
461
|
+
o.optionMenu = menu;
|
|
462
|
+
o.option = option;
|
|
463
|
+
}
|
|
464
|
+
if (remainingMenus.filter(m => !m.multipleChoice).length > 0) {
|
|
465
|
+
errors.addError(new SimpleError({
|
|
466
|
+
code: "missing_menu",
|
|
467
|
+
message: "Missing menu's " + remainingMenus.filter(m => !m.multipleChoice).map(m => m.name).join(", "),
|
|
468
|
+
human: "Er zijn nieuwe keuzemogelijkheden voor " + this.product.name + " waaruit je moet kiezen"
|
|
469
|
+
}));
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
try {
|
|
473
|
+
this.validateAnswers();
|
|
474
|
+
}
|
|
475
|
+
catch (e) {
|
|
476
|
+
errors.addError(e);
|
|
477
|
+
}
|
|
478
|
+
errors.throwIfNotEmpty();
|
|
479
|
+
}
|
|
480
|
+
getFixedStockDefinitions(oldItem, cart, webshop, admin) {
|
|
481
|
+
return CartStockHelper.getFixedStockDefinitions({ oldItem, cart, product: this.product, webshop, admin, amount: this.amount });
|
|
482
|
+
}
|
|
483
|
+
/**
|
|
484
|
+
* Return all the stock definitions for this cart item with the currently selected options
|
|
485
|
+
* = calculate how much you can order with these options
|
|
486
|
+
*/
|
|
487
|
+
getAvailableStock(oldItem, cart, webshop, admin) {
|
|
488
|
+
return CartStockHelper.getAvailableStock({ oldItem, cart, product: this.product, webshop, admin, amount: this.amount, productPrice: this.productPrice, options: this.options });
|
|
489
|
+
}
|
|
490
|
+
getMaximumRemaining(oldItem, cart, webshop, admin) {
|
|
491
|
+
return CartStockHelper.getRemaining(this.getAvailableStock(oldItem, cart, webshop, admin));
|
|
492
|
+
}
|
|
493
|
+
/**
|
|
494
|
+
* Update self to the newest available data and throw if it was not able to recover
|
|
495
|
+
*/
|
|
496
|
+
validate(webshop, cart, { refresh, admin, validateSeats } = { refresh: true, admin: false, validateSeats: true }) {
|
|
497
|
+
this.cartError = null;
|
|
498
|
+
if (admin === undefined) {
|
|
499
|
+
admin = false;
|
|
500
|
+
}
|
|
501
|
+
if (refresh === undefined) {
|
|
502
|
+
refresh = true;
|
|
503
|
+
}
|
|
504
|
+
if (validateSeats === undefined) {
|
|
505
|
+
validateSeats = true;
|
|
506
|
+
}
|
|
507
|
+
if (refresh) {
|
|
508
|
+
this.refresh(webshop);
|
|
509
|
+
}
|
|
510
|
+
const product = this.product;
|
|
511
|
+
if (!product.allowMultiple) {
|
|
512
|
+
this.amount = 1;
|
|
513
|
+
}
|
|
514
|
+
// Check stock
|
|
515
|
+
if (!admin) {
|
|
516
|
+
if (!product.isEnabled && this.amount > this.reservedAmount) {
|
|
517
|
+
throw new SimpleError({
|
|
518
|
+
code: "product_unavailable",
|
|
519
|
+
message: "Product unavailable",
|
|
520
|
+
human: this.product.name + " is niet meer beschikbaar"
|
|
521
|
+
});
|
|
522
|
+
}
|
|
523
|
+
if (this.productPrice.hidden) {
|
|
524
|
+
throw new SimpleError({
|
|
525
|
+
code: "product_price_unavailable",
|
|
526
|
+
message: "Product price unavailable",
|
|
527
|
+
human: this.productPrice.name + " is niet meer beschikbaar"
|
|
528
|
+
});
|
|
529
|
+
}
|
|
530
|
+
if (product.isSoldOut && this.amount > this.reservedAmount) {
|
|
531
|
+
throw new SimpleError({
|
|
532
|
+
code: "product_unavailable",
|
|
533
|
+
message: "Product unavailable",
|
|
534
|
+
human: this.product.name + " is uitverkocht"
|
|
535
|
+
});
|
|
536
|
+
}
|
|
537
|
+
const remaining = this.getAvailableStock(this, cart, webshop, admin);
|
|
538
|
+
const minimumRemaining = CartStockHelper.getRemaining(remaining);
|
|
539
|
+
if (minimumRemaining !== null && minimumRemaining < this.amount) {
|
|
540
|
+
// Search for appropriate message in stock definitions
|
|
541
|
+
const stockDefinition = remaining.find(r => r.remaining === minimumRemaining);
|
|
542
|
+
throw new SimpleError({
|
|
543
|
+
code: "product_unavailable",
|
|
544
|
+
message: "Product unavailable",
|
|
545
|
+
human: (stockDefinition === null || stockDefinition === void 0 ? void 0 : stockDefinition.text) || "Er zijn nog maar " + minimumRemaining + " stuks beschikbaar van " + this.product.name,
|
|
546
|
+
meta: { recoverable: minimumRemaining > 0 }
|
|
547
|
+
});
|
|
548
|
+
}
|
|
549
|
+
}
|
|
550
|
+
if (this.product.seatingPlanId && validateSeats) {
|
|
551
|
+
const seatingPlan = webshop.meta.seatingPlans.find(s => s.id === this.product.seatingPlanId);
|
|
552
|
+
if (!seatingPlan) {
|
|
553
|
+
throw new SimpleError({
|
|
554
|
+
code: "seating_plan_unavailable",
|
|
555
|
+
message: "Invalid seating plan",
|
|
556
|
+
human: "Het zaalplan van " + this.product.name + " is niet meer beschikbaar. Herlaad de pagina en probeer opnieuw. Neem contact met ons op als het probleem zich herhaalt."
|
|
557
|
+
});
|
|
558
|
+
}
|
|
559
|
+
// Check seats taken already?
|
|
560
|
+
const reservedSeats = this.product.reservedSeats;
|
|
561
|
+
// Remove invalid seats
|
|
562
|
+
const invalidSeats = this.seats.filter(s => {
|
|
563
|
+
const valid = seatingPlan.isValidSeat(s, reservedSeats, this.reservedSeats);
|
|
564
|
+
if (valid) {
|
|
565
|
+
return false;
|
|
566
|
+
}
|
|
567
|
+
else {
|
|
568
|
+
if (!admin && seatingPlan.isAdminSeat(s)) {
|
|
569
|
+
return false;
|
|
570
|
+
}
|
|
571
|
+
return true;
|
|
572
|
+
}
|
|
573
|
+
});
|
|
574
|
+
if (invalidSeats.length) {
|
|
575
|
+
throw new SimpleError({
|
|
576
|
+
code: "seats_unavailable",
|
|
577
|
+
message: "Seats unavailable",
|
|
578
|
+
human: "De volgende plaatsen zijn niet meer beschikbaar: " + invalidSeats.map(s => s.getNameString(webshop, this.product)).join(", "),
|
|
579
|
+
meta: { recoverable: true }
|
|
580
|
+
});
|
|
581
|
+
}
|
|
582
|
+
// Seating validation
|
|
583
|
+
if (this.seats.length !== this.amount) {
|
|
584
|
+
if (this.seats.length > this.amount) {
|
|
585
|
+
// We need to handle this, because this can be caused by a stock limit
|
|
586
|
+
throw new SimpleError({
|
|
587
|
+
code: "invalid_seats",
|
|
588
|
+
message: "Invalid seats",
|
|
589
|
+
human: `Kies ${Formatter.pluralText(this.amount, 'plaats', 'plaatsen')}`,
|
|
590
|
+
meta: { recoverable: true }
|
|
591
|
+
});
|
|
592
|
+
}
|
|
593
|
+
throw new SimpleError({
|
|
594
|
+
code: "invalid_seats",
|
|
595
|
+
message: "Invalid seats",
|
|
596
|
+
human: `Kies nog ${Formatter.pluralText(this.amount - this.seats.length, 'plaats', 'plaatsen')}`,
|
|
597
|
+
meta: { recoverable: true }
|
|
598
|
+
});
|
|
599
|
+
}
|
|
600
|
+
// Check other cart items have same seats
|
|
601
|
+
const otherItems = cart.items.filter(i => i.product.id === this.product.id && i.id != this.id);
|
|
602
|
+
for (const item of otherItems) {
|
|
603
|
+
for (const seat of item.seats) {
|
|
604
|
+
if (this.seats.find(s => s.equals(seat))) {
|
|
605
|
+
throw new SimpleError({
|
|
606
|
+
code: "seats_unavailable",
|
|
607
|
+
message: "Seats unavailable",
|
|
608
|
+
human: "De volgende plaatsen heb je twee keer gekozen: " + seat.getNameString(webshop, this.product)
|
|
609
|
+
});
|
|
610
|
+
}
|
|
611
|
+
}
|
|
612
|
+
}
|
|
613
|
+
// Adjust seats automatically if enabled
|
|
614
|
+
if (seatingPlan.requireOptimalReservation && !admin) {
|
|
615
|
+
const otherSeats = cart.items.filter(i => i.product.id === this.product.id && i.id !== this.id).flatMap(i => i.seats);
|
|
616
|
+
const adjusted = seatingPlan.adjustSeatsForBetterFit(this.seats, [...reservedSeats, ...otherSeats], this.reservedSeats);
|
|
617
|
+
if (adjusted) {
|
|
618
|
+
this.seats = adjusted.map(a => CartReservedSeat.create(a));
|
|
619
|
+
}
|
|
620
|
+
// Edge case: if seats are not optimal across multiple items, we can't fix it
|
|
621
|
+
const adjusted2 = seatingPlan.adjustSeatsForBetterFit([...this.seats, ...otherSeats], reservedSeats, this.reservedSeats);
|
|
622
|
+
if (adjusted2) {
|
|
623
|
+
// Not able to correct this across multiple items
|
|
624
|
+
throw new SimpleError({
|
|
625
|
+
code: "select_connected_seats",
|
|
626
|
+
message: "Select connected seats",
|
|
627
|
+
human: "Pas de plaatsen aan zodat ze aansluiten en geen enkele plaatsen openlaten.",
|
|
628
|
+
meta: { recoverable: true }
|
|
629
|
+
});
|
|
630
|
+
}
|
|
631
|
+
}
|
|
632
|
+
// Update prices
|
|
633
|
+
for (const seat of this.seats) {
|
|
634
|
+
seat.calculatePrice(seatingPlan);
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
// Update prices
|
|
638
|
+
// should now happen in the checkout so discounts are in sync
|
|
639
|
+
// this.calculateUnitPrice(cart)
|
|
640
|
+
}
|
|
641
|
+
}
|
|
642
|
+
__decorate([
|
|
643
|
+
field({ decoder: StringDecoder, defaultValue: () => uuidv4(), version: 106, upgrade: function () {
|
|
644
|
+
// Warning: this id will always be too long for storage in a normal database record.
|
|
645
|
+
// But that is not a problem, since only new orders will use tickets that need this field
|
|
646
|
+
return this.code;
|
|
647
|
+
} })
|
|
648
|
+
], CartItem.prototype, "id", void 0);
|
|
649
|
+
__decorate([
|
|
650
|
+
field({ decoder: Product })
|
|
651
|
+
], CartItem.prototype, "product", void 0);
|
|
652
|
+
__decorate([
|
|
653
|
+
field({ decoder: ProductPrice })
|
|
654
|
+
], CartItem.prototype, "productPrice", void 0);
|
|
655
|
+
__decorate([
|
|
656
|
+
field({ decoder: new ArrayDecoder(CartItemOption) })
|
|
657
|
+
], CartItem.prototype, "options", void 0);
|
|
658
|
+
__decorate([
|
|
659
|
+
field({ decoder: new ArrayDecoder(WebshopFieldAnswer), version: 94 })
|
|
660
|
+
], CartItem.prototype, "fieldAnswers", void 0);
|
|
661
|
+
__decorate([
|
|
662
|
+
field({ decoder: new ArrayDecoder(CartReservedSeat), version: 212 })
|
|
663
|
+
], CartItem.prototype, "seats", void 0);
|
|
664
|
+
__decorate([
|
|
665
|
+
field({ decoder: IntegerDecoder })
|
|
666
|
+
], CartItem.prototype, "amount", void 0);
|
|
667
|
+
__decorate([
|
|
668
|
+
field({ decoder: new ArrayDecoder(ProductDiscountSettings), version: 237, optional: true })
|
|
669
|
+
], CartItem.prototype, "discounts", void 0);
|
|
670
|
+
__decorate([
|
|
671
|
+
field({ decoder: IntegerDecoder, version: 115 })
|
|
672
|
+
], CartItem.prototype, "reservedAmount", void 0);
|
|
673
|
+
__decorate([
|
|
674
|
+
field({ decoder: new MapDecoder(StringDecoder, IntegerDecoder), version: 224 })
|
|
675
|
+
], CartItem.prototype, "reservedOptions", void 0);
|
|
676
|
+
__decorate([
|
|
677
|
+
field({ decoder: new MapDecoder(StringDecoder, IntegerDecoder), version: 224 })
|
|
678
|
+
], CartItem.prototype, "reservedPrices", void 0);
|
|
679
|
+
__decorate([
|
|
680
|
+
field({ decoder: new ArrayDecoder(CartReservedSeat), version: 213 })
|
|
681
|
+
], CartItem.prototype, "reservedSeats", void 0);
|
|
682
|
+
__decorate([
|
|
683
|
+
field({ decoder: IntegerDecoder, nullable: true, version: 107 })
|
|
684
|
+
], CartItem.prototype, "unitPrice", void 0);
|
|
685
|
+
__decorate([
|
|
686
|
+
field({ decoder: new ArrayDecoder(CartItemPrice), version: 236, upgrade: function () {
|
|
687
|
+
var _a;
|
|
688
|
+
const prices = [];
|
|
689
|
+
const unitPrice = (_a = this.unitPrice) !== null && _a !== void 0 ? _a : 0;
|
|
690
|
+
for (const seat of this.seats) {
|
|
691
|
+
const seatPrice = unitPrice + seat.price;
|
|
692
|
+
prices.push(CartItemPrice.create({
|
|
693
|
+
price: seatPrice
|
|
694
|
+
}));
|
|
695
|
+
}
|
|
696
|
+
// Others (non seats)
|
|
697
|
+
const remaining = this.amount - this.seats.length;
|
|
698
|
+
if (remaining > 0) {
|
|
699
|
+
for (let index = 0; index < remaining; index++) {
|
|
700
|
+
prices.push(CartItemPrice.create({
|
|
701
|
+
price: unitPrice
|
|
702
|
+
}));
|
|
703
|
+
}
|
|
704
|
+
}
|
|
705
|
+
return prices;
|
|
706
|
+
} })
|
|
707
|
+
], CartItem.prototype, "calculatedPrices", void 0);
|
|
708
|
+
//# sourceMappingURL=CartItem.js.map
|