@silexpert/core 1.3.66-6 → 1.3.67-0

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 (130) hide show
  1. package/dist/cjs/api/resources/Refund.d.ts +1 -9
  2. package/dist/cjs/api/resources/Refund.d.ts.map +1 -1
  3. package/dist/cjs/api/resources/Society.d.ts +1 -3
  4. package/dist/cjs/api/resources/Society.d.ts.map +1 -1
  5. package/dist/cjs/api/resources/Society.js +0 -6
  6. package/dist/cjs/api/resources/Society.js.map +1 -1
  7. package/dist/cjs/types/Enum/FollowList.d.ts +0 -6
  8. package/dist/cjs/types/Enum/FollowList.d.ts.map +1 -1
  9. package/dist/cjs/types/Enum/FollowList.js +0 -6
  10. package/dist/cjs/types/Enum/FollowList.js.map +1 -1
  11. package/dist/cjs/types/Enum/PaymentMethod.d.ts +10 -29
  12. package/dist/cjs/types/Enum/PaymentMethod.d.ts.map +1 -1
  13. package/dist/cjs/types/Enum/PaymentMethod.js +11 -31
  14. package/dist/cjs/types/Enum/PaymentMethod.js.map +1 -1
  15. package/dist/cjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.d.ts +1 -2
  16. package/dist/cjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.d.ts.map +1 -1
  17. package/dist/cjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.js +0 -6
  18. package/dist/cjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.js.map +1 -1
  19. package/dist/cjs/types/Interface/api/refund/QueryRefundPaginated.d.ts.map +1 -1
  20. package/dist/cjs/types/Interface/api/refund/QueryRefundPaginated.js +4 -3
  21. package/dist/cjs/types/Interface/api/refund/QueryRefundPaginated.js.map +1 -1
  22. package/dist/cjs/types/Interface/api/stripe/Create.d.ts +0 -3
  23. package/dist/cjs/types/Interface/api/stripe/Create.d.ts.map +1 -1
  24. package/dist/cjs/types/Interface/api/stripe/Create.js +1 -10
  25. package/dist/cjs/types/Interface/api/stripe/Create.js.map +1 -1
  26. package/dist/cjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.d.ts +1 -0
  27. package/dist/cjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.d.ts.map +1 -1
  28. package/dist/cjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.js +6 -0
  29. package/dist/cjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.js.map +1 -1
  30. package/dist/cjs/types/Interface/models/IAppNotification.d.ts +3 -3
  31. package/dist/cjs/types/Interface/models/IAppNotification.d.ts.map +1 -1
  32. package/dist/cjs/types/Interface/models/IAppNotification.js.map +1 -1
  33. package/dist/cjs/types/Interface/models/IMobileNotificationLog.d.ts +2 -4
  34. package/dist/cjs/types/Interface/models/IMobileNotificationLog.d.ts.map +1 -1
  35. package/dist/cjs/types/Interface/models/IMobileNotificationLog.js.map +1 -1
  36. package/dist/cjs/types/Interface/models/IPayment.d.ts +0 -2
  37. package/dist/cjs/types/Interface/models/IPayment.d.ts.map +1 -1
  38. package/dist/cjs/types/Interface/models/IPayment.js.map +1 -1
  39. package/dist/cjs/types/Interface/models/IRefund.d.ts +1 -9
  40. package/dist/cjs/types/Interface/models/IRefund.d.ts.map +1 -1
  41. package/dist/cjs/types/Interface/models/IRefund.js.map +1 -1
  42. package/dist/cjs/types/index.d.ts +0 -2
  43. package/dist/cjs/types/index.d.ts.map +1 -1
  44. package/dist/cjs/types/index.js +0 -2
  45. package/dist/cjs/types/index.js.map +1 -1
  46. package/dist/cjs/utils/subscription.d.ts +21 -0
  47. package/dist/cjs/utils/subscription.d.ts.map +1 -0
  48. package/dist/cjs/utils/subscription.js +97 -0
  49. package/dist/cjs/utils/subscription.js.map +1 -0
  50. package/dist/mjs/api/resources/Refund.d.ts +1 -9
  51. package/dist/mjs/api/resources/Refund.d.ts.map +1 -1
  52. package/dist/mjs/api/resources/Society.d.ts +1 -3
  53. package/dist/mjs/api/resources/Society.d.ts.map +1 -1
  54. package/dist/mjs/api/resources/Society.js +0 -6
  55. package/dist/mjs/api/resources/Society.js.map +1 -1
  56. package/dist/mjs/types/Enum/FollowList.d.ts +0 -6
  57. package/dist/mjs/types/Enum/FollowList.d.ts.map +1 -1
  58. package/dist/mjs/types/Enum/FollowList.js +0 -6
  59. package/dist/mjs/types/Enum/FollowList.js.map +1 -1
  60. package/dist/mjs/types/Enum/PaymentMethod.d.ts +10 -29
  61. package/dist/mjs/types/Enum/PaymentMethod.d.ts.map +1 -1
  62. package/dist/mjs/types/Enum/PaymentMethod.js +10 -30
  63. package/dist/mjs/types/Enum/PaymentMethod.js.map +1 -1
  64. package/dist/mjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.d.ts +1 -2
  65. package/dist/mjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.d.ts.map +1 -1
  66. package/dist/mjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.js +1 -8
  67. package/dist/mjs/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.js.map +1 -1
  68. package/dist/mjs/types/Interface/api/refund/QueryRefundPaginated.d.ts.map +1 -1
  69. package/dist/mjs/types/Interface/api/refund/QueryRefundPaginated.js +5 -4
  70. package/dist/mjs/types/Interface/api/refund/QueryRefundPaginated.js.map +1 -1
  71. package/dist/mjs/types/Interface/api/stripe/Create.d.ts +0 -3
  72. package/dist/mjs/types/Interface/api/stripe/Create.d.ts.map +1 -1
  73. package/dist/mjs/types/Interface/api/stripe/Create.js +0 -9
  74. package/dist/mjs/types/Interface/api/stripe/Create.js.map +1 -1
  75. package/dist/mjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.d.ts +1 -0
  76. package/dist/mjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.d.ts.map +1 -1
  77. package/dist/mjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.js +7 -0
  78. package/dist/mjs/types/Interface/api/webmail/GetPaginatedWhereObjectParams.js.map +1 -1
  79. package/dist/mjs/types/Interface/models/IAppNotification.d.ts +3 -3
  80. package/dist/mjs/types/Interface/models/IAppNotification.d.ts.map +1 -1
  81. package/dist/mjs/types/Interface/models/IAppNotification.js.map +1 -1
  82. package/dist/mjs/types/Interface/models/IMobileNotificationLog.d.ts +2 -4
  83. package/dist/mjs/types/Interface/models/IMobileNotificationLog.d.ts.map +1 -1
  84. package/dist/mjs/types/Interface/models/IMobileNotificationLog.js.map +1 -1
  85. package/dist/mjs/types/Interface/models/IPayment.d.ts +0 -2
  86. package/dist/mjs/types/Interface/models/IPayment.d.ts.map +1 -1
  87. package/dist/mjs/types/Interface/models/IPayment.js.map +1 -1
  88. package/dist/mjs/types/Interface/models/IRefund.d.ts +1 -9
  89. package/dist/mjs/types/Interface/models/IRefund.d.ts.map +1 -1
  90. package/dist/mjs/types/Interface/models/IRefund.js.map +1 -1
  91. package/dist/mjs/types/index.d.ts +0 -2
  92. package/dist/mjs/types/index.d.ts.map +1 -1
  93. package/dist/mjs/types/index.js +0 -2
  94. package/dist/mjs/types/index.js.map +1 -1
  95. package/dist/mjs/utils/subscription.d.ts +21 -0
  96. package/dist/mjs/utils/subscription.d.ts.map +1 -0
  97. package/dist/mjs/utils/subscription.js +92 -0
  98. package/dist/mjs/utils/subscription.js.map +1 -0
  99. package/package.json +1 -1
  100. package/ts/api/resources/Society.ts +0 -11
  101. package/ts/types/Enum/FollowList.ts +0 -6
  102. package/ts/types/Enum/PaymentMethod.ts +10 -30
  103. package/ts/types/Interface/api/internalInvoicing/RegenerateInternalInvoicing.ts +2 -7
  104. package/ts/types/Interface/api/refund/QueryRefundPaginated.ts +5 -4
  105. package/ts/types/Interface/api/stripe/Create.ts +0 -7
  106. package/ts/types/Interface/api/webmail/GetPaginatedWhereObjectParams.ts +5 -0
  107. package/ts/types/Interface/models/IAppNotification.ts +3 -3
  108. package/ts/types/Interface/models/IMobileNotificationLog.ts +2 -4
  109. package/ts/types/Interface/models/IPayment.ts +1 -3
  110. package/ts/types/Interface/models/IRefund.ts +1 -13
  111. package/ts/types/index.ts +0 -2
  112. package/ts/utils/subscription.ts +124 -0
  113. package/dist/cjs/types/Enum/PaymentAttempt.d.ts +0 -6
  114. package/dist/cjs/types/Enum/PaymentAttempt.d.ts.map +0 -1
  115. package/dist/cjs/types/Enum/PaymentAttempt.js +0 -10
  116. package/dist/cjs/types/Enum/PaymentAttempt.js.map +0 -1
  117. package/dist/cjs/types/Interface/models/IPaymentAttempt.d.ts +0 -15
  118. package/dist/cjs/types/Interface/models/IPaymentAttempt.d.ts.map +0 -1
  119. package/dist/cjs/types/Interface/models/IPaymentAttempt.js +0 -3
  120. package/dist/cjs/types/Interface/models/IPaymentAttempt.js.map +0 -1
  121. package/dist/mjs/types/Enum/PaymentAttempt.d.ts +0 -6
  122. package/dist/mjs/types/Enum/PaymentAttempt.d.ts.map +0 -1
  123. package/dist/mjs/types/Enum/PaymentAttempt.js +0 -7
  124. package/dist/mjs/types/Enum/PaymentAttempt.js.map +0 -1
  125. package/dist/mjs/types/Interface/models/IPaymentAttempt.d.ts +0 -15
  126. package/dist/mjs/types/Interface/models/IPaymentAttempt.d.ts.map +0 -1
  127. package/dist/mjs/types/Interface/models/IPaymentAttempt.js +0 -2
  128. package/dist/mjs/types/Interface/models/IPaymentAttempt.js.map +0 -1
  129. package/ts/types/Enum/PaymentAttempt.ts +0 -5
  130. package/ts/types/Interface/models/IPaymentAttempt.ts +0 -16
@@ -0,0 +1,92 @@
1
+ import { ComptaType } from '../types/Enum/ComptaType';
2
+ import { LegalFormTypeEnum } from '../types/Enum/LegalForm';
3
+ import { TaxSystem } from '../types/Enum/TaxSystem';
4
+ const isTestKey = ['dev', 'staging', 'development', 'test', 'gitlab'].includes(process.env.NODE_ENV ?? '');
5
+ // AE | Annuel | Forfait Bilan complet
6
+ const ID_SUBSCRIPTION_MICRO_ANNUAL = !isTestKey ? 'price_1PFyHHIHo1jEedppVjwrqPr1' : 'price_1MRyi1IHo1jEedppRKdY06Re';
7
+ // AE | Mensuel | Forfait Bilan complet
8
+ const ID_SUBSCRIPTION_MICRO_MENSUAL = !isTestKey ? 'price_1LBJ4xIHo1jEedppylxr3fFa' : 'price_1LBI57IHo1jEedpppnxskfgv';
9
+ // Entreprise | Annuel | Forfait entreprise à l'IR
10
+ const ID_SUBSCRIPTION_INCOME_TAX_ANNUAL = !isTestKey
11
+ ? 'price_1PFyG8IHo1jEedpp73TUxiJd'
12
+ : 'price_1MRyiJIHo1jEedppUe7MnPtW';
13
+ // Entreprise | Mensuel | Forfaitentreprise à l'IR
14
+ const ID_SUBSCRIPTION_INCOME_TAX_MENSUAL = !isTestKey
15
+ ? 'price_1LBJ5YIHo1jEedppzwTErh9M'
16
+ : 'price_1LBIA3IHo1jEedpp2taeQ7yW';
17
+ // Entreprise | Annuel | Forfait entreprise à l'IS
18
+ const ID_SUBSCRIPTION_SOCIETY_TAX_ANNUAL = !isTestKey
19
+ ? 'price_1PFwE3IHo1jEedpphgWrgwkA'
20
+ : 'price_1MRyiWIHo1jEedppp5tnksZe';
21
+ // Entreprise | Mensuel | Forfait entreprise à l'IS
22
+ const ID_SUBSCRIPTION_SOCIETY_TAX_MENSUAL = !isTestKey
23
+ ? 'price_1LBJ69IHo1jEedppAWLeOk3I'
24
+ : 'price_1LBIB7IHo1jEedppocxyc1ft';
25
+ export const stripeTaxRate = isTestKey ? 'txr_1I9X9MIHo1jEedppM0DqL4iE' : 'txr_1I9X5wIHo1jEedppYttGFc0N';
26
+ const list = [
27
+ {
28
+ name: 'Offre auto-entrepreneur',
29
+ isYearly: true,
30
+ isMicro: true,
31
+ key: ID_SUBSCRIPTION_MICRO_ANNUAL,
32
+ isCashBased: true,
33
+ isSocietyTax: false,
34
+ },
35
+ {
36
+ name: 'Offre auto-entrepreneur',
37
+ isYearly: false,
38
+ isMicro: true,
39
+ key: ID_SUBSCRIPTION_MICRO_MENSUAL,
40
+ isCashBased: true,
41
+ isSocietyTax: false,
42
+ },
43
+ {
44
+ name: 'Offre entreprise IS',
45
+ isYearly: true,
46
+ isMicro: false,
47
+ key: ID_SUBSCRIPTION_SOCIETY_TAX_ANNUAL,
48
+ isCashBased: false,
49
+ isSocietyTax: true,
50
+ },
51
+ {
52
+ name: 'Offre entreprise IS',
53
+ isMicro: false,
54
+ isYearly: false,
55
+ key: ID_SUBSCRIPTION_SOCIETY_TAX_MENSUAL,
56
+ isCashBased: false,
57
+ isSocietyTax: true,
58
+ },
59
+ {
60
+ name: 'Offre entreprise IR',
61
+ isMicro: false,
62
+ isYearly: true,
63
+ isCashBased: true,
64
+ isSocietyTax: false,
65
+ key: ID_SUBSCRIPTION_INCOME_TAX_ANNUAL,
66
+ },
67
+ {
68
+ name: 'Offre entreprise IR',
69
+ isMicro: false,
70
+ isYearly: false,
71
+ key: ID_SUBSCRIPTION_INCOME_TAX_MENSUAL,
72
+ isCashBased: true,
73
+ isSocietyTax: false,
74
+ },
75
+ ];
76
+ export function getDefaultOffer(params) {
77
+ const { idLegalForm, idComptaType, isYearly, idTaxSystem } = params;
78
+ const isMicro = LegalFormTypeEnum.AUTO_ENTREPRENEUR === idLegalForm;
79
+ const isCashBased = idComptaType
80
+ ? [ComptaType.CASH_BASED, ComptaType.CASH_BASED_ASSISTANCE, ComptaType.CASH_BASED_SEIZURE].includes(idComptaType)
81
+ : false;
82
+ const isSocietyTax = idTaxSystem === TaxSystem.IS;
83
+ const newPlan = list.find((l) => l.isMicro === isMicro &&
84
+ l.isYearly === isYearly &&
85
+ l.isCashBased === isCashBased &&
86
+ l.isSocietyTax === isSocietyTax);
87
+ if (newPlan) {
88
+ return newPlan;
89
+ }
90
+ return isYearly ? list[2] : list[3];
91
+ }
92
+ //# sourceMappingURL=subscription.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subscription.js","sourceRoot":"","sources":["../../../ts/utils/subscription.ts"],"names":[],"mappings":"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","sourcesContent":["import { ComptaType } from '../types/Enum/ComptaType';\nimport { LegalFormTypeEnum } from '../types/Enum/LegalForm';\nimport { TaxSystem } from '../types/Enum/TaxSystem';\n\ninterface OfferParams {\n idLegalForm: LegalFormTypeEnum | null;\n idComptaType: ComptaType | null;\n idTaxSystem: TaxSystem | null;\n isYearly?: boolean;\n}\n\ninterface StripeOffer {\n name: string;\n isYearly: boolean;\n isMicro: boolean;\n key: string;\n isCashBased: boolean;\n isSocietyTax?: boolean;\n}\n\nconst isTestKey: boolean = ['dev', 'staging', 'development', 'test', 'gitlab'].includes(process.env.NODE_ENV ?? '');\n\n// AE | Annuel | Forfait Bilan complet\nconst ID_SUBSCRIPTION_MICRO_ANNUAL = !isTestKey ? 'price_1PFyHHIHo1jEedppVjwrqPr1' : 'price_1MRyi1IHo1jEedppRKdY06Re';\n\n// AE | Mensuel | Forfait Bilan complet\nconst ID_SUBSCRIPTION_MICRO_MENSUAL = !isTestKey ? 'price_1LBJ4xIHo1jEedppylxr3fFa' : 'price_1LBI57IHo1jEedpppnxskfgv';\n\n// Entreprise | Annuel | Forfait entreprise à l'IR\nconst ID_SUBSCRIPTION_INCOME_TAX_ANNUAL = !isTestKey\n ? 'price_1PFyG8IHo1jEedpp73TUxiJd'\n : 'price_1MRyiJIHo1jEedppUe7MnPtW';\n\n// Entreprise | Mensuel | Forfaitentreprise à l'IR\nconst ID_SUBSCRIPTION_INCOME_TAX_MENSUAL = !isTestKey\n ? 'price_1LBJ5YIHo1jEedppzwTErh9M'\n : 'price_1LBIA3IHo1jEedpp2taeQ7yW';\n\n// Entreprise | Annuel | Forfait entreprise à l'IS\nconst ID_SUBSCRIPTION_SOCIETY_TAX_ANNUAL = !isTestKey\n ? 'price_1PFwE3IHo1jEedpphgWrgwkA'\n : 'price_1MRyiWIHo1jEedppp5tnksZe';\n\n// Entreprise | Mensuel | Forfait entreprise à l'IS\nconst ID_SUBSCRIPTION_SOCIETY_TAX_MENSUAL = !isTestKey\n ? 'price_1LBJ69IHo1jEedppAWLeOk3I'\n : 'price_1LBIB7IHo1jEedppocxyc1ft';\n\nexport const stripeTaxRate = isTestKey ? 'txr_1I9X9MIHo1jEedppM0DqL4iE' : 'txr_1I9X5wIHo1jEedppYttGFc0N';\n\nconst list: StripeOffer[] = [\n {\n name: 'Offre auto-entrepreneur',\n isYearly: true,\n isMicro: true,\n key: ID_SUBSCRIPTION_MICRO_ANNUAL,\n isCashBased: true,\n isSocietyTax: false,\n },\n {\n name: 'Offre auto-entrepreneur',\n isYearly: false,\n isMicro: true,\n key: ID_SUBSCRIPTION_MICRO_MENSUAL,\n isCashBased: true,\n isSocietyTax: false,\n },\n {\n name: 'Offre entreprise IS',\n isYearly: true,\n isMicro: false,\n key: ID_SUBSCRIPTION_SOCIETY_TAX_ANNUAL,\n isCashBased: false,\n isSocietyTax: true,\n },\n {\n name: 'Offre entreprise IS',\n isMicro: false,\n isYearly: false,\n key: ID_SUBSCRIPTION_SOCIETY_TAX_MENSUAL,\n isCashBased: false,\n isSocietyTax: true,\n },\n {\n name: 'Offre entreprise IR',\n isMicro: false,\n isYearly: true,\n isCashBased: true,\n isSocietyTax: false,\n key: ID_SUBSCRIPTION_INCOME_TAX_ANNUAL,\n },\n {\n name: 'Offre entreprise IR',\n isMicro: false,\n isYearly: false,\n key: ID_SUBSCRIPTION_INCOME_TAX_MENSUAL,\n isCashBased: true,\n isSocietyTax: false,\n },\n];\n\nexport function getDefaultOffer(params: OfferParams): StripeOffer {\n const { idLegalForm, idComptaType, isYearly, idTaxSystem } = params;\n\n const isMicro = LegalFormTypeEnum.AUTO_ENTREPRENEUR === idLegalForm;\n const isCashBased = idComptaType\n ? [ComptaType.CASH_BASED, ComptaType.CASH_BASED_ASSISTANCE, ComptaType.CASH_BASED_SEIZURE].includes(idComptaType)\n : false;\n const isSocietyTax = idTaxSystem === TaxSystem.IS;\n\n const newPlan = list.find(\n (l) =>\n l.isMicro === isMicro &&\n l.isYearly === isYearly &&\n l.isCashBased === isCashBased &&\n l.isSocietyTax === isSocietyTax,\n );\n\n if (newPlan) {\n return newPlan;\n }\n\n return isYearly ? list[2] : list[3];\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@silexpert/core",
3
- "version": "1.3.66-6",
3
+ "version": "1.3.67-0",
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": "dist/cjs/index.js",
@@ -29,10 +29,8 @@ import {
29
29
  ReadSocietyUnpaidStats,
30
30
  DataCustomersCsv,
31
31
  ReadCurrentPrestations,
32
- IComment,
33
32
  } from '../../types';
34
33
  import { CancelToken } from 'axios';
35
- import { User } from './User';
36
34
 
37
35
  export class Society extends Resource {
38
36
  public get(params: QuerySociety): Promise<ISociety> {
@@ -105,15 +103,6 @@ export class Society extends Resource {
105
103
  getAccountant(): Promise<IUser | null> {
106
104
  return this.axios.$get('/society/accountant');
107
105
  }
108
-
109
- createComment(idSociety: number, payload: Omit<IComment, 'id' | 'idSociety'>): Promise<IComment> {
110
- return this.axios.$post(`/society/${idSociety}/comment`, payload);
111
- }
112
-
113
- updateComment(idComment: number, payload: Partial<IComment>): Promise<IComment> {
114
- return this.axios.$put(`/society/comment/${idComment}`, payload);
115
- }
116
-
117
106
  deleteUser(idSociety: number, idUser: number): Promise<true> {
118
107
  return this.axios.$delete(`/society/${idSociety}/user/${idUser}`);
119
108
  }
@@ -141,10 +141,4 @@ export const FollowList = {
141
141
  hidden: false,
142
142
  color: 'purple lighten-5',
143
143
  },
144
- BILLING_SOFTWARE: {
145
- id: 25,
146
- name: 'Logiciel de facturation',
147
- hidden: false,
148
- color: 'orange lighten-2',
149
- },
150
144
  };
@@ -1,84 +1,64 @@
1
- export enum PaymentMethodIds {
2
- DIRECT_DEBIT = 1,
3
- BANK_TRANSFER = 2,
4
- BANK_CARD = 3,
5
- BANK_CHECK = 4,
6
- DIRECT_DEBIT_REJECTION_1 = 5,
7
- DIRECT_DEBIT_REJECTION_2 = 6,
8
- VARIOUS_UNPAID = 7,
9
- STRIPE_ECB = 8,
10
- STRIPE = 9,
11
- CASH = 10,
12
- STRIPE_ECB_REJECTION = 11,
13
- }
14
-
15
1
  export const PaymentMethod = {
16
2
  DIRECT_DEBIT: {
17
- id: PaymentMethodIds.DIRECT_DEBIT,
3
+ id: 1,
18
4
  name: 'Prélèvement',
19
5
  isSpecial: 0,
20
6
  isOverdue: 0,
21
7
  },
22
8
  BANK_TRANSFER: {
23
- id: PaymentMethodIds.BANK_TRANSFER,
9
+ id: 2,
24
10
  name: 'Virement',
25
11
  isSpecial: 0,
26
12
  isOverdue: 0,
27
13
  },
28
14
  BANK_CARD: {
29
- id: PaymentMethodIds.BANK_CARD,
15
+ id: 3,
30
16
  name: 'CB',
31
17
  isSpecial: 0,
32
18
  isOverdue: 0,
33
19
  },
34
20
  BANK_CHECK: {
35
- id: PaymentMethodIds.BANK_CHECK,
21
+ id: 4,
36
22
  name: 'Chèque',
37
23
  isSpecial: 0,
38
24
  isOverdue: 0,
39
25
  },
40
26
  DIRECT_DEBIT_REJECTION_1: {
41
- id: PaymentMethodIds.DIRECT_DEBIT_REJECTION_1,
27
+ id: 5,
42
28
  name: 'Rejet de prélèvement 1',
43
29
  isSpecial: 1,
44
30
  isOverdue: 1,
45
31
  },
46
32
  DIRECT_DEBIT_REJECTION_2: {
47
- id: PaymentMethodIds.DIRECT_DEBIT_REJECTION_2,
33
+ id: 6,
48
34
  name: 'Rejet de prélèvement 2',
49
35
  isSpecial: 1,
50
36
  isOverdue: 1,
51
37
  },
52
38
  VARIOUS_UNPAID: {
53
- id: PaymentMethodIds.VARIOUS_UNPAID,
39
+ id: 7,
54
40
  name: 'Impayés divers',
55
41
  isSpecial: 1,
56
42
  isOverdue: 1,
57
43
  },
58
44
  STRIPE_ECB: {
59
- id: PaymentMethodIds.STRIPE_ECB,
45
+ id: 8,
60
46
  name: 'Stripe (ECB)',
61
47
  isSpecial: 0,
62
48
  isOverdue: 0,
63
49
  },
64
50
  STRIPE: {
65
- id: PaymentMethodIds.STRIPE,
51
+ id: 9,
66
52
  name: 'Stripe',
67
53
  isSpecial: 0,
68
54
  isOverdue: 0,
69
55
  },
70
56
  CASH: {
71
- id: PaymentMethodIds.CASH,
57
+ id: 10,
72
58
  name: 'Espèces',
73
59
  isSpecial: 0,
74
60
  isOverdue: 0,
75
61
  },
76
- STRIPE_ECB_REJECTION: {
77
- id: PaymentMethodIds.STRIPE_ECB_REJECTION,
78
- name: 'Rejet Stripe ECB',
79
- isSpecial: 1,
80
- isOverdue: 1,
81
- },
82
62
  };
83
63
 
84
64
  export const PaymentParams = {
@@ -1,16 +1,11 @@
1
- import { IsArray, IsInt, IsNumber, IsOptional } from 'class-validator';
1
+ import { IsArray, IsNumber, IsOptional } from 'class-validator';
2
2
  import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
3
3
 
4
4
  export class RegenerateInternalInvoicing {
5
5
  @ApiPropertyOptional()
6
6
  @IsOptional()
7
7
  @IsArray()
8
- idSociety?: Array<number>;
9
-
10
- @ApiPropertyOptional()
11
- @IsOptional()
12
- @IsInt()
13
- idFile?: number | null;
8
+ idSociety: Array<number>;
14
9
 
15
10
  @ApiProperty()
16
11
  @IsNumber()
@@ -1,23 +1,24 @@
1
1
  import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
2
2
  import { RequiredQueryPaginate } from '../BasePaginate';
3
3
  import { Order } from '../BaseRequest';
4
- import { IsBoolean, IsInt, IsOptional } from 'class-validator';
4
+ import { Type } from 'class-transformer';
5
+ import { IsBoolean, IsOptional } from 'class-validator';
5
6
 
6
7
  export class QueryRefundPaginated extends RequiredQueryPaginate implements Order {
7
8
  @ApiPropertyOptional()
8
9
  search?: string;
9
10
 
10
11
  @ApiProperty()
11
- @IsInt()
12
+ @Type(() => Number)
12
13
  year: number;
13
14
 
14
15
  @ApiPropertyOptional()
15
- @IsInt()
16
+ @Type(() => Number)
16
17
  @IsOptional()
17
18
  month?: number;
18
19
 
19
20
  @ApiPropertyOptional()
20
- @IsInt()
21
+ @Type(() => Number)
21
22
  @IsOptional()
22
23
  motif?: number;
23
24
 
@@ -95,10 +95,3 @@ export class CreatePaymentIntent {
95
95
  @ApiPropertyOptional()
96
96
  metadata?: Stripe.MetadataParam;
97
97
  }
98
-
99
- export class PostProcessPaymentAutomatically {
100
- @ApiPropertyOptional()
101
- @IsInt()
102
- @IsOptional()
103
- idSociety?: number;
104
- }
@@ -88,4 +88,9 @@ export class GetPaginatedWhereObjectParams {
88
88
  @IsOptional()
89
89
  @IsInt()
90
90
  idRole?: number;
91
+
92
+ @ApiPropertyOptional()
93
+ @IsOptional()
94
+ @IsInt({ each: true })
95
+ idBrandType?: number[];
91
96
  }
@@ -3,7 +3,7 @@ import { ISociety } from './ISociety';
3
3
  import { IUser } from './IUser';
4
4
 
5
5
  export interface IAppNotification {
6
- id?: number;
6
+ id: number;
7
7
  title: string;
8
8
  message: string;
9
9
  link?: string;
@@ -17,6 +17,6 @@ export interface IAppNotification {
17
17
  updatedAt?: Date | null;
18
18
 
19
19
  // associations
20
- society?: ISociety;
21
- user?: IUser;
20
+ society: ISociety;
21
+ user: IUser;
22
22
  }
@@ -3,10 +3,8 @@ import { NotificationTypeEnum } from '../../Enum/NotificationType';
3
3
  export interface IMobileNotificationLog {
4
4
  id: number;
5
5
  idType: NotificationTypeEnum;
6
- /** @deprecated useless */
7
- lastSent?: Date | null;
8
- /** @deprecated useless */
9
- nextSend?: Date | null;
6
+ lastSent: Date | null;
7
+ nextSend: Date | null;
10
8
  success: boolean;
11
9
  error: string | null;
12
10
  count: number;
@@ -4,7 +4,6 @@ import { IUser } from './IUser';
4
4
  import { IExercice } from './IExercice';
5
5
  import { IFile } from './IFile';
6
6
  import { IPaymentExpectation } from './IPaymentExpectation';
7
- import { IPaymentAttempt } from './IPaymentAttempt';
8
7
 
9
8
  // payments
10
9
  export interface IPayment {
@@ -16,7 +15,7 @@ export interface IPayment {
16
15
  isOverpaid?: boolean;
17
16
  isFirst?: boolean;
18
17
  // @deprecated Use isCollectable instead
19
- toCollect?: boolean;
18
+ toCollect?: boolean;
20
19
  countRejects?: number;
21
20
  isCollectable?: boolean;
22
21
  isAsset?: boolean;
@@ -45,5 +44,4 @@ export interface IPayment {
45
44
  user?: IUser;
46
45
  exercice?: IExercice;
47
46
  files?: IFile;
48
- paymentAttempts?: IPaymentAttempt[];
49
47
  }
@@ -4,26 +4,16 @@ import { IUser } from './IUser';
4
4
 
5
5
  // refunds
6
6
  export interface IRefund {
7
- idRefund?: number;
7
+ id?: number;
8
8
  amount: number | null;
9
9
  comment: string | null;
10
10
  refundDate: Date | null;
11
- refundAt?: Date | null;
12
11
  processed: boolean;
13
-
14
12
  isAmountChecked?: boolean;
15
-
16
13
  idRefundMotif: number;
17
14
  idSociety: number;
18
15
  idUserDemand: number;
19
- refundBy?: number | null;
20
16
  idFile?: number | null; //non obligatoire désormais, utilisé avant pour rattacher le RIB
21
- idUserAgreement?: number | null;
22
- dateAgreement?: Date | null;
23
-
24
- exceptionalAgreement?: boolean | null;
25
- agreement?: number | null;
26
-
27
17
  createdAt?: Date | null;
28
18
  updatedAt?: Date | null;
29
19
 
@@ -31,6 +21,4 @@ export interface IRefund {
31
21
  society?: ISociety;
32
22
  file?: IFile;
33
23
  userDemand?: IUser;
34
- refundByUser?: IUser;
35
- agreementUser?: IUser;
36
24
  }
package/ts/types/index.ts CHANGED
@@ -323,7 +323,6 @@ export * from './Interface/models/IReminderAttachment';
323
323
  export * from './Interface/models/IStateBankAccount';
324
324
  export * from './Interface/models/IAIQuestion';
325
325
  export * from './Interface/models/IAIConversation';
326
- export * from './Interface/models/IPaymentAttempt';
327
326
 
328
327
  // Schemas
329
328
  export * from './Interface/schemas/IRegistrationDetail';
@@ -554,7 +553,6 @@ export * from './Enum/SocietyTypeExportCsv';
554
553
  export * from './Enum/TeamType';
555
554
  export * from './Enum/PartneredAccountantServiceType';
556
555
  export * from './Enum/PartneredAccountantServiceTypeId';
557
- export * from './Enum/PaymentAttempt';
558
556
 
559
557
  // Interfaces API
560
558
  export * from './Interface/api/exercice/ReadExercice';
@@ -0,0 +1,124 @@
1
+ import { ComptaType } from '../types/Enum/ComptaType';
2
+ import { LegalFormTypeEnum } from '../types/Enum/LegalForm';
3
+ import { TaxSystem } from '../types/Enum/TaxSystem';
4
+
5
+ interface OfferParams {
6
+ idLegalForm: LegalFormTypeEnum | null;
7
+ idComptaType: ComptaType | null;
8
+ idTaxSystem: TaxSystem | null;
9
+ isYearly?: boolean;
10
+ }
11
+
12
+ interface StripeOffer {
13
+ name: string;
14
+ isYearly: boolean;
15
+ isMicro: boolean;
16
+ key: string;
17
+ isCashBased: boolean;
18
+ isSocietyTax?: boolean;
19
+ }
20
+
21
+ const isTestKey: boolean = ['dev', 'staging', 'development', 'test', 'gitlab'].includes(process.env.NODE_ENV ?? '');
22
+
23
+ // AE | Annuel | Forfait Bilan complet
24
+ const ID_SUBSCRIPTION_MICRO_ANNUAL = !isTestKey ? 'price_1PFyHHIHo1jEedppVjwrqPr1' : 'price_1MRyi1IHo1jEedppRKdY06Re';
25
+
26
+ // AE | Mensuel | Forfait Bilan complet
27
+ const ID_SUBSCRIPTION_MICRO_MENSUAL = !isTestKey ? 'price_1LBJ4xIHo1jEedppylxr3fFa' : 'price_1LBI57IHo1jEedpppnxskfgv';
28
+
29
+ // Entreprise | Annuel | Forfait entreprise à l'IR
30
+ const ID_SUBSCRIPTION_INCOME_TAX_ANNUAL = !isTestKey
31
+ ? 'price_1PFyG8IHo1jEedpp73TUxiJd'
32
+ : 'price_1MRyiJIHo1jEedppUe7MnPtW';
33
+
34
+ // Entreprise | Mensuel | Forfaitentreprise à l'IR
35
+ const ID_SUBSCRIPTION_INCOME_TAX_MENSUAL = !isTestKey
36
+ ? 'price_1LBJ5YIHo1jEedppzwTErh9M'
37
+ : 'price_1LBIA3IHo1jEedpp2taeQ7yW';
38
+
39
+ // Entreprise | Annuel | Forfait entreprise à l'IS
40
+ const ID_SUBSCRIPTION_SOCIETY_TAX_ANNUAL = !isTestKey
41
+ ? 'price_1PFwE3IHo1jEedpphgWrgwkA'
42
+ : 'price_1MRyiWIHo1jEedppp5tnksZe';
43
+
44
+ // Entreprise | Mensuel | Forfait entreprise à l'IS
45
+ const ID_SUBSCRIPTION_SOCIETY_TAX_MENSUAL = !isTestKey
46
+ ? 'price_1LBJ69IHo1jEedppAWLeOk3I'
47
+ : 'price_1LBIB7IHo1jEedppocxyc1ft';
48
+
49
+ export const stripeTaxRate = isTestKey ? 'txr_1I9X9MIHo1jEedppM0DqL4iE' : 'txr_1I9X5wIHo1jEedppYttGFc0N';
50
+
51
+ const list: StripeOffer[] = [
52
+ {
53
+ name: 'Offre auto-entrepreneur',
54
+ isYearly: true,
55
+ isMicro: true,
56
+ key: ID_SUBSCRIPTION_MICRO_ANNUAL,
57
+ isCashBased: true,
58
+ isSocietyTax: false,
59
+ },
60
+ {
61
+ name: 'Offre auto-entrepreneur',
62
+ isYearly: false,
63
+ isMicro: true,
64
+ key: ID_SUBSCRIPTION_MICRO_MENSUAL,
65
+ isCashBased: true,
66
+ isSocietyTax: false,
67
+ },
68
+ {
69
+ name: 'Offre entreprise IS',
70
+ isYearly: true,
71
+ isMicro: false,
72
+ key: ID_SUBSCRIPTION_SOCIETY_TAX_ANNUAL,
73
+ isCashBased: false,
74
+ isSocietyTax: true,
75
+ },
76
+ {
77
+ name: 'Offre entreprise IS',
78
+ isMicro: false,
79
+ isYearly: false,
80
+ key: ID_SUBSCRIPTION_SOCIETY_TAX_MENSUAL,
81
+ isCashBased: false,
82
+ isSocietyTax: true,
83
+ },
84
+ {
85
+ name: 'Offre entreprise IR',
86
+ isMicro: false,
87
+ isYearly: true,
88
+ isCashBased: true,
89
+ isSocietyTax: false,
90
+ key: ID_SUBSCRIPTION_INCOME_TAX_ANNUAL,
91
+ },
92
+ {
93
+ name: 'Offre entreprise IR',
94
+ isMicro: false,
95
+ isYearly: false,
96
+ key: ID_SUBSCRIPTION_INCOME_TAX_MENSUAL,
97
+ isCashBased: true,
98
+ isSocietyTax: false,
99
+ },
100
+ ];
101
+
102
+ export function getDefaultOffer(params: OfferParams): StripeOffer {
103
+ const { idLegalForm, idComptaType, isYearly, idTaxSystem } = params;
104
+
105
+ const isMicro = LegalFormTypeEnum.AUTO_ENTREPRENEUR === idLegalForm;
106
+ const isCashBased = idComptaType
107
+ ? [ComptaType.CASH_BASED, ComptaType.CASH_BASED_ASSISTANCE, ComptaType.CASH_BASED_SEIZURE].includes(idComptaType)
108
+ : false;
109
+ const isSocietyTax = idTaxSystem === TaxSystem.IS;
110
+
111
+ const newPlan = list.find(
112
+ (l) =>
113
+ l.isMicro === isMicro &&
114
+ l.isYearly === isYearly &&
115
+ l.isCashBased === isCashBased &&
116
+ l.isSocietyTax === isSocietyTax,
117
+ );
118
+
119
+ if (newPlan) {
120
+ return newPlan;
121
+ }
122
+
123
+ return isYearly ? list[2] : list[3];
124
+ }
@@ -1,6 +0,0 @@
1
- export declare enum PaymentAttemptStatus {
2
- ERROR = 0,
3
- SUCCESS = 1,
4
- BLOCKING_ERROR = 3
5
- }
6
- //# sourceMappingURL=PaymentAttempt.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PaymentAttempt.d.ts","sourceRoot":"","sources":["../../../../ts/types/Enum/PaymentAttempt.ts"],"names":[],"mappings":"AAAA,oBAAY,oBAAoB;IAC9B,KAAK,IAAI;IACT,OAAO,IAAI;IACX,cAAc,IAAI;CACnB"}
@@ -1,10 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.PaymentAttemptStatus = void 0;
4
- var PaymentAttemptStatus;
5
- (function (PaymentAttemptStatus) {
6
- PaymentAttemptStatus[PaymentAttemptStatus["ERROR"] = 0] = "ERROR";
7
- PaymentAttemptStatus[PaymentAttemptStatus["SUCCESS"] = 1] = "SUCCESS";
8
- PaymentAttemptStatus[PaymentAttemptStatus["BLOCKING_ERROR"] = 3] = "BLOCKING_ERROR";
9
- })(PaymentAttemptStatus || (exports.PaymentAttemptStatus = PaymentAttemptStatus = {}));
10
- //# sourceMappingURL=PaymentAttempt.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PaymentAttempt.js","sourceRoot":"","sources":["../../../../ts/types/Enum/PaymentAttempt.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAIX;AAJD,WAAY,oBAAoB;IAC9B,iEAAS,CAAA;IACT,qEAAW,CAAA;IACX,mFAAkB,CAAA;AACpB,CAAC,EAJW,oBAAoB,oCAApB,oBAAoB,QAI/B","sourcesContent":["export enum PaymentAttemptStatus {\n ERROR = 0,\n SUCCESS = 1,\n BLOCKING_ERROR = 3, // Erreur bloquante, plus aucune tentative de paiement n'aura lieu\n}\n"]}
@@ -1,15 +0,0 @@
1
- import { PaymentAttemptStatus } from '../../Enum/PaymentAttempt';
2
- import { PaymentMethodIds } from '../../Enum/PaymentMethod';
3
- import { IPayment } from './IPayment';
4
- export interface IPaymentAttempt {
5
- id?: number;
6
- reference: string | null;
7
- comment: string | null;
8
- status: PaymentAttemptStatus;
9
- idPaymentMethod: PaymentMethodIds;
10
- idPayment: number;
11
- createdAt?: string;
12
- updatedAt?: string;
13
- payment?: IPayment;
14
- }
15
- //# sourceMappingURL=IPaymentAttempt.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"IPaymentAttempt.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/models/IPaymentAttempt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,WAAW,eAAe;IAC9B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,MAAM,EAAE,oBAAoB,CAAC;IAC7B,eAAe,EAAE,gBAAgB,CAAC;IAClC,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB,OAAO,CAAC,EAAE,QAAQ,CAAC;CACpB"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=IPaymentAttempt.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"IPaymentAttempt.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/models/IPaymentAttempt.ts"],"names":[],"mappings":"","sourcesContent":["import { PaymentAttemptStatus } from '../../Enum/PaymentAttempt';\nimport { PaymentMethodIds } from '../../Enum/PaymentMethod';\nimport { IPayment } from './IPayment';\n\nexport interface IPaymentAttempt {\n id?: number;\n reference: string | null;\n comment: string | null;\n status: PaymentAttemptStatus;\n idPaymentMethod: PaymentMethodIds;\n idPayment: number;\n createdAt?: string;\n updatedAt?: string;\n\n payment?: IPayment;\n}\n"]}
@@ -1,6 +0,0 @@
1
- export declare enum PaymentAttemptStatus {
2
- ERROR = 0,
3
- SUCCESS = 1,
4
- BLOCKING_ERROR = 3
5
- }
6
- //# sourceMappingURL=PaymentAttempt.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PaymentAttempt.d.ts","sourceRoot":"","sources":["../../../../ts/types/Enum/PaymentAttempt.ts"],"names":[],"mappings":"AAAA,oBAAY,oBAAoB;IAC9B,KAAK,IAAI;IACT,OAAO,IAAI;IACX,cAAc,IAAI;CACnB"}
@@ -1,7 +0,0 @@
1
- export var PaymentAttemptStatus;
2
- (function (PaymentAttemptStatus) {
3
- PaymentAttemptStatus[PaymentAttemptStatus["ERROR"] = 0] = "ERROR";
4
- PaymentAttemptStatus[PaymentAttemptStatus["SUCCESS"] = 1] = "SUCCESS";
5
- PaymentAttemptStatus[PaymentAttemptStatus["BLOCKING_ERROR"] = 3] = "BLOCKING_ERROR";
6
- })(PaymentAttemptStatus || (PaymentAttemptStatus = {}));
7
- //# sourceMappingURL=PaymentAttempt.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PaymentAttempt.js","sourceRoot":"","sources":["../../../../ts/types/Enum/PaymentAttempt.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,oBAIX;AAJD,WAAY,oBAAoB;IAC9B,iEAAS,CAAA;IACT,qEAAW,CAAA;IACX,mFAAkB,CAAA;AACpB,CAAC,EAJW,oBAAoB,KAApB,oBAAoB,QAI/B","sourcesContent":["export enum PaymentAttemptStatus {\n ERROR = 0,\n SUCCESS = 1,\n BLOCKING_ERROR = 3, // Erreur bloquante, plus aucune tentative de paiement n'aura lieu\n}\n"]}
@@ -1,15 +0,0 @@
1
- import { PaymentAttemptStatus } from '../../Enum/PaymentAttempt';
2
- import { PaymentMethodIds } from '../../Enum/PaymentMethod';
3
- import { IPayment } from './IPayment';
4
- export interface IPaymentAttempt {
5
- id?: number;
6
- reference: string | null;
7
- comment: string | null;
8
- status: PaymentAttemptStatus;
9
- idPaymentMethod: PaymentMethodIds;
10
- idPayment: number;
11
- createdAt?: string;
12
- updatedAt?: string;
13
- payment?: IPayment;
14
- }
15
- //# sourceMappingURL=IPaymentAttempt.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"IPaymentAttempt.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/models/IPaymentAttempt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,WAAW,eAAe;IAC9B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,MAAM,EAAE,oBAAoB,CAAC;IAC7B,eAAe,EAAE,gBAAgB,CAAC;IAClC,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB,OAAO,CAAC,EAAE,QAAQ,CAAC;CACpB"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=IPaymentAttempt.js.map