@silexpert/core 1.1.77 → 1.1.78
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/SocietyConfigBalanceSheet.d.ts +1 -0
- package/es/api/resources/SocietyConfigBalanceSheet.d.ts.map +1 -1
- package/es/api/resources/SocietyConfigBalanceSheet.js +3 -0
- package/es/api/resources/SocietyConfigBalanceSheet.js.map +1 -1
- package/es/types/Enum/Activity.d.ts +12 -0
- package/es/types/Enum/Activity.d.ts.map +1 -1
- package/es/types/Enum/Activity.js +13 -0
- package/es/types/Enum/Activity.js.map +1 -1
- package/es/types/Enum/DepositDocumentType.d.ts +9 -0
- package/es/types/Enum/DepositDocumentType.d.ts.map +1 -1
- package/es/types/Enum/DepositDocumentType.js +37 -0
- package/es/types/Enum/DepositDocumentType.js.map +1 -1
- package/es/types/Enum/Ged.d.ts +21 -1
- package/es/types/Enum/Ged.d.ts.map +1 -1
- package/es/types/Enum/Ged.js +34 -0
- package/es/types/Enum/Ged.js.map +1 -1
- package/es/types/Interface/api/society/SocietyWithStatsCaParams.d.ts +2 -0
- package/es/types/Interface/api/society/SocietyWithStatsCaParams.d.ts.map +1 -1
- package/es/types/Interface/api/society/SocietyWithStatsCaParams.js.map +1 -1
- package/es/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.d.ts +2 -0
- package/es/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.d.ts.map +1 -1
- package/es/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.js +11 -3
- package/es/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.js.map +1 -1
- package/es/types/Interface/models/ISocietyConfigBalanceSheet.d.ts +2 -1
- package/es/types/Interface/models/ISocietyConfigBalanceSheet.d.ts.map +1 -1
- package/es/types/Interface/models/ISocietyConfigBalanceSheet.js.map +1 -1
- package/es/utils/vat/utils.d.ts +1 -1
- package/es/utils/vat/utils.d.ts.map +1 -1
- package/es/utils/vat/utils.js +8 -1
- package/es/utils/vat/utils.js.map +1 -1
- package/js/api/resources/SocietyConfigBalanceSheet.js +3 -0
- package/js/api/resources/SocietyConfigBalanceSheet.js.map +1 -1
- package/js/types/Enum/Activity.js +26 -12
- package/js/types/Enum/Activity.js.map +1 -1
- package/js/types/Enum/DepositDocumentType.js +31 -1
- package/js/types/Enum/DepositDocumentType.js.map +1 -1
- package/js/types/Enum/Ged.js +28 -0
- package/js/types/Enum/Ged.js.map +1 -1
- package/js/types/Interface/api/society/SocietyWithStatsCaParams.js.map +1 -1
- package/js/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.js +3 -1
- package/js/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.js.map +1 -1
- package/js/types/Interface/models/ISocietyConfigBalanceSheet.js.map +1 -1
- package/js/utils/vat/utils.js +6 -1
- package/js/utils/vat/utils.js.map +1 -1
- package/package.json +1 -1
- package/ts/api/resources/SocietyConfigBalanceSheet.ts +4 -0
- package/ts/types/Enum/Activity.ts +14 -0
- package/ts/types/Enum/DepositDocumentType.ts +39 -1
- package/ts/types/Enum/Ged.ts +36 -0
- package/ts/types/Interface/api/society/SocietyWithStatsCaParams.ts +3 -1
- package/ts/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.ts +10 -3
- package/ts/types/Interface/models/ISocietyConfigBalanceSheet.ts +2 -1
- package/ts/utils/vat/utils.ts +8 -1
|
@@ -171,4 +171,42 @@ export const DepositDocumentType = [
|
|
|
171
171
|
},
|
|
172
172
|
],
|
|
173
173
|
},
|
|
174
|
-
];
|
|
174
|
+
];
|
|
175
|
+
|
|
176
|
+
export const JuridicalDepositDocumentType = [
|
|
177
|
+
{
|
|
178
|
+
id: TypeFile.IDENTITY_CARD_RECTO,
|
|
179
|
+
name: 'Justificatif d’identité recto',
|
|
180
|
+
idGedFolder: GedFolder.FORMALISM,
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
id: TypeFile.IDENTITY_CARD_VERSO,
|
|
184
|
+
name: 'Justificatif d’identité verso',
|
|
185
|
+
idGedFolder: GedFolder.FORMALISM,
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
id: TypeFile.RESIDENCE_CERTIFICATE,
|
|
189
|
+
name: 'Attestation domicile',
|
|
190
|
+
idGedFolder: GedFolder.FORMALISM,
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
id: TypeFile.NO_CONDEMNATION,
|
|
194
|
+
name: 'Attestation non condamnation',
|
|
195
|
+
idGedFolder: GedFolder.JURIDICAL,
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
id: TypeFile.CAPITAL_DEPOSIT,
|
|
199
|
+
name: 'Attestation dépôt de capital',
|
|
200
|
+
idGedFolder: GedFolder.JURIDICAL,
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
id: TypeFile.DOMICILIATION,
|
|
204
|
+
name: 'Contrat domiciliation',
|
|
205
|
+
idGedFolder: GedFolder.FORMALISM,
|
|
206
|
+
},
|
|
207
|
+
];
|
|
208
|
+
|
|
209
|
+
export enum DocumentConfigurationType {
|
|
210
|
+
BALANCESHEET = 1,
|
|
211
|
+
JURIDICAL = 2,
|
|
212
|
+
}
|
package/ts/types/Enum/Ged.ts
CHANGED
|
@@ -77,6 +77,16 @@ export enum TypeFile {
|
|
|
77
77
|
FUND_TO_SIGN = 26,
|
|
78
78
|
SUPPLIER_BOOK_TO_SIGN = 27,
|
|
79
79
|
CLIENT_BOOK_TO_SIGN = 28,
|
|
80
|
+
STATUTES_PROJECT = 29,
|
|
81
|
+
IDENTITY_CARD_RECTO = 30,
|
|
82
|
+
IDENTITY_CARD_VERSO = 31,
|
|
83
|
+
RESIDENCE_CERTIFICATE = 32,
|
|
84
|
+
NO_CONDEMNATION = 33,
|
|
85
|
+
CAPITAL_DEPOSIT = 34,
|
|
86
|
+
DOMICILIATION = 35,
|
|
87
|
+
DEFINITIVE_STATUTES = 36,
|
|
88
|
+
LEGAL_ANNOUNCEMENT = 37,
|
|
89
|
+
DEPOSIT_GREFFE = 38,
|
|
80
90
|
}
|
|
81
91
|
|
|
82
92
|
export enum GedFileType {
|
|
@@ -130,6 +140,32 @@ export const SignFileDetail = [
|
|
|
130
140
|
},
|
|
131
141
|
];
|
|
132
142
|
|
|
143
|
+
export const JuridicalSignFileDetail = [
|
|
144
|
+
{
|
|
145
|
+
id: TypeFile.STATUTES_PROJECT,
|
|
146
|
+
name: 'Projet de statut',
|
|
147
|
+
idGedFolder: GedFolder.JURIDICAL,
|
|
148
|
+
},
|
|
149
|
+
];
|
|
150
|
+
|
|
151
|
+
export const JuridicalJuristFile = [
|
|
152
|
+
{
|
|
153
|
+
id: TypeFile.DEFINITIVE_STATUTES,
|
|
154
|
+
title: 'Statut définitif',
|
|
155
|
+
idGedFolder: GedFolder.JURIDICAL,
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
id: TypeFile.LEGAL_ANNOUNCEMENT,
|
|
159
|
+
title: 'Attestation annonce légale',
|
|
160
|
+
idGedFolder: GedFolder.LEGAL_ANNOUNCEMENTS,
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
id: TypeFile.DEPOSIT_GREFFE,
|
|
164
|
+
title: 'Attestation dépôt Greffe',
|
|
165
|
+
idGedFolder: GedFolder.JURIDICAL,
|
|
166
|
+
},
|
|
167
|
+
];
|
|
168
|
+
|
|
133
169
|
export const GedFileTypeDetail = {
|
|
134
170
|
STATUTES: {
|
|
135
171
|
id: GedFileType.STATUTES,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GedFileType } from '../../../Enum/Ged';
|
|
2
2
|
import { IRegulate } from '../../models/IRegulate';
|
|
3
|
+
import { IRegulation } from '../../models/IRegulation';
|
|
3
4
|
import { ISociety } from '../../models/ISociety';
|
|
4
5
|
import { ReadInvalidFieldState } from './ReadSociety';
|
|
5
6
|
|
|
@@ -9,5 +10,6 @@ export interface SocietyWithStatsCaParams extends ISociety {
|
|
|
9
10
|
stateOfProgress?: string,
|
|
10
11
|
isBillingOk?: boolean,
|
|
11
12
|
labAcceptation?: boolean,
|
|
12
|
-
regulates?: IRegulate[]
|
|
13
|
+
regulates?: IRegulate[],
|
|
14
|
+
regulation?: IRegulation
|
|
13
15
|
}
|
package/ts/types/Interface/api/societyConfigBalanceSheet/QueryGetAllSocietyConfigBalanceSheet.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
|
-
IsOptional, IsString, IsIn, IsInt,
|
|
2
|
+
IsOptional, IsString, IsIn, IsInt, IsEnum,
|
|
3
3
|
} from 'class-validator';
|
|
4
|
-
import { ApiPropertyOptional
|
|
4
|
+
import { ApiPropertyOptional } from '../../../../utils';
|
|
5
|
+
import { DocumentConfigurationType } from '../../../Enum/DepositDocumentType';
|
|
5
6
|
|
|
6
7
|
export class QueryGetAllSocietyConfigBalanceSheet {
|
|
7
|
-
@
|
|
8
|
+
@ApiPropertyOptional()
|
|
8
9
|
@IsInt()
|
|
10
|
+
@IsOptional()
|
|
9
11
|
idBalanceSheet?: number;
|
|
10
12
|
|
|
11
13
|
@ApiPropertyOptional()
|
|
@@ -22,4 +24,9 @@ export class QueryGetAllSocietyConfigBalanceSheet {
|
|
|
22
24
|
})
|
|
23
25
|
@IsIn(['society', 'user'], { each: true })
|
|
24
26
|
include?: string[];
|
|
27
|
+
|
|
28
|
+
@ApiPropertyOptional()
|
|
29
|
+
@IsEnum(DocumentConfigurationType)
|
|
30
|
+
@IsOptional()
|
|
31
|
+
configurationType?: DocumentConfigurationType;
|
|
25
32
|
}
|
|
@@ -3,7 +3,7 @@ import { IExercice } from './IExercice';
|
|
|
3
3
|
import { IBalanceSheet } from './IBalanceSheet';
|
|
4
4
|
import { ISociety } from './ISociety';
|
|
5
5
|
import { IUser } from './IUser';
|
|
6
|
-
import { StateDepositDocument, StateClientDepositDocument } from '../../Enum/DepositDocumentType';
|
|
6
|
+
import { StateDepositDocument, StateClientDepositDocument, DocumentConfigurationType } from '../../Enum/DepositDocumentType';
|
|
7
7
|
|
|
8
8
|
// societyConfigBalanceSheet
|
|
9
9
|
export interface ISocietyConfigBalanceSheet {
|
|
@@ -13,6 +13,7 @@ export interface ISocietyConfigBalanceSheet {
|
|
|
13
13
|
idSociety: number | null;
|
|
14
14
|
comment: string | null;
|
|
15
15
|
amount: number | null;
|
|
16
|
+
configurationType: DocumentConfigurationType;
|
|
16
17
|
idTypeDocumentsWaiting?: number | null;
|
|
17
18
|
idExercice: number | null;
|
|
18
19
|
idBalanceSheet: number | null;
|
package/ts/utils/vat/utils.ts
CHANGED
|
@@ -22,12 +22,18 @@ export function setZeroIfIsNegative(value: number): number {
|
|
|
22
22
|
return value < 0 ? 0 : value;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
export function getTaxAmountByAccountNumber(accountingEntries: IAccountingEntry[], accountsNumber: string[], precision = 0): number {
|
|
25
|
+
export function getTaxAmountByAccountNumber(accountingEntries: IAccountingEntry[], accountsNumber: string[], precision = 0, logging = false): number {
|
|
26
26
|
const accountingEntriesUniq = _uniqBy(accountingEntries, 'id');
|
|
27
27
|
return _round(accountingEntriesUniq.reduce((acc, accountingEntry) => {
|
|
28
28
|
let accTmp = acc;
|
|
29
29
|
accountsNumber.some((number) => {
|
|
30
30
|
if (accountingEntry.account && accountingEntry.account.number && accountingEntry.account.number.toString().startsWith(number)) {
|
|
31
|
+
|
|
32
|
+
// eslint-disable-next-line no-console
|
|
33
|
+
if (logging) console.log('\'\'');
|
|
34
|
+
// eslint-disable-next-line no-console
|
|
35
|
+
if (logging) console.log(accountingEntry);
|
|
36
|
+
|
|
31
37
|
accTmp += ((accountingEntry.debit - accountingEntry.credit) * (((Object.values(Vat).find((v) => v.id === accountingEntry.idVat)?.value ?? 0) / 100)));
|
|
32
38
|
return true;
|
|
33
39
|
}
|
|
@@ -47,6 +53,7 @@ export function textFormatting(value: any, length: number | null = null): string
|
|
|
47
53
|
formattedValue = formattedValue.replace(/"/g, ''); // Suppression des "
|
|
48
54
|
formattedValue = formattedValue.replace(/^ */, ''); // Suppression des espaces de début
|
|
49
55
|
formattedValue = formattedValue.replace(/ *$/, ''); // Suppression des espaces de fin
|
|
56
|
+
formattedValue = formattedValue.replace(/€/g, 'EUR');
|
|
50
57
|
if (length) formattedValue = formattedValue.slice(0, length);
|
|
51
58
|
return formattedValue;
|
|
52
59
|
}
|