@silexpert/core 1.1.174 → 1.1.175

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 (64) hide show
  1. package/dist/cjs/api/resources/ExercicePrestation.d.ts +11 -0
  2. package/dist/cjs/api/resources/ExercicePrestation.d.ts.map +1 -0
  3. package/dist/cjs/api/resources/ExercicePrestation.js +16 -0
  4. package/dist/cjs/api/resources/ExercicePrestation.js.map +1 -0
  5. package/dist/cjs/api/resources/Notion.d.ts +5 -4
  6. package/dist/cjs/api/resources/Notion.d.ts.map +1 -1
  7. package/dist/cjs/api/resources/Notion.js +1 -1
  8. package/dist/cjs/api/resources/Notion.js.map +1 -1
  9. package/dist/cjs/api/resources.d.ts +2 -0
  10. package/dist/cjs/api/resources.d.ts.map +1 -1
  11. package/dist/cjs/api/resources.js +2 -0
  12. package/dist/cjs/api/resources.js.map +1 -1
  13. package/dist/cjs/types/Interface/api/exercicePrestation/Query.d.ts +7 -0
  14. package/dist/cjs/types/Interface/api/exercicePrestation/Query.d.ts.map +1 -0
  15. package/dist/cjs/types/Interface/api/exercicePrestation/Query.js +28 -0
  16. package/dist/cjs/types/Interface/api/exercicePrestation/Query.js.map +1 -0
  17. package/dist/cjs/types/Interface/api/notion/NotionResponse.d.ts +1537 -0
  18. package/dist/cjs/types/Interface/api/notion/NotionResponse.d.ts.map +1 -0
  19. package/dist/cjs/types/Interface/api/notion/NotionResponse.js +3 -0
  20. package/dist/cjs/types/Interface/api/notion/NotionResponse.js.map +1 -0
  21. package/dist/cjs/types/index.d.ts +2 -0
  22. package/dist/cjs/types/index.d.ts.map +1 -1
  23. package/dist/cjs/types/index.js +2 -0
  24. package/dist/cjs/types/index.js.map +1 -1
  25. package/dist/cjs/utils/prestation.d.ts +1 -0
  26. package/dist/cjs/utils/prestation.d.ts.map +1 -1
  27. package/dist/cjs/utils/prestation.js +2 -2
  28. package/dist/cjs/utils/prestation.js.map +1 -1
  29. package/dist/mjs/api/resources/ExercicePrestation.d.ts +11 -0
  30. package/dist/mjs/api/resources/ExercicePrestation.d.ts.map +1 -0
  31. package/dist/mjs/api/resources/ExercicePrestation.js +12 -0
  32. package/dist/mjs/api/resources/ExercicePrestation.js.map +1 -0
  33. package/dist/mjs/api/resources/Notion.d.ts +5 -4
  34. package/dist/mjs/api/resources/Notion.d.ts.map +1 -1
  35. package/dist/mjs/api/resources/Notion.js +1 -1
  36. package/dist/mjs/api/resources/Notion.js.map +1 -1
  37. package/dist/mjs/api/resources.d.ts +2 -0
  38. package/dist/mjs/api/resources.d.ts.map +1 -1
  39. package/dist/mjs/api/resources.js +2 -0
  40. package/dist/mjs/api/resources.js.map +1 -1
  41. package/dist/mjs/types/Interface/api/exercicePrestation/Query.d.ts +7 -0
  42. package/dist/mjs/types/Interface/api/exercicePrestation/Query.d.ts.map +1 -0
  43. package/dist/mjs/types/Interface/api/exercicePrestation/Query.js +26 -0
  44. package/dist/mjs/types/Interface/api/exercicePrestation/Query.js.map +1 -0
  45. package/dist/mjs/types/Interface/api/notion/NotionResponse.d.ts +1537 -0
  46. package/dist/mjs/types/Interface/api/notion/NotionResponse.d.ts.map +1 -0
  47. package/dist/mjs/types/Interface/api/notion/NotionResponse.js +2 -0
  48. package/dist/mjs/types/Interface/api/notion/NotionResponse.js.map +1 -0
  49. package/dist/mjs/types/index.d.ts +2 -0
  50. package/dist/mjs/types/index.d.ts.map +1 -1
  51. package/dist/mjs/types/index.js +2 -0
  52. package/dist/mjs/types/index.js.map +1 -1
  53. package/dist/mjs/utils/prestation.d.ts +1 -0
  54. package/dist/mjs/utils/prestation.d.ts.map +1 -1
  55. package/dist/mjs/utils/prestation.js +2 -2
  56. package/dist/mjs/utils/prestation.js.map +1 -1
  57. package/package.json +1 -1
  58. package/ts/api/resources/ExercicePrestation.ts +16 -0
  59. package/ts/api/resources/Notion.ts +6 -5
  60. package/ts/api/resources.ts +2 -0
  61. package/ts/types/Interface/api/exercicePrestation/Query.ts +14 -0
  62. package/ts/types/Interface/api/notion/NotionResponse.ts +1288 -0
  63. package/ts/types/index.ts +3 -0
  64. package/ts/utils/prestation.ts +3 -3
package/ts/types/index.ts CHANGED
@@ -936,6 +936,7 @@ export * from './Interface/api/file/Create';
936
936
  export * from './Interface/api/file/Read';
937
937
  export * from './Interface/api/societyConfig/update';
938
938
  export * from './Interface/api/wallet/UpdateAttribution';
939
+ export * from './Interface/api/exercicePrestation/Query';
939
940
  export * from './Interface/api/prestation/CreatePrestation';
940
941
  export * from './Interface/api/prestation/Query';
941
942
  export * from './Interface/api/prestation/QueryPrestation';
@@ -983,6 +984,8 @@ export * from './Interface/api/visualizedInformation/Update';
983
984
  export * from './Interface/api/society/QueryArchived';
984
985
  export * from './Interface/api/vatControl/CreateVatControl';
985
986
  export * from './Interface/api/vatControl/QueryVatControl';
987
+ export * from './Interface/api/notion/NotionResponse';
988
+
986
989
  // Enums types
987
990
  export * from './Interface/enum/Util';
988
991
  export * from './Interface/enum/Date';
@@ -193,7 +193,7 @@ const calculatePrestationPriceWithPrestationList = (prestationList: IPrestationL
193
193
  return totalPrestation;
194
194
  };
195
195
 
196
- const calculatePrestationPrice = (idPrestationList: number, prestationList: IPrestationList, endDate: string, NbrMonth: number, turnover: number, rentsNumber: number, employeesNumber: number, associatesNumber: number, idTypeBrand: number, idVatRegime: number, pastBalanceSheet: boolean, optionsList: number[], totalPercentage: number, totalAmount: number, totalMonth: number, isWithApplicationFees: boolean, idTaxSystem: number, isYearly: boolean = false): { totalPrestation: number, reduceMonth: number, canBeCreated: boolean, calculDetail: string, price: number } => {
196
+ const calculatePrestationPrice = (idPrestationList: number, prestationList: IPrestationList, endDate: string, NbrMonth: number, turnover: number, rentsNumber: number, employeesNumber: number, associatesNumber: number, idTypeBrand: number, idVatRegime: number, pastBalanceSheet: boolean, optionsList: number[], totalPercentage: number, totalAmount: number, totalMonth: number, isWithApplicationFees: boolean, idTaxSystem: number, isYearly: boolean = false): { totalPrestation: number, reduceMonth: number, canBeCreated: boolean, calculDetail: string, monthlyPrice: string, price: number } => {
197
197
  let totalPrestation: number = 0;
198
198
  let reduceMonth: number = 0;
199
199
  let canBeCreated: boolean = true;
@@ -246,9 +246,9 @@ const calculatePrestationPrice = (idPrestationList: number, prestationList: IPre
246
246
 
247
247
  if (isWithApplicationFees) totalPrestation += 50;
248
248
 
249
- const calculDetail = `${monthNbr > 0 ? monthNbr + ' mois x ' + price + '€' : price + '€'} ${totalAmount > 0 ? '- ' + totalAmount + '€' : ''} ${totalPercentage > 0 ? '- ' + totalPercentage + '%' : ''} ${isWithApplicationFees ? '+ 50€' : ''}`;
249
+ const calculDetail = `${monthNbr > 0 ? monthNbr + ' mois x ' + (Math.round(price * 100) / 100) + '€' : (Math.round(price * 100) / 100) + '€'} ${totalAmount > 0 ? '- ' + totalAmount + '€' : ''} ${totalPercentage > 0 ? '- ' + totalPercentage + '%' : ''} ${isWithApplicationFees ? '+ 50€' : ''}`;
250
250
 
251
- return { totalPrestation, reduceMonth, canBeCreated, calculDetail, price };
251
+ return { totalPrestation, reduceMonth, canBeCreated, calculDetail, monthlyPrice: monthNbr > 0 ? price + '€/mois' : price + '€', price };
252
252
  };
253
253
 
254
254
  const getPrestationOptions = (idPrestationList: number): PrestationOptionType[] => {