@silexpert/core 1.1.307 → 1.1.309
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/cjs/api/resources/CommercialDocument.d.ts +3 -1
- package/dist/cjs/api/resources/CommercialDocument.d.ts.map +1 -1
- package/dist/cjs/api/resources/CommercialDocument.js +9 -0
- package/dist/cjs/api/resources/CommercialDocument.js.map +1 -1
- package/dist/cjs/types/Enum/Card.d.ts +24 -2
- package/dist/cjs/types/Enum/Card.d.ts.map +1 -1
- package/dist/cjs/types/Enum/Card.js +26 -0
- package/dist/cjs/types/Enum/Card.js.map +1 -1
- package/dist/cjs/types/Enum/EstimateInvoice.d.ts +4 -0
- package/dist/cjs/types/Enum/EstimateInvoice.d.ts.map +1 -1
- package/dist/cjs/types/Enum/EstimateInvoice.js +27 -1
- package/dist/cjs/types/Enum/EstimateInvoice.js.map +1 -1
- package/dist/cjs/types/Enum/PriceGridClementine.js +1 -1
- package/dist/cjs/types/Enum/PriceGridClementine.js.map +1 -1
- package/dist/cjs/types/Interface/api/commercialManagement/Query.d.ts +6 -0
- package/dist/cjs/types/Interface/api/commercialManagement/Query.d.ts.map +1 -1
- package/dist/cjs/types/Interface/api/commercialManagement/Query.js +26 -1
- package/dist/cjs/types/Interface/api/commercialManagement/Query.js.map +1 -1
- package/dist/cjs/types/Interface/api/payment/Util.d.ts +3 -0
- package/dist/cjs/types/Interface/api/payment/Util.d.ts.map +1 -1
- package/dist/cjs/types/Interface/api/payment/Util.js.map +1 -1
- package/dist/cjs/types/Interface/models/IPrestation.d.ts +1 -0
- package/dist/cjs/types/Interface/models/IPrestation.d.ts.map +1 -1
- package/dist/cjs/types/Interface/models/IPrestation.js.map +1 -1
- package/dist/cjs/utils/payment.d.ts +2 -0
- package/dist/cjs/utils/payment.d.ts.map +1 -1
- package/dist/cjs/utils/payment.js +84 -33
- package/dist/cjs/utils/payment.js.map +1 -1
- package/dist/cjs/utils/tests/payment.spec.js +36 -0
- package/dist/cjs/utils/tests/payment.spec.js.map +1 -1
- package/dist/mjs/api/resources/CommercialDocument.d.ts +3 -1
- package/dist/mjs/api/resources/CommercialDocument.d.ts.map +1 -1
- package/dist/mjs/api/resources/CommercialDocument.js +9 -0
- package/dist/mjs/api/resources/CommercialDocument.js.map +1 -1
- package/dist/mjs/types/Enum/Card.d.ts +24 -2
- package/dist/mjs/types/Enum/Card.d.ts.map +1 -1
- package/dist/mjs/types/Enum/Card.js +26 -0
- package/dist/mjs/types/Enum/Card.js.map +1 -1
- package/dist/mjs/types/Enum/EstimateInvoice.d.ts +4 -0
- package/dist/mjs/types/Enum/EstimateInvoice.d.ts.map +1 -1
- package/dist/mjs/types/Enum/EstimateInvoice.js +26 -0
- package/dist/mjs/types/Enum/EstimateInvoice.js.map +1 -1
- package/dist/mjs/types/Enum/PriceGridClementine.js +1 -1
- package/dist/mjs/types/Enum/PriceGridClementine.js.map +1 -1
- package/dist/mjs/types/Interface/api/commercialManagement/Query.d.ts +6 -0
- package/dist/mjs/types/Interface/api/commercialManagement/Query.d.ts.map +1 -1
- package/dist/mjs/types/Interface/api/commercialManagement/Query.js +29 -1
- package/dist/mjs/types/Interface/api/commercialManagement/Query.js.map +1 -1
- package/dist/mjs/types/Interface/api/payment/Util.d.ts +3 -0
- package/dist/mjs/types/Interface/api/payment/Util.d.ts.map +1 -1
- package/dist/mjs/types/Interface/api/payment/Util.js.map +1 -1
- package/dist/mjs/types/Interface/models/IPrestation.d.ts +1 -0
- package/dist/mjs/types/Interface/models/IPrestation.d.ts.map +1 -1
- package/dist/mjs/types/Interface/models/IPrestation.js.map +1 -1
- package/dist/mjs/utils/payment.d.ts +2 -0
- package/dist/mjs/utils/payment.d.ts.map +1 -1
- package/dist/mjs/utils/payment.js +84 -34
- package/dist/mjs/utils/payment.js.map +1 -1
- package/dist/mjs/utils/tests/payment.spec.js +37 -1
- package/dist/mjs/utils/tests/payment.spec.js.map +1 -1
- package/package.json +1 -1
- package/ts/api/resources/CommercialDocument.ts +11 -0
- package/ts/types/Enum/Card.ts +27 -0
- package/ts/types/Enum/EstimateInvoice.ts +28 -1
- package/ts/types/Enum/PriceGridClementine.ts +1 -1
- package/ts/types/Interface/api/commercialManagement/Query.ts +21 -1
- package/ts/types/Interface/api/payment/Util.ts +3 -0
- package/ts/types/Interface/models/IPrestation.ts +1 -0
- package/ts/utils/payment.ts +87 -34
- package/ts/utils/tests/payment.spec.ts +37 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
|
-
IsArray, IsBoolean, IsDateString, IsOptional, IsString,
|
|
2
|
+
IsArray, IsBoolean, IsDateString, IsInt, IsOptional, IsString,
|
|
3
3
|
} from 'class-validator';
|
|
4
4
|
import { Order } from '../../..';
|
|
5
5
|
import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
|
|
@@ -150,4 +150,24 @@ export class QueryCountByStatus {
|
|
|
150
150
|
@ToBoolean()
|
|
151
151
|
@IsOptional()
|
|
152
152
|
isDraft?: boolean;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
export class QueryExportCommercialManagementIntoCSV {
|
|
156
|
+
@ApiPropertyOptional()
|
|
157
|
+
@IsDateString()
|
|
158
|
+
@IsOptional()
|
|
159
|
+
startDate?: string;
|
|
160
|
+
|
|
161
|
+
@ApiPropertyOptional()
|
|
162
|
+
@IsOptional()
|
|
163
|
+
@IsDateString()
|
|
164
|
+
endDate?: string;
|
|
165
|
+
|
|
166
|
+
@ApiProperty()
|
|
167
|
+
@IsInt()
|
|
168
|
+
idSociety: number;
|
|
169
|
+
|
|
170
|
+
@ApiProperty()
|
|
171
|
+
@IsArray()
|
|
172
|
+
types: EstimateInvoiceType[];
|
|
153
173
|
}
|
|
@@ -11,6 +11,8 @@ export interface ParamsForPaymentsAuto {
|
|
|
11
11
|
firstExerciceNonExpresssEndDate: Date;
|
|
12
12
|
goToClient: Date;
|
|
13
13
|
idPrestation: number;
|
|
14
|
+
idLegalForm: number;
|
|
15
|
+
isWithApplicationFees: boolean;
|
|
14
16
|
idVat: number;
|
|
15
17
|
prestationList: IPrestationList;
|
|
16
18
|
yearlyAmountNonExpress: number;
|
|
@@ -21,6 +23,7 @@ export interface ParamsForPaymentsAuto {
|
|
|
21
23
|
|
|
22
24
|
export interface PaymentAuto {
|
|
23
25
|
amount: number;
|
|
26
|
+
isPaid?: boolean;
|
|
24
27
|
datePayment: Date;
|
|
25
28
|
idPrestation: number;
|
|
26
29
|
idPaymentMethod: number;
|
package/ts/utils/payment.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
import { IPayment, IRegulation, ParamsForPaymentsAuto, PaymentMethod, PaymentAuto, getTaxesIncludedAmount } from '../types';
|
|
3
|
+
import { IPayment, IRegulation, ParamsForPaymentsAuto, PaymentMethod, PaymentAuto, getTaxesIncludedAmount, LegalFormTypeEnum } from '../types';
|
|
4
4
|
import * as dayjs from 'dayjs';
|
|
5
5
|
import { PartialExercicePrestationExpress } from '../types/Interface/api/payment/Util';
|
|
6
6
|
import { getPriceGrid } from './prestation';
|
|
@@ -78,6 +78,8 @@ const calculateFees = (amount: number, goToClient: Date, paymentDate: Date):numb
|
|
|
78
78
|
// * @param {number} firstPaymentAmount - amount of the first payment (first regulation of the customer)
|
|
79
79
|
* @param {Date} firstExerciceNonExpresssEndDate - end date of the first exercice non express
|
|
80
80
|
* @param {number} idPrestation - prestation id
|
|
81
|
+
* @param {number} idLegalForm - legal form id of the society
|
|
82
|
+
* @param {boolean} isWithApplicationFees - if the prestation has application fees to paid
|
|
81
83
|
* @param {IPrestationList} prestationList - type of prestation (hidden: 0, isCatalog: 1, isComptable: 1)
|
|
82
84
|
* @param {number} idVat - vat id of society linked
|
|
83
85
|
* @param {number} yearlyAmountNonExpress - yearly amount of non express prestation (HT)
|
|
@@ -87,11 +89,10 @@ const calculateFees = (amount: number, goToClient: Date, paymentDate: Date):numb
|
|
|
87
89
|
* @returns { IPayment[] } list of payment to create for billing auto, after each presta go to onBoarding
|
|
88
90
|
*/
|
|
89
91
|
const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
90
|
-
const { idTypeBrand, goToClient, firstExerciceNonExpresssEndDate, idPrestation, prestationList, idVat, yearlyAmountNonExpress, nextYearlyAmountNonExpress, listPartialExercicePrestationExpress, listRegulations } = params;
|
|
92
|
+
const { idTypeBrand, goToClient, isWithApplicationFees, firstExerciceNonExpresssEndDate, idPrestation, idLegalForm, prestationList, idVat, yearlyAmountNonExpress, nextYearlyAmountNonExpress, listPartialExercicePrestationExpress, listRegulations } = params;
|
|
91
93
|
const initializedPaymentDate = dayjs().endOf('month').diff(dayjs(), 'day') < 3/* || dayjs().date() >= 15 */
|
|
92
94
|
? dayjs().add(2, 'month').startOf('month').toDate()
|
|
93
95
|
: dayjs().add(1, 'month').startOf('month').toDate();
|
|
94
|
-
let isApplicationAlreadyPaid = false;
|
|
95
96
|
|
|
96
97
|
// On récupère la grille tarifaire pour savoir si les tarifs sont HT ou TTC
|
|
97
98
|
// et pour connaitre le montant du coût de l'app
|
|
@@ -100,6 +101,7 @@ const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
|
100
101
|
if (!priceGrid) throw new Error('Impossible de trouver la grille tarifaire correspondante');
|
|
101
102
|
const { applicationCost, priceWithTaxesIncluded } = priceGrid;
|
|
102
103
|
const applicationCostTotalTTC = (priceWithTaxesIncluded ? applicationCost : getTaxesIncludedAmount(applicationCost, idVat)) * 12;
|
|
104
|
+
const applicationFeesAmount = (idLegalForm === LegalFormTypeEnum.SCI) ? 150 : 50;
|
|
103
105
|
|
|
104
106
|
if (prestationList?.isCatalog || !prestationList?.isComptable) throw new Error('Ce type de prestation ne correspond pas aux conditions attendues.');
|
|
105
107
|
// if (!listRegulations?.length) throw new Error('List of regulations can not be empty');
|
|
@@ -110,7 +112,21 @@ const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
|
110
112
|
const listPayments:PaymentAuto[] = [];
|
|
111
113
|
|
|
112
114
|
// on récupère le/les premiers réglements effectués, non alloués
|
|
113
|
-
|
|
115
|
+
let isApplicationFeesAlreadyPaid = false;
|
|
116
|
+
const sumRegulations = listRegulations.reduce((acc: number, r:IRegulation) => {
|
|
117
|
+
//Si la regulation est rattachée à un paymentExpectation, on récupère le détail
|
|
118
|
+
// et on ne prend que les frais de dossier (applicationFee) + le montant de la compta (accountingFee)
|
|
119
|
+
if (r.paymentsExpectation?.payload) {
|
|
120
|
+
const payload = JSON.parse(r.paymentsExpectation?.payload);
|
|
121
|
+
if (+payload?.applicationFee > 0) {
|
|
122
|
+
isApplicationFeesAlreadyPaid = true;
|
|
123
|
+
}
|
|
124
|
+
if (+payload?.accountingFee > 0) acc += +payload?.accountingFee;
|
|
125
|
+
return acc;
|
|
126
|
+
} else {
|
|
127
|
+
return acc + r.amount - r.amountUsed;
|
|
128
|
+
}
|
|
129
|
+
}, 0);
|
|
114
130
|
let remainingAmount = -sumRegulations; //TTC
|
|
115
131
|
let paymentDate = initializedPaymentDate;
|
|
116
132
|
|
|
@@ -125,12 +141,26 @@ const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
|
125
141
|
if (sumRegulations) {
|
|
126
142
|
listPayments.push({
|
|
127
143
|
amount:sumRegulations, //TTC
|
|
144
|
+
isPaid: true,
|
|
128
145
|
datePayment: dayjs().toDate(),
|
|
129
146
|
idPrestation,
|
|
130
147
|
idPaymentMethod: PaymentMethod.DIRECT_DEBIT.id,
|
|
131
148
|
closingDate: listPartialExercicePrestationExpress?.length ? listPartialExercicePrestationExpress[0].endDate : firstExerciceNonExpresssEndDate,
|
|
132
149
|
});
|
|
133
150
|
}
|
|
151
|
+
|
|
152
|
+
// Si les frais de dossiers sont facturés et qu'ils n'ont pas déjà été payés,
|
|
153
|
+
// on ajoute un paiement sur la première mensualité non express
|
|
154
|
+
if (isWithApplicationFees && !isApplicationFeesAlreadyPaid) {
|
|
155
|
+
listPayments.push({
|
|
156
|
+
amount: getTaxesIncludedAmount(applicationFeesAmount, idVat), //TTC
|
|
157
|
+
isPaid: false,
|
|
158
|
+
datePayment: dayjs().startOf('month').add(1, 'month').toDate(),
|
|
159
|
+
idPrestation,
|
|
160
|
+
idPaymentMethod: PaymentMethod.DIRECT_DEBIT.id,
|
|
161
|
+
closingDate: listPartialExercicePrestationExpress?.length ? listPartialExercicePrestationExpress[0].endDate : firstExerciceNonExpresssEndDate,
|
|
162
|
+
});
|
|
163
|
+
}
|
|
134
164
|
|
|
135
165
|
// =========================
|
|
136
166
|
// EXPRESS
|
|
@@ -175,37 +205,61 @@ const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
|
175
205
|
// sinon, ils sont à la suite des express
|
|
176
206
|
if (nbExoExpress <= 1) paymentDate = initializedPaymentDate;
|
|
177
207
|
let exerciceEndDate = dayjs(firstExerciceNonExpresssEndDate).toDate();
|
|
208
|
+
|
|
209
|
+
let hasGeneratedWholeYear = false;
|
|
210
|
+
let isFirstNonExpress = true;
|
|
178
211
|
|
|
179
|
-
//On génère un
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
remainingAmount += priceWithTaxesIncluded ? exoAmount : getTaxesIncludedAmount(exoAmount, idVat);
|
|
212
|
+
//On génère des paiements jusqu'à ce qu'un exercice soit entier (12 mois), non express
|
|
213
|
+
while (!hasGeneratedWholeYear) {
|
|
214
|
+
|
|
215
|
+
//On compte le nb de mois restants entre la date à laquelle le paiement va être créé et la date de fin d'exercice
|
|
216
|
+
let countMonthsBeforeExerciceEnd = Math.ceil(dayjs(exerciceEndDate).diff(paymentDate, 'months', true));
|
|
217
|
+
if (countMonthsBeforeExerciceEnd < 3) countMonthsBeforeExerciceEnd = 3;
|
|
186
218
|
|
|
187
|
-
|
|
188
|
-
|
|
219
|
+
const exoAmount = isFirstNonExpress ? yearlyAmountNonExpress : nextYearlyAmountNonExpress;
|
|
220
|
+
remainingAmount += priceWithTaxesIncluded ? exoAmount : getTaxesIncludedAmount(exoAmount, idVat);
|
|
221
|
+
|
|
222
|
+
//TODO: CAS A TESTER : si sumRegulations couvre le premier exercice par exemple (cas rar mais à envisager)
|
|
223
|
+
//Si le premier règlement couvre le coût de cet exercicePrestation, on passe au suivant
|
|
224
|
+
// if (remainingAmount <= 0) {
|
|
225
|
+
// continue;
|
|
226
|
+
// }
|
|
189
227
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
228
|
+
// Si on a ajouté une ligne pour les applications fees, alors on les déduit du montant total
|
|
229
|
+
if (isFirstNonExpress && isWithApplicationFees && !isApplicationFeesAlreadyPaid) {
|
|
230
|
+
remainingAmount -= getTaxesIncludedAmount(applicationFeesAmount, idVat);
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
let remainingAmountByExercicePrestation = remainingAmount;
|
|
234
|
+
|
|
235
|
+
// - frais d'application dès les second exo non express
|
|
236
|
+
if (!isFirstNonExpress) remainingAmountByExercicePrestation += applicationCostTotalTTC;
|
|
237
|
+
|
|
238
|
+
const monthlyAmount = remainingAmountByExercicePrestation / countMonthsBeforeExerciceEnd; //TTC
|
|
239
|
+
|
|
240
|
+
if (monthlyAmount > 0) {
|
|
241
|
+
for (let index = 1; index <= countMonthsBeforeExerciceEnd; index++) {
|
|
242
|
+
let amount = index < countMonthsBeforeExerciceEnd ? monthlyAmount : remainingAmountByExercicePrestation;
|
|
193
243
|
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
244
|
+
// Si besoin, on applique les frais nécessaires :
|
|
245
|
+
// - 2,75% d'augmentation chaque année, sauf si souscriptiuon dans les 3 derniers mois de l'année civile)
|
|
246
|
+
amount = calculateFees(amount, goToClient, paymentDate);
|
|
197
247
|
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
248
|
+
listPayments.push({
|
|
249
|
+
amount: Math.round(100 * amount) / 100,
|
|
250
|
+
datePayment: paymentDate,
|
|
251
|
+
idPrestation,
|
|
252
|
+
idPaymentMethod: PaymentMethod.DIRECT_DEBIT.id,
|
|
253
|
+
closingDate: exerciceEndDate,
|
|
254
|
+
});
|
|
255
|
+
remainingAmountByExercicePrestation -= monthlyAmount;
|
|
256
|
+
paymentDate = dayjs(paymentDate).add(1, 'month').startOf('month').toDate();
|
|
257
|
+
}
|
|
258
|
+
exerciceEndDate = dayjs(exerciceEndDate).startOf('month').add(1, 'year').endOf('month').toDate();
|
|
207
259
|
}
|
|
208
|
-
|
|
260
|
+
remainingAmount = 0;
|
|
261
|
+
if (countMonthsBeforeExerciceEnd === 12) hasGeneratedWholeYear = true;
|
|
262
|
+
isFirstNonExpress = false;
|
|
209
263
|
}
|
|
210
264
|
|
|
211
265
|
remainingAmount = 0;
|
|
@@ -216,20 +270,20 @@ const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
|
216
270
|
// On applique le taux de tva de la société, si besoin, selon la grille tarifaire
|
|
217
271
|
remainingAmount += priceWithTaxesIncluded ? nextYearlyAmountNonExpress : getTaxesIncludedAmount(nextYearlyAmountNonExpress, idVat);
|
|
218
272
|
|
|
219
|
-
remainingAmountByExercicePrestation = remainingAmount;
|
|
273
|
+
let remainingAmountByExercicePrestation = remainingAmount;
|
|
220
274
|
//On compte le nb de mois restants entre la date à laquelle le paiement va être créé et la date de fin d'exercice
|
|
221
|
-
countMonthsBeforeExerciceEnd = Math.ceil(dayjs(exerciceEndDate).diff(paymentDate, 'months', true));
|
|
275
|
+
let countMonthsBeforeExerciceEnd = Math.ceil(dayjs(exerciceEndDate).diff(paymentDate, 'months', true));
|
|
222
276
|
if (countMonthsBeforeExerciceEnd < 3) countMonthsBeforeExerciceEnd = 3;
|
|
223
277
|
|
|
224
278
|
// - frais d'application dès les second exo non express
|
|
225
279
|
remainingAmountByExercicePrestation += applicationCostTotalTTC;
|
|
226
280
|
|
|
227
|
-
monthlyAmount = remainingAmountByExercicePrestation / countMonthsBeforeExerciceEnd;
|
|
281
|
+
const monthlyAmount = remainingAmountByExercicePrestation / countMonthsBeforeExerciceEnd;
|
|
228
282
|
|
|
229
283
|
// Si aucun paiement généré, on stoppe là
|
|
230
284
|
if (!listPayments.length) return [];
|
|
231
285
|
|
|
232
|
-
while (dayjs(listPayments.slice(-1)[0].datePayment).month() < 11
|
|
286
|
+
while (dayjs(listPayments.slice(-1)[0].datePayment).month() < 11) {
|
|
233
287
|
let amount = monthlyAmount;
|
|
234
288
|
|
|
235
289
|
// Si besoin, on applique les frais nécessaires :
|
|
@@ -245,7 +299,6 @@ const calculatePaymentsAuto = (params: ParamsForPaymentsAuto):PaymentAuto[] => {
|
|
|
245
299
|
closingDate: exerciceEndDate,
|
|
246
300
|
});
|
|
247
301
|
paymentDate = dayjs(paymentDate).add(1, 'month').startOf('month').toDate();
|
|
248
|
-
isApplicationAlreadyPaid = true;
|
|
249
302
|
}
|
|
250
303
|
|
|
251
304
|
return listPayments;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as dayjs from 'dayjs';
|
|
2
|
-
import { IRegulation, Vat, PaymentMethod } from '../../types';
|
|
2
|
+
import { IRegulation, Vat, PaymentMethod, LegalFormTypeEnum } from '../../types';
|
|
3
3
|
import MockDate from 'mockdate';
|
|
4
4
|
|
|
5
5
|
import { calculatePaymentsAuto } from '../payment';
|
|
@@ -83,6 +83,8 @@ describe('Payment', () => {
|
|
|
83
83
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
84
84
|
firstExerciceNonExpresssEndDate,
|
|
85
85
|
idPrestation,
|
|
86
|
+
isWithApplicationFees: true,
|
|
87
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
86
88
|
prestationList: {
|
|
87
89
|
...prestationList,
|
|
88
90
|
isCatalog: true,
|
|
@@ -106,6 +108,8 @@ describe('Payment', () => {
|
|
|
106
108
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
107
109
|
firstExerciceNonExpresssEndDate,
|
|
108
110
|
idPrestation,
|
|
111
|
+
isWithApplicationFees: true,
|
|
112
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
109
113
|
prestationList,
|
|
110
114
|
idVat,
|
|
111
115
|
listPartialExercicePrestationExpress,
|
|
@@ -126,6 +130,8 @@ describe('Payment', () => {
|
|
|
126
130
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
127
131
|
firstExerciceNonExpresssEndDate,
|
|
128
132
|
idPrestation,
|
|
133
|
+
isWithApplicationFees: true,
|
|
134
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
129
135
|
prestationList,
|
|
130
136
|
idVat,
|
|
131
137
|
listPartialExercicePrestationExpress,
|
|
@@ -149,6 +155,8 @@ describe('Payment', () => {
|
|
|
149
155
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
150
156
|
firstExerciceNonExpresssEndDate,
|
|
151
157
|
idPrestation,
|
|
158
|
+
isWithApplicationFees: true,
|
|
159
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
152
160
|
prestationList,
|
|
153
161
|
idVat,
|
|
154
162
|
listPartialExercicePrestationExpress: [listPartialExercicePrestationExpress[0]],
|
|
@@ -166,6 +174,8 @@ describe('Payment', () => {
|
|
|
166
174
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
167
175
|
firstExerciceNonExpresssEndDate,
|
|
168
176
|
idPrestation,
|
|
177
|
+
isWithApplicationFees: true,
|
|
178
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
169
179
|
prestationList,
|
|
170
180
|
idVat,
|
|
171
181
|
listPartialExercicePrestationExpress,
|
|
@@ -190,6 +200,8 @@ describe('Payment', () => {
|
|
|
190
200
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
191
201
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
192
202
|
idPrestation,
|
|
203
|
+
isWithApplicationFees: true,
|
|
204
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
193
205
|
prestationList,
|
|
194
206
|
idVat,
|
|
195
207
|
listPartialExercicePrestationExpress: [],
|
|
@@ -215,6 +227,8 @@ describe('Payment', () => {
|
|
|
215
227
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
216
228
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
217
229
|
idPrestation,
|
|
230
|
+
isWithApplicationFees: true,
|
|
231
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
218
232
|
prestationList,
|
|
219
233
|
idVat,
|
|
220
234
|
listPartialExercicePrestationExpress: [],
|
|
@@ -243,6 +257,8 @@ describe('Payment', () => {
|
|
|
243
257
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
244
258
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
245
259
|
idPrestation,
|
|
260
|
+
isWithApplicationFees: true,
|
|
261
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
246
262
|
prestationList,
|
|
247
263
|
idVat,
|
|
248
264
|
listPartialExercicePrestationExpress: [],
|
|
@@ -269,6 +285,8 @@ describe('Payment', () => {
|
|
|
269
285
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
270
286
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
271
287
|
idPrestation,
|
|
288
|
+
isWithApplicationFees: true,
|
|
289
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
272
290
|
prestationList,
|
|
273
291
|
idVat,
|
|
274
292
|
listPartialExercicePrestationExpress: [],
|
|
@@ -293,6 +311,8 @@ describe('Payment', () => {
|
|
|
293
311
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
294
312
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
295
313
|
idPrestation,
|
|
314
|
+
isWithApplicationFees: true,
|
|
315
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
296
316
|
prestationList,
|
|
297
317
|
idVat,
|
|
298
318
|
listPartialExercicePrestationExpress: [],
|
|
@@ -319,6 +339,8 @@ describe('Payment', () => {
|
|
|
319
339
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
320
340
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
321
341
|
idPrestation,
|
|
342
|
+
isWithApplicationFees: true,
|
|
343
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
322
344
|
prestationList,
|
|
323
345
|
idVat,
|
|
324
346
|
listPartialExercicePrestationExpress: [],
|
|
@@ -346,6 +368,8 @@ describe('Payment', () => {
|
|
|
346
368
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
347
369
|
firstExerciceNonExpresssEndDate: newFirstExerciceNonExpresssEndDate,
|
|
348
370
|
idPrestation,
|
|
371
|
+
isWithApplicationFees: true,
|
|
372
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
349
373
|
prestationList,
|
|
350
374
|
idVat,
|
|
351
375
|
listPartialExercicePrestationExpress: [],
|
|
@@ -379,6 +403,8 @@ describe('Payment', () => {
|
|
|
379
403
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
380
404
|
firstExerciceNonExpresssEndDate,
|
|
381
405
|
idPrestation,
|
|
406
|
+
isWithApplicationFees: true,
|
|
407
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
382
408
|
prestationList,
|
|
383
409
|
idVat,
|
|
384
410
|
listPartialExercicePrestationExpress: listPartialExercicePrestationExpressCloned,
|
|
@@ -397,6 +423,8 @@ describe('Payment', () => {
|
|
|
397
423
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
398
424
|
firstExerciceNonExpresssEndDate,
|
|
399
425
|
idPrestation,
|
|
426
|
+
isWithApplicationFees: true,
|
|
427
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
400
428
|
prestationList,
|
|
401
429
|
idVat,
|
|
402
430
|
listPartialExercicePrestationExpress,
|
|
@@ -436,6 +464,8 @@ describe('Payment', () => {
|
|
|
436
464
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
437
465
|
firstExerciceNonExpresssEndDate,
|
|
438
466
|
idPrestation,
|
|
467
|
+
isWithApplicationFees: true,
|
|
468
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
439
469
|
prestationList,
|
|
440
470
|
idVat,
|
|
441
471
|
listPartialExercicePrestationExpress,
|
|
@@ -455,6 +485,8 @@ describe('Payment', () => {
|
|
|
455
485
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
456
486
|
firstExerciceNonExpresssEndDate,
|
|
457
487
|
idPrestation,
|
|
488
|
+
isWithApplicationFees: true,
|
|
489
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
458
490
|
prestationList,
|
|
459
491
|
idVat,
|
|
460
492
|
listPartialExercicePrestationExpress,
|
|
@@ -470,6 +502,8 @@ describe('Payment', () => {
|
|
|
470
502
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
471
503
|
firstExerciceNonExpresssEndDate,
|
|
472
504
|
idPrestation,
|
|
505
|
+
isWithApplicationFees: true,
|
|
506
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
473
507
|
prestationList,
|
|
474
508
|
idVat,
|
|
475
509
|
listPartialExercicePrestationExpress: [],
|
|
@@ -484,6 +518,8 @@ describe('Payment', () => {
|
|
|
484
518
|
goToClient: dayjs('2024-06-06').toDate(),
|
|
485
519
|
firstExerciceNonExpresssEndDate: dayjs('2024-12-31').toDate(),
|
|
486
520
|
idPrestation,
|
|
521
|
+
isWithApplicationFees: true,
|
|
522
|
+
idLegalForm: LegalFormTypeEnum.SARL,
|
|
487
523
|
prestationList,
|
|
488
524
|
idVat: Vat.TX_20.id,
|
|
489
525
|
listPartialExercicePrestationExpress: [],
|