@metarisc/metarisc-js 0.0.1-alpha.57 → 0.0.1-alpha.59

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 (119) hide show
  1. package/lib/api/AnomaliesAPI.js +4 -4
  2. package/lib/api/CommissionsAPI.d.ts +4 -6
  3. package/lib/api/CommissionsAPI.js +13 -13
  4. package/lib/api/DossiersAPI.d.ts +4 -6
  5. package/lib/api/DossiersAPI.js +15 -15
  6. package/lib/api/ERPAPI.js +4 -4
  7. package/lib/api/EvenementsAPI.d.ts +2 -3
  8. package/lib/api/EvenementsAPI.js +7 -7
  9. package/lib/api/FeedAPI.d.ts +2 -3
  10. package/lib/api/FeedAPI.js +4 -4
  11. package/lib/api/MoiAPI.js +1 -1
  12. package/lib/api/NotificationsAPI.d.ts +2 -3
  13. package/lib/api/NotificationsAPI.js +6 -6
  14. package/lib/api/OrganisationsAPI.js +7 -7
  15. package/lib/api/PEIAPI.d.ts +2 -3
  16. package/lib/api/PEIAPI.js +8 -8
  17. package/lib/api/PingAPI.js +1 -1
  18. package/lib/api/PrescriptionsAPI.d.ts +4 -6
  19. package/lib/api/PrescriptionsAPI.js +12 -12
  20. package/lib/api/SupportAPI.js +3 -3
  21. package/lib/api/TournesDECIAPI.d.ts +8 -12
  22. package/lib/api/TournesDECIAPI.js +18 -18
  23. package/lib/api/UtilisateursAPI.js +5 -5
  24. package/lib/model/DescriptifTechniqueERPBase.d.ts +0 -1
  25. package/lib/model/Dossier.d.ts +0 -2
  26. package/lib/model/ERP.d.ts +4 -2
  27. package/lib/model/ERPReferencesExterieuresInner.d.ts +4 -0
  28. package/lib/model/FeedMessage.d.ts +4 -0
  29. package/lib/model/FeedMessage.js +6 -0
  30. package/lib/model/FeedMessageBase.d.ts +5 -1
  31. package/lib/model/FeedMessageBase.js +6 -0
  32. package/lib/model/FeedMessageTexte.d.ts +4 -0
  33. package/lib/model/FeedMessageTexte.js +6 -0
  34. package/lib/model/Notification.d.ts +6 -4
  35. package/lib/model/Prescription.d.ts +1 -0
  36. package/lib/model/TourneeDeci.d.ts +1 -0
  37. package/lib/model/TourneeDeciPei.d.ts +2 -2
  38. package/lib/model/TourneeDeciPeiListeAnomaliesInner.d.ts +6 -0
  39. package/lib/model/TourneeDeciSimple.d.ts +1 -0
  40. package/lib/utils.d.ts +8 -0
  41. package/lib/utils.js +26 -0
  42. package/package.json +1 -1
  43. package/src/api/AnomaliesAPI.ts +4 -4
  44. package/src/api/CommissionsAPI.ts +13 -15
  45. package/src/api/DossiersAPI.ts +15 -17
  46. package/src/api/ERPAPI.ts +4 -4
  47. package/src/api/EvenementsAPI.ts +7 -8
  48. package/src/api/FeedAPI.ts +4 -5
  49. package/src/api/MoiAPI.ts +1 -1
  50. package/src/api/NotificationsAPI.ts +6 -7
  51. package/src/api/OrganisationsAPI.ts +7 -7
  52. package/src/api/PEIAPI.ts +8 -9
  53. package/src/api/PingAPI.ts +1 -1
  54. package/src/api/PrescriptionsAPI.ts +12 -14
  55. package/src/api/SupportAPI.ts +3 -3
  56. package/src/api/TournesDECIAPI.ts +18 -22
  57. package/src/api/UtilisateursAPI.ts +5 -5
  58. package/src/model/DescriptifTechniqueERPBase.ts +0 -1
  59. package/src/model/Dossier.ts +0 -2
  60. package/src/model/ERP.ts +4 -2
  61. package/src/model/ERPReferencesExterieuresInner.ts +4 -0
  62. package/src/model/FeedMessage.ts +5 -0
  63. package/src/model/FeedMessageBase.ts +6 -1
  64. package/src/model/FeedMessageTexte.ts +5 -0
  65. package/src/model/Notification.ts +7 -4
  66. package/src/model/Prescription.ts +1 -0
  67. package/src/model/TourneeDeci.ts +1 -0
  68. package/src/model/TourneeDeciPei.ts +2 -2
  69. package/src/model/TourneeDeciPeiListeAnomaliesInner.ts +7 -0
  70. package/src/model/TourneeDeciSimple.ts +1 -0
  71. package/src/utils.ts +30 -0
  72. package/lib/model/PostCommissionDateRequest.d.ts +0 -11
  73. package/lib/model/PostCommissionDateRequest.js +0 -9
  74. package/lib/model/PostCommissionRequest.d.ts +0 -7
  75. package/lib/model/PostDossierRequest.d.ts +0 -5
  76. package/lib/model/PostEvenementRequest.d.ts +0 -7
  77. package/lib/model/PostEvenementRequest.js +0 -2
  78. package/lib/model/PostMessageRequest.d.ts +0 -8
  79. package/lib/model/PostMessageRequest.js +0 -7
  80. package/lib/model/PostNotificationRequest.d.ts +0 -9
  81. package/lib/model/PostNotificationRequest.js +0 -2
  82. package/lib/model/PostPeiRequest.d.ts +0 -9
  83. package/lib/model/PostPeiRequest.js +0 -2
  84. package/lib/model/PostPrescriptionRequest.d.ts +0 -6
  85. package/lib/model/PostPrescriptionRequest.js +0 -2
  86. package/lib/model/PostPrescriptionRequestSupportsReglementairesInner.d.ts +0 -3
  87. package/lib/model/PostPrescriptionRequestSupportsReglementairesInner.js +0 -2
  88. package/lib/model/PostSupportReglementaireRequest.d.ts +0 -8
  89. package/lib/model/PostSupportReglementaireRequest.js +0 -2
  90. package/lib/model/PostTourneeDeciPeiRequest.d.ts +0 -4
  91. package/lib/model/PostTourneeDeciPeiRequest.js +0 -2
  92. package/lib/model/PostTourneeDeciRequest.d.ts +0 -15
  93. package/lib/model/PostTourneeDeciRequest.js +0 -9
  94. package/lib/model/UpdateDossierWorkflowsDetailsRequest.d.ts +0 -17
  95. package/lib/model/UpdateDossierWorkflowsDetailsRequest.js +0 -2
  96. package/lib/model/UpdateTourneeDeciPeiRequest.d.ts +0 -13
  97. package/lib/model/UpdateTourneeDeciPeiRequest.js +0 -10
  98. package/lib/model/UpdateTourneeDeciPeiRequestListeAnomaliesInner.d.ts +0 -3
  99. package/lib/model/UpdateTourneeDeciPeiRequestListeAnomaliesInner.js +0 -2
  100. package/lib/model/UpdateTourneeDeciRequest.d.ts +0 -8
  101. package/lib/model/UpdateTourneeDeciRequest.js +0 -2
  102. package/src/model/PostCommissionDateRequest.ts +0 -12
  103. package/src/model/PostCommissionRequest.ts +0 -7
  104. package/src/model/PostDossierRequest.ts +0 -5
  105. package/src/model/PostEvenementRequest.ts +0 -7
  106. package/src/model/PostMessageRequest.ts +0 -9
  107. package/src/model/PostNotificationRequest.ts +0 -9
  108. package/src/model/PostPeiRequest.ts +0 -10
  109. package/src/model/PostPrescriptionRequest.ts +0 -7
  110. package/src/model/PostPrescriptionRequestSupportsReglementairesInner.ts +0 -3
  111. package/src/model/PostSupportReglementaireRequest.ts +0 -8
  112. package/src/model/PostTourneeDeciPeiRequest.ts +0 -4
  113. package/src/model/PostTourneeDeciRequest.ts +0 -16
  114. package/src/model/UpdateDossierWorkflowsDetailsRequest.ts +0 -17
  115. package/src/model/UpdateTourneeDeciPeiRequest.ts +0 -15
  116. package/src/model/UpdateTourneeDeciPeiRequestListeAnomaliesInner.ts +0 -3
  117. package/src/model/UpdateTourneeDeciRequest.ts +0 -8
  118. /package/lib/model/{PostCommissionRequest.js → ERPReferencesExterieuresInner.js} +0 -0
  119. /package/lib/model/{PostDossierRequest.js → TourneeDeciPeiListeAnomaliesInner.js} +0 -0
@@ -18,7 +18,7 @@ class AnomaliesAPI extends core_1.Core {
18
18
  endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies/{anomalie_id}'),
19
19
  headers: {},
20
20
  params: {},
21
- body: {}
21
+ body: utils_1.Utils.payloadFilter({})
22
22
  });
23
23
  }
24
24
  /**
@@ -32,7 +32,7 @@ class AnomaliesAPI extends core_1.Core {
32
32
  endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies/{anomalie_id}'),
33
33
  headers: {},
34
34
  params: {},
35
- body: {}
35
+ body: utils_1.Utils.payloadFilter({})
36
36
  });
37
37
  }
38
38
  /**
@@ -48,7 +48,7 @@ class AnomaliesAPI extends core_1.Core {
48
48
  endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies'),
49
49
  headers: {},
50
50
  params: { 'page': page?.toString(), 'per_page': perPage?.toString(), 'texte': texte },
51
- body: {}
51
+ body: utils_1.Utils.payloadFilter({})
52
52
  });
53
53
  }
54
54
  /**
@@ -62,7 +62,7 @@ class AnomaliesAPI extends core_1.Core {
62
62
  endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies'),
63
63
  headers: {},
64
64
  params: {},
65
- body: { 'code': anomalieDECI?.code, 'texte': anomalieDECI?.texte, 'indice_de_gravite': anomalieDECI?.indice_de_gravite }
65
+ body: utils_1.Utils.payloadFilter({ 'code': anomalieDECI?.code, 'texte': anomalieDECI?.texte, 'indice_de_gravite': anomalieDECI?.indice_de_gravite })
66
66
  });
67
67
  }
68
68
  }
@@ -6,8 +6,6 @@ import { Commission } from '../model/Commission';
6
6
  import { PassageCommission } from '../model/PassageCommission';
7
7
  import { PassageCommissionDossier } from '../model/PassageCommissionDossier';
8
8
  import { PostCommissionDateDossierRequest } from '../model/PostCommissionDateDossierRequest';
9
- import { PostCommissionDateRequest } from '../model/PostCommissionDateRequest';
10
- import { PostCommissionRequest } from '../model/PostCommissionRequest';
11
9
  export declare class CommissionsAPI extends Core {
12
10
  constructor(config: MetariscConfig, client?: Client);
13
11
  /**
@@ -49,15 +47,15 @@ export declare class CommissionsAPI extends Core {
49
47
  paginateCommissions(page?: number, perPage?: number): Collection<Commission>;
50
48
  /**
51
49
  * Ajoute une commission.
52
- * @param postCommissionRequest
50
+ * @param commission
53
51
  */
54
- postCommission(postCommissionRequest?: PostCommissionRequest): Promise<AxiosResponse<Commission>>;
52
+ postCommission(commission?: Commission): Promise<AxiosResponse<Commission>>;
55
53
  /**
56
54
  * Ajout d'une date de passage en commission.
57
55
  * @param commissionId Identifiant unique de la commission
58
- * @param postCommissionDateRequest
56
+ * @param passageCommission
59
57
  */
60
- postCommissionDate(commissionId: string, postCommissionDateRequest?: PostCommissionDateRequest): Promise<AxiosResponse<PassageCommission>>;
58
+ postCommissionDate(commissionId: string, passageCommission?: PassageCommission): Promise<AxiosResponse<PassageCommission>>;
61
59
  /**
62
60
  * Ajout d'un dossier à l'ordre du jour d'un passage en commission.
63
61
  * @param commissionId Identifiant unique de la commission
@@ -18,7 +18,7 @@ class CommissionsAPI extends core_1.Core {
18
18
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}'),
19
19
  headers: {},
20
20
  params: {},
21
- body: {}
21
+ body: utils_1.Utils.payloadFilter({})
22
22
  });
23
23
  }
24
24
  /**
@@ -32,7 +32,7 @@ class CommissionsAPI extends core_1.Core {
32
32
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}'),
33
33
  headers: {},
34
34
  params: {},
35
- body: {}
35
+ body: utils_1.Utils.payloadFilter({})
36
36
  });
37
37
  }
38
38
  /**
@@ -47,7 +47,7 @@ class CommissionsAPI extends core_1.Core {
47
47
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates/{date_id}'),
48
48
  headers: {},
49
49
  params: {},
50
- body: {}
50
+ body: utils_1.Utils.payloadFilter({})
51
51
  });
52
52
  }
53
53
  /**
@@ -64,7 +64,7 @@ class CommissionsAPI extends core_1.Core {
64
64
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates/{date_id}/ordre_du_jour'),
65
65
  headers: {},
66
66
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
67
- body: {}
67
+ body: utils_1.Utils.payloadFilter({})
68
68
  });
69
69
  }
70
70
  /**
@@ -80,7 +80,7 @@ class CommissionsAPI extends core_1.Core {
80
80
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates'),
81
81
  headers: {},
82
82
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
83
- body: {}
83
+ body: utils_1.Utils.payloadFilter({})
84
84
  });
85
85
  }
86
86
  /**
@@ -95,36 +95,36 @@ class CommissionsAPI extends core_1.Core {
95
95
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions'),
96
96
  headers: {},
97
97
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
98
- body: {}
98
+ body: utils_1.Utils.payloadFilter({})
99
99
  });
100
100
  }
101
101
  /**
102
102
  * Ajoute une commission.
103
- * @param postCommissionRequest
103
+ * @param commission
104
104
  */
105
- async postCommission(postCommissionRequest) {
105
+ async postCommission(commission) {
106
106
  const pathVariable = {};
107
107
  return this.request({
108
108
  method: 'POST',
109
109
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions'),
110
110
  headers: {},
111
111
  params: {},
112
- body: { 'type': postCommissionRequest?.type, 'libelle': postCommissionRequest?.libelle }
112
+ body: utils_1.Utils.payloadFilter({ 'id': commission?.id, 'type': commission?.type, 'libelle': commission?.libelle })
113
113
  });
114
114
  }
115
115
  /**
116
116
  * Ajout d'une date de passage en commission.
117
117
  * @param commissionId Identifiant unique de la commission
118
- * @param postCommissionDateRequest
118
+ * @param passageCommission
119
119
  */
120
- async postCommissionDate(commissionId, postCommissionDateRequest) {
120
+ async postCommissionDate(commissionId, passageCommission) {
121
121
  const pathVariable = { 'commission_id': (new String(commissionId)).toString() };
122
122
  return this.request({
123
123
  method: 'POST',
124
124
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates'),
125
125
  headers: {},
126
126
  params: {},
127
- body: { 'libelle': postCommissionDateRequest?.libelle, 'type': postCommissionDateRequest?.type, 'date_de_debut': postCommissionDateRequest?.date_de_debut, 'date_de_fin': postCommissionDateRequest?.date_de_fin }
127
+ body: utils_1.Utils.payloadFilter({ 'id': passageCommission?.id, 'date_debut': passageCommission?.date_debut ? utils_1.Utils.formatDate(passageCommission?.date_debut) : undefined, 'date_fin': passageCommission?.date_fin ? utils_1.Utils.formatDate(passageCommission?.date_fin) : undefined, 'type': passageCommission?.type, 'libelle': passageCommission?.libelle })
128
128
  });
129
129
  }
130
130
  /**
@@ -140,7 +140,7 @@ class CommissionsAPI extends core_1.Core {
140
140
  endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates/{date_id}/ordre_du_jour'),
141
141
  headers: {},
142
142
  params: {},
143
- body: { 'dossier_id': postCommissionDateDossierRequest?.dossier_id }
143
+ body: utils_1.Utils.payloadFilter({ 'dossier_id': postCommissionDateDossierRequest?.dossier_id })
144
144
  });
145
145
  }
146
146
  }
@@ -3,8 +3,6 @@ import type { AxiosResponse } from "axios";
3
3
  import { Client } from "../client";
4
4
  import { Collection } from "../collection";
5
5
  import { Dossier } from '../model/Dossier';
6
- import { PostDossierRequest } from '../model/PostDossierRequest';
7
- import { UpdateDossierWorkflowsDetailsRequest } from '../model/UpdateDossierWorkflowsDetailsRequest';
8
6
  import { Workflow } from '../model/Workflow';
9
7
  import { Tag } from '../model/Tag';
10
8
  import { PieceJointe } from '../model/PieceJointe';
@@ -71,14 +69,14 @@ export declare class DossiersAPI extends Core {
71
69
  patchDossier(dossierId: string, dossier?: Dossier): Promise<AxiosResponse<Dossier>>;
72
70
  /**
73
71
  * Création d'un nouveau dossier.
74
- * @param postDossierRequest
72
+ * @param dossier
75
73
  */
76
- postDossier(postDossierRequest?: PostDossierRequest): Promise<AxiosResponse<Dossier>>;
74
+ postDossier(dossier?: Dossier): Promise<AxiosResponse<Dossier>>;
77
75
  /**
78
76
  * Mise à jour d'un workflow.
79
77
  * @param dossierId Identifiant unique du Dossier
80
78
  * @param workflowId Identifiant unique du Workflow
81
- * @param updateDossierWorkflowsDetailsRequest
79
+ * @param workflow
82
80
  */
83
- updateDossierWorkflowsDetails(dossierId: string, workflowId: string, updateDossierWorkflowsDetailsRequest?: UpdateDossierWorkflowsDetailsRequest): Promise<AxiosResponse<Workflow>>;
81
+ updateDossierWorkflowsDetails(dossierId: string, workflowId: string, workflow?: Workflow): Promise<AxiosResponse<Workflow>>;
84
82
  }
@@ -18,7 +18,7 @@ class DossiersAPI extends core_1.Core {
18
18
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}'),
19
19
  headers: {},
20
20
  params: {},
21
- body: {}
21
+ body: utils_1.Utils.payloadFilter({})
22
22
  });
23
23
  }
24
24
  /**
@@ -33,7 +33,7 @@ class DossiersAPI extends core_1.Core {
33
33
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/workflows/{workflow_id}'),
34
34
  headers: {},
35
35
  params: {},
36
- body: {}
36
+ body: utils_1.Utils.payloadFilter({})
37
37
  });
38
38
  }
39
39
  /**
@@ -49,7 +49,7 @@ class DossiersAPI extends core_1.Core {
49
49
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/contacts'),
50
50
  headers: {},
51
51
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
52
- body: {}
52
+ body: utils_1.Utils.payloadFilter({})
53
53
  });
54
54
  }
55
55
  /**
@@ -65,7 +65,7 @@ class DossiersAPI extends core_1.Core {
65
65
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/documents'),
66
66
  headers: {},
67
67
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
68
- body: {}
68
+ body: utils_1.Utils.payloadFilter({})
69
69
  });
70
70
  }
71
71
  /**
@@ -81,7 +81,7 @@ class DossiersAPI extends core_1.Core {
81
81
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/tags'),
82
82
  headers: {},
83
83
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
84
- body: {}
84
+ body: utils_1.Utils.payloadFilter({})
85
85
  });
86
86
  }
87
87
  /**
@@ -98,7 +98,7 @@ class DossiersAPI extends core_1.Core {
98
98
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/workflows/{workflow_id}/documents'),
99
99
  headers: {},
100
100
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
101
- body: {}
101
+ body: utils_1.Utils.payloadFilter({})
102
102
  });
103
103
  }
104
104
  /**
@@ -114,7 +114,7 @@ class DossiersAPI extends core_1.Core {
114
114
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/workflows'),
115
115
  headers: {},
116
116
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
117
- body: {}
117
+ body: utils_1.Utils.payloadFilter({})
118
118
  });
119
119
  }
120
120
  /**
@@ -129,7 +129,7 @@ class DossiersAPI extends core_1.Core {
129
129
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers'),
130
130
  headers: {},
131
131
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
132
- body: {}
132
+ body: utils_1.Utils.payloadFilter({})
133
133
  });
134
134
  }
135
135
  /**
@@ -144,37 +144,37 @@ class DossiersAPI extends core_1.Core {
144
144
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}'),
145
145
  headers: {},
146
146
  params: {},
147
- body: { 'id': dossier?.id, 'type': dossier?.type, 'description': dossier?.description, 'date_de_creation': dossier?.date_de_creation, 'createur': dossier?.createur, 'application_utilisee_nom': dossier?.application_utilisee_nom, 'statut': dossier?.statut, 'objet': dossier?.objet, 'pei': dossier?.pei, 'erp': dossier?.erp, 'workflow_actif': dossier?.workflow_actif }
147
+ body: utils_1.Utils.payloadFilter({ 'id': dossier?.id, 'type': dossier?.type, 'description': dossier?.description, 'date_de_creation': dossier?.date_de_creation ? utils_1.Utils.formatDate(dossier?.date_de_creation) : undefined, 'createur': dossier?.createur, 'application_utilisee_nom': dossier?.application_utilisee_nom, 'statut': dossier?.statut, 'objet': dossier?.objet, 'pei': dossier?.pei, 'erp': dossier?.erp })
148
148
  });
149
149
  }
150
150
  /**
151
151
  * Création d'un nouveau dossier.
152
- * @param postDossierRequest
152
+ * @param dossier
153
153
  */
154
- async postDossier(postDossierRequest) {
154
+ async postDossier(dossier) {
155
155
  const pathVariable = {};
156
156
  return this.request({
157
157
  method: 'POST',
158
158
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers'),
159
159
  headers: {},
160
160
  params: {},
161
- body: { 'titre': postDossierRequest?.titre, 'description': postDossierRequest?.description, 'type': postDossierRequest?.type }
161
+ body: utils_1.Utils.payloadFilter({ 'id': dossier?.id, 'type': dossier?.type, 'description': dossier?.description, 'date_de_creation': dossier?.date_de_creation ? utils_1.Utils.formatDate(dossier?.date_de_creation) : undefined, 'createur': dossier?.createur, 'application_utilisee_nom': dossier?.application_utilisee_nom, 'statut': dossier?.statut, 'objet': dossier?.objet, 'pei': dossier?.pei, 'erp': dossier?.erp })
162
162
  });
163
163
  }
164
164
  /**
165
165
  * Mise à jour d'un workflow.
166
166
  * @param dossierId Identifiant unique du Dossier
167
167
  * @param workflowId Identifiant unique du Workflow
168
- * @param updateDossierWorkflowsDetailsRequest
168
+ * @param workflow
169
169
  */
170
- async updateDossierWorkflowsDetails(dossierId, workflowId, updateDossierWorkflowsDetailsRequest) {
170
+ async updateDossierWorkflowsDetails(dossierId, workflowId, workflow) {
171
171
  const pathVariable = { 'dossier_id': (new String(dossierId)).toString(), 'workflow_id': (new String(workflowId)).toString() };
172
172
  return this.request({
173
173
  method: 'POST',
174
174
  endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/workflows/{workflow_id}'),
175
175
  headers: {},
176
176
  params: {},
177
- body: { 'est_valide': updateDossierWorkflowsDetailsRequest?.est_valide, 'passage_commission_id': updateDossierWorkflowsDetailsRequest?.passage_commission_id, 'avis_favorable': updateDossierWorkflowsDetailsRequest?.avis_favorable, 'commission_id': updateDossierWorkflowsDetailsRequest?.commission_id, 'date_arrivee_secretariat': updateDossierWorkflowsDetailsRequest?.date_arrivee_secretariat, 'analyse_de_risque': updateDossierWorkflowsDetailsRequest?.analyse_de_risque, 'avis_rapporteur': updateDossierWorkflowsDetailsRequest?.avis_rapporteur, 'descriptif_effectifs': updateDossierWorkflowsDetailsRequest?.descriptif_effectifs, 'facteur_dangerosite': updateDossierWorkflowsDetailsRequest?.facteur_dangerosite, 'derogations': updateDossierWorkflowsDetailsRequest?.derogations, 'prescriptions': updateDossierWorkflowsDetailsRequest?.prescriptions, 'mesures_compensatoires': updateDossierWorkflowsDetailsRequest?.mesures_compensatoires, 'mesures_complementaires': updateDossierWorkflowsDetailsRequest?.mesures_complementaires, 'observations': updateDossierWorkflowsDetailsRequest?.observations, 'termine': updateDossierWorkflowsDetailsRequest?.termine }
177
+ body: utils_1.Utils.payloadFilter(workflow)
178
178
  });
179
179
  }
180
180
  }
package/lib/api/ERPAPI.js CHANGED
@@ -18,7 +18,7 @@ class ERPAPI extends core_1.Core {
18
18
  endpoint: utils_1.Utils.constructPath(pathVariable, '/erp/{erp_id}'),
19
19
  headers: {},
20
20
  params: {},
21
- body: {}
21
+ body: utils_1.Utils.payloadFilter({})
22
22
  });
23
23
  }
24
24
  /**
@@ -33,7 +33,7 @@ class ERPAPI extends core_1.Core {
33
33
  endpoint: utils_1.Utils.constructPath(pathVariable, '/erp'),
34
34
  headers: {},
35
35
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
36
- body: {}
36
+ body: utils_1.Utils.payloadFilter({})
37
37
  });
38
38
  }
39
39
  /**
@@ -49,7 +49,7 @@ class ERPAPI extends core_1.Core {
49
49
  endpoint: utils_1.Utils.constructPath(pathVariable, '/erp/{erp_id}/contacts'),
50
50
  headers: {},
51
51
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
52
- body: {}
52
+ body: utils_1.Utils.payloadFilter({})
53
53
  });
54
54
  }
55
55
  /**
@@ -65,7 +65,7 @@ class ERPAPI extends core_1.Core {
65
65
  endpoint: utils_1.Utils.constructPath(pathVariable, '/erp/{erp_id}/documents'),
66
66
  headers: {},
67
67
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
68
- body: {}
68
+ body: utils_1.Utils.payloadFilter({})
69
69
  });
70
70
  }
71
71
  }
@@ -3,7 +3,6 @@ import type { AxiosResponse } from "axios";
3
3
  import { Client } from "../client";
4
4
  import { Collection } from "../collection";
5
5
  import { Evenement } from '../model/Evenement';
6
- import { PostEvenementRequest } from '../model/PostEvenementRequest';
7
6
  import { Utilisateur } from '../model/Utilisateur';
8
7
  export declare class EvenementsAPI extends Core {
9
8
  constructor(config: MetariscConfig, client?: Client);
@@ -35,7 +34,7 @@ export declare class EvenementsAPI extends Core {
35
34
  paginateEvenements(page?: number, perPage?: number, type?: string, period?: string): Collection<Evenement>;
36
35
  /**
37
36
  * TODO : Création d'un événement.
38
- * @param postEvenementRequest
37
+ * @param evenement
39
38
  */
40
- postEvenement(postEvenementRequest?: PostEvenementRequest): Promise<AxiosResponse<Evenement>>;
39
+ postEvenement(evenement?: Evenement): Promise<AxiosResponse<Evenement>>;
41
40
  }
@@ -18,7 +18,7 @@ class EvenementsAPI extends core_1.Core {
18
18
  endpoint: utils_1.Utils.constructPath(pathVariable, '/evenements/{evenement_id}'),
19
19
  headers: {},
20
20
  params: {},
21
- body: {}
21
+ body: utils_1.Utils.payloadFilter({})
22
22
  });
23
23
  }
24
24
  /**
@@ -33,7 +33,7 @@ class EvenementsAPI extends core_1.Core {
33
33
  endpoint: utils_1.Utils.constructPath(pathVariable, '/evenements/{evenement_id}'),
34
34
  headers: {},
35
35
  params: {},
36
- body: { 'id': evenement?.id, 'title': evenement?.title, 'type': evenement?.type, 'description': evenement?.description, 'date_debut': evenement?.date_debut, 'date_fin': evenement?.date_fin }
36
+ body: utils_1.Utils.payloadFilter({ 'id': evenement?.id, 'title': evenement?.title, 'type': evenement?.type, 'description': evenement?.description, 'date_debut': evenement?.date_debut ? utils_1.Utils.formatDate(evenement?.date_debut) : undefined, 'date_fin': evenement?.date_fin ? utils_1.Utils.formatDate(evenement?.date_fin) : undefined })
37
37
  });
38
38
  }
39
39
  /**
@@ -49,7 +49,7 @@ class EvenementsAPI extends core_1.Core {
49
49
  endpoint: utils_1.Utils.constructPath(pathVariable, '/evenements/{evenement_id}/utilisateurs'),
50
50
  headers: {},
51
51
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
52
- body: {}
52
+ body: utils_1.Utils.payloadFilter({})
53
53
  });
54
54
  }
55
55
  /**
@@ -66,21 +66,21 @@ class EvenementsAPI extends core_1.Core {
66
66
  endpoint: utils_1.Utils.constructPath(pathVariable, '/evenements'),
67
67
  headers: {},
68
68
  params: { 'page': page?.toString(), 'per_page': perPage?.toString(), 'type': type, 'period': period },
69
- body: {}
69
+ body: utils_1.Utils.payloadFilter({})
70
70
  });
71
71
  }
72
72
  /**
73
73
  * TODO : Création d'un événement.
74
- * @param postEvenementRequest
74
+ * @param evenement
75
75
  */
76
- async postEvenement(postEvenementRequest) {
76
+ async postEvenement(evenement) {
77
77
  const pathVariable = {};
78
78
  return this.request({
79
79
  method: 'POST',
80
80
  endpoint: utils_1.Utils.constructPath(pathVariable, '/evenements'),
81
81
  headers: {},
82
82
  params: {},
83
- body: { 'title': postEvenementRequest?.title, 'type': postEvenementRequest?.type, 'description': postEvenementRequest?.description, 'date_debut': postEvenementRequest?.date_debut, 'date_fin': postEvenementRequest?.date_fin }
83
+ body: utils_1.Utils.payloadFilter({ 'id': evenement?.id, 'title': evenement?.title, 'type': evenement?.type, 'description': evenement?.description, 'date_debut': evenement?.date_debut ? utils_1.Utils.formatDate(evenement?.date_debut) : undefined, 'date_fin': evenement?.date_fin ? utils_1.Utils.formatDate(evenement?.date_fin) : undefined })
84
84
  });
85
85
  }
86
86
  }
@@ -3,7 +3,6 @@ import type { AxiosResponse } from "axios";
3
3
  import { Client } from "../client";
4
4
  import { Collection } from "../collection";
5
5
  import { FeedMessage } from '../model/FeedMessage';
6
- import { PostMessageRequest } from '../model/PostMessageRequest';
7
6
  export declare class FeedAPI extends Core {
8
7
  constructor(config: MetariscConfig, client?: Client);
9
8
  /**
@@ -14,7 +13,7 @@ export declare class FeedAPI extends Core {
14
13
  paginateFeedMessages(page?: number, perPage?: number): Collection<FeedMessage>;
15
14
  /**
16
15
  * Ajoute un message dans le feed général.
17
- * @param postMessageRequest
16
+ * @param feedMessage
18
17
  */
19
- postMessage(postMessageRequest?: PostMessageRequest): Promise<AxiosResponse<FeedMessage>>;
18
+ postMessage(feedMessage?: FeedMessage): Promise<AxiosResponse<FeedMessage>>;
20
19
  }
@@ -19,21 +19,21 @@ class FeedAPI extends core_1.Core {
19
19
  endpoint: utils_1.Utils.constructPath(pathVariable, '/feed'),
20
20
  headers: {},
21
21
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
22
- body: {}
22
+ body: utils_1.Utils.payloadFilter({})
23
23
  });
24
24
  }
25
25
  /**
26
26
  * Ajoute un message dans le feed général.
27
- * @param postMessageRequest
27
+ * @param feedMessage
28
28
  */
29
- async postMessage(postMessageRequest) {
29
+ async postMessage(feedMessage) {
30
30
  const pathVariable = {};
31
31
  return this.request({
32
32
  method: 'POST',
33
33
  endpoint: utils_1.Utils.constructPath(pathVariable, '/feed'),
34
34
  headers: {},
35
35
  params: {},
36
- body: { 'type': postMessageRequest?.type, 'titre': postMessageRequest?.titre, 'texte': postMessageRequest?.texte }
36
+ body: utils_1.Utils.payloadFilter(feedMessage)
37
37
  });
38
38
  }
39
39
  }
package/lib/api/MoiAPI.js CHANGED
@@ -17,7 +17,7 @@ class MoiAPI extends core_1.Core {
17
17
  endpoint: utils_1.Utils.constructPath(pathVariable, '/@moi'),
18
18
  headers: {},
19
19
  params: {},
20
- body: {}
20
+ body: utils_1.Utils.payloadFilter({})
21
21
  });
22
22
  }
23
23
  }
@@ -3,7 +3,6 @@ import type { AxiosResponse } from "axios";
3
3
  import { Client } from "../client";
4
4
  import { Collection } from "../collection";
5
5
  import { Notification } from '../model/Notification';
6
- import { PostNotificationRequest } from '../model/PostNotificationRequest';
7
6
  export declare class NotificationsAPI extends Core {
8
7
  constructor(config: MetariscConfig, client?: Client);
9
8
  /**
@@ -24,7 +23,7 @@ export declare class NotificationsAPI extends Core {
24
23
  paginateNotifications(page?: number, perPage?: number): Collection<Notification>;
25
24
  /**
26
25
  * Création d'une notification.
27
- * @param postNotificationRequest
26
+ * @param notification
28
27
  */
29
- postNotification(postNotificationRequest?: PostNotificationRequest): Promise<AxiosResponse<Notification>>;
28
+ postNotification(notification?: Notification): Promise<AxiosResponse<Notification>>;
30
29
  }
@@ -18,7 +18,7 @@ class NotificationsAPI extends core_1.Core {
18
18
  endpoint: utils_1.Utils.constructPath(pathVariable, '/notifications/{notification_id}'),
19
19
  headers: {},
20
20
  params: {},
21
- body: {}
21
+ body: utils_1.Utils.payloadFilter({})
22
22
  });
23
23
  }
24
24
  /**
@@ -32,7 +32,7 @@ class NotificationsAPI extends core_1.Core {
32
32
  endpoint: utils_1.Utils.constructPath(pathVariable, '/notifications/{notification_id}'),
33
33
  headers: {},
34
34
  params: {},
35
- body: {}
35
+ body: utils_1.Utils.payloadFilter({})
36
36
  });
37
37
  }
38
38
  /**
@@ -47,21 +47,21 @@ class NotificationsAPI extends core_1.Core {
47
47
  endpoint: utils_1.Utils.constructPath(pathVariable, '/notifications'),
48
48
  headers: {},
49
49
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
50
- body: {}
50
+ body: utils_1.Utils.payloadFilter({})
51
51
  });
52
52
  }
53
53
  /**
54
54
  * Création d'une notification.
55
- * @param postNotificationRequest
55
+ * @param notification
56
56
  */
57
- async postNotification(postNotificationRequest) {
57
+ async postNotification(notification) {
58
58
  const pathVariable = {};
59
59
  return this.request({
60
60
  method: 'POST',
61
61
  endpoint: utils_1.Utils.constructPath(pathVariable, '/notifications'),
62
62
  headers: {},
63
63
  params: {},
64
- body: { 'title': postNotificationRequest?.title, 'message': postNotificationRequest?.message, 'contexte': postNotificationRequest?.contexte, 'utilisateur_id': postNotificationRequest?.utilisateur_id }
64
+ body: utils_1.Utils.payloadFilter({ 'id': notification?.id, 'title': notification?.title, 'message': notification?.message, 'contexte': notification?.contexte, 'date_creation': notification?.date_creation ? utils_1.Utils.formatDate(notification?.date_creation) : undefined, 'date_de_lecture': notification?.date_de_lecture ? utils_1.Utils.formatDate(notification?.date_de_lecture) : undefined, 'utilisateur_id': notification?.utilisateur_id, 'utilisateur': notification?.utilisateur })
65
65
  });
66
66
  }
67
67
  }
@@ -19,7 +19,7 @@ class OrganisationsAPI extends core_1.Core {
19
19
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations/{org_id}/membres'),
20
20
  headers: {},
21
21
  params: {},
22
- body: { 'utilisateur_id': addOrganisationMembresRequest?.utilisateur_id }
22
+ body: utils_1.Utils.payloadFilter({ 'utilisateur_id': addOrganisationMembresRequest?.utilisateur_id })
23
23
  });
24
24
  }
25
25
  /**
@@ -33,7 +33,7 @@ class OrganisationsAPI extends core_1.Core {
33
33
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations/{org_id}'),
34
34
  headers: {},
35
35
  params: {},
36
- body: {}
36
+ body: utils_1.Utils.payloadFilter({})
37
37
  });
38
38
  }
39
39
  /**
@@ -47,7 +47,7 @@ class OrganisationsAPI extends core_1.Core {
47
47
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations/{org_id}/regles-deci'),
48
48
  headers: {},
49
49
  params: {},
50
- body: {}
50
+ body: utils_1.Utils.payloadFilter({})
51
51
  });
52
52
  }
53
53
  /**
@@ -61,7 +61,7 @@ class OrganisationsAPI extends core_1.Core {
61
61
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations/{org_id}/dossiers-workflows-suites'),
62
62
  headers: {},
63
63
  params: {},
64
- body: {}
64
+ body: utils_1.Utils.payloadFilter({})
65
65
  });
66
66
  }
67
67
  /**
@@ -77,7 +77,7 @@ class OrganisationsAPI extends core_1.Core {
77
77
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations/{org_id}/geoservices'),
78
78
  headers: {},
79
79
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
80
- body: {}
80
+ body: utils_1.Utils.payloadFilter({})
81
81
  });
82
82
  }
83
83
  /**
@@ -93,7 +93,7 @@ class OrganisationsAPI extends core_1.Core {
93
93
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations/{org_id}/membres'),
94
94
  headers: {},
95
95
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
96
- body: {}
96
+ body: utils_1.Utils.payloadFilter({})
97
97
  });
98
98
  }
99
99
  /**
@@ -108,7 +108,7 @@ class OrganisationsAPI extends core_1.Core {
108
108
  endpoint: utils_1.Utils.constructPath(pathVariable, '/organisations'),
109
109
  headers: {},
110
110
  params: { 'page': page?.toString(), 'per_page': perPage?.toString() },
111
- body: {}
111
+ body: utils_1.Utils.payloadFilter({})
112
112
  });
113
113
  }
114
114
  }
@@ -3,7 +3,6 @@ import type { AxiosResponse } from "axios";
3
3
  import { Client } from "../client";
4
4
  import { Collection } from "../collection";
5
5
  import { PEI } from '../model/PEI';
6
- import { PostPeiRequest } from '../model/PostPeiRequest';
7
6
  import { Contact } from '../model/Contact';
8
7
  import { DescriptifTechniqueDECI } from '../model/DescriptifTechniqueDECI';
9
8
  import { PieceJointe } from '../model/PieceJointe';
@@ -44,7 +43,7 @@ export declare class PEIAPI extends Core {
44
43
  paginatePeiPiecesJointes(peiId: string, page?: number, perPage?: number): Collection<PieceJointe>;
45
44
  /**
46
45
  * Ajout d'un PEI.
47
- * @param postPeiRequest
46
+ * @param PEI
48
47
  */
49
- postPei(postPeiRequest?: PostPeiRequest): Promise<AxiosResponse<PEI>>;
48
+ postPei(PEI?: PEI): Promise<AxiosResponse<PEI>>;
50
49
  }