adamo-types 2.1.46-uat → 2.1.48-sit

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 (39) hide show
  1. package/dist/common/edge-zoho/sale-process/req/patch.entity.d.ts +3 -6
  2. package/dist/common/edge-zoho/sale-process/req/patch.entity.js +6 -29
  3. package/dist/sys03/approval/data.entity.d.ts +63 -0
  4. package/dist/sys03/approval/data.entity.js +141 -0
  5. package/dist/sys03/approval/entity.d.ts +60 -0
  6. package/dist/sys03/approval/entity.js +199 -0
  7. package/dist/sys03/approval/generic/entity.d.ts +31 -0
  8. package/dist/sys03/approval/generic/entity.js +41 -0
  9. package/dist/sys03/approval/generic/index.d.ts +1 -0
  10. package/dist/sys03/approval/generic/index.js +17 -0
  11. package/dist/sys03/approval/index.d.ts +5 -1
  12. package/dist/sys03/approval/index.js +5 -1
  13. package/dist/sys03/approval/main/entity.d.ts +58 -0
  14. package/dist/sys03/approval/main/entity.js +113 -0
  15. package/dist/sys03/approval/main/index.d.ts +1 -0
  16. package/dist/sys03/approval/main/index.js +17 -0
  17. package/dist/sys03/approval/validation-data.entity.d.ts +22 -0
  18. package/dist/sys03/approval/validation-data.entity.js +49 -0
  19. package/dist/sys03/customer-handover-process/customer-handover-process.entity.d.ts +2 -2
  20. package/dist/sys03/generic-sale-process/constants.d.ts +3 -1
  21. package/dist/sys03/generic-sale-process/constants.js +3 -1
  22. package/dist/sys03/generic-sale-process/entity.d.ts +5 -3
  23. package/dist/sys03/generic-sale-process/entity.js +7 -4
  24. package/dist/sys03/generic-sale-process/patch/index.d.ts +2 -1
  25. package/dist/sys03/generic-sale-process/patch/index.js +2 -1
  26. package/dist/sys03/generic-sale-process/patch/pending-iban-validation.entity.d.ts +32 -0
  27. package/dist/sys03/generic-sale-process/patch/pending-iban-validation.entity.js +152 -0
  28. package/dist/sys03/sale-process/approval.entity.d.ts +17 -0
  29. package/dist/sys03/sale-process/approval.entity.js +92 -0
  30. package/dist/sys03/sale-process/index.d.ts +3 -2
  31. package/dist/sys03/sale-process/index.js +3 -2
  32. package/dist/sys03/sale-process/patch/contract-data-saved.entity.d.ts +4 -0
  33. package/dist/sys03/sale-process/patch/contract-data-saved.entity.js +26 -1
  34. package/dist/sys03/sale-process/sale-process.entity.d.ts +0 -17
  35. package/dist/sys03/sale-process/sale-process.entity.js +3 -77
  36. package/dist/tsconfig.build.tsbuildinfo +1 -1
  37. package/package.json +1 -1
  38. package/dist/sys03/approval/approval.entity.d.ts +0 -179
  39. package/dist/sys03/approval/approval.entity.js +0 -504
@@ -4,6 +4,7 @@ import { SaleProcessStatusType } from '../../../../zoho/constants';
4
4
  import { CreateCustomerAccountAddressReqDto } from '../../../../sys03/customer';
5
5
  import { ExistingCustomerBehaviourType } from '../../../../sys03/common';
6
6
  import { SaleProcessCompanyIdentificationDto, SaleProcessIndividualIdentificationDto } from '../../../../sys03/sale-process/identification.entity';
7
+ import { PartialSaleProcessBillingFirstAndLastNameDto } from '../../../../sys03/sale-process/patch';
7
8
  export declare class PartialSaleProcessCustomerDto {
8
9
  customerType: CustomerType;
9
10
  identification?: SaleProcessIndividualIdentificationDto;
@@ -35,11 +36,7 @@ export declare class PartialSaleProcessDigitelDto {
35
36
  export declare class PartialSaleProcessContractDataSavedPatchBehaviourBusinessInfoDto {
36
37
  businessInfo: PatchSaleProcessBusinessInfoContractDataSavedDto;
37
38
  }
38
- export declare class PartialSaleProcessBillingInfoFirstAndLastNameDto {
39
- firstName: string;
40
- lastName: string;
41
- }
42
- export declare class PartialSaleProcessBillingInfoDto extends PartialSaleProcessBillingInfoFirstAndLastNameDto {
39
+ export declare class PartialSaleProcessBillingInfoDto extends PartialSaleProcessBillingFirstAndLastNameDto {
43
40
  billingAddressData: CreateCustomerAccountAddressReqDto;
44
41
  }
45
42
  export declare class PartialSaleProcessCustomerBaseDto {
@@ -186,7 +183,7 @@ export declare class PatchSaleProcessNoCoverageWebDto {
186
183
  }
187
184
  export declare class PartialSaleProcessPendingIbanValidationPersonDto {
188
185
  iban: string;
189
- billingInfo: PartialSaleProcessBillingInfoFirstAndLastNameDto;
186
+ billingInfo: PartialSaleProcessBillingFirstAndLastNameDto;
190
187
  customer: PartialSaleProcessCustomerBaseWithoutTypeDto;
191
188
  }
192
189
  export declare class PatchSaleProcessPendingIbanValidationPersonDto extends PartialSaleProcessPendingIbanValidationPersonDto {
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.PatchSaleProcessPendingIbanValidationCompanyDto = exports.PartialSaleProcessPendingIbanValidationCompanyDto = exports.PatchSaleProcessPendingIbanValidationPersonDto = exports.PartialSaleProcessPendingIbanValidationPersonDto = exports.PatchSaleProcessNoCoverageWebDto = exports.PatchSaleProcessFhContactDto = exports.PatchSaleProcessNearByDto = exports.PatchSaleProcessApolloDto = exports.PatchSaleProcessB2bContactDto = exports.PatchSaleProcessNoSaleDto = exports.PatchSaleProcessApartmentSelectedDto = exports.PatchSaleProcessAddressSelectedDto = exports.PatchSaleProcessAddressSearchDto = exports.PartialNearByFhContactNoCoverageAddressSearchDto = exports.PartialNearByFhContactNoCoverageCustomerDto = exports.PartialApolloAddressSearchDto = exports.PartialB2bContactAddressSearchDto = exports.PartialB2bContactCustomerDto = exports.PartialApartmentSelectedDto = exports.PartialAddressSelectedDto = exports.PartialAddressSearchDto = exports.PatchSaleProcessFeaturesSelectedDto = exports.PatchSaleProcessBundleSelectedDto = exports.PatchSaleProcessNoCoverageDto = exports.PatchSaleProcessPersonalDataSavedDto = exports.PatchSaleProcessContractDataSavedDto = exports.PartialSaleProcessBusinessInfoDto = exports.PartialSaleProcessBillingInfoBaseWithIdentificationDto = exports.PartialSaleProcessBillingInfoBaseDto = exports.PartialSaleProcessContractCustomerDto = exports.PartialSaleProcessCustomerBaseWithoutTypeDto = exports.PartialSaleProcessCustomerBaseDto = exports.PartialSaleProcessBillingInfoDto = exports.PartialSaleProcessBillingInfoFirstAndLastNameDto = exports.PartialSaleProcessContractDataSavedPatchBehaviourBusinessInfoDto = exports.PartialSaleProcessDigitelDto = exports.PartialSaleProcessDigitelCustomerDto = exports.PatchSaleProcessBusinessInfoContractDataSavedDto = exports.PatchSaleProcessCustomerTypeValidatedDto = exports.PatchSaleProcessCustomerTypeSelectedDto = exports.PartialSaleProcessBusinessDto = exports.PartialSaleProcessCustomerDto = void 0;
12
+ exports.PatchSaleProcessPendingIbanValidationCompanyDto = exports.PartialSaleProcessPendingIbanValidationCompanyDto = exports.PatchSaleProcessPendingIbanValidationPersonDto = exports.PartialSaleProcessPendingIbanValidationPersonDto = exports.PatchSaleProcessNoCoverageWebDto = exports.PatchSaleProcessFhContactDto = exports.PatchSaleProcessNearByDto = exports.PatchSaleProcessApolloDto = exports.PatchSaleProcessB2bContactDto = exports.PatchSaleProcessNoSaleDto = exports.PatchSaleProcessApartmentSelectedDto = exports.PatchSaleProcessAddressSelectedDto = exports.PatchSaleProcessAddressSearchDto = exports.PartialNearByFhContactNoCoverageAddressSearchDto = exports.PartialNearByFhContactNoCoverageCustomerDto = exports.PartialApolloAddressSearchDto = exports.PartialB2bContactAddressSearchDto = exports.PartialB2bContactCustomerDto = exports.PartialApartmentSelectedDto = exports.PartialAddressSelectedDto = exports.PartialAddressSearchDto = exports.PatchSaleProcessFeaturesSelectedDto = exports.PatchSaleProcessBundleSelectedDto = exports.PatchSaleProcessNoCoverageDto = exports.PatchSaleProcessPersonalDataSavedDto = exports.PatchSaleProcessContractDataSavedDto = exports.PartialSaleProcessBusinessInfoDto = exports.PartialSaleProcessBillingInfoBaseWithIdentificationDto = exports.PartialSaleProcessBillingInfoBaseDto = exports.PartialSaleProcessContractCustomerDto = exports.PartialSaleProcessCustomerBaseWithoutTypeDto = exports.PartialSaleProcessCustomerBaseDto = exports.PartialSaleProcessBillingInfoDto = exports.PartialSaleProcessContractDataSavedPatchBehaviourBusinessInfoDto = exports.PartialSaleProcessDigitelDto = exports.PartialSaleProcessDigitelCustomerDto = exports.PatchSaleProcessBusinessInfoContractDataSavedDto = exports.PatchSaleProcessCustomerTypeValidatedDto = exports.PatchSaleProcessCustomerTypeSelectedDto = exports.PartialSaleProcessBusinessDto = exports.PartialSaleProcessCustomerDto = void 0;
13
13
  const openapi = require("@nestjs/swagger");
14
14
  const constants_1 = require("../../../../bss/constants");
15
15
  const constants_2 = require("../../../constants");
@@ -21,6 +21,7 @@ const swagger_1 = require("@nestjs/swagger");
21
21
  const customer_1 = require("../../../../sys03/customer");
22
22
  const common_1 = require("../../../../sys03/common");
23
23
  const identification_entity_1 = require("../../../../sys03/sale-process/identification.entity");
24
+ const patch_1 = require("../../../../sys03/sale-process/patch");
24
25
  class PartialSaleProcessCustomerDto {
25
26
  customerType;
26
27
  identification;
@@ -171,31 +172,7 @@ __decorate([
171
172
  (0, class_transformer_1.Expose)(),
172
173
  __metadata("design:type", PatchSaleProcessBusinessInfoContractDataSavedDto)
173
174
  ], PartialSaleProcessContractDataSavedPatchBehaviourBusinessInfoDto.prototype, "businessInfo", void 0);
174
- class PartialSaleProcessBillingInfoFirstAndLastNameDto {
175
- firstName;
176
- lastName;
177
- static _OPENAPI_METADATA_FACTORY() {
178
- return { firstName: { required: true, type: () => String, maxLength: 64 }, lastName: { required: true, type: () => String, maxLength: 64 } };
179
- }
180
- }
181
- exports.PartialSaleProcessBillingInfoFirstAndLastNameDto = PartialSaleProcessBillingInfoFirstAndLastNameDto;
182
- __decorate([
183
- (0, class_validator_1.IsString)(),
184
- (0, class_validator_1.IsNotEmpty)(),
185
- (0, _validators_1.IsNotBlank)(),
186
- (0, class_validator_1.MaxLength)(64),
187
- (0, class_transformer_1.Expose)(),
188
- __metadata("design:type", String)
189
- ], PartialSaleProcessBillingInfoFirstAndLastNameDto.prototype, "firstName", void 0);
190
- __decorate([
191
- (0, class_validator_1.IsString)(),
192
- (0, class_validator_1.IsNotEmpty)(),
193
- (0, _validators_1.IsNotBlank)(),
194
- (0, class_validator_1.MaxLength)(64),
195
- (0, class_transformer_1.Expose)(),
196
- __metadata("design:type", String)
197
- ], PartialSaleProcessBillingInfoFirstAndLastNameDto.prototype, "lastName", void 0);
198
- class PartialSaleProcessBillingInfoDto extends PartialSaleProcessBillingInfoFirstAndLastNameDto {
175
+ class PartialSaleProcessBillingInfoDto extends patch_1.PartialSaleProcessBillingFirstAndLastNameDto {
199
176
  billingAddressData;
200
177
  static _OPENAPI_METADATA_FACTORY() {
201
178
  return { billingAddressData: { required: true, type: () => require("../../../../sys03/customer/customer-account-address.entity").CreateCustomerAccountAddressReqDto } };
@@ -1007,7 +984,7 @@ class PartialSaleProcessPendingIbanValidationPersonDto {
1007
984
  billingInfo;
1008
985
  customer;
1009
986
  static _OPENAPI_METADATA_FACTORY() {
1010
- return { iban: { required: true, type: () => String, pattern: "/^[A-Za-z0-9]+$/" }, billingInfo: { required: true, type: () => require("./patch.entity").PartialSaleProcessBillingInfoFirstAndLastNameDto }, customer: { required: true, type: () => require("./patch.entity").PartialSaleProcessCustomerBaseWithoutTypeDto } };
987
+ return { iban: { required: true, type: () => String, pattern: "/^[A-Za-z0-9]+$/" }, billingInfo: { required: true, type: () => require("../../../../sys03/sale-process/patch/contract-data-saved.entity").PartialSaleProcessBillingFirstAndLastNameDto }, customer: { required: true, type: () => require("./patch.entity").PartialSaleProcessCustomerBaseWithoutTypeDto } };
1011
988
  }
1012
989
  }
1013
990
  exports.PartialSaleProcessPendingIbanValidationPersonDto = PartialSaleProcessPendingIbanValidationPersonDto;
@@ -1021,9 +998,9 @@ __decorate([
1021
998
  __decorate([
1022
999
  (0, class_validator_1.IsDefined)(),
1023
1000
  (0, class_validator_1.ValidateNested)(),
1024
- (0, class_transformer_1.Type)(() => PartialSaleProcessBillingInfoFirstAndLastNameDto),
1001
+ (0, class_transformer_1.Type)(() => patch_1.PartialSaleProcessBillingFirstAndLastNameDto),
1025
1002
  (0, class_transformer_1.Expose)(),
1026
- __metadata("design:type", PartialSaleProcessBillingInfoFirstAndLastNameDto)
1003
+ __metadata("design:type", patch_1.PartialSaleProcessBillingFirstAndLastNameDto)
1027
1004
  ], PartialSaleProcessPendingIbanValidationPersonDto.prototype, "billingInfo", void 0);
1028
1005
  __decorate([
1029
1006
  (0, class_validator_1.IsDefined)(),
@@ -0,0 +1,63 @@
1
+ import { Builder } from '../../common/helpers/helpers';
2
+ import { AuditFieldsDto } from '../common';
3
+ import { SaleProcessApprovalValidation } from '../constants';
4
+ import { SaleProcessCompanyIdentificationDto, SaleProcessIndividualIdentificationDto } from '../sale-process';
5
+ import { ApprovalBillingDto } from './entity';
6
+ import { ApprovalValidationDataDto } from './validation-data.entity';
7
+ export declare class ApprovalDataCustomerDto {
8
+ id?: string;
9
+ url?: string;
10
+ identification?: SaleProcessIndividualIdentificationDto | SaleProcessCompanyIdentificationDto;
11
+ }
12
+ declare const CreateApprovalDataCustomerDto_base: import("@nestjs/common").Type<Pick<ApprovalDataCustomerDto, "id" | "identification">>;
13
+ export declare class CreateApprovalDataCustomerDto extends CreateApprovalDataCustomerDto_base {
14
+ }
15
+ declare const ApprovalDataBillingDto_base: import("@nestjs/common").Type<Pick<ApprovalBillingDto, "firstName" | "lastName" | "identification" | "iban">>;
16
+ export declare class ApprovalDataBillingDto extends ApprovalDataBillingDto_base {
17
+ }
18
+ export declare class ApprovalDataDto {
19
+ id: number;
20
+ approvalId: number;
21
+ validation: SaleProcessApprovalValidation;
22
+ active: boolean;
23
+ customer?: ApprovalDataCustomerDto;
24
+ billing?: ApprovalDataBillingDto;
25
+ approved: boolean;
26
+ notes?: string;
27
+ created: AuditFieldsDto;
28
+ updated?: AuditFieldsDto;
29
+ }
30
+ declare const CreateApprovalDataDto_base: import("@nestjs/common").Type<Pick<ApprovalDataDto, "notes" | "created" | "validation" | "billing">>;
31
+ export declare class CreateApprovalDataDto extends CreateApprovalDataDto_base {
32
+ customer?: CreateApprovalDataCustomerDto;
33
+ }
34
+ declare const CreateApprovalDataFromValidationDto_base: import("@nestjs/common").Type<Omit<CreateApprovalDataDto, "created">>;
35
+ export declare class CreateApprovalDataFromValidationDto extends CreateApprovalDataFromValidationDto_base {
36
+ }
37
+ declare const UpdateApprovalDataDto_base: import("@nestjs/common").Type<Omit<ApprovalDataDto, "id" | "created" | "active" | "validation" | "approvalId">>;
38
+ export declare class UpdateApprovalDataDto extends UpdateApprovalDataDto_base {
39
+ validation?: SaleProcessApprovalValidation;
40
+ active?: boolean;
41
+ }
42
+ declare const LegacyCreateApprovalDataDto_base: import("@nestjs/common").Type<Omit<ApprovalDataDto, "id" | "updated" | "active" | "approved">>;
43
+ export declare class LegacyCreateApprovalDataDto extends LegacyCreateApprovalDataDto_base {
44
+ }
45
+ declare const LegacyPartialCreateApprovalDataDto_base: import("@nestjs/common").Type<Omit<LegacyCreateApprovalDataDto, "created" | "approvalId">>;
46
+ export declare class LegacyPartialCreateApprovalDataDto extends LegacyPartialCreateApprovalDataDto_base {
47
+ }
48
+ export declare class ApprovalDataGroupDto {
49
+ validation: SaleProcessApprovalValidation;
50
+ validationData?: ApprovalValidationDataDto;
51
+ templateUrl?: string;
52
+ data: ApprovalDataDto[];
53
+ }
54
+ export declare class ApprovalDataDtoBuilder extends Builder<ApprovalDataDto> {
55
+ setDefaults(): ApprovalDataDto;
56
+ }
57
+ export declare class PatchApprovalDataDto {
58
+ validation?: SaleProcessApprovalValidation;
59
+ active?: boolean;
60
+ approved?: boolean;
61
+ notes?: string;
62
+ }
63
+ export {};
@@ -0,0 +1,141 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ 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;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.PatchApprovalDataDto = exports.ApprovalDataDtoBuilder = exports.ApprovalDataGroupDto = exports.LegacyPartialCreateApprovalDataDto = exports.LegacyCreateApprovalDataDto = exports.UpdateApprovalDataDto = exports.CreateApprovalDataFromValidationDto = exports.CreateApprovalDataDto = exports.ApprovalDataDto = exports.ApprovalDataBillingDto = exports.CreateApprovalDataCustomerDto = exports.ApprovalDataCustomerDto = void 0;
13
+ const openapi = require("@nestjs/swagger");
14
+ const helpers_1 = require("../../common/helpers/helpers");
15
+ const faker_1 = require("@faker-js/faker");
16
+ const swagger_1 = require("@nestjs/swagger");
17
+ const common_1 = require("../common");
18
+ const constants_1 = require("../constants");
19
+ const entity_1 = require("./entity");
20
+ const class_validator_1 = require("class-validator");
21
+ const class_transformer_1 = require("class-transformer");
22
+ class ApprovalDataCustomerDto {
23
+ id;
24
+ url;
25
+ identification;
26
+ static _OPENAPI_METADATA_FACTORY() {
27
+ return { id: { required: false, type: () => String }, url: { required: false, type: () => String }, identification: { required: false, type: () => Object } };
28
+ }
29
+ }
30
+ exports.ApprovalDataCustomerDto = ApprovalDataCustomerDto;
31
+ class CreateApprovalDataCustomerDto extends (0, swagger_1.PickType)(ApprovalDataCustomerDto, ['id', 'identification']) {
32
+ static _OPENAPI_METADATA_FACTORY() {
33
+ return {};
34
+ }
35
+ }
36
+ exports.CreateApprovalDataCustomerDto = CreateApprovalDataCustomerDto;
37
+ class ApprovalDataBillingDto extends (0, swagger_1.PickType)(entity_1.ApprovalBillingDto, ['firstName', 'lastName', 'identification', 'iban']) {
38
+ static _OPENAPI_METADATA_FACTORY() {
39
+ return {};
40
+ }
41
+ }
42
+ exports.ApprovalDataBillingDto = ApprovalDataBillingDto;
43
+ class ApprovalDataDto {
44
+ id;
45
+ approvalId;
46
+ validation;
47
+ active;
48
+ customer;
49
+ billing;
50
+ approved;
51
+ notes;
52
+ created;
53
+ updated;
54
+ static _OPENAPI_METADATA_FACTORY() {
55
+ return { id: { required: true, type: () => Number }, approvalId: { required: true, type: () => Number }, validation: { required: true, enum: require("../constants/sys03.constants").SaleProcessApprovalValidation }, active: { required: true, type: () => Boolean }, customer: { required: false, type: () => require("./data.entity").ApprovalDataCustomerDto }, billing: { required: false, type: () => require("./data.entity").ApprovalDataBillingDto }, approved: { required: true, type: () => Boolean }, notes: { required: false, type: () => String }, created: { required: true, type: () => require("../common/common.entity").AuditFieldsDto }, updated: { required: false, type: () => require("../common/common.entity").AuditFieldsDto } };
56
+ }
57
+ }
58
+ exports.ApprovalDataDto = ApprovalDataDto;
59
+ class CreateApprovalDataDto extends (0, swagger_1.PickType)(ApprovalDataDto, ['validation', 'billing', 'notes', 'created']) {
60
+ customer;
61
+ static _OPENAPI_METADATA_FACTORY() {
62
+ return { customer: { required: false, type: () => require("./data.entity").CreateApprovalDataCustomerDto } };
63
+ }
64
+ }
65
+ exports.CreateApprovalDataDto = CreateApprovalDataDto;
66
+ class CreateApprovalDataFromValidationDto extends (0, swagger_1.OmitType)(CreateApprovalDataDto, ['created']) {
67
+ static _OPENAPI_METADATA_FACTORY() {
68
+ return {};
69
+ }
70
+ }
71
+ exports.CreateApprovalDataFromValidationDto = CreateApprovalDataFromValidationDto;
72
+ class UpdateApprovalDataDto extends (0, swagger_1.OmitType)(ApprovalDataDto, ['id', 'approvalId', 'created', 'validation', 'active']) {
73
+ validation;
74
+ active;
75
+ static _OPENAPI_METADATA_FACTORY() {
76
+ return { validation: { required: false, enum: require("../constants/sys03.constants").SaleProcessApprovalValidation }, active: { required: false, type: () => Boolean } };
77
+ }
78
+ }
79
+ exports.UpdateApprovalDataDto = UpdateApprovalDataDto;
80
+ class LegacyCreateApprovalDataDto extends (0, swagger_1.OmitType)(ApprovalDataDto, ['id', 'approved', 'active', 'updated']) {
81
+ static _OPENAPI_METADATA_FACTORY() {
82
+ return {};
83
+ }
84
+ }
85
+ exports.LegacyCreateApprovalDataDto = LegacyCreateApprovalDataDto;
86
+ class LegacyPartialCreateApprovalDataDto extends (0, swagger_1.OmitType)(LegacyCreateApprovalDataDto, ['approvalId', 'created']) {
87
+ static _OPENAPI_METADATA_FACTORY() {
88
+ return {};
89
+ }
90
+ }
91
+ exports.LegacyPartialCreateApprovalDataDto = LegacyPartialCreateApprovalDataDto;
92
+ class ApprovalDataGroupDto {
93
+ validation;
94
+ validationData;
95
+ templateUrl;
96
+ data;
97
+ static _OPENAPI_METADATA_FACTORY() {
98
+ return { validation: { required: true, enum: require("../constants/sys03.constants").SaleProcessApprovalValidation }, validationData: { required: false, type: () => require("./validation-data.entity").ApprovalValidationDataDto }, templateUrl: { required: false, type: () => String }, data: { required: true, type: () => [require("./data.entity").ApprovalDataDto] } };
99
+ }
100
+ }
101
+ exports.ApprovalDataGroupDto = ApprovalDataGroupDto;
102
+ class ApprovalDataDtoBuilder extends helpers_1.Builder {
103
+ setDefaults() {
104
+ return {
105
+ id: faker_1.faker.number.int(),
106
+ approvalId: faker_1.faker.number.int(),
107
+ validation: faker_1.faker.helpers.enumValue(constants_1.SaleProcessApprovalValidation),
108
+ active: faker_1.faker.datatype.boolean(0.99),
109
+ approved: null,
110
+ created: new common_1.AuditFieldsDtoBuilder().build()
111
+ };
112
+ }
113
+ static _OPENAPI_METADATA_FACTORY() {
114
+ return {};
115
+ }
116
+ }
117
+ exports.ApprovalDataDtoBuilder = ApprovalDataDtoBuilder;
118
+ class PatchApprovalDataDto {
119
+ validation;
120
+ active;
121
+ approved;
122
+ notes;
123
+ static _OPENAPI_METADATA_FACTORY() {
124
+ return { validation: { required: false, enum: require("../constants/sys03.constants").SaleProcessApprovalValidation }, active: { required: false, type: () => Boolean }, approved: { required: false, type: () => Boolean }, notes: { required: false, type: () => String, maxLength: 1000 } };
125
+ }
126
+ }
127
+ exports.PatchApprovalDataDto = PatchApprovalDataDto;
128
+ __decorate([
129
+ (0, class_validator_1.IsBoolean)(),
130
+ (0, class_validator_1.IsDefined)(),
131
+ (0, class_validator_1.IsOptional)(),
132
+ (0, class_transformer_1.Expose)(),
133
+ __metadata("design:type", Boolean)
134
+ ], PatchApprovalDataDto.prototype, "approved", void 0);
135
+ __decorate([
136
+ (0, class_validator_1.IsString)(),
137
+ (0, class_validator_1.MaxLength)(1000),
138
+ (0, class_validator_1.IsOptional)(),
139
+ (0, class_transformer_1.Expose)(),
140
+ __metadata("design:type", String)
141
+ ], PatchApprovalDataDto.prototype, "notes", void 0);
@@ -0,0 +1,60 @@
1
+ import { BusinessCustomerType, CustomerType } from '../../common/constants';
2
+ import { PaginationQueryDto } from '../../common/common.entity';
3
+ import { BpCustomerAccountIndividualTitleType } from '../../bss/constants';
4
+ import { Builder } from '../../common/helpers/helpers';
5
+ import { SaleProcessCompanyIdentificationDto, SaleProcessIndividualIdentificationDto } from '../sale-process/identification.entity';
6
+ export declare class DashboardApprovalFilterDto extends PaginationQueryDto {
7
+ dateFrom?: string;
8
+ dateTo?: string;
9
+ saleProcessId?: number;
10
+ phone?: string;
11
+ shoppingCartPhone?: string;
12
+ owner?: string;
13
+ channel?: string;
14
+ customerType?: CustomerType;
15
+ id?: number;
16
+ approvedBy?: string;
17
+ approved?: 'all' | 'true' | 'false';
18
+ validation?: string;
19
+ }
20
+ export declare class ApprovalCustomerDto {
21
+ type: CustomerType;
22
+ identification?: SaleProcessIndividualIdentificationDto;
23
+ title?: BpCustomerAccountIndividualTitleType;
24
+ firstName?: string;
25
+ lastName: string;
26
+ email: string;
27
+ phones: string[];
28
+ }
29
+ export declare class ApprovalCustomerDtoBuilder extends Builder<ApprovalCustomerDto> {
30
+ setDefaults(): ApprovalCustomerDto;
31
+ }
32
+ export declare class ApprovalBusinessDto {
33
+ type: BusinessCustomerType;
34
+ tradingName: string;
35
+ legalName: string;
36
+ identification?: SaleProcessCompanyIdentificationDto;
37
+ }
38
+ export declare class ApprovalBusinessDtoBuilder extends Builder<ApprovalBusinessDto> {
39
+ setDefaults(): ApprovalBusinessDto;
40
+ }
41
+ declare const UpdateApprovalBusinessDto_base: import("@nestjs/common").Type<Partial<ApprovalBusinessDto>>;
42
+ export declare class UpdateApprovalBusinessDto extends UpdateApprovalBusinessDto_base {
43
+ }
44
+ export declare class ApprovalBillingDto {
45
+ firstName: string;
46
+ lastName: string;
47
+ identification?: SaleProcessIndividualIdentificationDto;
48
+ iban: string;
49
+ ibanValidationId?: string;
50
+ }
51
+ export declare class ApprovalBillingDtoBuilder extends Builder<ApprovalBillingDto> {
52
+ setDefaults(): ApprovalBillingDto;
53
+ }
54
+ declare const UpdateApprovalBillingDto_base: import("@nestjs/common").Type<Partial<ApprovalBillingDto>>;
55
+ export declare class UpdateApprovalBillingDto extends UpdateApprovalBillingDto_base {
56
+ }
57
+ export declare class UpdateApprovalSaleProcessActiveCustomerContactMediumValidationDto {
58
+ mobilePhone: string;
59
+ }
60
+ export {};
@@ -0,0 +1,199 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ 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;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.UpdateApprovalSaleProcessActiveCustomerContactMediumValidationDto = exports.UpdateApprovalBillingDto = exports.ApprovalBillingDtoBuilder = exports.ApprovalBillingDto = exports.UpdateApprovalBusinessDto = exports.ApprovalBusinessDtoBuilder = exports.ApprovalBusinessDto = exports.ApprovalCustomerDtoBuilder = exports.ApprovalCustomerDto = exports.DashboardApprovalFilterDto = void 0;
13
+ const swagger_1 = require("@nestjs/swagger");
14
+ const constants_1 = require("../../common/constants");
15
+ const _validators_1 = require("../../validators/index");
16
+ const class_transformer_1 = require("class-transformer");
17
+ const class_validator_1 = require("class-validator");
18
+ const common_entity_1 = require("../../common/common.entity");
19
+ const constants_2 = require("../../bss/constants");
20
+ const helpers_1 = require("../../common/helpers/helpers");
21
+ const faker_1 = require("@faker-js/faker");
22
+ class DashboardApprovalFilterDto extends common_entity_1.PaginationQueryDto {
23
+ dateFrom;
24
+ dateTo;
25
+ saleProcessId;
26
+ phone;
27
+ shoppingCartPhone;
28
+ owner;
29
+ channel;
30
+ customerType;
31
+ id;
32
+ approvedBy;
33
+ approved;
34
+ validation;
35
+ }
36
+ exports.DashboardApprovalFilterDto = DashboardApprovalFilterDto;
37
+ __decorate([
38
+ (0, class_validator_1.IsDateString)(),
39
+ (0, class_validator_1.IsNotEmpty)(),
40
+ (0, class_validator_1.IsOptional)(),
41
+ __metadata("design:type", String)
42
+ ], DashboardApprovalFilterDto.prototype, "dateFrom", void 0);
43
+ __decorate([
44
+ (0, class_validator_1.IsDateString)(),
45
+ (0, class_validator_1.IsNotEmpty)(),
46
+ (0, class_validator_1.IsOptional)(),
47
+ __metadata("design:type", String)
48
+ ], DashboardApprovalFilterDto.prototype, "dateTo", void 0);
49
+ __decorate([
50
+ (0, class_validator_1.IsInt)(),
51
+ (0, class_validator_1.Min)(1),
52
+ (0, class_validator_1.IsOptional)(),
53
+ (0, class_transformer_1.Transform)(({ value }) => Number(value)),
54
+ __metadata("design:type", Number)
55
+ ], DashboardApprovalFilterDto.prototype, "saleProcessId", void 0);
56
+ __decorate([
57
+ (0, class_validator_1.IsString)(),
58
+ (0, class_validator_1.IsNotEmpty)(),
59
+ (0, class_validator_1.IsOptional)(),
60
+ __metadata("design:type", String)
61
+ ], DashboardApprovalFilterDto.prototype, "phone", void 0);
62
+ __decorate([
63
+ (0, class_validator_1.IsString)(),
64
+ (0, class_validator_1.IsNotEmpty)(),
65
+ (0, class_validator_1.IsOptional)(),
66
+ __metadata("design:type", String)
67
+ ], DashboardApprovalFilterDto.prototype, "shoppingCartPhone", void 0);
68
+ __decorate([
69
+ (0, class_validator_1.IsString)(),
70
+ (0, class_validator_1.IsNotEmpty)(),
71
+ (0, class_validator_1.IsOptional)(),
72
+ __metadata("design:type", String)
73
+ ], DashboardApprovalFilterDto.prototype, "owner", void 0);
74
+ __decorate([
75
+ (0, class_validator_1.IsString)(),
76
+ (0, class_validator_1.IsOptional)(),
77
+ (0, class_transformer_1.Transform)(({ value }) => (typeof value === 'string' && value === 'all' ? undefined : value)),
78
+ __metadata("design:type", String)
79
+ ], DashboardApprovalFilterDto.prototype, "channel", void 0);
80
+ __decorate([
81
+ (0, class_validator_1.IsEnum)(constants_1.CustomerType),
82
+ (0, class_validator_1.IsOptional)(),
83
+ __metadata("design:type", String)
84
+ ], DashboardApprovalFilterDto.prototype, "customerType", void 0);
85
+ __decorate([
86
+ (0, class_validator_1.IsInt)(),
87
+ (0, class_validator_1.Min)(1),
88
+ (0, class_validator_1.IsOptional)(),
89
+ (0, class_transformer_1.Transform)(({ value }) => Number(value)),
90
+ __metadata("design:type", Number)
91
+ ], DashboardApprovalFilterDto.prototype, "id", void 0);
92
+ __decorate([
93
+ (0, class_validator_1.IsString)(),
94
+ (0, class_validator_1.IsNotEmpty)(),
95
+ (0, class_validator_1.IsOptional)(),
96
+ __metadata("design:type", String)
97
+ ], DashboardApprovalFilterDto.prototype, "approvedBy", void 0);
98
+ __decorate([
99
+ (0, class_validator_1.IsString)(),
100
+ (0, class_validator_1.IsNotEmpty)(),
101
+ (0, _validators_1.IsNotBlank)(),
102
+ (0, class_validator_1.IsOptional)(),
103
+ (0, class_transformer_1.Transform)(({ value }) => {
104
+ if (['all', 'true', 'false'].includes(value))
105
+ return value;
106
+ return undefined;
107
+ }),
108
+ __metadata("design:type", String)
109
+ ], DashboardApprovalFilterDto.prototype, "approved", void 0);
110
+ __decorate([
111
+ (0, class_validator_1.IsString)(),
112
+ (0, class_validator_1.IsNotEmpty)(),
113
+ (0, class_validator_1.IsOptional)(),
114
+ __metadata("design:type", String)
115
+ ], DashboardApprovalFilterDto.prototype, "validation", void 0);
116
+ class ApprovalCustomerDto {
117
+ type;
118
+ identification;
119
+ title;
120
+ firstName;
121
+ lastName;
122
+ email;
123
+ phones;
124
+ }
125
+ exports.ApprovalCustomerDto = ApprovalCustomerDto;
126
+ class ApprovalCustomerDtoBuilder extends helpers_1.Builder {
127
+ setDefaults() {
128
+ return {
129
+ type: faker_1.faker.helpers.enumValue(constants_1.CustomerType),
130
+ identification: undefined,
131
+ title: faker_1.faker.helpers.enumValue(constants_2.BpCustomerAccountIndividualTitleType),
132
+ firstName: faker_1.faker.person.firstName(),
133
+ lastName: faker_1.faker.person.lastName(),
134
+ email: faker_1.faker.internet.email(),
135
+ phones: faker_1.faker.helpers.arrayElements([
136
+ faker_1.faker.helpers.fromRegExp('[6789][0-9]{8}'),
137
+ faker_1.faker.helpers.fromRegExp('[6789][0-9]{8}'),
138
+ faker_1.faker.helpers.fromRegExp('[6789][0-9]{8}'),
139
+ faker_1.faker.helpers.fromRegExp('[6789][0-9]{8}'),
140
+ faker_1.faker.helpers.fromRegExp('[6789][0-9]{8}')
141
+ ], 2)
142
+ };
143
+ }
144
+ }
145
+ exports.ApprovalCustomerDtoBuilder = ApprovalCustomerDtoBuilder;
146
+ class ApprovalBusinessDto {
147
+ type;
148
+ tradingName;
149
+ legalName;
150
+ identification;
151
+ }
152
+ exports.ApprovalBusinessDto = ApprovalBusinessDto;
153
+ class ApprovalBusinessDtoBuilder extends helpers_1.Builder {
154
+ setDefaults() {
155
+ return {
156
+ type: faker_1.faker.helpers.enumValue(constants_1.BusinessCustomerType),
157
+ tradingName: faker_1.faker.company.name(),
158
+ legalName: faker_1.faker.company.name(),
159
+ identification: undefined
160
+ };
161
+ }
162
+ }
163
+ exports.ApprovalBusinessDtoBuilder = ApprovalBusinessDtoBuilder;
164
+ class UpdateApprovalBusinessDto extends (0, swagger_1.PartialType)(ApprovalBusinessDto) {
165
+ }
166
+ exports.UpdateApprovalBusinessDto = UpdateApprovalBusinessDto;
167
+ class ApprovalBillingDto {
168
+ firstName;
169
+ lastName;
170
+ identification;
171
+ iban;
172
+ ibanValidationId;
173
+ }
174
+ exports.ApprovalBillingDto = ApprovalBillingDto;
175
+ class ApprovalBillingDtoBuilder extends helpers_1.Builder {
176
+ setDefaults() {
177
+ return {
178
+ firstName: faker_1.faker.person.firstName(),
179
+ lastName: faker_1.faker.person.lastName(),
180
+ identification: undefined,
181
+ iban: faker_1.faker.finance.iban({ countryCode: 'ES' })
182
+ };
183
+ }
184
+ }
185
+ exports.ApprovalBillingDtoBuilder = ApprovalBillingDtoBuilder;
186
+ class UpdateApprovalBillingDto extends (0, swagger_1.PartialType)(ApprovalBillingDto) {
187
+ }
188
+ exports.UpdateApprovalBillingDto = UpdateApprovalBillingDto;
189
+ class UpdateApprovalSaleProcessActiveCustomerContactMediumValidationDto {
190
+ mobilePhone;
191
+ }
192
+ exports.UpdateApprovalSaleProcessActiveCustomerContactMediumValidationDto = UpdateApprovalSaleProcessActiveCustomerContactMediumValidationDto;
193
+ __decorate([
194
+ (0, class_validator_1.IsString)(),
195
+ (0, class_validator_1.IsNotEmpty)(),
196
+ (0, _validators_1.IsNotBlank)(),
197
+ (0, class_transformer_1.Expose)(),
198
+ __metadata("design:type", String)
199
+ ], UpdateApprovalSaleProcessActiveCustomerContactMediumValidationDto.prototype, "mobilePhone", void 0);
@@ -0,0 +1,31 @@
1
+ import { AuditFieldsDto, AuditFieldsWithValueDto, CreateAuditFieldsDto } from '../../common';
2
+ import { ApprovalDataDto, CreateApprovalDataDto } from '../data.entity';
3
+ import { ApprovalValidationDataDto } from '../validation-data.entity';
4
+ import { SaleProcessApprovalValidation } from '../../constants';
5
+ import { ApprovalBillingDto, ApprovalBusinessDto, ApprovalCustomerDto } from '../entity';
6
+ import { GenericSaleProcessCoverageApartmentDto } from '../../generic-sale-process';
7
+ export declare class GenericApprovalDto {
8
+ id: number;
9
+ saleProcessId: number;
10
+ saleProcessIbanValidationId?: string;
11
+ data?: ApprovalDataDto[];
12
+ validationData?: ApprovalValidationDataDto[];
13
+ validations: SaleProcessApprovalValidation[];
14
+ owner: string;
15
+ channel: string;
16
+ apartment: GenericSaleProcessCoverageApartmentDto;
17
+ customer: ApprovalCustomerDto;
18
+ billing: ApprovalBillingDto;
19
+ business?: ApprovalBusinessDto;
20
+ shoppingCartId?: string;
21
+ shoppingCartPhones?: string[];
22
+ created: AuditFieldsDto;
23
+ updated?: AuditFieldsDto;
24
+ approved?: AuditFieldsWithValueDto;
25
+ }
26
+ declare const CreateGenericApprovalDto_base: import("@nestjs/common").Type<Pick<GenericApprovalDto, "business" | "channel" | "owner" | "shoppingCartId" | "apartment" | "saleProcessId" | "billing" | "customer" | "saleProcessIbanValidationId" | "validations" | "shoppingCartPhones">>;
27
+ export declare class CreateGenericApprovalDto extends CreateGenericApprovalDto_base {
28
+ data: CreateApprovalDataDto[];
29
+ created: CreateAuditFieldsDto;
30
+ }
31
+ export {};
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CreateGenericApprovalDto = exports.GenericApprovalDto = void 0;
4
+ const swagger_1 = require("@nestjs/swagger");
5
+ class GenericApprovalDto {
6
+ id;
7
+ saleProcessId;
8
+ saleProcessIbanValidationId;
9
+ data;
10
+ validationData;
11
+ validations;
12
+ owner;
13
+ channel;
14
+ apartment;
15
+ customer;
16
+ billing;
17
+ business;
18
+ shoppingCartId;
19
+ shoppingCartPhones;
20
+ created;
21
+ updated;
22
+ approved;
23
+ }
24
+ exports.GenericApprovalDto = GenericApprovalDto;
25
+ class CreateGenericApprovalDto extends (0, swagger_1.PickType)(GenericApprovalDto, [
26
+ 'saleProcessId',
27
+ 'saleProcessIbanValidationId',
28
+ 'validations',
29
+ 'owner',
30
+ 'channel',
31
+ 'apartment',
32
+ 'customer',
33
+ 'billing',
34
+ 'business',
35
+ 'shoppingCartId',
36
+ 'shoppingCartPhones'
37
+ ]) {
38
+ data;
39
+ created;
40
+ }
41
+ exports.CreateGenericApprovalDto = CreateGenericApprovalDto;
@@ -0,0 +1 @@
1
+ export * from './entity';
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./entity"), exports);