adamo-types 2.1.46-sit → 2.1.47-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.
- package/dist/sys03/approval/data.entity.d.ts +63 -0
- package/dist/sys03/approval/data.entity.js +141 -0
- package/dist/sys03/approval/entity.d.ts +60 -0
- package/dist/sys03/approval/entity.js +199 -0
- package/dist/sys03/approval/generic/entity.d.ts +31 -0
- package/dist/sys03/approval/generic/entity.js +41 -0
- package/dist/sys03/approval/generic/index.d.ts +1 -0
- package/dist/sys03/approval/generic/index.js +17 -0
- package/dist/sys03/approval/index.d.ts +5 -1
- package/dist/sys03/approval/index.js +5 -1
- package/dist/sys03/approval/main/entity.d.ts +57 -0
- package/dist/sys03/approval/main/entity.js +112 -0
- package/dist/sys03/approval/main/index.d.ts +1 -0
- package/dist/sys03/approval/main/index.js +17 -0
- package/dist/sys03/approval/validation-data.entity.d.ts +22 -0
- package/dist/sys03/approval/validation-data.entity.js +49 -0
- package/dist/sys03/customer-handover-process/customer-handover-process.entity.d.ts +2 -2
- package/dist/sys03/generic-sale-process/constants.d.ts +1 -0
- package/dist/sys03/generic-sale-process/constants.js +1 -0
- package/dist/sys03/generic-sale-process/entity.d.ts +5 -3
- package/dist/sys03/generic-sale-process/entity.js +7 -4
- package/dist/sys03/sale-process/sale-process.entity.d.ts +2 -2
- package/dist/sys03/sale-process/sale-process.entity.js +4 -4
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/dist/sys03/approval/approval.entity.d.ts +0 -179
- package/dist/sys03/approval/approval.entity.js +0 -504
|
@@ -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);
|
|
@@ -14,4 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./generic"), exports);
|
|
18
|
+
__exportStar(require("./main"), exports);
|
|
19
|
+
__exportStar(require("./data.entity"), exports);
|
|
20
|
+
__exportStar(require("./entity"), exports);
|
|
21
|
+
__exportStar(require("./validation-data.entity"), exports);
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { SaleProcessApprovalValidation } from '../../constants';
|
|
2
|
+
import { ApprovalDataDto, ApprovalDataGroupDto, LegacyCreateApprovalDataDto } from '../data.entity';
|
|
3
|
+
import { ApprovalValidationDataDto } from '../validation-data.entity';
|
|
4
|
+
import { ApprovalBillingDto, ApprovalBusinessDto, ApprovalCustomerDto, UpdateApprovalBillingDto, UpdateApprovalBusinessDto } from '../entity';
|
|
5
|
+
import { AuditFieldsDto, AuditFieldsWithValueDto } from '../../common';
|
|
6
|
+
import { SaleProcessDto } from '../../../zoho/sale-process';
|
|
7
|
+
import { PartialSaleProcessBillingInfoBaseWithIdentificationDto, PartialSaleProcessBillingInfoFirstAndLastNameDto, PartialSaleProcessCustomerBaseWithoutTypeDto } from '../../../common/edge-zoho';
|
|
8
|
+
export declare class ApprovalDto {
|
|
9
|
+
id: number;
|
|
10
|
+
saleProcessId: number;
|
|
11
|
+
saleProcessIbanValidationId?: string;
|
|
12
|
+
data?: ApprovalDataDto[];
|
|
13
|
+
validationData?: ApprovalValidationDataDto[];
|
|
14
|
+
validations: SaleProcessApprovalValidation[];
|
|
15
|
+
owner: string;
|
|
16
|
+
channel: string;
|
|
17
|
+
apartmentId: string;
|
|
18
|
+
customer: ApprovalCustomerDto;
|
|
19
|
+
billing: ApprovalBillingDto;
|
|
20
|
+
business?: ApprovalBusinessDto;
|
|
21
|
+
shoppingCartId?: string;
|
|
22
|
+
shoppingCartPhones?: string[];
|
|
23
|
+
created: AuditFieldsDto;
|
|
24
|
+
updated?: AuditFieldsDto;
|
|
25
|
+
approved?: AuditFieldsWithValueDto;
|
|
26
|
+
}
|
|
27
|
+
declare const CreateApprovalDto_base: import("@nestjs/common").Type<Omit<ApprovalDto, "id" | "updated" | "data" | "approved">>;
|
|
28
|
+
export declare class CreateApprovalDto extends CreateApprovalDto_base {
|
|
29
|
+
}
|
|
30
|
+
declare const PartialCreateApprovalDto_base: import("@nestjs/common").Type<Omit<CreateApprovalDto, "created">>;
|
|
31
|
+
export declare class PartialCreateApprovalDto extends PartialCreateApprovalDto_base {
|
|
32
|
+
}
|
|
33
|
+
declare const UpdateApprovalCustomerDto_base: import("@nestjs/common").Type<Partial<Pick<ApprovalCustomerDto, "title" | "firstName" | "lastName" | "identification" | "phones">>>;
|
|
34
|
+
export declare class UpdateApprovalCustomerDto extends UpdateApprovalCustomerDto_base {
|
|
35
|
+
}
|
|
36
|
+
declare const UpdateApprovalDto_base: import("@nestjs/common").Type<Partial<Pick<ApprovalDto, "updated" | "approved" | "validations">>>;
|
|
37
|
+
export declare class UpdateApprovalDto extends UpdateApprovalDto_base {
|
|
38
|
+
customer?: UpdateApprovalCustomerDto;
|
|
39
|
+
billing?: UpdateApprovalBillingDto;
|
|
40
|
+
business?: UpdateApprovalBusinessDto;
|
|
41
|
+
saleProcess?: SaleProcessDto;
|
|
42
|
+
data?: LegacyCreateApprovalDataDto[];
|
|
43
|
+
}
|
|
44
|
+
export declare class ApprovalWithGroupsDto extends ApprovalDto {
|
|
45
|
+
groups: ApprovalDataGroupDto[];
|
|
46
|
+
}
|
|
47
|
+
export declare class UpdateApprovalSaleProcessDto {
|
|
48
|
+
validation: SaleProcessApprovalValidation;
|
|
49
|
+
saleProcess: any;
|
|
50
|
+
}
|
|
51
|
+
export declare class UpdateApprovalSaleProcessIbanValidationDto {
|
|
52
|
+
iban: string;
|
|
53
|
+
billingInfo?: PartialSaleProcessBillingInfoFirstAndLastNameDto;
|
|
54
|
+
customer?: PartialSaleProcessCustomerBaseWithoutTypeDto;
|
|
55
|
+
businessInfo?: PartialSaleProcessBillingInfoBaseWithIdentificationDto;
|
|
56
|
+
}
|
|
57
|
+
export {};
|