@silexpert/core 2.0.56 → 2.0.58-zendesk
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/api/resources/CommercialDocument.d.ts +4 -1
- package/dist/api/resources/CommercialDocument.d.ts.map +1 -1
- package/dist/api/resources/CommercialDocument.js +9 -0
- package/dist/api/resources/CommercialDocument.js.map +1 -1
- package/dist/api/resources/zendesk/Ticket.d.ts +12 -0
- package/dist/api/resources/zendesk/Ticket.d.ts.map +1 -0
- package/dist/api/resources/zendesk/Ticket.js +40 -0
- package/dist/api/resources/zendesk/Ticket.js.map +1 -0
- package/dist/api/resources.d.ts +2 -0
- package/dist/api/resources.d.ts.map +1 -1
- package/dist/api/resources.js +2 -0
- package/dist/api/resources.js.map +1 -1
- package/dist/types/Enum/Annotation.d.ts +4 -0
- package/dist/types/Enum/Annotation.d.ts.map +1 -1
- package/dist/types/Enum/Annotation.js +2 -0
- package/dist/types/Enum/Annotation.js.map +1 -1
- package/dist/types/Enum/BalanceSheet.d.ts +1 -1
- package/dist/types/Enum/BalanceSheet.js +1 -1
- package/dist/types/Enum/BalanceSheet.js.map +1 -1
- package/dist/types/Enum/BrandClementine.d.ts.map +1 -1
- package/dist/types/Enum/BrandClementine.js +1 -0
- package/dist/types/Enum/BrandClementine.js.map +1 -1
- package/dist/types/Enum/CustomerSignature.d.ts +2 -1
- package/dist/types/Enum/CustomerSignature.d.ts.map +1 -1
- package/dist/types/Enum/CustomerSignature.js +1 -0
- package/dist/types/Enum/CustomerSignature.js.map +1 -1
- package/dist/types/Enum/EInvoicingDirection.d.ts +5 -0
- package/dist/types/Enum/EInvoicingDirection.d.ts.map +1 -0
- package/dist/types/Enum/EInvoicingDirection.js +6 -0
- package/dist/types/Enum/EInvoicingDirection.js.map +1 -0
- package/dist/types/Enum/EInvoicingReasonType.d.ts +44 -0
- package/dist/types/Enum/EInvoicingReasonType.d.ts.map +1 -0
- package/dist/types/Enum/EInvoicingReasonType.js +143 -0
- package/dist/types/Enum/EInvoicingReasonType.js.map +1 -0
- package/dist/types/Enum/EInvoicingStatusCode.d.ts +16 -0
- package/dist/types/Enum/EInvoicingStatusCode.d.ts.map +1 -0
- package/dist/types/Enum/EInvoicingStatusCode.js +20 -0
- package/dist/types/Enum/EInvoicingStatusCode.js.map +1 -0
- package/dist/types/Enum/MimeType.d.ts +2 -0
- package/dist/types/Enum/MimeType.d.ts.map +1 -1
- package/dist/types/Enum/MimeType.js +1 -0
- package/dist/types/Enum/MimeType.js.map +1 -1
- package/dist/types/Enum/SalesContractBrandClementine.js +1 -1
- package/dist/types/Enum/SalesContractBrandClementine.js.map +1 -1
- package/dist/types/Enum/Unit.d.ts +2 -0
- package/dist/types/Enum/Unit.d.ts.map +1 -1
- package/dist/types/Enum/Unit.js +22 -0
- package/dist/types/Enum/Unit.js.map +1 -1
- package/dist/types/Enum/Zendesk.d.ts +40 -0
- package/dist/types/Enum/Zendesk.d.ts.map +1 -0
- package/dist/types/Enum/Zendesk.js +40 -0
- package/dist/types/Enum/Zendesk.js.map +1 -0
- package/dist/types/Interface/api/accountingEntry/AnnotateAccountingTransaction.d.ts +1 -0
- package/dist/types/Interface/api/accountingEntry/AnnotateAccountingTransaction.d.ts.map +1 -1
- package/dist/types/Interface/api/accountingEntry/AnnotateAccountingTransaction.js.map +1 -1
- package/dist/types/Interface/api/commercialManagement/Read.d.ts +113 -0
- package/dist/types/Interface/api/commercialManagement/Read.d.ts.map +1 -1
- package/dist/types/Interface/api/commercialManagement/Read.js.map +1 -1
- package/dist/types/Interface/api/docoon/Create.d.ts +17 -0
- package/dist/types/Interface/api/docoon/Create.d.ts.map +1 -1
- package/dist/types/Interface/api/docoon/Create.js +72 -1
- package/dist/types/Interface/api/docoon/Create.js.map +1 -1
- package/dist/types/Interface/api/docoon/DocoonInvoice.d.ts +195 -0
- package/dist/types/Interface/api/docoon/DocoonInvoice.d.ts.map +1 -0
- package/dist/types/Interface/api/docoon/DocoonInvoice.js +2 -0
- package/dist/types/Interface/api/docoon/DocoonInvoice.js.map +1 -0
- package/dist/types/Interface/api/docoon/Query.js +1 -1
- package/dist/types/Interface/api/docoon/Query.js.map +1 -1
- package/dist/types/Interface/api/society/QueryUnpaid.d.ts +4 -0
- package/dist/types/Interface/api/society/QueryUnpaid.d.ts.map +1 -1
- package/dist/types/Interface/api/society/QueryUnpaid.js +27 -0
- package/dist/types/Interface/api/society/QueryUnpaid.js.map +1 -1
- package/dist/types/Interface/api/thirdParty/CreateThirdPartyForm.d.ts +2 -0
- package/dist/types/Interface/api/thirdParty/CreateThirdPartyForm.d.ts.map +1 -1
- package/dist/types/Interface/api/thirdParty/CreateThirdPartyForm.js +10 -0
- package/dist/types/Interface/api/thirdParty/CreateThirdPartyForm.js.map +1 -1
- package/dist/types/Interface/api/thirdParty/UpdateThirdPartyForm.d.ts +2 -0
- package/dist/types/Interface/api/thirdParty/UpdateThirdPartyForm.d.ts.map +1 -1
- package/dist/types/Interface/api/thirdParty/UpdateThirdPartyForm.js +12 -0
- package/dist/types/Interface/api/thirdParty/UpdateThirdPartyForm.js.map +1 -1
- package/dist/types/Interface/api/zendesk/QueryTicket.d.ts +39 -0
- package/dist/types/Interface/api/zendesk/QueryTicket.d.ts.map +1 -0
- package/dist/types/Interface/api/zendesk/QueryTicket.js +244 -0
- package/dist/types/Interface/api/zendesk/QueryTicket.js.map +1 -0
- package/dist/types/Interface/api/zendesk/ReadTicket.d.ts +99 -0
- package/dist/types/Interface/api/zendesk/ReadTicket.d.ts.map +1 -0
- package/dist/types/Interface/api/zendesk/ReadTicket.js +2 -0
- package/dist/types/Interface/api/zendesk/ReadTicket.js.map +1 -0
- package/dist/types/Interface/models/IAccountingFile.d.ts +10 -0
- package/dist/types/Interface/models/IAccountingFile.d.ts.map +1 -1
- package/dist/types/Interface/models/IAccountingFile.js +8 -0
- package/dist/types/Interface/models/IAccountingFile.js.map +1 -1
- package/dist/types/Interface/models/IAccountingTransaction.d.ts +3 -0
- package/dist/types/Interface/models/IAccountingTransaction.d.ts.map +1 -1
- package/dist/types/Interface/models/IAccountingTransaction.js +2 -0
- package/dist/types/Interface/models/IAccountingTransaction.js.map +1 -1
- package/dist/types/Interface/models/IEInvoicing.d.ts +18 -0
- package/dist/types/Interface/models/IEInvoicing.d.ts.map +1 -0
- package/dist/types/Interface/models/IEInvoicing.js +13 -0
- package/dist/types/Interface/models/IEInvoicing.js.map +1 -0
- package/dist/types/Interface/models/IEInvoicingStatus.d.ts +17 -0
- package/dist/types/Interface/models/IEInvoicingStatus.d.ts.map +1 -0
- package/dist/types/Interface/models/IEInvoicingStatus.js +13 -0
- package/dist/types/Interface/models/IEInvoicingStatus.js.map +1 -0
- package/dist/types/Interface/models/IPayment.d.ts +3 -0
- package/dist/types/Interface/models/IPayment.d.ts.map +1 -1
- package/dist/types/Interface/models/IPayment.js +2 -0
- package/dist/types/Interface/models/IPayment.js.map +1 -1
- package/dist/types/Interface/models/ISocietyDetail.d.ts +1 -0
- package/dist/types/Interface/models/ISocietyDetail.d.ts.map +1 -1
- package/dist/types/Interface/models/ISocietyDetail.js +1 -0
- package/dist/types/Interface/models/ISocietyDetail.js.map +1 -1
- package/dist/types/Interface/models/IThirdParty.d.ts +2 -0
- package/dist/types/Interface/models/IThirdParty.d.ts.map +1 -1
- package/dist/types/Interface/models/IThirdParty.js +2 -0
- package/dist/types/Interface/models/IThirdParty.js.map +1 -1
- package/dist/types/index.d.ts +13 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +13 -0
- package/dist/types/index.js.map +1 -1
- package/dist/utils/prestation.d.ts.map +1 -1
- package/dist/utils/prestation.js +7 -3
- package/dist/utils/prestation.js.map +1 -1
- package/dist/utils/vat/centuries.d.ts.map +1 -1
- package/dist/utils/vat/centuries.js +11 -1
- package/dist/utils/vat/centuries.js.map +1 -1
- package/package.json +1 -1
- package/ts/api/resources/CommercialDocument.ts +16 -0
- package/ts/api/resources/zendesk/Ticket.ts +58 -0
- package/ts/api/resources.ts +2 -0
- package/ts/types/Enum/Annotation.ts +3 -0
- package/ts/types/Enum/BalanceSheet.ts +1 -1
- package/ts/types/Enum/BrandClementine.ts +1 -0
- package/ts/types/Enum/CustomerSignature.ts +2 -1
- package/ts/types/Enum/EInvoicingDirection.ts +4 -0
- package/ts/types/Enum/EInvoicingReasonType.ts +156 -0
- package/ts/types/Enum/EInvoicingStatusCode.ts +18 -0
- package/ts/types/Enum/MimeType.ts +1 -0
- package/ts/types/Enum/SalesContractBrandClementine.ts +1 -1
- package/ts/types/Enum/Unit.ts +24 -1
- package/ts/types/Enum/Zendesk.ts +56 -0
- package/ts/types/Interface/api/accountingEntry/AnnotateAccountingTransaction.ts +1 -0
- package/ts/types/Interface/api/commercialManagement/Read.ts +110 -0
- package/ts/types/Interface/api/docoon/Create.ts +46 -0
- package/ts/types/Interface/api/docoon/DocoonInvoice.ts +201 -0
- package/ts/types/Interface/api/docoon/Query.ts +1 -1
- package/ts/types/Interface/api/society/QueryUnpaid.ts +19 -0
- package/ts/types/Interface/api/thirdParty/CreateThirdPartyForm.ts +6 -0
- package/ts/types/Interface/api/thirdParty/UpdateThirdPartyForm.ts +8 -0
- package/ts/types/Interface/api/zendesk/QueryTicket.ts +192 -0
- package/ts/types/Interface/api/zendesk/ReadTicket.ts +110 -0
- package/ts/types/Interface/models/IAccountingFile.ts +10 -0
- package/ts/types/Interface/models/IAccountingTransaction.ts +3 -0
- package/ts/types/Interface/models/IEInvoicing.ts +21 -0
- package/ts/types/Interface/models/IEInvoicingStatus.ts +18 -0
- package/ts/types/Interface/models/IPayment.ts +3 -0
- package/ts/types/Interface/models/ISocietyDetail.ts +1 -0
- package/ts/types/Interface/models/IThirdParty.ts +2 -0
- package/ts/types/index.ts +13 -0
- package/ts/utils/prestation.ts +9 -3
- package/ts/utils/vat/centuries.ts +11 -1
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
export type DocoonInvoice = {
|
|
2
|
+
numeroFacture: string;
|
|
3
|
+
dateEmission: string;
|
|
4
|
+
codeType: string;
|
|
5
|
+
codeDevise: string;
|
|
6
|
+
codeDateExigibiliteTva: string;
|
|
7
|
+
dateEcheance: string;
|
|
8
|
+
referenceAcheteur: string;
|
|
9
|
+
referenceBonCommande: string;
|
|
10
|
+
numeroOrdreVente: string;
|
|
11
|
+
identifiantObjetFacture: string;
|
|
12
|
+
identifiantSchema: string;
|
|
13
|
+
referenceComptableAcheteur: string;
|
|
14
|
+
conditionPaiement: string;
|
|
15
|
+
noteDeFacture: Array<{
|
|
16
|
+
codeSujetNote: string;
|
|
17
|
+
noteFacture: string;
|
|
18
|
+
}>;
|
|
19
|
+
controleDuProcessus: {
|
|
20
|
+
typeProcessus: string;
|
|
21
|
+
typeProfil: string;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* THIRDPARTY
|
|
25
|
+
*/
|
|
26
|
+
vendeur: {
|
|
27
|
+
raisonSociale: string;
|
|
28
|
+
appellationCommerciale: string;
|
|
29
|
+
identifiantPrive: Array<{
|
|
30
|
+
identifiant: string;
|
|
31
|
+
identifiantSchema: string;
|
|
32
|
+
}>;
|
|
33
|
+
numeroSiren: string;
|
|
34
|
+
identifiantSchemaIdentifiant: string;
|
|
35
|
+
identifiantFiscal: Array<{
|
|
36
|
+
qualifiantIdentifiantFiscal: string;
|
|
37
|
+
identifiantTva: string;
|
|
38
|
+
}>;
|
|
39
|
+
email: string;
|
|
40
|
+
identifiantEmail: string;
|
|
41
|
+
formeJuridique: string;
|
|
42
|
+
adressePostale: {
|
|
43
|
+
adresse1: string;
|
|
44
|
+
adresse2: string | null;
|
|
45
|
+
localite: string;
|
|
46
|
+
cp: string;
|
|
47
|
+
codePays: string;
|
|
48
|
+
};
|
|
49
|
+
contact: {
|
|
50
|
+
pointContact: string;
|
|
51
|
+
telephone: string;
|
|
52
|
+
email: string;
|
|
53
|
+
};
|
|
54
|
+
countryCodeFR: boolean;
|
|
55
|
+
};
|
|
56
|
+
//
|
|
57
|
+
acheteur: {
|
|
58
|
+
raisonSociale: string;
|
|
59
|
+
appellationCommerciale?: string;
|
|
60
|
+
identifiantPrive: Array<{
|
|
61
|
+
identifiant: string;
|
|
62
|
+
identifiantSchema: string;
|
|
63
|
+
}>;
|
|
64
|
+
numeroSiren: string;
|
|
65
|
+
identifiantSchemaIdentifiant: string;
|
|
66
|
+
identifiantFiscal: Array<{
|
|
67
|
+
qualifiantIdentifiantFiscal: string;
|
|
68
|
+
identifiantTva: string;
|
|
69
|
+
}>;
|
|
70
|
+
email: string;
|
|
71
|
+
identifiantEmail: string;
|
|
72
|
+
adressePostale: {
|
|
73
|
+
adresse1: string;
|
|
74
|
+
adresse2: string | null;
|
|
75
|
+
localite: string;
|
|
76
|
+
cp: string;
|
|
77
|
+
codePays: string;
|
|
78
|
+
};
|
|
79
|
+
contact: {
|
|
80
|
+
pointContact: string;
|
|
81
|
+
telephone: string;
|
|
82
|
+
email: string;
|
|
83
|
+
};
|
|
84
|
+
countryCodeFR: boolean;
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
informationsDeLivraisonPresentationDeService: {
|
|
88
|
+
lieuLivraison: string;
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
periodeDeFacturation: {
|
|
92
|
+
dateDebut: string;
|
|
93
|
+
dateFin: string;
|
|
94
|
+
};
|
|
95
|
+
adresseDeLivraisonRealisationPrestationDeService: {
|
|
96
|
+
adresse1: string;
|
|
97
|
+
adresse2: string | null;
|
|
98
|
+
localite: string;
|
|
99
|
+
cp: string;
|
|
100
|
+
codePays: string;
|
|
101
|
+
};
|
|
102
|
+
instructionsDePaiement: {
|
|
103
|
+
codeMoyen: string;
|
|
104
|
+
libelleMoyen: 'Virement';
|
|
105
|
+
avis: string;
|
|
106
|
+
virement: {
|
|
107
|
+
identifiantComptePaiement: string;
|
|
108
|
+
nomComptePaiement: string;
|
|
109
|
+
identifiantPrestatairePaiement: string;
|
|
110
|
+
};
|
|
111
|
+
};
|
|
112
|
+
totauxDuDocument: {
|
|
113
|
+
sommeMontantNetLigne: number;
|
|
114
|
+
sommeRemiseDocument: number;
|
|
115
|
+
sommeChargeDocument: number;
|
|
116
|
+
montantTotalFactureHorsTva: number;
|
|
117
|
+
montantTotalTvaFacture: number;
|
|
118
|
+
montantTotalFactureAvecTva: number;
|
|
119
|
+
montantPaye: number;
|
|
120
|
+
montantAPayer: number;
|
|
121
|
+
};
|
|
122
|
+
ventilationDeLaTva: Array<{
|
|
123
|
+
baseImpositionTva: number;
|
|
124
|
+
montantTypeTva: number;
|
|
125
|
+
codeTypeTva: string;
|
|
126
|
+
tauxTypeTva: number;
|
|
127
|
+
}>;
|
|
128
|
+
ligneDeFacture: Array<{
|
|
129
|
+
identifiant: string;
|
|
130
|
+
quantiteFacture: number;
|
|
131
|
+
codeQuantiteFacture: string;
|
|
132
|
+
montantNetFacture: number;
|
|
133
|
+
detailDuPrix: {
|
|
134
|
+
prixNet: number;
|
|
135
|
+
rabaisPrix: number;
|
|
136
|
+
prixBrut: number;
|
|
137
|
+
quantiteBasePrix: number;
|
|
138
|
+
codeQuantitePrix: string;
|
|
139
|
+
};
|
|
140
|
+
informationSurLaTva: {
|
|
141
|
+
codeTypeTva: string;
|
|
142
|
+
tauxTva: number;
|
|
143
|
+
};
|
|
144
|
+
informationSurArticle: {
|
|
145
|
+
designation: string;
|
|
146
|
+
description: string;
|
|
147
|
+
};
|
|
148
|
+
}>;
|
|
149
|
+
};
|
|
150
|
+
|
|
151
|
+
export type ReadDocoonSearch = {
|
|
152
|
+
total: number;
|
|
153
|
+
offset: number;
|
|
154
|
+
limit: number;
|
|
155
|
+
filter: {
|
|
156
|
+
limit: number;
|
|
157
|
+
offset: number;
|
|
158
|
+
where: {
|
|
159
|
+
updatedAfter: string;
|
|
160
|
+
flowType: DocoonFlowType[];
|
|
161
|
+
};
|
|
162
|
+
};
|
|
163
|
+
result: ReadDocoonResultSearch[];
|
|
164
|
+
};
|
|
165
|
+
|
|
166
|
+
export type ReadDocoonResultSearch = {
|
|
167
|
+
documentId: string;
|
|
168
|
+
structureId: string;
|
|
169
|
+
submittedAt: string;
|
|
170
|
+
updatedAt: string;
|
|
171
|
+
flowId: string;
|
|
172
|
+
trackingId: string;
|
|
173
|
+
flowDirection: DocoonFlowDirection;
|
|
174
|
+
flowType: DocoonFlowType;
|
|
175
|
+
flowStatus: string;
|
|
176
|
+
flowSyntax: DocoonFlowSyntax;
|
|
177
|
+
flowProfile: string;
|
|
178
|
+
flowCategory: DocoonFlowCategory;
|
|
179
|
+
isRead: boolean;
|
|
180
|
+
documentTypeCode: string;
|
|
181
|
+
documentStatus: string;
|
|
182
|
+
name: string;
|
|
183
|
+
acknowledgement: DocoonFlowAcknowledgement;
|
|
184
|
+
};
|
|
185
|
+
|
|
186
|
+
export type DocoonFlowAcknowledgement = {
|
|
187
|
+
status: 'Ok' | 'Error';
|
|
188
|
+
details: Array<{
|
|
189
|
+
level: string | null;
|
|
190
|
+
item: string | null;
|
|
191
|
+
reasonCode: string | null;
|
|
192
|
+
reasonMessage: string | null;
|
|
193
|
+
fullMessage: string | null;
|
|
194
|
+
}>;
|
|
195
|
+
};
|
|
196
|
+
export type DocoonFlowType = 'CustomerInvoice' | 'SupplierInvoice';
|
|
197
|
+
export type DocoonFlowDirection = 'In' | 'Out';
|
|
198
|
+
export type DocoonFlowSyntax = 'UBL' | 'CII' | 'Factur-X';
|
|
199
|
+
export type DocoonFlowCategory = 'FLUX1' | 'FLUX2' | 'FLUX3' | 'FLUX4' | 'FLUX5' | 'FLUX6';
|
|
200
|
+
|
|
201
|
+
export type DocoonFlowDocType = 'Original' | 'ReadableView';
|
|
@@ -47,6 +47,25 @@ export class QueryUnpaidSociety {
|
|
|
47
47
|
@IsInt({ each: true })
|
|
48
48
|
listIdPrestationList?: number[];
|
|
49
49
|
|
|
50
|
+
@ApiPropertyOptional()
|
|
51
|
+
@IsOptional()
|
|
52
|
+
@IsInt()
|
|
53
|
+
month?: number;
|
|
54
|
+
|
|
55
|
+
@ApiPropertyOptional()
|
|
56
|
+
@IsOptional()
|
|
57
|
+
@IsInt()
|
|
58
|
+
year?: number;
|
|
59
|
+
|
|
60
|
+
@ApiPropertyOptional()
|
|
61
|
+
@IsOptional()
|
|
62
|
+
@IsInt()
|
|
63
|
+
idPaymentMethod?: number;
|
|
64
|
+
|
|
65
|
+
@ApiPropertyOptional()
|
|
66
|
+
@IsOptional()
|
|
67
|
+
order?: [string, 'ASC' | 'DESC'];
|
|
68
|
+
|
|
50
69
|
@ApiPropertyOptional({ default: 25 })
|
|
51
70
|
@IsOptional()
|
|
52
71
|
@IsInt()
|
|
@@ -33,6 +33,12 @@ export class CreateThirdPartyForm {
|
|
|
33
33
|
@ApiPropertyOptional()
|
|
34
34
|
nSiret?: string | null;
|
|
35
35
|
|
|
36
|
+
@ApiPropertyOptional()
|
|
37
|
+
isPrivateIndividual?: boolean | null;
|
|
38
|
+
|
|
39
|
+
@ApiPropertyOptional()
|
|
40
|
+
addressingIdentifier?: string | null;
|
|
41
|
+
|
|
36
42
|
@ApiPropertyOptional()
|
|
37
43
|
nTva?: string | null;
|
|
38
44
|
|
|
@@ -43,6 +43,14 @@ export class UpdateThirdPartyForm {
|
|
|
43
43
|
@IsOptional()
|
|
44
44
|
nSiret?: string | null;
|
|
45
45
|
|
|
46
|
+
@ApiPropertyOptional()
|
|
47
|
+
@IsOptional()
|
|
48
|
+
isPrivateIndividual?: boolean | null;
|
|
49
|
+
|
|
50
|
+
@ApiPropertyOptional()
|
|
51
|
+
@IsOptional()
|
|
52
|
+
addressingIdentifier?: string | null;
|
|
53
|
+
|
|
46
54
|
@ApiPropertyOptional()
|
|
47
55
|
@IsOptional()
|
|
48
56
|
nTva?: string | null;
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import {
|
|
2
|
+
IsString,
|
|
3
|
+
IsNotEmpty,
|
|
4
|
+
IsOptional,
|
|
5
|
+
IsEnum,
|
|
6
|
+
IsArray,
|
|
7
|
+
IsNumber,
|
|
8
|
+
MinLength,
|
|
9
|
+
IsInt,
|
|
10
|
+
Min,
|
|
11
|
+
Max,
|
|
12
|
+
} from 'class-validator';
|
|
13
|
+
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
|
|
14
|
+
import {
|
|
15
|
+
ZendeskTicketChannel,
|
|
16
|
+
ZendeskTicketChannelEnum,
|
|
17
|
+
ZendeskTicketPriority,
|
|
18
|
+
ZendeskTicketPriorityEnum,
|
|
19
|
+
ZendeskTicketStatus,
|
|
20
|
+
ZendeskTicketStatusEnum,
|
|
21
|
+
ZendeskTicketType,
|
|
22
|
+
ZendeskTicketTypeEnum,
|
|
23
|
+
} from '../../../../types/Enum/Zendesk.js';
|
|
24
|
+
|
|
25
|
+
export class CreateZendeskTicket {
|
|
26
|
+
@ApiProperty()
|
|
27
|
+
@IsString()
|
|
28
|
+
@IsNotEmpty()
|
|
29
|
+
@MinLength(3)
|
|
30
|
+
subject: string;
|
|
31
|
+
|
|
32
|
+
@ApiProperty()
|
|
33
|
+
@IsString()
|
|
34
|
+
@IsNotEmpty()
|
|
35
|
+
body: string;
|
|
36
|
+
|
|
37
|
+
@ApiPropertyOptional()
|
|
38
|
+
@IsOptional()
|
|
39
|
+
@IsArray()
|
|
40
|
+
@IsString({ each: true })
|
|
41
|
+
attachments?: string[];
|
|
42
|
+
|
|
43
|
+
@ApiPropertyOptional()
|
|
44
|
+
@IsOptional()
|
|
45
|
+
@IsEnum(ZendeskTicketStatusEnum)
|
|
46
|
+
status?: ZendeskTicketStatus;
|
|
47
|
+
|
|
48
|
+
@ApiPropertyOptional()
|
|
49
|
+
@IsOptional()
|
|
50
|
+
@IsEnum(ZendeskTicketPriorityEnum)
|
|
51
|
+
priority?: ZendeskTicketPriority;
|
|
52
|
+
|
|
53
|
+
@ApiPropertyOptional()
|
|
54
|
+
@IsOptional()
|
|
55
|
+
@IsEnum(ZendeskTicketTypeEnum)
|
|
56
|
+
type?: ZendeskTicketType;
|
|
57
|
+
|
|
58
|
+
@ApiPropertyOptional()
|
|
59
|
+
@IsOptional()
|
|
60
|
+
@IsArray()
|
|
61
|
+
@IsString({ each: true })
|
|
62
|
+
tags?: string[];
|
|
63
|
+
|
|
64
|
+
@ApiPropertyOptional()
|
|
65
|
+
@IsOptional()
|
|
66
|
+
@IsNumber()
|
|
67
|
+
requesterId?: number;
|
|
68
|
+
|
|
69
|
+
@ApiPropertyOptional()
|
|
70
|
+
@IsOptional()
|
|
71
|
+
@IsNumber()
|
|
72
|
+
assigneeId?: number;
|
|
73
|
+
|
|
74
|
+
@ApiPropertyOptional()
|
|
75
|
+
@IsOptional()
|
|
76
|
+
@IsNumber()
|
|
77
|
+
groupId?: number;
|
|
78
|
+
|
|
79
|
+
@ApiPropertyOptional()
|
|
80
|
+
@IsOptional()
|
|
81
|
+
@IsNumber()
|
|
82
|
+
organizationId?: number;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export class UpdateZendeskTicket {
|
|
86
|
+
@ApiPropertyOptional()
|
|
87
|
+
@IsOptional()
|
|
88
|
+
@IsString()
|
|
89
|
+
@MinLength(3)
|
|
90
|
+
subject?: string;
|
|
91
|
+
|
|
92
|
+
@ApiPropertyOptional()
|
|
93
|
+
@IsOptional()
|
|
94
|
+
@IsString()
|
|
95
|
+
body?: string;
|
|
96
|
+
|
|
97
|
+
@ApiPropertyOptional()
|
|
98
|
+
@IsOptional()
|
|
99
|
+
@IsArray()
|
|
100
|
+
@IsString({ each: true })
|
|
101
|
+
attachments?: string[];
|
|
102
|
+
|
|
103
|
+
@ApiPropertyOptional()
|
|
104
|
+
@IsOptional()
|
|
105
|
+
@IsEnum(ZendeskTicketStatusEnum)
|
|
106
|
+
status?: ZendeskTicketStatus;
|
|
107
|
+
|
|
108
|
+
@ApiPropertyOptional()
|
|
109
|
+
@IsOptional()
|
|
110
|
+
@IsEnum(ZendeskTicketPriorityEnum)
|
|
111
|
+
priority?: ZendeskTicketPriority;
|
|
112
|
+
|
|
113
|
+
@ApiPropertyOptional()
|
|
114
|
+
@IsOptional()
|
|
115
|
+
@IsEnum(ZendeskTicketTypeEnum)
|
|
116
|
+
type?: ZendeskTicketType;
|
|
117
|
+
|
|
118
|
+
@ApiPropertyOptional()
|
|
119
|
+
@IsOptional()
|
|
120
|
+
@IsArray()
|
|
121
|
+
@IsString({ each: true })
|
|
122
|
+
tags?: string[];
|
|
123
|
+
|
|
124
|
+
@ApiPropertyOptional()
|
|
125
|
+
@IsOptional()
|
|
126
|
+
@IsNumber()
|
|
127
|
+
assigneeId?: number;
|
|
128
|
+
|
|
129
|
+
@ApiPropertyOptional()
|
|
130
|
+
@IsOptional()
|
|
131
|
+
@IsNumber()
|
|
132
|
+
groupId?: number;
|
|
133
|
+
|
|
134
|
+
@ApiPropertyOptional()
|
|
135
|
+
@IsOptional()
|
|
136
|
+
@IsNumber()
|
|
137
|
+
organizationId?: number;
|
|
138
|
+
|
|
139
|
+
@ApiPropertyOptional()
|
|
140
|
+
@IsOptional()
|
|
141
|
+
@IsNumber()
|
|
142
|
+
authorId?: number;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
export class ListZendeskTickets {
|
|
146
|
+
@ApiProperty()
|
|
147
|
+
@IsEnum(ZendeskTicketChannelEnum)
|
|
148
|
+
channel: ZendeskTicketChannel;
|
|
149
|
+
|
|
150
|
+
@ApiPropertyOptional()
|
|
151
|
+
@IsOptional()
|
|
152
|
+
@IsEnum(ZendeskTicketStatusEnum)
|
|
153
|
+
status?: ZendeskTicketStatus;
|
|
154
|
+
|
|
155
|
+
@ApiPropertyOptional()
|
|
156
|
+
@IsOptional()
|
|
157
|
+
@IsInt()
|
|
158
|
+
@Min(1)
|
|
159
|
+
page?: number = 1;
|
|
160
|
+
|
|
161
|
+
@ApiPropertyOptional()
|
|
162
|
+
@IsOptional()
|
|
163
|
+
@IsInt()
|
|
164
|
+
@Min(1)
|
|
165
|
+
@Max(100)
|
|
166
|
+
limit?: number = 25;
|
|
167
|
+
|
|
168
|
+
@ApiPropertyOptional()
|
|
169
|
+
@IsOptional()
|
|
170
|
+
@IsString()
|
|
171
|
+
search?: string;
|
|
172
|
+
|
|
173
|
+
@ApiPropertyOptional()
|
|
174
|
+
@IsOptional()
|
|
175
|
+
@IsString()
|
|
176
|
+
startDate?: string;
|
|
177
|
+
|
|
178
|
+
@ApiPropertyOptional()
|
|
179
|
+
@IsOptional()
|
|
180
|
+
@IsString()
|
|
181
|
+
endDate?: string;
|
|
182
|
+
|
|
183
|
+
@ApiPropertyOptional()
|
|
184
|
+
@IsOptional()
|
|
185
|
+
@IsString()
|
|
186
|
+
sortBy?: string;
|
|
187
|
+
|
|
188
|
+
@ApiPropertyOptional()
|
|
189
|
+
@IsOptional()
|
|
190
|
+
@IsEnum(['asc', 'desc'])
|
|
191
|
+
sortOrder?: 'asc' | 'desc';
|
|
192
|
+
}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ZendeskTicketChannel,
|
|
3
|
+
ZendeskTicketPriority,
|
|
4
|
+
ZendeskTicketStatus,
|
|
5
|
+
ZendeskTicketType,
|
|
6
|
+
} from '#types/Enum/Zendesk.js';
|
|
7
|
+
|
|
8
|
+
export interface TicketZendesk {
|
|
9
|
+
id: number;
|
|
10
|
+
url: string;
|
|
11
|
+
subject: string;
|
|
12
|
+
description: string;
|
|
13
|
+
comments: TicketComment[];
|
|
14
|
+
status: ZendeskTicketStatus;
|
|
15
|
+
priority: ZendeskTicketPriority | null;
|
|
16
|
+
type: ZendeskTicketType | null;
|
|
17
|
+
tags: string[];
|
|
18
|
+
via: { channel: ZendeskTicketChannel };
|
|
19
|
+
requesterId: number;
|
|
20
|
+
assigneeId: number | null;
|
|
21
|
+
groupId: number | null;
|
|
22
|
+
organizationId: number | null;
|
|
23
|
+
createdAt: string;
|
|
24
|
+
updatedAt: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface SearchZendeskResponse {
|
|
28
|
+
results: TicketZendesk[];
|
|
29
|
+
count: number;
|
|
30
|
+
nextPage: string | null;
|
|
31
|
+
previousPage: string | null;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export interface TicketZendeskResponse {
|
|
35
|
+
results: TicketZendesk[];
|
|
36
|
+
count: number;
|
|
37
|
+
nextPage: string | null;
|
|
38
|
+
previousPage: string | null;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface CustomFieldZendeskOption {
|
|
42
|
+
id: number;
|
|
43
|
+
name: string;
|
|
44
|
+
rawName: string;
|
|
45
|
+
value: string;
|
|
46
|
+
default: boolean;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface TicketFieldZendesk {
|
|
50
|
+
id: number;
|
|
51
|
+
url: string;
|
|
52
|
+
type: string;
|
|
53
|
+
title: string;
|
|
54
|
+
rawTitle: string;
|
|
55
|
+
description: string;
|
|
56
|
+
position: number;
|
|
57
|
+
active: boolean;
|
|
58
|
+
required: boolean;
|
|
59
|
+
requiredInPortal: boolean;
|
|
60
|
+
visibleInPortal: boolean;
|
|
61
|
+
editableInPortal: boolean;
|
|
62
|
+
tag: string | null;
|
|
63
|
+
customFieldOptions: CustomFieldZendeskOption[];
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export interface TicketFormZendesk {
|
|
67
|
+
id: number;
|
|
68
|
+
url: string;
|
|
69
|
+
name: string;
|
|
70
|
+
rawName: string;
|
|
71
|
+
displayName: string;
|
|
72
|
+
rawDisplayName: string;
|
|
73
|
+
endUserVisible: boolean;
|
|
74
|
+
position: number;
|
|
75
|
+
active: boolean;
|
|
76
|
+
default: boolean;
|
|
77
|
+
inAllBrands: boolean;
|
|
78
|
+
restrictedBrandIds: number[];
|
|
79
|
+
ticketFieldIds: number[];
|
|
80
|
+
createdAt: string;
|
|
81
|
+
updatedAt: string;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export interface TicketFormEnriched extends Omit<TicketFormZendesk, 'ticketFieldIds'> {
|
|
85
|
+
fields: TicketFieldZendesk[];
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export interface TicketAttachment {
|
|
89
|
+
id: number;
|
|
90
|
+
fileName: string;
|
|
91
|
+
contentUrl: string;
|
|
92
|
+
contentType: string;
|
|
93
|
+
size: number;
|
|
94
|
+
createdAt: string;
|
|
95
|
+
updatedAt: string;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export interface TicketComment {
|
|
99
|
+
id: number;
|
|
100
|
+
type: string;
|
|
101
|
+
authorId: number;
|
|
102
|
+
author: any;
|
|
103
|
+
body: string;
|
|
104
|
+
htmlBody: string;
|
|
105
|
+
plainBody: string;
|
|
106
|
+
public: boolean;
|
|
107
|
+
attachments: TicketAttachment[];
|
|
108
|
+
createdAt: string;
|
|
109
|
+
updatedAt: string;
|
|
110
|
+
}
|
|
@@ -4,6 +4,8 @@ import { IFileType } from './IFileType.js';
|
|
|
4
4
|
import { IFile } from './IFile.js';
|
|
5
5
|
import { ISociety } from './ISociety.js';
|
|
6
6
|
import { IAccountingFileType } from './IAccountingFileType.js';
|
|
7
|
+
import { IEInvoicing } from './IEInvoicing.js';
|
|
8
|
+
import { IThirdParty } from './IThirdParty.js';
|
|
7
9
|
|
|
8
10
|
// accountingFile
|
|
9
11
|
export class IAccountingFile {
|
|
@@ -13,16 +15,22 @@ export class IAccountingFile {
|
|
|
13
15
|
budgeaDocumentId?: number | null;
|
|
14
16
|
bankFileId?: string | null;
|
|
15
17
|
emissionDate?: Date | null;
|
|
18
|
+
totalTaxIncluded?: number | null;
|
|
19
|
+
totalTaxExcluded?: number | null;
|
|
16
20
|
isMobile: boolean;
|
|
21
|
+
internComment?: string | null;
|
|
17
22
|
idAccountingTransaction?: number | null;
|
|
18
23
|
idEstimateInvoice?: number | null;
|
|
19
24
|
idAccountingFileType: number;
|
|
25
|
+
idThirdParty?: number | null;
|
|
20
26
|
idSociety: number;
|
|
21
27
|
idFile: number;
|
|
28
|
+
idEInvoicing?: number | null;
|
|
22
29
|
createdAt?: Date | null;
|
|
23
30
|
updatedAt?: Date | null;
|
|
24
31
|
deletedAt?: Date | null;
|
|
25
32
|
idFileType?: number | null;
|
|
33
|
+
isVerified?: boolean;
|
|
26
34
|
|
|
27
35
|
// Associations
|
|
28
36
|
accountingTransaction?: IAccountingTransaction;
|
|
@@ -31,4 +39,6 @@ export class IAccountingFile {
|
|
|
31
39
|
fileType?: IFileType;
|
|
32
40
|
file?: IFile;
|
|
33
41
|
society?: ISociety;
|
|
42
|
+
thirdParty?: IThirdParty | null;
|
|
43
|
+
eInvoicing?: IEInvoicing | null;
|
|
34
44
|
}
|
|
@@ -14,6 +14,7 @@ import { IMachineLearningResult } from './IMachineLearningResult.js';
|
|
|
14
14
|
import { ISocietyPartner } from './ISocietyPartner.js';
|
|
15
15
|
import { ISocietyVehicle } from './ISocietyVehicle.js';
|
|
16
16
|
import { IAccountingTransactionTracking } from './IAccountingTransactionTracking.js';
|
|
17
|
+
import { IEInvoicing } from './IEInvoicing.js';
|
|
17
18
|
|
|
18
19
|
// accountingTransactions
|
|
19
20
|
export class IAccountingTransaction {
|
|
@@ -53,6 +54,7 @@ export class IAccountingTransaction {
|
|
|
53
54
|
idRegistration?: number | null;
|
|
54
55
|
idFile?: number | null;
|
|
55
56
|
classificationId?: string | null; // Id returned by the team system for the predictions of an accounting transaction, can be null if the transaction has not been classified by the team system
|
|
57
|
+
idEInvoicing?: number | null;
|
|
56
58
|
createdAt?: Date | null;
|
|
57
59
|
updatedAt?: Date | null;
|
|
58
60
|
deletedAt?: Date | null;
|
|
@@ -76,4 +78,5 @@ export class IAccountingTransaction {
|
|
|
76
78
|
societyPartner?: ISocietyPartner;
|
|
77
79
|
vehicle?: ISocietyVehicle | null;
|
|
78
80
|
trackings?: IAccountingTransactionTracking[];
|
|
81
|
+
eInvoicing?: IEInvoicing | null;
|
|
79
82
|
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { IFile } from './IFile.js';
|
|
2
|
+
import { EInvoicingDirection } from '../../Enum/EInvoicingDirection.js';
|
|
3
|
+
import { IEInvoicingStatus } from './IEInvoicingStatus.js';
|
|
4
|
+
import { IAccountingFile } from './IAccountingFile.js';
|
|
5
|
+
import { IAccountingTransaction } from './IAccountingTransaction.js';
|
|
6
|
+
|
|
7
|
+
export class IEInvoicing {
|
|
8
|
+
id?: number;
|
|
9
|
+
|
|
10
|
+
direction: EInvoicingDirection;
|
|
11
|
+
externalId: string;
|
|
12
|
+
idXmlFile: number;
|
|
13
|
+
|
|
14
|
+
createdAt?: Date | null;
|
|
15
|
+
updatedAt?: Date | null;
|
|
16
|
+
|
|
17
|
+
xmlFile?: IFile;
|
|
18
|
+
eInvoicingStatus?: IEInvoicingStatus[];
|
|
19
|
+
AccountingFile?: IAccountingFile;
|
|
20
|
+
AccountingTransaction?: IAccountingTransaction;
|
|
21
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { IUser } from './IUser.js';
|
|
2
|
+
import { EInvoicingStatusCode } from '../../Enum/EInvoicingStatusCode.js';
|
|
3
|
+
import { IEInvoicing } from './IEInvoicing.js';
|
|
4
|
+
import { EInvoicingReasonType } from '../../../index.js';
|
|
5
|
+
|
|
6
|
+
export class IEInvoicingStatus {
|
|
7
|
+
id?: number;
|
|
8
|
+
status: EInvoicingStatusCode;
|
|
9
|
+
reasonType: EInvoicingReasonType | null;
|
|
10
|
+
message: string | null;
|
|
11
|
+
idUser: number;
|
|
12
|
+
idEInvoicing: number;
|
|
13
|
+
createdAt?: Date | null;
|
|
14
|
+
updatedAt?: Date | null;
|
|
15
|
+
|
|
16
|
+
user?: IUser;
|
|
17
|
+
eInvoicing?: IEInvoicing;
|
|
18
|
+
}
|
|
@@ -3,6 +3,7 @@ import { IPaymentMethod } from './IPaymentMethod.js';
|
|
|
3
3
|
import { IUser } from './IUser.js';
|
|
4
4
|
import { IExercice } from './IExercice.js';
|
|
5
5
|
import { IFile } from './IFile.js';
|
|
6
|
+
import { IEInvoicing } from './IEInvoicing.js';
|
|
6
7
|
import { IPaymentExpectation } from './IPaymentExpectation.js';
|
|
7
8
|
import { IPaymentAttempt } from './IPaymentAttempt.js';
|
|
8
9
|
|
|
@@ -37,6 +38,7 @@ export class IPayment {
|
|
|
37
38
|
idUser?: number | null;
|
|
38
39
|
idPaymentMethod: number;
|
|
39
40
|
idFile?: number | null;
|
|
41
|
+
idEInvoicing?: number | null;
|
|
40
42
|
createdAt?: Date | null;
|
|
41
43
|
updatedAt?: Date | null;
|
|
42
44
|
deletedAt?: Date | null;
|
|
@@ -48,5 +50,6 @@ export class IPayment {
|
|
|
48
50
|
user?: IUser;
|
|
49
51
|
exercice?: IExercice;
|
|
50
52
|
files?: IFile;
|
|
53
|
+
eInvoicing?: IEInvoicing;
|
|
51
54
|
paymentAttempts?: IPaymentAttempt[];
|
|
52
55
|
}
|
|
@@ -18,6 +18,8 @@ export class IThirdParty {
|
|
|
18
18
|
phone?: string | null;
|
|
19
19
|
email?: string | null;
|
|
20
20
|
nSiret?: string | null;
|
|
21
|
+
isPrivateIndividual?: boolean | null;
|
|
22
|
+
addressingIdentifier?: string | null;
|
|
21
23
|
legalForm?: number | null;
|
|
22
24
|
termOfPayment?: TermOfPayment | null;
|
|
23
25
|
nTva?: string | null;
|