@saasicat/core 1.0.0-rc.24 → 1.0.0-rc.25
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/dist/.build-stamp +1 -1
- package/dist/index.cjs +435 -7
- package/dist/index.d.cts +1860 -545
- package/dist/index.d.ts +1860 -545
- package/dist/index.js +415 -7
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -24,6 +24,7 @@ __export(index_exports, {
|
|
|
24
24
|
AUTH_ERROR_CODES: () => AUTH_ERROR_CODES,
|
|
25
25
|
BILLING_ERROR_CODES: () => BILLING_ERROR_CODES,
|
|
26
26
|
BUNDLE_PRICE_LOOKUP_LIMIT: () => BUNDLE_PRICE_LOOKUP_LIMIT,
|
|
27
|
+
BUNDLE_VERSION_RETIREMENT_CAPABILITY: () => BUNDLE_VERSION_RETIREMENT_CAPABILITY,
|
|
27
28
|
CATALOGUE_KEYS: () => CATALOGUE_KEYS,
|
|
28
29
|
CATALOG_ERROR_CODES: () => CATALOG_ERROR_CODES,
|
|
29
30
|
CONTRACT_ERROR_CODES: () => CONTRACT_ERROR_CODES,
|
|
@@ -64,7 +65,15 @@ __export(index_exports, {
|
|
|
64
65
|
SETTINGS_ERROR_CODES: () => SETTINGS_ERROR_CODES,
|
|
65
66
|
SETUP_ERROR_CODES: () => SETUP_ERROR_CODES,
|
|
66
67
|
SUBSCRIBER_ACCOUNT_CAPABILITY: () => SUBSCRIBER_ACCOUNT_CAPABILITY,
|
|
68
|
+
SUBSCRIBER_ATTENTION_CAPABILITY: () => SUBSCRIBER_ATTENTION_CAPABILITY,
|
|
69
|
+
SUBSCRIBER_ATTENTION_PAGE_SIZE: () => SUBSCRIBER_ATTENTION_PAGE_SIZE,
|
|
70
|
+
SUBSCRIBER_CORRECTION_CAPABILITY: () => SUBSCRIBER_CORRECTION_CAPABILITY,
|
|
67
71
|
SUBSCRIBER_ERROR_CODES: () => SUBSCRIBER_ERROR_CODES,
|
|
72
|
+
SUBSCRIBER_INVOICE_ADDRESS_FIELDS: () => SUBSCRIBER_INVOICE_ADDRESS_FIELDS,
|
|
73
|
+
SUBSCRIBER_STANDING_CAPABILITY: () => SUBSCRIBER_STANDING_CAPABILITY,
|
|
74
|
+
SUBSCRIBER_TAX_ORIGIN_FIELDS: () => SUBSCRIBER_TAX_ORIGIN_FIELDS,
|
|
75
|
+
TAX_ERROR_CODES: () => TAX_ERROR_CODES,
|
|
76
|
+
TAX_TREATMENT_KINDS: () => TAX_TREATMENT_KINDS,
|
|
68
77
|
VERSION_RETIREMENT_CAPABILITY: () => VERSION_RETIREMENT_CAPABILITY,
|
|
69
78
|
applyPromo: () => applyPromo,
|
|
70
79
|
assertPersistenceCapabilities: () => assertPersistenceCapabilities,
|
|
@@ -75,6 +84,7 @@ __export(index_exports, {
|
|
|
75
84
|
bundleKeyTaken: () => bundleKeyTaken,
|
|
76
85
|
bundleStemDefaults: () => bundleStemDefaults,
|
|
77
86
|
canonicalJson: () => canonicalJson,
|
|
87
|
+
canonicalVatId: () => canonicalVatId,
|
|
78
88
|
catalogDraftExists: () => catalogDraftExists,
|
|
79
89
|
catalogVersionAlreadyPublished: () => catalogVersionAlreadyPublished,
|
|
80
90
|
catalogVersionGone: () => catalogVersionGone,
|
|
@@ -106,6 +116,7 @@ __export(index_exports, {
|
|
|
106
116
|
isVersionEditable: () => isVersionEditable,
|
|
107
117
|
issuerIdentityOf: () => issuerIdentityOf,
|
|
108
118
|
keepOneRecommended: () => keepOneRecommended,
|
|
119
|
+
keepsVatIdCheck: () => keepsVatIdCheck,
|
|
109
120
|
maintenanceRetryAfterSeconds: () => maintenanceRetryAfterSeconds,
|
|
110
121
|
maintenanceStatusOf: () => maintenanceStatusOf,
|
|
111
122
|
maintenanceWindowStatusOf: () => maintenanceWindowStatusOf,
|
|
@@ -152,7 +163,11 @@ __export(index_exports, {
|
|
|
152
163
|
subscriptionContractGone: () => subscriptionContractGone,
|
|
153
164
|
subscriptionGone: () => subscriptionGone,
|
|
154
165
|
sumToCents: () => sumToCents,
|
|
166
|
+
taxOriginOf: () => taxOriginOf,
|
|
167
|
+
taxOriginWrite: () => taxOriginWrite,
|
|
168
|
+
taxTreatmentToJson: () => taxTreatmentToJson,
|
|
155
169
|
toBundleStemRow: () => toBundleStemRow,
|
|
170
|
+
toBundleVersionRetirementRecord: () => toBundleVersionRetirementRecord,
|
|
156
171
|
toCents: () => toCents,
|
|
157
172
|
toContractLineItemRecord: () => toContractLineItemRecord,
|
|
158
173
|
toDecimalString: () => toDecimalString,
|
|
@@ -164,10 +179,15 @@ __export(index_exports, {
|
|
|
164
179
|
toSubscriberCorrectionRecord: () => toSubscriberCorrectionRecord,
|
|
165
180
|
toSubscriberPaymentMethodRecord: () => toSubscriberPaymentMethodRecord,
|
|
166
181
|
toSubscriberRecord: () => toSubscriberRecord,
|
|
182
|
+
toSubscriberTaxOriginChangeRecord: () => toSubscriberTaxOriginChangeRecord,
|
|
183
|
+
toSubscriberVatIdCheckRecord: () => toSubscriberVatIdCheckRecord,
|
|
167
184
|
toSubscriptionBundleRecord: () => toSubscriptionBundleRecord,
|
|
168
185
|
toSubscriptionContractRecord: () => toSubscriptionContractRecord,
|
|
169
186
|
toSubscriptionNoticeRecord: () => toSubscriptionNoticeRecord,
|
|
187
|
+
toTaxOriginValues: () => toTaxOriginValues,
|
|
188
|
+
toTaxTreatment: () => toTaxTreatment,
|
|
170
189
|
toVersionRetirementRecord: () => toVersionRetirementRecord,
|
|
190
|
+
vatIdCheckFromStore: () => vatIdCheckFromStore,
|
|
171
191
|
versionOnSale: () => versionOnSale,
|
|
172
192
|
versionOnSaleOrNext: () => versionOnSaleOrNext,
|
|
173
193
|
versionSale: () => versionSale
|
|
@@ -580,7 +600,10 @@ var TABLE = "subscription_notices";
|
|
|
580
600
|
var KINDS = {
|
|
581
601
|
"version-offered": true,
|
|
582
602
|
"version-retired": true,
|
|
583
|
-
"version-retirement-reminder": true
|
|
603
|
+
"version-retirement-reminder": true,
|
|
604
|
+
"bundle-version-retired": true,
|
|
605
|
+
"bundle-version-retirement-reminder": true,
|
|
606
|
+
"bundle-version-offered": true
|
|
584
607
|
};
|
|
585
608
|
function toSubscriptionNoticeRecord(row) {
|
|
586
609
|
return {
|
|
@@ -689,6 +712,28 @@ function toVersionRetirementRecord(row) {
|
|
|
689
712
|
};
|
|
690
713
|
}
|
|
691
714
|
|
|
715
|
+
// src/bundle-version-retirement.types.ts
|
|
716
|
+
var BUNDLE_VERSION_RETIREMENT_CAPABILITY = "bundleVersions.retire";
|
|
717
|
+
|
|
718
|
+
// src/bundle-version-retirement-mapping.ts
|
|
719
|
+
function toBundleVersionRetirementRecord(row) {
|
|
720
|
+
return {
|
|
721
|
+
id: row.id,
|
|
722
|
+
retired: {
|
|
723
|
+
bundleVersionId: row.retiredBundleVersionId,
|
|
724
|
+
bundleKey: row.retiredBundleKey,
|
|
725
|
+
version: row.retiredVersion
|
|
726
|
+
},
|
|
727
|
+
replacement: {
|
|
728
|
+
bundleVersionId: row.replacementBundleVersionId,
|
|
729
|
+
bundleKey: row.replacementBundleKey,
|
|
730
|
+
version: row.replacementVersion
|
|
731
|
+
},
|
|
732
|
+
announcedAt: row.announcedAt,
|
|
733
|
+
announcedBy: row.announcedBy
|
|
734
|
+
};
|
|
735
|
+
}
|
|
736
|
+
|
|
692
737
|
// src/scheduled-change-after-write.ts
|
|
693
738
|
var NO_SCHEDULED_CHANGE = {
|
|
694
739
|
pendingPlan: null,
|
|
@@ -996,6 +1041,13 @@ var CATALOG_ERROR_CODES = {
|
|
|
996
1041
|
PLAN_NOT_FOUND: "PLAN_NOT_FOUND",
|
|
997
1042
|
PLAN_VERSION_NOT_FOUND: "PLAN_VERSION_NOT_FOUND",
|
|
998
1043
|
BUNDLE_NOT_FOUND: "BUNDLE_NOT_FOUND",
|
|
1044
|
+
/**
|
|
1045
|
+
* Bookings told that their add-on version is being retired have still to
|
|
1046
|
+
* move onto a version of this add-on — waiting for their notice, for their
|
|
1047
|
+
* date, or past it — and a deleted add-on is booked by nothing, the move
|
|
1048
|
+
* included. Carries how many, and the add-on's key.
|
|
1049
|
+
*/
|
|
1050
|
+
BUNDLE_DELETE_WHILE_RETIREMENT_MOVES_PENDING: "BUNDLE_DELETE_WHILE_RETIREMENT_MOVES_PENDING",
|
|
999
1051
|
BUNDLE_VERSION_NOT_FOUND: "BUNDLE_VERSION_NOT_FOUND",
|
|
1000
1052
|
FEATURE_NOT_FOUND: "FEATURE_NOT_FOUND",
|
|
1001
1053
|
QUOTA_NOT_FOUND: "QUOTA_NOT_FOUND",
|
|
@@ -1186,6 +1238,16 @@ var BILLING_ERROR_CODES = {
|
|
|
1186
1238
|
* to pick, so the way past it is the add-on ending.
|
|
1187
1239
|
*/
|
|
1188
1240
|
RETIREMENT_SWITCH_BUNDLE_CANNOT_FOLLOW: "RETIREMENT_SWITCH_BUNDLE_CANNOT_FOLLOW",
|
|
1241
|
+
/**
|
|
1242
|
+
* As `RETIREMENT_SWITCH_BUNDLE_CANNOT_FOLLOW`, where only the version the
|
|
1243
|
+
* add-on continues on from a retirement's date cannot run beside the
|
|
1244
|
+
* replacement's plan. The version it is on can, so cancelling it — it then
|
|
1245
|
+
* ends before that date — lets the switch through. Given while that date
|
|
1246
|
+
* is ahead and the add-on is not cancelled yet; otherwise the earlier code
|
|
1247
|
+
* names the day it can end. Carries the add-on, that version, its date and
|
|
1248
|
+
* the plan.
|
|
1249
|
+
*/
|
|
1250
|
+
RETIREMENT_SWITCH_BUNDLE_REPLACEMENT_CANNOT_FOLLOW: "RETIREMENT_SWITCH_BUNDLE_REPLACEMENT_CANNOT_FOLLOW",
|
|
1189
1251
|
/**
|
|
1190
1252
|
* The subscription takes no switch now: a change is scheduled, it has
|
|
1191
1253
|
* ended, or its plan is held for a special contract.
|
|
@@ -1196,6 +1258,75 @@ var BILLING_ERROR_CODES = {
|
|
|
1196
1258
|
* the retirement as it now stands.
|
|
1197
1259
|
*/
|
|
1198
1260
|
RETIREMENT_SWITCH_CHANGED: "RETIREMENT_SWITCH_CHANGED",
|
|
1261
|
+
// ── retiring an add-on version for running bookings ──
|
|
1262
|
+
//
|
|
1263
|
+
// An add-on retirement answers with the plan retirement's codes where the
|
|
1264
|
+
// sentence is the same — terms not confirmed, a version named as its own
|
|
1265
|
+
// replacement, twelve months, a preview that changed — and with these
|
|
1266
|
+
// where it names an add-on rather than a plan.
|
|
1267
|
+
/**
|
|
1268
|
+
* The add-on version is still on sale: a booking made after the
|
|
1269
|
+
* announcement would be on it without having been told. Carries the
|
|
1270
|
+
* add-on key and the version.
|
|
1271
|
+
*/
|
|
1272
|
+
BUNDLE_RETIREMENT_VERSION_ON_SALE: "BUNDLE_RETIREMENT_VERSION_ON_SALE",
|
|
1273
|
+
/** The replacement is not on sale, so no booking can continue on it. Carries add-on key and version. */
|
|
1274
|
+
BUNDLE_RETIREMENT_REPLACEMENT_NOT_ON_SALE: "BUNDLE_RETIREMENT_REPLACEMENT_NOT_ON_SALE",
|
|
1275
|
+
/**
|
|
1276
|
+
* The replacement is a version of another add-on. A booking continues on
|
|
1277
|
+
* a version of its own add-on, so it stays the same booking with its term.
|
|
1278
|
+
* Carries both add-on keys.
|
|
1279
|
+
*/
|
|
1280
|
+
BUNDLE_RETIREMENT_REPLACEMENT_OF_ANOTHER_BUNDLE: "BUNDLE_RETIREMENT_REPLACEMENT_OF_ANOTHER_BUNDLE",
|
|
1281
|
+
/**
|
|
1282
|
+
* Some of the bookings it reaches run, at their date, beside a plan the
|
|
1283
|
+
* replacement cannot run beside: not allowed there, without a price there
|
|
1284
|
+
* in the booking's rhythm, or in a longer rhythm than the plan's. Carries
|
|
1285
|
+
* how many, and the replacement's add-on key and version.
|
|
1286
|
+
*/
|
|
1287
|
+
BUNDLE_RETIREMENT_REPLACEMENT_CANNOT_RUN: "BUNDLE_RETIREMENT_REPLACEMENT_CANNOT_RUN",
|
|
1288
|
+
/** No running booking is on the version: there is nobody to tell. Carries add-on key and version. */
|
|
1289
|
+
BUNDLE_RETIREMENT_NOTHING_AFFECTED: "BUNDLE_RETIREMENT_NOTHING_AFFECTED",
|
|
1290
|
+
/**
|
|
1291
|
+
* The booking is on an add-on version being retired, and was cancelled to
|
|
1292
|
+
* end before it would move, so it was never told and nothing moves it.
|
|
1293
|
+
* Reinstated, it would run on past the date on a version nobody sells;
|
|
1294
|
+
* booking the replacement once it has ended is the way. Carries the add-on
|
|
1295
|
+
* key, the version, the replacement's version and the day it can be booked
|
|
1296
|
+
* from.
|
|
1297
|
+
*/
|
|
1298
|
+
BUNDLE_RETIREMENT_REINSTATE_REFUSED: "BUNDLE_RETIREMENT_REINSTATE_REFUSED",
|
|
1299
|
+
/**
|
|
1300
|
+
* As `BUNDLE_RETIREMENT_REINSTATE_REFUSED`, where the replacement cannot
|
|
1301
|
+
* run beside the plan the subscription is on when the booking ends, or
|
|
1302
|
+
* beside one it is already set to move to after that, in any rhythm it
|
|
1303
|
+
* could be booked in, so there is no version of the add-on to book.
|
|
1304
|
+
* Carries the add-on key, the version and the replacement's version.
|
|
1305
|
+
*/
|
|
1306
|
+
BUNDLE_RETIREMENT_REINSTATE_REPLACEMENT_CANNOT_RUN: "BUNDLE_RETIREMENT_REINSTATE_REPLACEMENT_CANNOT_RUN",
|
|
1307
|
+
/**
|
|
1308
|
+
* As `BUNDLE_RETIREMENT_REINSTATE_REFUSED`, where the subscription ends by
|
|
1309
|
+
* the day the replacement could be booked from, so there is no day to
|
|
1310
|
+
* name. Carries the add-on key, the version and the replacement's version.
|
|
1311
|
+
*/
|
|
1312
|
+
BUNDLE_RETIREMENT_REINSTATE_SUBSCRIPTION_ENDS: "BUNDLE_RETIREMENT_REINSTATE_SUBSCRIPTION_ENDS",
|
|
1313
|
+
/**
|
|
1314
|
+
* The plan the add-on runs beside, or the rhythm it is billed in, changes
|
|
1315
|
+
* before the date the booking was told — by a change scheduled, or by a
|
|
1316
|
+
* retirement told that moves the subscription to another plan — so the
|
|
1317
|
+
* price a switch now would hold is not the one the booking pays until
|
|
1318
|
+
* then. Switching once the plan has changed, or waiting for the
|
|
1319
|
+
* date, is the way. Carries the add-on and the date.
|
|
1320
|
+
*/
|
|
1321
|
+
BUNDLE_RETIREMENT_SWITCH_PLAN_CHANGES: "BUNDLE_RETIREMENT_SWITCH_PLAN_CHANGES",
|
|
1322
|
+
/**
|
|
1323
|
+
* The add-on version the caller asked to switch a booking to is no longer
|
|
1324
|
+
* the one offered beside it — another is on sale, the booking moved, or
|
|
1325
|
+
* there is no offer. Nothing was switched. Carries the version named
|
|
1326
|
+
* (`bundleVersionId`) and the current `offer`, or `null`, so the page can
|
|
1327
|
+
* show it instead of guessing.
|
|
1328
|
+
*/
|
|
1329
|
+
BUNDLE_VERSION_OFFER_CHANGED: "BUNDLE_VERSION_OFFER_CHANGED",
|
|
1199
1330
|
// ── the preview routes' own blockers and warnings ──
|
|
1200
1331
|
//
|
|
1201
1332
|
// These travel inside a 200 response, in `blockers[]` and `warnings[]`, not
|
|
@@ -1242,6 +1373,16 @@ var BILLING_ERROR_CODES = {
|
|
|
1242
1373
|
* day the booking can end.
|
|
1243
1374
|
*/
|
|
1244
1375
|
BUNDLE_BOOKING_DOES_NOT_FIT_TARGET_PLAN: "BUNDLE_BOOKING_DOES_NOT_FIT_TARGET_PLAN",
|
|
1376
|
+
/**
|
|
1377
|
+
* A bundle the tenant already holds can run on the plan they are moving
|
|
1378
|
+
* to, but the version it continues on from a retirement's date cannot.
|
|
1379
|
+
* Cancelling it lets the change through at once: the booking then ends
|
|
1380
|
+
* before that date and never reaches the version. Given while that date is
|
|
1381
|
+
* ahead and the booking is not cancelled yet; otherwise
|
|
1382
|
+
* `BUNDLE_BOOKING_DOES_NOT_FIT_TARGET_PLAN` names the day it can end.
|
|
1383
|
+
* Carries the bundle, that version, its date and the plan.
|
|
1384
|
+
*/
|
|
1385
|
+
BUNDLE_REPLACEMENT_DOES_NOT_FIT_TARGET_PLAN: "BUNDLE_REPLACEMENT_DOES_NOT_FIT_TARGET_PLAN",
|
|
1245
1386
|
/**
|
|
1246
1387
|
* Features of the previewed bundle are already covered by the plan or by
|
|
1247
1388
|
* another booked bundle. A warning rather than a blocker: paying twice is
|
|
@@ -1311,6 +1452,21 @@ var CONTRACT_ERROR_CODES = {
|
|
|
1311
1452
|
* describes. Nothing was written; load the offer and conclude it again.
|
|
1312
1453
|
*/
|
|
1313
1454
|
CHECKOUT_OFFER_CHANGED: "CHECKOUT_OFFER_CHANGED",
|
|
1455
|
+
/**
|
|
1456
|
+
* An offer concludes a tenant's first contract, and this tenant has a
|
|
1457
|
+
* contract in force at the moment the offer's would take effect, or one
|
|
1458
|
+
* beginning after it. Concluded, the two would run side by side. Nothing
|
|
1459
|
+
* was written; a running subscription changes through its plan and its
|
|
1460
|
+
* add-ons. Carries the offer and the contract that runs.
|
|
1461
|
+
*/
|
|
1462
|
+
CHECKOUT_OFFER_CONTRACT_IN_FORCE: "CHECKOUT_OFFER_CONTRACT_IN_FORCE",
|
|
1463
|
+
/**
|
|
1464
|
+
* The offer names a version of an add-on the tenant has booked in another
|
|
1465
|
+
* version. Concluded, the contract would name a version the booking is not
|
|
1466
|
+
* on. Nothing was written; a booking changes its version through the offer
|
|
1467
|
+
* beside it. Carries the offer, the add-on, the booking and both versions.
|
|
1468
|
+
*/
|
|
1469
|
+
CHECKOUT_OFFER_ADD_ON_BOOKED_IN_ANOTHER_VERSION: "CHECKOUT_OFFER_ADD_ON_BOOKED_IN_ANOTHER_VERSION",
|
|
1314
1470
|
SUBSCRIPTION_CONTRACT_NOT_FOUND: "SUBSCRIPTION_CONTRACT_NOT_FOUND",
|
|
1315
1471
|
NO_ACTIVE_SUBSCRIPTION_CONTRACT: "NO_ACTIVE_SUBSCRIPTION_CONTRACT",
|
|
1316
1472
|
SUBSCRIPTION_CONTRACT_ALREADY_CLOSED: "SUBSCRIPTION_CONTRACT_ALREADY_CLOSED",
|
|
@@ -1321,7 +1477,12 @@ var CONTRACT_ERROR_CODES = {
|
|
|
1321
1477
|
* second attempt, or a contract begins after the moment the successor
|
|
1322
1478
|
* would take effect. Nothing was written.
|
|
1323
1479
|
*/
|
|
1324
|
-
SUBSCRIPTION_CONTRACT_CHANGED: "SUBSCRIPTION_CONTRACT_CHANGED"
|
|
1480
|
+
SUBSCRIPTION_CONTRACT_CHANGED: "SUBSCRIPTION_CONTRACT_CHANGED",
|
|
1481
|
+
/**
|
|
1482
|
+
* A contract states a tax rate — `field` names where — other than the one
|
|
1483
|
+
* the installation's tax adapter decides for its subscriber.
|
|
1484
|
+
*/
|
|
1485
|
+
SUBSCRIPTION_CONTRACT_TAX_RATE_NOT_DECIDED: "SUBSCRIPTION_CONTRACT_TAX_RATE_NOT_DECIDED"
|
|
1325
1486
|
};
|
|
1326
1487
|
var SUBSCRIBER_ERROR_CODES = {
|
|
1327
1488
|
/**
|
|
@@ -1345,7 +1506,30 @@ var SUBSCRIBER_ERROR_CODES = {
|
|
|
1345
1506
|
SUBSCRIBER_CORRECTION_ACTOR_REQUIRED: "SUBSCRIBER_CORRECTION_ACTOR_REQUIRED",
|
|
1346
1507
|
SUBSCRIBER_CORRECTION_CHANGES_NOTHING: "SUBSCRIBER_CORRECTION_CHANGES_NOTHING",
|
|
1347
1508
|
/** The operator declared another legal entity: that is a transfer, not an edit. */
|
|
1348
|
-
SUBSCRIBER_TAKEOVER_IS_A_TRANSFER: "SUBSCRIBER_TAKEOVER_IS_A_TRANSFER"
|
|
1509
|
+
SUBSCRIBER_TAKEOVER_IS_A_TRANSFER: "SUBSCRIBER_TAKEOVER_IS_A_TRANSFER",
|
|
1510
|
+
/**
|
|
1511
|
+
* A contact change named whether the subscriber is a business. That is part
|
|
1512
|
+
* of its tax origin and changes as a recorded change naming who made it.
|
|
1513
|
+
*/
|
|
1514
|
+
SUBSCRIBER_BUSINESS_STATUS_NOT_A_CONTACT: "SUBSCRIBER_BUSINESS_STATUS_NOT_A_CONTACT",
|
|
1515
|
+
/** A change of the subscriber's contact details or business status did not say who makes it. */
|
|
1516
|
+
SUBSCRIBER_CHANGE_ACTOR_REQUIRED: "SUBSCRIBER_CHANGE_ACTOR_REQUIRED",
|
|
1517
|
+
/**
|
|
1518
|
+
* Where a tax adapter decides, a contract names its subscriber only once
|
|
1519
|
+
* the address an invoice names is complete (`SC-PRIC-032`): a party copied
|
|
1520
|
+
* onto a contract incomplete cannot be completed afterwards. Carries
|
|
1521
|
+
* `missing`, the empty fields, for a screen to name by their labels; the
|
|
1522
|
+
* shipped sentence names all four rather than the keys.
|
|
1523
|
+
*/
|
|
1524
|
+
SUBSCRIBER_IDENTITY_INCOMPLETE: "SUBSCRIBER_IDENTITY_INCOMPLETE",
|
|
1525
|
+
/**
|
|
1526
|
+
* A change of whether the subscriber is a business states no reason. It
|
|
1527
|
+
* decides the tax treatment of the next invoice, so the change log keeps
|
|
1528
|
+
* why it moved (`SC-PRIC-043`).
|
|
1529
|
+
*/
|
|
1530
|
+
SUBSCRIBER_BUSINESS_STATUS_REASON_REQUIRED: "SUBSCRIBER_BUSINESS_STATUS_REASON_REQUIRED",
|
|
1531
|
+
/** A check of the subscriber's VAT identification number was asked for, and it holds none. */
|
|
1532
|
+
SUBSCRIBER_VAT_ID_MISSING: "SUBSCRIBER_VAT_ID_MISSING"
|
|
1349
1533
|
};
|
|
1350
1534
|
var REGISTRATION_ERROR_CODES = {
|
|
1351
1535
|
PENDING_REGISTRATION_NOT_FOUND: "PENDING_REGISTRATION_NOT_FOUND",
|
|
@@ -1450,6 +1634,29 @@ var MAINTENANCE_ERROR_CODES = {
|
|
|
1450
1634
|
/** The message is longer than `MAINTENANCE_MESSAGE_MAX_LENGTH`. */
|
|
1451
1635
|
MAINTENANCE_MESSAGE_TOO_LONG: "MAINTENANCE_MESSAGE_TOO_LONG"
|
|
1452
1636
|
};
|
|
1637
|
+
var TAX_ERROR_CODES = {
|
|
1638
|
+
/**
|
|
1639
|
+
* The tax adapter answers that it does not support the subscriber's case;
|
|
1640
|
+
* `adapter` names it and `reason` is its sentence. Nothing is concluded with
|
|
1641
|
+
* a guessed tax (`SC-PRIC-039`).
|
|
1642
|
+
*/
|
|
1643
|
+
TAX_TREATMENT_NOT_SUPPORTED: "TAX_TREATMENT_NOT_SUPPORTED",
|
|
1644
|
+
/**
|
|
1645
|
+
* The tax adapter needs the VAT identification number checked to treat the
|
|
1646
|
+
* case, and the check did not complete — the service is unavailable, timed
|
|
1647
|
+
* out, or answered in a way the adapter cannot read (`503`). Nothing is
|
|
1648
|
+
* decided in the subscriber's favour on a number not checked
|
|
1649
|
+
* (`SC-PRIC-040`): try again later. `adapter` names the adapter and
|
|
1650
|
+
* `reason` says why.
|
|
1651
|
+
*/
|
|
1652
|
+
TAX_VAT_ID_CHECK_NOT_COMPLETED: "TAX_VAT_ID_CHECK_NOT_COMPLETED",
|
|
1653
|
+
/**
|
|
1654
|
+
* A VAT identification number was to be checked, and `config/saas.yaml`
|
|
1655
|
+
* names no tax adapter, which is what names the service to check with
|
|
1656
|
+
* (`409`).
|
|
1657
|
+
*/
|
|
1658
|
+
TAX_VAT_ID_CHECK_NOT_AVAILABLE: "TAX_VAT_ID_CHECK_NOT_AVAILABLE"
|
|
1659
|
+
};
|
|
1453
1660
|
var PLATFORM_ERROR_CODES = {
|
|
1454
1661
|
...SETUP_ERROR_CODES,
|
|
1455
1662
|
...AUTH_ERROR_CODES,
|
|
@@ -1461,7 +1668,8 @@ var PLATFORM_ERROR_CODES = {
|
|
|
1461
1668
|
...REGISTRATION_ERROR_CODES,
|
|
1462
1669
|
...PAYMENT_ERROR_CODES,
|
|
1463
1670
|
...SETTINGS_ERROR_CODES,
|
|
1464
|
-
...MAINTENANCE_ERROR_CODES
|
|
1671
|
+
...MAINTENANCE_ERROR_CODES,
|
|
1672
|
+
...TAX_ERROR_CODES
|
|
1465
1673
|
};
|
|
1466
1674
|
|
|
1467
1675
|
// src/errors.ts
|
|
@@ -1508,6 +1716,7 @@ var OPTIONAL_CANONICAL_MODELS = {
|
|
|
1508
1716
|
MaintenanceWindow: ["core.maintenanceWindows"],
|
|
1509
1717
|
SubscriptionNotice: ["tenantBilling.subscriptionNotices"],
|
|
1510
1718
|
VersionRetirement: ["tenantBilling.versionRetirements"],
|
|
1719
|
+
BundleVersionRetirement: ["tenantBilling.bundleVersionRetirements"],
|
|
1511
1720
|
SubscriberLedgerEntry: ["entitlement.subscriberLedgerRepository"],
|
|
1512
1721
|
PromoCodeHold: ["promo.holdRepository"]
|
|
1513
1722
|
};
|
|
@@ -1625,6 +1834,7 @@ var ERROR_MESSAGES_EN = {
|
|
|
1625
1834
|
PLAN_NOT_FOUND: "Plan '{planId}' not found",
|
|
1626
1835
|
PLAN_VERSION_NOT_FOUND: "PlanVersion '{versionId}' not found",
|
|
1627
1836
|
BUNDLE_NOT_FOUND: "Bundle '{bundleId}' not found",
|
|
1837
|
+
BUNDLE_DELETE_WHILE_RETIREMENT_MOVES_PENDING: "{count} bookings still move onto a version of {bundleKey}, as a retirement told them. The add-on can be deleted once they have.",
|
|
1628
1838
|
BUNDLE_VERSION_NOT_FOUND: "BundleVersion '{bundleVersionId}' not found",
|
|
1629
1839
|
FEATURE_NOT_FOUND: "Feature '{featureKey}' not found",
|
|
1630
1840
|
QUOTA_NOT_FOUND: "Quota '{quotaKey}' not found",
|
|
@@ -1680,9 +1890,20 @@ var ERROR_MESSAGES_EN = {
|
|
|
1680
1890
|
RETIREMENT_NOTHING_AFFECTED: "No running subscription is on version {version} of {planKey}, so there is nobody to tell.",
|
|
1681
1891
|
RETIREMENT_WITHIN_TWELVE_MONTHS: "{count} of these subscriptions were reached by a retirement within the last twelve months. A subscription is reached at most once a year.",
|
|
1682
1892
|
RETIREMENT_PREVIEW_CHANGED: "The subscriptions this retirement reaches changed since they were shown. Look at them again before announcing it.",
|
|
1893
|
+
BUNDLE_RETIREMENT_VERSION_ON_SALE: "Version {version} of {bundleKey} is still on sale. Publish the version that replaces it, and retire this one once its sale has ended, so nobody books it after the announcement.",
|
|
1894
|
+
BUNDLE_RETIREMENT_REPLACEMENT_NOT_ON_SALE: "Version {version} of {bundleKey} is not on sale, so bookings cannot continue on it.",
|
|
1895
|
+
BUNDLE_RETIREMENT_REPLACEMENT_OF_ANOTHER_BUNDLE: "The replacement is a version of {replacementBundleKey}, not of {bundleKey}. A booking continues on a version of its own add-on.",
|
|
1896
|
+
BUNDLE_RETIREMENT_REPLACEMENT_CANNOT_RUN: "{count} of these bookings run beside a plan that version {version} of {bundleKey} cannot run beside, so they cannot continue on it.",
|
|
1897
|
+
BUNDLE_RETIREMENT_NOTHING_AFFECTED: "No running booking is on version {version} of {bundleKey}, so there is nobody to tell.",
|
|
1898
|
+
BUNDLE_RETIREMENT_REINSTATE_REFUSED: "Version {version} of {bundleKey} is being retired, and this booking ends before it would move. Book version {replacementVersion} from {bookableFrom}, when this booking has ended.",
|
|
1899
|
+
BUNDLE_RETIREMENT_REINSTATE_REPLACEMENT_CANNOT_RUN: "Version {version} of {bundleKey} is being retired, and this booking ends before it would move. Version {replacementVersion}, which replaces it, cannot run beside your plan, or beside one your subscription is set to move to.",
|
|
1900
|
+
BUNDLE_RETIREMENT_REINSTATE_SUBSCRIPTION_ENDS: "Version {version} of {bundleKey} is being retired, and this booking ends before it would move. Your subscription ends by then as well.",
|
|
1901
|
+
BUNDLE_RETIREMENT_SWITCH_PLAN_CHANGES: "{bundleName} moves to its new version on {date}, and your plan changes before then, so the price a switch would keep is not known yet. Switch once your plan has changed, or let it move on that date.",
|
|
1902
|
+
BUNDLE_VERSION_OFFER_CHANGED: "The offer changed since it was shown. Look at the current one before switching.",
|
|
1683
1903
|
RETIREMENT_SWITCH_NOT_PENDING: "No retirement of your version is waiting for its date, so there is nothing to switch to.",
|
|
1684
1904
|
RETIREMENT_SWITCH_IN_TRIAL: "The switch opens when your trial ends.",
|
|
1685
1905
|
RETIREMENT_SWITCH_BUNDLE_CANNOT_FOLLOW: "{bundleName} cannot run on {planName} and runs until {until} at the earliest. Once it is cancelled, the switch can be made from that day.",
|
|
1906
|
+
RETIREMENT_SWITCH_BUNDLE_REPLACEMENT_CANNOT_FOLLOW: "{bundleName} continues on version {version} from {from}, which cannot run on {planName}. Once it is cancelled, the switch can be made.",
|
|
1686
1907
|
RETIREMENT_SWITCH_NOT_OPEN: "This subscription cannot switch now: a change is scheduled, it has ended, or its plan is held for a special contract.",
|
|
1687
1908
|
RETIREMENT_SWITCH_CHANGED: "The retirement changed since it was shown. Look at it again before switching.",
|
|
1688
1909
|
SUBSCRIPTION_ENDED: "This subscription has ended. Its plan can no longer be changed.",
|
|
@@ -1695,6 +1916,7 @@ var ERROR_MESSAGES_EN = {
|
|
|
1695
1916
|
CYCLE_SHORTENS_AT_TERM_END: "A monthly {planName} cannot start inside the yearly term you are in. The upgrade takes effect when that term ends; to have it today, keep the yearly cycle.",
|
|
1696
1917
|
BUNDLE_BOOKING_OUTLASTS_TARGET_CYCLE: "{bundleName} is billed yearly and runs until {until} at the earliest, which a monthly plan cannot carry. Once it is cancelled, a change that takes effect on or after that day goes through \u2014 or keep the yearly cycle.",
|
|
1697
1918
|
BUNDLE_BOOKING_DOES_NOT_FIT_TARGET_PLAN: "{bundleName} cannot run on {planName} and runs until {until} at the earliest. Once it is cancelled, a change that takes effect on or after that day goes through \u2014 or choose another plan.",
|
|
1919
|
+
BUNDLE_REPLACEMENT_DOES_NOT_FIT_TARGET_PLAN: "{bundleName} continues on version {version} from {from}, which cannot run on {planName}. Cancel it, and the change goes through \u2014 or choose another plan.",
|
|
1698
1920
|
REDUNDANT_FEATURES: "The plan or another booked bundle already includes {count} of the features in this bundle \u2014 booking it pays for them twice.",
|
|
1699
1921
|
MINIMUM_TERM_BINDS: "The minimum term extends beyond the end of the period \u2014 the cancellation only takes effect when the minimum term ends.",
|
|
1700
1922
|
BUNDLE_FEATURE_DEPENDENCY_UNSATISFIED: "The bundle requires [{features}] \u2014 present neither in the plan nor in the active bundles.",
|
|
@@ -1719,6 +1941,7 @@ var ERROR_MESSAGES_EN = {
|
|
|
1719
1941
|
PROMO_WOULD_PRODUCE_ZERO_INVOICE: "For absolute amounts the discount must stay below the lowest applicable plan price, or allowZeroInvoice must be enabled.",
|
|
1720
1942
|
PROMO_MAX_REDEMPTIONS_LOWERED: "maxRedemptions cannot be lowered.",
|
|
1721
1943
|
// ── contract ──
|
|
1944
|
+
SUBSCRIPTION_CONTRACT_TAX_RATE_NOT_DECIDED: "The contract states {stated} % in {field}, and the tax adapter decides {decided} %.",
|
|
1722
1945
|
CHECKOUT_OFFER_LINE_ITEMS_REQUIRED: "A checkout offer can yield only one contract, and only once its line items are frozen.",
|
|
1723
1946
|
CHECKOUT_OFFER_PLAN_LINE_ITEM_REQUIRED: "A checkout offer requires a frozen plan line item.",
|
|
1724
1947
|
CHECKOUT_OFFER_BUNDLE_LINE_ITEMS_REQUIRED: "Every selected bundle version requires a frozen bundle line item.",
|
|
@@ -1743,6 +1966,8 @@ var ERROR_MESSAGES_EN = {
|
|
|
1743
1966
|
CHECKOUT_OFFER_ALREADY_CONSUMED: "Checkout offer '{offerId}' has already been consumed and cannot be {action}",
|
|
1744
1967
|
CHECKOUT_OFFER_NOT_CONSUMED: "CheckoutOffer '{offerId}' must be consumed before the contract is created",
|
|
1745
1968
|
CHECKOUT_OFFER_CHANGED: "Checkout offer '{offerId}' changed while it was being concluded. Load it again.",
|
|
1969
|
+
CHECKOUT_OFFER_CONTRACT_IN_FORCE: "Checkout offer '{offerId}' concludes a first contract, and this tenant already has one. A running subscription changes through its plan and its add-ons.",
|
|
1970
|
+
CHECKOUT_OFFER_ADD_ON_BOOKED_IN_ANOTHER_VERSION: "Checkout offer '{offerId}' names version {offeredVersion} of add-on '{bundleKey}', which this tenant has booked in version {bookedVersion} (booking {subscriptionBundleId}). Its version changes through the offer beside the add-on.",
|
|
1746
1971
|
SUBSCRIPTION_CONTRACT_NOT_FOUND: "SubscriptionContract '{contractId}' not found",
|
|
1747
1972
|
NO_ACTIVE_SUBSCRIPTION_CONTRACT: "No active subscription contract for tenant {tenantId}",
|
|
1748
1973
|
SUBSCRIPTION_CONTRACT_ALREADY_CLOSED: "SubscriptionContract '{contractId}' is already closed",
|
|
@@ -1753,11 +1978,16 @@ var ERROR_MESSAGES_EN = {
|
|
|
1753
1978
|
SUBSCRIBER_NOT_FOUND: "Subscriber '{subscriberId}' not found",
|
|
1754
1979
|
SUBSCRIBER_LEGAL_NAME_REQUIRED: "A subscriber needs its legal name.",
|
|
1755
1980
|
SUBSCRIBER_DETAIL_INVALID: "The subscriber's {field} is not valid.",
|
|
1981
|
+
SUBSCRIBER_IDENTITY_INCOMPLETE: "The subscriber's billing address is not complete yet: a contract names it only with street and number, postal code, city and country.",
|
|
1756
1982
|
SUBSCRIBER_IDENTITY_NOT_A_CONTACT: "{field} is part of the subscriber's legal identity and changes only as a correction, with a reason.",
|
|
1983
|
+
SUBSCRIBER_BUSINESS_STATUS_REASON_REQUIRED: "A change of whether the subscriber is a business needs a reason.",
|
|
1984
|
+
SUBSCRIBER_VAT_ID_MISSING: "The subscriber has no VAT identification number to check.",
|
|
1757
1985
|
SUBSCRIBER_CORRECTION_REASON_REQUIRED: "A correction of the legal identity needs a reason.",
|
|
1758
1986
|
SUBSCRIBER_CORRECTION_ACTOR_REQUIRED: "A correction of the legal identity has to say who makes it.",
|
|
1759
1987
|
SUBSCRIBER_CORRECTION_CHANGES_NOTHING: "The correction changes nothing: every value it names is already recorded.",
|
|
1760
1988
|
SUBSCRIBER_TAKEOVER_IS_A_TRANSFER: "Another legal entity taking over a subscriber is a transfer, not a correction, and cannot be recorded as an edit.",
|
|
1989
|
+
SUBSCRIBER_BUSINESS_STATUS_NOT_A_CONTACT: "Whether the subscriber is a business is part of its tax origin and changes only as a recorded change that names who made it.",
|
|
1990
|
+
SUBSCRIBER_CHANGE_ACTOR_REQUIRED: "A change of the subscriber's details has to say who makes it.",
|
|
1761
1991
|
// ── registration ──
|
|
1762
1992
|
PENDING_REGISTRATION_NOT_FOUND: "This registration could not be found. It may have already been completed or discarded.",
|
|
1763
1993
|
PENDING_REGISTRATION_EXPIRED: "This registration has expired. Please start again.",
|
|
@@ -1791,7 +2021,11 @@ var ERROR_MESSAGES_EN = {
|
|
|
1791
2021
|
MAINTENANCE_WINDOW_END_NOT_AFTER_START: "The end of a maintenance window has to be after its start.",
|
|
1792
2022
|
MAINTENANCE_WINDOW_END_IN_PAST: "The end of a maintenance window cannot be in the past.",
|
|
1793
2023
|
MAINTENANCE_TIME_INVALID: "The {field} has to be a date and time with its zone, such as 2026-10-02T22:00+02:00.",
|
|
1794
|
-
MAINTENANCE_MESSAGE_TOO_LONG: "The message may be at most {max} characters long."
|
|
2024
|
+
MAINTENANCE_MESSAGE_TOO_LONG: "The message may be at most {max} characters long.",
|
|
2025
|
+
// ── tax ──
|
|
2026
|
+
TAX_TREATMENT_NOT_SUPPORTED: "The tax adapter {adapter} does not support this case: {reason}",
|
|
2027
|
+
TAX_VAT_ID_CHECK_NOT_COMPLETED: "The VAT identification number could not be checked just now ({reason}). Please try again later.",
|
|
2028
|
+
TAX_VAT_ID_CHECK_NOT_AVAILABLE: "This installation names no tax adapter, so no VAT identification number is checked."
|
|
1795
2029
|
};
|
|
1796
2030
|
function formatErrorMessage(template, params = {}) {
|
|
1797
2031
|
return template.replace(/\{(\w+)\}/g, (match, name) => {
|
|
@@ -2148,6 +2382,7 @@ var ORIGINS = {
|
|
|
2148
2382
|
renewal: true,
|
|
2149
2383
|
planChange: true,
|
|
2150
2384
|
bundleBooking: true,
|
|
2385
|
+
bundleChange: true,
|
|
2151
2386
|
credit: true,
|
|
2152
2387
|
correction: true
|
|
2153
2388
|
};
|
|
@@ -2208,6 +2443,137 @@ function keysOf(record) {
|
|
|
2208
2443
|
// src/subscriber-ledger.types.ts
|
|
2209
2444
|
var SUBSCRIBER_ACCOUNT_CAPABILITY = "charges.read";
|
|
2210
2445
|
|
|
2446
|
+
// src/subscriber.types.ts
|
|
2447
|
+
var SUBSCRIBER_INVOICE_ADDRESS_FIELDS = [
|
|
2448
|
+
"addressLine1",
|
|
2449
|
+
"postalCode",
|
|
2450
|
+
"city",
|
|
2451
|
+
"country"
|
|
2452
|
+
];
|
|
2453
|
+
var SUBSCRIBER_STANDING_CAPABILITY = "subscribers.read";
|
|
2454
|
+
var SUBSCRIBER_ATTENTION_CAPABILITY = "subscribers.attention";
|
|
2455
|
+
var SUBSCRIBER_ATTENTION_PAGE_SIZE = 200;
|
|
2456
|
+
var SUBSCRIBER_CORRECTION_CAPABILITY = "subscribers.correct";
|
|
2457
|
+
var SUBSCRIBER_TAX_ORIGIN_FIELDS = ["country", "business", "vatId"];
|
|
2458
|
+
|
|
2459
|
+
// src/tax.types.ts
|
|
2460
|
+
var TAX_TREATMENT_KINDS = [
|
|
2461
|
+
"standard",
|
|
2462
|
+
"reduced",
|
|
2463
|
+
"exempt",
|
|
2464
|
+
"reverse-charge",
|
|
2465
|
+
"not-taxable",
|
|
2466
|
+
"small-business"
|
|
2467
|
+
];
|
|
2468
|
+
|
|
2469
|
+
// src/tax-origin.ts
|
|
2470
|
+
var VAT_ID_SEPARATORS = /[\s.-]/g;
|
|
2471
|
+
function canonicalVatId(written) {
|
|
2472
|
+
const vatId = written.replace(VAT_ID_SEPARATORS, "").toUpperCase();
|
|
2473
|
+
return vatId === "" ? null : vatId;
|
|
2474
|
+
}
|
|
2475
|
+
function taxOriginOf(subscriber, currentCheck) {
|
|
2476
|
+
const validated = subscriber.vatId !== null && currentCheck?.valid === true && currentCheck.vatId === subscriber.vatId;
|
|
2477
|
+
return {
|
|
2478
|
+
country: subscriber.country,
|
|
2479
|
+
business: subscriber.business,
|
|
2480
|
+
vatId: subscriber.vatId,
|
|
2481
|
+
validatedVatId: validated ? subscriber.vatId : null
|
|
2482
|
+
};
|
|
2483
|
+
}
|
|
2484
|
+
function keepsVatIdCheck(held, counting, check) {
|
|
2485
|
+
if (held.vatId === null || check.vatId !== held.vatId) return false;
|
|
2486
|
+
if (held.vatIdSince !== null && check.checkedAt.getTime() < held.vatIdSince.getTime()) {
|
|
2487
|
+
return false;
|
|
2488
|
+
}
|
|
2489
|
+
if (counting === null || counting.vatId !== held.vatId) return true;
|
|
2490
|
+
return counting.checkedAt.getTime() <= check.checkedAt.getTime();
|
|
2491
|
+
}
|
|
2492
|
+
function toSubscriberVatIdCheckRecord(row) {
|
|
2493
|
+
return {
|
|
2494
|
+
id: row.id,
|
|
2495
|
+
subscriberId: row.subscriberId,
|
|
2496
|
+
vatId: row.vatId,
|
|
2497
|
+
checkedAt: row.checkedAt,
|
|
2498
|
+
valid: row.valid,
|
|
2499
|
+
service: row.service,
|
|
2500
|
+
confirmation: textEntries(row.confirmation),
|
|
2501
|
+
recordedAt: row.recordedAt
|
|
2502
|
+
};
|
|
2503
|
+
}
|
|
2504
|
+
function taxTreatmentToJson(treatment) {
|
|
2505
|
+
return {
|
|
2506
|
+
kind: treatment.kind,
|
|
2507
|
+
rate: treatment.rate,
|
|
2508
|
+
note: treatment.note,
|
|
2509
|
+
adapter: { name: treatment.adapter.name, version: treatment.adapter.version }
|
|
2510
|
+
};
|
|
2511
|
+
}
|
|
2512
|
+
function toTaxTreatment(value) {
|
|
2513
|
+
if (!isObject(value)) return null;
|
|
2514
|
+
const { kind, rate, note, adapter } = value;
|
|
2515
|
+
if (!isTreatmentKind(kind)) return null;
|
|
2516
|
+
if (typeof rate !== "number" || !Number.isFinite(rate)) return null;
|
|
2517
|
+
if (note !== null && typeof note !== "string") return null;
|
|
2518
|
+
if (!isObject(adapter)) return null;
|
|
2519
|
+
if (typeof adapter.name !== "string" || typeof adapter.version !== "string") return null;
|
|
2520
|
+
return { kind, rate, note, adapter: { name: adapter.name, version: adapter.version } };
|
|
2521
|
+
}
|
|
2522
|
+
function taxOriginWrite(current, next) {
|
|
2523
|
+
const previous = {};
|
|
2524
|
+
const changed = {};
|
|
2525
|
+
for (const field of SUBSCRIBER_TAX_ORIGIN_FIELDS) {
|
|
2526
|
+
const value = next[field];
|
|
2527
|
+
if (value === void 0 || value === current[field]) continue;
|
|
2528
|
+
previous[field] = current[field];
|
|
2529
|
+
changed[field] = value;
|
|
2530
|
+
}
|
|
2531
|
+
return {
|
|
2532
|
+
previous,
|
|
2533
|
+
changed,
|
|
2534
|
+
moved: Object.keys(changed).length > 0,
|
|
2535
|
+
endsCountingVatIdCheck: Object.prototype.hasOwnProperty.call(changed, "vatId")
|
|
2536
|
+
};
|
|
2537
|
+
}
|
|
2538
|
+
function toTaxOriginValues(value) {
|
|
2539
|
+
if (!isObject(value)) return {};
|
|
2540
|
+
const values = {};
|
|
2541
|
+
for (const field of SUBSCRIBER_TAX_ORIGIN_FIELDS) {
|
|
2542
|
+
if (!Object.prototype.hasOwnProperty.call(value, field)) continue;
|
|
2543
|
+
const entry = value[field];
|
|
2544
|
+
if (field === "business") {
|
|
2545
|
+
values[field] = typeof entry === "boolean" ? entry : null;
|
|
2546
|
+
} else {
|
|
2547
|
+
values[field] = typeof entry === "string" ? entry : null;
|
|
2548
|
+
}
|
|
2549
|
+
}
|
|
2550
|
+
return values;
|
|
2551
|
+
}
|
|
2552
|
+
function isTreatmentKind(value) {
|
|
2553
|
+
return TAX_TREATMENT_KINDS.includes(value);
|
|
2554
|
+
}
|
|
2555
|
+
function isObject(value) {
|
|
2556
|
+
return value !== null && typeof value === "object" && !Array.isArray(value);
|
|
2557
|
+
}
|
|
2558
|
+
function vatIdCheckFromStore(value) {
|
|
2559
|
+
if (!isObject(value)) return null;
|
|
2560
|
+
const { vatId, checkedAt, valid, service, confirmation } = value;
|
|
2561
|
+
const at = checkedAt instanceof Date ? checkedAt : new Date(String(checkedAt));
|
|
2562
|
+
if (typeof vatId !== "string" || typeof valid !== "boolean" || typeof service !== "string") {
|
|
2563
|
+
return null;
|
|
2564
|
+
}
|
|
2565
|
+
if (checkedAt === void 0 || checkedAt === null || Number.isNaN(at.getTime())) return null;
|
|
2566
|
+
return { vatId, checkedAt: at, valid, service, confirmation: textEntries(confirmation) };
|
|
2567
|
+
}
|
|
2568
|
+
function textEntries(value) {
|
|
2569
|
+
if (!isObject(value)) return {};
|
|
2570
|
+
const entries = {};
|
|
2571
|
+
for (const [key, entry] of Object.entries(value)) {
|
|
2572
|
+
if (typeof entry === "string") entries[key] = entry;
|
|
2573
|
+
}
|
|
2574
|
+
return entries;
|
|
2575
|
+
}
|
|
2576
|
+
|
|
2211
2577
|
// src/subscriber-mapping.ts
|
|
2212
2578
|
function formatCustomerNumber(prefix, sequence) {
|
|
2213
2579
|
return `${prefix}${sequence}`;
|
|
@@ -2225,6 +2591,7 @@ function toSubscriberRecord(row, tenantId) {
|
|
|
2225
2591
|
vatId: row.vatId,
|
|
2226
2592
|
taxNumber: row.taxNumber,
|
|
2227
2593
|
invoiceEmail: row.invoiceEmail,
|
|
2594
|
+
business: row.business,
|
|
2228
2595
|
tenantId,
|
|
2229
2596
|
migrated: row.migrated,
|
|
2230
2597
|
createdAt: row.createdAt,
|
|
@@ -2242,6 +2609,17 @@ function toSubscriberCorrectionRecord(row) {
|
|
|
2242
2609
|
correctedAt: row.correctedAt
|
|
2243
2610
|
};
|
|
2244
2611
|
}
|
|
2612
|
+
function toSubscriberTaxOriginChangeRecord(row) {
|
|
2613
|
+
return {
|
|
2614
|
+
id: row.id,
|
|
2615
|
+
subscriberId: row.subscriberId,
|
|
2616
|
+
previous: toTaxOriginValues(row.previous),
|
|
2617
|
+
changed: toTaxOriginValues(row.changed),
|
|
2618
|
+
changedBy: row.changedBy,
|
|
2619
|
+
changedAt: row.changedAt,
|
|
2620
|
+
reason: row.reason
|
|
2621
|
+
};
|
|
2622
|
+
}
|
|
2245
2623
|
function identityCorrectionDelta(current, corrected) {
|
|
2246
2624
|
const previous = {};
|
|
2247
2625
|
const next = {};
|
|
@@ -2305,7 +2683,9 @@ function subscriberFromRegistration(pending) {
|
|
|
2305
2683
|
city: pending.city,
|
|
2306
2684
|
country: pending.country,
|
|
2307
2685
|
vatId: pending.vatId,
|
|
2308
|
-
taxNumber: pending.taxNumber
|
|
2686
|
+
taxNumber: pending.taxNumber,
|
|
2687
|
+
business: pending.business,
|
|
2688
|
+
vatIdCheck: vatIdCheckFromStore(pending.vatIdCheck)
|
|
2309
2689
|
};
|
|
2310
2690
|
}
|
|
2311
2691
|
function toIdentityValues(value) {
|
|
@@ -2406,6 +2786,8 @@ function toSubscriptionBundleRecord(row) {
|
|
|
2406
2786
|
}),
|
|
2407
2787
|
currentPeriodStart: row.currentPeriodStart ?? null,
|
|
2408
2788
|
currentPeriodEnd: row.currentPeriodEnd ?? null,
|
|
2789
|
+
pendingBundleVersionId: row.pendingBundleVersionId ?? null,
|
|
2790
|
+
pendingVersionEffectiveAt: row.pendingVersionEffectiveAt ?? null,
|
|
2409
2791
|
canceledAt: row.canceledAt,
|
|
2410
2792
|
canceledEffectiveAt: row.canceledEffectiveAt,
|
|
2411
2793
|
createdAt: row.createdAt,
|
|
@@ -2422,6 +2804,7 @@ function toSubscriptionContractRecord(row, lineItems) {
|
|
|
2422
2804
|
subscriber: toSubscriberParty(row.subscriberSnapshot),
|
|
2423
2805
|
issuer: isPlainObject2(row.issuerSnapshot) ? toIssuerParty(row.issuerSnapshot) : null,
|
|
2424
2806
|
partiesMigrated: row.partiesMigrated,
|
|
2807
|
+
taxTreatment: toTaxTreatment(row.taxTreatment),
|
|
2425
2808
|
status: row.status,
|
|
2426
2809
|
effectiveFrom: row.effectiveFrom,
|
|
2427
2810
|
effectiveUntil: row.effectiveUntil,
|
|
@@ -2669,6 +3052,7 @@ var ERROR_MESSAGES_DE = {
|
|
|
2669
3052
|
PLAN_NOT_FOUND: "Plan '{planId}' nicht gefunden",
|
|
2670
3053
|
PLAN_VERSION_NOT_FOUND: "PlanVersion '{versionId}' nicht gefunden",
|
|
2671
3054
|
BUNDLE_NOT_FOUND: "Bundle '{bundleId}' nicht gefunden",
|
|
3055
|
+
BUNDLE_DELETE_WHILE_RETIREMENT_MOVES_PENDING: "{count} Buchungen ziehen noch auf eine Version von {bundleKey} um, wie eine Stilllegung es ihnen mitgeteilt hat. Das Add-on l\xE4sst sich l\xF6schen, sobald sie umgezogen sind.",
|
|
2672
3056
|
BUNDLE_VERSION_NOT_FOUND: "BundleVersion '{bundleVersionId}' nicht gefunden",
|
|
2673
3057
|
FEATURE_NOT_FOUND: "Feature '{featureKey}' nicht gefunden",
|
|
2674
3058
|
QUOTA_NOT_FOUND: "Quota '{quotaKey}' nicht gefunden",
|
|
@@ -2724,9 +3108,20 @@ var ERROR_MESSAGES_DE = {
|
|
|
2724
3108
|
RETIREMENT_NOTHING_AFFECTED: "Kein laufendes Abonnement nutzt Version {version} von {planKey}. Es gibt niemanden zu benachrichtigen.",
|
|
2725
3109
|
RETIREMENT_WITHIN_TWELVE_MONTHS: "{count} dieser Abonnements waren in den letzten zw\xF6lf Monaten schon von einer Stilllegung betroffen. Ein Abonnement ist h\xF6chstens einmal im Jahr betroffen.",
|
|
2726
3110
|
RETIREMENT_PREVIEW_CHANGED: "Die Abonnements, die diese Stilllegung betrifft, haben sich seit der Anzeige ge\xE4ndert. Sieh sie dir noch einmal an, bevor du sie ank\xFCndigst.",
|
|
3111
|
+
BUNDLE_RETIREMENT_VERSION_ON_SALE: "Version {version} von {bundleKey} wird noch verkauft. Ver\xF6ffentliche die Version, die sie ersetzt, und lege diese still, sobald ihr Verkauf geendet hat, damit sie nach der Ank\xFCndigung niemand mehr bucht.",
|
|
3112
|
+
BUNDLE_RETIREMENT_REPLACEMENT_NOT_ON_SALE: "Version {version} von {bundleKey} wird nicht verkauft. Buchungen k\xF6nnen nicht auf ihr weiterlaufen.",
|
|
3113
|
+
BUNDLE_RETIREMENT_REPLACEMENT_OF_ANOTHER_BUNDLE: "Der Ersatz ist eine Version von {replacementBundleKey}, nicht von {bundleKey}. Eine Buchung l\xE4uft auf einer Version ihres eigenen Add-ons weiter.",
|
|
3114
|
+
BUNDLE_RETIREMENT_REPLACEMENT_CANNOT_RUN: "{count} dieser Buchungen laufen neben einem Plan, neben dem Version {version} von {bundleKey} nicht laufen kann. Sie k\xF6nnen nicht auf ihr weiterlaufen.",
|
|
3115
|
+
BUNDLE_RETIREMENT_NOTHING_AFFECTED: "Keine laufende Buchung nutzt Version {version} von {bundleKey}. Es gibt niemanden zu benachrichtigen.",
|
|
3116
|
+
BUNDLE_RETIREMENT_REINSTATE_REFUSED: "Version {version} von {bundleKey} wird stillgelegt, und diese Buchung endet, bevor sie umziehen w\xFCrde. Buchen Sie Version {replacementVersion} ab dem {bookableFrom}, wenn diese Buchung beendet ist.",
|
|
3117
|
+
BUNDLE_RETIREMENT_REINSTATE_REPLACEMENT_CANNOT_RUN: "Version {version} von {bundleKey} wird stillgelegt, und diese Buchung endet, bevor sie umziehen w\xFCrde. Version {replacementVersion}, die sie ersetzt, kann neben Ihrem Paket oder einem Paket, zu dem Ihr Abonnement wechselt, nicht laufen.",
|
|
3118
|
+
BUNDLE_RETIREMENT_REINSTATE_SUBSCRIPTION_ENDS: "Version {version} von {bundleKey} wird stillgelegt, und diese Buchung endet, bevor sie umziehen w\xFCrde. Ihr Abonnement endet bis dahin ebenfalls.",
|
|
3119
|
+
BUNDLE_RETIREMENT_SWITCH_PLAN_CHANGES: "{bundleName} zieht am {date} auf seine neue Version um, und Ihr Paket \xE4ndert sich vorher. Der Preis, den ein Wechsel halten w\xFCrde, steht deshalb noch nicht fest. Wechseln Sie, sobald Ihr Paket gewechselt hat, oder lassen Sie es an diesem Tag umziehen.",
|
|
3120
|
+
BUNDLE_VERSION_OFFER_CHANGED: "Das Angebot hat sich seit der Anzeige ge\xE4ndert. Bitte sieh dir das aktuelle an, bevor du wechselst.",
|
|
2727
3121
|
RETIREMENT_SWITCH_NOT_PENDING: "F\xFCr Ihre Version steht keine Einstellung mehr bevor. Es gibt nichts, wohin Sie wechseln k\xF6nnten.",
|
|
2728
3122
|
RETIREMENT_SWITCH_IN_TRIAL: "Der Wechsel ist m\xF6glich, sobald Ihre Testphase endet.",
|
|
2729
3123
|
RETIREMENT_SWITCH_BUNDLE_CANNOT_FOLLOW: "{bundleName} kann im Paket {planName} nicht laufen und l\xE4uft fr\xFChestens bis {until}. Ist es gek\xFCndigt, ist der Wechsel ab diesem Tag m\xF6glich.",
|
|
3124
|
+
RETIREMENT_SWITCH_BUNDLE_REPLACEMENT_CANNOT_FOLLOW: "{bundleName} l\xE4uft ab dem {from} auf Version {version} weiter, die im Paket {planName} nicht laufen kann. Ist es gek\xFCndigt, ist der Wechsel m\xF6glich.",
|
|
2730
3125
|
RETIREMENT_SWITCH_NOT_OPEN: "Dieses Abonnement kann gerade nicht wechseln: Eine \xC4nderung ist geplant, es ist beendet, oder sein Paket gilt f\xFCr einen Sondervertrag.",
|
|
2731
3126
|
RETIREMENT_SWITCH_CHANGED: "Die Einstellung hat sich seit der Anzeige ge\xE4ndert. Sehen Sie sie sich noch einmal an, bevor Sie wechseln.",
|
|
2732
3127
|
SUBSCRIPTION_ENDED: "Dieses Abonnement ist beendet. Sein Paket kann nicht mehr gewechselt werden.",
|
|
@@ -2739,6 +3134,7 @@ var ERROR_MESSAGES_DE = {
|
|
|
2739
3134
|
CYCLE_SHORTENS_AT_TERM_END: "Ein monatlich abgerechnetes {planName} kann nicht innerhalb der laufenden Jahreslaufzeit beginnen. Das Upgrade greift zum Ende dieser Laufzeit; wer es sofort m\xF6chte, beh\xE4lt den j\xE4hrlichen Rhythmus.",
|
|
2740
3135
|
BUNDLE_BOOKING_OUTLASTS_TARGET_CYCLE: "{bundleName} wird j\xE4hrlich abgerechnet und l\xE4uft fr\xFChestens bis {until}; ein monatlich abgerechnetes Paket kann es nicht tragen. Ist es gek\xFCndigt, geht ein Wechsel durch, der an diesem Tag oder sp\xE4ter wirksam wird \u2014 oder behalten Sie den j\xE4hrlichen Rhythmus.",
|
|
2741
3136
|
BUNDLE_BOOKING_DOES_NOT_FIT_TARGET_PLAN: "{bundleName} kann im Paket {planName} nicht laufen und l\xE4uft fr\xFChestens bis {until}. Ist es gek\xFCndigt, geht ein Wechsel durch, der an diesem Tag oder sp\xE4ter wirksam wird \u2014 oder w\xE4hlen Sie ein anderes Paket.",
|
|
3137
|
+
BUNDLE_REPLACEMENT_DOES_NOT_FIT_TARGET_PLAN: "{bundleName} l\xE4uft ab dem {from} auf Version {version} weiter, die im Paket {planName} nicht laufen kann. K\xFCndigen Sie es, dann geht der Wechsel durch \u2014 oder w\xE4hlen Sie ein anderes Paket.",
|
|
2742
3138
|
REDUNDANT_FEATURES: "Der Plan oder ein anderes gebuchtes Bundle enth\xE4lt bereits {count} der Funktionen aus diesem Bundle \u2014 mit der Buchung werden sie doppelt bezahlt.",
|
|
2743
3139
|
MINIMUM_TERM_BINDS: "Die Mindestlaufzeit reicht \xFCber das Ende der Periode hinaus \u2014 die K\xFCndigung wird erst zum Ende der Mindestlaufzeit wirksam.",
|
|
2744
3140
|
BUNDLE_FEATURE_DEPENDENCY_UNSATISFIED: "Das Bundle setzt [{features}] voraus \u2014 weder im Plan noch in den aktiven Bundles vorhanden.",
|
|
@@ -2763,6 +3159,7 @@ var ERROR_MESSAGES_DE = {
|
|
|
2763
3159
|
PROMO_WOULD_PRODUCE_ZERO_INVOICE: "Bei absoluten Betr\xE4gen muss der Rabatt unter dem niedrigsten anwendbaren Planpreis bleiben, oder allowZeroInvoice muss aktiviert sein.",
|
|
2764
3160
|
PROMO_MAX_REDEMPTIONS_LOWERED: "maxRedemptions l\xE4sst sich nicht senken.",
|
|
2765
3161
|
// ── contract ──
|
|
3162
|
+
SUBSCRIPTION_CONTRACT_TAX_RATE_NOT_DECIDED: "Der Vertrag nennt in {field} {stated} %, der Steueradapter entscheidet {decided} %.",
|
|
2766
3163
|
CHECKOUT_OFFER_LINE_ITEMS_REQUIRED: "Aus einem Checkout-Angebot entsteht nur ein einziger Vertrag, und das erst, wenn seine Positionen eingefroren sind.",
|
|
2767
3164
|
CHECKOUT_OFFER_PLAN_LINE_ITEM_REQUIRED: "Ein Checkout-Angebot braucht eine eingefrorene Plan-Position.",
|
|
2768
3165
|
CHECKOUT_OFFER_BUNDLE_LINE_ITEMS_REQUIRED: "Jede gew\xE4hlte Bundle-Version braucht eine eingefrorene Bundle-Position.",
|
|
@@ -2787,6 +3184,8 @@ var ERROR_MESSAGES_DE = {
|
|
|
2787
3184
|
CHECKOUT_OFFER_ALREADY_CONSUMED: "Checkout-Angebot '{offerId}' wurde bereits eingel\xF6st \u2014 '{action}' ist nicht mehr m\xF6glich",
|
|
2788
3185
|
CHECKOUT_OFFER_NOT_CONSUMED: "CheckoutOffer '{offerId}' muss eingel\xF6st sein, bevor der Vertrag entsteht",
|
|
2789
3186
|
CHECKOUT_OFFER_CHANGED: "Checkout-Angebot '{offerId}' hat sich w\xE4hrend des Abschlusses ge\xE4ndert. Bitte neu laden.",
|
|
3187
|
+
CHECKOUT_OFFER_CONTRACT_IN_FORCE: "Checkout-Angebot '{offerId}' schlie\xDFt einen ersten Vertrag ab, und dieser Mandant hat bereits einen. Ein laufendes Abo \xE4ndert sich \xFCber seinen Plan und seine Add-ons.",
|
|
3188
|
+
CHECKOUT_OFFER_ADD_ON_BOOKED_IN_ANOTHER_VERSION: "Checkout-Angebot '{offerId}' nennt Version {offeredVersion} des Add-ons '{bundleKey}', das dieser Mandant in Version {bookedVersion} gebucht hat (Buchung {subscriptionBundleId}). Die Version wechselt \xFCber das Angebot neben dem Add-on.",
|
|
2790
3189
|
SUBSCRIPTION_CONTRACT_NOT_FOUND: "SubscriptionContract '{contractId}' nicht gefunden",
|
|
2791
3190
|
NO_ACTIVE_SUBSCRIPTION_CONTRACT: "Kein aktiver Abo-Vertrag f\xFCr Mandant {tenantId}",
|
|
2792
3191
|
SUBSCRIPTION_CONTRACT_ALREADY_CLOSED: "SubscriptionContract '{contractId}' ist bereits geschlossen",
|
|
@@ -2797,11 +3196,16 @@ var ERROR_MESSAGES_DE = {
|
|
|
2797
3196
|
SUBSCRIBER_NOT_FOUND: "Vertragspartner '{subscriberId}' nicht gefunden",
|
|
2798
3197
|
SUBSCRIBER_LEGAL_NAME_REQUIRED: "Ein Vertragspartner braucht seinen rechtlichen Namen.",
|
|
2799
3198
|
SUBSCRIBER_DETAIL_INVALID: "Das Feld {field} des Vertragspartners ist ung\xFCltig.",
|
|
3199
|
+
SUBSCRIBER_IDENTITY_INCOMPLETE: "Die Rechnungsadresse des Vertragspartners ist noch nicht vollst\xE4ndig: Ein Vertrag nennt ihn nur mit Stra\xDFe und Hausnummer, PLZ, Ort und Land.",
|
|
3200
|
+
SUBSCRIBER_BUSINESS_STATUS_REASON_REQUIRED: "Eine \xC4nderung, ob der Vertragspartner ein Unternehmen ist, braucht eine Begr\xFCndung.",
|
|
3201
|
+
SUBSCRIBER_VAT_ID_MISSING: "Der Vertragspartner hat keine Umsatzsteuer-Identifikationsnummer, die sich pr\xFCfen lie\xDFe.",
|
|
2800
3202
|
SUBSCRIBER_IDENTITY_NOT_A_CONTACT: "{field} geh\xF6rt zur rechtlichen Identit\xE4t des Vertragspartners und \xE4ndert sich nur als Korrektur mit Begr\xFCndung.",
|
|
2801
3203
|
SUBSCRIBER_CORRECTION_REASON_REQUIRED: "Eine Korrektur der rechtlichen Identit\xE4t braucht eine Begr\xFCndung.",
|
|
2802
3204
|
SUBSCRIBER_CORRECTION_ACTOR_REQUIRED: "Eine Korrektur der rechtlichen Identit\xE4t muss nennen, wer sie vornimmt.",
|
|
2803
3205
|
SUBSCRIBER_CORRECTION_CHANGES_NOTHING: "Die Korrektur \xE4ndert nichts: Jeder genannte Wert ist bereits erfasst.",
|
|
2804
3206
|
SUBSCRIBER_TAKEOVER_IS_A_TRANSFER: "\xDCbernimmt eine andere Rechtsperson, ist das eine \xDCbertragung und keine Korrektur; sie l\xE4sst sich nicht als \xC4nderung erfassen.",
|
|
3207
|
+
SUBSCRIBER_BUSINESS_STATUS_NOT_A_CONTACT: "Ob der Vertragspartner ein Unternehmen ist, geh\xF6rt zu seiner steuerlichen Herkunft und \xE4ndert sich nur als erfasste \xC4nderung, die nennt, wer sie vornimmt.",
|
|
3208
|
+
SUBSCRIBER_CHANGE_ACTOR_REQUIRED: "Eine \xC4nderung der Angaben des Vertragspartners muss nennen, wer sie vornimmt.",
|
|
2805
3209
|
// ── registration ──
|
|
2806
3210
|
PENDING_REGISTRATION_NOT_FOUND: "Diese Registrierung konnten wir nicht finden. Vielleicht ist sie bereits abgeschlossen oder verworfen.",
|
|
2807
3211
|
PENDING_REGISTRATION_EXPIRED: "Diese Registrierung ist abgelaufen. Bitte fange noch einmal von vorn an.",
|
|
@@ -2835,7 +3239,11 @@ var ERROR_MESSAGES_DE = {
|
|
|
2835
3239
|
MAINTENANCE_WINDOW_END_NOT_AFTER_START: "Das Ende eines Wartungsfensters muss nach seinem Beginn liegen.",
|
|
2836
3240
|
MAINTENANCE_WINDOW_END_IN_PAST: "Das Ende eines Wartungsfensters darf nicht in der Vergangenheit liegen.",
|
|
2837
3241
|
MAINTENANCE_TIME_INVALID: "{field} muss Datum und Uhrzeit mit Zeitzone sein, etwa 2026-10-02T22:00+02:00.",
|
|
2838
|
-
MAINTENANCE_MESSAGE_TOO_LONG: "Die Nachricht darf h\xF6chstens {max} Zeichen lang sein."
|
|
3242
|
+
MAINTENANCE_MESSAGE_TOO_LONG: "Die Nachricht darf h\xF6chstens {max} Zeichen lang sein.",
|
|
3243
|
+
// ── tax ──
|
|
3244
|
+
TAX_TREATMENT_NOT_SUPPORTED: "Der Steueradapter {adapter} unterst\xFCtzt diesen Fall nicht: {reason}",
|
|
3245
|
+
TAX_VAT_ID_CHECK_NOT_COMPLETED: "Die Umsatzsteuer-Identifikationsnummer lie\xDF sich gerade nicht pr\xFCfen ({reason}). Bitte sp\xE4ter erneut versuchen.",
|
|
3246
|
+
TAX_VAT_ID_CHECK_NOT_AVAILABLE: "Diese Installation nennt keinen Steueradapter, darum wird keine Umsatzsteuer-Identifikationsnummer gepr\xFCft."
|
|
2839
3247
|
};
|
|
2840
3248
|
// Annotate the CommonJS export names for ESM import in node:
|
|
2841
3249
|
0 && (module.exports = {
|
|
@@ -2843,6 +3251,7 @@ var ERROR_MESSAGES_DE = {
|
|
|
2843
3251
|
AUTH_ERROR_CODES,
|
|
2844
3252
|
BILLING_ERROR_CODES,
|
|
2845
3253
|
BUNDLE_PRICE_LOOKUP_LIMIT,
|
|
3254
|
+
BUNDLE_VERSION_RETIREMENT_CAPABILITY,
|
|
2846
3255
|
CATALOGUE_KEYS,
|
|
2847
3256
|
CATALOG_ERROR_CODES,
|
|
2848
3257
|
CONTRACT_ERROR_CODES,
|
|
@@ -2883,7 +3292,15 @@ var ERROR_MESSAGES_DE = {
|
|
|
2883
3292
|
SETTINGS_ERROR_CODES,
|
|
2884
3293
|
SETUP_ERROR_CODES,
|
|
2885
3294
|
SUBSCRIBER_ACCOUNT_CAPABILITY,
|
|
3295
|
+
SUBSCRIBER_ATTENTION_CAPABILITY,
|
|
3296
|
+
SUBSCRIBER_ATTENTION_PAGE_SIZE,
|
|
3297
|
+
SUBSCRIBER_CORRECTION_CAPABILITY,
|
|
2886
3298
|
SUBSCRIBER_ERROR_CODES,
|
|
3299
|
+
SUBSCRIBER_INVOICE_ADDRESS_FIELDS,
|
|
3300
|
+
SUBSCRIBER_STANDING_CAPABILITY,
|
|
3301
|
+
SUBSCRIBER_TAX_ORIGIN_FIELDS,
|
|
3302
|
+
TAX_ERROR_CODES,
|
|
3303
|
+
TAX_TREATMENT_KINDS,
|
|
2887
3304
|
VERSION_RETIREMENT_CAPABILITY,
|
|
2888
3305
|
applyPromo,
|
|
2889
3306
|
assertPersistenceCapabilities,
|
|
@@ -2894,6 +3311,7 @@ var ERROR_MESSAGES_DE = {
|
|
|
2894
3311
|
bundleKeyTaken,
|
|
2895
3312
|
bundleStemDefaults,
|
|
2896
3313
|
canonicalJson,
|
|
3314
|
+
canonicalVatId,
|
|
2897
3315
|
catalogDraftExists,
|
|
2898
3316
|
catalogVersionAlreadyPublished,
|
|
2899
3317
|
catalogVersionGone,
|
|
@@ -2925,6 +3343,7 @@ var ERROR_MESSAGES_DE = {
|
|
|
2925
3343
|
isVersionEditable,
|
|
2926
3344
|
issuerIdentityOf,
|
|
2927
3345
|
keepOneRecommended,
|
|
3346
|
+
keepsVatIdCheck,
|
|
2928
3347
|
maintenanceRetryAfterSeconds,
|
|
2929
3348
|
maintenanceStatusOf,
|
|
2930
3349
|
maintenanceWindowStatusOf,
|
|
@@ -2971,7 +3390,11 @@ var ERROR_MESSAGES_DE = {
|
|
|
2971
3390
|
subscriptionContractGone,
|
|
2972
3391
|
subscriptionGone,
|
|
2973
3392
|
sumToCents,
|
|
3393
|
+
taxOriginOf,
|
|
3394
|
+
taxOriginWrite,
|
|
3395
|
+
taxTreatmentToJson,
|
|
2974
3396
|
toBundleStemRow,
|
|
3397
|
+
toBundleVersionRetirementRecord,
|
|
2975
3398
|
toCents,
|
|
2976
3399
|
toContractLineItemRecord,
|
|
2977
3400
|
toDecimalString,
|
|
@@ -2983,10 +3406,15 @@ var ERROR_MESSAGES_DE = {
|
|
|
2983
3406
|
toSubscriberCorrectionRecord,
|
|
2984
3407
|
toSubscriberPaymentMethodRecord,
|
|
2985
3408
|
toSubscriberRecord,
|
|
3409
|
+
toSubscriberTaxOriginChangeRecord,
|
|
3410
|
+
toSubscriberVatIdCheckRecord,
|
|
2986
3411
|
toSubscriptionBundleRecord,
|
|
2987
3412
|
toSubscriptionContractRecord,
|
|
2988
3413
|
toSubscriptionNoticeRecord,
|
|
3414
|
+
toTaxOriginValues,
|
|
3415
|
+
toTaxTreatment,
|
|
2989
3416
|
toVersionRetirementRecord,
|
|
3417
|
+
vatIdCheckFromStore,
|
|
2990
3418
|
versionOnSale,
|
|
2991
3419
|
versionOnSaleOrNext,
|
|
2992
3420
|
versionSale
|