@silexpert/core 0.4.18 → 0.4.20

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.
Files changed (127) hide show
  1. package/es/api/resources/Transaction.d.ts +2 -1
  2. package/es/api/resources/Transaction.d.ts.map +1 -1
  3. package/es/api/resources/Transaction.js +3 -0
  4. package/es/api/resources/Transaction.js.map +1 -1
  5. package/es/types/Enum/ComptaType.d.ts +1 -1
  6. package/es/types/Enum/ComptaType.js +1 -1
  7. package/es/types/Enum/ComptaType.js.map +1 -1
  8. package/es/types/Enum/PartnerTransactionType.d.ts +7 -0
  9. package/es/types/Enum/PartnerTransactionType.d.ts.map +1 -0
  10. package/es/types/Enum/PartnerTransactionType.js +8 -0
  11. package/es/types/Enum/PartnerTransactionType.js.map +1 -0
  12. package/es/types/Interface/api/account/CreateAccountSociety.d.ts +7 -0
  13. package/es/types/Interface/api/account/CreateAccountSociety.d.ts.map +1 -0
  14. package/es/types/Interface/api/account/CreateAccountSociety.js +29 -0
  15. package/es/types/Interface/api/account/CreateAccountSociety.js.map +1 -0
  16. package/es/types/Interface/api/account/QueryAccountSociety.d.ts +8 -0
  17. package/es/types/Interface/api/account/QueryAccountSociety.d.ts.map +1 -0
  18. package/es/types/Interface/api/account/QueryAccountSociety.js +33 -0
  19. package/es/types/Interface/api/account/QueryAccountSociety.js.map +1 -0
  20. package/es/types/Interface/api/account/QueryGenericAccount.d.ts +6 -0
  21. package/es/types/Interface/api/account/QueryGenericAccount.d.ts.map +1 -0
  22. package/es/types/Interface/api/account/QueryGenericAccount.js +25 -0
  23. package/es/types/Interface/api/account/QueryGenericAccount.js.map +1 -0
  24. package/es/types/Interface/api/account/UpdateAccountSociety.d.ts +8 -0
  25. package/es/types/Interface/api/account/UpdateAccountSociety.d.ts.map +1 -0
  26. package/es/types/Interface/api/account/UpdateAccountSociety.js +29 -0
  27. package/es/types/Interface/api/account/UpdateAccountSociety.js.map +1 -0
  28. package/es/types/Interface/api/bankAccount/DeleteTransaction.d.ts +9 -0
  29. package/es/types/Interface/api/bankAccount/DeleteTransaction.d.ts.map +1 -0
  30. package/es/types/Interface/api/bankAccount/DeleteTransaction.js +37 -0
  31. package/es/types/Interface/api/bankAccount/DeleteTransaction.js.map +1 -0
  32. package/es/types/Interface/api/shine/CreateShine.d.ts +80 -0
  33. package/es/types/Interface/api/shine/CreateShine.d.ts.map +1 -0
  34. package/es/types/Interface/api/shine/CreateShine.js +2 -0
  35. package/es/types/Interface/api/shine/CreateShine.js.map +1 -0
  36. package/es/types/Interface/api/society/LegalFormSiren.d.ts +2 -0
  37. package/es/types/Interface/api/society/LegalFormSiren.d.ts.map +1 -1
  38. package/es/types/Interface/api/society/LegalFormSiren.js.map +1 -1
  39. package/es/types/Interface/models/IAccountingTransaction.d.ts +1 -1
  40. package/es/types/Interface/models/IAccountingTransaction.d.ts.map +1 -1
  41. package/es/types/Interface/models/IAccountingTransaction.js.map +1 -1
  42. package/es/types/Interface/models/IApiError.d.ts +29 -0
  43. package/es/types/Interface/models/IApiError.d.ts.map +1 -1
  44. package/es/types/Interface/models/IApiError.js +30 -0
  45. package/es/types/Interface/models/IApiError.js.map +1 -1
  46. package/es/types/Interface/models/IBankConnection.d.ts +4 -1
  47. package/es/types/Interface/models/IBankConnection.d.ts.map +1 -1
  48. package/es/types/Interface/models/IBankConnection.js.map +1 -1
  49. package/es/types/Interface/models/IBankTransaction.d.ts +1 -1
  50. package/es/types/Interface/models/IBankTransaction.d.ts.map +1 -1
  51. package/es/types/Interface/models/IBankTransaction.js.map +1 -1
  52. package/es/types/Interface/models/IEngagementBankTransaction.d.ts +1 -1
  53. package/es/types/Interface/models/IEngagementBankTransaction.d.ts.map +1 -1
  54. package/es/types/Interface/models/IEngagementBankTransaction.js.map +1 -1
  55. package/es/types/Interface/models/IPartnerTransaction.d.ts +3 -3
  56. package/es/types/Interface/models/IPartnerTransaction.d.ts.map +1 -1
  57. package/es/types/Interface/models/IPartnerTransaction.js.map +1 -1
  58. package/es/types/index.d.ts +6 -0
  59. package/es/types/index.d.ts.map +1 -1
  60. package/es/types/index.js +6 -0
  61. package/es/types/index.js.map +1 -1
  62. package/es/utils/index.d.ts +1 -0
  63. package/es/utils/index.d.ts.map +1 -1
  64. package/es/utils/index.js +1 -0
  65. package/es/utils/index.js.map +1 -1
  66. package/es/utils/stringUtils/clean.d.ts +3 -0
  67. package/es/utils/stringUtils/clean.d.ts.map +1 -0
  68. package/es/utils/stringUtils/clean.js +12 -0
  69. package/es/utils/stringUtils/clean.js.map +1 -0
  70. package/es/utils/stringUtils/index.d.ts +2 -0
  71. package/es/utils/stringUtils/index.d.ts.map +1 -0
  72. package/es/utils/stringUtils/index.js +2 -0
  73. package/es/utils/stringUtils/index.js.map +1 -0
  74. package/js/api/resources/Transaction.js +6 -0
  75. package/js/api/resources/Transaction.js.map +1 -1
  76. package/js/types/Enum/ComptaType.js +1 -1
  77. package/js/types/Enum/ComptaType.js.map +1 -1
  78. package/js/types/Enum/PartnerTransactionType.js +14 -0
  79. package/js/types/Enum/{TypePartnerTransaction.js.map → PartnerTransactionType.js.map} +1 -1
  80. package/js/types/Interface/api/account/CreateAccountSociety.js +33 -0
  81. package/js/types/Interface/api/account/CreateAccountSociety.js.map +1 -0
  82. package/js/types/Interface/api/account/QueryAccountSociety.js +35 -0
  83. package/js/types/Interface/api/account/QueryAccountSociety.js.map +1 -0
  84. package/js/types/Interface/api/account/QueryGenericAccount.js +31 -0
  85. package/js/types/Interface/api/account/QueryGenericAccount.js.map +1 -0
  86. package/js/types/Interface/api/account/UpdateAccountSociety.js +33 -0
  87. package/js/types/Interface/api/account/UpdateAccountSociety.js.map +1 -0
  88. package/js/types/Interface/api/bankAccount/DeleteTransaction.js +37 -0
  89. package/js/types/Interface/api/bankAccount/DeleteTransaction.js.map +1 -0
  90. package/js/types/Interface/api/shine/CreateShine.js +6 -0
  91. package/js/types/Interface/api/shine/CreateShine.js.map +1 -0
  92. package/js/types/Interface/models/IApiError.js +31 -1
  93. package/js/types/Interface/models/IApiError.js.map +1 -1
  94. package/js/types/index.js +72 -0
  95. package/js/types/index.js.map +1 -1
  96. package/js/utils/index.js +12 -0
  97. package/js/utils/index.js.map +1 -1
  98. package/js/utils/stringUtils/clean.js +15 -0
  99. package/js/utils/stringUtils/clean.js.map +1 -0
  100. package/js/utils/stringUtils/index.js +18 -0
  101. package/js/utils/stringUtils/index.js.map +1 -0
  102. package/package.json +1 -1
  103. package/ts/api/resources/Transaction.ts +4 -1
  104. package/ts/types/Enum/ComptaType.ts +1 -1
  105. package/ts/types/Enum/{TypePartnerTransaction.ts → PartnerTransactionType.ts} +1 -1
  106. package/ts/types/Interface/api/account/CreateAccountSociety.ts +15 -0
  107. package/ts/types/Interface/api/account/QueryAccountSociety.ts +18 -0
  108. package/ts/types/Interface/api/account/QueryGenericAccount.ts +12 -0
  109. package/ts/types/Interface/api/account/UpdateAccountSociety.ts +18 -0
  110. package/ts/types/Interface/api/bankAccount/DeleteTransaction.ts +21 -0
  111. package/ts/types/Interface/api/shine/CreateShine.ts +84 -0
  112. package/ts/types/Interface/api/society/LegalFormSiren.ts +2 -0
  113. package/ts/types/Interface/models/IAccountingTransaction.ts +1 -1
  114. package/ts/types/Interface/models/IApiError.ts +31 -0
  115. package/ts/types/Interface/models/IBankConnection.ts +4 -1
  116. package/ts/types/Interface/models/IBankTransaction.ts +1 -1
  117. package/ts/types/Interface/models/IEngagementBankTransaction.ts +1 -1
  118. package/ts/types/Interface/models/IPartnerTransaction.ts +3 -3
  119. package/ts/types/index.ts +6 -0
  120. package/ts/utils/index.ts +1 -0
  121. package/ts/utils/stringUtils/clean.ts +12 -0
  122. package/ts/utils/stringUtils/index.ts +1 -0
  123. package/es/types/Enum/TypePartnerTransaction.d.ts +0 -7
  124. package/es/types/Enum/TypePartnerTransaction.d.ts.map +0 -1
  125. package/es/types/Enum/TypePartnerTransaction.js +0 -8
  126. package/es/types/Enum/TypePartnerTransaction.js.map +0 -1
  127. package/js/types/Enum/TypePartnerTransaction.js +0 -14
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ var _clean = require("./clean");
8
+
9
+ Object.keys(_clean).forEach(function (key) {
10
+ if (key === "default" || key === "__esModule") return;
11
+ Object.defineProperty(exports, key, {
12
+ enumerable: true,
13
+ get: function () {
14
+ return _clean[key];
15
+ }
16
+ });
17
+ });
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../ts/utils/stringUtils/index.ts"],"names":[],"mappings":";;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA","sourcesContent":["export * from './clean';\n"],"sourceRoot":"","file":"index.js"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@silexpert/core",
3
- "version": "0.4.18",
3
+ "version": "0.4.20",
4
4
  "description": "Silex Core perform HTTP Request and object binding. Silex core helps developers to retrieve and return formatted object",
5
5
  "homepage": "https://gitlab.compta-clementine.fr/dev/silex-api",
6
6
  "main": "js/index.js",
@@ -2,7 +2,7 @@ import { Resource } from '../Resource';
2
2
  import {
3
3
  AccountingJournal,
4
4
  BasePaginate,
5
- QueryPaginate, ReadFormattedAccountingTransaction, UpdateAccountingTransaction,
5
+ QueryPaginate, ReadFormattedAccountingTransaction, UpdateAccountingTransaction, DeleteTransactions,
6
6
  } from '../../types';
7
7
 
8
8
  export class Transaction extends Resource {
@@ -21,4 +21,7 @@ export class Transaction extends Resource {
21
21
  annotate(id: number, data: UpdateAccountingTransaction): Promise<ReadFormattedAccountingTransaction | Error> {
22
22
  return this.axios.$put(`/transactions/${id}`, data);
23
23
  }
24
+ deleteTransactions(id: number, data: DeleteTransactions): Promise<number | Error> {
25
+ return this.axios.$delete(`/bankAccount/${id}/transactions`, { params: data });
26
+ }
24
27
  }
@@ -4,5 +4,5 @@ export enum ComptaType {
4
4
  CASH_BASED_SEIZURE = 3,
5
5
  ACCRUALS_SEIZURE = 4,
6
6
  CASH_BASED_ASSISTANCE = 5,
7
- CASH_BASED_ACCRUALS = 6,
7
+ ACCRUALS_ASSISTANCE = 6,
8
8
  }
@@ -1,4 +1,4 @@
1
- export enum TypePartnerTransaction {
1
+ export enum PartnerTransactionType {
2
2
  OTHER = 1,
3
3
  BUDGET_INSIGHT = 2,
4
4
  QONTO = 3,
@@ -0,0 +1,15 @@
1
+ import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
2
+
3
+ export class CreateAccountSociety {
4
+ @ApiProperty()
5
+ number: number;
6
+
7
+ @ApiProperty()
8
+ name: string;
9
+
10
+ @ApiProperty()
11
+ idParentAccount: number;
12
+
13
+ @ApiPropertyOptional()
14
+ idVat?: number;
15
+ }
@@ -0,0 +1,18 @@
1
+ import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
2
+
3
+ export class QueryAccountSociety {
4
+ @ApiProperty()
5
+ page: number;
6
+
7
+ @ApiProperty()
8
+ limit: number;
9
+
10
+ @ApiProperty()
11
+ descending: boolean;
12
+
13
+ @ApiPropertyOptional()
14
+ accountClass?: number;
15
+
16
+ @ApiPropertyOptional()
17
+ search?: string;
18
+ }
@@ -0,0 +1,12 @@
1
+ import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
2
+
3
+ export class QueryGenericAccount {
4
+ @ApiProperty()
5
+ page: number;
6
+
7
+ @ApiProperty()
8
+ limit: number;
9
+
10
+ @ApiPropertyOptional()
11
+ accountClass?: number;
12
+ }
@@ -0,0 +1,18 @@
1
+ import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
2
+
3
+ export class UpdateAccountSociety {
4
+ @ApiProperty()
5
+ id: number;
6
+
7
+ @ApiPropertyOptional()
8
+ number?: number;
9
+
10
+ @ApiPropertyOptional()
11
+ name?: string;
12
+
13
+ // @ApiPropertyOptional() // value toujours à false lorsque ce décorateur est actif
14
+ isHidden?: boolean;
15
+
16
+ @ApiPropertyOptional()
17
+ idVat?: number | null;
18
+ }
@@ -0,0 +1,21 @@
1
+ import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
2
+
3
+ export class DeleteTransactions {
4
+ @ApiProperty()
5
+ idBankAccount: number;
6
+
7
+ @ApiPropertyOptional()
8
+ isLocked?: boolean;
9
+
10
+ @ApiPropertyOptional()
11
+ isExported?: boolean;
12
+
13
+ @ApiPropertyOptional()
14
+ isFromCsv?: boolean;
15
+
16
+ @ApiPropertyOptional()
17
+ startDate?: string;
18
+
19
+ @ApiPropertyOptional()
20
+ endDate?: string;
21
+ }
@@ -0,0 +1,84 @@
1
+ import { Code } from '../../models/IApiError';
2
+
3
+ export type ShineErrorResponse = {
4
+ code: Code;
5
+ message: string;
6
+ status: number;
7
+ };
8
+
9
+ export type ShineSuccessResponse = {
10
+ access_token: string;
11
+ expires_in: number;
12
+ id_token?: string;
13
+ refresh_token: string;
14
+ scope: string;
15
+ token_type: string;
16
+ };
17
+
18
+ export type ShineTokenInformations = {
19
+ exp: number;
20
+ };
21
+
22
+ export type ShineBankAccount = {
23
+ bankAccountId: string;
24
+ currentBalance:number;
25
+ currentBalanceFloat:number;
26
+ nextBalance:number;
27
+ nextBalanceFloat:number;
28
+ currency:string;
29
+ iban:string;
30
+ bic:string;
31
+ name:string;
32
+ ownerName:string;
33
+ trzWalletId:string;
34
+ type:string;
35
+ createdAt:number;
36
+ status:string;
37
+ uid:string;
38
+ companyProfileId:string;
39
+ updatedAt:number;
40
+ };
41
+
42
+ export type ShineBankTransaction = {
43
+ transactionId: string;
44
+ createdAt: number;
45
+ currency: string;
46
+ paymentMethod: string;
47
+ paymentProvider: string;
48
+ providerTransactionId: string;
49
+ status: string;
50
+ title: string;
51
+ titleLatinised: string;
52
+ type: 'payout' | 'payin';
53
+ uid: string;
54
+ updatedAt: number;
55
+ value: number;
56
+ bankTransferId: string;
57
+ transactionAt: number;
58
+ fee: number;
59
+ transferPayinSenderName: string;
60
+ feeType: string;
61
+ description: string;
62
+ category: string;
63
+ isRefund: false;
64
+ directDebitMandateId: string;
65
+ bankAccountId: string;
66
+ transactionSettledAt: number;
67
+ providerCardPaymentId: null;
68
+ providerCardTransactionId: null;
69
+ cardPaymentStatus: null;
70
+ isPersonal: false;
71
+ hasReceipts: false;
72
+ note: string;
73
+ isHidden: false;
74
+ authorizationReleasedAt: null;
75
+ refundTransactionId: null;
76
+ executedAt: null;
77
+ companyUserId: null;
78
+ initiatorName: null;
79
+ remainingAuthorized: null;
80
+ expectedReleaseDate: null;
81
+ cardPaymentMethod: null;
82
+ paymentCurrency: string;
83
+ is3DS: false
84
+ };
@@ -2,4 +2,6 @@ export type LegalFormSiren = {
2
2
  l1_normalisee: string;
3
3
  l4_declaree: string;
4
4
  l6_declaree: string;
5
+ libcom: string;
6
+ codpos: string;
5
7
  };
@@ -17,7 +17,7 @@ export interface IAccountingTransaction {
17
17
  id?: number;
18
18
  label: string | null;
19
19
  invoiceNumber: string | null;
20
- budgeaTransactionId: string | null;
20
+ reference: string | null;
21
21
  dateValue: Date;
22
22
  dateLocked?: Date | null;
23
23
  dateVerified?: Date | null;
@@ -55,6 +55,37 @@ export enum Code {
55
55
  // Income statement
56
56
  invalidIncomeStatementList = 'invalid_income_statement_list',
57
57
 
58
+ // Shine errors
59
+ AUTHORIZATION_CLIENT_NOT_FOUND = 'AUTHORIZATION_CLIENT_NOT_FOUND',
60
+ AUTHORIZATION_CLIENT_SECRET_DOES_NOT_MATCH = 'AUTHORIZATION_CLIENT_SECRET_DOES_NOT_MATCH',
61
+ AUTHORIZATION_REDIRECT_URI_DOES_NOT_MATCH = 'AUTHORIZATION_REDIRECT_URI_DOES_NOT_MATCH',
62
+ AUTHORIZATION_REQUESTED_SCOPE_NOT_AVAILABLE = 'AUTHORIZATION_REQUESTED_SCOPE_NOT_AVAILABLE',
63
+ AUTHORIZATION_REQUESTED_SCOPE_NOT_AUTHORIZED = 'AUTHORIZATION_REQUESTED_SCOPE_NOT_AUTHORIZED',
64
+ AUTHORIZATION_REQUESTED_SCOPE_MISSING_OPENID = 'AUTHORIZATION_REQUESTED_SCOPE_MISSING_OPENID',
65
+ AUTHORIZATION_CLIENT_STATUS_NOT_VALID = 'AUTHORIZATION_CLIENT_STATUS_NOT_VALID',
66
+ AUTHORIZATION_CODE_MISSING = 'AUTHORIZATION_CODE_MISSING',
67
+ AUTHORIZATION_CODE_NOT_FOUND = 'AUTHORIZATION_CODE_NOT_FOUND',
68
+ AUTHORIZATION_CODE_ALREADY_USED = 'AUTHORIZATION_CODE_ALREADY_USED',
69
+ AUTHORIZATION_CODE_EXPIRED = 'AUTHORIZATION_CODE_EXPIRED',
70
+ AUTHORIZATION_CODE_REDIRECT_URI_DOES_NOT_MATCH = 'AUTHORIZATION_CODE_REDIRECT_URI_DOES_NOT_MATCH',
71
+ AUTHORIZATION_ACCESS_TOKEN_EXPIRED = 'AUTHORIZATION_ACCESS_TOKEN_EXPIRED',
72
+ AUTHORIZATION_INVALID_ACCESS_TOKEN = 'AUTHORIZATION_INVALID_ACCESS_TOKEN',
73
+ AUTHORIZATION_MISSING_ACCESS_TOKEN = 'AUTHORIZATION_MISSING_ACCESS_TOKEN',
74
+ AUTHORIZATION_ACCESS_TOKEN_WRONG_AUDIENCE = 'AUTHORIZATION_ACCESS_TOKEN_WRONG_AUDIENCE',
75
+ AUTHORIZATION_ACCESS_TOKEN_MISSING_SCOPE = 'AUTHORIZATION_ACCESS_TOKEN_MISSING_SCOPE',
76
+ AUTHORIZATION_ACCESS_TOKEN_FORBIDDEN = 'AUTHORIZATION_ACCESS_TOKEN_FORBIDDEN',
77
+ AUTHORIZATION_UNSUPPORTED_RESPONSE_TYPE = 'AUTHORIZATION_UNSUPPORTED_RESPONSE_TYPE',
78
+ AUTHORIZATION_UNSUPPORTED_GRANT_TYPE = 'AUTHORIZATION_UNSUPPORTED_GRANT_TYPE',
79
+ AUTHORIZATION_REFRESH_TOKEN_MISSING = 'AUTHORIZATION_REFRESH_TOKEN_MISSING',
80
+ AUTHORIZATION_REFRESH_TOKEN_EXPIRED = 'AUTHORIZATION_REFRESH_TOKEN_EXPIRED',
81
+ AUTHORIZATION_REFRESH_TOKEN_INVALID = 'AUTHORIZATION_REFRESH_TOKEN_INVALID',
82
+ AUTHORIZATION_REFRESH_TOKEN_REDIRECT_URI_DOES_NOT_MATCH = 'AUTHORIZATION_REFRESH_TOKEN_REDIRECT_URI_DOES_NOT_MATCH',
83
+ AUTHORIZATION_REFRESH_TOKEN_REVOKED = 'AUTHORIZATION_REFRESH_TOKEN_REVOKED',
84
+ AUTHORIZATION_USER_NOT_AUTHORIZED = 'AUTHORIZATION_USER_NOT_AUTHORIZED',
85
+ responseNotManaged = 'response_not_managed',
86
+ bankAccountsError = 'bank_accounts_error',
87
+ refreshTokenError = 'refresh_token_error',
88
+
58
89
  // Balance Sheet
59
90
  invalidBalanceSheetList = 'invalid_balance_sheet_list',
60
91
 
@@ -5,11 +5,14 @@ export interface IBankConnection {
5
5
  id?: number;
6
6
  login: string | null;
7
7
  password: string | null;
8
+ token: string | null;
9
+ refreshToken: string | null;
10
+ expireAt: Date | null;
8
11
  idBankList: number | null;
9
12
  idSociety: number;
10
13
  createdAt?: Date | null;
11
14
  updatedAt?: Date | null;
12
15
 
13
16
  // Associations
14
- bankList: IBankList;
17
+ bankList?: IBankList;
15
18
  }
@@ -6,7 +6,7 @@ import { IUser } from './IUser';
6
6
  // bankTransactions
7
7
  export interface IBankTransaction {
8
8
  id?: number;
9
- budgeaTransactionId: string | null;
9
+ reference: string | null;
10
10
  dateValue: Date;
11
11
  dateLocked: Date | null;
12
12
  checkDateLocked: boolean | null;
@@ -9,7 +9,7 @@ import { IPartnerTransaction } from './IPartnerTransaction';
9
9
  export interface IEngagementBankTransaction {
10
10
  id?: number;
11
11
  migrate: boolean;
12
- budgeaTransactionId: string | null;
12
+ reference: string | null;
13
13
  dateValue: Date;
14
14
  dateLocked: Date | null;
15
15
  dateVerified: Date | null;
@@ -1,4 +1,4 @@
1
- import { TypePartnerTransaction } from '../../Enum/TypePartnerTransaction';
1
+ import { PartnerTransactionType } from '../../Enum/PartnerTransactionType';
2
2
  import { IPartnerTransactionType } from './IPartnerTransactionType';
3
3
 
4
4
  // partnersTransactions
@@ -6,12 +6,12 @@ export interface IPartnerTransaction {
6
6
  id?: number;
7
7
  tokenString: string | null;
8
8
  tokenInteger: number | null;
9
- idTypePartnerTransaction: TypePartnerTransaction;
9
+ idTypePartnerTransaction: PartnerTransactionType;
10
10
  idAccountingTransaction: number | null;
11
11
  createdAt?: Date | null;
12
12
  updatedAt?: Date | null;
13
13
  idEngagementBankTransaction: number | null;
14
14
 
15
15
  // Associations
16
- typePartnerTransaction: IPartnerTransactionType;
16
+ typePartnerTransaction?: IPartnerTransactionType;
17
17
  }
package/ts/types/index.ts CHANGED
@@ -304,6 +304,7 @@ export * from './Enum/PartnerType';
304
304
  export * from './Enum/ThirdPartyType';
305
305
  export * from './Enum/FecFileDelimiter';
306
306
  export * from './Enum/IncomeStatement';
307
+ export * from './Enum/PartnerTransactionType';
307
308
  export * from './Enum/Vehicle';
308
309
  export * from './Enum/VehicleType';
309
310
  export * from './Enum/BalanceSheet';
@@ -322,6 +323,10 @@ export * from './Interface/api/paymentExpectationCustomer/UpdatePaymentExpectati
322
323
  export * from './Interface/api/paymentExpectationCustomer/CreatePaymentExpectationCustomer';
323
324
  export * from './Interface/api/accountType/ReadAccountType';
324
325
  export * from './Interface/api/account/QueryAccounts';
326
+ export * from './Interface/api/account/CreateAccountSociety';
327
+ export * from './Interface/api/account/UpdateAccountSociety';
328
+ export * from './Interface/api/account/QueryAccountSociety';
329
+ export * from './Interface/api/account/QueryGenericAccount';
325
330
  export * from './Interface/api/accountingTransaction/QueryTransaction';
326
331
  export * from './Interface/api/user/QueryConfirm';
327
332
  export * from './Interface/api/user/QueryResendConfirmationLink';
@@ -359,3 +364,4 @@ export * from './Interface/api/balanceSheet/ReadBalanceSheet';
359
364
  export * from './Interface/api/pappers/QueryPappers';
360
365
  export * from './Interface/api/pappers/ReadPappers';
361
366
  export * from './Interface/api/pappers/CreatePappers';
367
+ export * from './Interface/api/bankAccount/DeleteTransaction';
package/ts/utils/index.ts CHANGED
@@ -1,2 +1,3 @@
1
1
  export * from './objectUtils';
2
+ export * from './stringUtils';
2
3
  export * from './decorators';
@@ -0,0 +1,12 @@
1
+ const wordsToExclude = ['cheque', 'prelevement', 'cheques', 'prelevements', 'prlvt', 'prlv', 'valeur', 'euro', 'solde', 'dont'];
2
+ export const minWordsForDesignation = 3;
3
+
4
+ export function cleanForRules(string: string) : string {
5
+ return string
6
+ .toLowerCase()
7
+ .replace(/[^a-z0-9 ]/gi, '') // Conservation des espaces & caractères alphanumérique
8
+ .split(' ')
9
+ .filter((str) => str.length >= minWordsForDesignation && !wordsToExclude.includes(str)) // Suppression des mots à exclure et désignation inférieur à 3 char
10
+ .join(' ')
11
+ .replace(/[^a-z]/gi, ''); // Conservation des caractères alphanumérique
12
+ }
@@ -0,0 +1 @@
1
+ export * from './clean';
@@ -1,7 +0,0 @@
1
- export declare enum TypePartnerTransaction {
2
- OTHER = 1,
3
- BUDGET_INSIGHT = 2,
4
- QONTO = 3,
5
- SHINE = 4
6
- }
7
- //# sourceMappingURL=TypePartnerTransaction.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TypePartnerTransaction.d.ts","sourceRoot":"","sources":["../../../ts/types/Enum/TypePartnerTransaction.ts"],"names":[],"mappings":"AAAA,oBAAY,sBAAsB;IAChC,KAAK,IAAI;IACT,cAAc,IAAI;IAClB,KAAK,IAAI;IACT,KAAK,IAAI;CACV"}
@@ -1,8 +0,0 @@
1
- export var TypePartnerTransaction;
2
- (function (TypePartnerTransaction) {
3
- TypePartnerTransaction[TypePartnerTransaction["OTHER"] = 1] = "OTHER";
4
- TypePartnerTransaction[TypePartnerTransaction["BUDGET_INSIGHT"] = 2] = "BUDGET_INSIGHT";
5
- TypePartnerTransaction[TypePartnerTransaction["QONTO"] = 3] = "QONTO";
6
- TypePartnerTransaction[TypePartnerTransaction["SHINE"] = 4] = "SHINE";
7
- })(TypePartnerTransaction || (TypePartnerTransaction = {}));
8
- //# sourceMappingURL=TypePartnerTransaction.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TypePartnerTransaction.js","sourceRoot":"","sources":["../../../ts/types/Enum/TypePartnerTransaction.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,sBAKX;AALD,WAAY,sBAAsB;IAChC,qEAAS,CAAA;IACT,uFAAkB,CAAA;IAClB,qEAAS,CAAA;IACT,qEAAS,CAAA;AACX,CAAC,EALW,sBAAsB,KAAtB,sBAAsB,QAKjC","sourcesContent":["export enum TypePartnerTransaction {\n OTHER = 1,\n BUDGET_INSIGHT = 2,\n QONTO = 3,\n SHINE = 4,\n}"]}
@@ -1,14 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var TypePartnerTransaction = exports.TypePartnerTransaction = undefined;
7
-
8
- (function (TypePartnerTransaction) {
9
- TypePartnerTransaction[TypePartnerTransaction["OTHER"] = 1] = "OTHER";
10
- TypePartnerTransaction[TypePartnerTransaction["BUDGET_INSIGHT"] = 2] = "BUDGET_INSIGHT";
11
- TypePartnerTransaction[TypePartnerTransaction["QONTO"] = 3] = "QONTO";
12
- TypePartnerTransaction[TypePartnerTransaction["SHINE"] = 4] = "SHINE";
13
- })(TypePartnerTransaction || (exports.TypePartnerTransaction = TypePartnerTransaction = {}));
14
- //# sourceMappingURL=TypePartnerTransaction.js.map