@metarisc/metarisc-js 0.0.1-alpha.110 → 0.0.1-alpha.112
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/AnomaliesAPI.js +8 -0
- package/lib/api/CommissionsAPI.js +22 -0
- package/lib/api/CommissionsMembresAPI.js +8 -0
- package/lib/api/ContactsAPI.js +8 -0
- package/lib/api/ControlesPEIAPI.js +6 -0
- package/lib/api/DatesPassageCommissionAPI.js +8 -0
- package/lib/api/DocumentsAPI.js +8 -0
- package/lib/api/DossiersAPI.d.ts +12 -1
- package/lib/api/DossiersAPI.js +101 -2
- package/lib/api/DossiersAffectationsAPI.js +4 -0
- package/lib/api/DossiersRattachementsAPI.d.ts +15 -0
- package/lib/api/DossiersRattachementsAPI.js +54 -0
- package/lib/api/ERPAPI.d.ts +5 -0
- package/lib/api/ERPAPI.js +71 -0
- package/lib/api/EnveloppesAPI.js +10 -0
- package/lib/api/EvenementsAPI.js +10 -0
- package/lib/api/FeedAPI.js +8 -0
- package/lib/api/HealthcheckAPI.js +2 -0
- package/lib/api/MainsCourantesAPI.js +14 -0
- package/lib/api/MainsCourantesParticipantsAPI.js +2 -0
- package/lib/api/MoiAPI.js +2 -0
- package/lib/api/NotificationsAPI.js +10 -0
- package/lib/api/OrdresDuJourAPI.js +10 -0
- package/lib/api/OrganisationsAPI.js +24 -0
- package/lib/api/PEIAPI.js +28 -0
- package/lib/api/PermissionsAPI.js +2 -0
- package/lib/api/PingAPI.js +2 -0
- package/lib/api/PrescriptionsAPI.js +12 -0
- package/lib/api/SearchAPI.js +2 -0
- package/lib/api/SitesGeographiquesAPI.js +10 -0
- package/lib/api/SupportsReglementairesAPI.js +10 -0
- package/lib/api/TourneesDECIAPI.js +18 -0
- package/lib/api/UtilisateursAPI.js +18 -0
- package/lib/api/WorkflowsAPI.js +4 -0
- package/lib/metarisc.d.ts +1 -0
- package/lib/metarisc.js +1 -0
- package/lib/model/DossierBase.d.ts +3 -1
- package/lib/model/DossierBaseRattachement.d.ts +9 -0
- package/lib/model/DossierBaseRattachement.js +7 -0
- package/lib/model/DossierEnhanced.d.ts +60 -0
- package/lib/model/DossierEnhanced.js +67 -0
- package/lib/resources.d.ts +1 -0
- package/lib/resources.js +3 -1
- package/package.json +1 -1
- package/src/api/AnomaliesAPI.ts +4 -0
- package/src/api/CommissionsAPI.ts +11 -0
- package/src/api/CommissionsMembresAPI.ts +4 -0
- package/src/api/ContactsAPI.ts +4 -0
- package/src/api/ControlesPEIAPI.ts +3 -0
- package/src/api/DatesPassageCommissionAPI.ts +4 -0
- package/src/api/DocumentsAPI.ts +4 -0
- package/src/api/DossiersAPI.ts +82 -2
- package/src/api/DossiersAffectationsAPI.ts +2 -0
- package/src/api/DossiersRattachementsAPI.ts +62 -0
- package/src/api/ERPAPI.ts +58 -0
- package/src/api/EnveloppesAPI.ts +5 -0
- package/src/api/EvenementsAPI.ts +5 -0
- package/src/api/FeedAPI.ts +4 -0
- package/src/api/HealthcheckAPI.ts +1 -0
- package/src/api/MainsCourantesAPI.ts +7 -0
- package/src/api/MainsCourantesParticipantsAPI.ts +1 -0
- package/src/api/MoiAPI.ts +1 -0
- package/src/api/NotificationsAPI.ts +5 -0
- package/src/api/OrdresDuJourAPI.ts +5 -0
- package/src/api/OrganisationsAPI.ts +12 -0
- package/src/api/PEIAPI.ts +14 -0
- package/src/api/PermissionsAPI.ts +1 -0
- package/src/api/PingAPI.ts +1 -0
- package/src/api/PrescriptionsAPI.ts +6 -0
- package/src/api/SearchAPI.ts +1 -0
- package/src/api/SitesGeographiquesAPI.ts +5 -0
- package/src/api/SupportsReglementairesAPI.ts +5 -0
- package/src/api/TourneesDECIAPI.ts +9 -0
- package/src/api/UtilisateursAPI.ts +9 -0
- package/src/api/WorkflowsAPI.ts +2 -0
- package/src/metarisc.ts +2 -0
- package/src/model/DossierBase.ts +3 -1
- package/src/model/DossierBaseRattachement.ts +12 -0
- package/src/model/DossierEnhanced.ts +69 -0
- package/src/resources.ts +2 -0
package/lib/api/AnomaliesAPI.js
CHANGED
|
@@ -17,6 +17,8 @@ class AnomaliesAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies/{anomalie_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class AnomaliesAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies/{anomalie_id}'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -50,6 +54,8 @@ class AnomaliesAPI extends core_1.Core {
|
|
|
50
54
|
'code': code === undefined ? undefined : (new String(code)).toString()
|
|
51
55
|
}),
|
|
52
56
|
transformResponse: [(data) => {
|
|
57
|
+
if (!data)
|
|
58
|
+
return data;
|
|
53
59
|
const parsedData = JSON.parse(data);
|
|
54
60
|
return parsedData;
|
|
55
61
|
}]
|
|
@@ -64,6 +70,8 @@ class AnomaliesAPI extends core_1.Core {
|
|
|
64
70
|
method: 'POST',
|
|
65
71
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/anomalies'),
|
|
66
72
|
transformResponse: [(data) => {
|
|
73
|
+
if (!data)
|
|
74
|
+
return data;
|
|
67
75
|
const parsedData = JSON.parse(data);
|
|
68
76
|
return parsedData;
|
|
69
77
|
}],
|
|
@@ -17,6 +17,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
17
17
|
method: 'GET',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/preferences'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -49,6 +53,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
49
53
|
'type': type === undefined ? undefined : (new String(type)).toString()
|
|
50
54
|
}),
|
|
51
55
|
transformResponse: [(data) => {
|
|
56
|
+
if (!data)
|
|
57
|
+
return data;
|
|
52
58
|
const parsedData = JSON.parse(data);
|
|
53
59
|
return parsedData;
|
|
54
60
|
}]
|
|
@@ -67,6 +73,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
67
73
|
'type': type === undefined ? undefined : (new String(type)).toString()
|
|
68
74
|
}),
|
|
69
75
|
transformResponse: [(data) => {
|
|
76
|
+
if (!data)
|
|
77
|
+
return data;
|
|
70
78
|
const parsedData = JSON.parse(data);
|
|
71
79
|
return parsedData;
|
|
72
80
|
}]
|
|
@@ -84,6 +92,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
84
92
|
'commission': commission === undefined ? undefined : (new String(commission)).toString()
|
|
85
93
|
}),
|
|
86
94
|
transformResponse: [(data) => {
|
|
95
|
+
if (!data)
|
|
96
|
+
return data;
|
|
87
97
|
const parsedData = JSON.parse(data);
|
|
88
98
|
return parsedData;
|
|
89
99
|
}]
|
|
@@ -98,6 +108,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
98
108
|
method: 'PATCH',
|
|
99
109
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}'),
|
|
100
110
|
transformResponse: [(data) => {
|
|
111
|
+
if (!data)
|
|
112
|
+
return data;
|
|
101
113
|
const parsedData = JSON.parse(data);
|
|
102
114
|
return parsedData;
|
|
103
115
|
}],
|
|
@@ -113,6 +125,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
113
125
|
method: 'PATCH',
|
|
114
126
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates/{passage_id}'),
|
|
115
127
|
transformResponse: [(data) => {
|
|
128
|
+
if (!data)
|
|
129
|
+
return data;
|
|
116
130
|
const parsedData = JSON.parse(data);
|
|
117
131
|
return parsedData;
|
|
118
132
|
}],
|
|
@@ -128,6 +142,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
128
142
|
method: 'POST',
|
|
129
143
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions'),
|
|
130
144
|
transformResponse: [(data) => {
|
|
145
|
+
if (!data)
|
|
146
|
+
return data;
|
|
131
147
|
const parsedData = JSON.parse(data);
|
|
132
148
|
return parsedData;
|
|
133
149
|
}],
|
|
@@ -143,6 +159,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
143
159
|
method: 'POST',
|
|
144
160
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/dates'),
|
|
145
161
|
transformResponse: [(data) => {
|
|
162
|
+
if (!data)
|
|
163
|
+
return data;
|
|
146
164
|
const parsedData = JSON.parse(data);
|
|
147
165
|
return parsedData;
|
|
148
166
|
}],
|
|
@@ -158,6 +176,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
158
176
|
method: 'POST',
|
|
159
177
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/membres'),
|
|
160
178
|
transformResponse: [(data) => {
|
|
179
|
+
if (!data)
|
|
180
|
+
return data;
|
|
161
181
|
const parsedData = JSON.parse(data);
|
|
162
182
|
return parsedData;
|
|
163
183
|
}],
|
|
@@ -173,6 +193,8 @@ class CommissionsAPI extends core_1.Core {
|
|
|
173
193
|
method: 'POST',
|
|
174
194
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions/{commission_id}/preferences'),
|
|
175
195
|
transformResponse: [(data) => {
|
|
196
|
+
if (!data)
|
|
197
|
+
return data;
|
|
176
198
|
const parsedData = JSON.parse(data);
|
|
177
199
|
return parsedData;
|
|
178
200
|
}],
|
|
@@ -17,6 +17,8 @@ class CommissionsMembresAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions_membres/{membre_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class CommissionsMembresAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions_membres/{membre_id}'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -45,6 +49,8 @@ class CommissionsMembresAPI extends core_1.Core {
|
|
|
45
49
|
method: 'GET',
|
|
46
50
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions_membres'),
|
|
47
51
|
transformResponse: [(data) => {
|
|
52
|
+
if (!data)
|
|
53
|
+
return data;
|
|
48
54
|
const parsedData = JSON.parse(data);
|
|
49
55
|
return parsedData;
|
|
50
56
|
}]
|
|
@@ -59,6 +65,8 @@ class CommissionsMembresAPI extends core_1.Core {
|
|
|
59
65
|
method: 'POST',
|
|
60
66
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/commissions_membres/{membre_id}'),
|
|
61
67
|
transformResponse: [(data) => {
|
|
68
|
+
if (!data)
|
|
69
|
+
return data;
|
|
62
70
|
const parsedData = JSON.parse(data);
|
|
63
71
|
return parsedData;
|
|
64
72
|
}],
|
package/lib/api/ContactsAPI.js
CHANGED
|
@@ -17,6 +17,8 @@ class ContactsAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/contacts/{contact_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class ContactsAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/contacts/{contact_id}'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -45,6 +49,8 @@ class ContactsAPI extends core_1.Core {
|
|
|
45
49
|
method: 'GET',
|
|
46
50
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/contacts'),
|
|
47
51
|
transformResponse: [(data) => {
|
|
52
|
+
if (!data)
|
|
53
|
+
return data;
|
|
48
54
|
const parsedData = JSON.parse(data);
|
|
49
55
|
return parsedData;
|
|
50
56
|
}]
|
|
@@ -59,6 +65,8 @@ class ContactsAPI extends core_1.Core {
|
|
|
59
65
|
method: 'POST',
|
|
60
66
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/contacts/{contact_id}'),
|
|
61
67
|
transformResponse: [(data) => {
|
|
68
|
+
if (!data)
|
|
69
|
+
return data;
|
|
62
70
|
const parsedData = JSON.parse(data);
|
|
63
71
|
return parsedData;
|
|
64
72
|
}],
|
|
@@ -17,6 +17,8 @@ class ControlesPEIAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/controles_pei/{pei_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class ControlesPEIAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/controles_pei/{pei_id}'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -45,6 +49,8 @@ class ControlesPEIAPI extends core_1.Core {
|
|
|
45
49
|
method: 'POST',
|
|
46
50
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/controles_pei/{pei_id}'),
|
|
47
51
|
transformResponse: [(data) => {
|
|
52
|
+
if (!data)
|
|
53
|
+
return data;
|
|
48
54
|
const parsedData = JSON.parse(data);
|
|
49
55
|
return parsedData;
|
|
50
56
|
}],
|
|
@@ -39,6 +39,8 @@ class DatesPassageCommissionAPI extends core_1.Core {
|
|
|
39
39
|
method: 'GET',
|
|
40
40
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dates_passage_commission/{date_id}'),
|
|
41
41
|
transformResponse: [(data) => {
|
|
42
|
+
if (!data)
|
|
43
|
+
return data;
|
|
42
44
|
const parsedData = JSON.parse(data);
|
|
43
45
|
return parsedData;
|
|
44
46
|
}]
|
|
@@ -53,6 +55,8 @@ class DatesPassageCommissionAPI extends core_1.Core {
|
|
|
53
55
|
method: 'GET',
|
|
54
56
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dates_passage_commission/{date_id}/ordre_du_jour'),
|
|
55
57
|
transformResponse: [(data) => {
|
|
58
|
+
if (!data)
|
|
59
|
+
return data;
|
|
56
60
|
const parsedData = JSON.parse(data);
|
|
57
61
|
return parsedData;
|
|
58
62
|
}]
|
|
@@ -67,6 +71,8 @@ class DatesPassageCommissionAPI extends core_1.Core {
|
|
|
67
71
|
method: 'POST',
|
|
68
72
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dates_passage_commission/{date_id}/ordre_du_jour'),
|
|
69
73
|
transformResponse: [(data) => {
|
|
74
|
+
if (!data)
|
|
75
|
+
return data;
|
|
70
76
|
const parsedData = JSON.parse(data);
|
|
71
77
|
if (parsedData && parsedData.dossier.createur?.roles) {
|
|
72
78
|
parsedData.dossier.createur.roles = new Set(parsedData.dossier.createur.roles);
|
|
@@ -100,6 +106,8 @@ class DatesPassageCommissionAPI extends core_1.Core {
|
|
|
100
106
|
method: 'POST',
|
|
101
107
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dates_passage_commission/{date_id}/reprogrammer'),
|
|
102
108
|
transformResponse: [(data) => {
|
|
109
|
+
if (!data)
|
|
110
|
+
return data;
|
|
103
111
|
const parsedData = JSON.parse(data);
|
|
104
112
|
return parsedData;
|
|
105
113
|
}],
|
package/lib/api/DocumentsAPI.js
CHANGED
|
@@ -17,6 +17,8 @@ class DocumentsAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/documents/{document_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class DocumentsAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/documents/{document_id}'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -45,6 +49,8 @@ class DocumentsAPI extends core_1.Core {
|
|
|
45
49
|
method: 'GET',
|
|
46
50
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/documents'),
|
|
47
51
|
transformResponse: [(data) => {
|
|
52
|
+
if (!data)
|
|
53
|
+
return data;
|
|
48
54
|
const parsedData = JSON.parse(data);
|
|
49
55
|
return parsedData;
|
|
50
56
|
}]
|
|
@@ -59,6 +65,8 @@ class DocumentsAPI extends core_1.Core {
|
|
|
59
65
|
method: 'POST',
|
|
60
66
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/documents/{document_id}'),
|
|
61
67
|
transformResponse: [(data) => {
|
|
68
|
+
if (!data)
|
|
69
|
+
return data;
|
|
62
70
|
const parsedData = JSON.parse(data);
|
|
63
71
|
return parsedData;
|
|
64
72
|
}],
|
package/lib/api/DossiersAPI.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ import { Contact } from '../model/Contact';
|
|
|
6
6
|
import { Derogation } from '../model/Derogation';
|
|
7
7
|
import { Dossier } from '../model/Dossier';
|
|
8
8
|
import { DossierAffectation } from '../model/DossierAffectation';
|
|
9
|
+
import { DossierBaseRattachement } from '../model/DossierBaseRattachement';
|
|
9
10
|
import { FilRougeMessage } from '../model/FilRougeMessage';
|
|
10
11
|
import { PieceJointe } from '../model/PieceJointe';
|
|
11
12
|
import { PrescriptionAnalyseDeRisque } from '../model/PrescriptionAnalyseDeRisque';
|
|
@@ -65,6 +66,12 @@ export declare class DossiersAPI extends Core {
|
|
|
65
66
|
* Récupération des détails du rapport de visite.
|
|
66
67
|
*/
|
|
67
68
|
getRapportVisiteDossier(dossierId: string): Promise<AxiosResponse<RapportVisite>>;
|
|
69
|
+
/**
|
|
70
|
+
* Liste des rattachements du dossier.
|
|
71
|
+
*/
|
|
72
|
+
getRattachementsDossier(dossierId: string): Promise<AxiosResponse<{
|
|
73
|
+
data: DossierBaseRattachement[];
|
|
74
|
+
}>>;
|
|
68
75
|
/**
|
|
69
76
|
* Récupération de la liste des tags d'un dossier.
|
|
70
77
|
*/
|
|
@@ -82,7 +89,7 @@ export declare class DossiersAPI extends Core {
|
|
|
82
89
|
/**
|
|
83
90
|
* Récupération de la liste des dossiers selon des critères de recherche.
|
|
84
91
|
*/
|
|
85
|
-
paginateDossiers(sort?: 'date_de_creation' | '-date_de_creation', objet?: string, erp?: string, pei?: string, type?: string | Array<string>, workflowActif?: 'analyse_de_risque' | 'validation' | 'arrivee_sis' | 'arrivee_sis_prev' | 'arrivee_secretariat_commission' | 'consultation_sis' | 'passage_commission' | 'relecture' | 'visite' | 'arrivee_secretariat' | 'workflow' | 'reception_de_travaux_en_attente', affecte?: string, enveloppe?: string, numeroUrba?: string): Collection<Dossier>;
|
|
92
|
+
paginateDossiers(sort?: 'date_de_creation' | '-date_de_creation', objet?: string, erp?: string, pei?: string, type?: string | Array<string>, workflowActif?: 'analyse_de_risque' | 'validation' | 'arrivee_sis' | 'arrivee_sis_prev' | 'arrivee_secretariat_commission' | 'consultation_sis' | 'passage_commission' | 'relecture' | 'visite' | 'arrivee_secretariat' | 'workflow' | 'reception_de_travaux_en_attente', affecte?: string, enveloppe?: string, numeroUrba?: string, estParent?: boolean): Collection<Dossier>;
|
|
86
93
|
/**
|
|
87
94
|
* Consulter l'espace d'échange pour le suivi du dossier.
|
|
88
95
|
*/
|
|
@@ -127,6 +134,10 @@ export declare class DossiersAPI extends Core {
|
|
|
127
134
|
* Mise à jour du rapport de visite en définissant les valeurs des paramètres transmis. Tous les paramètres non fournis resteront inchangés.
|
|
128
135
|
*/
|
|
129
136
|
postRapportVisiteDossier(dossierId: string, params: any): Promise<AxiosResponse<RapportVisite>>;
|
|
137
|
+
/**
|
|
138
|
+
* Ajoute un rattachement à un dossier. Vous pouvez rattacher plusieurs dossiers à un dossier.
|
|
139
|
+
*/
|
|
140
|
+
postRattachementsDossier(dossierId: string, params: any): Promise<AxiosResponse<DossierBaseRattachement>>;
|
|
130
141
|
/**
|
|
131
142
|
* Réorganiser les numéros d'ordre des prescriptions du rapport d'étude. Cela permet de mettre à jour simplement les numéros d'ordre des prescriptions du rapport d'étude.
|
|
132
143
|
*/
|
package/lib/api/DossiersAPI.js
CHANGED
|
@@ -17,6 +17,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/archiver'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
31
33
|
method: 'GET',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/affectations'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
return parsedData;
|
|
36
40
|
}]
|
|
@@ -45,6 +49,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
45
49
|
method: 'GET',
|
|
46
50
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/derogations'),
|
|
47
51
|
transformResponse: [(data) => {
|
|
52
|
+
if (!data)
|
|
53
|
+
return data;
|
|
48
54
|
const parsedData = JSON.parse(data);
|
|
49
55
|
return parsedData;
|
|
50
56
|
}]
|
|
@@ -59,6 +65,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
59
65
|
method: 'GET',
|
|
60
66
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}'),
|
|
61
67
|
transformResponse: [(data) => {
|
|
68
|
+
if (!data)
|
|
69
|
+
return data;
|
|
62
70
|
const parsedData = JSON.parse(data);
|
|
63
71
|
if (parsedData && parsedData.createur?.roles) {
|
|
64
72
|
parsedData.createur.roles = new Set(parsedData.createur.roles);
|
|
@@ -91,6 +99,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
91
99
|
method: 'GET',
|
|
92
100
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/essais'),
|
|
93
101
|
transformResponse: [(data) => {
|
|
102
|
+
if (!data)
|
|
103
|
+
return data;
|
|
94
104
|
const parsedData = JSON.parse(data);
|
|
95
105
|
return parsedData;
|
|
96
106
|
}]
|
|
@@ -116,6 +126,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
116
126
|
method: 'GET',
|
|
117
127
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/permissions'),
|
|
118
128
|
transformResponse: [(data) => {
|
|
129
|
+
if (!data)
|
|
130
|
+
return data;
|
|
119
131
|
const parsedData = JSON.parse(data);
|
|
120
132
|
return parsedData;
|
|
121
133
|
}]
|
|
@@ -130,6 +142,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
130
142
|
method: 'GET',
|
|
131
143
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_etude/prescriptions'),
|
|
132
144
|
transformResponse: [(data) => {
|
|
145
|
+
if (!data)
|
|
146
|
+
return data;
|
|
133
147
|
const parsedData = JSON.parse(data);
|
|
134
148
|
return parsedData;
|
|
135
149
|
}]
|
|
@@ -144,6 +158,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
144
158
|
method: 'GET',
|
|
145
159
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_etude'),
|
|
146
160
|
transformResponse: [(data) => {
|
|
161
|
+
if (!data)
|
|
162
|
+
return data;
|
|
147
163
|
const parsedData = JSON.parse(data);
|
|
148
164
|
if (parsedData && parsedData.analyse_risque?.activites_secondaire) {
|
|
149
165
|
parsedData.analyse_risque.activites_secondaire = new Set(parsedData.analyse_risque.activites_secondaire);
|
|
@@ -167,6 +183,24 @@ class DossiersAPI extends core_1.Core {
|
|
|
167
183
|
method: 'GET',
|
|
168
184
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_visite'),
|
|
169
185
|
transformResponse: [(data) => {
|
|
186
|
+
if (!data)
|
|
187
|
+
return data;
|
|
188
|
+
const parsedData = JSON.parse(data);
|
|
189
|
+
return parsedData;
|
|
190
|
+
}]
|
|
191
|
+
});
|
|
192
|
+
}
|
|
193
|
+
/**
|
|
194
|
+
* Liste des rattachements du dossier.
|
|
195
|
+
*/
|
|
196
|
+
getRattachementsDossier(dossierId) {
|
|
197
|
+
const pathVariable = { 'dossier_id': (new String(dossierId)).toString() };
|
|
198
|
+
return this.request({
|
|
199
|
+
method: 'GET',
|
|
200
|
+
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rattachements'),
|
|
201
|
+
transformResponse: [(data) => {
|
|
202
|
+
if (!data)
|
|
203
|
+
return data;
|
|
170
204
|
const parsedData = JSON.parse(data);
|
|
171
205
|
return parsedData;
|
|
172
206
|
}]
|
|
@@ -181,6 +215,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
181
215
|
method: 'GET',
|
|
182
216
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/tags'),
|
|
183
217
|
transformResponse: [(data) => {
|
|
218
|
+
if (!data)
|
|
219
|
+
return data;
|
|
184
220
|
const parsedData = JSON.parse(data);
|
|
185
221
|
return parsedData;
|
|
186
222
|
}]
|
|
@@ -195,6 +231,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
195
231
|
method: 'GET',
|
|
196
232
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/contacts'),
|
|
197
233
|
transformResponse: [(data) => {
|
|
234
|
+
if (!data)
|
|
235
|
+
return data;
|
|
198
236
|
const parsedData = JSON.parse(data);
|
|
199
237
|
return parsedData;
|
|
200
238
|
}]
|
|
@@ -209,6 +247,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
209
247
|
method: 'GET',
|
|
210
248
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/documents'),
|
|
211
249
|
transformResponse: [(data) => {
|
|
250
|
+
if (!data)
|
|
251
|
+
return data;
|
|
212
252
|
const parsedData = JSON.parse(data);
|
|
213
253
|
return parsedData;
|
|
214
254
|
}]
|
|
@@ -217,7 +257,7 @@ class DossiersAPI extends core_1.Core {
|
|
|
217
257
|
/**
|
|
218
258
|
* Récupération de la liste des dossiers selon des critères de recherche.
|
|
219
259
|
*/
|
|
220
|
-
paginateDossiers(sort, objet, erp, pei, type, workflowActif, affecte, enveloppe, numeroUrba) {
|
|
260
|
+
paginateDossiers(sort, objet, erp, pei, type, workflowActif, affecte, enveloppe, numeroUrba, estParent) {
|
|
221
261
|
const pathVariable = {};
|
|
222
262
|
return this.collect({
|
|
223
263
|
method: 'GET',
|
|
@@ -231,9 +271,12 @@ class DossiersAPI extends core_1.Core {
|
|
|
231
271
|
'workflow_actif': workflowActif === undefined ? undefined : (new String(workflowActif)).toString(),
|
|
232
272
|
'affecte': affecte === undefined ? undefined : (new String(affecte)).toString(),
|
|
233
273
|
'enveloppe': enveloppe === undefined ? undefined : (new String(enveloppe)).toString(),
|
|
234
|
-
'numero_urba': numeroUrba === undefined ? undefined : (new String(numeroUrba)).toString()
|
|
274
|
+
'numero_urba': numeroUrba === undefined ? undefined : (new String(numeroUrba)).toString(),
|
|
275
|
+
'est_parent': estParent === undefined ? undefined : (new String(estParent)).toString()
|
|
235
276
|
}),
|
|
236
277
|
transformResponse: [(data) => {
|
|
278
|
+
if (!data)
|
|
279
|
+
return data;
|
|
237
280
|
const parsedData = JSON.parse(data);
|
|
238
281
|
return parsedData;
|
|
239
282
|
}]
|
|
@@ -248,6 +291,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
248
291
|
method: 'GET',
|
|
249
292
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/fil_rouge'),
|
|
250
293
|
transformResponse: [(data) => {
|
|
294
|
+
if (!data)
|
|
295
|
+
return data;
|
|
251
296
|
const parsedData = JSON.parse(data);
|
|
252
297
|
return parsedData;
|
|
253
298
|
}]
|
|
@@ -262,6 +307,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
262
307
|
method: 'GET',
|
|
263
308
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/workflows'),
|
|
264
309
|
transformResponse: [(data) => {
|
|
310
|
+
if (!data)
|
|
311
|
+
return data;
|
|
265
312
|
const parsedData = JSON.parse(data);
|
|
266
313
|
return parsedData;
|
|
267
314
|
}]
|
|
@@ -276,6 +323,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
276
323
|
method: 'POST',
|
|
277
324
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/affectations'),
|
|
278
325
|
transformResponse: [(data) => {
|
|
326
|
+
if (!data)
|
|
327
|
+
return data;
|
|
279
328
|
const parsedData = JSON.parse(data);
|
|
280
329
|
if (parsedData && parsedData.utilisateur?.roles) {
|
|
281
330
|
parsedData.utilisateur.roles = new Set(parsedData.utilisateur.roles);
|
|
@@ -294,6 +343,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
294
343
|
method: 'POST',
|
|
295
344
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/contacts'),
|
|
296
345
|
transformResponse: [(data) => {
|
|
346
|
+
if (!data)
|
|
347
|
+
return data;
|
|
297
348
|
const parsedData = JSON.parse(data);
|
|
298
349
|
return parsedData;
|
|
299
350
|
}],
|
|
@@ -309,6 +360,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
309
360
|
method: 'POST',
|
|
310
361
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/derogations'),
|
|
311
362
|
transformResponse: [(data) => {
|
|
363
|
+
if (!data)
|
|
364
|
+
return data;
|
|
312
365
|
const parsedData = JSON.parse(data);
|
|
313
366
|
return parsedData;
|
|
314
367
|
}],
|
|
@@ -324,6 +377,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
324
377
|
method: 'POST',
|
|
325
378
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/documents'),
|
|
326
379
|
transformResponse: [(data) => {
|
|
380
|
+
if (!data)
|
|
381
|
+
return data;
|
|
327
382
|
const parsedData = JSON.parse(data);
|
|
328
383
|
return parsedData;
|
|
329
384
|
}],
|
|
@@ -339,6 +394,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
339
394
|
method: 'POST',
|
|
340
395
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}'),
|
|
341
396
|
transformResponse: [(data) => {
|
|
397
|
+
if (!data)
|
|
398
|
+
return data;
|
|
342
399
|
const parsedData = JSON.parse(data);
|
|
343
400
|
if (parsedData && parsedData.createur?.roles) {
|
|
344
401
|
parsedData.createur.roles = new Set(parsedData.createur.roles);
|
|
@@ -372,6 +429,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
372
429
|
method: 'POST',
|
|
373
430
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/fil_rouge'),
|
|
374
431
|
transformResponse: [(data) => {
|
|
432
|
+
if (!data)
|
|
433
|
+
return data;
|
|
375
434
|
const parsedData = JSON.parse(data);
|
|
376
435
|
if (parsedData && parsedData.auteur?.roles) {
|
|
377
436
|
parsedData.auteur.roles = new Set(parsedData.auteur.roles);
|
|
@@ -390,6 +449,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
390
449
|
method: 'POST',
|
|
391
450
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_etude/prescriptions'),
|
|
392
451
|
transformResponse: [(data) => {
|
|
452
|
+
if (!data)
|
|
453
|
+
return data;
|
|
393
454
|
const parsedData = JSON.parse(data);
|
|
394
455
|
return parsedData;
|
|
395
456
|
}],
|
|
@@ -405,6 +466,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
405
466
|
method: 'POST',
|
|
406
467
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_etude'),
|
|
407
468
|
transformResponse: [(data) => {
|
|
469
|
+
if (!data)
|
|
470
|
+
return data;
|
|
408
471
|
const parsedData = JSON.parse(data);
|
|
409
472
|
if (parsedData && parsedData.analyse_risque?.activites_secondaire) {
|
|
410
473
|
parsedData.analyse_risque.activites_secondaire = new Set(parsedData.analyse_risque.activites_secondaire);
|
|
@@ -429,7 +492,35 @@ class DossiersAPI extends core_1.Core {
|
|
|
429
492
|
method: 'POST',
|
|
430
493
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_visite'),
|
|
431
494
|
transformResponse: [(data) => {
|
|
495
|
+
if (!data)
|
|
496
|
+
return data;
|
|
497
|
+
const parsedData = JSON.parse(data);
|
|
498
|
+
return parsedData;
|
|
499
|
+
}],
|
|
500
|
+
body: utils_1.Utils.payloadFilter(params)
|
|
501
|
+
});
|
|
502
|
+
}
|
|
503
|
+
/**
|
|
504
|
+
* Ajoute un rattachement à un dossier. Vous pouvez rattacher plusieurs dossiers à un dossier.
|
|
505
|
+
*/
|
|
506
|
+
postRattachementsDossier(dossierId, params) {
|
|
507
|
+
const pathVariable = { 'dossier_id': (new String(dossierId)).toString() };
|
|
508
|
+
return this.request({
|
|
509
|
+
method: 'POST',
|
|
510
|
+
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rattachements'),
|
|
511
|
+
transformResponse: [(data) => {
|
|
512
|
+
if (!data)
|
|
513
|
+
return data;
|
|
432
514
|
const parsedData = JSON.parse(data);
|
|
515
|
+
if (parsedData && parsedData.dossier_enfant.createur?.roles) {
|
|
516
|
+
parsedData.dossier_enfant.createur.roles = new Set(parsedData.dossier_enfant.createur.roles);
|
|
517
|
+
}
|
|
518
|
+
if (parsedData && parsedData.dossier_enfant.modules) {
|
|
519
|
+
parsedData.dossier_enfant.modules = new Set(parsedData.dossier_enfant.modules);
|
|
520
|
+
}
|
|
521
|
+
if (parsedData && parsedData.dossier_enfant.workflows_actifs) {
|
|
522
|
+
parsedData.dossier_enfant.workflows_actifs = new Set(parsedData.dossier_enfant.workflows_actifs);
|
|
523
|
+
}
|
|
433
524
|
return parsedData;
|
|
434
525
|
}],
|
|
435
526
|
body: utils_1.Utils.payloadFilter(params)
|
|
@@ -444,6 +535,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
444
535
|
method: 'POST',
|
|
445
536
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/rapport_etude/prescriptions/reorganiser'),
|
|
446
537
|
transformResponse: [(data) => {
|
|
538
|
+
if (!data)
|
|
539
|
+
return data;
|
|
447
540
|
const parsedData = JSON.parse(data);
|
|
448
541
|
return parsedData;
|
|
449
542
|
}],
|
|
@@ -459,6 +552,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
459
552
|
method: 'POST',
|
|
460
553
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/tags'),
|
|
461
554
|
transformResponse: [(data) => {
|
|
555
|
+
if (!data)
|
|
556
|
+
return data;
|
|
462
557
|
const parsedData = JSON.parse(data);
|
|
463
558
|
return parsedData;
|
|
464
559
|
}],
|
|
@@ -474,6 +569,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
474
569
|
method: 'PUT',
|
|
475
570
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/archiver'),
|
|
476
571
|
transformResponse: [(data) => {
|
|
572
|
+
if (!data)
|
|
573
|
+
return data;
|
|
477
574
|
const parsedData = JSON.parse(data);
|
|
478
575
|
return parsedData;
|
|
479
576
|
}]
|
|
@@ -488,6 +585,8 @@ class DossiersAPI extends core_1.Core {
|
|
|
488
585
|
method: 'PUT',
|
|
489
586
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers/{dossier_id}/essais'),
|
|
490
587
|
transformResponse: [(data) => {
|
|
588
|
+
if (!data)
|
|
589
|
+
return data;
|
|
491
590
|
const parsedData = JSON.parse(data);
|
|
492
591
|
return parsedData;
|
|
493
592
|
}],
|
|
@@ -17,6 +17,8 @@ class DossiersAffectationsAPI extends core_1.Core {
|
|
|
17
17
|
method: 'DELETE',
|
|
18
18
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers_affectations/{affectation_id}'),
|
|
19
19
|
transformResponse: [(data) => {
|
|
20
|
+
if (!data)
|
|
21
|
+
return data;
|
|
20
22
|
const parsedData = JSON.parse(data);
|
|
21
23
|
return parsedData;
|
|
22
24
|
}]
|
|
@@ -31,6 +33,8 @@ class DossiersAffectationsAPI extends core_1.Core {
|
|
|
31
33
|
method: 'POST',
|
|
32
34
|
endpoint: utils_1.Utils.constructPath(pathVariable, '/dossiers_affectations/{affectation_id}'),
|
|
33
35
|
transformResponse: [(data) => {
|
|
36
|
+
if (!data)
|
|
37
|
+
return data;
|
|
34
38
|
const parsedData = JSON.parse(data);
|
|
35
39
|
if (parsedData && parsedData.utilisateur?.roles) {
|
|
36
40
|
parsedData.utilisateur.roles = new Set(parsedData.utilisateur.roles);
|