@saasicat/nest 0.4.0 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. package/dist/admin/index.cjs +3 -8
  2. package/dist/admin/index.d.cts +5 -33
  3. package/dist/admin/index.d.ts +5 -33
  4. package/dist/admin/index.js +2 -2
  5. package/dist/{admin-manifest.config-DxTfZ8-L.d.cts → admin-manifest.config-DyrQNT7M.d.cts} +1 -1
  6. package/dist/{admin-manifest.config-DxTfZ8-L.d.ts → admin-manifest.config-DyrQNT7M.d.ts} +1 -1
  7. package/dist/admin-manifest.service-Cp6uwvmt.d.cts +33 -0
  8. package/dist/admin-manifest.service-UGgzR1x-.d.ts +33 -0
  9. package/dist/{aggregation-DGCyoN5d.d.ts → aggregation-BibpEO0t.d.ts} +6 -59
  10. package/dist/{aggregation-Bt1i_whS.d.cts → aggregation-CfI0bOsQ.d.cts} +6 -59
  11. package/dist/billing/index.cjs +18 -106
  12. package/dist/billing/index.d.cts +8 -30
  13. package/dist/billing/index.d.ts +8 -30
  14. package/dist/billing/index.js +12 -14
  15. package/dist/catalog/index.cjs +1160 -1985
  16. package/dist/catalog/index.d.cts +9 -124
  17. package/dist/catalog/index.d.ts +9 -124
  18. package/dist/catalog/index.js +5 -27
  19. package/dist/checkout-offer/index.js +2 -2
  20. package/dist/{chunk-2VNZYRDV.js → chunk-52UTQRD3.js} +1 -1
  21. package/dist/{chunk-FN65XZKH.js → chunk-5DDCSGZC.js} +1110 -1923
  22. package/dist/{chunk-VHEHZMHB.js → chunk-BTL66TR6.js} +22 -75
  23. package/dist/{chunk-XSGU2Y2O.js → chunk-CK54YKVK.js} +2 -33
  24. package/dist/{chunk-SG34XT7J.js → chunk-FSGBRFLX.js} +18 -10
  25. package/dist/{chunk-SYEVGPFC.js → chunk-K3OPNVFR.js} +1 -1
  26. package/dist/{chunk-XCZ3TTFK.js → chunk-N3WANKSA.js} +0 -2
  27. package/dist/{chunk-K42EQPBB.js → chunk-ND7OOKOG.js} +18 -51
  28. package/dist/{chunk-MV6LW5UB.js → chunk-R2QOSVAA.js} +2 -2
  29. package/dist/{chunk-YNEW3L63.js → chunk-SD3TT2BR.js} +1 -1
  30. package/dist/{chunk-P6MYZMXQ.js → chunk-U6HT27J7.js} +3 -8
  31. package/dist/{chunk-7MLGHWKO.js → chunk-WKVBNTYC.js} +2 -0
  32. package/dist/{chunk-ZL4LLE2Z.js → chunk-ZLUGQE5D.js} +1 -1
  33. package/dist/discovery/index.js +4 -4
  34. package/dist/{enforce-quota.interceptor-3HmbeHTM.d.ts → enforce-quota.interceptor-Dj1Kusr5.d.ts} +9 -4
  35. package/dist/{enforce-quota.interceptor-HmdZFg41.d.cts → enforce-quota.interceptor-cv7r80VM.d.cts} +9 -4
  36. package/dist/entitlement/index.cjs +13 -46
  37. package/dist/entitlement/index.d.cts +4 -3
  38. package/dist/entitlement/index.d.ts +4 -3
  39. package/dist/entitlement/index.js +7 -9
  40. package/dist/index.cjs +1348 -2300
  41. package/dist/index.d.cts +8 -7
  42. package/dist/index.d.ts +8 -7
  43. package/dist/index.js +85 -113
  44. package/dist/platform/index.cjs +28 -54
  45. package/dist/platform/index.d.cts +4 -3
  46. package/dist/platform/index.d.ts +4 -3
  47. package/dist/platform/index.js +10 -7
  48. package/dist/promo/index.cjs +2 -2
  49. package/dist/promo/index.js +3 -3
  50. package/dist/registration/index.cjs +2 -34
  51. package/dist/registration/index.d.cts +3 -21
  52. package/dist/registration/index.d.ts +3 -21
  53. package/dist/registration/index.js +1 -3
  54. package/dist/testing/index.cjs +26 -255
  55. package/dist/testing/index.d.cts +5 -37
  56. package/dist/testing/index.d.ts +5 -37
  57. package/dist/testing/index.js +7 -207
  58. package/package.json +3 -3
@@ -33,18 +33,13 @@ var catalog_exports = {};
33
33
  __export(catalog_exports, {
34
34
  ADVISORY_STRICT_MODE_CODES: () => ADVISORY_STRICT_MODE_CODES,
35
35
  BUNDLE_REPOSITORY_TOKEN: () => BUNDLE_REPOSITORY_TOKEN,
36
- BUSINESS_TYPE_REPOSITORY_TOKEN: () => BUSINESS_TYPE_REPOSITORY_TOKEN,
37
36
  BundlesService: () => BundlesService,
38
- BusinessTypeBundleInputDto: () => BusinessTypeBundleInputDto,
39
- BusinessTypesService: () => BusinessTypesService,
40
37
  CATALOG_ENTRY_REPOSITORY_TOKEN: () => CATALOG_ENTRY_REPOSITORY_TOKEN,
41
38
  CATALOG_SERVICE_CONFIG_TOKEN: () => CATALOG_SERVICE_CONFIG_TOKEN,
42
39
  CatalogEntriesService: () => CatalogEntriesService,
43
40
  CatalogModule: () => CatalogModule,
44
41
  CreateBundleDto: () => CreateBundleDto,
45
42
  CreateBundleVersionDraftDto: () => CreateBundleVersionDraftDto,
46
- CreateBusinessTypeDto: () => CreateBusinessTypeDto,
47
- CreateBusinessTypeVersionDraftDto: () => CreateBusinessTypeVersionDraftDto,
48
43
  CreateMarketingProjectionDto: () => CreateMarketingProjectionDto,
49
44
  CreatePlanDto: () => CreatePlanDto,
50
45
  CreatePlanVersionDraftDto: () => CreatePlanVersionDraftDto,
@@ -64,14 +59,11 @@ __export(catalog_exports, {
64
59
  PromotionsService: () => PromotionsService,
65
60
  PublicMarketingCatalogService: () => PublicMarketingCatalogService,
66
61
  PublishBundleVersionDto: () => PublishBundleVersionDto,
67
- PublishBusinessTypeVersionDto: () => PublishBusinessTypeVersionDto,
68
62
  PublishPlanVersionDto: () => PublishPlanVersionDto,
69
63
  ReviewCatalogEntryDto: () => ReviewCatalogEntryDto,
70
64
  SyncDiscoveryDto: () => SyncDiscoveryDto,
71
65
  UpdateBundleDto: () => UpdateBundleDto,
72
66
  UpdateBundleVersionDraftDto: () => UpdateBundleVersionDraftDto,
73
- UpdateBusinessTypeDto: () => UpdateBusinessTypeDto,
74
- UpdateBusinessTypeVersionDraftDto: () => UpdateBusinessTypeVersionDraftDto,
75
67
  UpdateCatalogEntryI18nDto: () => UpdateCatalogEntryI18nDto,
76
68
  UpdateMarketingProjectionDto: () => UpdateMarketingProjectionDto,
77
69
  UpdateMarketingSettingsDto: () => UpdateMarketingSettingsDto,
@@ -81,8 +73,6 @@ __export(catalog_exports, {
81
73
  blockingStrictModeWarnings: () => blockingStrictModeWarnings,
82
74
  buildBundleVersionsController: () => buildBundleVersionsController,
83
75
  buildBundlesController: () => buildBundlesController,
84
- buildBusinessTypeVersionsController: () => buildBusinessTypeVersionsController,
85
- buildBusinessTypesController: () => buildBusinessTypesController,
86
76
  buildCatalogEntriesController: () => buildCatalogEntriesController,
87
77
  buildMarketingProjectionsController: () => buildMarketingProjectionsController,
88
78
  buildMarketingSettingsController: () => buildMarketingSettingsController,
@@ -100,7 +90,6 @@ __export(catalog_exports, {
100
90
  runSeedGateFromFile: () => runSeedGateFromFile,
101
91
  seedGateExitCode: () => seedGateExitCode,
102
92
  validateBundleDraft: () => validateBundleDraft,
103
- validateBusinessTypeDraft: () => validateBusinessTypeDraft,
104
93
  validatePlanDraft: () => validatePlanDraft,
105
94
  validateSeedAgainstSnapshot: () => validateSeedAgainstSnapshot
106
95
  });
@@ -436,7 +425,6 @@ var SUBSCRIPTION_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol.for("saas-platform/Su
436
425
  // src/catalog/tokens.ts
437
426
  var PLAN_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol("PLAN_REPOSITORY");
438
427
  var BUNDLE_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol("BUNDLE_REPOSITORY");
439
- var BUSINESS_TYPE_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol("BUSINESS_TYPE_REPOSITORY");
440
428
  var MARKETING_PROJECTION_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol("MARKETING_PROJECTION_REPOSITORY");
441
429
  var CATALOG_ENTRY_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol("CATALOG_ENTRY_REPOSITORY");
442
430
  var PROMOTION_REPOSITORY_TOKEN = /* @__PURE__ */ Symbol("PROMOTION_REPOSITORY");
@@ -551,58 +539,6 @@ function validateBundleDraft(draft, snapshot, knownPlanKeys = null, marketedOnly
551
539
  return warnings;
552
540
  }
553
541
  __name(validateBundleDraft, "validateBundleDraft");
554
- function validateBusinessTypeDraft(draft, bundles, snapshot, approved = null) {
555
- const warnings = [];
556
- const featureToBundleKeys = /* @__PURE__ */ new Map();
557
- for (const bundle of bundles) {
558
- for (const feature of bundle.features) {
559
- const list = featureToBundleKeys.get(feature) ?? [];
560
- list.push(bundle.bundleKey);
561
- featureToBundleKeys.set(feature, list);
562
- }
563
- }
564
- for (const [feature, bundleKeys] of featureToBundleKeys) {
565
- if (bundleKeys.length > 1) {
566
- warnings.push({
567
- code: "BUNDLE_DISJOINTNESS",
568
- message: `Feature '${feature}' wird von mehreren Bundles aktiviert (${bundleKeys.join(", ")}). GESCHAEFTSTYP_SPEC \xA76.3 verlangt Disjointness pro Gesch\xE4ftstyp \u2014 entferne das Feature aus allen Bundles bis auf eines.`,
569
- field: "bundles",
570
- value: feature
571
- });
572
- }
573
- }
574
- for (const bundle of bundles) {
575
- const whitelist = bundle.compatibility?.businessTypeKeys;
576
- if (whitelist && whitelist.length > 0 && !whitelist.includes(draft.businessTypeKey)) {
577
- warnings.push({
578
- code: "BUNDLE_COMPATIBILITY",
579
- message: `Bundle '${bundle.bundleKey}' hat eine Compatibility-Whitelist [${whitelist.join(", ")}], in der '${draft.businessTypeKey}' nicht enthalten ist. Override per Audit-Marker m\xF6glich, aber riskant.`,
580
- field: `bundles[${bundle.bundleKey}].compatibility`,
581
- value: bundle.bundleKey
582
- });
583
- }
584
- }
585
- const knownQuotas = new Set(snapshot.quotas.map((q) => q.quotaKey));
586
- for (const quotaKey of Object.keys(draft.quotaOverrides ?? {})) {
587
- if (!knownQuotas.has(quotaKey)) {
588
- warnings.push({
589
- code: "QUOTA_MISSING",
590
- message: `Quota-Override '${quotaKey}' existiert nicht im Discovery-Snapshot.`,
591
- field: `quotaOverrides.${quotaKey}`,
592
- value: quotaKey
593
- });
594
- } else if (approved && !approved.quotas.has(quotaKey)) {
595
- warnings.push({
596
- code: "QUOTA_NOT_APPROVED",
597
- message: `Quota-Override '${quotaKey}' ist nicht freigegeben (Status != approved). Nur freigegebene Quotas sind verkaufbar \u2014 im Discovery-Review freigeben (#20).`,
598
- field: `quotaOverrides.${quotaKey}`,
599
- value: quotaKey
600
- });
601
- }
602
- }
603
- return warnings;
604
- }
605
- __name(validateBusinessTypeDraft, "validateBusinessTypeDraft");
606
542
  function validatePlanDraft(draft, snapshot, marketedOnlyFeatures = /* @__PURE__ */ new Set(), approved = null) {
607
543
  const warnings = [];
608
544
  const knownFeatures = new Set(snapshot.features.map((f) => f.featureKey));
@@ -1114,9 +1050,8 @@ BundlesService = _ts_decorate2([
1114
1050
  ])
1115
1051
  ], BundlesService);
1116
1052
 
1117
- // src/catalog/business-types.service.ts
1053
+ // src/catalog/marketing-projections.service.ts
1118
1054
  var import_common3 = require("@nestjs/common");
1119
- var import_types3 = require("@saasicat/types");
1120
1055
  function _ts_decorate3(decorators, target, key, desc) {
1121
1056
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1122
1057
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
@@ -1134,276 +1069,6 @@ function _ts_param3(paramIndex, decorator) {
1134
1069
  };
1135
1070
  }
1136
1071
  __name(_ts_param3, "_ts_param");
1137
- var BusinessTypesService = class {
1138
- static {
1139
- __name(this, "BusinessTypesService");
1140
- }
1141
- repo;
1142
- bundleRepo;
1143
- snapshot;
1144
- scanner;
1145
- catalogEntries;
1146
- mode;
1147
- constructor(repo, bundleRepo, snapshot = null, config = {}, scanner = null, catalogEntries = null) {
1148
- this.repo = repo;
1149
- this.bundleRepo = bundleRepo;
1150
- this.snapshot = snapshot;
1151
- this.scanner = scanner;
1152
- this.catalogEntries = catalogEntries;
1153
- this.mode = config.strictModeCheckMode ?? "blocking";
1154
- }
1155
- // =========================================================================
1156
- // Master operations
1157
- // =========================================================================
1158
- listBusinessTypes(projectKey) {
1159
- return this.repo.list({
1160
- projectKey,
1161
- excludeDeleted: true
1162
- });
1163
- }
1164
- async getBusinessType(businessTypeId) {
1165
- const businessType = await this.repo.findById(businessTypeId);
1166
- if (!businessType) {
1167
- throw new import_common3.NotFoundException(`BusinessType '${businessTypeId}' nicht gefunden`);
1168
- }
1169
- const versions = await this.repo.listVersions(businessTypeId);
1170
- return {
1171
- businessType,
1172
- versions
1173
- };
1174
- }
1175
- async createBusinessType(data) {
1176
- const existing = await this.repo.findByKey(data.projectKey, data.businessTypeKey);
1177
- if (existing) {
1178
- throw new import_common3.UnprocessableEntityException(`BusinessType '${data.businessTypeKey}' existiert bereits in Projekt '${data.projectKey}'`);
1179
- }
1180
- return this.repo.create(data);
1181
- }
1182
- async updateBusinessType(businessTypeId, data) {
1183
- const existing = await this.repo.findById(businessTypeId);
1184
- if (!existing) {
1185
- throw new import_common3.NotFoundException(`BusinessType '${businessTypeId}' nicht gefunden`);
1186
- }
1187
- return this.repo.update(businessTypeId, data);
1188
- }
1189
- async softDeleteBusinessType(businessTypeId) {
1190
- const existing = await this.repo.findById(businessTypeId);
1191
- if (!existing) {
1192
- throw new import_common3.NotFoundException(`BusinessType '${businessTypeId}' nicht gefunden`);
1193
- }
1194
- if (existing.deletedAt !== null) return;
1195
- await this.repo.softDelete(businessTypeId);
1196
- }
1197
- // =========================================================================
1198
- // Version operations
1199
- // =========================================================================
1200
- listBusinessTypeVersions(businessTypeId) {
1201
- return this.repo.listVersions(businessTypeId);
1202
- }
1203
- async getBusinessTypeVersion(versionId) {
1204
- const version = await this.repo.findVersionById(versionId);
1205
- if (!version) {
1206
- throw new import_common3.NotFoundException(`BusinessTypeVersion '${versionId}' nicht gefunden`);
1207
- }
1208
- return version;
1209
- }
1210
- async createBusinessTypeDraft(data) {
1211
- const businessType = await this.repo.findById(data.businessTypeId);
1212
- if (!businessType) {
1213
- throw new import_common3.NotFoundException(`BusinessType '${data.businessTypeId}' nicht gefunden`);
1214
- }
1215
- const existingDraft = await this.repo.findCurrentDraft(data.businessTypeId);
1216
- if (existingDraft) {
1217
- throw new import_common3.UnprocessableEntityException(`BusinessType '${businessType.businessTypeKey}' hat bereits eine Draft-Version v${existingDraft.version}; bitte erst publishen oder verwerfen`);
1218
- }
1219
- if (!data.bundles || data.bundles.length === 0) {
1220
- throw new import_common3.UnprocessableEntityException("BusinessTypeVersion muss mindestens einen Bundle referenzieren (siehe GESCHAEFTSTYP_SPEC \xA710).");
1221
- }
1222
- const bundleVersions = await this.loadAndAssertBundles(data.bundles.map((b) => b.bundleVersionId));
1223
- if (data.baseVersionId === void 0) {
1224
- const latestLive = await this.repo.findLatestLive(data.businessTypeId);
1225
- data = {
1226
- ...data,
1227
- baseVersionId: latestLive?.id ?? null
1228
- };
1229
- }
1230
- const warnings = await this.runStrictCheck({
1231
- businessTypeKey: businessType.businessTypeKey,
1232
- quotaOverrides: data.quotaOverrides ?? {}
1233
- }, bundleVersions);
1234
- this.gateOrPass(warnings);
1235
- const businessTypeVersion = await this.repo.createDraft(data);
1236
- return {
1237
- businessTypeVersion,
1238
- warnings
1239
- };
1240
- }
1241
- async updateBusinessTypeDraft(versionId, data) {
1242
- const existing = await this.repo.findVersionById(versionId);
1243
- if (!existing) {
1244
- throw new import_common3.NotFoundException(`BusinessTypeVersion '${versionId}' nicht gefunden`);
1245
- }
1246
- if (existing.publishedAt !== null) {
1247
- throw new import_common3.UnprocessableEntityException(`BusinessTypeVersion '${versionId}' ist bereits published und kann nicht mehr ge\xE4ndert werden`);
1248
- }
1249
- const businessType = await this.repo.findById(existing.businessTypeId);
1250
- if (!businessType) {
1251
- throw new import_common3.NotFoundException(`BusinessType '${existing.businessTypeId}' nicht gefunden (referentielle Inkonsistenz)`);
1252
- }
1253
- const targetBundles = data.bundles ?? existing.bundles.map((b) => ({
1254
- bundleVersionId: b.bundleVersionId,
1255
- sortOrder: b.sortOrder
1256
- }));
1257
- if (targetBundles.length === 0) {
1258
- throw new import_common3.UnprocessableEntityException("BusinessTypeVersion muss mindestens einen Bundle referenzieren.");
1259
- }
1260
- const bundleVersions = await this.loadAndAssertBundles(targetBundles.map((b) => b.bundleVersionId));
1261
- const warnings = await this.runStrictCheck({
1262
- businessTypeKey: businessType.businessTypeKey,
1263
- quotaOverrides: data.quotaOverrides ?? existing.quotaOverrides
1264
- }, bundleVersions);
1265
- this.gateOrPass(warnings);
1266
- const businessTypeVersion = await this.repo.updateDraft(versionId, data);
1267
- return {
1268
- businessTypeVersion,
1269
- warnings
1270
- };
1271
- }
1272
- async publishBusinessTypeVersion(versionId, publishMeta) {
1273
- const draft = await this.repo.findVersionById(versionId);
1274
- if (!draft) {
1275
- throw new import_common3.NotFoundException(`BusinessTypeVersion '${versionId}' nicht gefunden`);
1276
- }
1277
- if (draft.publishedAt !== null) {
1278
- throw new import_common3.UnprocessableEntityException(`BusinessTypeVersion '${versionId}' ist bereits published`);
1279
- }
1280
- const businessType = await this.repo.findById(draft.businessTypeId);
1281
- if (!businessType) {
1282
- throw new import_common3.NotFoundException(`BusinessType '${draft.businessTypeId}' nicht gefunden`);
1283
- }
1284
- const bundleVersions = await this.loadAndAssertBundles(draft.bundles.map((b) => b.bundleVersionId));
1285
- const warnings = await this.runStrictCheck({
1286
- businessTypeKey: businessType.businessTypeKey,
1287
- quotaOverrides: draft.quotaOverrides
1288
- }, bundleVersions);
1289
- this.gateOrPass(warnings);
1290
- const previous = await this.repo.findLatestLive(draft.businessTypeId);
1291
- const diff = previous ? (0, import_types3.classifyBusinessTypeVersionDiff)(previous, draft) : {
1292
- changes: [],
1293
- nonRegressive: true
1294
- };
1295
- if (!diff.nonRegressive && !publishMeta.forceRegressive) {
1296
- throw new import_common3.UnprocessableEntityException({
1297
- code: "BUSINESS_TYPE_VERSION_REGRESSION",
1298
- message: "Diese BusinessTypeVersion ist regressiv (Bundle entfernt / Quota-Override gesenkt / Preis erh\xF6ht). Publishen erfordert explizites `forceRegressive: true` (UI-Best\xE4tigungsmodal mit MFA).",
1299
- changes: diff.changes
1300
- });
1301
- }
1302
- const businessTypeVersion = await this.repo.publishDraft(versionId, {
1303
- publishedByUserId: publishMeta.publishedByUserId,
1304
- publishedChanges: diff.changes,
1305
- nonRegressive: diff.nonRegressive
1306
- });
1307
- return {
1308
- businessTypeVersion,
1309
- warnings
1310
- };
1311
- }
1312
- // =========================================================================
1313
- // Helper
1314
- // =========================================================================
1315
- /**
1316
- * Loads the referenced BundleVersions and verifies that all exist
1317
- * and are published (live or superseded — both allowed, because
1318
- * BusinessTypeBundle holds the concrete version). Throws NotFound for
1319
- * missing ones, UnprocessableEntity for non-published ones.
1320
- */
1321
- async loadAndAssertBundles(bundleVersionIds) {
1322
- const result = [];
1323
- for (const id of bundleVersionIds) {
1324
- const bv = await this.bundleRepo.findVersionById(id);
1325
- if (!bv) {
1326
- throw new import_common3.UnprocessableEntityException(`BundleVersion '${id}' nicht gefunden \u2014 BusinessTypeVersion kann nur published BundleVersions referenzieren`);
1327
- }
1328
- if (bv.publishedAt === null) {
1329
- throw new import_common3.UnprocessableEntityException(`BundleVersion '${id}' ist Draft \u2014 BusinessTypeVersion-Komposition braucht published Versionen`);
1330
- }
1331
- result.push(bv);
1332
- }
1333
- return result;
1334
- }
1335
- async runStrictCheck(draft, bundleVersions) {
1336
- const snapshot = resolveDiscoverySnapshot(this.snapshot, this.scanner);
1337
- if (!snapshot) {
1338
- return validateBusinessTypeDraft(draft, bundleVersions, {
1339
- schemaVersion: 1,
1340
- scannedAt: (/* @__PURE__ */ new Date()).toISOString(),
1341
- app: {
1342
- key: "unknown",
1343
- version: "0.0.0"
1344
- },
1345
- capabilities: [],
1346
- features: [],
1347
- quotas: [],
1348
- hash: "sha256-empty"
1349
- }).filter((w) => w.code !== "QUOTA_MISSING");
1350
- }
1351
- const approved = await loadApprovedCatalogKeys(this.catalogEntries, snapshot.app.key);
1352
- return validateBusinessTypeDraft(draft, bundleVersions, snapshot, approved);
1353
- }
1354
- gateOrPass(warnings) {
1355
- if (warnings.length === 0) return;
1356
- if (this.mode === "blocking") {
1357
- throw new import_common3.UnprocessableEntityException({
1358
- code: "STRICT_MODE_VIOLATIONS",
1359
- message: "Strict-Mode-Check hat Drift gegen den Discovery-Snapshot gefunden.",
1360
- warnings
1361
- });
1362
- }
1363
- }
1364
- };
1365
- BusinessTypesService = _ts_decorate3([
1366
- (0, import_common3.Injectable)(),
1367
- _ts_param3(0, (0, import_common3.Inject)(BUSINESS_TYPE_REPOSITORY_TOKEN)),
1368
- _ts_param3(1, (0, import_common3.Inject)(BUNDLE_REPOSITORY_TOKEN)),
1369
- _ts_param3(2, (0, import_common3.Optional)()),
1370
- _ts_param3(2, (0, import_common3.Inject)(DISCOVERY_SNAPSHOT_TOKEN)),
1371
- _ts_param3(3, (0, import_common3.Optional)()),
1372
- _ts_param3(3, (0, import_common3.Inject)(CATALOG_SERVICE_CONFIG_TOKEN)),
1373
- _ts_param3(4, (0, import_common3.Optional)()),
1374
- _ts_param3(4, (0, import_common3.Inject)(DiscoveryScanner)),
1375
- _ts_param3(5, (0, import_common3.Optional)()),
1376
- _ts_param3(5, (0, import_common3.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
1377
- _ts_metadata3("design:type", Function),
1378
- _ts_metadata3("design:paramtypes", [
1379
- typeof BusinessTypeRepository === "undefined" ? Object : BusinessTypeRepository,
1380
- typeof BundleRepository === "undefined" ? Object : BundleRepository,
1381
- Object,
1382
- typeof CatalogServiceConfig === "undefined" ? Object : CatalogServiceConfig,
1383
- Object,
1384
- Object
1385
- ])
1386
- ], BusinessTypesService);
1387
-
1388
- // src/catalog/marketing-projections.service.ts
1389
- var import_common4 = require("@nestjs/common");
1390
- function _ts_decorate4(decorators, target, key, desc) {
1391
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1392
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1393
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
1394
- return c > 3 && r && Object.defineProperty(target, key, r), r;
1395
- }
1396
- __name(_ts_decorate4, "_ts_decorate");
1397
- function _ts_metadata4(k, v) {
1398
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
1399
- }
1400
- __name(_ts_metadata4, "_ts_metadata");
1401
- function _ts_param4(paramIndex, decorator) {
1402
- return function(target, key) {
1403
- decorator(target, key, paramIndex);
1404
- };
1405
- }
1406
- __name(_ts_param4, "_ts_param");
1407
1072
  var MarketingProjectionsService = class {
1408
1073
  static {
1409
1074
  __name(this, "MarketingProjectionsService");
@@ -1418,7 +1083,7 @@ var MarketingProjectionsService = class {
1418
1083
  async getById(id) {
1419
1084
  const row = await this.repo.findById(id);
1420
1085
  if (!row) {
1421
- throw new import_common4.NotFoundException(`MarketingProjection '${id}' nicht gefunden`);
1086
+ throw new import_common3.NotFoundException(`MarketingProjection '${id}' nicht gefunden`);
1422
1087
  }
1423
1088
  return row;
1424
1089
  }
@@ -1426,7 +1091,7 @@ var MarketingProjectionsService = class {
1426
1091
  const locale = data.locale ?? "de";
1427
1092
  const existing = await this.repo.findByTarget(data.targetType, data.targetVersionId, locale);
1428
1093
  if (existing) {
1429
- throw new import_common4.ConflictException(`MarketingProjection f\xFCr ${data.targetType}/${data.targetVersionId}/${locale} existiert bereits \u2014 nutze PATCH zum Editieren`);
1094
+ throw new import_common3.ConflictException(`MarketingProjection f\xFCr ${data.targetType}/${data.targetVersionId}/${locale} existiert bereits \u2014 nutze PATCH zum Editieren`);
1430
1095
  }
1431
1096
  return this.repo.create({
1432
1097
  ...data,
@@ -1436,29 +1101,29 @@ var MarketingProjectionsService = class {
1436
1101
  async update(id, data) {
1437
1102
  const existing = await this.repo.findById(id);
1438
1103
  if (!existing) {
1439
- throw new import_common4.NotFoundException(`MarketingProjection '${id}' nicht gefunden`);
1104
+ throw new import_common3.NotFoundException(`MarketingProjection '${id}' nicht gefunden`);
1440
1105
  }
1441
1106
  return this.repo.update(id, data);
1442
1107
  }
1443
1108
  async delete(id) {
1444
1109
  const existing = await this.repo.findById(id);
1445
1110
  if (!existing) {
1446
- throw new import_common4.NotFoundException(`MarketingProjection '${id}' nicht gefunden`);
1111
+ throw new import_common3.NotFoundException(`MarketingProjection '${id}' nicht gefunden`);
1447
1112
  }
1448
1113
  await this.repo.delete(id);
1449
1114
  }
1450
1115
  };
1451
- MarketingProjectionsService = _ts_decorate4([
1452
- (0, import_common4.Injectable)(),
1453
- _ts_param4(0, (0, import_common4.Inject)(MARKETING_PROJECTION_REPOSITORY_TOKEN)),
1454
- _ts_metadata4("design:type", Function),
1455
- _ts_metadata4("design:paramtypes", [
1116
+ MarketingProjectionsService = _ts_decorate3([
1117
+ (0, import_common3.Injectable)(),
1118
+ _ts_param3(0, (0, import_common3.Inject)(MARKETING_PROJECTION_REPOSITORY_TOKEN)),
1119
+ _ts_metadata3("design:type", Function),
1120
+ _ts_metadata3("design:paramtypes", [
1456
1121
  typeof MarketingProjectionRepository === "undefined" ? Object : MarketingProjectionRepository
1457
1122
  ])
1458
1123
  ], MarketingProjectionsService);
1459
1124
 
1460
1125
  // src/catalog/catalog-entries.service.ts
1461
- var import_common5 = require("@nestjs/common");
1126
+ var import_common4 = require("@nestjs/common");
1462
1127
 
1463
1128
  // src/catalog/approval-signature.ts
1464
1129
  function featureApprovalSignature(featureKey, snapshot) {
@@ -1483,23 +1148,23 @@ function keyListSegment(name, keys) {
1483
1148
  __name(keyListSegment, "keyListSegment");
1484
1149
 
1485
1150
  // src/catalog/catalog-entries.service.ts
1486
- function _ts_decorate5(decorators, target, key, desc) {
1151
+ function _ts_decorate4(decorators, target, key, desc) {
1487
1152
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1488
1153
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1489
1154
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
1490
1155
  return c > 3 && r && Object.defineProperty(target, key, r), r;
1491
1156
  }
1492
- __name(_ts_decorate5, "_ts_decorate");
1493
- function _ts_metadata5(k, v) {
1157
+ __name(_ts_decorate4, "_ts_decorate");
1158
+ function _ts_metadata4(k, v) {
1494
1159
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
1495
1160
  }
1496
- __name(_ts_metadata5, "_ts_metadata");
1497
- function _ts_param5(paramIndex, decorator) {
1161
+ __name(_ts_metadata4, "_ts_metadata");
1162
+ function _ts_param4(paramIndex, decorator) {
1498
1163
  return function(target, key) {
1499
1164
  decorator(target, key, paramIndex);
1500
1165
  };
1501
1166
  }
1502
- __name(_ts_param5, "_ts_param");
1167
+ __name(_ts_param4, "_ts_param");
1503
1168
  var REVIEW_TRANSITIONS = {
1504
1169
  pending: [
1505
1170
  "approved",
@@ -1551,7 +1216,7 @@ var CatalogEntriesService = class _CatalogEntriesService {
1551
1216
  snapshot;
1552
1217
  scanner;
1553
1218
  featureUiRegistry;
1554
- logger = new import_common5.Logger(_CatalogEntriesService.name);
1219
+ logger = new import_common4.Logger(_CatalogEntriesService.name);
1555
1220
  autoSyncAtBoot;
1556
1221
  constructor(repo, snapshot = null, config = {}, scanner = null, featureUiRegistry = null) {
1557
1222
  this.repo = repo;
@@ -1608,7 +1273,7 @@ var CatalogEntriesService = class _CatalogEntriesService {
1608
1273
  async reviewFeature(projectKey, featureKey, data, reviewedBy) {
1609
1274
  const existing = await this.repo.findFeature(projectKey, featureKey);
1610
1275
  if (!existing) {
1611
- throw new import_common5.NotFoundException(`Feature '${featureKey}' in Projekt '${projectKey}' nicht gefunden`);
1276
+ throw new import_common4.NotFoundException(`Feature '${featureKey}' in Projekt '${projectKey}' nicht gefunden`);
1612
1277
  }
1613
1278
  return this.repo.setFeatureReview(projectKey, featureKey, this.resolveReviewUpdate(existing, data.discoveryStatus, reviewedBy, (snapshot) => featureApprovalSignature(featureKey, snapshot)));
1614
1279
  }
@@ -1616,24 +1281,24 @@ var CatalogEntriesService = class _CatalogEntriesService {
1616
1281
  async reviewQuota(projectKey, quotaKey, data, reviewedBy) {
1617
1282
  const existing = await this.repo.findQuota(projectKey, quotaKey);
1618
1283
  if (!existing) {
1619
- throw new import_common5.NotFoundException(`Quota '${quotaKey}' in Projekt '${projectKey}' nicht gefunden`);
1284
+ throw new import_common4.NotFoundException(`Quota '${quotaKey}' in Projekt '${projectKey}' nicht gefunden`);
1620
1285
  }
1621
1286
  return this.repo.setQuotaReview(projectKey, quotaKey, this.resolveReviewUpdate(existing, data.discoveryStatus, reviewedBy, (snapshot) => {
1622
1287
  const discovered = snapshot.quotas.find((q) => q.quotaKey === quotaKey);
1623
1288
  if (!discovered) {
1624
- throw new import_common5.UnprocessableEntityException(`Quota '${quotaKey}' ist nicht im Discovery-Snapshot \u2014 eine nicht im Code deklarierte Quota kann nicht freigegeben werden`);
1289
+ throw new import_common4.UnprocessableEntityException(`Quota '${quotaKey}' ist nicht im Discovery-Snapshot \u2014 eine nicht im Code deklarierte Quota kann nicht freigegeben werden`);
1625
1290
  }
1626
1291
  return quotaApprovalSignature(discovered);
1627
1292
  }));
1628
1293
  }
1629
1294
  resolveReviewUpdate(existing, target, reviewedBy, signatureOf) {
1630
1295
  if (!REVIEW_TRANSITIONS[existing.discoveryStatus].includes(target)) {
1631
- throw new import_common5.UnprocessableEntityException(`\xDCbergang '${existing.discoveryStatus}' \u2192 '${target}' ist nicht erlaubt`);
1296
+ throw new import_common4.UnprocessableEntityException(`\xDCbergang '${existing.discoveryStatus}' \u2192 '${target}' ist nicht erlaubt`);
1632
1297
  }
1633
1298
  if (target === "approved") {
1634
1299
  const snapshot = resolveDiscoverySnapshot(this.snapshot, this.scanner);
1635
1300
  if (!snapshot) {
1636
- throw new import_common5.UnprocessableEntityException("Freigabe braucht einen Discovery-Snapshot \u2014 Discovery ist nicht initialisiert (#25)");
1301
+ throw new import_common4.UnprocessableEntityException("Freigabe braucht einen Discovery-Snapshot \u2014 Discovery ist nicht initialisiert (#25)");
1637
1302
  }
1638
1303
  return {
1639
1304
  discoveryStatus: "approved",
@@ -1850,19 +1515,19 @@ var CatalogEntriesService = class _CatalogEntriesService {
1850
1515
  return replaced;
1851
1516
  }
1852
1517
  };
1853
- CatalogEntriesService = _ts_decorate5([
1854
- (0, import_common5.Injectable)(),
1855
- _ts_param5(0, (0, import_common5.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
1856
- _ts_param5(1, (0, import_common5.Optional)()),
1857
- _ts_param5(1, (0, import_common5.Inject)(DISCOVERY_SNAPSHOT_TOKEN)),
1858
- _ts_param5(2, (0, import_common5.Optional)()),
1859
- _ts_param5(2, (0, import_common5.Inject)(CATALOG_SERVICE_CONFIG_TOKEN)),
1860
- _ts_param5(3, (0, import_common5.Optional)()),
1861
- _ts_param5(3, (0, import_common5.Inject)(DiscoveryScanner)),
1862
- _ts_param5(4, (0, import_common5.Optional)()),
1863
- _ts_param5(4, (0, import_common5.Inject)(FEATURE_UI_REGISTRY_TOKEN)),
1864
- _ts_metadata5("design:type", Function),
1865
- _ts_metadata5("design:paramtypes", [
1518
+ CatalogEntriesService = _ts_decorate4([
1519
+ (0, import_common4.Injectable)(),
1520
+ _ts_param4(0, (0, import_common4.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
1521
+ _ts_param4(1, (0, import_common4.Optional)()),
1522
+ _ts_param4(1, (0, import_common4.Inject)(DISCOVERY_SNAPSHOT_TOKEN)),
1523
+ _ts_param4(2, (0, import_common4.Optional)()),
1524
+ _ts_param4(2, (0, import_common4.Inject)(CATALOG_SERVICE_CONFIG_TOKEN)),
1525
+ _ts_param4(3, (0, import_common4.Optional)()),
1526
+ _ts_param4(3, (0, import_common4.Inject)(DiscoveryScanner)),
1527
+ _ts_param4(4, (0, import_common4.Optional)()),
1528
+ _ts_param4(4, (0, import_common4.Inject)(FEATURE_UI_REGISTRY_TOKEN)),
1529
+ _ts_metadata4("design:type", Function),
1530
+ _ts_metadata4("design:paramtypes", [
1866
1531
  typeof CatalogEntryRepository === "undefined" ? Object : CatalogEntryRepository,
1867
1532
  Object,
1868
1533
  typeof CatalogServiceConfig === "undefined" ? Object : CatalogServiceConfig,
@@ -1872,36 +1537,36 @@ CatalogEntriesService = _ts_decorate5([
1872
1537
  ], CatalogEntriesService);
1873
1538
 
1874
1539
  // src/catalog/catalog-entries.controller.ts
1875
- var import_common8 = require("@nestjs/common");
1540
+ var import_common7 = require("@nestjs/common");
1876
1541
 
1877
1542
  // src/core/web-audit.ts
1878
- var import_common7 = require("@nestjs/common");
1543
+ var import_common6 = require("@nestjs/common");
1879
1544
 
1880
1545
  // src/admin/admin-audit.service.ts
1881
1546
  var os = __toESM(require("os"), 1);
1882
- var import_common6 = require("@nestjs/common");
1547
+ var import_common5 = require("@nestjs/common");
1883
1548
 
1884
1549
  // src/admin/tokens.ts
1885
1550
  var AUDIT_PORT_TOKEN = /* @__PURE__ */ Symbol.for("saas-platform/AuditPort");
1886
1551
 
1887
1552
  // src/admin/admin-audit.service.ts
1888
- function _ts_decorate6(decorators, target, key, desc) {
1553
+ function _ts_decorate5(decorators, target, key, desc) {
1889
1554
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1890
1555
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1891
1556
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
1892
1557
  return c > 3 && r && Object.defineProperty(target, key, r), r;
1893
1558
  }
1894
- __name(_ts_decorate6, "_ts_decorate");
1895
- function _ts_metadata6(k, v) {
1559
+ __name(_ts_decorate5, "_ts_decorate");
1560
+ function _ts_metadata5(k, v) {
1896
1561
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
1897
1562
  }
1898
- __name(_ts_metadata6, "_ts_metadata");
1899
- function _ts_param6(paramIndex, decorator) {
1563
+ __name(_ts_metadata5, "_ts_metadata");
1564
+ function _ts_param5(paramIndex, decorator) {
1900
1565
  return function(target, key) {
1901
1566
  decorator(target, key, paramIndex);
1902
1567
  };
1903
1568
  }
1904
- __name(_ts_param6, "_ts_param");
1569
+ __name(_ts_param5, "_ts_param");
1905
1570
  var AdminAuditService = class {
1906
1571
  static {
1907
1572
  __name(this, "AdminAuditService");
@@ -1948,11 +1613,11 @@ var AdminAuditService = class {
1948
1613
  };
1949
1614
  }
1950
1615
  };
1951
- AdminAuditService = _ts_decorate6([
1952
- (0, import_common6.Injectable)(),
1953
- _ts_param6(0, (0, import_common6.Inject)(AUDIT_PORT_TOKEN)),
1954
- _ts_metadata6("design:type", Function),
1955
- _ts_metadata6("design:paramtypes", [
1616
+ AdminAuditService = _ts_decorate5([
1617
+ (0, import_common5.Injectable)(),
1618
+ _ts_param5(0, (0, import_common5.Inject)(AUDIT_PORT_TOKEN)),
1619
+ _ts_metadata5("design:type", Function),
1620
+ _ts_metadata5("design:paramtypes", [
1956
1621
  typeof AuditPort === "undefined" ? Object : AuditPort
1957
1622
  ])
1958
1623
  ], AdminAuditService);
@@ -1963,23 +1628,23 @@ var USER_EMAIL_RESOLVER_TOKEN = /* @__PURE__ */ Symbol.for("saas-platform/UserEm
1963
1628
  var AUDIT_CONTEXT_RESOLVER_TOKEN = /* @__PURE__ */ Symbol.for("saas-platform/AuditContextResolver");
1964
1629
 
1965
1630
  // src/core/web-audit.ts
1966
- function _ts_decorate7(decorators, target, key, desc) {
1631
+ function _ts_decorate6(decorators, target, key, desc) {
1967
1632
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1968
1633
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1969
1634
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
1970
1635
  return c > 3 && r && Object.defineProperty(target, key, r), r;
1971
1636
  }
1972
- __name(_ts_decorate7, "_ts_decorate");
1973
- function _ts_metadata7(k, v) {
1637
+ __name(_ts_decorate6, "_ts_decorate");
1638
+ function _ts_metadata6(k, v) {
1974
1639
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
1975
1640
  }
1976
- __name(_ts_metadata7, "_ts_metadata");
1977
- function _ts_param7(paramIndex, decorator) {
1641
+ __name(_ts_metadata6, "_ts_metadata");
1642
+ function _ts_param6(paramIndex, decorator) {
1978
1643
  return function(target, key) {
1979
1644
  decorator(target, key, paramIndex);
1980
1645
  };
1981
1646
  }
1982
- __name(_ts_param7, "_ts_param");
1647
+ __name(_ts_param6, "_ts_param");
1983
1648
  var DEFAULT_CONTEXT = "admin";
1984
1649
  var WebAuditLogger = class {
1985
1650
  static {
@@ -2036,18 +1701,18 @@ var WebAuditLogger = class {
2036
1701
  }
2037
1702
  }
2038
1703
  };
2039
- WebAuditLogger = _ts_decorate7([
2040
- (0, import_common7.Injectable)(),
2041
- _ts_param7(0, (0, import_common7.Optional)()),
2042
- _ts_param7(0, (0, import_common7.Inject)(AdminAuditService)),
2043
- _ts_param7(1, (0, import_common7.Optional)()),
2044
- _ts_param7(1, (0, import_common7.Inject)(USER_ID_RESOLVER_TOKEN)),
2045
- _ts_param7(2, (0, import_common7.Optional)()),
2046
- _ts_param7(2, (0, import_common7.Inject)(USER_EMAIL_RESOLVER_TOKEN)),
2047
- _ts_param7(3, (0, import_common7.Optional)()),
2048
- _ts_param7(3, (0, import_common7.Inject)(AUDIT_CONTEXT_RESOLVER_TOKEN)),
2049
- _ts_metadata7("design:type", Function),
2050
- _ts_metadata7("design:paramtypes", [
1704
+ WebAuditLogger = _ts_decorate6([
1705
+ (0, import_common6.Injectable)(),
1706
+ _ts_param6(0, (0, import_common6.Optional)()),
1707
+ _ts_param6(0, (0, import_common6.Inject)(AdminAuditService)),
1708
+ _ts_param6(1, (0, import_common6.Optional)()),
1709
+ _ts_param6(1, (0, import_common6.Inject)(USER_ID_RESOLVER_TOKEN)),
1710
+ _ts_param6(2, (0, import_common6.Optional)()),
1711
+ _ts_param6(2, (0, import_common6.Inject)(USER_EMAIL_RESOLVER_TOKEN)),
1712
+ _ts_param6(3, (0, import_common6.Optional)()),
1713
+ _ts_param6(3, (0, import_common6.Inject)(AUDIT_CONTEXT_RESOLVER_TOKEN)),
1714
+ _ts_metadata6("design:type", Function),
1715
+ _ts_metadata6("design:paramtypes", [
2051
1716
  Object,
2052
1717
  Object,
2053
1718
  Object,
@@ -2057,17 +1722,17 @@ WebAuditLogger = _ts_decorate7([
2057
1722
 
2058
1723
  // src/catalog/dto/catalog-entries.dto.ts
2059
1724
  var import_class_validator = require("class-validator");
2060
- function _ts_decorate8(decorators, target, key, desc) {
1725
+ function _ts_decorate7(decorators, target, key, desc) {
2061
1726
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2062
1727
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2063
1728
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2064
1729
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2065
1730
  }
2066
- __name(_ts_decorate8, "_ts_decorate");
2067
- function _ts_metadata8(k, v) {
1731
+ __name(_ts_decorate7, "_ts_decorate");
1732
+ function _ts_metadata7(k, v) {
2068
1733
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2069
1734
  }
2070
- __name(_ts_metadata8, "_ts_metadata");
1735
+ __name(_ts_metadata7, "_ts_metadata");
2071
1736
  var PROJECT_KEY_PATTERN = /^[a-z][a-z0-9-]*$/;
2072
1737
  var REVIEW_STATUSES = [
2073
1738
  "pending",
@@ -2091,24 +1756,24 @@ var ListCatalogEntriesQueryDto = class {
2091
1756
  /** Filter for capabilities (read-only code facts). */
2092
1757
  codeStatus;
2093
1758
  };
2094
- _ts_decorate8([
1759
+ _ts_decorate7([
2095
1760
  (0, import_class_validator.IsString)(),
2096
1761
  (0, import_class_validator.Matches)(PROJECT_KEY_PATTERN, {
2097
1762
  message: "projectKey muss kebab-case sein"
2098
1763
  }),
2099
- _ts_metadata8("design:type", String)
1764
+ _ts_metadata7("design:type", String)
2100
1765
  ], ListCatalogEntriesQueryDto.prototype, "projectKey", void 0);
2101
- _ts_decorate8([
1766
+ _ts_decorate7([
2102
1767
  (0, import_class_validator.IsOptional)(),
2103
1768
  (0, import_class_validator.IsString)(),
2104
1769
  (0, import_class_validator.IsIn)(REVIEW_STATUSES),
2105
- _ts_metadata8("design:type", String)
1770
+ _ts_metadata7("design:type", String)
2106
1771
  ], ListCatalogEntriesQueryDto.prototype, "discoveryStatus", void 0);
2107
- _ts_decorate8([
1772
+ _ts_decorate7([
2108
1773
  (0, import_class_validator.IsOptional)(),
2109
1774
  (0, import_class_validator.IsString)(),
2110
1775
  (0, import_class_validator.IsIn)(CODE_STATUSES),
2111
- _ts_metadata8("design:type", String)
1776
+ _ts_metadata7("design:type", String)
2112
1777
  ], ListCatalogEntriesQueryDto.prototype, "codeStatus", void 0);
2113
1778
  var ReviewCatalogEntryDto = class {
2114
1779
  static {
@@ -2116,12 +1781,12 @@ var ReviewCatalogEntryDto = class {
2116
1781
  }
2117
1782
  discoveryStatus;
2118
1783
  };
2119
- _ts_decorate8([
1784
+ _ts_decorate7([
2120
1785
  (0, import_class_validator.IsString)(),
2121
1786
  (0, import_class_validator.IsIn)(REVIEW_STATUSES, {
2122
1787
  message: "discoveryStatus muss pending|approved|outdated|obsolete sein"
2123
1788
  }),
2124
- _ts_metadata8("design:type", typeof DiscoveryStatus === "undefined" ? Object : DiscoveryStatus)
1789
+ _ts_metadata7("design:type", typeof DiscoveryStatus === "undefined" ? Object : DiscoveryStatus)
2125
1790
  ], ReviewCatalogEntryDto.prototype, "discoveryStatus", void 0);
2126
1791
  var UpdateCatalogEntryI18nDto = class {
2127
1792
  static {
@@ -2129,9 +1794,9 @@ var UpdateCatalogEntryI18nDto = class {
2129
1794
  }
2130
1795
  i18n;
2131
1796
  };
2132
- _ts_decorate8([
1797
+ _ts_decorate7([
2133
1798
  (0, import_class_validator.IsObject)(),
2134
- _ts_metadata8("design:type", typeof CatalogEntryI18n === "undefined" ? Object : CatalogEntryI18n)
1799
+ _ts_metadata7("design:type", typeof CatalogEntryI18n === "undefined" ? Object : CatalogEntryI18n)
2135
1800
  ], UpdateCatalogEntryI18nDto.prototype, "i18n", void 0);
2136
1801
  var UpdateCatalogEntryBaseDto = class {
2137
1802
  static {
@@ -2144,29 +1809,29 @@ var UpdateCatalogEntryBaseDto = class {
2144
1809
  icon;
2145
1810
  tier;
2146
1811
  };
2147
- _ts_decorate8([
1812
+ _ts_decorate7([
2148
1813
  (0, import_class_validator.IsOptional)(),
2149
1814
  (0, import_class_validator.IsString)(),
2150
1815
  (0, import_class_validator.MaxLength)(120),
2151
- _ts_metadata8("design:type", String)
1816
+ _ts_metadata7("design:type", String)
2152
1817
  ], UpdateCatalogEntryBaseDto.prototype, "label", void 0);
2153
- _ts_decorate8([
1818
+ _ts_decorate7([
2154
1819
  (0, import_class_validator.IsOptional)(),
2155
1820
  (0, import_class_validator.IsString)(),
2156
1821
  (0, import_class_validator.MaxLength)(2e3),
2157
- _ts_metadata8("design:type", Object)
1822
+ _ts_metadata7("design:type", Object)
2158
1823
  ], UpdateCatalogEntryBaseDto.prototype, "description", void 0);
2159
- _ts_decorate8([
1824
+ _ts_decorate7([
2160
1825
  (0, import_class_validator.IsOptional)(),
2161
1826
  (0, import_class_validator.IsString)(),
2162
1827
  (0, import_class_validator.MaxLength)(64),
2163
- _ts_metadata8("design:type", Object)
1828
+ _ts_metadata7("design:type", Object)
2164
1829
  ], UpdateCatalogEntryBaseDto.prototype, "icon", void 0);
2165
- _ts_decorate8([
1830
+ _ts_decorate7([
2166
1831
  (0, import_class_validator.IsOptional)(),
2167
1832
  (0, import_class_validator.IsString)(),
2168
1833
  (0, import_class_validator.MaxLength)(40),
2169
- _ts_metadata8("design:type", Object)
1834
+ _ts_metadata7("design:type", Object)
2170
1835
  ], UpdateCatalogEntryBaseDto.prototype, "tier", void 0);
2171
1836
  var SyncDiscoveryDto = class {
2172
1837
  static {
@@ -2174,29 +1839,29 @@ var SyncDiscoveryDto = class {
2174
1839
  }
2175
1840
  snapshot;
2176
1841
  };
2177
- _ts_decorate8([
1842
+ _ts_decorate7([
2178
1843
  (0, import_class_validator.IsObject)(),
2179
- _ts_metadata8("design:type", typeof DiscoverySnapshot === "undefined" ? Object : DiscoverySnapshot)
1844
+ _ts_metadata7("design:type", typeof DiscoverySnapshot === "undefined" ? Object : DiscoverySnapshot)
2180
1845
  ], SyncDiscoveryDto.prototype, "snapshot", void 0);
2181
1846
 
2182
1847
  // src/catalog/catalog-entries.controller.ts
2183
- function _ts_decorate9(decorators, target, key, desc) {
1848
+ function _ts_decorate8(decorators, target, key, desc) {
2184
1849
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2185
1850
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2186
1851
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2187
1852
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2188
1853
  }
2189
- __name(_ts_decorate9, "_ts_decorate");
2190
- function _ts_metadata9(k, v) {
1854
+ __name(_ts_decorate8, "_ts_decorate");
1855
+ function _ts_metadata8(k, v) {
2191
1856
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2192
1857
  }
2193
- __name(_ts_metadata9, "_ts_metadata");
2194
- function _ts_param8(paramIndex, decorator) {
1858
+ __name(_ts_metadata8, "_ts_metadata");
1859
+ function _ts_param7(paramIndex, decorator) {
2195
1860
  return function(target, key) {
2196
1861
  decorator(target, key, paramIndex);
2197
1862
  };
2198
1863
  }
2199
- __name(_ts_param8, "_ts_param");
1864
+ __name(_ts_param7, "_ts_param");
2200
1865
  function buildCatalogEntriesController(guards) {
2201
1866
  let GeneratedCatalogEntriesController = class GeneratedCatalogEntriesController {
2202
1867
  static {
@@ -2274,142 +1939,142 @@ function buildCatalogEntriesController(guards) {
2274
1939
  return result;
2275
1940
  }
2276
1941
  };
2277
- _ts_decorate9([
2278
- (0, import_common8.Get)("capabilities"),
2279
- _ts_param8(0, (0, import_common8.Query)()),
2280
- _ts_metadata9("design:type", Function),
2281
- _ts_metadata9("design:paramtypes", [
1942
+ _ts_decorate8([
1943
+ (0, import_common7.Get)("capabilities"),
1944
+ _ts_param7(0, (0, import_common7.Query)()),
1945
+ _ts_metadata8("design:type", Function),
1946
+ _ts_metadata8("design:paramtypes", [
2282
1947
  typeof ListCatalogEntriesQueryDto === "undefined" ? Object : ListCatalogEntriesQueryDto
2283
1948
  ]),
2284
- _ts_metadata9("design:returntype", void 0)
1949
+ _ts_metadata8("design:returntype", void 0)
2285
1950
  ], GeneratedCatalogEntriesController.prototype, "listCapabilities", null);
2286
- _ts_decorate9([
2287
- (0, import_common8.Get)("features"),
2288
- _ts_param8(0, (0, import_common8.Query)()),
2289
- _ts_metadata9("design:type", Function),
2290
- _ts_metadata9("design:paramtypes", [
1951
+ _ts_decorate8([
1952
+ (0, import_common7.Get)("features"),
1953
+ _ts_param7(0, (0, import_common7.Query)()),
1954
+ _ts_metadata8("design:type", Function),
1955
+ _ts_metadata8("design:paramtypes", [
2291
1956
  typeof ListCatalogEntriesQueryDto === "undefined" ? Object : ListCatalogEntriesQueryDto
2292
1957
  ]),
2293
- _ts_metadata9("design:returntype", void 0)
1958
+ _ts_metadata8("design:returntype", void 0)
2294
1959
  ], GeneratedCatalogEntriesController.prototype, "listFeatures", null);
2295
- _ts_decorate9([
2296
- (0, import_common8.Get)("quotas"),
2297
- _ts_param8(0, (0, import_common8.Query)()),
2298
- _ts_metadata9("design:type", Function),
2299
- _ts_metadata9("design:paramtypes", [
1960
+ _ts_decorate8([
1961
+ (0, import_common7.Get)("quotas"),
1962
+ _ts_param7(0, (0, import_common7.Query)()),
1963
+ _ts_metadata8("design:type", Function),
1964
+ _ts_metadata8("design:paramtypes", [
2300
1965
  typeof ListCatalogEntriesQueryDto === "undefined" ? Object : ListCatalogEntriesQueryDto
2301
1966
  ]),
2302
- _ts_metadata9("design:returntype", void 0)
1967
+ _ts_metadata8("design:returntype", void 0)
2303
1968
  ], GeneratedCatalogEntriesController.prototype, "listQuotas", null);
2304
- _ts_decorate9([
2305
- (0, import_common8.Patch)("features/:key/review"),
2306
- _ts_param8(0, (0, import_common8.Req)()),
2307
- _ts_param8(1, (0, import_common8.Param)("key")),
2308
- _ts_param8(2, (0, import_common8.Query)("projectKey")),
2309
- _ts_param8(3, (0, import_common8.Body)()),
2310
- _ts_metadata9("design:type", Function),
2311
- _ts_metadata9("design:paramtypes", [
1969
+ _ts_decorate8([
1970
+ (0, import_common7.Patch)("features/:key/review"),
1971
+ _ts_param7(0, (0, import_common7.Req)()),
1972
+ _ts_param7(1, (0, import_common7.Param)("key")),
1973
+ _ts_param7(2, (0, import_common7.Query)("projectKey")),
1974
+ _ts_param7(3, (0, import_common7.Body)()),
1975
+ _ts_metadata8("design:type", Function),
1976
+ _ts_metadata8("design:paramtypes", [
2312
1977
  Object,
2313
1978
  String,
2314
1979
  String,
2315
1980
  typeof ReviewCatalogEntryDto === "undefined" ? Object : ReviewCatalogEntryDto
2316
1981
  ]),
2317
- _ts_metadata9("design:returntype", Promise)
1982
+ _ts_metadata8("design:returntype", Promise)
2318
1983
  ], GeneratedCatalogEntriesController.prototype, "reviewFeature", null);
2319
- _ts_decorate9([
2320
- (0, import_common8.Patch)("quotas/:key/review"),
2321
- _ts_param8(0, (0, import_common8.Req)()),
2322
- _ts_param8(1, (0, import_common8.Param)("key")),
2323
- _ts_param8(2, (0, import_common8.Query)("projectKey")),
2324
- _ts_param8(3, (0, import_common8.Body)()),
2325
- _ts_metadata9("design:type", Function),
2326
- _ts_metadata9("design:paramtypes", [
1984
+ _ts_decorate8([
1985
+ (0, import_common7.Patch)("quotas/:key/review"),
1986
+ _ts_param7(0, (0, import_common7.Req)()),
1987
+ _ts_param7(1, (0, import_common7.Param)("key")),
1988
+ _ts_param7(2, (0, import_common7.Query)("projectKey")),
1989
+ _ts_param7(3, (0, import_common7.Body)()),
1990
+ _ts_metadata8("design:type", Function),
1991
+ _ts_metadata8("design:paramtypes", [
2327
1992
  Object,
2328
1993
  String,
2329
1994
  String,
2330
1995
  typeof ReviewCatalogEntryDto === "undefined" ? Object : ReviewCatalogEntryDto
2331
1996
  ]),
2332
- _ts_metadata9("design:returntype", Promise)
1997
+ _ts_metadata8("design:returntype", Promise)
2333
1998
  ], GeneratedCatalogEntriesController.prototype, "reviewQuota", null);
2334
- _ts_decorate9([
2335
- (0, import_common8.Patch)("features/:key/i18n"),
2336
- _ts_param8(0, (0, import_common8.Req)()),
2337
- _ts_param8(1, (0, import_common8.Param)("key")),
2338
- _ts_param8(2, (0, import_common8.Query)("projectKey")),
2339
- _ts_param8(3, (0, import_common8.Body)()),
2340
- _ts_metadata9("design:type", Function),
2341
- _ts_metadata9("design:paramtypes", [
1999
+ _ts_decorate8([
2000
+ (0, import_common7.Patch)("features/:key/i18n"),
2001
+ _ts_param7(0, (0, import_common7.Req)()),
2002
+ _ts_param7(1, (0, import_common7.Param)("key")),
2003
+ _ts_param7(2, (0, import_common7.Query)("projectKey")),
2004
+ _ts_param7(3, (0, import_common7.Body)()),
2005
+ _ts_metadata8("design:type", Function),
2006
+ _ts_metadata8("design:paramtypes", [
2342
2007
  Object,
2343
2008
  String,
2344
2009
  String,
2345
2010
  typeof UpdateCatalogEntryI18nDto === "undefined" ? Object : UpdateCatalogEntryI18nDto
2346
2011
  ]),
2347
- _ts_metadata9("design:returntype", Promise)
2012
+ _ts_metadata8("design:returntype", Promise)
2348
2013
  ], GeneratedCatalogEntriesController.prototype, "setFeatureI18n", null);
2349
- _ts_decorate9([
2350
- (0, import_common8.Patch)("quotas/:key/i18n"),
2351
- _ts_param8(0, (0, import_common8.Req)()),
2352
- _ts_param8(1, (0, import_common8.Param)("key")),
2353
- _ts_param8(2, (0, import_common8.Query)("projectKey")),
2354
- _ts_param8(3, (0, import_common8.Body)()),
2355
- _ts_metadata9("design:type", Function),
2356
- _ts_metadata9("design:paramtypes", [
2014
+ _ts_decorate8([
2015
+ (0, import_common7.Patch)("quotas/:key/i18n"),
2016
+ _ts_param7(0, (0, import_common7.Req)()),
2017
+ _ts_param7(1, (0, import_common7.Param)("key")),
2018
+ _ts_param7(2, (0, import_common7.Query)("projectKey")),
2019
+ _ts_param7(3, (0, import_common7.Body)()),
2020
+ _ts_metadata8("design:type", Function),
2021
+ _ts_metadata8("design:paramtypes", [
2357
2022
  Object,
2358
2023
  String,
2359
2024
  String,
2360
2025
  typeof UpdateCatalogEntryI18nDto === "undefined" ? Object : UpdateCatalogEntryI18nDto
2361
2026
  ]),
2362
- _ts_metadata9("design:returntype", Promise)
2027
+ _ts_metadata8("design:returntype", Promise)
2363
2028
  ], GeneratedCatalogEntriesController.prototype, "setQuotaI18n", null);
2364
- _ts_decorate9([
2365
- (0, import_common8.Patch)("features/:key"),
2366
- _ts_param8(0, (0, import_common8.Req)()),
2367
- _ts_param8(1, (0, import_common8.Param)("key")),
2368
- _ts_param8(2, (0, import_common8.Query)("projectKey")),
2369
- _ts_param8(3, (0, import_common8.Body)()),
2370
- _ts_metadata9("design:type", Function),
2371
- _ts_metadata9("design:paramtypes", [
2029
+ _ts_decorate8([
2030
+ (0, import_common7.Patch)("features/:key"),
2031
+ _ts_param7(0, (0, import_common7.Req)()),
2032
+ _ts_param7(1, (0, import_common7.Param)("key")),
2033
+ _ts_param7(2, (0, import_common7.Query)("projectKey")),
2034
+ _ts_param7(3, (0, import_common7.Body)()),
2035
+ _ts_metadata8("design:type", Function),
2036
+ _ts_metadata8("design:paramtypes", [
2372
2037
  Object,
2373
2038
  String,
2374
2039
  String,
2375
2040
  typeof UpdateCatalogEntryBaseDto === "undefined" ? Object : UpdateCatalogEntryBaseDto
2376
2041
  ]),
2377
- _ts_metadata9("design:returntype", Promise)
2042
+ _ts_metadata8("design:returntype", Promise)
2378
2043
  ], GeneratedCatalogEntriesController.prototype, "setFeatureBase", null);
2379
- _ts_decorate9([
2380
- (0, import_common8.Patch)("quotas/:key"),
2381
- _ts_param8(0, (0, import_common8.Req)()),
2382
- _ts_param8(1, (0, import_common8.Param)("key")),
2383
- _ts_param8(2, (0, import_common8.Query)("projectKey")),
2384
- _ts_param8(3, (0, import_common8.Body)()),
2385
- _ts_metadata9("design:type", Function),
2386
- _ts_metadata9("design:paramtypes", [
2044
+ _ts_decorate8([
2045
+ (0, import_common7.Patch)("quotas/:key"),
2046
+ _ts_param7(0, (0, import_common7.Req)()),
2047
+ _ts_param7(1, (0, import_common7.Param)("key")),
2048
+ _ts_param7(2, (0, import_common7.Query)("projectKey")),
2049
+ _ts_param7(3, (0, import_common7.Body)()),
2050
+ _ts_metadata8("design:type", Function),
2051
+ _ts_metadata8("design:paramtypes", [
2387
2052
  Object,
2388
2053
  String,
2389
2054
  String,
2390
2055
  typeof UpdateCatalogEntryBaseDto === "undefined" ? Object : UpdateCatalogEntryBaseDto
2391
2056
  ]),
2392
- _ts_metadata9("design:returntype", Promise)
2057
+ _ts_metadata8("design:returntype", Promise)
2393
2058
  ], GeneratedCatalogEntriesController.prototype, "setQuotaBase", null);
2394
- _ts_decorate9([
2395
- (0, import_common8.Post)("discovery/sync"),
2396
- _ts_param8(0, (0, import_common8.Req)()),
2397
- _ts_param8(1, (0, import_common8.Body)()),
2398
- _ts_metadata9("design:type", Function),
2399
- _ts_metadata9("design:paramtypes", [
2059
+ _ts_decorate8([
2060
+ (0, import_common7.Post)("discovery/sync"),
2061
+ _ts_param7(0, (0, import_common7.Req)()),
2062
+ _ts_param7(1, (0, import_common7.Body)()),
2063
+ _ts_metadata8("design:type", Function),
2064
+ _ts_metadata8("design:paramtypes", [
2400
2065
  Object,
2401
2066
  typeof SyncDiscoveryDto === "undefined" ? Object : SyncDiscoveryDto
2402
2067
  ]),
2403
- _ts_metadata9("design:returntype", Promise)
2068
+ _ts_metadata8("design:returntype", Promise)
2404
2069
  ], GeneratedCatalogEntriesController.prototype, "syncDiscovery", null);
2405
- GeneratedCatalogEntriesController = _ts_decorate9([
2406
- (0, import_common8.Controller)("admin/catalog"),
2407
- (0, import_common8.UseGuards)(...guards),
2408
- _ts_param8(0, (0, import_common8.Inject)(CatalogEntriesService)),
2409
- _ts_param8(1, (0, import_common8.Optional)()),
2410
- _ts_param8(1, (0, import_common8.Inject)(WebAuditLogger)),
2411
- _ts_metadata9("design:type", Function),
2412
- _ts_metadata9("design:paramtypes", [
2070
+ GeneratedCatalogEntriesController = _ts_decorate8([
2071
+ (0, import_common7.Controller)("admin/catalog"),
2072
+ (0, import_common7.UseGuards)(...guards),
2073
+ _ts_param7(0, (0, import_common7.Inject)(CatalogEntriesService)),
2074
+ _ts_param7(1, (0, import_common7.Optional)()),
2075
+ _ts_param7(1, (0, import_common7.Inject)(WebAuditLogger)),
2076
+ _ts_metadata8("design:type", Function),
2077
+ _ts_metadata8("design:paramtypes", [
2413
2078
  typeof CatalogEntriesService === "undefined" ? Object : CatalogEntriesService,
2414
2079
  Object
2415
2080
  ])
@@ -2419,24 +2084,24 @@ function buildCatalogEntriesController(guards) {
2419
2084
  __name(buildCatalogEntriesController, "buildCatalogEntriesController");
2420
2085
 
2421
2086
  // src/catalog/promotions.service.ts
2422
- var import_common9 = require("@nestjs/common");
2423
- function _ts_decorate10(decorators, target, key, desc) {
2087
+ var import_common8 = require("@nestjs/common");
2088
+ function _ts_decorate9(decorators, target, key, desc) {
2424
2089
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2425
2090
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2426
2091
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2427
2092
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2428
2093
  }
2429
- __name(_ts_decorate10, "_ts_decorate");
2430
- function _ts_metadata10(k, v) {
2094
+ __name(_ts_decorate9, "_ts_decorate");
2095
+ function _ts_metadata9(k, v) {
2431
2096
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2432
2097
  }
2433
- __name(_ts_metadata10, "_ts_metadata");
2434
- function _ts_param9(paramIndex, decorator) {
2098
+ __name(_ts_metadata9, "_ts_metadata");
2099
+ function _ts_param8(paramIndex, decorator) {
2435
2100
  return function(target, key) {
2436
2101
  decorator(target, key, paramIndex);
2437
2102
  };
2438
2103
  }
2439
- __name(_ts_param9, "_ts_param");
2104
+ __name(_ts_param8, "_ts_param");
2440
2105
  var PromotionsService = class {
2441
2106
  static {
2442
2107
  __name(this, "PromotionsService");
@@ -2453,7 +2118,7 @@ var PromotionsService = class {
2453
2118
  async getById(id) {
2454
2119
  const row = await this.repo.findById(id);
2455
2120
  if (!row) {
2456
- throw new import_common9.NotFoundException(`Promotion '${id}' nicht gefunden`);
2121
+ throw new import_common8.NotFoundException(`Promotion '${id}' nicht gefunden`);
2457
2122
  }
2458
2123
  return row;
2459
2124
  }
@@ -2463,43 +2128,43 @@ var PromotionsService = class {
2463
2128
  async update(id, data) {
2464
2129
  const existing = await this.repo.findById(id);
2465
2130
  if (!existing) {
2466
- throw new import_common9.NotFoundException(`Promotion '${id}' nicht gefunden`);
2131
+ throw new import_common8.NotFoundException(`Promotion '${id}' nicht gefunden`);
2467
2132
  }
2468
2133
  return this.repo.update(id, data);
2469
2134
  }
2470
2135
  async delete(id) {
2471
2136
  const existing = await this.repo.findById(id);
2472
2137
  if (!existing) {
2473
- throw new import_common9.NotFoundException(`Promotion '${id}' nicht gefunden`);
2138
+ throw new import_common8.NotFoundException(`Promotion '${id}' nicht gefunden`);
2474
2139
  }
2475
2140
  await this.repo.delete(id);
2476
2141
  }
2477
2142
  };
2478
- PromotionsService = _ts_decorate10([
2479
- (0, import_common9.Injectable)(),
2480
- _ts_param9(0, (0, import_common9.Inject)(PROMOTION_REPOSITORY_TOKEN)),
2481
- _ts_metadata10("design:type", Function),
2482
- _ts_metadata10("design:paramtypes", [
2143
+ PromotionsService = _ts_decorate9([
2144
+ (0, import_common8.Injectable)(),
2145
+ _ts_param8(0, (0, import_common8.Inject)(PROMOTION_REPOSITORY_TOKEN)),
2146
+ _ts_metadata9("design:type", Function),
2147
+ _ts_metadata9("design:paramtypes", [
2483
2148
  typeof PromotionRepository === "undefined" ? Object : PromotionRepository
2484
2149
  ])
2485
2150
  ], PromotionsService);
2486
2151
 
2487
2152
  // src/catalog/promotions.controller.ts
2488
- var import_common10 = require("@nestjs/common");
2153
+ var import_common9 = require("@nestjs/common");
2489
2154
 
2490
2155
  // src/catalog/dto/promotions.dto.ts
2491
2156
  var import_class_validator2 = require("class-validator");
2492
- function _ts_decorate11(decorators, target, key, desc) {
2157
+ function _ts_decorate10(decorators, target, key, desc) {
2493
2158
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2494
2159
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2495
2160
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2496
2161
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2497
2162
  }
2498
- __name(_ts_decorate11, "_ts_decorate");
2499
- function _ts_metadata11(k, v) {
2163
+ __name(_ts_decorate10, "_ts_decorate");
2164
+ function _ts_metadata10(k, v) {
2500
2165
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2501
2166
  }
2502
- __name(_ts_metadata11, "_ts_metadata");
2167
+ __name(_ts_metadata10, "_ts_metadata");
2503
2168
  var PROJECT_KEY_PATTERN2 = /^[a-z][a-z0-9-]*$/;
2504
2169
  var ISO_DATE_PATTERN = /^\d{4}-\d{2}-\d{2}/;
2505
2170
  var TYPES = [
@@ -2524,12 +2189,12 @@ var ListPromotionsQueryDto = class {
2524
2189
  }
2525
2190
  projectKey;
2526
2191
  };
2527
- _ts_decorate11([
2192
+ _ts_decorate10([
2528
2193
  (0, import_class_validator2.IsString)(),
2529
2194
  (0, import_class_validator2.Matches)(PROJECT_KEY_PATTERN2, {
2530
2195
  message: "projectKey muss kebab-case sein"
2531
2196
  }),
2532
- _ts_metadata11("design:type", String)
2197
+ _ts_metadata10("design:type", String)
2533
2198
  ], ListPromotionsQueryDto.prototype, "projectKey", void 0);
2534
2199
  var CreatePromotionDto = class {
2535
2200
  static {
@@ -2552,96 +2217,96 @@ var CreatePromotionDto = class {
2552
2217
  color;
2553
2218
  i18n;
2554
2219
  };
2555
- _ts_decorate11([
2220
+ _ts_decorate10([
2556
2221
  (0, import_class_validator2.IsString)(),
2557
2222
  (0, import_class_validator2.Matches)(PROJECT_KEY_PATTERN2),
2558
2223
  (0, import_class_validator2.MaxLength)(64),
2559
- _ts_metadata11("design:type", String)
2224
+ _ts_metadata10("design:type", String)
2560
2225
  ], CreatePromotionDto.prototype, "projectKey", void 0);
2561
- _ts_decorate11([
2226
+ _ts_decorate10([
2562
2227
  (0, import_class_validator2.IsString)(),
2563
2228
  (0, import_class_validator2.MaxLength)(120),
2564
- _ts_metadata11("design:type", String)
2229
+ _ts_metadata10("design:type", String)
2565
2230
  ], CreatePromotionDto.prototype, "internalLabel", void 0);
2566
- _ts_decorate11([
2231
+ _ts_decorate10([
2567
2232
  (0, import_class_validator2.IsString)(),
2568
2233
  (0, import_class_validator2.IsIn)(TYPES),
2569
- _ts_metadata11("design:type", typeof PromotionType === "undefined" ? Object : PromotionType)
2234
+ _ts_metadata10("design:type", typeof PromotionType === "undefined" ? Object : PromotionType)
2570
2235
  ], CreatePromotionDto.prototype, "type", void 0);
2571
- _ts_decorate11([
2236
+ _ts_decorate10([
2572
2237
  (0, import_class_validator2.IsDefined)(),
2573
- _ts_metadata11("design:type", typeof PromotionValue === "undefined" ? Object : PromotionValue)
2238
+ _ts_metadata10("design:type", typeof PromotionValue === "undefined" ? Object : PromotionValue)
2574
2239
  ], CreatePromotionDto.prototype, "value", void 0);
2575
- _ts_decorate11([
2240
+ _ts_decorate10([
2576
2241
  (0, import_class_validator2.IsOptional)(),
2577
2242
  (0, import_class_validator2.IsArray)(),
2578
2243
  (0, import_class_validator2.IsString)({
2579
2244
  each: true
2580
2245
  }),
2581
- _ts_metadata11("design:type", Array)
2246
+ _ts_metadata10("design:type", Array)
2582
2247
  ], CreatePromotionDto.prototype, "appliesTo", void 0);
2583
- _ts_decorate11([
2248
+ _ts_decorate10([
2584
2249
  (0, import_class_validator2.IsOptional)(),
2585
2250
  (0, import_class_validator2.IsString)(),
2586
2251
  (0, import_class_validator2.IsIn)(TARGET_TYPES),
2587
- _ts_metadata11("design:type", typeof PromotionTargetType === "undefined" ? Object : PromotionTargetType)
2252
+ _ts_metadata10("design:type", typeof PromotionTargetType === "undefined" ? Object : PromotionTargetType)
2588
2253
  ], CreatePromotionDto.prototype, "targetType", void 0);
2589
- _ts_decorate11([
2254
+ _ts_decorate10([
2590
2255
  (0, import_class_validator2.IsOptional)(),
2591
2256
  (0, import_class_validator2.IsString)(),
2592
2257
  (0, import_class_validator2.IsIn)(CYCLES),
2593
- _ts_metadata11("design:type", typeof PromotionBillingCycle === "undefined" ? Object : PromotionBillingCycle)
2258
+ _ts_metadata10("design:type", typeof PromotionBillingCycle === "undefined" ? Object : PromotionBillingCycle)
2594
2259
  ], CreatePromotionDto.prototype, "billingCycle", void 0);
2595
- _ts_decorate11([
2260
+ _ts_decorate10([
2596
2261
  (0, import_class_validator2.IsString)(),
2597
2262
  (0, import_class_validator2.Matches)(ISO_DATE_PATTERN, {
2598
2263
  message: "validFrom muss ISO-Datum sein"
2599
2264
  }),
2600
- _ts_metadata11("design:type", String)
2265
+ _ts_metadata10("design:type", String)
2601
2266
  ], CreatePromotionDto.prototype, "validFrom", void 0);
2602
- _ts_decorate11([
2267
+ _ts_decorate10([
2603
2268
  (0, import_class_validator2.IsString)(),
2604
2269
  (0, import_class_validator2.Matches)(ISO_DATE_PATTERN, {
2605
2270
  message: "validTo muss ISO-Datum sein"
2606
2271
  }),
2607
- _ts_metadata11("design:type", String)
2272
+ _ts_metadata10("design:type", String)
2608
2273
  ], CreatePromotionDto.prototype, "validTo", void 0);
2609
- _ts_decorate11([
2274
+ _ts_decorate10([
2610
2275
  (0, import_class_validator2.IsOptional)(),
2611
2276
  (0, import_class_validator2.IsInt)(),
2612
- _ts_metadata11("design:type", Number)
2277
+ _ts_metadata10("design:type", Number)
2613
2278
  ], CreatePromotionDto.prototype, "priority", void 0);
2614
- _ts_decorate11([
2279
+ _ts_decorate10([
2615
2280
  (0, import_class_validator2.IsOptional)(),
2616
2281
  (0, import_class_validator2.IsArray)(),
2617
2282
  (0, import_class_validator2.IsString)({
2618
2283
  each: true
2619
2284
  }),
2620
- _ts_metadata11("design:type", Object)
2285
+ _ts_metadata10("design:type", Object)
2621
2286
  ], CreatePromotionDto.prototype, "onlyLocales", void 0);
2622
- _ts_decorate11([
2287
+ _ts_decorate10([
2623
2288
  (0, import_class_validator2.IsOptional)(),
2624
2289
  (0, import_class_validator2.IsBoolean)(),
2625
- _ts_metadata11("design:type", Boolean)
2290
+ _ts_metadata10("design:type", Boolean)
2626
2291
  ], CreatePromotionDto.prototype, "requiresCoupon", void 0);
2627
- _ts_decorate11([
2292
+ _ts_decorate10([
2628
2293
  (0, import_class_validator2.IsOptional)(),
2629
2294
  (0, import_class_validator2.IsArray)(),
2630
2295
  (0, import_class_validator2.IsString)({
2631
2296
  each: true
2632
2297
  }),
2633
- _ts_metadata11("design:type", Array)
2298
+ _ts_metadata10("design:type", Array)
2634
2299
  ], CreatePromotionDto.prototype, "codes", void 0);
2635
- _ts_decorate11([
2300
+ _ts_decorate10([
2636
2301
  (0, import_class_validator2.IsOptional)(),
2637
2302
  (0, import_class_validator2.IsString)(),
2638
2303
  (0, import_class_validator2.MaxLength)(16),
2639
- _ts_metadata11("design:type", String)
2304
+ _ts_metadata10("design:type", String)
2640
2305
  ], CreatePromotionDto.prototype, "color", void 0);
2641
- _ts_decorate11([
2306
+ _ts_decorate10([
2642
2307
  (0, import_class_validator2.IsOptional)(),
2643
2308
  (0, import_class_validator2.IsObject)(),
2644
- _ts_metadata11("design:type", typeof PromotionI18n === "undefined" ? Object : PromotionI18n)
2309
+ _ts_metadata10("design:type", typeof PromotionI18n === "undefined" ? Object : PromotionI18n)
2645
2310
  ], CreatePromotionDto.prototype, "i18n", void 0);
2646
2311
  var UpdatePromotionDto = class {
2647
2312
  static {
@@ -2662,110 +2327,110 @@ var UpdatePromotionDto = class {
2662
2327
  color;
2663
2328
  i18n;
2664
2329
  };
2665
- _ts_decorate11([
2330
+ _ts_decorate10([
2666
2331
  (0, import_class_validator2.IsOptional)(),
2667
2332
  (0, import_class_validator2.IsString)(),
2668
2333
  (0, import_class_validator2.MaxLength)(120),
2669
- _ts_metadata11("design:type", String)
2334
+ _ts_metadata10("design:type", String)
2670
2335
  ], UpdatePromotionDto.prototype, "internalLabel", void 0);
2671
- _ts_decorate11([
2336
+ _ts_decorate10([
2672
2337
  (0, import_class_validator2.IsOptional)(),
2673
2338
  (0, import_class_validator2.IsString)(),
2674
2339
  (0, import_class_validator2.IsIn)(TYPES),
2675
- _ts_metadata11("design:type", typeof PromotionType === "undefined" ? Object : PromotionType)
2340
+ _ts_metadata10("design:type", typeof PromotionType === "undefined" ? Object : PromotionType)
2676
2341
  ], UpdatePromotionDto.prototype, "type", void 0);
2677
- _ts_decorate11([
2342
+ _ts_decorate10([
2678
2343
  (0, import_class_validator2.IsOptional)(),
2679
- _ts_metadata11("design:type", typeof PromotionValue === "undefined" ? Object : PromotionValue)
2344
+ _ts_metadata10("design:type", typeof PromotionValue === "undefined" ? Object : PromotionValue)
2680
2345
  ], UpdatePromotionDto.prototype, "value", void 0);
2681
- _ts_decorate11([
2346
+ _ts_decorate10([
2682
2347
  (0, import_class_validator2.IsOptional)(),
2683
2348
  (0, import_class_validator2.IsArray)(),
2684
2349
  (0, import_class_validator2.IsString)({
2685
2350
  each: true
2686
2351
  }),
2687
- _ts_metadata11("design:type", Array)
2352
+ _ts_metadata10("design:type", Array)
2688
2353
  ], UpdatePromotionDto.prototype, "appliesTo", void 0);
2689
- _ts_decorate11([
2354
+ _ts_decorate10([
2690
2355
  (0, import_class_validator2.IsOptional)(),
2691
2356
  (0, import_class_validator2.IsString)(),
2692
2357
  (0, import_class_validator2.IsIn)(TARGET_TYPES),
2693
- _ts_metadata11("design:type", typeof PromotionTargetType === "undefined" ? Object : PromotionTargetType)
2358
+ _ts_metadata10("design:type", typeof PromotionTargetType === "undefined" ? Object : PromotionTargetType)
2694
2359
  ], UpdatePromotionDto.prototype, "targetType", void 0);
2695
- _ts_decorate11([
2360
+ _ts_decorate10([
2696
2361
  (0, import_class_validator2.IsOptional)(),
2697
2362
  (0, import_class_validator2.IsString)(),
2698
2363
  (0, import_class_validator2.IsIn)(CYCLES),
2699
- _ts_metadata11("design:type", typeof PromotionBillingCycle === "undefined" ? Object : PromotionBillingCycle)
2364
+ _ts_metadata10("design:type", typeof PromotionBillingCycle === "undefined" ? Object : PromotionBillingCycle)
2700
2365
  ], UpdatePromotionDto.prototype, "billingCycle", void 0);
2701
- _ts_decorate11([
2366
+ _ts_decorate10([
2702
2367
  (0, import_class_validator2.IsOptional)(),
2703
2368
  (0, import_class_validator2.IsString)(),
2704
2369
  (0, import_class_validator2.Matches)(ISO_DATE_PATTERN),
2705
- _ts_metadata11("design:type", String)
2370
+ _ts_metadata10("design:type", String)
2706
2371
  ], UpdatePromotionDto.prototype, "validFrom", void 0);
2707
- _ts_decorate11([
2372
+ _ts_decorate10([
2708
2373
  (0, import_class_validator2.IsOptional)(),
2709
2374
  (0, import_class_validator2.IsString)(),
2710
2375
  (0, import_class_validator2.Matches)(ISO_DATE_PATTERN),
2711
- _ts_metadata11("design:type", String)
2376
+ _ts_metadata10("design:type", String)
2712
2377
  ], UpdatePromotionDto.prototype, "validTo", void 0);
2713
- _ts_decorate11([
2378
+ _ts_decorate10([
2714
2379
  (0, import_class_validator2.IsOptional)(),
2715
2380
  (0, import_class_validator2.IsInt)(),
2716
- _ts_metadata11("design:type", Number)
2381
+ _ts_metadata10("design:type", Number)
2717
2382
  ], UpdatePromotionDto.prototype, "priority", void 0);
2718
- _ts_decorate11([
2383
+ _ts_decorate10([
2719
2384
  (0, import_class_validator2.IsOptional)(),
2720
2385
  (0, import_class_validator2.IsArray)(),
2721
2386
  (0, import_class_validator2.IsString)({
2722
2387
  each: true
2723
2388
  }),
2724
- _ts_metadata11("design:type", Object)
2389
+ _ts_metadata10("design:type", Object)
2725
2390
  ], UpdatePromotionDto.prototype, "onlyLocales", void 0);
2726
- _ts_decorate11([
2391
+ _ts_decorate10([
2727
2392
  (0, import_class_validator2.IsOptional)(),
2728
2393
  (0, import_class_validator2.IsBoolean)(),
2729
- _ts_metadata11("design:type", Boolean)
2394
+ _ts_metadata10("design:type", Boolean)
2730
2395
  ], UpdatePromotionDto.prototype, "requiresCoupon", void 0);
2731
- _ts_decorate11([
2396
+ _ts_decorate10([
2732
2397
  (0, import_class_validator2.IsOptional)(),
2733
2398
  (0, import_class_validator2.IsArray)(),
2734
2399
  (0, import_class_validator2.IsString)({
2735
2400
  each: true
2736
2401
  }),
2737
- _ts_metadata11("design:type", Array)
2402
+ _ts_metadata10("design:type", Array)
2738
2403
  ], UpdatePromotionDto.prototype, "codes", void 0);
2739
- _ts_decorate11([
2404
+ _ts_decorate10([
2740
2405
  (0, import_class_validator2.IsOptional)(),
2741
2406
  (0, import_class_validator2.IsString)(),
2742
2407
  (0, import_class_validator2.MaxLength)(16),
2743
- _ts_metadata11("design:type", String)
2408
+ _ts_metadata10("design:type", String)
2744
2409
  ], UpdatePromotionDto.prototype, "color", void 0);
2745
- _ts_decorate11([
2410
+ _ts_decorate10([
2746
2411
  (0, import_class_validator2.IsOptional)(),
2747
2412
  (0, import_class_validator2.IsObject)(),
2748
- _ts_metadata11("design:type", typeof PromotionI18n === "undefined" ? Object : PromotionI18n)
2413
+ _ts_metadata10("design:type", typeof PromotionI18n === "undefined" ? Object : PromotionI18n)
2749
2414
  ], UpdatePromotionDto.prototype, "i18n", void 0);
2750
2415
 
2751
2416
  // src/catalog/promotions.controller.ts
2752
- function _ts_decorate12(decorators, target, key, desc) {
2417
+ function _ts_decorate11(decorators, target, key, desc) {
2753
2418
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2754
2419
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2755
2420
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2756
2421
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2757
2422
  }
2758
- __name(_ts_decorate12, "_ts_decorate");
2759
- function _ts_metadata12(k, v) {
2423
+ __name(_ts_decorate11, "_ts_decorate");
2424
+ function _ts_metadata11(k, v) {
2760
2425
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2761
2426
  }
2762
- __name(_ts_metadata12, "_ts_metadata");
2763
- function _ts_param10(paramIndex, decorator) {
2427
+ __name(_ts_metadata11, "_ts_metadata");
2428
+ function _ts_param9(paramIndex, decorator) {
2764
2429
  return function(target, key) {
2765
2430
  decorator(target, key, paramIndex);
2766
2431
  };
2767
2432
  }
2768
- __name(_ts_param10, "_ts_param");
2433
+ __name(_ts_param9, "_ts_param");
2769
2434
  function buildPromotionsController(guards) {
2770
2435
  let GeneratedPromotionsController = class GeneratedPromotionsController {
2771
2436
  static {
@@ -2791,60 +2456,60 @@ function buildPromotionsController(guards) {
2791
2456
  await this.service.delete(id);
2792
2457
  }
2793
2458
  };
2794
- _ts_decorate12([
2795
- (0, import_common10.Get)(),
2796
- _ts_param10(0, (0, import_common10.Query)()),
2797
- _ts_metadata12("design:type", Function),
2798
- _ts_metadata12("design:paramtypes", [
2459
+ _ts_decorate11([
2460
+ (0, import_common9.Get)(),
2461
+ _ts_param9(0, (0, import_common9.Query)()),
2462
+ _ts_metadata11("design:type", Function),
2463
+ _ts_metadata11("design:paramtypes", [
2799
2464
  typeof ListPromotionsQueryDto === "undefined" ? Object : ListPromotionsQueryDto
2800
2465
  ]),
2801
- _ts_metadata12("design:returntype", void 0)
2466
+ _ts_metadata11("design:returntype", void 0)
2802
2467
  ], GeneratedPromotionsController.prototype, "list", null);
2803
- _ts_decorate12([
2804
- (0, import_common10.Get)(":id"),
2805
- _ts_param10(0, (0, import_common10.Param)("id", new import_common10.ParseUUIDPipe())),
2806
- _ts_metadata12("design:type", Function),
2807
- _ts_metadata12("design:paramtypes", [
2468
+ _ts_decorate11([
2469
+ (0, import_common9.Get)(":id"),
2470
+ _ts_param9(0, (0, import_common9.Param)("id", new import_common9.ParseUUIDPipe())),
2471
+ _ts_metadata11("design:type", Function),
2472
+ _ts_metadata11("design:paramtypes", [
2808
2473
  String
2809
2474
  ]),
2810
- _ts_metadata12("design:returntype", void 0)
2475
+ _ts_metadata11("design:returntype", void 0)
2811
2476
  ], GeneratedPromotionsController.prototype, "getById", null);
2812
- _ts_decorate12([
2813
- (0, import_common10.Post)(),
2814
- _ts_param10(0, (0, import_common10.Body)()),
2815
- _ts_metadata12("design:type", Function),
2816
- _ts_metadata12("design:paramtypes", [
2477
+ _ts_decorate11([
2478
+ (0, import_common9.Post)(),
2479
+ _ts_param9(0, (0, import_common9.Body)()),
2480
+ _ts_metadata11("design:type", Function),
2481
+ _ts_metadata11("design:paramtypes", [
2817
2482
  typeof CreatePromotionDto === "undefined" ? Object : CreatePromotionDto
2818
2483
  ]),
2819
- _ts_metadata12("design:returntype", void 0)
2484
+ _ts_metadata11("design:returntype", void 0)
2820
2485
  ], GeneratedPromotionsController.prototype, "create", null);
2821
- _ts_decorate12([
2822
- (0, import_common10.Patch)(":id"),
2823
- _ts_param10(0, (0, import_common10.Param)("id", new import_common10.ParseUUIDPipe())),
2824
- _ts_param10(1, (0, import_common10.Body)()),
2825
- _ts_metadata12("design:type", Function),
2826
- _ts_metadata12("design:paramtypes", [
2486
+ _ts_decorate11([
2487
+ (0, import_common9.Patch)(":id"),
2488
+ _ts_param9(0, (0, import_common9.Param)("id", new import_common9.ParseUUIDPipe())),
2489
+ _ts_param9(1, (0, import_common9.Body)()),
2490
+ _ts_metadata11("design:type", Function),
2491
+ _ts_metadata11("design:paramtypes", [
2827
2492
  String,
2828
2493
  typeof UpdatePromotionDto === "undefined" ? Object : UpdatePromotionDto
2829
2494
  ]),
2830
- _ts_metadata12("design:returntype", void 0)
2495
+ _ts_metadata11("design:returntype", void 0)
2831
2496
  ], GeneratedPromotionsController.prototype, "update", null);
2832
- _ts_decorate12([
2833
- (0, import_common10.Delete)(":id"),
2834
- (0, import_common10.HttpCode)(import_common10.HttpStatus.NO_CONTENT),
2835
- _ts_param10(0, (0, import_common10.Param)("id", new import_common10.ParseUUIDPipe())),
2836
- _ts_metadata12("design:type", Function),
2837
- _ts_metadata12("design:paramtypes", [
2497
+ _ts_decorate11([
2498
+ (0, import_common9.Delete)(":id"),
2499
+ (0, import_common9.HttpCode)(import_common9.HttpStatus.NO_CONTENT),
2500
+ _ts_param9(0, (0, import_common9.Param)("id", new import_common9.ParseUUIDPipe())),
2501
+ _ts_metadata11("design:type", Function),
2502
+ _ts_metadata11("design:paramtypes", [
2838
2503
  String
2839
2504
  ]),
2840
- _ts_metadata12("design:returntype", Promise)
2505
+ _ts_metadata11("design:returntype", Promise)
2841
2506
  ], GeneratedPromotionsController.prototype, "remove", null);
2842
- GeneratedPromotionsController = _ts_decorate12([
2843
- (0, import_common10.Controller)("admin/catalog/promotions"),
2844
- (0, import_common10.UseGuards)(...guards),
2845
- _ts_param10(0, (0, import_common10.Inject)(PromotionsService)),
2846
- _ts_metadata12("design:type", Function),
2847
- _ts_metadata12("design:paramtypes", [
2507
+ GeneratedPromotionsController = _ts_decorate11([
2508
+ (0, import_common9.Controller)("admin/catalog/promotions"),
2509
+ (0, import_common9.UseGuards)(...guards),
2510
+ _ts_param9(0, (0, import_common9.Inject)(PromotionsService)),
2511
+ _ts_metadata11("design:type", Function),
2512
+ _ts_metadata11("design:paramtypes", [
2848
2513
  typeof PromotionsService === "undefined" ? Object : PromotionsService
2849
2514
  ])
2850
2515
  ], GeneratedPromotionsController);
@@ -2853,24 +2518,24 @@ function buildPromotionsController(guards) {
2853
2518
  __name(buildPromotionsController, "buildPromotionsController");
2854
2519
 
2855
2520
  // src/catalog/marketing-settings.service.ts
2856
- var import_common11 = require("@nestjs/common");
2857
- function _ts_decorate13(decorators, target, key, desc) {
2521
+ var import_common10 = require("@nestjs/common");
2522
+ function _ts_decorate12(decorators, target, key, desc) {
2858
2523
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2859
2524
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2860
2525
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2861
2526
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2862
2527
  }
2863
- __name(_ts_decorate13, "_ts_decorate");
2864
- function _ts_metadata13(k, v) {
2528
+ __name(_ts_decorate12, "_ts_decorate");
2529
+ function _ts_metadata12(k, v) {
2865
2530
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2866
2531
  }
2867
- __name(_ts_metadata13, "_ts_metadata");
2868
- function _ts_param11(paramIndex, decorator) {
2532
+ __name(_ts_metadata12, "_ts_metadata");
2533
+ function _ts_param10(paramIndex, decorator) {
2869
2534
  return function(target, key) {
2870
2535
  decorator(target, key, paramIndex);
2871
2536
  };
2872
2537
  }
2873
- __name(_ts_param11, "_ts_param");
2538
+ __name(_ts_param10, "_ts_param");
2874
2539
  var MarketingSettingsService = class {
2875
2540
  static {
2876
2541
  __name(this, "MarketingSettingsService");
@@ -2887,31 +2552,31 @@ var MarketingSettingsService = class {
2887
2552
  return this.repo.upsert(projectKey, data);
2888
2553
  }
2889
2554
  };
2890
- MarketingSettingsService = _ts_decorate13([
2891
- (0, import_common11.Injectable)(),
2892
- _ts_param11(0, (0, import_common11.Inject)(MARKETING_SETTINGS_REPOSITORY_TOKEN)),
2893
- _ts_metadata13("design:type", Function),
2894
- _ts_metadata13("design:paramtypes", [
2555
+ MarketingSettingsService = _ts_decorate12([
2556
+ (0, import_common10.Injectable)(),
2557
+ _ts_param10(0, (0, import_common10.Inject)(MARKETING_SETTINGS_REPOSITORY_TOKEN)),
2558
+ _ts_metadata12("design:type", Function),
2559
+ _ts_metadata12("design:paramtypes", [
2895
2560
  typeof MarketingSettingsRepository === "undefined" ? Object : MarketingSettingsRepository
2896
2561
  ])
2897
2562
  ], MarketingSettingsService);
2898
2563
 
2899
2564
  // src/catalog/marketing-settings.controller.ts
2900
- var import_common12 = require("@nestjs/common");
2565
+ var import_common11 = require("@nestjs/common");
2901
2566
 
2902
2567
  // src/catalog/dto/marketing-settings.dto.ts
2903
2568
  var import_class_validator3 = require("class-validator");
2904
- function _ts_decorate14(decorators, target, key, desc) {
2569
+ function _ts_decorate13(decorators, target, key, desc) {
2905
2570
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2906
2571
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2907
2572
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2908
2573
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2909
2574
  }
2910
- __name(_ts_decorate14, "_ts_decorate");
2911
- function _ts_metadata14(k, v) {
2575
+ __name(_ts_decorate13, "_ts_decorate");
2576
+ function _ts_metadata13(k, v) {
2912
2577
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2913
2578
  }
2914
- __name(_ts_metadata14, "_ts_metadata");
2579
+ __name(_ts_metadata13, "_ts_metadata");
2915
2580
  var PROJECT_KEY_PATTERN3 = /^[a-z][a-z0-9-]*$/;
2916
2581
  var LOCALE_PATTERN = /^[a-z]{2}(-[A-Z]{2})?$/;
2917
2582
  var ListMarketingSettingsQueryDto = class {
@@ -2920,12 +2585,12 @@ var ListMarketingSettingsQueryDto = class {
2920
2585
  }
2921
2586
  projectKey;
2922
2587
  };
2923
- _ts_decorate14([
2588
+ _ts_decorate13([
2924
2589
  (0, import_class_validator3.IsString)(),
2925
2590
  (0, import_class_validator3.Matches)(PROJECT_KEY_PATTERN3, {
2926
2591
  message: "projectKey muss kebab-case sein"
2927
2592
  }),
2928
- _ts_metadata14("design:type", String)
2593
+ _ts_metadata13("design:type", String)
2929
2594
  ], ListMarketingSettingsQueryDto.prototype, "projectKey", void 0);
2930
2595
  var UpdateMarketingSettingsDto = class {
2931
2596
  static {
@@ -2934,14 +2599,14 @@ var UpdateMarketingSettingsDto = class {
2934
2599
  projectKey;
2935
2600
  activeLocales;
2936
2601
  };
2937
- _ts_decorate14([
2602
+ _ts_decorate13([
2938
2603
  (0, import_class_validator3.IsString)(),
2939
2604
  (0, import_class_validator3.Matches)(PROJECT_KEY_PATTERN3, {
2940
2605
  message: "projectKey muss kebab-case sein"
2941
2606
  }),
2942
- _ts_metadata14("design:type", String)
2607
+ _ts_metadata13("design:type", String)
2943
2608
  ], UpdateMarketingSettingsDto.prototype, "projectKey", void 0);
2944
- _ts_decorate14([
2609
+ _ts_decorate13([
2945
2610
  (0, import_class_validator3.IsArray)(),
2946
2611
  (0, import_class_validator3.ArrayUnique)(),
2947
2612
  (0, import_class_validator3.IsString)({
@@ -2951,27 +2616,27 @@ _ts_decorate14([
2951
2616
  each: true,
2952
2617
  message: "Locale muss ISO-639-1 sein"
2953
2618
  }),
2954
- _ts_metadata14("design:type", Array)
2619
+ _ts_metadata13("design:type", Array)
2955
2620
  ], UpdateMarketingSettingsDto.prototype, "activeLocales", void 0);
2956
2621
 
2957
2622
  // src/catalog/marketing-settings.controller.ts
2958
- function _ts_decorate15(decorators, target, key, desc) {
2623
+ function _ts_decorate14(decorators, target, key, desc) {
2959
2624
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2960
2625
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
2961
2626
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2962
2627
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2963
2628
  }
2964
- __name(_ts_decorate15, "_ts_decorate");
2965
- function _ts_metadata15(k, v) {
2629
+ __name(_ts_decorate14, "_ts_decorate");
2630
+ function _ts_metadata14(k, v) {
2966
2631
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
2967
2632
  }
2968
- __name(_ts_metadata15, "_ts_metadata");
2969
- function _ts_param12(paramIndex, decorator) {
2633
+ __name(_ts_metadata14, "_ts_metadata");
2634
+ function _ts_param11(paramIndex, decorator) {
2970
2635
  return function(target, key) {
2971
2636
  decorator(target, key, paramIndex);
2972
2637
  };
2973
2638
  }
2974
- __name(_ts_param12, "_ts_param");
2639
+ __name(_ts_param11, "_ts_param");
2975
2640
  function buildMarketingSettingsController(guards) {
2976
2641
  let GeneratedMarketingSettingsController = class GeneratedMarketingSettingsController {
2977
2642
  static {
@@ -2991,30 +2656,30 @@ function buildMarketingSettingsController(guards) {
2991
2656
  });
2992
2657
  }
2993
2658
  };
2994
- _ts_decorate15([
2995
- (0, import_common12.Get)(),
2996
- _ts_param12(0, (0, import_common12.Query)()),
2997
- _ts_metadata15("design:type", Function),
2998
- _ts_metadata15("design:paramtypes", [
2659
+ _ts_decorate14([
2660
+ (0, import_common11.Get)(),
2661
+ _ts_param11(0, (0, import_common11.Query)()),
2662
+ _ts_metadata14("design:type", Function),
2663
+ _ts_metadata14("design:paramtypes", [
2999
2664
  typeof ListMarketingSettingsQueryDto === "undefined" ? Object : ListMarketingSettingsQueryDto
3000
2665
  ]),
3001
- _ts_metadata15("design:returntype", void 0)
2666
+ _ts_metadata14("design:returntype", void 0)
3002
2667
  ], GeneratedMarketingSettingsController.prototype, "get", null);
3003
- _ts_decorate15([
3004
- (0, import_common12.Put)(),
3005
- _ts_param12(0, (0, import_common12.Body)()),
3006
- _ts_metadata15("design:type", Function),
3007
- _ts_metadata15("design:paramtypes", [
2668
+ _ts_decorate14([
2669
+ (0, import_common11.Put)(),
2670
+ _ts_param11(0, (0, import_common11.Body)()),
2671
+ _ts_metadata14("design:type", Function),
2672
+ _ts_metadata14("design:paramtypes", [
3008
2673
  typeof UpdateMarketingSettingsDto === "undefined" ? Object : UpdateMarketingSettingsDto
3009
2674
  ]),
3010
- _ts_metadata15("design:returntype", void 0)
2675
+ _ts_metadata14("design:returntype", void 0)
3011
2676
  ], GeneratedMarketingSettingsController.prototype, "update", null);
3012
- GeneratedMarketingSettingsController = _ts_decorate15([
3013
- (0, import_common12.Controller)("admin/catalog/marketing-settings"),
3014
- (0, import_common12.UseGuards)(...guards),
3015
- _ts_param12(0, (0, import_common12.Inject)(MarketingSettingsService)),
3016
- _ts_metadata15("design:type", Function),
3017
- _ts_metadata15("design:paramtypes", [
2677
+ GeneratedMarketingSettingsController = _ts_decorate14([
2678
+ (0, import_common11.Controller)("admin/catalog/marketing-settings"),
2679
+ (0, import_common11.UseGuards)(...guards),
2680
+ _ts_param11(0, (0, import_common11.Inject)(MarketingSettingsService)),
2681
+ _ts_metadata14("design:type", Function),
2682
+ _ts_metadata14("design:paramtypes", [
3018
2683
  typeof MarketingSettingsService === "undefined" ? Object : MarketingSettingsService
3019
2684
  ])
3020
2685
  ], GeneratedMarketingSettingsController);
@@ -3023,25 +2688,25 @@ function buildMarketingSettingsController(guards) {
3023
2688
  __name(buildMarketingSettingsController, "buildMarketingSettingsController");
3024
2689
 
3025
2690
  // src/catalog/public-marketing-catalog.service.ts
3026
- var import_common13 = require("@nestjs/common");
3027
- var import_types4 = require("@saasicat/types");
3028
- function _ts_decorate16(decorators, target, key, desc) {
2691
+ var import_common12 = require("@nestjs/common");
2692
+ var import_types3 = require("@saasicat/types");
2693
+ function _ts_decorate15(decorators, target, key, desc) {
3029
2694
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3030
2695
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3031
2696
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3032
2697
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3033
2698
  }
3034
- __name(_ts_decorate16, "_ts_decorate");
3035
- function _ts_metadata16(k, v) {
2699
+ __name(_ts_decorate15, "_ts_decorate");
2700
+ function _ts_metadata15(k, v) {
3036
2701
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
3037
2702
  }
3038
- __name(_ts_metadata16, "_ts_metadata");
3039
- function _ts_param13(paramIndex, decorator) {
2703
+ __name(_ts_metadata15, "_ts_metadata");
2704
+ function _ts_param12(paramIndex, decorator) {
3040
2705
  return function(target, key) {
3041
2706
  decorator(target, key, paramIndex);
3042
2707
  };
3043
2708
  }
3044
- __name(_ts_param13, "_ts_param");
2709
+ __name(_ts_param12, "_ts_param");
3045
2710
  var DEFAULT_LOCALE = "de";
3046
2711
  function toNumber(decimal) {
3047
2712
  if (decimal === null) return null;
@@ -3127,7 +2792,7 @@ var PublicMarketingCatalogService = class {
3127
2792
  });
3128
2793
  }
3129
2794
  out.sort((a, b) => b.priority - a.priority);
3130
- const requiresIndex = (0, import_types4.buildFeatureRequiresIndex)([
2795
+ const requiresIndex = (0, import_types3.buildFeatureRequiresIndex)([
3131
2796
  ...labelMeta.features
3132
2797
  ].map(([featureKey, meta]) => ({
3133
2798
  featureKey,
@@ -3181,7 +2846,7 @@ var PublicMarketingCatalogService = class {
3181
2846
  const features = [
3182
2847
  ...bv.features ?? []
3183
2848
  ];
3184
- const requiresFeatures = (0, import_types4.collectUnsatisfiedRequires)(features, requiresIndex);
2849
+ const requiresFeatures = (0, import_types3.collectUnsatisfiedRequires)(features, requiresIndex);
3185
2850
  return {
3186
2851
  bundleKey: bv.bundleKey,
3187
2852
  label: marketing?.displayLabel || bv.label,
@@ -3325,12 +2990,12 @@ var PublicMarketingCatalogService = class {
3325
2990
  };
3326
2991
  }
3327
2992
  resolvePromo(promotions, targetKey, targetType, locale, monthlyNet, yearlyNet, asOf) {
3328
- const monthlyPromo = (0, import_types4.pickActivePromo)(promotions, targetKey, locale, "monthly", asOf, targetType);
3329
- const yearlyPromo = (0, import_types4.pickActivePromo)(promotions, targetKey, locale, "yearly", asOf, targetType);
2993
+ const monthlyPromo = (0, import_types3.pickActivePromo)(promotions, targetKey, locale, "monthly", asOf, targetType);
2994
+ const yearlyPromo = (0, import_types3.pickActivePromo)(promotions, targetKey, locale, "yearly", asOf, targetType);
3330
2995
  const promo = monthlyPromo ?? yearlyPromo;
3331
2996
  if (!promo) return null;
3332
- const monthlyResult = (0, import_types4.applyPromo)(monthlyPromo, monthlyNet);
3333
- const yearlyResult = (0, import_types4.applyPromo)(yearlyPromo, yearlyNet);
2997
+ const monthlyResult = (0, import_types3.applyPromo)(monthlyPromo, monthlyNet);
2998
+ const yearlyResult = (0, import_types3.applyPromo)(yearlyPromo, yearlyNet);
3334
2999
  const i18n = promo.i18n?.[locale] ?? promo.i18n?.[DEFAULT_LOCALE] ?? {};
3335
3000
  return {
3336
3001
  type: promo.type,
@@ -3342,17 +3007,17 @@ var PublicMarketingCatalogService = class {
3342
3007
  };
3343
3008
  }
3344
3009
  };
3345
- PublicMarketingCatalogService = _ts_decorate16([
3346
- (0, import_common13.Injectable)(),
3347
- _ts_param13(0, (0, import_common13.Inject)(PLAN_REPOSITORY_TOKEN)),
3348
- _ts_param13(1, (0, import_common13.Inject)(MARKETING_PROJECTION_REPOSITORY_TOKEN)),
3349
- _ts_param13(2, (0, import_common13.Inject)(PROMOTION_REPOSITORY_TOKEN)),
3350
- _ts_param13(3, (0, import_common13.Optional)()),
3351
- _ts_param13(3, (0, import_common13.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
3352
- _ts_param13(4, (0, import_common13.Optional)()),
3353
- _ts_param13(4, (0, import_common13.Inject)(BUNDLE_REPOSITORY_TOKEN)),
3354
- _ts_metadata16("design:type", Function),
3355
- _ts_metadata16("design:paramtypes", [
3010
+ PublicMarketingCatalogService = _ts_decorate15([
3011
+ (0, import_common12.Injectable)(),
3012
+ _ts_param12(0, (0, import_common12.Inject)(PLAN_REPOSITORY_TOKEN)),
3013
+ _ts_param12(1, (0, import_common12.Inject)(MARKETING_PROJECTION_REPOSITORY_TOKEN)),
3014
+ _ts_param12(2, (0, import_common12.Inject)(PROMOTION_REPOSITORY_TOKEN)),
3015
+ _ts_param12(3, (0, import_common12.Optional)()),
3016
+ _ts_param12(3, (0, import_common12.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
3017
+ _ts_param12(4, (0, import_common12.Optional)()),
3018
+ _ts_param12(4, (0, import_common12.Inject)(BUNDLE_REPOSITORY_TOKEN)),
3019
+ _ts_metadata15("design:type", Function),
3020
+ _ts_metadata15("design:paramtypes", [
3356
3021
  typeof PlanRepository === "undefined" ? Object : PlanRepository,
3357
3022
  typeof MarketingProjectionRepository === "undefined" ? Object : MarketingProjectionRepository,
3358
3023
  typeof PromotionRepository === "undefined" ? Object : PromotionRepository,
@@ -3362,24 +3027,24 @@ PublicMarketingCatalogService = _ts_decorate16([
3362
3027
  ], PublicMarketingCatalogService);
3363
3028
 
3364
3029
  // src/catalog/public-marketing-catalog.controller.ts
3365
- var import_common14 = require("@nestjs/common");
3366
- function _ts_decorate17(decorators, target, key, desc) {
3030
+ var import_common13 = require("@nestjs/common");
3031
+ function _ts_decorate16(decorators, target, key, desc) {
3367
3032
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3368
3033
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3369
3034
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3370
3035
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3371
3036
  }
3372
- __name(_ts_decorate17, "_ts_decorate");
3373
- function _ts_metadata17(k, v) {
3037
+ __name(_ts_decorate16, "_ts_decorate");
3038
+ function _ts_metadata16(k, v) {
3374
3039
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
3375
3040
  }
3376
- __name(_ts_metadata17, "_ts_metadata");
3377
- function _ts_param14(paramIndex, decorator) {
3041
+ __name(_ts_metadata16, "_ts_metadata");
3042
+ function _ts_param13(paramIndex, decorator) {
3378
3043
  return function(target, key) {
3379
3044
  decorator(target, key, paramIndex);
3380
3045
  };
3381
3046
  }
3382
- __name(_ts_param14, "_ts_param");
3047
+ __name(_ts_param13, "_ts_param");
3383
3048
  function buildPublicMarketingCatalogController(guards, projectKey, currency, vatRate) {
3384
3049
  let GeneratedPublicMarketingCatalogController = class GeneratedPublicMarketingCatalogController {
3385
3050
  static {
@@ -3402,25 +3067,25 @@ function buildPublicMarketingCatalogController(guards, projectKey, currency, vat
3402
3067
  return this.service.getCatalog(projectKey, locale, currency, vatRate, asOf);
3403
3068
  }
3404
3069
  };
3405
- _ts_decorate17([
3406
- (0, import_common14.Get)(),
3407
- _ts_param14(0, (0, import_common14.Query)("lang")),
3408
- _ts_param14(1, (0, import_common14.Query)("locale")),
3409
- _ts_param14(2, (0, import_common14.Query)("asOf")),
3410
- _ts_metadata17("design:type", Function),
3411
- _ts_metadata17("design:paramtypes", [
3070
+ _ts_decorate16([
3071
+ (0, import_common13.Get)(),
3072
+ _ts_param13(0, (0, import_common13.Query)("lang")),
3073
+ _ts_param13(1, (0, import_common13.Query)("locale")),
3074
+ _ts_param13(2, (0, import_common13.Query)("asOf")),
3075
+ _ts_metadata16("design:type", Function),
3076
+ _ts_metadata16("design:paramtypes", [
3412
3077
  String,
3413
3078
  String,
3414
3079
  String
3415
3080
  ]),
3416
- _ts_metadata17("design:returntype", void 0)
3081
+ _ts_metadata16("design:returntype", void 0)
3417
3082
  ], GeneratedPublicMarketingCatalogController.prototype, "getCatalog", null);
3418
- GeneratedPublicMarketingCatalogController = _ts_decorate17([
3419
- (0, import_common14.Controller)("public/marketing-catalog"),
3420
- (0, import_common14.UseGuards)(...guards),
3421
- _ts_param14(0, (0, import_common14.Inject)(PublicMarketingCatalogService)),
3422
- _ts_metadata17("design:type", Function),
3423
- _ts_metadata17("design:paramtypes", [
3083
+ GeneratedPublicMarketingCatalogController = _ts_decorate16([
3084
+ (0, import_common13.Controller)("public/marketing-catalog"),
3085
+ (0, import_common13.UseGuards)(...guards),
3086
+ _ts_param13(0, (0, import_common13.Inject)(PublicMarketingCatalogService)),
3087
+ _ts_metadata16("design:type", Function),
3088
+ _ts_metadata16("design:paramtypes", [
3424
3089
  typeof PublicMarketingCatalogService === "undefined" ? Object : PublicMarketingCatalogService
3425
3090
  ])
3426
3091
  ], GeneratedPublicMarketingCatalogController);
@@ -3435,24 +3100,24 @@ function parseAsOf(raw) {
3435
3100
  __name(parseAsOf, "parseAsOf");
3436
3101
 
3437
3102
  // src/catalog/plans.service.ts
3438
- var import_common15 = require("@nestjs/common");
3439
- function _ts_decorate18(decorators, target, key, desc) {
3103
+ var import_common14 = require("@nestjs/common");
3104
+ function _ts_decorate17(decorators, target, key, desc) {
3440
3105
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3441
3106
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3442
3107
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3443
3108
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3444
3109
  }
3445
- __name(_ts_decorate18, "_ts_decorate");
3446
- function _ts_metadata18(k, v) {
3110
+ __name(_ts_decorate17, "_ts_decorate");
3111
+ function _ts_metadata17(k, v) {
3447
3112
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
3448
3113
  }
3449
- __name(_ts_metadata18, "_ts_metadata");
3450
- function _ts_param15(paramIndex, decorator) {
3114
+ __name(_ts_metadata17, "_ts_metadata");
3115
+ function _ts_param14(paramIndex, decorator) {
3451
3116
  return function(target, key) {
3452
3117
  decorator(target, key, paramIndex);
3453
3118
  };
3454
3119
  }
3455
- __name(_ts_param15, "_ts_param");
3120
+ __name(_ts_param14, "_ts_param");
3456
3121
  var PlansService = class {
3457
3122
  static {
3458
3123
  __name(this, "PlansService");
@@ -3482,24 +3147,24 @@ var PlansService = class {
3482
3147
  }
3483
3148
  async getPlan(planId) {
3484
3149
  const plan = await this.repo.findById(planId);
3485
- if (!plan) throw new import_common15.NotFoundException(`Plan '${planId}' nicht gefunden`);
3150
+ if (!plan) throw new import_common14.NotFoundException(`Plan '${planId}' nicht gefunden`);
3486
3151
  return plan;
3487
3152
  }
3488
3153
  async createPlan(data) {
3489
3154
  const existing = await this.repo.findByKey(data.projectKey, data.planKey);
3490
3155
  if (existing) {
3491
- throw new import_common15.UnprocessableEntityException(`Plan '${data.planKey}' existiert bereits in Projekt '${data.projectKey}'`);
3156
+ throw new import_common14.UnprocessableEntityException(`Plan '${data.planKey}' existiert bereits in Projekt '${data.projectKey}'`);
3492
3157
  }
3493
3158
  return this.repo.create(data);
3494
3159
  }
3495
3160
  async updatePlan(planId, data) {
3496
3161
  const existing = await this.repo.findById(planId);
3497
- if (!existing) throw new import_common15.NotFoundException(`Plan '${planId}' nicht gefunden`);
3162
+ if (!existing) throw new import_common14.NotFoundException(`Plan '${planId}' nicht gefunden`);
3498
3163
  return this.repo.update(planId, data);
3499
3164
  }
3500
3165
  async softDeletePlan(planId) {
3501
3166
  const existing = await this.repo.findById(planId);
3502
- if (!existing) throw new import_common15.NotFoundException(`Plan '${planId}' nicht gefunden`);
3167
+ if (!existing) throw new import_common14.NotFoundException(`Plan '${planId}' nicht gefunden`);
3503
3168
  if (existing.deletedAt !== null) return;
3504
3169
  await this.assertNoPublishedVersions(existing.planKey, "soft-delete");
3505
3170
  await this.repo.softDelete(planId);
@@ -3516,11 +3181,11 @@ var PlansService = class {
3516
3181
  */
3517
3182
  async hardDeletePlan(planId) {
3518
3183
  const existing = await this.repo.findById(planId);
3519
- if (!existing) throw new import_common15.NotFoundException(`Plan '${planId}' nicht gefunden`);
3184
+ if (!existing) throw new import_common14.NotFoundException(`Plan '${planId}' nicht gefunden`);
3520
3185
  await this.assertNoPublishedVersions(existing.planKey, "hard-delete");
3521
3186
  await this.assertNoDrafts(existing.planKey);
3522
3187
  if (typeof this.repo.hardDelete !== "function") {
3523
- throw new import_common15.UnprocessableEntityException({
3188
+ throw new import_common14.UnprocessableEntityException({
3524
3189
  code: "PLAN_HARD_DELETE_NOT_IMPLEMENTED",
3525
3190
  message: "Hartes L\xF6schen ist im aktuellen Repository nicht implementiert. Implementiere PlanRepository.hardDelete."
3526
3191
  });
@@ -3541,7 +3206,7 @@ var PlansService = class {
3541
3206
  if (published.length === 0) return;
3542
3207
  const live = published.filter((v) => v.supersededAt === null).length;
3543
3208
  const superseded = published.length - live;
3544
- throw new import_common15.UnprocessableEntityException({
3209
+ throw new import_common14.UnprocessableEntityException({
3545
3210
  code: "PLAN_HAS_PUBLISHED_VERSIONS",
3546
3211
  message: `Plan '${planKey}' kann nicht ${op === "hard-delete" ? "gel\xF6scht" : "archiviert"} werden \u2014 der Plan hat ${published.length} published Version(en) (${live} live, ${superseded} superseded). Bestand-Subscriptions referenzieren diese Versionen (Vertragsschutz P1), der Plan-Stamm muss erhalten bleiben.`,
3547
3212
  publishedCount: published.length,
@@ -3554,45 +3219,45 @@ var PlansService = class {
3554
3219
  const versions = await this.repo.listVersions(planKey);
3555
3220
  const drafts = versions.filter((v) => v.publishedAt === null);
3556
3221
  if (drafts.length === 0) return;
3557
- throw new import_common15.UnprocessableEntityException({
3222
+ throw new import_common14.UnprocessableEntityException({
3558
3223
  code: "PLAN_HAS_DRAFTS",
3559
3224
  message: `Plan '${planKey}' hat noch ${drafts.length} offene Draft-Version(en). Verwerfe sie zuerst (DELETE /admin/catalog/plan-versions/:id) oder publishe sie.`,
3560
3225
  draftCount: drafts.length
3561
3226
  });
3562
3227
  }
3563
3228
  };
3564
- PlansService = _ts_decorate18([
3565
- (0, import_common15.Injectable)(),
3566
- _ts_param15(0, (0, import_common15.Inject)(PLAN_REPOSITORY_TOKEN)),
3567
- _ts_param15(1, (0, import_common15.Optional)()),
3568
- _ts_param15(1, (0, import_common15.Inject)(SUBSCRIPTION_REPOSITORY_TOKEN)),
3569
- _ts_metadata18("design:type", Function),
3570
- _ts_metadata18("design:paramtypes", [
3229
+ PlansService = _ts_decorate17([
3230
+ (0, import_common14.Injectable)(),
3231
+ _ts_param14(0, (0, import_common14.Inject)(PLAN_REPOSITORY_TOKEN)),
3232
+ _ts_param14(1, (0, import_common14.Optional)()),
3233
+ _ts_param14(1, (0, import_common14.Inject)(SUBSCRIPTION_REPOSITORY_TOKEN)),
3234
+ _ts_metadata17("design:type", Function),
3235
+ _ts_metadata17("design:paramtypes", [
3571
3236
  typeof PlanRepository === "undefined" ? Object : PlanRepository,
3572
3237
  Object
3573
3238
  ])
3574
3239
  ], PlansService);
3575
3240
 
3576
3241
  // src/catalog/plan-versions.service.ts
3577
- var import_common16 = require("@nestjs/common");
3578
- var import_types5 = require("@saasicat/types");
3579
- function _ts_decorate19(decorators, target, key, desc) {
3242
+ var import_common15 = require("@nestjs/common");
3243
+ var import_types4 = require("@saasicat/types");
3244
+ function _ts_decorate18(decorators, target, key, desc) {
3580
3245
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3581
3246
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3582
3247
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3583
3248
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3584
3249
  }
3585
- __name(_ts_decorate19, "_ts_decorate");
3586
- function _ts_metadata19(k, v) {
3250
+ __name(_ts_decorate18, "_ts_decorate");
3251
+ function _ts_metadata18(k, v) {
3587
3252
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
3588
3253
  }
3589
- __name(_ts_metadata19, "_ts_metadata");
3590
- function _ts_param16(paramIndex, decorator) {
3254
+ __name(_ts_metadata18, "_ts_metadata");
3255
+ function _ts_param15(paramIndex, decorator) {
3591
3256
  return function(target, key) {
3592
3257
  decorator(target, key, paramIndex);
3593
3258
  };
3594
3259
  }
3595
- __name(_ts_param16, "_ts_param");
3260
+ __name(_ts_param15, "_ts_param");
3596
3261
  var PlanVersionsService = class _PlanVersionsService {
3597
3262
  static {
3598
3263
  __name(this, "PlanVersionsService");
@@ -3602,7 +3267,7 @@ var PlanVersionsService = class _PlanVersionsService {
3602
3267
  subscriptions;
3603
3268
  scanner;
3604
3269
  catalogEntries;
3605
- logger = new import_common16.Logger(_PlanVersionsService.name);
3270
+ logger = new import_common15.Logger(_PlanVersionsService.name);
3606
3271
  mode;
3607
3272
  marketedOnly;
3608
3273
  constructor(repo, snapshot = null, config = {}, subscriptions = null, scanner = null, catalogEntries = null) {
@@ -3644,16 +3309,16 @@ var PlanVersionsService = class _PlanVersionsService {
3644
3309
  async discardPlanDraft(versionId) {
3645
3310
  const existing = await this.repo.findVersionById(versionId);
3646
3311
  if (!existing) {
3647
- throw new import_common16.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3312
+ throw new import_common15.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3648
3313
  }
3649
3314
  if (existing.publishedAt !== null) {
3650
- throw new import_common16.UnprocessableEntityException({
3315
+ throw new import_common15.UnprocessableEntityException({
3651
3316
  code: "PLAN_VERSION_ALREADY_PUBLISHED",
3652
3317
  message: `PlanVersion '${versionId}' ist bereits published und kann nicht verworfen werden.`
3653
3318
  });
3654
3319
  }
3655
3320
  if (typeof this.repo.deletePlanVersionDraft !== "function") {
3656
- throw new import_common16.UnprocessableEntityException({
3321
+ throw new import_common15.UnprocessableEntityException({
3657
3322
  code: "PLAN_VERSION_DISCARD_NOT_IMPLEMENTED",
3658
3323
  message: "Discard ist im aktuellen Repository nicht implementiert. Implementiere PlanRepository.deletePlanVersionDraft."
3659
3324
  });
@@ -3668,7 +3333,7 @@ var PlanVersionsService = class _PlanVersionsService {
3668
3333
  async listPlanVersions(planUuid) {
3669
3334
  const plan = await this.repo.findById(planUuid);
3670
3335
  if (!plan) {
3671
- throw new import_common16.NotFoundException(`Plan '${planUuid}' nicht gefunden`);
3336
+ throw new import_common15.NotFoundException(`Plan '${planUuid}' nicht gefunden`);
3672
3337
  }
3673
3338
  const versions = await this.repo.listVersions(plan.planKey);
3674
3339
  return this.annotateEditability(versions);
@@ -3676,7 +3341,7 @@ var PlanVersionsService = class _PlanVersionsService {
3676
3341
  async getPlanVersion(versionId) {
3677
3342
  const version = await this.repo.findVersionById(versionId);
3678
3343
  if (!version) {
3679
- throw new import_common16.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3344
+ throw new import_common15.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3680
3345
  }
3681
3346
  const [annotated] = await this.annotateEditability([
3682
3347
  version
@@ -3714,12 +3379,12 @@ var PlanVersionsService = class _PlanVersionsService {
3714
3379
  async createPlanDraft(data) {
3715
3380
  const plan = await this.repo.findById(data.planId);
3716
3381
  if (!plan) {
3717
- throw new import_common16.NotFoundException(`Plan '${data.planId}' nicht gefunden`);
3382
+ throw new import_common15.NotFoundException(`Plan '${data.planId}' nicht gefunden`);
3718
3383
  }
3719
3384
  const planKey = plan.planKey;
3720
3385
  const existingDraft = await this.repo.findCurrentDraft(planKey);
3721
3386
  if (existingDraft) {
3722
- throw new import_common16.UnprocessableEntityException(`Plan '${planKey}' hat bereits eine Draft-Version v${existingDraft.version}; bitte erst publishen oder verwerfen`);
3387
+ throw new import_common15.UnprocessableEntityException(`Plan '${planKey}' hat bereits eine Draft-Version v${existingDraft.version}; bitte erst publishen oder verwerfen`);
3723
3388
  }
3724
3389
  let baseVersionId = data.baseVersionId;
3725
3390
  if (baseVersionId === void 0) {
@@ -3744,14 +3409,14 @@ var PlanVersionsService = class _PlanVersionsService {
3744
3409
  async updatePlanDraft(versionId, data) {
3745
3410
  const existing = await this.repo.findVersionById(versionId);
3746
3411
  if (!existing) {
3747
- throw new import_common16.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3412
+ throw new import_common15.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3748
3413
  }
3749
3414
  const [annotated] = await this.annotateEditability([
3750
3415
  existing
3751
3416
  ]);
3752
- const { editable } = (0, import_types5.isVersionEditable)(annotated);
3417
+ const { editable } = (0, import_types4.isVersionEditable)(annotated);
3753
3418
  if (!editable) {
3754
- throw new import_common16.UnprocessableEntityException({
3419
+ throw new import_common15.UnprocessableEntityException({
3755
3420
  code: "PLAN_VERSION_NOT_EDITABLE",
3756
3421
  message: `PlanVersion '${versionId}' ist nicht editierbar. Editierbar sind nur Drafts und published Versionen, die latest-in-chain sind, noch keine Subscription binden und deren validFrom in der Zukunft liegt.`
3757
3422
  });
@@ -3771,10 +3436,10 @@ var PlanVersionsService = class _PlanVersionsService {
3771
3436
  async publishPlanVersion(versionId, publishMeta) {
3772
3437
  const draft = await this.repo.findVersionById(versionId);
3773
3438
  if (!draft) {
3774
- throw new import_common16.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3439
+ throw new import_common15.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3775
3440
  }
3776
3441
  if (draft.publishedAt !== null) {
3777
- throw new import_common16.UnprocessableEntityException(`PlanVersion '${versionId}' ist bereits published`);
3442
+ throw new import_common15.UnprocessableEntityException(`PlanVersion '${versionId}' ist bereits published`);
3778
3443
  }
3779
3444
  const warnings = await this.runStrictCheck({
3780
3445
  features: draft.features,
@@ -3785,7 +3450,7 @@ var PlanVersionsService = class _PlanVersionsService {
3785
3450
  const monthly = Number.parseFloat(String(draft.monthlyNet ?? "0"));
3786
3451
  const yearly = Number.parseFloat(String(draft.yearlyNet ?? "0"));
3787
3452
  if (monthly <= 0 || yearly <= 0) {
3788
- throw new import_common16.UnprocessableEntityException({
3453
+ throw new import_common15.UnprocessableEntityException({
3789
3454
  code: "PLAN_VERSION_ZERO_PRICE",
3790
3455
  message: "PlanVersion kann nicht mit Preis 0,00 published werden (Schutz gegen Seed-Platzhalter). F\xFCr bewusst kostenlose Sondervertr\xE4ge: allowZeroPrice setzen.",
3791
3456
  monthlyNet: String(draft.monthlyNet),
@@ -3796,14 +3461,14 @@ var PlanVersionsService = class _PlanVersionsService {
3796
3461
  const previous = await this.repo.findLatestLivePlanVersion(draft.planId);
3797
3462
  const validFromInput = publishMeta.validFrom ?? draft.validFrom;
3798
3463
  if (!validFromInput) {
3799
- throw new import_common16.UnprocessableEntityException({
3464
+ throw new import_common15.UnprocessableEntityException({
3800
3465
  code: "PLAN_VERSION_VALID_FROM_REQUIRED",
3801
3466
  message: "Beim Publish muss validFrom gesetzt sein (auf Draft oder Publish-Aufruf). SPEC_V2 \xA74.2."
3802
3467
  });
3803
3468
  }
3804
3469
  const validFrom = new Date(validFromInput);
3805
3470
  if (Number.isNaN(validFrom.getTime())) {
3806
- throw new import_common16.UnprocessableEntityException({
3471
+ throw new import_common15.UnprocessableEntityException({
3807
3472
  code: "PLAN_VERSION_VALID_FROM_INVALID",
3808
3473
  message: `validFrom '${validFromInput}' ist kein g\xFCltiges Datum`
3809
3474
  });
@@ -3811,7 +3476,7 @@ var PlanVersionsService = class _PlanVersionsService {
3811
3476
  if (previous?.validFrom) {
3812
3477
  const prevFrom = new Date(previous.validFrom);
3813
3478
  if (validFrom <= prevFrom) {
3814
- throw new import_common16.UnprocessableEntityException({
3479
+ throw new import_common15.UnprocessableEntityException({
3815
3480
  code: "PLAN_VERSION_VALID_FROM_NOT_AFTER_PREVIOUS",
3816
3481
  message: `validFrom (${validFrom.toISOString()}) muss strikt nach validFrom der Vorg\xE4nger-Version (${previous.validFrom}) liegen.`
3817
3482
  });
@@ -3821,7 +3486,7 @@ var PlanVersionsService = class _PlanVersionsService {
3821
3486
  const dayMs = 24 * 60 * 60 * 1e3;
3822
3487
  const requiredStart = new Date(prevUntil.getTime() + dayMs);
3823
3488
  if (validFrom.getTime() !== requiredStart.getTime()) {
3824
- throw new import_common16.UnprocessableEntityException({
3489
+ throw new import_common15.UnprocessableEntityException({
3825
3490
  code: "PLAN_VERSION_VALID_FROM_NOT_GAPLESS",
3826
3491
  message: `Vorg\xE4nger hat validUntil=${previous.validUntil.slice(0, 10)} \u2014 der Nachfolger muss nahtlos am Folgetag (${requiredStart.toISOString().slice(0, 10)}) starten. Geliefert: ${validFrom.toISOString().slice(0, 10)}.`,
3827
3492
  requiredValidFrom: requiredStart.toISOString().slice(0, 10),
@@ -3833,13 +3498,13 @@ var PlanVersionsService = class _PlanVersionsService {
3833
3498
  const validUntilInput = publishMeta.validUntil !== void 0 ? publishMeta.validUntil : draft.validUntil;
3834
3499
  const validUntil = validUntilInput ? new Date(validUntilInput) : null;
3835
3500
  if (validUntil && Number.isNaN(validUntil.getTime())) {
3836
- throw new import_common16.UnprocessableEntityException({
3501
+ throw new import_common15.UnprocessableEntityException({
3837
3502
  code: "PLAN_VERSION_VALID_UNTIL_INVALID",
3838
3503
  message: `validUntil '${validUntilInput}' ist kein g\xFCltiges Datum`
3839
3504
  });
3840
3505
  }
3841
3506
  if (validUntil && validUntil <= validFrom) {
3842
- throw new import_common16.UnprocessableEntityException({
3507
+ throw new import_common15.UnprocessableEntityException({
3843
3508
  code: "PLAN_VERSION_VALID_UNTIL_BEFORE_FROM",
3844
3509
  message: `validUntil (${validUntil.toISOString()}) muss strikt nach validFrom (${validFrom.toISOString()}) liegen.`
3845
3510
  });
@@ -3857,7 +3522,7 @@ var PlanVersionsService = class _PlanVersionsService {
3857
3522
  nonRegressive: true
3858
3523
  };
3859
3524
  if (!diff.nonRegressive && !publishMeta.forceRegressive) {
3860
- throw new import_common16.UnprocessableEntityException({
3525
+ throw new import_common15.UnprocessableEntityException({
3861
3526
  code: "PLAN_VERSION_REGRESSION",
3862
3527
  message: "Diese PlanVersion ist regressiv (Feature entfernt / Quota gesenkt / Preis erh\xF6ht). Publishen erfordert explizites `forceRegressive: true` (UI-Best\xE4tigungsmodal mit MFA).",
3863
3528
  changes: diff.changes
@@ -3894,34 +3559,34 @@ var PlanVersionsService = class _PlanVersionsService {
3894
3559
  async terminatePlanVersion(versionId, endsAt) {
3895
3560
  const existing = await this.repo.findVersionById(versionId);
3896
3561
  if (!existing) {
3897
- throw new import_common16.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3562
+ throw new import_common15.NotFoundException(`PlanVersion '${versionId}' nicht gefunden`);
3898
3563
  }
3899
3564
  if (existing.publishedAt === null) {
3900
- throw new import_common16.UnprocessableEntityException({
3565
+ throw new import_common15.UnprocessableEntityException({
3901
3566
  code: "PLAN_VERSION_NOT_LIVE",
3902
3567
  message: `PlanVersion '${versionId}' ist nicht published und kann nicht terminiert werden.`
3903
3568
  });
3904
3569
  }
3905
3570
  if (existing.supersededAt !== null) {
3906
- throw new import_common16.UnprocessableEntityException({
3571
+ throw new import_common15.UnprocessableEntityException({
3907
3572
  code: "PLAN_VERSION_NOT_LIVE",
3908
3573
  message: `PlanVersion '${versionId}' wurde bereits von einer Nachfolge-Version abgel\xF6st (supersededAt) und kann nicht terminiert werden.`
3909
3574
  });
3910
3575
  }
3911
3576
  if (Number.isNaN(endsAt.getTime())) {
3912
- throw new import_common16.UnprocessableEntityException({
3577
+ throw new import_common15.UnprocessableEntityException({
3913
3578
  code: "PLAN_TERMINATE_INVALID_DATE",
3914
3579
  message: "endsAt ist kein g\xFCltiges Datum."
3915
3580
  });
3916
3581
  }
3917
3582
  if (endsAt.getTime() <= Date.now()) {
3918
- throw new import_common16.UnprocessableEntityException({
3583
+ throw new import_common15.UnprocessableEntityException({
3919
3584
  code: "PLAN_TERMINATE_DATE_NOT_FUTURE",
3920
3585
  message: `endsAt (${endsAt.toISOString()}) muss strikt in der Zukunft liegen.`
3921
3586
  });
3922
3587
  }
3923
3588
  if (typeof this.repo.terminate !== "function") {
3924
- throw new import_common16.UnprocessableEntityException({
3589
+ throw new import_common15.UnprocessableEntityException({
3925
3590
  code: "PLAN_TERMINATE_NOT_IMPLEMENTED",
3926
3591
  message: "Terminate ist im aktuellen Repository nicht implementiert. Implementiere PlanRepository.terminate."
3927
3592
  });
@@ -3940,7 +3605,7 @@ var PlanVersionsService = class _PlanVersionsService {
3940
3605
  gateOrPass(warnings) {
3941
3606
  if (blockingStrictModeWarnings(warnings).length === 0) return;
3942
3607
  if (this.mode === "blocking") {
3943
- throw new import_common16.UnprocessableEntityException({
3608
+ throw new import_common15.UnprocessableEntityException({
3944
3609
  code: "STRICT_MODE_VIOLATIONS",
3945
3610
  message: "Strict-Mode-Check hat Drift gegen den Discovery-Snapshot gefunden.",
3946
3611
  warnings
@@ -3948,21 +3613,21 @@ var PlanVersionsService = class _PlanVersionsService {
3948
3613
  }
3949
3614
  }
3950
3615
  };
3951
- PlanVersionsService = _ts_decorate19([
3952
- (0, import_common16.Injectable)(),
3953
- _ts_param16(0, (0, import_common16.Inject)(PLAN_REPOSITORY_TOKEN)),
3954
- _ts_param16(1, (0, import_common16.Optional)()),
3955
- _ts_param16(1, (0, import_common16.Inject)(DISCOVERY_SNAPSHOT_TOKEN)),
3956
- _ts_param16(2, (0, import_common16.Optional)()),
3957
- _ts_param16(2, (0, import_common16.Inject)(CATALOG_SERVICE_CONFIG_TOKEN)),
3958
- _ts_param16(3, (0, import_common16.Optional)()),
3959
- _ts_param16(3, (0, import_common16.Inject)(SUBSCRIPTION_REPOSITORY_TOKEN)),
3960
- _ts_param16(4, (0, import_common16.Optional)()),
3961
- _ts_param16(4, (0, import_common16.Inject)(DiscoveryScanner)),
3962
- _ts_param16(5, (0, import_common16.Optional)()),
3963
- _ts_param16(5, (0, import_common16.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
3964
- _ts_metadata19("design:type", Function),
3965
- _ts_metadata19("design:paramtypes", [
3616
+ PlanVersionsService = _ts_decorate18([
3617
+ (0, import_common15.Injectable)(),
3618
+ _ts_param15(0, (0, import_common15.Inject)(PLAN_REPOSITORY_TOKEN)),
3619
+ _ts_param15(1, (0, import_common15.Optional)()),
3620
+ _ts_param15(1, (0, import_common15.Inject)(DISCOVERY_SNAPSHOT_TOKEN)),
3621
+ _ts_param15(2, (0, import_common15.Optional)()),
3622
+ _ts_param15(2, (0, import_common15.Inject)(CATALOG_SERVICE_CONFIG_TOKEN)),
3623
+ _ts_param15(3, (0, import_common15.Optional)()),
3624
+ _ts_param15(3, (0, import_common15.Inject)(SUBSCRIPTION_REPOSITORY_TOKEN)),
3625
+ _ts_param15(4, (0, import_common15.Optional)()),
3626
+ _ts_param15(4, (0, import_common15.Inject)(DiscoveryScanner)),
3627
+ _ts_param15(5, (0, import_common15.Optional)()),
3628
+ _ts_param15(5, (0, import_common15.Inject)(CATALOG_ENTRY_REPOSITORY_TOKEN)),
3629
+ _ts_metadata18("design:type", Function),
3630
+ _ts_metadata18("design:paramtypes", [
3966
3631
  typeof PlanRepository === "undefined" ? Object : PlanRepository,
3967
3632
  Object,
3968
3633
  typeof CatalogServiceConfig === "undefined" ? Object : CatalogServiceConfig,
@@ -3973,21 +3638,21 @@ PlanVersionsService = _ts_decorate19([
3973
3638
  ], PlanVersionsService);
3974
3639
 
3975
3640
  // src/catalog/bundles.controller.ts
3976
- var import_common17 = require("@nestjs/common");
3641
+ var import_common16 = require("@nestjs/common");
3977
3642
 
3978
3643
  // src/catalog/dto/bundles.dto.ts
3979
3644
  var import_class_validator4 = require("class-validator");
3980
- function _ts_decorate20(decorators, target, key, desc) {
3645
+ function _ts_decorate19(decorators, target, key, desc) {
3981
3646
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3982
3647
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3983
3648
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3984
3649
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3985
3650
  }
3986
- __name(_ts_decorate20, "_ts_decorate");
3987
- function _ts_metadata20(k, v) {
3651
+ __name(_ts_decorate19, "_ts_decorate");
3652
+ function _ts_metadata19(k, v) {
3988
3653
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
3989
3654
  }
3990
- __name(_ts_metadata20, "_ts_metadata");
3655
+ __name(_ts_metadata19, "_ts_metadata");
3991
3656
  var KEY_PATTERN = /^[A-Z][A-Z0-9_]*$/;
3992
3657
  var FEATURE_KEY_PATTERN = /^[A-Z][A-Z0-9_]*$/;
3993
3658
  var PROJECT_KEY_PATTERN4 = /^[a-z][a-z0-9-]*$/;
@@ -4006,51 +3671,51 @@ var CreateBundleDto = class {
4006
3671
  /** Locale translations { "en": { label, description }, … }. */
4007
3672
  i18n;
4008
3673
  };
4009
- _ts_decorate20([
3674
+ _ts_decorate19([
4010
3675
  (0, import_class_validator4.IsString)(),
4011
3676
  (0, import_class_validator4.Matches)(PROJECT_KEY_PATTERN4, {
4012
3677
  message: 'projectKey muss kebab-case sein (z. B. "my-app")'
4013
3678
  }),
4014
3679
  (0, import_class_validator4.MaxLength)(64),
4015
- _ts_metadata20("design:type", String)
3680
+ _ts_metadata19("design:type", String)
4016
3681
  ], CreateBundleDto.prototype, "projectKey", void 0);
4017
- _ts_decorate20([
3682
+ _ts_decorate19([
4018
3683
  (0, import_class_validator4.IsString)(),
4019
3684
  (0, import_class_validator4.Matches)(KEY_PATTERN, {
4020
3685
  message: 'bundleKey muss SCREAMING_SNAKE_CASE sein (z. B. "BANKING")'
4021
3686
  }),
4022
3687
  (0, import_class_validator4.MaxLength)(64),
4023
- _ts_metadata20("design:type", String)
3688
+ _ts_metadata19("design:type", String)
4024
3689
  ], CreateBundleDto.prototype, "bundleKey", void 0);
4025
- _ts_decorate20([
3690
+ _ts_decorate19([
4026
3691
  (0, import_class_validator4.IsString)(),
4027
3692
  (0, import_class_validator4.MinLength)(1),
4028
3693
  (0, import_class_validator4.MaxLength)(120),
4029
- _ts_metadata20("design:type", String)
3694
+ _ts_metadata19("design:type", String)
4030
3695
  ], CreateBundleDto.prototype, "label", void 0);
4031
- _ts_decorate20([
3696
+ _ts_decorate19([
4032
3697
  (0, import_class_validator4.IsOptional)(),
4033
3698
  (0, import_class_validator4.IsString)(),
4034
3699
  (0, import_class_validator4.MaxLength)(2e3),
4035
- _ts_metadata20("design:type", String)
3700
+ _ts_metadata19("design:type", String)
4036
3701
  ], CreateBundleDto.prototype, "description", void 0);
4037
- _ts_decorate20([
3702
+ _ts_decorate19([
4038
3703
  (0, import_class_validator4.IsOptional)(),
4039
3704
  (0, import_class_validator4.IsString)(),
4040
3705
  (0, import_class_validator4.MaxLength)(64),
4041
- _ts_metadata20("design:type", String)
3706
+ _ts_metadata19("design:type", String)
4042
3707
  ], CreateBundleDto.prototype, "icon", void 0);
4043
- _ts_decorate20([
3708
+ _ts_decorate19([
4044
3709
  (0, import_class_validator4.IsOptional)(),
4045
3710
  (0, import_class_validator4.IsInt)(),
4046
3711
  (0, import_class_validator4.Min)(0),
4047
3712
  (0, import_class_validator4.Max)(1e4),
4048
- _ts_metadata20("design:type", Number)
3713
+ _ts_metadata19("design:type", Number)
4049
3714
  ], CreateBundleDto.prototype, "sortOrder", void 0);
4050
- _ts_decorate20([
3715
+ _ts_decorate19([
4051
3716
  (0, import_class_validator4.IsOptional)(),
4052
3717
  (0, import_class_validator4.IsObject)(),
4053
- _ts_metadata20("design:type", typeof Record === "undefined" ? Object : Record)
3718
+ _ts_metadata19("design:type", typeof Record === "undefined" ? Object : Record)
4054
3719
  ], CreateBundleDto.prototype, "i18n", void 0);
4055
3720
  var UpdateBundleDto = class {
4056
3721
  static {
@@ -4063,36 +3728,36 @@ var UpdateBundleDto = class {
4063
3728
  /** Locale translations { "en": { label, description }, … }. */
4064
3729
  i18n;
4065
3730
  };
4066
- _ts_decorate20([
3731
+ _ts_decorate19([
4067
3732
  (0, import_class_validator4.IsOptional)(),
4068
3733
  (0, import_class_validator4.IsString)(),
4069
3734
  (0, import_class_validator4.MinLength)(1),
4070
3735
  (0, import_class_validator4.MaxLength)(120),
4071
- _ts_metadata20("design:type", String)
3736
+ _ts_metadata19("design:type", String)
4072
3737
  ], UpdateBundleDto.prototype, "label", void 0);
4073
- _ts_decorate20([
3738
+ _ts_decorate19([
4074
3739
  (0, import_class_validator4.IsOptional)(),
4075
3740
  (0, import_class_validator4.IsString)(),
4076
3741
  (0, import_class_validator4.MaxLength)(2e3),
4077
- _ts_metadata20("design:type", Object)
3742
+ _ts_metadata19("design:type", Object)
4078
3743
  ], UpdateBundleDto.prototype, "description", void 0);
4079
- _ts_decorate20([
3744
+ _ts_decorate19([
4080
3745
  (0, import_class_validator4.IsOptional)(),
4081
3746
  (0, import_class_validator4.IsString)(),
4082
3747
  (0, import_class_validator4.MaxLength)(64),
4083
- _ts_metadata20("design:type", Object)
3748
+ _ts_metadata19("design:type", Object)
4084
3749
  ], UpdateBundleDto.prototype, "icon", void 0);
4085
- _ts_decorate20([
3750
+ _ts_decorate19([
4086
3751
  (0, import_class_validator4.IsOptional)(),
4087
3752
  (0, import_class_validator4.IsInt)(),
4088
3753
  (0, import_class_validator4.Min)(0),
4089
3754
  (0, import_class_validator4.Max)(1e4),
4090
- _ts_metadata20("design:type", Number)
3755
+ _ts_metadata19("design:type", Number)
4091
3756
  ], UpdateBundleDto.prototype, "sortOrder", void 0);
4092
- _ts_decorate20([
3757
+ _ts_decorate19([
4093
3758
  (0, import_class_validator4.IsOptional)(),
4094
3759
  (0, import_class_validator4.IsObject)(),
4095
- _ts_metadata20("design:type", typeof Record === "undefined" ? Object : Record)
3760
+ _ts_metadata19("design:type", typeof Record === "undefined" ? Object : Record)
4096
3761
  ], UpdateBundleDto.prototype, "i18n", void 0);
4097
3762
  var CreateBundleVersionDraftDto = class {
4098
3763
  static {
@@ -4110,7 +3775,7 @@ var CreateBundleVersionDraftDto = class {
4110
3775
  validFrom;
4111
3776
  validUntil;
4112
3777
  };
4113
- _ts_decorate20([
3778
+ _ts_decorate19([
4114
3779
  (0, import_class_validator4.IsArray)(),
4115
3780
  (0, import_class_validator4.IsString)({
4116
3781
  each: true
@@ -4119,24 +3784,24 @@ _ts_decorate20([
4119
3784
  each: true,
4120
3785
  message: "features-Eintr\xE4ge m\xFCssen SCREAMING_SNAKE_CASE sein"
4121
3786
  }),
4122
- _ts_metadata20("design:type", Array)
3787
+ _ts_metadata19("design:type", Array)
4123
3788
  ], CreateBundleVersionDraftDto.prototype, "features", void 0);
4124
- _ts_decorate20([
3789
+ _ts_decorate19([
4125
3790
  (0, import_class_validator4.IsOptional)(),
4126
3791
  (0, import_class_validator4.IsObject)(),
4127
- _ts_metadata20("design:type", typeof Record === "undefined" ? Object : Record)
3792
+ _ts_metadata19("design:type", typeof Record === "undefined" ? Object : Record)
4128
3793
  ], CreateBundleVersionDraftDto.prototype, "quotas", void 0);
4129
- _ts_decorate20([
3794
+ _ts_decorate19([
4130
3795
  (0, import_class_validator4.IsOptional)(),
4131
3796
  (0, import_class_validator4.IsObject)(),
4132
- _ts_metadata20("design:type", Object)
3797
+ _ts_metadata19("design:type", Object)
4133
3798
  ], CreateBundleVersionDraftDto.prototype, "compatibility", void 0);
4134
- _ts_decorate20([
3799
+ _ts_decorate19([
4135
3800
  (0, import_class_validator4.IsOptional)(),
4136
3801
  (0, import_class_validator4.IsArray)(),
4137
- _ts_metadata20("design:type", typeof Array === "undefined" ? Object : Array)
3802
+ _ts_metadata19("design:type", typeof Array === "undefined" ? Object : Array)
4138
3803
  ], CreateBundleVersionDraftDto.prototype, "pricingOverrides", void 0);
4139
- _ts_decorate20([
3804
+ _ts_decorate19([
4140
3805
  (0, import_class_validator4.IsOptional)(),
4141
3806
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4142
3807
  (0, import_class_validator4.IsNumberString)({
@@ -4145,9 +3810,9 @@ _ts_decorate20([
4145
3810
  (0, import_class_validator4.Matches)(DECIMAL_PATTERN, {
4146
3811
  message: 'monthlyNet muss Decimal mit max. 2 Nachkommastellen sein (z. B. "9.90")'
4147
3812
  }),
4148
- _ts_metadata20("design:type", Object)
3813
+ _ts_metadata19("design:type", Object)
4149
3814
  ], CreateBundleVersionDraftDto.prototype, "monthlyNet", void 0);
4150
- _ts_decorate20([
3815
+ _ts_decorate19([
4151
3816
  (0, import_class_validator4.IsOptional)(),
4152
3817
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4153
3818
  (0, import_class_validator4.IsNumberString)({
@@ -4156,39 +3821,39 @@ _ts_decorate20([
4156
3821
  (0, import_class_validator4.Matches)(DECIMAL_PATTERN, {
4157
3822
  message: "yearlyNet muss Decimal mit max. 2 Nachkommastellen sein"
4158
3823
  }),
4159
- _ts_metadata20("design:type", Object)
3824
+ _ts_metadata19("design:type", Object)
4160
3825
  ], CreateBundleVersionDraftDto.prototype, "yearlyNet", void 0);
4161
- _ts_decorate20([
3826
+ _ts_decorate19([
4162
3827
  (0, import_class_validator4.IsOptional)(),
4163
3828
  (0, import_class_validator4.IsBoolean)(),
4164
- _ts_metadata20("design:type", Boolean)
3829
+ _ts_metadata19("design:type", Boolean)
4165
3830
  ], CreateBundleVersionDraftDto.prototype, "marketed", void 0);
4166
- _ts_decorate20([
3831
+ _ts_decorate19([
4167
3832
  (0, import_class_validator4.IsOptional)(),
4168
3833
  (0, import_class_validator4.IsString)(),
4169
3834
  (0, import_class_validator4.MaxLength)(2e3),
4170
- _ts_metadata20("design:type", String)
3835
+ _ts_metadata19("design:type", String)
4171
3836
  ], CreateBundleVersionDraftDto.prototype, "changeNote", void 0);
4172
- _ts_decorate20([
3837
+ _ts_decorate19([
4173
3838
  (0, import_class_validator4.IsOptional)(),
4174
3839
  (0, import_class_validator4.IsUUID)(),
4175
- _ts_metadata20("design:type", Object)
3840
+ _ts_metadata19("design:type", Object)
4176
3841
  ], CreateBundleVersionDraftDto.prototype, "baseVersionId", void 0);
4177
- _ts_decorate20([
3842
+ _ts_decorate19([
4178
3843
  (0, import_class_validator4.IsOptional)(),
4179
3844
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4180
3845
  (0, import_class_validator4.Matches)(ISO_DATE_PATTERN2, {
4181
3846
  message: "validFrom muss ISO-Datum sein (YYYY-MM-DD)"
4182
3847
  }),
4183
- _ts_metadata20("design:type", Object)
3848
+ _ts_metadata19("design:type", Object)
4184
3849
  ], CreateBundleVersionDraftDto.prototype, "validFrom", void 0);
4185
- _ts_decorate20([
3850
+ _ts_decorate19([
4186
3851
  (0, import_class_validator4.IsOptional)(),
4187
3852
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4188
3853
  (0, import_class_validator4.Matches)(ISO_DATE_PATTERN2, {
4189
3854
  message: "validUntil muss ISO-Datum sein (YYYY-MM-DD)"
4190
3855
  }),
4191
- _ts_metadata20("design:type", Object)
3856
+ _ts_metadata19("design:type", Object)
4192
3857
  ], CreateBundleVersionDraftDto.prototype, "validUntil", void 0);
4193
3858
  var UpdateBundleVersionDraftDto = class {
4194
3859
  static {
@@ -4205,7 +3870,7 @@ var UpdateBundleVersionDraftDto = class {
4205
3870
  validFrom;
4206
3871
  validUntil;
4207
3872
  };
4208
- _ts_decorate20([
3873
+ _ts_decorate19([
4209
3874
  (0, import_class_validator4.IsOptional)(),
4210
3875
  (0, import_class_validator4.IsArray)(),
4211
3876
  (0, import_class_validator4.IsString)({
@@ -4214,61 +3879,61 @@ _ts_decorate20([
4214
3879
  (0, import_class_validator4.Matches)(FEATURE_KEY_PATTERN, {
4215
3880
  each: true
4216
3881
  }),
4217
- _ts_metadata20("design:type", Array)
3882
+ _ts_metadata19("design:type", Array)
4218
3883
  ], UpdateBundleVersionDraftDto.prototype, "features", void 0);
4219
- _ts_decorate20([
3884
+ _ts_decorate19([
4220
3885
  (0, import_class_validator4.IsOptional)(),
4221
3886
  (0, import_class_validator4.IsObject)(),
4222
- _ts_metadata20("design:type", typeof Record === "undefined" ? Object : Record)
3887
+ _ts_metadata19("design:type", typeof Record === "undefined" ? Object : Record)
4223
3888
  ], UpdateBundleVersionDraftDto.prototype, "quotas", void 0);
4224
- _ts_decorate20([
3889
+ _ts_decorate19([
4225
3890
  (0, import_class_validator4.IsOptional)(),
4226
3891
  (0, import_class_validator4.IsObject)(),
4227
- _ts_metadata20("design:type", Object)
3892
+ _ts_metadata19("design:type", Object)
4228
3893
  ], UpdateBundleVersionDraftDto.prototype, "compatibility", void 0);
4229
- _ts_decorate20([
3894
+ _ts_decorate19([
4230
3895
  (0, import_class_validator4.IsOptional)(),
4231
3896
  (0, import_class_validator4.IsArray)(),
4232
- _ts_metadata20("design:type", typeof Array === "undefined" ? Object : Array)
3897
+ _ts_metadata19("design:type", typeof Array === "undefined" ? Object : Array)
4233
3898
  ], UpdateBundleVersionDraftDto.prototype, "pricingOverrides", void 0);
4234
- _ts_decorate20([
3899
+ _ts_decorate19([
4235
3900
  (0, import_class_validator4.IsOptional)(),
4236
3901
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4237
3902
  (0, import_class_validator4.Matches)(DECIMAL_PATTERN),
4238
- _ts_metadata20("design:type", Object)
3903
+ _ts_metadata19("design:type", Object)
4239
3904
  ], UpdateBundleVersionDraftDto.prototype, "monthlyNet", void 0);
4240
- _ts_decorate20([
3905
+ _ts_decorate19([
4241
3906
  (0, import_class_validator4.IsOptional)(),
4242
3907
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4243
3908
  (0, import_class_validator4.Matches)(DECIMAL_PATTERN),
4244
- _ts_metadata20("design:type", Object)
3909
+ _ts_metadata19("design:type", Object)
4245
3910
  ], UpdateBundleVersionDraftDto.prototype, "yearlyNet", void 0);
4246
- _ts_decorate20([
3911
+ _ts_decorate19([
4247
3912
  (0, import_class_validator4.IsOptional)(),
4248
3913
  (0, import_class_validator4.IsBoolean)(),
4249
- _ts_metadata20("design:type", Boolean)
3914
+ _ts_metadata19("design:type", Boolean)
4250
3915
  ], UpdateBundleVersionDraftDto.prototype, "marketed", void 0);
4251
- _ts_decorate20([
3916
+ _ts_decorate19([
4252
3917
  (0, import_class_validator4.IsOptional)(),
4253
3918
  (0, import_class_validator4.IsString)(),
4254
3919
  (0, import_class_validator4.MaxLength)(2e3),
4255
- _ts_metadata20("design:type", String)
3920
+ _ts_metadata19("design:type", String)
4256
3921
  ], UpdateBundleVersionDraftDto.prototype, "changeNote", void 0);
4257
- _ts_decorate20([
3922
+ _ts_decorate19([
4258
3923
  (0, import_class_validator4.IsOptional)(),
4259
3924
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4260
3925
  (0, import_class_validator4.Matches)(ISO_DATE_PATTERN2, {
4261
3926
  message: "validFrom muss ISO-Datum sein (YYYY-MM-DD)"
4262
3927
  }),
4263
- _ts_metadata20("design:type", Object)
3928
+ _ts_metadata19("design:type", Object)
4264
3929
  ], UpdateBundleVersionDraftDto.prototype, "validFrom", void 0);
4265
- _ts_decorate20([
3930
+ _ts_decorate19([
4266
3931
  (0, import_class_validator4.IsOptional)(),
4267
3932
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4268
3933
  (0, import_class_validator4.Matches)(ISO_DATE_PATTERN2, {
4269
3934
  message: "validUntil muss ISO-Datum sein (YYYY-MM-DD)"
4270
3935
  }),
4271
- _ts_metadata20("design:type", Object)
3936
+ _ts_metadata19("design:type", Object)
4272
3937
  ], UpdateBundleVersionDraftDto.prototype, "validUntil", void 0);
4273
3938
  var PublishBundleVersionDto = class {
4274
3939
  static {
@@ -4289,51 +3954,51 @@ var PublishBundleVersionDto = class {
4289
3954
  validFrom;
4290
3955
  validUntil;
4291
3956
  };
4292
- _ts_decorate20([
3957
+ _ts_decorate19([
4293
3958
  (0, import_class_validator4.IsOptional)(),
4294
3959
  (0, import_class_validator4.IsBoolean)(),
4295
- _ts_metadata20("design:type", Boolean)
3960
+ _ts_metadata19("design:type", Boolean)
4296
3961
  ], PublishBundleVersionDto.prototype, "forceRegressive", void 0);
4297
- _ts_decorate20([
3962
+ _ts_decorate19([
4298
3963
  (0, import_class_validator4.IsOptional)(),
4299
3964
  (0, import_class_validator4.IsBoolean)(),
4300
- _ts_metadata20("design:type", Boolean)
3965
+ _ts_metadata19("design:type", Boolean)
4301
3966
  ], PublishBundleVersionDto.prototype, "allowZeroPrice", void 0);
4302
- _ts_decorate20([
3967
+ _ts_decorate19([
4303
3968
  (0, import_class_validator4.IsOptional)(),
4304
3969
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4305
3970
  (0, import_class_validator4.Matches)(ISO_DATE_PATTERN2, {
4306
3971
  message: "validFrom muss ISO-Datum sein (YYYY-MM-DD)"
4307
3972
  }),
4308
- _ts_metadata20("design:type", Object)
3973
+ _ts_metadata19("design:type", Object)
4309
3974
  ], PublishBundleVersionDto.prototype, "validFrom", void 0);
4310
- _ts_decorate20([
3975
+ _ts_decorate19([
4311
3976
  (0, import_class_validator4.IsOptional)(),
4312
3977
  (0, import_class_validator4.ValidateIf)((_o, value) => value !== null),
4313
3978
  (0, import_class_validator4.Matches)(ISO_DATE_PATTERN2, {
4314
3979
  message: "validUntil muss ISO-Datum sein (YYYY-MM-DD)"
4315
3980
  }),
4316
- _ts_metadata20("design:type", Object)
3981
+ _ts_metadata19("design:type", Object)
4317
3982
  ], PublishBundleVersionDto.prototype, "validUntil", void 0);
4318
3983
 
4319
3984
  // src/catalog/bundles.controller.ts
4320
- function _ts_decorate21(decorators, target, key, desc) {
3985
+ function _ts_decorate20(decorators, target, key, desc) {
4321
3986
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4322
3987
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4323
3988
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4324
3989
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4325
3990
  }
4326
- __name(_ts_decorate21, "_ts_decorate");
4327
- function _ts_metadata21(k, v) {
3991
+ __name(_ts_decorate20, "_ts_decorate");
3992
+ function _ts_metadata20(k, v) {
4328
3993
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
4329
3994
  }
4330
- __name(_ts_metadata21, "_ts_metadata");
4331
- function _ts_param17(paramIndex, decorator) {
3995
+ __name(_ts_metadata20, "_ts_metadata");
3996
+ function _ts_param16(paramIndex, decorator) {
4332
3997
  return function(target, key) {
4333
3998
  decorator(target, key, paramIndex);
4334
3999
  };
4335
4000
  }
4336
- __name(_ts_param17, "_ts_param");
4001
+ __name(_ts_param16, "_ts_param");
4337
4002
  function buildBundlesController(guards) {
4338
4003
  let GeneratedBundlesController = class GeneratedBundlesController {
4339
4004
  static {
@@ -4380,80 +4045,80 @@ function buildBundlesController(guards) {
4380
4045
  });
4381
4046
  }
4382
4047
  };
4383
- _ts_decorate21([
4384
- (0, import_common17.Get)(),
4385
- _ts_param17(0, (0, import_common17.Query)("projectKey")),
4386
- _ts_metadata21("design:type", Function),
4387
- _ts_metadata21("design:paramtypes", [
4048
+ _ts_decorate20([
4049
+ (0, import_common16.Get)(),
4050
+ _ts_param16(0, (0, import_common16.Query)("projectKey")),
4051
+ _ts_metadata20("design:type", Function),
4052
+ _ts_metadata20("design:paramtypes", [
4388
4053
  String
4389
4054
  ]),
4390
- _ts_metadata21("design:returntype", void 0)
4055
+ _ts_metadata20("design:returntype", void 0)
4391
4056
  ], GeneratedBundlesController.prototype, "listBundles", null);
4392
- _ts_decorate21([
4393
- (0, import_common17.Get)(":id"),
4394
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4395
- _ts_metadata21("design:type", Function),
4396
- _ts_metadata21("design:paramtypes", [
4057
+ _ts_decorate20([
4058
+ (0, import_common16.Get)(":id"),
4059
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4060
+ _ts_metadata20("design:type", Function),
4061
+ _ts_metadata20("design:paramtypes", [
4397
4062
  String
4398
4063
  ]),
4399
- _ts_metadata21("design:returntype", void 0)
4064
+ _ts_metadata20("design:returntype", void 0)
4400
4065
  ], GeneratedBundlesController.prototype, "getBundle", null);
4401
- _ts_decorate21([
4402
- (0, import_common17.Post)(),
4403
- _ts_param17(0, (0, import_common17.Body)()),
4404
- _ts_metadata21("design:type", Function),
4405
- _ts_metadata21("design:paramtypes", [
4066
+ _ts_decorate20([
4067
+ (0, import_common16.Post)(),
4068
+ _ts_param16(0, (0, import_common16.Body)()),
4069
+ _ts_metadata20("design:type", Function),
4070
+ _ts_metadata20("design:paramtypes", [
4406
4071
  typeof CreateBundleDto === "undefined" ? Object : CreateBundleDto
4407
4072
  ]),
4408
- _ts_metadata21("design:returntype", void 0)
4073
+ _ts_metadata20("design:returntype", void 0)
4409
4074
  ], GeneratedBundlesController.prototype, "createBundle", null);
4410
- _ts_decorate21([
4411
- (0, import_common17.Patch)(":id"),
4412
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4413
- _ts_param17(1, (0, import_common17.Body)()),
4414
- _ts_metadata21("design:type", Function),
4415
- _ts_metadata21("design:paramtypes", [
4075
+ _ts_decorate20([
4076
+ (0, import_common16.Patch)(":id"),
4077
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4078
+ _ts_param16(1, (0, import_common16.Body)()),
4079
+ _ts_metadata20("design:type", Function),
4080
+ _ts_metadata20("design:paramtypes", [
4416
4081
  String,
4417
4082
  typeof UpdateBundleDto === "undefined" ? Object : UpdateBundleDto
4418
4083
  ]),
4419
- _ts_metadata21("design:returntype", void 0)
4084
+ _ts_metadata20("design:returntype", void 0)
4420
4085
  ], GeneratedBundlesController.prototype, "updateBundle", null);
4421
- _ts_decorate21([
4422
- (0, import_common17.Delete)(":id"),
4423
- (0, import_common17.HttpCode)(import_common17.HttpStatus.NO_CONTENT),
4424
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4425
- _ts_metadata21("design:type", Function),
4426
- _ts_metadata21("design:paramtypes", [
4086
+ _ts_decorate20([
4087
+ (0, import_common16.Delete)(":id"),
4088
+ (0, import_common16.HttpCode)(import_common16.HttpStatus.NO_CONTENT),
4089
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4090
+ _ts_metadata20("design:type", Function),
4091
+ _ts_metadata20("design:paramtypes", [
4427
4092
  String
4428
4093
  ]),
4429
- _ts_metadata21("design:returntype", Promise)
4094
+ _ts_metadata20("design:returntype", Promise)
4430
4095
  ], GeneratedBundlesController.prototype, "softDeleteBundle", null);
4431
- _ts_decorate21([
4432
- (0, import_common17.Get)(":id/versions"),
4433
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4434
- _ts_metadata21("design:type", Function),
4435
- _ts_metadata21("design:paramtypes", [
4096
+ _ts_decorate20([
4097
+ (0, import_common16.Get)(":id/versions"),
4098
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4099
+ _ts_metadata20("design:type", Function),
4100
+ _ts_metadata20("design:paramtypes", [
4436
4101
  String
4437
4102
  ]),
4438
- _ts_metadata21("design:returntype", void 0)
4103
+ _ts_metadata20("design:returntype", void 0)
4439
4104
  ], GeneratedBundlesController.prototype, "listVersions", null);
4440
- _ts_decorate21([
4441
- (0, import_common17.Post)(":id/versions"),
4442
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4443
- _ts_param17(1, (0, import_common17.Body)()),
4444
- _ts_metadata21("design:type", Function),
4445
- _ts_metadata21("design:paramtypes", [
4105
+ _ts_decorate20([
4106
+ (0, import_common16.Post)(":id/versions"),
4107
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4108
+ _ts_param16(1, (0, import_common16.Body)()),
4109
+ _ts_metadata20("design:type", Function),
4110
+ _ts_metadata20("design:paramtypes", [
4446
4111
  String,
4447
4112
  typeof CreateBundleVersionDraftDto === "undefined" ? Object : CreateBundleVersionDraftDto
4448
4113
  ]),
4449
- _ts_metadata21("design:returntype", void 0)
4114
+ _ts_metadata20("design:returntype", void 0)
4450
4115
  ], GeneratedBundlesController.prototype, "createDraft", null);
4451
- GeneratedBundlesController = _ts_decorate21([
4452
- (0, import_common17.Controller)("admin/catalog/bundles"),
4453
- (0, import_common17.UseGuards)(...guards),
4454
- _ts_param17(0, (0, import_common17.Inject)(BundlesService)),
4455
- _ts_metadata21("design:type", Function),
4456
- _ts_metadata21("design:paramtypes", [
4116
+ GeneratedBundlesController = _ts_decorate20([
4117
+ (0, import_common16.Controller)("admin/catalog/bundles"),
4118
+ (0, import_common16.UseGuards)(...guards),
4119
+ _ts_param16(0, (0, import_common16.Inject)(BundlesService)),
4120
+ _ts_metadata20("design:type", Function),
4121
+ _ts_metadata20("design:paramtypes", [
4457
4122
  typeof BundlesService === "undefined" ? Object : BundlesService
4458
4123
  ])
4459
4124
  ], GeneratedBundlesController);
@@ -4488,53 +4153,53 @@ function buildBundleVersionsController(guards) {
4488
4153
  });
4489
4154
  }
4490
4155
  };
4491
- _ts_decorate21([
4492
- (0, import_common17.Get)(":id"),
4493
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4494
- _ts_metadata21("design:type", Function),
4495
- _ts_metadata21("design:paramtypes", [
4156
+ _ts_decorate20([
4157
+ (0, import_common16.Get)(":id"),
4158
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4159
+ _ts_metadata20("design:type", Function),
4160
+ _ts_metadata20("design:paramtypes", [
4496
4161
  String
4497
4162
  ]),
4498
- _ts_metadata21("design:returntype", void 0)
4163
+ _ts_metadata20("design:returntype", void 0)
4499
4164
  ], GeneratedBundleVersionsController.prototype, "getVersion", null);
4500
- _ts_decorate21([
4501
- (0, import_common17.Patch)(":id"),
4502
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4503
- _ts_param17(1, (0, import_common17.Body)()),
4504
- _ts_metadata21("design:type", Function),
4505
- _ts_metadata21("design:paramtypes", [
4165
+ _ts_decorate20([
4166
+ (0, import_common16.Patch)(":id"),
4167
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4168
+ _ts_param16(1, (0, import_common16.Body)()),
4169
+ _ts_metadata20("design:type", Function),
4170
+ _ts_metadata20("design:paramtypes", [
4506
4171
  String,
4507
4172
  typeof UpdateBundleVersionDraftDto === "undefined" ? Object : UpdateBundleVersionDraftDto
4508
4173
  ]),
4509
- _ts_metadata21("design:returntype", void 0)
4174
+ _ts_metadata20("design:returntype", void 0)
4510
4175
  ], GeneratedBundleVersionsController.prototype, "updateDraft", null);
4511
- _ts_decorate21([
4512
- (0, import_common17.Delete)(":id"),
4513
- (0, import_common17.HttpCode)(import_common17.HttpStatus.NO_CONTENT),
4514
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4515
- _ts_metadata21("design:type", Function),
4516
- _ts_metadata21("design:paramtypes", [
4176
+ _ts_decorate20([
4177
+ (0, import_common16.Delete)(":id"),
4178
+ (0, import_common16.HttpCode)(import_common16.HttpStatus.NO_CONTENT),
4179
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4180
+ _ts_metadata20("design:type", Function),
4181
+ _ts_metadata20("design:paramtypes", [
4517
4182
  String
4518
4183
  ]),
4519
- _ts_metadata21("design:returntype", Promise)
4184
+ _ts_metadata20("design:returntype", Promise)
4520
4185
  ], GeneratedBundleVersionsController.prototype, "discardDraft", null);
4521
- _ts_decorate21([
4522
- (0, import_common17.Post)(":id/publish"),
4523
- _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4524
- _ts_param17(1, (0, import_common17.Body)()),
4525
- _ts_metadata21("design:type", Function),
4526
- _ts_metadata21("design:paramtypes", [
4186
+ _ts_decorate20([
4187
+ (0, import_common16.Post)(":id/publish"),
4188
+ _ts_param16(0, (0, import_common16.Param)("id", new import_common16.ParseUUIDPipe())),
4189
+ _ts_param16(1, (0, import_common16.Body)()),
4190
+ _ts_metadata20("design:type", Function),
4191
+ _ts_metadata20("design:paramtypes", [
4527
4192
  String,
4528
4193
  typeof PublishBundleVersionDto === "undefined" ? Object : PublishBundleVersionDto
4529
4194
  ]),
4530
- _ts_metadata21("design:returntype", void 0)
4195
+ _ts_metadata20("design:returntype", void 0)
4531
4196
  ], GeneratedBundleVersionsController.prototype, "publish", null);
4532
- GeneratedBundleVersionsController = _ts_decorate21([
4533
- (0, import_common17.Controller)("admin/catalog/bundle-versions"),
4534
- (0, import_common17.UseGuards)(...guards),
4535
- _ts_param17(0, (0, import_common17.Inject)(BundlesService)),
4536
- _ts_metadata21("design:type", Function),
4537
- _ts_metadata21("design:paramtypes", [
4197
+ GeneratedBundleVersionsController = _ts_decorate20([
4198
+ (0, import_common16.Controller)("admin/catalog/bundle-versions"),
4199
+ (0, import_common16.UseGuards)(...guards),
4200
+ _ts_param16(0, (0, import_common16.Inject)(BundlesService)),
4201
+ _ts_metadata20("design:type", Function),
4202
+ _ts_metadata20("design:paramtypes", [
4538
4203
  typeof BundlesService === "undefined" ? Object : BundlesService
4539
4204
  ])
4540
4205
  ], GeneratedBundleVersionsController);
@@ -4542,504 +4207,55 @@ function buildBundleVersionsController(guards) {
4542
4207
  }
4543
4208
  __name(buildBundleVersionsController, "buildBundleVersionsController");
4544
4209
 
4545
- // src/catalog/business-types.controller.ts
4546
- var import_common18 = require("@nestjs/common");
4210
+ // src/catalog/marketing-projections.controller.ts
4211
+ var import_common17 = require("@nestjs/common");
4547
4212
 
4548
- // src/catalog/dto/business-types.dto.ts
4213
+ // src/catalog/dto/marketing-projections.dto.ts
4549
4214
  var import_class_validator5 = require("class-validator");
4550
4215
  var import_class_transformer = require("class-transformer");
4551
- function _ts_decorate22(decorators, target, key, desc) {
4216
+ function _ts_decorate21(decorators, target, key, desc) {
4552
4217
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4553
4218
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4554
4219
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4555
4220
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4556
4221
  }
4557
- __name(_ts_decorate22, "_ts_decorate");
4558
- function _ts_metadata22(k, v) {
4222
+ __name(_ts_decorate21, "_ts_decorate");
4223
+ function _ts_metadata21(k, v) {
4559
4224
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
4560
4225
  }
4561
- __name(_ts_metadata22, "_ts_metadata");
4562
- var KEY_PATTERN2 = /^[A-Z][A-Z0-9_]*$/;
4226
+ __name(_ts_metadata21, "_ts_metadata");
4563
4227
  var PROJECT_KEY_PATTERN5 = /^[a-z][a-z0-9-]*$/;
4564
- var DECIMAL_PATTERN2 = /^\d+(\.\d{1,2})?$/;
4565
- var CreateBusinessTypeDto = class {
4228
+ var LOCALE_PATTERN2 = /^[a-z]{2}(-[A-Z]{2})?$/;
4229
+ var TARGET_TYPES2 = [
4230
+ "PLAN",
4231
+ "BUNDLE"
4232
+ ];
4233
+ var MarketingTopFeatureDto = class {
4566
4234
  static {
4567
- __name(this, "CreateBusinessTypeDto");
4235
+ __name(this, "MarketingTopFeatureDto");
4568
4236
  }
4569
- projectKey;
4570
- businessTypeKey;
4237
+ /** Optional feature/quota key reference (auto-translation of the label). */
4238
+ key;
4239
+ /** Free text or override; empty + `key` set = auto label. */
4571
4240
  label;
4572
- description;
4573
- icon;
4574
- sortOrder;
4241
+ /** Optional bold addendum — may be empty. */
4242
+ strong;
4575
4243
  };
4576
- _ts_decorate22([
4577
- (0, import_class_validator5.IsString)(),
4578
- (0, import_class_validator5.Matches)(PROJECT_KEY_PATTERN5, {
4579
- message: 'projectKey muss kebab-case sein (z. B. "my-app")'
4580
- }),
4581
- (0, import_class_validator5.MaxLength)(64),
4582
- _ts_metadata22("design:type", String)
4583
- ], CreateBusinessTypeDto.prototype, "projectKey", void 0);
4584
- _ts_decorate22([
4244
+ _ts_decorate21([
4245
+ (0, import_class_validator5.IsOptional)(),
4585
4246
  (0, import_class_validator5.IsString)(),
4586
- (0, import_class_validator5.Matches)(KEY_PATTERN2, {
4587
- message: "businessTypeKey muss SCREAMING_SNAKE_CASE sein"
4588
- }),
4589
- (0, import_class_validator5.MaxLength)(64),
4590
- _ts_metadata22("design:type", String)
4591
- ], CreateBusinessTypeDto.prototype, "businessTypeKey", void 0);
4592
- _ts_decorate22([
4247
+ (0, import_class_validator5.MaxLength)(120),
4248
+ _ts_metadata21("design:type", String)
4249
+ ], MarketingTopFeatureDto.prototype, "key", void 0);
4250
+ _ts_decorate21([
4593
4251
  (0, import_class_validator5.IsString)(),
4594
- (0, import_class_validator5.MinLength)(1),
4595
4252
  (0, import_class_validator5.MaxLength)(120),
4596
- _ts_metadata22("design:type", String)
4597
- ], CreateBusinessTypeDto.prototype, "label", void 0);
4598
- _ts_decorate22([
4599
- (0, import_class_validator5.IsOptional)(),
4253
+ _ts_metadata21("design:type", String)
4254
+ ], MarketingTopFeatureDto.prototype, "label", void 0);
4255
+ _ts_decorate21([
4600
4256
  (0, import_class_validator5.IsString)(),
4601
- (0, import_class_validator5.MaxLength)(2e3),
4602
- _ts_metadata22("design:type", String)
4603
- ], CreateBusinessTypeDto.prototype, "description", void 0);
4604
- _ts_decorate22([
4605
- (0, import_class_validator5.IsOptional)(),
4606
- (0, import_class_validator5.IsString)(),
4607
- (0, import_class_validator5.MaxLength)(64),
4608
- _ts_metadata22("design:type", String)
4609
- ], CreateBusinessTypeDto.prototype, "icon", void 0);
4610
- _ts_decorate22([
4611
- (0, import_class_validator5.IsOptional)(),
4612
- (0, import_class_validator5.IsInt)(),
4613
- (0, import_class_validator5.Min)(0),
4614
- (0, import_class_validator5.Max)(1e4),
4615
- _ts_metadata22("design:type", Number)
4616
- ], CreateBusinessTypeDto.prototype, "sortOrder", void 0);
4617
- var UpdateBusinessTypeDto = class {
4618
- static {
4619
- __name(this, "UpdateBusinessTypeDto");
4620
- }
4621
- label;
4622
- description;
4623
- icon;
4624
- sortOrder;
4625
- };
4626
- _ts_decorate22([
4627
- (0, import_class_validator5.IsOptional)(),
4628
- (0, import_class_validator5.IsString)(),
4629
- (0, import_class_validator5.MinLength)(1),
4630
- (0, import_class_validator5.MaxLength)(120),
4631
- _ts_metadata22("design:type", String)
4632
- ], UpdateBusinessTypeDto.prototype, "label", void 0);
4633
- _ts_decorate22([
4634
- (0, import_class_validator5.IsOptional)(),
4635
- (0, import_class_validator5.IsString)(),
4636
- (0, import_class_validator5.MaxLength)(2e3),
4637
- _ts_metadata22("design:type", Object)
4638
- ], UpdateBusinessTypeDto.prototype, "description", void 0);
4639
- _ts_decorate22([
4640
- (0, import_class_validator5.IsOptional)(),
4641
- (0, import_class_validator5.IsString)(),
4642
- (0, import_class_validator5.MaxLength)(64),
4643
- _ts_metadata22("design:type", Object)
4644
- ], UpdateBusinessTypeDto.prototype, "icon", void 0);
4645
- _ts_decorate22([
4646
- (0, import_class_validator5.IsOptional)(),
4647
- (0, import_class_validator5.IsInt)(),
4648
- (0, import_class_validator5.Min)(0),
4649
- (0, import_class_validator5.Max)(1e4),
4650
- _ts_metadata22("design:type", Number)
4651
- ], UpdateBusinessTypeDto.prototype, "sortOrder", void 0);
4652
- var BusinessTypeBundleInputDto = class {
4653
- static {
4654
- __name(this, "BusinessTypeBundleInputDto");
4655
- }
4656
- bundleVersionId;
4657
- sortOrder;
4658
- };
4659
- _ts_decorate22([
4660
- (0, import_class_validator5.IsUUID)(),
4661
- _ts_metadata22("design:type", String)
4662
- ], BusinessTypeBundleInputDto.prototype, "bundleVersionId", void 0);
4663
- _ts_decorate22([
4664
- (0, import_class_validator5.IsOptional)(),
4665
- (0, import_class_validator5.IsInt)(),
4666
- (0, import_class_validator5.Min)(0),
4667
- (0, import_class_validator5.Max)(1e4),
4668
- _ts_metadata22("design:type", Number)
4669
- ], BusinessTypeBundleInputDto.prototype, "sortOrder", void 0);
4670
- var CreateBusinessTypeVersionDraftDto = class {
4671
- static {
4672
- __name(this, "CreateBusinessTypeVersionDraftDto");
4673
- }
4674
- bundles;
4675
- quotaOverrides;
4676
- monthlyNet;
4677
- yearlyNet;
4678
- marketed;
4679
- changeNote;
4680
- baseVersionId;
4681
- };
4682
- _ts_decorate22([
4683
- (0, import_class_validator5.IsArray)(),
4684
- (0, import_class_validator5.ArrayMinSize)(1, {
4685
- message: "mindestens ein Bundle muss referenziert werden"
4686
- }),
4687
- (0, import_class_validator5.ValidateNested)({
4688
- each: true
4689
- }),
4690
- (0, import_class_transformer.Type)(() => BusinessTypeBundleInputDto),
4691
- _ts_metadata22("design:type", Array)
4692
- ], CreateBusinessTypeVersionDraftDto.prototype, "bundles", void 0);
4693
- _ts_decorate22([
4694
- (0, import_class_validator5.IsOptional)(),
4695
- (0, import_class_validator5.IsObject)(),
4696
- _ts_metadata22("design:type", typeof Record === "undefined" ? Object : Record)
4697
- ], CreateBusinessTypeVersionDraftDto.prototype, "quotaOverrides", void 0);
4698
- _ts_decorate22([
4699
- (0, import_class_validator5.IsOptional)(),
4700
- (0, import_class_validator5.ValidateIf)((_o, value) => value !== null),
4701
- (0, import_class_validator5.Matches)(DECIMAL_PATTERN2, {
4702
- message: "monthlyNet muss Decimal mit max. 2 NK sein"
4703
- }),
4704
- _ts_metadata22("design:type", Object)
4705
- ], CreateBusinessTypeVersionDraftDto.prototype, "monthlyNet", void 0);
4706
- _ts_decorate22([
4707
- (0, import_class_validator5.IsOptional)(),
4708
- (0, import_class_validator5.ValidateIf)((_o, value) => value !== null),
4709
- (0, import_class_validator5.Matches)(DECIMAL_PATTERN2),
4710
- _ts_metadata22("design:type", Object)
4711
- ], CreateBusinessTypeVersionDraftDto.prototype, "yearlyNet", void 0);
4712
- _ts_decorate22([
4713
- (0, import_class_validator5.IsOptional)(),
4714
- (0, import_class_validator5.IsBoolean)(),
4715
- _ts_metadata22("design:type", Boolean)
4716
- ], CreateBusinessTypeVersionDraftDto.prototype, "marketed", void 0);
4717
- _ts_decorate22([
4718
- (0, import_class_validator5.IsOptional)(),
4719
- (0, import_class_validator5.IsString)(),
4720
- (0, import_class_validator5.MaxLength)(2e3),
4721
- _ts_metadata22("design:type", String)
4722
- ], CreateBusinessTypeVersionDraftDto.prototype, "changeNote", void 0);
4723
- _ts_decorate22([
4724
- (0, import_class_validator5.IsOptional)(),
4725
- (0, import_class_validator5.IsUUID)(),
4726
- _ts_metadata22("design:type", Object)
4727
- ], CreateBusinessTypeVersionDraftDto.prototype, "baseVersionId", void 0);
4728
- var UpdateBusinessTypeVersionDraftDto = class {
4729
- static {
4730
- __name(this, "UpdateBusinessTypeVersionDraftDto");
4731
- }
4732
- bundles;
4733
- quotaOverrides;
4734
- monthlyNet;
4735
- yearlyNet;
4736
- marketed;
4737
- changeNote;
4738
- };
4739
- _ts_decorate22([
4740
- (0, import_class_validator5.IsOptional)(),
4741
- (0, import_class_validator5.IsArray)(),
4742
- (0, import_class_validator5.ArrayMinSize)(1),
4743
- (0, import_class_validator5.ValidateNested)({
4744
- each: true
4745
- }),
4746
- (0, import_class_transformer.Type)(() => BusinessTypeBundleInputDto),
4747
- _ts_metadata22("design:type", Array)
4748
- ], UpdateBusinessTypeVersionDraftDto.prototype, "bundles", void 0);
4749
- _ts_decorate22([
4750
- (0, import_class_validator5.IsOptional)(),
4751
- (0, import_class_validator5.IsObject)(),
4752
- _ts_metadata22("design:type", typeof Record === "undefined" ? Object : Record)
4753
- ], UpdateBusinessTypeVersionDraftDto.prototype, "quotaOverrides", void 0);
4754
- _ts_decorate22([
4755
- (0, import_class_validator5.IsOptional)(),
4756
- (0, import_class_validator5.ValidateIf)((_o, value) => value !== null),
4757
- (0, import_class_validator5.Matches)(DECIMAL_PATTERN2),
4758
- _ts_metadata22("design:type", Object)
4759
- ], UpdateBusinessTypeVersionDraftDto.prototype, "monthlyNet", void 0);
4760
- _ts_decorate22([
4761
- (0, import_class_validator5.IsOptional)(),
4762
- (0, import_class_validator5.ValidateIf)((_o, value) => value !== null),
4763
- (0, import_class_validator5.Matches)(DECIMAL_PATTERN2),
4764
- _ts_metadata22("design:type", Object)
4765
- ], UpdateBusinessTypeVersionDraftDto.prototype, "yearlyNet", void 0);
4766
- _ts_decorate22([
4767
- (0, import_class_validator5.IsOptional)(),
4768
- (0, import_class_validator5.IsBoolean)(),
4769
- _ts_metadata22("design:type", Boolean)
4770
- ], UpdateBusinessTypeVersionDraftDto.prototype, "marketed", void 0);
4771
- _ts_decorate22([
4772
- (0, import_class_validator5.IsOptional)(),
4773
- (0, import_class_validator5.IsString)(),
4774
- (0, import_class_validator5.MaxLength)(2e3),
4775
- _ts_metadata22("design:type", String)
4776
- ], UpdateBusinessTypeVersionDraftDto.prototype, "changeNote", void 0);
4777
- var PublishBusinessTypeVersionDto = class {
4778
- static {
4779
- __name(this, "PublishBusinessTypeVersionDto");
4780
- }
4781
- forceRegressive;
4782
- };
4783
- _ts_decorate22([
4784
- (0, import_class_validator5.IsOptional)(),
4785
- (0, import_class_validator5.IsBoolean)(),
4786
- _ts_metadata22("design:type", Boolean)
4787
- ], PublishBusinessTypeVersionDto.prototype, "forceRegressive", void 0);
4788
-
4789
- // src/catalog/business-types.controller.ts
4790
- function _ts_decorate23(decorators, target, key, desc) {
4791
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4792
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4793
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4794
- return c > 3 && r && Object.defineProperty(target, key, r), r;
4795
- }
4796
- __name(_ts_decorate23, "_ts_decorate");
4797
- function _ts_metadata23(k, v) {
4798
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
4799
- }
4800
- __name(_ts_metadata23, "_ts_metadata");
4801
- function _ts_param18(paramIndex, decorator) {
4802
- return function(target, key) {
4803
- decorator(target, key, paramIndex);
4804
- };
4805
- }
4806
- __name(_ts_param18, "_ts_param");
4807
- function buildBusinessTypesController(guards) {
4808
- let GeneratedBusinessTypesController = class GeneratedBusinessTypesController {
4809
- static {
4810
- __name(this, "GeneratedBusinessTypesController");
4811
- }
4812
- service;
4813
- constructor(service) {
4814
- this.service = service;
4815
- }
4816
- listBusinessTypes(projectKey) {
4817
- return this.service.listBusinessTypes(projectKey);
4818
- }
4819
- getBusinessType(businessTypeId) {
4820
- return this.service.getBusinessType(businessTypeId);
4821
- }
4822
- createBusinessType(dto) {
4823
- return this.service.createBusinessType(dto);
4824
- }
4825
- updateBusinessType(businessTypeId, dto) {
4826
- return this.service.updateBusinessType(businessTypeId, dto);
4827
- }
4828
- async softDeleteBusinessType(businessTypeId) {
4829
- await this.service.softDeleteBusinessType(businessTypeId);
4830
- }
4831
- listVersions(businessTypeId) {
4832
- return this.service.listBusinessTypeVersions(businessTypeId);
4833
- }
4834
- createDraft(businessTypeId, dto) {
4835
- return this.service.createBusinessTypeDraft({
4836
- businessTypeId,
4837
- bundles: dto.bundles,
4838
- quotaOverrides: dto.quotaOverrides,
4839
- monthlyNet: dto.monthlyNet,
4840
- yearlyNet: dto.yearlyNet,
4841
- marketed: dto.marketed,
4842
- changeNote: dto.changeNote,
4843
- baseVersionId: dto.baseVersionId
4844
- });
4845
- }
4846
- };
4847
- _ts_decorate23([
4848
- (0, import_common18.Get)(),
4849
- _ts_param18(0, (0, import_common18.Query)("projectKey")),
4850
- _ts_metadata23("design:type", Function),
4851
- _ts_metadata23("design:paramtypes", [
4852
- String
4853
- ]),
4854
- _ts_metadata23("design:returntype", void 0)
4855
- ], GeneratedBusinessTypesController.prototype, "listBusinessTypes", null);
4856
- _ts_decorate23([
4857
- (0, import_common18.Get)(":id"),
4858
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4859
- _ts_metadata23("design:type", Function),
4860
- _ts_metadata23("design:paramtypes", [
4861
- String
4862
- ]),
4863
- _ts_metadata23("design:returntype", void 0)
4864
- ], GeneratedBusinessTypesController.prototype, "getBusinessType", null);
4865
- _ts_decorate23([
4866
- (0, import_common18.Post)(),
4867
- _ts_param18(0, (0, import_common18.Body)()),
4868
- _ts_metadata23("design:type", Function),
4869
- _ts_metadata23("design:paramtypes", [
4870
- typeof CreateBusinessTypeDto === "undefined" ? Object : CreateBusinessTypeDto
4871
- ]),
4872
- _ts_metadata23("design:returntype", void 0)
4873
- ], GeneratedBusinessTypesController.prototype, "createBusinessType", null);
4874
- _ts_decorate23([
4875
- (0, import_common18.Patch)(":id"),
4876
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4877
- _ts_param18(1, (0, import_common18.Body)()),
4878
- _ts_metadata23("design:type", Function),
4879
- _ts_metadata23("design:paramtypes", [
4880
- String,
4881
- typeof UpdateBusinessTypeDto === "undefined" ? Object : UpdateBusinessTypeDto
4882
- ]),
4883
- _ts_metadata23("design:returntype", void 0)
4884
- ], GeneratedBusinessTypesController.prototype, "updateBusinessType", null);
4885
- _ts_decorate23([
4886
- (0, import_common18.Delete)(":id"),
4887
- (0, import_common18.HttpCode)(import_common18.HttpStatus.NO_CONTENT),
4888
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4889
- _ts_metadata23("design:type", Function),
4890
- _ts_metadata23("design:paramtypes", [
4891
- String
4892
- ]),
4893
- _ts_metadata23("design:returntype", Promise)
4894
- ], GeneratedBusinessTypesController.prototype, "softDeleteBusinessType", null);
4895
- _ts_decorate23([
4896
- (0, import_common18.Get)(":id/versions"),
4897
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4898
- _ts_metadata23("design:type", Function),
4899
- _ts_metadata23("design:paramtypes", [
4900
- String
4901
- ]),
4902
- _ts_metadata23("design:returntype", void 0)
4903
- ], GeneratedBusinessTypesController.prototype, "listVersions", null);
4904
- _ts_decorate23([
4905
- (0, import_common18.Post)(":id/versions"),
4906
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4907
- _ts_param18(1, (0, import_common18.Body)()),
4908
- _ts_metadata23("design:type", Function),
4909
- _ts_metadata23("design:paramtypes", [
4910
- String,
4911
- typeof CreateBusinessTypeVersionDraftDto === "undefined" ? Object : CreateBusinessTypeVersionDraftDto
4912
- ]),
4913
- _ts_metadata23("design:returntype", void 0)
4914
- ], GeneratedBusinessTypesController.prototype, "createDraft", null);
4915
- GeneratedBusinessTypesController = _ts_decorate23([
4916
- (0, import_common18.Controller)("admin/catalog/business-types"),
4917
- (0, import_common18.UseGuards)(...guards),
4918
- _ts_param18(0, (0, import_common18.Inject)(BusinessTypesService)),
4919
- _ts_metadata23("design:type", Function),
4920
- _ts_metadata23("design:paramtypes", [
4921
- typeof BusinessTypesService === "undefined" ? Object : BusinessTypesService
4922
- ])
4923
- ], GeneratedBusinessTypesController);
4924
- return GeneratedBusinessTypesController;
4925
- }
4926
- __name(buildBusinessTypesController, "buildBusinessTypesController");
4927
- function buildBusinessTypeVersionsController(guards) {
4928
- let GeneratedBusinessTypeVersionsController = class GeneratedBusinessTypeVersionsController {
4929
- static {
4930
- __name(this, "GeneratedBusinessTypeVersionsController");
4931
- }
4932
- service;
4933
- constructor(service) {
4934
- this.service = service;
4935
- }
4936
- getVersion(versionId) {
4937
- return this.service.getBusinessTypeVersion(versionId);
4938
- }
4939
- updateDraft(versionId, dto) {
4940
- return this.service.updateBusinessTypeDraft(versionId, dto);
4941
- }
4942
- publish(versionId, dto) {
4943
- return this.service.publishBusinessTypeVersion(versionId, {
4944
- publishedByUserId: null,
4945
- forceRegressive: dto.forceRegressive
4946
- });
4947
- }
4948
- };
4949
- _ts_decorate23([
4950
- (0, import_common18.Get)(":id"),
4951
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4952
- _ts_metadata23("design:type", Function),
4953
- _ts_metadata23("design:paramtypes", [
4954
- String
4955
- ]),
4956
- _ts_metadata23("design:returntype", void 0)
4957
- ], GeneratedBusinessTypeVersionsController.prototype, "getVersion", null);
4958
- _ts_decorate23([
4959
- (0, import_common18.Patch)(":id"),
4960
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4961
- _ts_param18(1, (0, import_common18.Body)()),
4962
- _ts_metadata23("design:type", Function),
4963
- _ts_metadata23("design:paramtypes", [
4964
- String,
4965
- typeof UpdateBusinessTypeVersionDraftDto === "undefined" ? Object : UpdateBusinessTypeVersionDraftDto
4966
- ]),
4967
- _ts_metadata23("design:returntype", void 0)
4968
- ], GeneratedBusinessTypeVersionsController.prototype, "updateDraft", null);
4969
- _ts_decorate23([
4970
- (0, import_common18.Post)(":id/publish"),
4971
- _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
4972
- _ts_param18(1, (0, import_common18.Body)()),
4973
- _ts_metadata23("design:type", Function),
4974
- _ts_metadata23("design:paramtypes", [
4975
- String,
4976
- typeof PublishBusinessTypeVersionDto === "undefined" ? Object : PublishBusinessTypeVersionDto
4977
- ]),
4978
- _ts_metadata23("design:returntype", void 0)
4979
- ], GeneratedBusinessTypeVersionsController.prototype, "publish", null);
4980
- GeneratedBusinessTypeVersionsController = _ts_decorate23([
4981
- (0, import_common18.Controller)("admin/catalog/business-type-versions"),
4982
- (0, import_common18.UseGuards)(...guards),
4983
- _ts_param18(0, (0, import_common18.Inject)(BusinessTypesService)),
4984
- _ts_metadata23("design:type", Function),
4985
- _ts_metadata23("design:paramtypes", [
4986
- typeof BusinessTypesService === "undefined" ? Object : BusinessTypesService
4987
- ])
4988
- ], GeneratedBusinessTypeVersionsController);
4989
- return GeneratedBusinessTypeVersionsController;
4990
- }
4991
- __name(buildBusinessTypeVersionsController, "buildBusinessTypeVersionsController");
4992
-
4993
- // src/catalog/marketing-projections.controller.ts
4994
- var import_common19 = require("@nestjs/common");
4995
-
4996
- // src/catalog/dto/marketing-projections.dto.ts
4997
- var import_class_validator6 = require("class-validator");
4998
- var import_class_transformer2 = require("class-transformer");
4999
- function _ts_decorate24(decorators, target, key, desc) {
5000
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5001
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5002
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5003
- return c > 3 && r && Object.defineProperty(target, key, r), r;
5004
- }
5005
- __name(_ts_decorate24, "_ts_decorate");
5006
- function _ts_metadata24(k, v) {
5007
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
5008
- }
5009
- __name(_ts_metadata24, "_ts_metadata");
5010
- var PROJECT_KEY_PATTERN6 = /^[a-z][a-z0-9-]*$/;
5011
- var LOCALE_PATTERN2 = /^[a-z]{2}(-[A-Z]{2})?$/;
5012
- var TARGET_TYPES2 = [
5013
- "PLAN",
5014
- "BUNDLE",
5015
- "BUSINESS_TYPE"
5016
- ];
5017
- var MarketingTopFeatureDto = class {
5018
- static {
5019
- __name(this, "MarketingTopFeatureDto");
5020
- }
5021
- /** Optional feature/quota key reference (auto-translation of the label). */
5022
- key;
5023
- /** Free text or override; empty + `key` set = auto label. */
5024
- label;
5025
- /** Optional bold addendum — may be empty. */
5026
- strong;
5027
- };
5028
- _ts_decorate24([
5029
- (0, import_class_validator6.IsOptional)(),
5030
- (0, import_class_validator6.IsString)(),
5031
- (0, import_class_validator6.MaxLength)(120),
5032
- _ts_metadata24("design:type", String)
5033
- ], MarketingTopFeatureDto.prototype, "key", void 0);
5034
- _ts_decorate24([
5035
- (0, import_class_validator6.IsString)(),
5036
- (0, import_class_validator6.MaxLength)(120),
5037
- _ts_metadata24("design:type", String)
5038
- ], MarketingTopFeatureDto.prototype, "label", void 0);
5039
- _ts_decorate24([
5040
- (0, import_class_validator6.IsString)(),
5041
- (0, import_class_validator6.MaxLength)(80),
5042
- _ts_metadata24("design:type", String)
4257
+ (0, import_class_validator5.MaxLength)(80),
4258
+ _ts_metadata21("design:type", String)
5043
4259
  ], MarketingTopFeatureDto.prototype, "strong", void 0);
5044
4260
  var CreateMarketingProjectionDto = class {
5045
4261
  static {
@@ -5061,98 +4277,98 @@ var CreateMarketingProjectionDto = class {
5061
4277
  priority;
5062
4278
  highlight;
5063
4279
  };
5064
- _ts_decorate24([
5065
- (0, import_class_validator6.IsString)(),
5066
- (0, import_class_validator6.Matches)(PROJECT_KEY_PATTERN6, {
4280
+ _ts_decorate21([
4281
+ (0, import_class_validator5.IsString)(),
4282
+ (0, import_class_validator5.Matches)(PROJECT_KEY_PATTERN5, {
5067
4283
  message: "projectKey muss kebab-case sein"
5068
4284
  }),
5069
- (0, import_class_validator6.MaxLength)(64),
5070
- _ts_metadata24("design:type", String)
4285
+ (0, import_class_validator5.MaxLength)(64),
4286
+ _ts_metadata21("design:type", String)
5071
4287
  ], CreateMarketingProjectionDto.prototype, "projectKey", void 0);
5072
- _ts_decorate24([
5073
- (0, import_class_validator6.IsString)(),
5074
- (0, import_class_validator6.IsIn)(TARGET_TYPES2),
5075
- _ts_metadata24("design:type", String)
4288
+ _ts_decorate21([
4289
+ (0, import_class_validator5.IsString)(),
4290
+ (0, import_class_validator5.IsIn)(TARGET_TYPES2),
4291
+ _ts_metadata21("design:type", String)
5076
4292
  ], CreateMarketingProjectionDto.prototype, "targetType", void 0);
5077
- _ts_decorate24([
5078
- (0, import_class_validator6.IsUUID)(),
5079
- _ts_metadata24("design:type", String)
4293
+ _ts_decorate21([
4294
+ (0, import_class_validator5.IsUUID)(),
4295
+ _ts_metadata21("design:type", String)
5080
4296
  ], CreateMarketingProjectionDto.prototype, "targetVersionId", void 0);
5081
- _ts_decorate24([
5082
- (0, import_class_validator6.IsOptional)(),
5083
- (0, import_class_validator6.IsString)(),
5084
- (0, import_class_validator6.Matches)(LOCALE_PATTERN2, {
4297
+ _ts_decorate21([
4298
+ (0, import_class_validator5.IsOptional)(),
4299
+ (0, import_class_validator5.IsString)(),
4300
+ (0, import_class_validator5.Matches)(LOCALE_PATTERN2, {
5085
4301
  message: 'locale muss ISO-639-1 sein (z. B. "de", "en", "de-AT")'
5086
4302
  }),
5087
- _ts_metadata24("design:type", String)
4303
+ _ts_metadata21("design:type", String)
5088
4304
  ], CreateMarketingProjectionDto.prototype, "locale", void 0);
5089
- _ts_decorate24([
5090
- (0, import_class_validator6.IsString)(),
5091
- (0, import_class_validator6.MinLength)(1),
5092
- (0, import_class_validator6.MaxLength)(120),
5093
- _ts_metadata24("design:type", String)
4305
+ _ts_decorate21([
4306
+ (0, import_class_validator5.IsString)(),
4307
+ (0, import_class_validator5.MinLength)(1),
4308
+ (0, import_class_validator5.MaxLength)(120),
4309
+ _ts_metadata21("design:type", String)
5094
4310
  ], CreateMarketingProjectionDto.prototype, "displayLabel", void 0);
5095
- _ts_decorate24([
5096
- (0, import_class_validator6.IsString)(),
5097
- (0, import_class_validator6.MinLength)(1),
5098
- (0, import_class_validator6.MaxLength)(2e3),
5099
- _ts_metadata24("design:type", String)
4311
+ _ts_decorate21([
4312
+ (0, import_class_validator5.IsString)(),
4313
+ (0, import_class_validator5.MinLength)(1),
4314
+ (0, import_class_validator5.MaxLength)(2e3),
4315
+ _ts_metadata21("design:type", String)
5100
4316
  ], CreateMarketingProjectionDto.prototype, "description", void 0);
5101
- _ts_decorate24([
5102
- (0, import_class_validator6.IsOptional)(),
5103
- (0, import_class_validator6.IsBoolean)(),
5104
- _ts_metadata24("design:type", Boolean)
4317
+ _ts_decorate21([
4318
+ (0, import_class_validator5.IsOptional)(),
4319
+ (0, import_class_validator5.IsBoolean)(),
4320
+ _ts_metadata21("design:type", Boolean)
5105
4321
  ], CreateMarketingProjectionDto.prototype, "visible", void 0);
5106
- _ts_decorate24([
5107
- (0, import_class_validator6.IsOptional)(),
5108
- (0, import_class_validator6.IsString)(),
5109
- (0, import_class_validator6.MaxLength)(40),
5110
- _ts_metadata24("design:type", String)
4322
+ _ts_decorate21([
4323
+ (0, import_class_validator5.IsOptional)(),
4324
+ (0, import_class_validator5.IsString)(),
4325
+ (0, import_class_validator5.MaxLength)(40),
4326
+ _ts_metadata21("design:type", String)
5111
4327
  ], CreateMarketingProjectionDto.prototype, "badge", void 0);
5112
- _ts_decorate24([
5113
- (0, import_class_validator6.IsOptional)(),
5114
- (0, import_class_validator6.IsArray)(),
5115
- (0, import_class_validator6.ValidateNested)({
4328
+ _ts_decorate21([
4329
+ (0, import_class_validator5.IsOptional)(),
4330
+ (0, import_class_validator5.IsArray)(),
4331
+ (0, import_class_validator5.ValidateNested)({
5116
4332
  each: true
5117
4333
  }),
5118
- (0, import_class_transformer2.Type)(() => MarketingTopFeatureDto),
5119
- _ts_metadata24("design:type", Array)
4334
+ (0, import_class_transformer.Type)(() => MarketingTopFeatureDto),
4335
+ _ts_metadata21("design:type", Array)
5120
4336
  ], CreateMarketingProjectionDto.prototype, "topFeatures", void 0);
5121
- _ts_decorate24([
5122
- (0, import_class_validator6.IsOptional)(),
5123
- (0, import_class_validator6.IsBoolean)(),
5124
- _ts_metadata24("design:type", Boolean)
4337
+ _ts_decorate21([
4338
+ (0, import_class_validator5.IsOptional)(),
4339
+ (0, import_class_validator5.IsBoolean)(),
4340
+ _ts_metadata21("design:type", Boolean)
5125
4341
  ], CreateMarketingProjectionDto.prototype, "trialEnabled", void 0);
5126
- _ts_decorate24([
5127
- (0, import_class_validator6.IsOptional)(),
5128
- (0, import_class_validator6.IsInt)(),
5129
- (0, import_class_validator6.Min)(1),
5130
- (0, import_class_validator6.Max)(365),
5131
- _ts_metadata24("design:type", Number)
4342
+ _ts_decorate21([
4343
+ (0, import_class_validator5.IsOptional)(),
4344
+ (0, import_class_validator5.IsInt)(),
4345
+ (0, import_class_validator5.Min)(1),
4346
+ (0, import_class_validator5.Max)(365),
4347
+ _ts_metadata21("design:type", Number)
5132
4348
  ], CreateMarketingProjectionDto.prototype, "trialDays", void 0);
5133
- _ts_decorate24([
5134
- (0, import_class_validator6.IsOptional)(),
5135
- (0, import_class_validator6.IsString)(),
5136
- (0, import_class_validator6.MaxLength)(120),
5137
- _ts_metadata24("design:type", Object)
4349
+ _ts_decorate21([
4350
+ (0, import_class_validator5.IsOptional)(),
4351
+ (0, import_class_validator5.IsString)(),
4352
+ (0, import_class_validator5.MaxLength)(120),
4353
+ _ts_metadata21("design:type", Object)
5138
4354
  ], CreateMarketingProjectionDto.prototype, "priceTag", void 0);
5139
- _ts_decorate24([
5140
- (0, import_class_validator6.IsOptional)(),
5141
- (0, import_class_validator6.IsString)(),
5142
- (0, import_class_validator6.MaxLength)(120),
5143
- _ts_metadata24("design:type", Object)
4355
+ _ts_decorate21([
4356
+ (0, import_class_validator5.IsOptional)(),
4357
+ (0, import_class_validator5.IsString)(),
4358
+ (0, import_class_validator5.MaxLength)(120),
4359
+ _ts_metadata21("design:type", Object)
5144
4360
  ], CreateMarketingProjectionDto.prototype, "ctaLabel", void 0);
5145
- _ts_decorate24([
5146
- (0, import_class_validator6.IsOptional)(),
5147
- (0, import_class_validator6.IsInt)(),
5148
- (0, import_class_validator6.Min)(0),
5149
- (0, import_class_validator6.Max)(1e4),
5150
- _ts_metadata24("design:type", Number)
4361
+ _ts_decorate21([
4362
+ (0, import_class_validator5.IsOptional)(),
4363
+ (0, import_class_validator5.IsInt)(),
4364
+ (0, import_class_validator5.Min)(0),
4365
+ (0, import_class_validator5.Max)(1e4),
4366
+ _ts_metadata21("design:type", Number)
5151
4367
  ], CreateMarketingProjectionDto.prototype, "priority", void 0);
5152
- _ts_decorate24([
5153
- (0, import_class_validator6.IsOptional)(),
5154
- (0, import_class_validator6.IsBoolean)(),
5155
- _ts_metadata24("design:type", Boolean)
4368
+ _ts_decorate21([
4369
+ (0, import_class_validator5.IsOptional)(),
4370
+ (0, import_class_validator5.IsBoolean)(),
4371
+ _ts_metadata21("design:type", Boolean)
5156
4372
  ], CreateMarketingProjectionDto.prototype, "highlight", void 0);
5157
4373
  var UpdateMarketingProjectionDto = class {
5158
4374
  static {
@@ -5170,75 +4386,75 @@ var UpdateMarketingProjectionDto = class {
5170
4386
  priority;
5171
4387
  highlight;
5172
4388
  };
5173
- _ts_decorate24([
5174
- (0, import_class_validator6.IsOptional)(),
5175
- (0, import_class_validator6.IsString)(),
5176
- (0, import_class_validator6.MinLength)(1),
5177
- (0, import_class_validator6.MaxLength)(120),
5178
- _ts_metadata24("design:type", String)
4389
+ _ts_decorate21([
4390
+ (0, import_class_validator5.IsOptional)(),
4391
+ (0, import_class_validator5.IsString)(),
4392
+ (0, import_class_validator5.MinLength)(1),
4393
+ (0, import_class_validator5.MaxLength)(120),
4394
+ _ts_metadata21("design:type", String)
5179
4395
  ], UpdateMarketingProjectionDto.prototype, "displayLabel", void 0);
5180
- _ts_decorate24([
5181
- (0, import_class_validator6.IsOptional)(),
5182
- (0, import_class_validator6.IsString)(),
5183
- (0, import_class_validator6.MinLength)(1),
5184
- (0, import_class_validator6.MaxLength)(2e3),
5185
- _ts_metadata24("design:type", String)
4396
+ _ts_decorate21([
4397
+ (0, import_class_validator5.IsOptional)(),
4398
+ (0, import_class_validator5.IsString)(),
4399
+ (0, import_class_validator5.MinLength)(1),
4400
+ (0, import_class_validator5.MaxLength)(2e3),
4401
+ _ts_metadata21("design:type", String)
5186
4402
  ], UpdateMarketingProjectionDto.prototype, "description", void 0);
5187
- _ts_decorate24([
5188
- (0, import_class_validator6.IsOptional)(),
5189
- (0, import_class_validator6.IsBoolean)(),
5190
- _ts_metadata24("design:type", Boolean)
4403
+ _ts_decorate21([
4404
+ (0, import_class_validator5.IsOptional)(),
4405
+ (0, import_class_validator5.IsBoolean)(),
4406
+ _ts_metadata21("design:type", Boolean)
5191
4407
  ], UpdateMarketingProjectionDto.prototype, "visible", void 0);
5192
- _ts_decorate24([
5193
- (0, import_class_validator6.IsOptional)(),
5194
- (0, import_class_validator6.IsString)(),
5195
- (0, import_class_validator6.MaxLength)(40),
5196
- _ts_metadata24("design:type", String)
4408
+ _ts_decorate21([
4409
+ (0, import_class_validator5.IsOptional)(),
4410
+ (0, import_class_validator5.IsString)(),
4411
+ (0, import_class_validator5.MaxLength)(40),
4412
+ _ts_metadata21("design:type", String)
5197
4413
  ], UpdateMarketingProjectionDto.prototype, "badge", void 0);
5198
- _ts_decorate24([
5199
- (0, import_class_validator6.IsOptional)(),
5200
- (0, import_class_validator6.IsArray)(),
5201
- (0, import_class_validator6.ValidateNested)({
4414
+ _ts_decorate21([
4415
+ (0, import_class_validator5.IsOptional)(),
4416
+ (0, import_class_validator5.IsArray)(),
4417
+ (0, import_class_validator5.ValidateNested)({
5202
4418
  each: true
5203
4419
  }),
5204
- (0, import_class_transformer2.Type)(() => MarketingTopFeatureDto),
5205
- _ts_metadata24("design:type", Array)
4420
+ (0, import_class_transformer.Type)(() => MarketingTopFeatureDto),
4421
+ _ts_metadata21("design:type", Array)
5206
4422
  ], UpdateMarketingProjectionDto.prototype, "topFeatures", void 0);
5207
- _ts_decorate24([
5208
- (0, import_class_validator6.IsOptional)(),
5209
- (0, import_class_validator6.IsBoolean)(),
5210
- _ts_metadata24("design:type", Boolean)
4423
+ _ts_decorate21([
4424
+ (0, import_class_validator5.IsOptional)(),
4425
+ (0, import_class_validator5.IsBoolean)(),
4426
+ _ts_metadata21("design:type", Boolean)
5211
4427
  ], UpdateMarketingProjectionDto.prototype, "trialEnabled", void 0);
5212
- _ts_decorate24([
5213
- (0, import_class_validator6.IsOptional)(),
5214
- (0, import_class_validator6.IsInt)(),
5215
- (0, import_class_validator6.Min)(1),
5216
- (0, import_class_validator6.Max)(365),
5217
- _ts_metadata24("design:type", Number)
4428
+ _ts_decorate21([
4429
+ (0, import_class_validator5.IsOptional)(),
4430
+ (0, import_class_validator5.IsInt)(),
4431
+ (0, import_class_validator5.Min)(1),
4432
+ (0, import_class_validator5.Max)(365),
4433
+ _ts_metadata21("design:type", Number)
5218
4434
  ], UpdateMarketingProjectionDto.prototype, "trialDays", void 0);
5219
- _ts_decorate24([
5220
- (0, import_class_validator6.IsOptional)(),
5221
- (0, import_class_validator6.IsString)(),
5222
- (0, import_class_validator6.MaxLength)(120),
5223
- _ts_metadata24("design:type", Object)
4435
+ _ts_decorate21([
4436
+ (0, import_class_validator5.IsOptional)(),
4437
+ (0, import_class_validator5.IsString)(),
4438
+ (0, import_class_validator5.MaxLength)(120),
4439
+ _ts_metadata21("design:type", Object)
5224
4440
  ], UpdateMarketingProjectionDto.prototype, "priceTag", void 0);
5225
- _ts_decorate24([
5226
- (0, import_class_validator6.IsOptional)(),
5227
- (0, import_class_validator6.IsString)(),
5228
- (0, import_class_validator6.MaxLength)(120),
5229
- _ts_metadata24("design:type", Object)
4441
+ _ts_decorate21([
4442
+ (0, import_class_validator5.IsOptional)(),
4443
+ (0, import_class_validator5.IsString)(),
4444
+ (0, import_class_validator5.MaxLength)(120),
4445
+ _ts_metadata21("design:type", Object)
5230
4446
  ], UpdateMarketingProjectionDto.prototype, "ctaLabel", void 0);
5231
- _ts_decorate24([
5232
- (0, import_class_validator6.IsOptional)(),
5233
- (0, import_class_validator6.IsInt)(),
5234
- (0, import_class_validator6.Min)(0),
5235
- (0, import_class_validator6.Max)(1e4),
5236
- _ts_metadata24("design:type", Number)
4447
+ _ts_decorate21([
4448
+ (0, import_class_validator5.IsOptional)(),
4449
+ (0, import_class_validator5.IsInt)(),
4450
+ (0, import_class_validator5.Min)(0),
4451
+ (0, import_class_validator5.Max)(1e4),
4452
+ _ts_metadata21("design:type", Number)
5237
4453
  ], UpdateMarketingProjectionDto.prototype, "priority", void 0);
5238
- _ts_decorate24([
5239
- (0, import_class_validator6.IsOptional)(),
5240
- (0, import_class_validator6.IsBoolean)(),
5241
- _ts_metadata24("design:type", Boolean)
4454
+ _ts_decorate21([
4455
+ (0, import_class_validator5.IsOptional)(),
4456
+ (0, import_class_validator5.IsBoolean)(),
4457
+ _ts_metadata21("design:type", Boolean)
5242
4458
  ], UpdateMarketingProjectionDto.prototype, "highlight", void 0);
5243
4459
  var ListMarketingProjectionsQueryDto = class {
5244
4460
  static {
@@ -5249,47 +4465,47 @@ var ListMarketingProjectionsQueryDto = class {
5249
4465
  targetVersionId;
5250
4466
  locale;
5251
4467
  };
5252
- _ts_decorate24([
5253
- (0, import_class_validator6.IsString)(),
5254
- (0, import_class_validator6.Matches)(PROJECT_KEY_PATTERN6),
5255
- _ts_metadata24("design:type", String)
4468
+ _ts_decorate21([
4469
+ (0, import_class_validator5.IsString)(),
4470
+ (0, import_class_validator5.Matches)(PROJECT_KEY_PATTERN5),
4471
+ _ts_metadata21("design:type", String)
5256
4472
  ], ListMarketingProjectionsQueryDto.prototype, "projectKey", void 0);
5257
- _ts_decorate24([
5258
- (0, import_class_validator6.IsOptional)(),
5259
- (0, import_class_validator6.IsString)(),
5260
- (0, import_class_validator6.IsIn)(TARGET_TYPES2),
5261
- _ts_metadata24("design:type", String)
4473
+ _ts_decorate21([
4474
+ (0, import_class_validator5.IsOptional)(),
4475
+ (0, import_class_validator5.IsString)(),
4476
+ (0, import_class_validator5.IsIn)(TARGET_TYPES2),
4477
+ _ts_metadata21("design:type", String)
5262
4478
  ], ListMarketingProjectionsQueryDto.prototype, "targetType", void 0);
5263
- _ts_decorate24([
5264
- (0, import_class_validator6.IsOptional)(),
5265
- (0, import_class_validator6.IsUUID)(),
5266
- _ts_metadata24("design:type", String)
4479
+ _ts_decorate21([
4480
+ (0, import_class_validator5.IsOptional)(),
4481
+ (0, import_class_validator5.IsUUID)(),
4482
+ _ts_metadata21("design:type", String)
5267
4483
  ], ListMarketingProjectionsQueryDto.prototype, "targetVersionId", void 0);
5268
- _ts_decorate24([
5269
- (0, import_class_validator6.IsOptional)(),
5270
- (0, import_class_validator6.IsString)(),
5271
- (0, import_class_validator6.Matches)(LOCALE_PATTERN2),
5272
- _ts_metadata24("design:type", String)
4484
+ _ts_decorate21([
4485
+ (0, import_class_validator5.IsOptional)(),
4486
+ (0, import_class_validator5.IsString)(),
4487
+ (0, import_class_validator5.Matches)(LOCALE_PATTERN2),
4488
+ _ts_metadata21("design:type", String)
5273
4489
  ], ListMarketingProjectionsQueryDto.prototype, "locale", void 0);
5274
4490
 
5275
4491
  // src/catalog/marketing-projections.controller.ts
5276
- function _ts_decorate25(decorators, target, key, desc) {
4492
+ function _ts_decorate22(decorators, target, key, desc) {
5277
4493
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5278
4494
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5279
4495
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5280
4496
  return c > 3 && r && Object.defineProperty(target, key, r), r;
5281
4497
  }
5282
- __name(_ts_decorate25, "_ts_decorate");
5283
- function _ts_metadata25(k, v) {
4498
+ __name(_ts_decorate22, "_ts_decorate");
4499
+ function _ts_metadata22(k, v) {
5284
4500
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
5285
4501
  }
5286
- __name(_ts_metadata25, "_ts_metadata");
5287
- function _ts_param19(paramIndex, decorator) {
4502
+ __name(_ts_metadata22, "_ts_metadata");
4503
+ function _ts_param17(paramIndex, decorator) {
5288
4504
  return function(target, key) {
5289
4505
  decorator(target, key, paramIndex);
5290
4506
  };
5291
4507
  }
5292
- __name(_ts_param19, "_ts_param");
4508
+ __name(_ts_param17, "_ts_param");
5293
4509
  function buildMarketingProjectionsController(guards) {
5294
4510
  let GeneratedMarketingProjectionsController = class GeneratedMarketingProjectionsController {
5295
4511
  static {
@@ -5320,60 +4536,60 @@ function buildMarketingProjectionsController(guards) {
5320
4536
  await this.service.delete(id);
5321
4537
  }
5322
4538
  };
5323
- _ts_decorate25([
5324
- (0, import_common19.Get)(),
5325
- _ts_param19(0, (0, import_common19.Query)()),
5326
- _ts_metadata25("design:type", Function),
5327
- _ts_metadata25("design:paramtypes", [
4539
+ _ts_decorate22([
4540
+ (0, import_common17.Get)(),
4541
+ _ts_param17(0, (0, import_common17.Query)()),
4542
+ _ts_metadata22("design:type", Function),
4543
+ _ts_metadata22("design:paramtypes", [
5328
4544
  typeof ListMarketingProjectionsQueryDto === "undefined" ? Object : ListMarketingProjectionsQueryDto
5329
4545
  ]),
5330
- _ts_metadata25("design:returntype", void 0)
4546
+ _ts_metadata22("design:returntype", void 0)
5331
4547
  ], GeneratedMarketingProjectionsController.prototype, "list", null);
5332
- _ts_decorate25([
5333
- (0, import_common19.Get)(":id"),
5334
- _ts_param19(0, (0, import_common19.Param)("id", new import_common19.ParseUUIDPipe())),
5335
- _ts_metadata25("design:type", Function),
5336
- _ts_metadata25("design:paramtypes", [
4548
+ _ts_decorate22([
4549
+ (0, import_common17.Get)(":id"),
4550
+ _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4551
+ _ts_metadata22("design:type", Function),
4552
+ _ts_metadata22("design:paramtypes", [
5337
4553
  String
5338
4554
  ]),
5339
- _ts_metadata25("design:returntype", void 0)
4555
+ _ts_metadata22("design:returntype", void 0)
5340
4556
  ], GeneratedMarketingProjectionsController.prototype, "getById", null);
5341
- _ts_decorate25([
5342
- (0, import_common19.Post)(),
5343
- _ts_param19(0, (0, import_common19.Body)()),
5344
- _ts_metadata25("design:type", Function),
5345
- _ts_metadata25("design:paramtypes", [
4557
+ _ts_decorate22([
4558
+ (0, import_common17.Post)(),
4559
+ _ts_param17(0, (0, import_common17.Body)()),
4560
+ _ts_metadata22("design:type", Function),
4561
+ _ts_metadata22("design:paramtypes", [
5346
4562
  typeof CreateMarketingProjectionDto === "undefined" ? Object : CreateMarketingProjectionDto
5347
4563
  ]),
5348
- _ts_metadata25("design:returntype", void 0)
4564
+ _ts_metadata22("design:returntype", void 0)
5349
4565
  ], GeneratedMarketingProjectionsController.prototype, "create", null);
5350
- _ts_decorate25([
5351
- (0, import_common19.Patch)(":id"),
5352
- _ts_param19(0, (0, import_common19.Param)("id", new import_common19.ParseUUIDPipe())),
5353
- _ts_param19(1, (0, import_common19.Body)()),
5354
- _ts_metadata25("design:type", Function),
5355
- _ts_metadata25("design:paramtypes", [
4566
+ _ts_decorate22([
4567
+ (0, import_common17.Patch)(":id"),
4568
+ _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4569
+ _ts_param17(1, (0, import_common17.Body)()),
4570
+ _ts_metadata22("design:type", Function),
4571
+ _ts_metadata22("design:paramtypes", [
5356
4572
  String,
5357
4573
  typeof UpdateMarketingProjectionDto === "undefined" ? Object : UpdateMarketingProjectionDto
5358
4574
  ]),
5359
- _ts_metadata25("design:returntype", void 0)
5360
- ], GeneratedMarketingProjectionsController.prototype, "update", null);
5361
- _ts_decorate25([
5362
- (0, import_common19.Delete)(":id"),
5363
- (0, import_common19.HttpCode)(import_common19.HttpStatus.NO_CONTENT),
5364
- _ts_param19(0, (0, import_common19.Param)("id", new import_common19.ParseUUIDPipe())),
5365
- _ts_metadata25("design:type", Function),
5366
- _ts_metadata25("design:paramtypes", [
4575
+ _ts_metadata22("design:returntype", void 0)
4576
+ ], GeneratedMarketingProjectionsController.prototype, "update", null);
4577
+ _ts_decorate22([
4578
+ (0, import_common17.Delete)(":id"),
4579
+ (0, import_common17.HttpCode)(import_common17.HttpStatus.NO_CONTENT),
4580
+ _ts_param17(0, (0, import_common17.Param)("id", new import_common17.ParseUUIDPipe())),
4581
+ _ts_metadata22("design:type", Function),
4582
+ _ts_metadata22("design:paramtypes", [
5367
4583
  String
5368
4584
  ]),
5369
- _ts_metadata25("design:returntype", Promise)
4585
+ _ts_metadata22("design:returntype", Promise)
5370
4586
  ], GeneratedMarketingProjectionsController.prototype, "delete", null);
5371
- GeneratedMarketingProjectionsController = _ts_decorate25([
5372
- (0, import_common19.Controller)("admin/catalog/marketing-projections"),
5373
- (0, import_common19.UseGuards)(...guards),
5374
- _ts_param19(0, (0, import_common19.Inject)(MarketingProjectionsService)),
5375
- _ts_metadata25("design:type", Function),
5376
- _ts_metadata25("design:paramtypes", [
4587
+ GeneratedMarketingProjectionsController = _ts_decorate22([
4588
+ (0, import_common17.Controller)("admin/catalog/marketing-projections"),
4589
+ (0, import_common17.UseGuards)(...guards),
4590
+ _ts_param17(0, (0, import_common17.Inject)(MarketingProjectionsService)),
4591
+ _ts_metadata22("design:type", Function),
4592
+ _ts_metadata22("design:paramtypes", [
5377
4593
  typeof MarketingProjectionsService === "undefined" ? Object : MarketingProjectionsService
5378
4594
  ])
5379
4595
  ], GeneratedMarketingProjectionsController);
@@ -5382,23 +4598,23 @@ function buildMarketingProjectionsController(guards) {
5382
4598
  __name(buildMarketingProjectionsController, "buildMarketingProjectionsController");
5383
4599
 
5384
4600
  // src/catalog/plans.controller.ts
5385
- var import_common20 = require("@nestjs/common");
4601
+ var import_common18 = require("@nestjs/common");
5386
4602
 
5387
4603
  // src/catalog/dto/plans.dto.ts
5388
- var import_class_validator7 = require("class-validator");
5389
- function _ts_decorate26(decorators, target, key, desc) {
4604
+ var import_class_validator6 = require("class-validator");
4605
+ function _ts_decorate23(decorators, target, key, desc) {
5390
4606
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5391
4607
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5392
4608
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5393
4609
  return c > 3 && r && Object.defineProperty(target, key, r), r;
5394
4610
  }
5395
- __name(_ts_decorate26, "_ts_decorate");
5396
- function _ts_metadata26(k, v) {
4611
+ __name(_ts_decorate23, "_ts_decorate");
4612
+ function _ts_metadata23(k, v) {
5397
4613
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
5398
4614
  }
5399
- __name(_ts_metadata26, "_ts_metadata");
5400
- var KEY_PATTERN3 = /^[A-Z][A-Z0-9_]*$/;
5401
- var PROJECT_KEY_PATTERN7 = /^[a-z][a-z0-9-]*$/;
4615
+ __name(_ts_metadata23, "_ts_metadata");
4616
+ var KEY_PATTERN2 = /^[A-Z][A-Z0-9_]*$/;
4617
+ var PROJECT_KEY_PATTERN6 = /^[a-z][a-z0-9-]*$/;
5402
4618
  var CreatePlanDto = class {
5403
4619
  static {
5404
4620
  __name(this, "CreatePlanDto");
@@ -5410,46 +4626,46 @@ var CreatePlanDto = class {
5410
4626
  icon;
5411
4627
  sortOrder;
5412
4628
  };
5413
- _ts_decorate26([
5414
- (0, import_class_validator7.IsString)(),
5415
- (0, import_class_validator7.Matches)(PROJECT_KEY_PATTERN7, {
4629
+ _ts_decorate23([
4630
+ (0, import_class_validator6.IsString)(),
4631
+ (0, import_class_validator6.Matches)(PROJECT_KEY_PATTERN6, {
5416
4632
  message: 'projectKey muss kebab-case sein (z. B. "my-app")'
5417
4633
  }),
5418
- (0, import_class_validator7.MaxLength)(64),
5419
- _ts_metadata26("design:type", String)
4634
+ (0, import_class_validator6.MaxLength)(64),
4635
+ _ts_metadata23("design:type", String)
5420
4636
  ], CreatePlanDto.prototype, "projectKey", void 0);
5421
- _ts_decorate26([
5422
- (0, import_class_validator7.IsString)(),
5423
- (0, import_class_validator7.Matches)(KEY_PATTERN3, {
4637
+ _ts_decorate23([
4638
+ (0, import_class_validator6.IsString)(),
4639
+ (0, import_class_validator6.Matches)(KEY_PATTERN2, {
5424
4640
  message: 'planKey muss SCREAMING_SNAKE_CASE sein (z. B. "STARTER")'
5425
4641
  }),
5426
- (0, import_class_validator7.MaxLength)(64),
5427
- _ts_metadata26("design:type", String)
4642
+ (0, import_class_validator6.MaxLength)(64),
4643
+ _ts_metadata23("design:type", String)
5428
4644
  ], CreatePlanDto.prototype, "planKey", void 0);
5429
- _ts_decorate26([
5430
- (0, import_class_validator7.IsString)(),
5431
- (0, import_class_validator7.MinLength)(1),
5432
- (0, import_class_validator7.MaxLength)(120),
5433
- _ts_metadata26("design:type", String)
4645
+ _ts_decorate23([
4646
+ (0, import_class_validator6.IsString)(),
4647
+ (0, import_class_validator6.MinLength)(1),
4648
+ (0, import_class_validator6.MaxLength)(120),
4649
+ _ts_metadata23("design:type", String)
5434
4650
  ], CreatePlanDto.prototype, "label", void 0);
5435
- _ts_decorate26([
5436
- (0, import_class_validator7.IsOptional)(),
5437
- (0, import_class_validator7.IsString)(),
5438
- (0, import_class_validator7.MaxLength)(2e3),
5439
- _ts_metadata26("design:type", String)
4651
+ _ts_decorate23([
4652
+ (0, import_class_validator6.IsOptional)(),
4653
+ (0, import_class_validator6.IsString)(),
4654
+ (0, import_class_validator6.MaxLength)(2e3),
4655
+ _ts_metadata23("design:type", String)
5440
4656
  ], CreatePlanDto.prototype, "description", void 0);
5441
- _ts_decorate26([
5442
- (0, import_class_validator7.IsOptional)(),
5443
- (0, import_class_validator7.IsString)(),
5444
- (0, import_class_validator7.MaxLength)(64),
5445
- _ts_metadata26("design:type", String)
4657
+ _ts_decorate23([
4658
+ (0, import_class_validator6.IsOptional)(),
4659
+ (0, import_class_validator6.IsString)(),
4660
+ (0, import_class_validator6.MaxLength)(64),
4661
+ _ts_metadata23("design:type", String)
5446
4662
  ], CreatePlanDto.prototype, "icon", void 0);
5447
- _ts_decorate26([
5448
- (0, import_class_validator7.IsOptional)(),
5449
- (0, import_class_validator7.IsInt)(),
5450
- (0, import_class_validator7.Min)(0),
5451
- (0, import_class_validator7.Max)(1e4),
5452
- _ts_metadata26("design:type", Number)
4663
+ _ts_decorate23([
4664
+ (0, import_class_validator6.IsOptional)(),
4665
+ (0, import_class_validator6.IsInt)(),
4666
+ (0, import_class_validator6.Min)(0),
4667
+ (0, import_class_validator6.Max)(1e4),
4668
+ _ts_metadata23("design:type", Number)
5453
4669
  ], CreatePlanDto.prototype, "sortOrder", void 0);
5454
4670
  var UpdatePlanDto = class {
5455
4671
  static {
@@ -5460,48 +4676,48 @@ var UpdatePlanDto = class {
5460
4676
  icon;
5461
4677
  sortOrder;
5462
4678
  };
5463
- _ts_decorate26([
5464
- (0, import_class_validator7.IsOptional)(),
5465
- (0, import_class_validator7.IsString)(),
5466
- (0, import_class_validator7.MinLength)(1),
5467
- (0, import_class_validator7.MaxLength)(120),
5468
- _ts_metadata26("design:type", String)
4679
+ _ts_decorate23([
4680
+ (0, import_class_validator6.IsOptional)(),
4681
+ (0, import_class_validator6.IsString)(),
4682
+ (0, import_class_validator6.MinLength)(1),
4683
+ (0, import_class_validator6.MaxLength)(120),
4684
+ _ts_metadata23("design:type", String)
5469
4685
  ], UpdatePlanDto.prototype, "label", void 0);
5470
- _ts_decorate26([
5471
- (0, import_class_validator7.IsOptional)(),
5472
- (0, import_class_validator7.IsString)(),
5473
- (0, import_class_validator7.MaxLength)(2e3),
5474
- _ts_metadata26("design:type", Object)
4686
+ _ts_decorate23([
4687
+ (0, import_class_validator6.IsOptional)(),
4688
+ (0, import_class_validator6.IsString)(),
4689
+ (0, import_class_validator6.MaxLength)(2e3),
4690
+ _ts_metadata23("design:type", Object)
5475
4691
  ], UpdatePlanDto.prototype, "description", void 0);
5476
- _ts_decorate26([
5477
- (0, import_class_validator7.IsOptional)(),
5478
- (0, import_class_validator7.IsString)(),
5479
- (0, import_class_validator7.MaxLength)(64),
5480
- _ts_metadata26("design:type", Object)
4692
+ _ts_decorate23([
4693
+ (0, import_class_validator6.IsOptional)(),
4694
+ (0, import_class_validator6.IsString)(),
4695
+ (0, import_class_validator6.MaxLength)(64),
4696
+ _ts_metadata23("design:type", Object)
5481
4697
  ], UpdatePlanDto.prototype, "icon", void 0);
5482
- _ts_decorate26([
5483
- (0, import_class_validator7.IsOptional)(),
5484
- (0, import_class_validator7.IsInt)(),
5485
- (0, import_class_validator7.Min)(0),
5486
- (0, import_class_validator7.Max)(1e4),
5487
- _ts_metadata26("design:type", Number)
4698
+ _ts_decorate23([
4699
+ (0, import_class_validator6.IsOptional)(),
4700
+ (0, import_class_validator6.IsInt)(),
4701
+ (0, import_class_validator6.Min)(0),
4702
+ (0, import_class_validator6.Max)(1e4),
4703
+ _ts_metadata23("design:type", Number)
5488
4704
  ], UpdatePlanDto.prototype, "sortOrder", void 0);
5489
4705
 
5490
4706
  // src/catalog/dto/plan-versions.dto.ts
5491
- var import_class_validator8 = require("class-validator");
5492
- function _ts_decorate27(decorators, target, key, desc) {
4707
+ var import_class_validator7 = require("class-validator");
4708
+ function _ts_decorate24(decorators, target, key, desc) {
5493
4709
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5494
4710
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5495
4711
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5496
4712
  return c > 3 && r && Object.defineProperty(target, key, r), r;
5497
4713
  }
5498
- __name(_ts_decorate27, "_ts_decorate");
5499
- function _ts_metadata27(k, v) {
4714
+ __name(_ts_decorate24, "_ts_decorate");
4715
+ function _ts_metadata24(k, v) {
5500
4716
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
5501
4717
  }
5502
- __name(_ts_metadata27, "_ts_metadata");
4718
+ __name(_ts_metadata24, "_ts_metadata");
5503
4719
  var FEATURE_KEY_PATTERN2 = /^[A-Z][A-Z0-9_]*$/;
5504
- var DECIMAL_PATTERN3 = /^\d+(\.\d{1,2})?$/;
4720
+ var DECIMAL_PATTERN2 = /^\d+(\.\d{1,2})?$/;
5505
4721
  var CreatePlanVersionDraftDto = class {
5506
4722
  static {
5507
4723
  __name(this, "CreatePlanVersionDraftDto");
@@ -5523,73 +4739,73 @@ var CreatePlanVersionDraftDto = class {
5523
4739
  /** Optional; null = unlimited. ISO date string. */
5524
4740
  validUntil;
5525
4741
  };
5526
- _ts_decorate27([
5527
- (0, import_class_validator8.IsArray)(),
5528
- (0, import_class_validator8.IsString)({
4742
+ _ts_decorate24([
4743
+ (0, import_class_validator7.IsArray)(),
4744
+ (0, import_class_validator7.IsString)({
5529
4745
  each: true
5530
4746
  }),
5531
- (0, import_class_validator8.Matches)(FEATURE_KEY_PATTERN2, {
4747
+ (0, import_class_validator7.Matches)(FEATURE_KEY_PATTERN2, {
5532
4748
  each: true,
5533
4749
  message: "features-Eintr\xE4ge m\xFCssen SCREAMING_SNAKE_CASE sein"
5534
4750
  }),
5535
- _ts_metadata27("design:type", Array)
4751
+ _ts_metadata24("design:type", Array)
5536
4752
  ], CreatePlanVersionDraftDto.prototype, "features", void 0);
5537
- _ts_decorate27([
5538
- (0, import_class_validator8.IsOptional)(),
5539
- (0, import_class_validator8.IsArray)(),
5540
- (0, import_class_validator8.IsString)({
4753
+ _ts_decorate24([
4754
+ (0, import_class_validator7.IsOptional)(),
4755
+ (0, import_class_validator7.IsArray)(),
4756
+ (0, import_class_validator7.IsString)({
5541
4757
  each: true
5542
4758
  }),
5543
- (0, import_class_validator8.Matches)(FEATURE_KEY_PATTERN2, {
4759
+ (0, import_class_validator7.Matches)(FEATURE_KEY_PATTERN2, {
5544
4760
  each: true,
5545
4761
  message: "bundles-Eintr\xE4ge m\xFCssen SCREAMING_SNAKE_CASE sein"
5546
4762
  }),
5547
- _ts_metadata27("design:type", Array)
4763
+ _ts_metadata24("design:type", Array)
5548
4764
  ], CreatePlanVersionDraftDto.prototype, "bundles", void 0);
5549
- _ts_decorate27([
5550
- (0, import_class_validator8.IsObject)(),
5551
- _ts_metadata27("design:type", typeof Record === "undefined" ? Object : Record)
4765
+ _ts_decorate24([
4766
+ (0, import_class_validator7.IsObject)(),
4767
+ _ts_metadata24("design:type", typeof Record === "undefined" ? Object : Record)
5552
4768
  ], CreatePlanVersionDraftDto.prototype, "quotas", void 0);
5553
- _ts_decorate27([
5554
- (0, import_class_validator8.Matches)(DECIMAL_PATTERN3, {
4769
+ _ts_decorate24([
4770
+ (0, import_class_validator7.Matches)(DECIMAL_PATTERN2, {
5555
4771
  message: 'monthlyNet muss Decimal mit max. 2 Nachkommastellen sein (z. B. "9.90")'
5556
4772
  }),
5557
- _ts_metadata27("design:type", String)
4773
+ _ts_metadata24("design:type", String)
5558
4774
  ], CreatePlanVersionDraftDto.prototype, "monthlyNet", void 0);
5559
- _ts_decorate27([
5560
- (0, import_class_validator8.Matches)(DECIMAL_PATTERN3, {
4775
+ _ts_decorate24([
4776
+ (0, import_class_validator7.Matches)(DECIMAL_PATTERN2, {
5561
4777
  message: "yearlyNet muss Decimal mit max. 2 Nachkommastellen sein"
5562
4778
  }),
5563
- _ts_metadata27("design:type", String)
4779
+ _ts_metadata24("design:type", String)
5564
4780
  ], CreatePlanVersionDraftDto.prototype, "yearlyNet", void 0);
5565
- _ts_decorate27([
5566
- (0, import_class_validator8.IsOptional)(),
5567
- (0, import_class_validator8.IsBoolean)(),
5568
- _ts_metadata27("design:type", Boolean)
4781
+ _ts_decorate24([
4782
+ (0, import_class_validator7.IsOptional)(),
4783
+ (0, import_class_validator7.IsBoolean)(),
4784
+ _ts_metadata24("design:type", Boolean)
5569
4785
  ], CreatePlanVersionDraftDto.prototype, "marketed", void 0);
5570
- _ts_decorate27([
5571
- (0, import_class_validator8.IsOptional)(),
5572
- (0, import_class_validator8.IsString)(),
5573
- (0, import_class_validator8.MaxLength)(2e3),
5574
- _ts_metadata27("design:type", String)
4786
+ _ts_decorate24([
4787
+ (0, import_class_validator7.IsOptional)(),
4788
+ (0, import_class_validator7.IsString)(),
4789
+ (0, import_class_validator7.MaxLength)(2e3),
4790
+ _ts_metadata24("design:type", String)
5575
4791
  ], CreatePlanVersionDraftDto.prototype, "changeNote", void 0);
5576
- _ts_decorate27([
5577
- (0, import_class_validator8.IsOptional)(),
5578
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5579
- (0, import_class_validator8.IsUUID)(),
5580
- _ts_metadata27("design:type", Object)
4792
+ _ts_decorate24([
4793
+ (0, import_class_validator7.IsOptional)(),
4794
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4795
+ (0, import_class_validator7.IsUUID)(),
4796
+ _ts_metadata24("design:type", Object)
5581
4797
  ], CreatePlanVersionDraftDto.prototype, "baseVersionId", void 0);
5582
- _ts_decorate27([
5583
- (0, import_class_validator8.IsOptional)(),
5584
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5585
- (0, import_class_validator8.IsISO8601)(),
5586
- _ts_metadata27("design:type", Object)
4798
+ _ts_decorate24([
4799
+ (0, import_class_validator7.IsOptional)(),
4800
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4801
+ (0, import_class_validator7.IsISO8601)(),
4802
+ _ts_metadata24("design:type", Object)
5587
4803
  ], CreatePlanVersionDraftDto.prototype, "validFrom", void 0);
5588
- _ts_decorate27([
5589
- (0, import_class_validator8.IsOptional)(),
5590
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5591
- (0, import_class_validator8.IsISO8601)(),
5592
- _ts_metadata27("design:type", Object)
4804
+ _ts_decorate24([
4805
+ (0, import_class_validator7.IsOptional)(),
4806
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4807
+ (0, import_class_validator7.IsISO8601)(),
4808
+ _ts_metadata24("design:type", Object)
5593
4809
  ], CreatePlanVersionDraftDto.prototype, "validUntil", void 0);
5594
4810
  var UpdatePlanVersionDraftDto = class {
5595
4811
  static {
@@ -5606,65 +4822,65 @@ var UpdatePlanVersionDraftDto = class {
5606
4822
  validFrom;
5607
4823
  validUntil;
5608
4824
  };
5609
- _ts_decorate27([
5610
- (0, import_class_validator8.IsOptional)(),
5611
- (0, import_class_validator8.IsArray)(),
5612
- (0, import_class_validator8.IsString)({
4825
+ _ts_decorate24([
4826
+ (0, import_class_validator7.IsOptional)(),
4827
+ (0, import_class_validator7.IsArray)(),
4828
+ (0, import_class_validator7.IsString)({
5613
4829
  each: true
5614
4830
  }),
5615
- (0, import_class_validator8.Matches)(FEATURE_KEY_PATTERN2, {
4831
+ (0, import_class_validator7.Matches)(FEATURE_KEY_PATTERN2, {
5616
4832
  each: true
5617
4833
  }),
5618
- _ts_metadata27("design:type", Array)
4834
+ _ts_metadata24("design:type", Array)
5619
4835
  ], UpdatePlanVersionDraftDto.prototype, "features", void 0);
5620
- _ts_decorate27([
5621
- (0, import_class_validator8.IsOptional)(),
5622
- (0, import_class_validator8.IsArray)(),
5623
- (0, import_class_validator8.IsString)({
4836
+ _ts_decorate24([
4837
+ (0, import_class_validator7.IsOptional)(),
4838
+ (0, import_class_validator7.IsArray)(),
4839
+ (0, import_class_validator7.IsString)({
5624
4840
  each: true
5625
4841
  }),
5626
- (0, import_class_validator8.Matches)(FEATURE_KEY_PATTERN2, {
4842
+ (0, import_class_validator7.Matches)(FEATURE_KEY_PATTERN2, {
5627
4843
  each: true
5628
4844
  }),
5629
- _ts_metadata27("design:type", Array)
4845
+ _ts_metadata24("design:type", Array)
5630
4846
  ], UpdatePlanVersionDraftDto.prototype, "bundles", void 0);
5631
- _ts_decorate27([
5632
- (0, import_class_validator8.IsOptional)(),
5633
- (0, import_class_validator8.IsObject)(),
5634
- _ts_metadata27("design:type", typeof Record === "undefined" ? Object : Record)
4847
+ _ts_decorate24([
4848
+ (0, import_class_validator7.IsOptional)(),
4849
+ (0, import_class_validator7.IsObject)(),
4850
+ _ts_metadata24("design:type", typeof Record === "undefined" ? Object : Record)
5635
4851
  ], UpdatePlanVersionDraftDto.prototype, "quotas", void 0);
5636
- _ts_decorate27([
5637
- (0, import_class_validator8.IsOptional)(),
5638
- (0, import_class_validator8.Matches)(DECIMAL_PATTERN3),
5639
- _ts_metadata27("design:type", String)
4852
+ _ts_decorate24([
4853
+ (0, import_class_validator7.IsOptional)(),
4854
+ (0, import_class_validator7.Matches)(DECIMAL_PATTERN2),
4855
+ _ts_metadata24("design:type", String)
5640
4856
  ], UpdatePlanVersionDraftDto.prototype, "monthlyNet", void 0);
5641
- _ts_decorate27([
5642
- (0, import_class_validator8.IsOptional)(),
5643
- (0, import_class_validator8.Matches)(DECIMAL_PATTERN3),
5644
- _ts_metadata27("design:type", String)
4857
+ _ts_decorate24([
4858
+ (0, import_class_validator7.IsOptional)(),
4859
+ (0, import_class_validator7.Matches)(DECIMAL_PATTERN2),
4860
+ _ts_metadata24("design:type", String)
5645
4861
  ], UpdatePlanVersionDraftDto.prototype, "yearlyNet", void 0);
5646
- _ts_decorate27([
5647
- (0, import_class_validator8.IsOptional)(),
5648
- (0, import_class_validator8.IsBoolean)(),
5649
- _ts_metadata27("design:type", Boolean)
4862
+ _ts_decorate24([
4863
+ (0, import_class_validator7.IsOptional)(),
4864
+ (0, import_class_validator7.IsBoolean)(),
4865
+ _ts_metadata24("design:type", Boolean)
5650
4866
  ], UpdatePlanVersionDraftDto.prototype, "marketed", void 0);
5651
- _ts_decorate27([
5652
- (0, import_class_validator8.IsOptional)(),
5653
- (0, import_class_validator8.IsString)(),
5654
- (0, import_class_validator8.MaxLength)(2e3),
5655
- _ts_metadata27("design:type", String)
4867
+ _ts_decorate24([
4868
+ (0, import_class_validator7.IsOptional)(),
4869
+ (0, import_class_validator7.IsString)(),
4870
+ (0, import_class_validator7.MaxLength)(2e3),
4871
+ _ts_metadata24("design:type", String)
5656
4872
  ], UpdatePlanVersionDraftDto.prototype, "changeNote", void 0);
5657
- _ts_decorate27([
5658
- (0, import_class_validator8.IsOptional)(),
5659
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5660
- (0, import_class_validator8.IsISO8601)(),
5661
- _ts_metadata27("design:type", Object)
4873
+ _ts_decorate24([
4874
+ (0, import_class_validator7.IsOptional)(),
4875
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4876
+ (0, import_class_validator7.IsISO8601)(),
4877
+ _ts_metadata24("design:type", Object)
5662
4878
  ], UpdatePlanVersionDraftDto.prototype, "validFrom", void 0);
5663
- _ts_decorate27([
5664
- (0, import_class_validator8.IsOptional)(),
5665
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5666
- (0, import_class_validator8.IsISO8601)(),
5667
- _ts_metadata27("design:type", Object)
4879
+ _ts_decorate24([
4880
+ (0, import_class_validator7.IsOptional)(),
4881
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4882
+ (0, import_class_validator7.IsISO8601)(),
4883
+ _ts_metadata24("design:type", Object)
5668
4884
  ], UpdatePlanVersionDraftDto.prototype, "validUntil", void 0);
5669
4885
  var TerminatePlanVersionDto = class {
5670
4886
  static {
@@ -5676,9 +4892,9 @@ var TerminatePlanVersionDto = class {
5676
4892
  */
5677
4893
  endsAt;
5678
4894
  };
5679
- _ts_decorate27([
5680
- (0, import_class_validator8.IsISO8601)(),
5681
- _ts_metadata27("design:type", String)
4895
+ _ts_decorate24([
4896
+ (0, import_class_validator7.IsISO8601)(),
4897
+ _ts_metadata24("design:type", String)
5682
4898
  ], TerminatePlanVersionDto.prototype, "endsAt", void 0);
5683
4899
  var PublishPlanVersionDto = class {
5684
4900
  static {
@@ -5698,47 +4914,47 @@ var PublishPlanVersionDto = class {
5698
4914
  validFrom;
5699
4915
  validUntil;
5700
4916
  };
5701
- _ts_decorate27([
5702
- (0, import_class_validator8.IsOptional)(),
5703
- (0, import_class_validator8.IsBoolean)(),
5704
- _ts_metadata27("design:type", Boolean)
4917
+ _ts_decorate24([
4918
+ (0, import_class_validator7.IsOptional)(),
4919
+ (0, import_class_validator7.IsBoolean)(),
4920
+ _ts_metadata24("design:type", Boolean)
5705
4921
  ], PublishPlanVersionDto.prototype, "forceRegressive", void 0);
5706
- _ts_decorate27([
5707
- (0, import_class_validator8.IsOptional)(),
5708
- (0, import_class_validator8.IsBoolean)(),
5709
- _ts_metadata27("design:type", Boolean)
4922
+ _ts_decorate24([
4923
+ (0, import_class_validator7.IsOptional)(),
4924
+ (0, import_class_validator7.IsBoolean)(),
4925
+ _ts_metadata24("design:type", Boolean)
5710
4926
  ], PublishPlanVersionDto.prototype, "allowZeroPrice", void 0);
5711
- _ts_decorate27([
5712
- (0, import_class_validator8.IsOptional)(),
5713
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5714
- (0, import_class_validator8.IsISO8601)(),
5715
- _ts_metadata27("design:type", Object)
4927
+ _ts_decorate24([
4928
+ (0, import_class_validator7.IsOptional)(),
4929
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4930
+ (0, import_class_validator7.IsISO8601)(),
4931
+ _ts_metadata24("design:type", Object)
5716
4932
  ], PublishPlanVersionDto.prototype, "validFrom", void 0);
5717
- _ts_decorate27([
5718
- (0, import_class_validator8.IsOptional)(),
5719
- (0, import_class_validator8.ValidateIf)((_o, value) => value !== null),
5720
- (0, import_class_validator8.IsISO8601)(),
5721
- _ts_metadata27("design:type", Object)
4933
+ _ts_decorate24([
4934
+ (0, import_class_validator7.IsOptional)(),
4935
+ (0, import_class_validator7.ValidateIf)((_o, value) => value !== null),
4936
+ (0, import_class_validator7.IsISO8601)(),
4937
+ _ts_metadata24("design:type", Object)
5722
4938
  ], PublishPlanVersionDto.prototype, "validUntil", void 0);
5723
4939
 
5724
4940
  // src/catalog/plans.controller.ts
5725
- function _ts_decorate28(decorators, target, key, desc) {
4941
+ function _ts_decorate25(decorators, target, key, desc) {
5726
4942
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5727
4943
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5728
4944
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5729
4945
  return c > 3 && r && Object.defineProperty(target, key, r), r;
5730
4946
  }
5731
- __name(_ts_decorate28, "_ts_decorate");
5732
- function _ts_metadata28(k, v) {
4947
+ __name(_ts_decorate25, "_ts_decorate");
4948
+ function _ts_metadata25(k, v) {
5733
4949
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
5734
4950
  }
5735
- __name(_ts_metadata28, "_ts_metadata");
5736
- function _ts_param20(paramIndex, decorator) {
4951
+ __name(_ts_metadata25, "_ts_metadata");
4952
+ function _ts_param18(paramIndex, decorator) {
5737
4953
  return function(target, key) {
5738
4954
  decorator(target, key, paramIndex);
5739
4955
  };
5740
4956
  }
5741
- __name(_ts_param20, "_ts_param");
4957
+ __name(_ts_param18, "_ts_param");
5742
4958
  function buildPlansController(guards) {
5743
4959
  let GeneratedPlansController = class GeneratedPlansController {
5744
4960
  static {
@@ -5806,103 +5022,103 @@ function buildPlansController(guards) {
5806
5022
  }
5807
5023
  }
5808
5024
  };
5809
- _ts_decorate28([
5810
- (0, import_common20.Get)(),
5811
- _ts_param20(0, (0, import_common20.Query)("projectKey")),
5812
- _ts_param20(1, (0, import_common20.Query)("onlyPublished")),
5813
- _ts_metadata28("design:type", Function),
5814
- _ts_metadata28("design:paramtypes", [
5025
+ _ts_decorate25([
5026
+ (0, import_common18.Get)(),
5027
+ _ts_param18(0, (0, import_common18.Query)("projectKey")),
5028
+ _ts_param18(1, (0, import_common18.Query)("onlyPublished")),
5029
+ _ts_metadata25("design:type", Function),
5030
+ _ts_metadata25("design:paramtypes", [
5815
5031
  String,
5816
5032
  String
5817
5033
  ]),
5818
- _ts_metadata28("design:returntype", void 0)
5034
+ _ts_metadata25("design:returntype", void 0)
5819
5035
  ], GeneratedPlansController.prototype, "listPlans", null);
5820
- _ts_decorate28([
5821
- (0, import_common20.Get)("tenant-counts"),
5822
- _ts_param20(0, (0, import_common20.Query)("projectKey")),
5823
- _ts_metadata28("design:type", Function),
5824
- _ts_metadata28("design:paramtypes", [
5036
+ _ts_decorate25([
5037
+ (0, import_common18.Get)("tenant-counts"),
5038
+ _ts_param18(0, (0, import_common18.Query)("projectKey")),
5039
+ _ts_metadata25("design:type", Function),
5040
+ _ts_metadata25("design:paramtypes", [
5825
5041
  String
5826
5042
  ]),
5827
- _ts_metadata28("design:returntype", void 0)
5043
+ _ts_metadata25("design:returntype", void 0)
5828
5044
  ], GeneratedPlansController.prototype, "getTenantCounts", null);
5829
- _ts_decorate28([
5830
- (0, import_common20.Get)(":id"),
5831
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5832
- _ts_metadata28("design:type", Function),
5833
- _ts_metadata28("design:paramtypes", [
5045
+ _ts_decorate25([
5046
+ (0, import_common18.Get)(":id"),
5047
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5048
+ _ts_metadata25("design:type", Function),
5049
+ _ts_metadata25("design:paramtypes", [
5834
5050
  String
5835
5051
  ]),
5836
- _ts_metadata28("design:returntype", void 0)
5052
+ _ts_metadata25("design:returntype", void 0)
5837
5053
  ], GeneratedPlansController.prototype, "getPlan", null);
5838
- _ts_decorate28([
5839
- (0, import_common20.Post)(),
5840
- _ts_param20(0, (0, import_common20.Body)()),
5841
- _ts_metadata28("design:type", Function),
5842
- _ts_metadata28("design:paramtypes", [
5054
+ _ts_decorate25([
5055
+ (0, import_common18.Post)(),
5056
+ _ts_param18(0, (0, import_common18.Body)()),
5057
+ _ts_metadata25("design:type", Function),
5058
+ _ts_metadata25("design:paramtypes", [
5843
5059
  typeof CreatePlanDto === "undefined" ? Object : CreatePlanDto
5844
5060
  ]),
5845
- _ts_metadata28("design:returntype", void 0)
5061
+ _ts_metadata25("design:returntype", void 0)
5846
5062
  ], GeneratedPlansController.prototype, "createPlan", null);
5847
- _ts_decorate28([
5848
- (0, import_common20.Patch)(":id"),
5849
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5850
- _ts_param20(1, (0, import_common20.Body)()),
5851
- _ts_metadata28("design:type", Function),
5852
- _ts_metadata28("design:paramtypes", [
5063
+ _ts_decorate25([
5064
+ (0, import_common18.Patch)(":id"),
5065
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5066
+ _ts_param18(1, (0, import_common18.Body)()),
5067
+ _ts_metadata25("design:type", Function),
5068
+ _ts_metadata25("design:paramtypes", [
5853
5069
  String,
5854
5070
  typeof UpdatePlanDto === "undefined" ? Object : UpdatePlanDto
5855
5071
  ]),
5856
- _ts_metadata28("design:returntype", void 0)
5072
+ _ts_metadata25("design:returntype", void 0)
5857
5073
  ], GeneratedPlansController.prototype, "updatePlan", null);
5858
- _ts_decorate28([
5859
- (0, import_common20.Delete)(":id"),
5860
- (0, import_common20.HttpCode)(import_common20.HttpStatus.NO_CONTENT),
5861
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5862
- _ts_metadata28("design:type", Function),
5863
- _ts_metadata28("design:paramtypes", [
5074
+ _ts_decorate25([
5075
+ (0, import_common18.Delete)(":id"),
5076
+ (0, import_common18.HttpCode)(import_common18.HttpStatus.NO_CONTENT),
5077
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5078
+ _ts_metadata25("design:type", Function),
5079
+ _ts_metadata25("design:paramtypes", [
5864
5080
  String
5865
5081
  ]),
5866
- _ts_metadata28("design:returntype", Promise)
5082
+ _ts_metadata25("design:returntype", Promise)
5867
5083
  ], GeneratedPlansController.prototype, "softDeletePlan", null);
5868
- _ts_decorate28([
5869
- (0, import_common20.Delete)(":id/purge"),
5870
- (0, import_common20.HttpCode)(import_common20.HttpStatus.NO_CONTENT),
5871
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5872
- _ts_metadata28("design:type", Function),
5873
- _ts_metadata28("design:paramtypes", [
5084
+ _ts_decorate25([
5085
+ (0, import_common18.Delete)(":id/purge"),
5086
+ (0, import_common18.HttpCode)(import_common18.HttpStatus.NO_CONTENT),
5087
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5088
+ _ts_metadata25("design:type", Function),
5089
+ _ts_metadata25("design:paramtypes", [
5874
5090
  String
5875
5091
  ]),
5876
- _ts_metadata28("design:returntype", Promise)
5092
+ _ts_metadata25("design:returntype", Promise)
5877
5093
  ], GeneratedPlansController.prototype, "hardDeletePlan", null);
5878
- _ts_decorate28([
5879
- (0, import_common20.Get)(":id/versions"),
5880
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5881
- _ts_metadata28("design:type", Function),
5882
- _ts_metadata28("design:paramtypes", [
5094
+ _ts_decorate25([
5095
+ (0, import_common18.Get)(":id/versions"),
5096
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5097
+ _ts_metadata25("design:type", Function),
5098
+ _ts_metadata25("design:paramtypes", [
5883
5099
  String
5884
5100
  ]),
5885
- _ts_metadata28("design:returntype", void 0)
5101
+ _ts_metadata25("design:returntype", void 0)
5886
5102
  ], GeneratedPlansController.prototype, "listVersions", null);
5887
- _ts_decorate28([
5888
- (0, import_common20.Post)(":id/versions"),
5889
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5890
- _ts_param20(1, (0, import_common20.Body)()),
5891
- _ts_metadata28("design:type", Function),
5892
- _ts_metadata28("design:paramtypes", [
5103
+ _ts_decorate25([
5104
+ (0, import_common18.Post)(":id/versions"),
5105
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5106
+ _ts_param18(1, (0, import_common18.Body)()),
5107
+ _ts_metadata25("design:type", Function),
5108
+ _ts_metadata25("design:paramtypes", [
5893
5109
  String,
5894
5110
  typeof CreatePlanVersionDraftDto === "undefined" ? Object : CreatePlanVersionDraftDto
5895
5111
  ]),
5896
- _ts_metadata28("design:returntype", void 0)
5112
+ _ts_metadata25("design:returntype", void 0)
5897
5113
  ], GeneratedPlansController.prototype, "createDraft", null);
5898
- GeneratedPlansController = _ts_decorate28([
5899
- (0, import_common20.Controller)("admin/catalog/plans"),
5900
- (0, import_common20.UseGuards)(...guards),
5901
- _ts_param20(0, (0, import_common20.Inject)(PlansService)),
5902
- _ts_param20(1, (0, import_common20.Optional)()),
5903
- _ts_param20(1, (0, import_common20.Inject)(PlanVersionsService)),
5904
- _ts_metadata28("design:type", Function),
5905
- _ts_metadata28("design:paramtypes", [
5114
+ GeneratedPlansController = _ts_decorate25([
5115
+ (0, import_common18.Controller)("admin/catalog/plans"),
5116
+ (0, import_common18.UseGuards)(...guards),
5117
+ _ts_param18(0, (0, import_common18.Inject)(PlansService)),
5118
+ _ts_param18(1, (0, import_common18.Optional)()),
5119
+ _ts_param18(1, (0, import_common18.Inject)(PlanVersionsService)),
5120
+ _ts_metadata25("design:type", Function),
5121
+ _ts_metadata25("design:paramtypes", [
5906
5122
  typeof PlansService === "undefined" ? Object : PlansService,
5907
5123
  Object
5908
5124
  ])
@@ -5941,64 +5157,64 @@ function buildPlanVersionsController(guards) {
5941
5157
  return this.service.terminatePlanVersion(versionId, new Date(dto.endsAt));
5942
5158
  }
5943
5159
  };
5944
- _ts_decorate28([
5945
- (0, import_common20.Get)(":id"),
5946
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5947
- _ts_metadata28("design:type", Function),
5948
- _ts_metadata28("design:paramtypes", [
5160
+ _ts_decorate25([
5161
+ (0, import_common18.Get)(":id"),
5162
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5163
+ _ts_metadata25("design:type", Function),
5164
+ _ts_metadata25("design:paramtypes", [
5949
5165
  String
5950
5166
  ]),
5951
- _ts_metadata28("design:returntype", void 0)
5167
+ _ts_metadata25("design:returntype", void 0)
5952
5168
  ], GeneratedPlanVersionsController.prototype, "getVersion", null);
5953
- _ts_decorate28([
5954
- (0, import_common20.Patch)(":id"),
5955
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5956
- _ts_param20(1, (0, import_common20.Body)()),
5957
- _ts_metadata28("design:type", Function),
5958
- _ts_metadata28("design:paramtypes", [
5169
+ _ts_decorate25([
5170
+ (0, import_common18.Patch)(":id"),
5171
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5172
+ _ts_param18(1, (0, import_common18.Body)()),
5173
+ _ts_metadata25("design:type", Function),
5174
+ _ts_metadata25("design:paramtypes", [
5959
5175
  String,
5960
5176
  typeof UpdatePlanVersionDraftDto === "undefined" ? Object : UpdatePlanVersionDraftDto
5961
5177
  ]),
5962
- _ts_metadata28("design:returntype", void 0)
5178
+ _ts_metadata25("design:returntype", void 0)
5963
5179
  ], GeneratedPlanVersionsController.prototype, "updateDraft", null);
5964
- _ts_decorate28([
5965
- (0, import_common20.Post)(":id/publish"),
5966
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5967
- _ts_param20(1, (0, import_common20.Body)()),
5968
- _ts_metadata28("design:type", Function),
5969
- _ts_metadata28("design:paramtypes", [
5180
+ _ts_decorate25([
5181
+ (0, import_common18.Post)(":id/publish"),
5182
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5183
+ _ts_param18(1, (0, import_common18.Body)()),
5184
+ _ts_metadata25("design:type", Function),
5185
+ _ts_metadata25("design:paramtypes", [
5970
5186
  String,
5971
5187
  typeof PublishPlanVersionDto === "undefined" ? Object : PublishPlanVersionDto
5972
5188
  ]),
5973
- _ts_metadata28("design:returntype", void 0)
5189
+ _ts_metadata25("design:returntype", void 0)
5974
5190
  ], GeneratedPlanVersionsController.prototype, "publish", null);
5975
- _ts_decorate28([
5976
- (0, import_common20.Delete)(":id"),
5977
- (0, import_common20.HttpCode)(import_common20.HttpStatus.NO_CONTENT),
5978
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5979
- _ts_metadata28("design:type", Function),
5980
- _ts_metadata28("design:paramtypes", [
5191
+ _ts_decorate25([
5192
+ (0, import_common18.Delete)(":id"),
5193
+ (0, import_common18.HttpCode)(import_common18.HttpStatus.NO_CONTENT),
5194
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5195
+ _ts_metadata25("design:type", Function),
5196
+ _ts_metadata25("design:paramtypes", [
5981
5197
  String
5982
5198
  ]),
5983
- _ts_metadata28("design:returntype", Promise)
5199
+ _ts_metadata25("design:returntype", Promise)
5984
5200
  ], GeneratedPlanVersionsController.prototype, "discardDraft", null);
5985
- _ts_decorate28([
5986
- (0, import_common20.Post)(":id/terminate"),
5987
- _ts_param20(0, (0, import_common20.Param)("id", new import_common20.ParseUUIDPipe())),
5988
- _ts_param20(1, (0, import_common20.Body)()),
5989
- _ts_metadata28("design:type", Function),
5990
- _ts_metadata28("design:paramtypes", [
5201
+ _ts_decorate25([
5202
+ (0, import_common18.Post)(":id/terminate"),
5203
+ _ts_param18(0, (0, import_common18.Param)("id", new import_common18.ParseUUIDPipe())),
5204
+ _ts_param18(1, (0, import_common18.Body)()),
5205
+ _ts_metadata25("design:type", Function),
5206
+ _ts_metadata25("design:paramtypes", [
5991
5207
  String,
5992
5208
  typeof TerminatePlanVersionDto === "undefined" ? Object : TerminatePlanVersionDto
5993
5209
  ]),
5994
- _ts_metadata28("design:returntype", void 0)
5210
+ _ts_metadata25("design:returntype", void 0)
5995
5211
  ], GeneratedPlanVersionsController.prototype, "terminate", null);
5996
- GeneratedPlanVersionsController = _ts_decorate28([
5997
- (0, import_common20.Controller)("admin/catalog/plan-versions"),
5998
- (0, import_common20.UseGuards)(...guards),
5999
- _ts_param20(0, (0, import_common20.Inject)(PlanVersionsService)),
6000
- _ts_metadata28("design:type", Function),
6001
- _ts_metadata28("design:paramtypes", [
5212
+ GeneratedPlanVersionsController = _ts_decorate25([
5213
+ (0, import_common18.Controller)("admin/catalog/plan-versions"),
5214
+ (0, import_common18.UseGuards)(...guards),
5215
+ _ts_param18(0, (0, import_common18.Inject)(PlanVersionsService)),
5216
+ _ts_metadata25("design:type", Function),
5217
+ _ts_metadata25("design:paramtypes", [
6002
5218
  typeof PlanVersionsService === "undefined" ? Object : PlanVersionsService
6003
5219
  ])
6004
5220
  ], GeneratedPlanVersionsController);
@@ -6007,7 +5223,7 @@ function buildPlanVersionsController(guards) {
6007
5223
  __name(buildPlanVersionsController, "buildPlanVersionsController");
6008
5224
 
6009
5225
  // src/catalog/catalog.module.ts
6010
- var import_common21 = require("@nestjs/common");
5226
+ var import_common19 = require("@nestjs/common");
6011
5227
 
6012
5228
  // src/core/di.ts
6013
5229
  function asProvider(token, impl) {
@@ -6027,19 +5243,18 @@ function asProvider(token, impl) {
6027
5243
  __name(asProvider, "asProvider");
6028
5244
 
6029
5245
  // src/catalog/catalog.module.ts
6030
- function _ts_decorate29(decorators, target, key, desc) {
5246
+ function _ts_decorate26(decorators, target, key, desc) {
6031
5247
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
6032
5248
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
6033
5249
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6034
5250
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6035
5251
  }
6036
- __name(_ts_decorate29, "_ts_decorate");
5252
+ __name(_ts_decorate26, "_ts_decorate");
6037
5253
  var CatalogModule = class _CatalogModule {
6038
5254
  static {
6039
5255
  __name(this, "CatalogModule");
6040
5256
  }
6041
5257
  static forRoot(options) {
6042
- const hasBusinessType = options.businessTypeRepository !== void 0;
6043
5258
  const hasMarketing = options.marketingProjectionRepository !== void 0;
6044
5259
  const hasPlan = options.planRepository !== void 0;
6045
5260
  const hasCatalogEntry = options.catalogEntryRepository !== void 0;
@@ -6050,10 +5265,6 @@ var CatalogModule = class _CatalogModule {
6050
5265
  if (options.controller) {
6051
5266
  controllers.push(buildBundlesController(options.controller.guards));
6052
5267
  controllers.push(buildBundleVersionsController(options.controller.guards));
6053
- if (hasBusinessType) {
6054
- controllers.push(buildBusinessTypesController(options.controller.guards));
6055
- controllers.push(buildBusinessTypeVersionsController(options.controller.guards));
6056
- }
6057
5268
  if (hasMarketing) {
6058
5269
  controllers.push(buildMarketingProjectionsController(options.controller.guards));
6059
5270
  }
@@ -6098,10 +5309,6 @@ var CatalogModule = class _CatalogModule {
6098
5309
  BundlesService,
6099
5310
  BUNDLE_REPOSITORY_TOKEN
6100
5311
  ];
6101
- if (hasBusinessType && options.businessTypeRepository) {
6102
- providers.push(asProvider(BUSINESS_TYPE_REPOSITORY_TOKEN, options.businessTypeRepository), BusinessTypesService);
6103
- exports2.push(BusinessTypesService, BUSINESS_TYPE_REPOSITORY_TOKEN);
6104
- }
6105
5312
  if (hasMarketing && options.marketingProjectionRepository) {
6106
5313
  providers.push(asProvider(MARKETING_PROJECTION_REPOSITORY_TOKEN, options.marketingProjectionRepository), MarketingProjectionsService);
6107
5314
  exports2.push(MarketingProjectionsService, MARKETING_PROJECTION_REPOSITORY_TOKEN);
@@ -6136,8 +5343,8 @@ var CatalogModule = class _CatalogModule {
6136
5343
  };
6137
5344
  }
6138
5345
  };
6139
- CatalogModule = _ts_decorate29([
6140
- (0, import_common21.Module)({})
5346
+ CatalogModule = _ts_decorate26([
5347
+ (0, import_common19.Module)({})
6141
5348
  ], CatalogModule);
6142
5349
 
6143
5350
  // src/catalog/preflight.ts
@@ -6174,26 +5381,6 @@ function runPreflight(input) {
6174
5381
  });
6175
5382
  }
6176
5383
  }
6177
- const bundleVersionById = new Map(input.bundleVersions.map((bv) => [
6178
- bv.id,
6179
- bv
6180
- ]));
6181
- for (const btv of input.businessTypeVersions) {
6182
- const referencedBundles = btv.bundles.map((b) => bundleVersionById.get(b.bundleVersionId)).filter((b) => b !== void 0);
6183
- const warns = validateBusinessTypeDraft({
6184
- businessTypeKey: btv.businessTypeKey,
6185
- quotaOverrides: btv.quotaOverrides ?? {}
6186
- }, referencedBundles, input.snapshot, approved);
6187
- for (const w of warns) {
6188
- findings.push({
6189
- kind: "business-type",
6190
- versionId: btv.id,
6191
- entityKey: btv.businessTypeKey,
6192
- version: btv.version,
6193
- warning: w
6194
- });
6195
- }
6196
- }
6197
5384
  findings.sort((a, b) => {
6198
5385
  if (a.kind !== b.kind) return a.kind.localeCompare(b.kind);
6199
5386
  if (a.entityKey !== b.entityKey) return a.entityKey.localeCompare(b.entityKey);
@@ -6203,7 +5390,6 @@ function runPreflight(input) {
6203
5390
  const counts = {
6204
5391
  planFindings: findings.filter((f) => f.kind === "plan").length,
6205
5392
  bundleFindings: findings.filter((f) => f.kind === "bundle").length,
6206
- businessTypeFindings: findings.filter((f) => f.kind === "business-type").length,
6207
5393
  total: findings.length
6208
5394
  };
6209
5395
  const hasBlockingFinding = findings.some((f) => !ADVISORY_STRICT_MODE_CODES.has(f.warning.code));
@@ -6216,7 +5402,7 @@ function runPreflight(input) {
6216
5402
  __name(runPreflight, "runPreflight");
6217
5403
  function formatPreflightReport(report) {
6218
5404
  const lines = [];
6219
- lines.push(`Preflight (Status: ${report.overall.toUpperCase()})`, ` Plans: ${report.counts.planFindings} \xB7 Bundles: ${report.counts.bundleFindings} \xB7 BusinessTypes: ${report.counts.businessTypeFindings} \xB7 Gesamt: ${report.counts.total}`, "");
5405
+ lines.push(`Preflight (Status: ${report.overall.toUpperCase()})`, ` Plans: ${report.counts.planFindings} \xB7 Bundles: ${report.counts.bundleFindings} \xB7 Gesamt: ${report.counts.total}`, "");
6220
5406
  if (report.findings.length === 0) {
6221
5407
  lines.push(" \u2713 Keine Strict-Mode-Verst\xF6\xDFe gefunden.");
6222
5408
  return lines.join("\n");
@@ -6376,18 +5562,13 @@ __name(runSeedGateFromFile, "runSeedGateFromFile");
6376
5562
  0 && (module.exports = {
6377
5563
  ADVISORY_STRICT_MODE_CODES,
6378
5564
  BUNDLE_REPOSITORY_TOKEN,
6379
- BUSINESS_TYPE_REPOSITORY_TOKEN,
6380
5565
  BundlesService,
6381
- BusinessTypeBundleInputDto,
6382
- BusinessTypesService,
6383
5566
  CATALOG_ENTRY_REPOSITORY_TOKEN,
6384
5567
  CATALOG_SERVICE_CONFIG_TOKEN,
6385
5568
  CatalogEntriesService,
6386
5569
  CatalogModule,
6387
5570
  CreateBundleDto,
6388
5571
  CreateBundleVersionDraftDto,
6389
- CreateBusinessTypeDto,
6390
- CreateBusinessTypeVersionDraftDto,
6391
5572
  CreateMarketingProjectionDto,
6392
5573
  CreatePlanDto,
6393
5574
  CreatePlanVersionDraftDto,
@@ -6407,14 +5588,11 @@ __name(runSeedGateFromFile, "runSeedGateFromFile");
6407
5588
  PromotionsService,
6408
5589
  PublicMarketingCatalogService,
6409
5590
  PublishBundleVersionDto,
6410
- PublishBusinessTypeVersionDto,
6411
5591
  PublishPlanVersionDto,
6412
5592
  ReviewCatalogEntryDto,
6413
5593
  SyncDiscoveryDto,
6414
5594
  UpdateBundleDto,
6415
5595
  UpdateBundleVersionDraftDto,
6416
- UpdateBusinessTypeDto,
6417
- UpdateBusinessTypeVersionDraftDto,
6418
5596
  UpdateCatalogEntryI18nDto,
6419
5597
  UpdateMarketingProjectionDto,
6420
5598
  UpdateMarketingSettingsDto,
@@ -6424,8 +5602,6 @@ __name(runSeedGateFromFile, "runSeedGateFromFile");
6424
5602
  blockingStrictModeWarnings,
6425
5603
  buildBundleVersionsController,
6426
5604
  buildBundlesController,
6427
- buildBusinessTypeVersionsController,
6428
- buildBusinessTypesController,
6429
5605
  buildCatalogEntriesController,
6430
5606
  buildMarketingProjectionsController,
6431
5607
  buildMarketingSettingsController,
@@ -6443,7 +5619,6 @@ __name(runSeedGateFromFile, "runSeedGateFromFile");
6443
5619
  runSeedGateFromFile,
6444
5620
  seedGateExitCode,
6445
5621
  validateBundleDraft,
6446
- validateBusinessTypeDraft,
6447
5622
  validatePlanDraft,
6448
5623
  validateSeedAgainstSnapshot
6449
5624
  });