@silexpert/core 0.4.114 → 0.4.117
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/es/api/resources/BalanceSheetQuestion.d.ts +6 -0
- package/es/api/resources/BalanceSheetQuestion.d.ts.map +1 -0
- package/es/api/resources/BalanceSheetQuestion.js +7 -0
- package/es/api/resources/BalanceSheetQuestion.js.map +1 -0
- package/es/api/resources/Cerfa.d.ts +8 -1
- package/es/api/resources/Cerfa.d.ts.map +1 -1
- package/es/api/resources/Cerfa.js +5 -0
- package/es/api/resources/Cerfa.js.map +1 -1
- package/es/api/resources/ExerciceQuestion.d.ts +8 -0
- package/es/api/resources/ExerciceQuestion.d.ts.map +1 -0
- package/es/api/resources/ExerciceQuestion.js +13 -0
- package/es/api/resources/ExerciceQuestion.js.map +1 -0
- package/es/api/resources/PartneredAccountant.d.ts +3 -1
- package/es/api/resources/PartneredAccountant.d.ts.map +1 -1
- package/es/api/resources/PartneredAccountant.js +6 -0
- package/es/api/resources/PartneredAccountant.js.map +1 -1
- package/es/api/resources/VatControl.d.ts +10 -0
- package/es/api/resources/VatControl.d.ts.map +1 -0
- package/es/api/resources/VatControl.js +20 -0
- package/es/api/resources/VatControl.js.map +1 -0
- package/es/api/resources.d.ts +6 -0
- package/es/api/resources.d.ts.map +1 -1
- package/es/api/resources.js +6 -0
- package/es/api/resources.js.map +1 -1
- package/es/types/Enum/AnswerTypeValue.d.ts +10 -0
- package/es/types/Enum/AnswerTypeValue.d.ts.map +1 -0
- package/es/types/Enum/AnswerTypeValue.js +12 -0
- package/es/types/Enum/AnswerTypeValue.js.map +1 -0
- package/es/types/Enum/BalanceSheetQuestion.d.ts +12 -0
- package/es/types/Enum/BalanceSheetQuestion.d.ts.map +1 -0
- package/es/types/Enum/BalanceSheetQuestion.js +14 -0
- package/es/types/Enum/BalanceSheetQuestion.js.map +1 -0
- package/es/types/Enum/PartneredAccountantServiceType.d.ts +11 -0
- package/es/types/Enum/PartneredAccountantServiceType.d.ts.map +1 -0
- package/es/types/Enum/PartneredAccountantServiceType.js +40 -0
- package/es/types/Enum/PartneredAccountantServiceType.js.map +1 -0
- package/es/types/Enum/PartneredAccountantServiceTypeId.d.ts +9 -0
- package/es/types/Enum/PartneredAccountantServiceTypeId.d.ts.map +1 -0
- package/es/types/Enum/PartneredAccountantServiceTypeId.js +10 -0
- package/es/types/Enum/PartneredAccountantServiceTypeId.js.map +1 -0
- package/es/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.d.ts +1 -0
- package/es/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.d.ts.map +1 -1
- package/es/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.js +7 -0
- package/es/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.js.map +1 -1
- package/es/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.d.ts +1 -0
- package/es/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.d.ts.map +1 -1
- package/es/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.js +7 -0
- package/es/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.js.map +1 -1
- package/es/types/Interface/api/cerfa/ReadCerfa.d.ts +6 -0
- package/es/types/Interface/api/cerfa/ReadCerfa.d.ts.map +1 -0
- package/es/types/Interface/api/cerfa/ReadCerfa.js +2 -0
- package/es/types/Interface/api/cerfa/ReadCerfa.js.map +1 -0
- package/es/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.d.ts +10 -0
- package/es/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.d.ts.map +1 -0
- package/es/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.js +43 -0
- package/es/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.js.map +1 -0
- package/es/types/Interface/api/exerciceQuestion/QueryQuestion.d.ts +5 -0
- package/es/types/Interface/api/exerciceQuestion/QueryQuestion.d.ts.map +1 -0
- package/es/types/Interface/api/exerciceQuestion/QueryQuestion.js +23 -0
- package/es/types/Interface/api/exerciceQuestion/QueryQuestion.js.map +1 -0
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.d.ts +1 -0
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.d.ts.map +1 -1
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.js +4 -0
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.js.map +1 -1
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.d.ts +7 -0
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.d.ts.map +1 -0
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.js +32 -0
- package/es/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.js.map +1 -0
- package/es/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.d.ts +2 -0
- package/es/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.d.ts.map +1 -1
- package/es/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.js +8 -0
- package/es/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.js.map +1 -1
- package/es/types/Interface/models/IAnswerType.d.ts +9 -0
- package/es/types/Interface/models/IAnswerType.d.ts.map +1 -0
- package/es/types/Interface/models/IAnswerType.js +2 -0
- package/es/types/Interface/models/IAnswerType.js.map +1 -0
- package/es/types/Interface/models/IAnswerTypeValue.d.ts +10 -0
- package/es/types/Interface/models/IAnswerTypeValue.d.ts.map +1 -0
- package/es/types/Interface/models/IAnswerTypeValue.js +2 -0
- package/es/types/Interface/models/IAnswerTypeValue.js.map +1 -0
- package/es/types/Interface/models/IApiError.d.ts +3 -1
- package/es/types/Interface/models/IApiError.d.ts.map +1 -1
- package/es/types/Interface/models/IApiError.js +3 -0
- package/es/types/Interface/models/IApiError.js.map +1 -1
- package/es/types/Interface/models/IBalanceSheetModule.d.ts +1 -0
- package/es/types/Interface/models/IBalanceSheetModule.d.ts.map +1 -1
- package/es/types/Interface/models/IBalanceSheetModule.js.map +1 -1
- package/es/types/Interface/models/IBalanceSheetQuestion.d.ts +11 -0
- package/es/types/Interface/models/IBalanceSheetQuestion.d.ts.map +1 -0
- package/es/types/Interface/models/IBalanceSheetQuestion.js +2 -0
- package/es/types/Interface/models/IBalanceSheetQuestion.js.map +1 -0
- package/es/types/Interface/models/IExerciceQuestion.d.ts +16 -0
- package/es/types/Interface/models/IExerciceQuestion.d.ts.map +1 -0
- package/es/types/Interface/models/IExerciceQuestion.js +2 -0
- package/es/types/Interface/models/IExerciceQuestion.js.map +1 -0
- package/es/types/index.d.ts +12 -0
- package/es/types/index.d.ts.map +1 -1
- package/es/types/index.js +12 -0
- package/es/types/index.js.map +1 -1
- package/es/utils/cerfa.d.ts +6 -0
- package/es/utils/cerfa.d.ts.map +1 -0
- package/es/utils/cerfa.js +20 -0
- package/es/utils/cerfa.js.map +1 -0
- package/js/api/resources/BalanceSheetQuestion.js +20 -0
- package/js/api/resources/BalanceSheetQuestion.js.map +1 -0
- package/js/api/resources/Cerfa.js +12 -0
- package/js/api/resources/Cerfa.js.map +1 -1
- package/js/api/resources/ExerciceQuestion.js +28 -0
- package/js/api/resources/ExerciceQuestion.js.map +1 -0
- package/js/api/resources/PartneredAccountant.js +8 -0
- package/js/api/resources/PartneredAccountant.js.map +1 -1
- package/js/api/resources/VatControl.js +46 -0
- package/js/api/resources/VatControl.js.map +1 -0
- package/js/api/resources.js +10 -1
- package/js/api/resources.js.map +1 -1
- package/js/types/Enum/AnswerTypeValue.js +20 -0
- package/js/types/Enum/AnswerTypeValue.js.map +1 -0
- package/js/types/Enum/BalanceSheetQuestion.js +22 -0
- package/js/types/Enum/BalanceSheetQuestion.js.map +1 -0
- package/js/types/Enum/PartneredAccountantServiceType.js +48 -0
- package/js/types/Enum/PartneredAccountantServiceType.js.map +1 -0
- package/js/types/Enum/PartneredAccountantServiceTypeId.js +16 -0
- package/js/types/Enum/PartneredAccountantServiceTypeId.js.map +1 -0
- package/js/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.js +2 -0
- package/js/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.js.map +1 -1
- package/js/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.js +2 -0
- package/js/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.js.map +1 -1
- package/js/types/Interface/api/cerfa/ReadCerfa.js +6 -0
- package/js/types/Interface/api/cerfa/ReadCerfa.js.map +1 -0
- package/js/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.js +39 -0
- package/js/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.js.map +1 -0
- package/js/types/Interface/api/exerciceQuestion/QueryQuestion.js +33 -0
- package/js/types/Interface/api/exerciceQuestion/QueryQuestion.js.map +1 -0
- package/js/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.js +2 -0
- package/js/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.js.map +1 -1
- package/js/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.js +37 -0
- package/js/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.js.map +1 -0
- package/js/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.js +4 -0
- package/js/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.js.map +1 -1
- package/js/types/Interface/models/IAnswerType.js +6 -0
- package/js/types/Interface/models/IAnswerType.js.map +1 -0
- package/js/types/Interface/models/IAnswerTypeValue.js +6 -0
- package/js/types/Interface/models/IAnswerTypeValue.js.map +1 -0
- package/js/types/Interface/models/IApiError.js +4 -1
- package/js/types/Interface/models/IApiError.js.map +1 -1
- package/js/types/Interface/models/IBalanceSheetQuestion.js +6 -0
- package/js/types/Interface/models/IBalanceSheetQuestion.js.map +1 -0
- package/js/types/Interface/models/IExerciceQuestion.js +6 -0
- package/js/types/Interface/models/IExerciceQuestion.js.map +1 -0
- package/js/types/index.js +144 -0
- package/js/types/index.js.map +1 -1
- package/js/utils/cerfa.js +33 -0
- package/js/utils/cerfa.js.map +1 -0
- package/package.json +1 -1
- package/ts/api/resources/BalanceSheetQuestion.ts +8 -0
- package/ts/api/resources/Cerfa.ts +11 -1
- package/ts/api/resources/ExerciceQuestion.ts +16 -0
- package/ts/api/resources/PartneredAccountant.ts +9 -0
- package/ts/api/resources/VatControl.ts +26 -0
- package/ts/api/resources.ts +6 -0
- package/ts/types/Enum/AnswerTypeValue.ts +10 -0
- package/ts/types/Enum/BalanceSheetQuestion.ts +12 -0
- package/ts/types/Enum/PartneredAccountantServiceType.ts +52 -0
- package/ts/types/Enum/PartneredAccountantServiceTypeId.ts +8 -0
- package/ts/types/Interface/api/balanceSheetModule/CreateBalanceSheetModule.ts +6 -0
- package/ts/types/Interface/api/balanceSheetModule/UpdateBalanceSheetModule.ts +6 -0
- package/ts/types/Interface/api/cerfa/ReadCerfa.ts +6 -0
- package/ts/types/Interface/api/exerciceQuestion/CreateExerciceQuestion.ts +33 -0
- package/ts/types/Interface/api/exerciceQuestion/QueryQuestion.ts +12 -0
- package/ts/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService.ts +3 -0
- package/ts/types/Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress.ts +18 -0
- package/ts/types/Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService.ts +6 -0
- package/ts/types/Interface/models/IAnswerType.ts +12 -0
- package/ts/types/Interface/models/IAnswerTypeValue.ts +13 -0
- package/ts/types/Interface/models/IApiError.ts +4 -0
- package/ts/types/Interface/models/IBalanceSheetModule.ts +1 -0
- package/ts/types/Interface/models/IBalanceSheetQuestion.ts +14 -0
- package/ts/types/Interface/models/IExerciceQuestion.ts +19 -0
- package/ts/types/index.ts +12 -0
- package/ts/utils/cerfa.ts +26 -0
|
@@ -18,6 +18,7 @@ import {
|
|
|
18
18
|
QueryPartneredAccountantSocieties,
|
|
19
19
|
CreatedPartneredAccountantSociety,
|
|
20
20
|
ReadPartneredAccountantInvoice,
|
|
21
|
+
CreatePartneredAccountantRequestedServiceExpress,
|
|
21
22
|
} from '../../types';
|
|
22
23
|
import { Resource } from '../Resource';
|
|
23
24
|
import { ReadPartneredAccountantSociety } from '../../types/Interface/api/partneredAccountant/ReadPartneredAccountantSociety';
|
|
@@ -66,6 +67,14 @@ export class PartneredAccountant extends Resource {
|
|
|
66
67
|
return this.axios.$post(`/partnered-accountants/${idPartneredAccountant}/requested-services`, payload);
|
|
67
68
|
}
|
|
68
69
|
|
|
70
|
+
createRequestedServicesExpress(payload: Array<CreatePartneredAccountantRequestedServiceExpress>): Promise<Array<IPartneredAccountantCompanyService>> {
|
|
71
|
+
return this.axios.$post('/partnered-accountants/requested-services/express', payload);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
duplicateRequestedService(idRequest: number): Promise<Array<IPartneredAccountantCompanyService>> {
|
|
75
|
+
return this.axios.$post(`/partnered-accountants/requested-service/${idRequest}/duplicate`);
|
|
76
|
+
}
|
|
77
|
+
|
|
69
78
|
getPaginatedSocieties(params: QueryPaginate & QueryPartneredAccountantSocieties, cancelToken?: CancelToken): Promise<BasePaginate<ReadPartneredAccountantSociety>> {
|
|
70
79
|
return this.axios.$get('/partnered-accountants/societies', {
|
|
71
80
|
...(cancelToken ? { cancelToken } : {}),
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import {
|
|
2
|
+
CreateExerciceQuestions, IBalanceSheetQuestion, IExerciceQuestion, QueryVat, QuestionTheme, ReadVat,
|
|
3
|
+
} from '../..';
|
|
4
|
+
import { Resource } from '../Resource';
|
|
5
|
+
|
|
6
|
+
export class VatControl extends Resource {
|
|
7
|
+
getComputedVatValues(params: QueryVat): Promise<ReadVat> {
|
|
8
|
+
return this.axios.$get('/dashboard/vat', { params });
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
getQuestions(): Promise<Array<IBalanceSheetQuestion>> {
|
|
12
|
+
return this.axios.$get('/balance-sheets/questions', { params: { themes: [QuestionTheme.VAT_CONTROL] } });
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
getExerciceQuestions(idExercice: number): Promise<Array<IExerciceQuestion>> {
|
|
16
|
+
return this.axios.$get(`/balance-sheets/exercices/${idExercice}/questions`, { params: { themes: [QuestionTheme.VAT_CONTROL] } });
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
bulkCreate(idExercice: number, payload: CreateExerciceQuestions): Promise<Array<IExerciceQuestion>> {
|
|
20
|
+
return this.axios.$post(`/balance-sheets/exercices/${idExercice}/questions/batch-create`, payload);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
bulkUpdate(idExercice: number, payload: CreateExerciceQuestions): Promise<void> {
|
|
24
|
+
return this.axios.$post(`/balance-sheets/exercices/${idExercice}/questions/batch-update`, payload);
|
|
25
|
+
}
|
|
26
|
+
}
|
package/ts/api/resources.ts
CHANGED
|
@@ -47,6 +47,9 @@ import { Journal } from './resources/Journal';
|
|
|
47
47
|
import { Product } from './resources/Product';
|
|
48
48
|
import { MealExpense } from './resources/MealExpense';
|
|
49
49
|
import { InternalInvoicing } from './resources/InternalInvoicing';
|
|
50
|
+
import { BalanceSheetQuestion } from './resources/BalanceSheetQuestion';
|
|
51
|
+
import { ExerciceQuestion } from './resources/ExerciceQuestion';
|
|
52
|
+
import { VatControl } from './resources/VatControl';
|
|
50
53
|
|
|
51
54
|
export const resources = {
|
|
52
55
|
simulation: Simulation,
|
|
@@ -98,4 +101,7 @@ export const resources = {
|
|
|
98
101
|
journal: Journal,
|
|
99
102
|
product: Product,
|
|
100
103
|
mealExpense: MealExpense,
|
|
104
|
+
balanceSheetQuestion: BalanceSheetQuestion,
|
|
105
|
+
exerciceQuestion: ExerciceQuestion,
|
|
106
|
+
vatControl: VatControl,
|
|
101
107
|
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export enum QuestionTheme {
|
|
2
|
+
CAPITAL = 'CAPITAL',
|
|
3
|
+
VAT_CONTROL = 'VAT_CONTROL',
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
export enum Question {
|
|
7
|
+
CAPITAL_FULLY_REPAID = 'Est ce que le capital a été entièrement reversé et est détenu à au moins 75 % par des personnes physiques ?',
|
|
8
|
+
CAPITAL_FULLY_PAID_UP = 'Est ce que le capital social est entièrement libéré ?',
|
|
9
|
+
VERIFIED_DEDUCTIBLE_VAT = 'TVA déductible',
|
|
10
|
+
VERIFIED_COLLECTED_VAT = 'TVA collectée',
|
|
11
|
+
VERIFIED_DEDUCTIBLE_VAT_FROM_RETROCESSION_FEES = 'Dont TVA déductible afférente aux honoraires retrocédés',
|
|
12
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { PartneredAccountantServiceTypeId } from './PartneredAccountantServiceTypeId';
|
|
2
|
+
|
|
3
|
+
export type PartneredAccountantServiceTypeTypeContent = {
|
|
4
|
+
id: number;
|
|
5
|
+
name: string;
|
|
6
|
+
imageSVG: string;
|
|
7
|
+
imagePNG: string;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export type PartneredAccountantServiceTypeType = {
|
|
11
|
+
[key: string]: PartneredAccountantServiceTypeTypeContent
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const PartneredAccountantServiceType: PartneredAccountantServiceTypeType = {
|
|
15
|
+
CERTIFICATION: {
|
|
16
|
+
id: PartneredAccountantServiceTypeId.CERTIFICATION,
|
|
17
|
+
name: 'Certification du bilan',
|
|
18
|
+
imageSVG: 'certificationDuBilan.svg',
|
|
19
|
+
imagePNG: 'Icon_3.png',
|
|
20
|
+
},
|
|
21
|
+
FOLLOW_UP: {
|
|
22
|
+
id: PartneredAccountantServiceTypeId.FOLLOW_UP,
|
|
23
|
+
name: 'Suivi comptable',
|
|
24
|
+
imageSVG: 'suiviMensuel.svg',
|
|
25
|
+
imagePNG: 'Icon_1.png',
|
|
26
|
+
},
|
|
27
|
+
FORECAST: {
|
|
28
|
+
id: PartneredAccountantServiceTypeId.FORECAST,
|
|
29
|
+
name: 'Bilan prévisionnel',
|
|
30
|
+
imageSVG: 'bilanPrevisionnel.svg',
|
|
31
|
+
imagePNG: 'Icon_2.png',
|
|
32
|
+
},
|
|
33
|
+
CREATION_DISSOLUTION: {
|
|
34
|
+
id: PartneredAccountantServiceTypeId.CREATION_DISSOLUTION,
|
|
35
|
+
name: 'Constitution/ dissolution',
|
|
36
|
+
imageSVG: 'dissolution.svg',
|
|
37
|
+
imagePNG: 'Icon_8.png',
|
|
38
|
+
},
|
|
39
|
+
LIQUIDATION: {
|
|
40
|
+
id: PartneredAccountantServiceTypeId.LIQUIDATION,
|
|
41
|
+
name: 'Bilan de liquidation',
|
|
42
|
+
imageSVG: 'bilanLiquidation.svg',
|
|
43
|
+
imagePNG: 'Icon_7.png',
|
|
44
|
+
},
|
|
45
|
+
OTHER: {
|
|
46
|
+
id: PartneredAccountantServiceTypeId.OTHER,
|
|
47
|
+
name: 'Conseils et autres',
|
|
48
|
+
imageSVG: 'prestationGenerique.svg',
|
|
49
|
+
imagePNG: 'Icon_9.png',
|
|
50
|
+
},
|
|
51
|
+
|
|
52
|
+
};
|
|
@@ -51,6 +51,12 @@ export class CreateBalanceSheetModuleForm {
|
|
|
51
51
|
@IsOptional()
|
|
52
52
|
hasMealExpenses?: boolean | null;
|
|
53
53
|
|
|
54
|
+
@ApiPropertyOptional()
|
|
55
|
+
@IsBoolean()
|
|
56
|
+
@ToBoolean()
|
|
57
|
+
@IsOptional()
|
|
58
|
+
hasCheckedVAT?: boolean | null;
|
|
59
|
+
|
|
54
60
|
@ApiProperty()
|
|
55
61
|
idExercice: number;
|
|
56
62
|
}
|
|
@@ -51,6 +51,12 @@ export class UpdateBalanceSheetModuleForm {
|
|
|
51
51
|
@IsOptional()
|
|
52
52
|
hasMealExpenses?: boolean | null;
|
|
53
53
|
|
|
54
|
+
@ApiPropertyOptional()
|
|
55
|
+
@IsBoolean()
|
|
56
|
+
@ToBoolean()
|
|
57
|
+
@IsOptional()
|
|
58
|
+
hasCheckedVAT?: boolean | null;
|
|
59
|
+
|
|
54
60
|
@ApiPropertyOptional()
|
|
55
61
|
idExercice?: number;
|
|
56
62
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ArrayUnique,
|
|
3
|
+
IsArray,
|
|
4
|
+
IsInt, IsOptional, IsPositive, IsString, ValidateNested,
|
|
5
|
+
} from 'class-validator';
|
|
6
|
+
import { ApiProperty, ApiPropertyOptional } from '../../../..';
|
|
7
|
+
|
|
8
|
+
class ExerciceQuestion {
|
|
9
|
+
@ApiProperty()
|
|
10
|
+
@IsInt()
|
|
11
|
+
@IsPositive()
|
|
12
|
+
idQuestion: number;
|
|
13
|
+
|
|
14
|
+
@ApiPropertyOptional()
|
|
15
|
+
@IsOptional()
|
|
16
|
+
@IsInt()
|
|
17
|
+
@IsPositive()
|
|
18
|
+
idAnswerTypeValue?: number;
|
|
19
|
+
|
|
20
|
+
@ApiPropertyOptional()
|
|
21
|
+
@IsOptional()
|
|
22
|
+
@IsString()
|
|
23
|
+
answer?: string;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export class CreateExerciceQuestions {
|
|
27
|
+
@IsArray()
|
|
28
|
+
@ArrayUnique((q) => q.idQuestion)
|
|
29
|
+
@ValidateNested({
|
|
30
|
+
each: true,
|
|
31
|
+
})
|
|
32
|
+
exerciceQuestions: Array<ExerciceQuestion>;
|
|
33
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IsEnum, IsOptional } from 'class-validator';
|
|
2
|
+
import { QuestionTheme } from '../../..';
|
|
3
|
+
import { ApiPropertyOptional } from '../../../..';
|
|
4
|
+
|
|
5
|
+
export class QueryQuestion {
|
|
6
|
+
@ApiPropertyOptional()
|
|
7
|
+
@IsOptional()
|
|
8
|
+
@IsEnum(QuestionTheme, {
|
|
9
|
+
each: true,
|
|
10
|
+
})
|
|
11
|
+
themes?: Array<QuestionTheme>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { IsEnum } from 'class-validator';
|
|
2
|
+
import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
|
|
3
|
+
import { PartneredAccountantServiceTypeId } from '../../../Enum/PartneredAccountantServiceTypeId';
|
|
4
|
+
|
|
5
|
+
export class CreatePartneredAccountantRequestedServiceExpress {
|
|
6
|
+
@ApiPropertyOptional()
|
|
7
|
+
idPartneredAccountantService?: number;
|
|
8
|
+
|
|
9
|
+
@ApiProperty()
|
|
10
|
+
notes: string;
|
|
11
|
+
|
|
12
|
+
@ApiPropertyOptional()
|
|
13
|
+
preTaxPrice?: number;
|
|
14
|
+
|
|
15
|
+
@ApiPropertyOptional()
|
|
16
|
+
@IsEnum(PartneredAccountantServiceTypeId)
|
|
17
|
+
idServiceType?: number;
|
|
18
|
+
}
|
|
@@ -138,6 +138,10 @@ export enum Code {
|
|
|
138
138
|
|
|
139
139
|
// Accounts
|
|
140
140
|
GENERIC_ACCOUNT_NOT_FOUND = 'GENERIC_ACCOUNT_NOT_FOUND',
|
|
141
|
+
|
|
142
|
+
// Balance Sheet Questions
|
|
143
|
+
UNKNOWN_ANSWER_VALUE = 'UNKNOWN_ANSWER_VALUE',
|
|
144
|
+
QUESTION_ALREADY_EXISTS_IN_EXERCICE = 'QUESTION_ALREADY_EXISTS_IN_EXERCICE',
|
|
141
145
|
}
|
|
142
146
|
|
|
143
147
|
export interface IApiError {
|
|
@@ -14,6 +14,7 @@ export interface IBalanceSheetModule {
|
|
|
14
14
|
hasManualEntryToDeclare?: boolean | null;
|
|
15
15
|
hasLaundryFees?: boolean | null;
|
|
16
16
|
hasMealExpenses?: boolean | null;
|
|
17
|
+
hasCheckedVAT?: boolean | null;
|
|
17
18
|
idSociety: number;
|
|
18
19
|
idExercice: number;
|
|
19
20
|
createdAt?: Date | null;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { IAnswerType } from './IAnswerType';
|
|
2
|
+
|
|
3
|
+
export interface IBalanceSheetQuestion {
|
|
4
|
+
id: number;
|
|
5
|
+
name: string;
|
|
6
|
+
theme: string;
|
|
7
|
+
idAnswerType: number;
|
|
8
|
+
|
|
9
|
+
createdAt?: Date | null;
|
|
10
|
+
updatedAt?: Date | null;
|
|
11
|
+
|
|
12
|
+
// Associations
|
|
13
|
+
answerType?: IAnswerType;
|
|
14
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { IAnswerTypeValue } from './IAnswerTypeValue';
|
|
2
|
+
import { IBalanceSheetQuestion } from './IBalanceSheetQuestion';
|
|
3
|
+
import { IExercice } from './IExercice';
|
|
4
|
+
|
|
5
|
+
export interface IExerciceQuestion {
|
|
6
|
+
id: number;
|
|
7
|
+
idExercice: number;
|
|
8
|
+
idQuestion: number;
|
|
9
|
+
idAnswerTypeValue?: number;
|
|
10
|
+
answer?: string;
|
|
11
|
+
|
|
12
|
+
createdAt?: Date | null;
|
|
13
|
+
updatedAt?: Date | null;
|
|
14
|
+
|
|
15
|
+
// Associations
|
|
16
|
+
exercice?: IExercice;
|
|
17
|
+
question?: IBalanceSheetQuestion;
|
|
18
|
+
answerTypeValue?: IAnswerTypeValue;
|
|
19
|
+
}
|
package/ts/types/index.ts
CHANGED
|
@@ -291,6 +291,10 @@ export * from './Interface/models/IRevisionGuide';
|
|
|
291
291
|
export * from './Interface/models/ISponsorshipWithSponsorInfo';
|
|
292
292
|
export * from './Interface/models/ILastUpdateConnection';
|
|
293
293
|
export * from './Interface/models/IAccountsSectors';
|
|
294
|
+
export * from './Interface/models/IAnswerType';
|
|
295
|
+
export * from './Interface/models/IAnswerTypeValue';
|
|
296
|
+
export * from './Interface/models/IBalanceSheetQuestion';
|
|
297
|
+
export * from './Interface/models/IExerciceQuestion';
|
|
294
298
|
|
|
295
299
|
// Forms
|
|
296
300
|
export * from './Form/FormAuthenticate';
|
|
@@ -298,6 +302,7 @@ export * from './Form/FormConnector';
|
|
|
298
302
|
|
|
299
303
|
// Enums
|
|
300
304
|
export * from './Enum/Tax';
|
|
305
|
+
export * from './Enum/ProfitsType';
|
|
301
306
|
export * from './Enum/RegistrationSource';
|
|
302
307
|
export * from './Enum/Log';
|
|
303
308
|
export * from './Enum/Quality';
|
|
@@ -370,10 +375,14 @@ export * from './Enum/ProductType';
|
|
|
370
375
|
export * from './Enum/Unit';
|
|
371
376
|
export * from './Enum/MealExpenseTresholds';
|
|
372
377
|
export * from './Enum/MimeType';
|
|
378
|
+
export * from './Enum/BalanceSheetQuestion';
|
|
379
|
+
export * from './Enum/AnswerTypeValue';
|
|
380
|
+
export * from './Enum/PartneredAccountantServiceType';
|
|
373
381
|
|
|
374
382
|
// Interfaces API
|
|
375
383
|
export * from './Interface/api/businessPartner/ReadBusinessPartner';
|
|
376
384
|
export * from './Interface/api/simulation/CreateSimulation';
|
|
385
|
+
export * from './Interface/api/cerfa/ReadCerfa';
|
|
377
386
|
export * from './Interface/api/accountingEntry/AnnotateAccountingTransaction';
|
|
378
387
|
export * from './Interface/api/accountingEntry/CreateManualEntry';
|
|
379
388
|
export * from './Interface/api/immobilization/ReadFormattedImmobilization';
|
|
@@ -534,6 +543,7 @@ export * from './Interface/api/partneredAccountant/QueryParteneredAccountantSold
|
|
|
534
543
|
export * from './Interface/api/partneredAccountant/ReadPartneredAccountantSoldServicesPaginated';
|
|
535
544
|
export * from './Interface/api/partneredAccountant/ReadPartneredAccountantRequestedService';
|
|
536
545
|
export * from './Interface/api/partneredAccountant/CreatePartneredAccountantRequestedService';
|
|
546
|
+
export * from './Interface/api/partneredAccountant/CreatePartneredAccountantRequestedServiceExpress';
|
|
537
547
|
export * from './Interface/api/partneredAccountant/CreatePartneredAccountantSociety';
|
|
538
548
|
export * from './Interface/api/partneredAccountant/ReadPartneredAccountantSociety';
|
|
539
549
|
export * from './Interface/api/partneredAccountant/UpdatePartneredAccountantSoldService';
|
|
@@ -556,3 +566,5 @@ export * from './Interface/api/journal/QueryJournal';
|
|
|
556
566
|
export * from './Interface/api/balanceSheet/ReadBalanceSheetTransaction';
|
|
557
567
|
export * from './Interface/api/mealExpense/CreateMealExpense';
|
|
558
568
|
export * from './Interface/api/mealExpense/ReadMealExpense';
|
|
569
|
+
export * from './Interface/api/exerciceQuestion/QueryQuestion';
|
|
570
|
+
export * from './Interface/api/exerciceQuestion/CreateExerciceQuestion';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ReadCerfaToComplete } from '../types/Interface/api/cerfa/ReadCerfa';
|
|
2
|
+
import { GlobalRegime, GlobalRegimeTypeContent } from '../types/Enum/GlobalRegime';
|
|
3
|
+
import { ProfitsType, FiscalRegime, TaxSystem } from '../types';
|
|
4
|
+
|
|
5
|
+
export function retrieveCerfaFromSocietyInformations(idLegalForm: number, idTaxSystem: TaxSystem, idFiscalRegime: FiscalRegime, profitsType: ProfitsType):ReadCerfaToComplete {
|
|
6
|
+
const globalRegimes = Object.values(GlobalRegime);
|
|
7
|
+
const selectedGlobalRegime = globalRegimes.find((gr) => gr.idLegalForms.includes(idLegalForm));
|
|
8
|
+
|
|
9
|
+
if (!selectedGlobalRegime) throw Error('Missing informations to retrieve CERFA informations');
|
|
10
|
+
|
|
11
|
+
const choiceIndex = selectedGlobalRegime.choices.findIndex((sgr) => sgr.idFiscalRegime === idFiscalRegime && sgr.profitsType === profitsType && sgr.idTaxSystem === idTaxSystem);
|
|
12
|
+
|
|
13
|
+
if (choiceIndex < 0) throw Error('Missing informations to retrieve CERFA informations');
|
|
14
|
+
|
|
15
|
+
const { declaration, annexe } = selectedGlobalRegime.choices[choiceIndex];
|
|
16
|
+
|
|
17
|
+
return { declaration, annex: annexe ?? null };
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export function retreiveChoicesDependingLegalForm(idLegalForm: number): GlobalRegimeTypeContent {
|
|
21
|
+
const globalRegimes = Object.values(GlobalRegime);
|
|
22
|
+
const selectedGlobalRegime = globalRegimes.find((gr) => gr.idLegalForms.includes(idLegalForm));
|
|
23
|
+
|
|
24
|
+
if (!selectedGlobalRegime) throw Error(`LegalForm #${idLegalForm} not implemented`);
|
|
25
|
+
return selectedGlobalRegime;
|
|
26
|
+
}
|