project-booster-vue 8.125.2 → 8.126.2
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/package.json +1 -1
- package/src/components/appointment/PbAppointment.stories.mdx +21 -27
- package/src/components/categories/PbCategories.stories.mdx +14 -14
- package/src/components/configurations/search/PbConfigurationsSearch.stories.mdx +5 -5
- package/src/components/configurations/section/PbConfigurationsSection.stories.mdx +5 -10
- package/src/components/estimates/PbEstimatesList.stories.mdx +4 -4
- package/src/components/media/PbMedia.stories.mdx +26 -29
- package/src/components/media/detail/PbMediaDetail.stories.mdx +17 -23
- package/src/components/media/list/PbMediaList.stories.mdx +6 -6
- package/src/components/media/upload/PbMediaUpload.stories.mdx +21 -27
- package/src/components/products/PbProducts.stories.mdx +4 -4
- package/src/components/projects/project-hub/PbProjectHub-Collaborator.stories.mdx +54 -63
- package/src/components/projects/project-hub/PbProjectHub-Features-Appointment.stories.mdx +8 -8
- package/src/components/projects/project-hub/PbProjectHub-Features-Categories.stories.mdx +14 -14
- package/src/components/projects/project-hub/PbProjectHub-Features-Configurations.stories.mdx +24 -33
- package/src/components/projects/project-hub/PbProjectHub-Features-Documents&Media.stories.mdx +45 -54
- package/src/components/projects/project-hub/PbProjectHub-Features-Estimates.stories.mdx +14 -14
- package/src/components/projects/project-hub/PbProjectHub-Features-Planner.stories.mdx +3 -3
- package/src/components/projects/project-hub/PbProjectHub-Features-Project-Attributes.stories.mdx +6 -6
- package/src/components/projects/project-hub/PbProjectHub-Features-Project.stories.mdx +8 -8
- package/src/components/projects/project-hub/PbProjectHub-Features-Tools.stories.mdx +5 -5
- package/src/components/projects/project-hub/PbProjectHub.stories.mdx +171 -192
- package/src/components/projects/project-item-save/PbProjectItemSave.stories.mdx +10 -10
- package/src/components/projects/projects/PbProjects.stories.mdx +13 -13
- package/src/components/projects/projects-list/PbProjectsList.stories.mdx +3 -3
- package/src/components/question/configurations-import/PbConfigurationsImport.stories.mdx +12 -21
- package/src/components/question/configurations-import/PbConfigurationsImport.vue +2 -1
- package/src/components/question/upload-document/PbUploadDocument-Features-ShowMore.stories.mdx +4 -4
- package/src/components/question/upload-document/PbUploadDocument-Features-StartOpen.stories.mdx +4 -4
- package/src/components/question/upload-document/PbUploadDocument.stories.mdx +8 -8
- package/src/components/restitution/PbRestitution.stories.mdx +6 -6
- package/src/components/scenario/PbScenario-Features-Test.stories.mdx +13 -22
- package/src/components/scenario/scenarii/appointment-qualification-kitchen.json +9 -1
- package/src/services/api/appointmentQualificationsApi.js +4 -4
- package/src/services/api/configurationsApi.js +4 -4
- package/src/services/api/documentsApi.js +6 -6
- package/src/services/api/estimatesApi.js +5 -5
- package/src/services/api/eventsApi.js +18 -6
- package/src/services/api/inhabitantsApi.js +1 -1
- package/src/services/api/mediaApi.js +6 -6
- package/src/services/api/mocks/documentsMock.js +1 -1
- package/src/services/api/mocks/jsons/appointmentsRecovery.json +1 -1
- package/src/services/api/mocks/mediaMock.js +1 -1
- package/src/services/api/productsApi.js +5 -5
- package/src/services/api/projectsApi.js +8 -8
- package/src/stores/modules/mediaDocumentsStore.js +10 -9
package/package.json
CHANGED
|
@@ -97,21 +97,18 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
97
97
|
controls: { disable: true },
|
|
98
98
|
storyshots: { disable: true },
|
|
99
99
|
msw: [
|
|
100
|
-
rest.get('/
|
|
101
|
-
rest.post('/
|
|
102
|
-
rest.get('/
|
|
100
|
+
rest.get('/appointment-qualifications', getEmptyAppointmentQualificationResolver),
|
|
101
|
+
rest.post('/declarations-with-appointment', declarationsWithAppointmentResolver),
|
|
102
|
+
rest.get('/simulations', getConfigurationsByProjectIdResolver),
|
|
103
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/simulations', getEmptyConfigurationsByProjectIdResolver),
|
|
104
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/simulations', getConfigurationsByProjectIdResolver),
|
|
105
|
+
rest.post('/inhabitant-projects/:inhabitantProjectId/simulations/:simulationId', notContentResolver),
|
|
106
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
107
|
+
rest.post('/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
108
|
+
rest.post('/events/documents', acceptedResolver),
|
|
109
|
+
rest.post('/inhabitant-projects/:inhabitantProjectId/documents', uploadDocumentResolver),
|
|
103
110
|
rest.get(
|
|
104
|
-
'/
|
|
105
|
-
getEmptyConfigurationsByProjectIdResolver,
|
|
106
|
-
),
|
|
107
|
-
rest.get('/api/inhabitant-projects/:inhabitantProjectId/simulations', getConfigurationsByProjectIdResolver),
|
|
108
|
-
rest.post('/api/inhabitant-projects/:inhabitantProjectId/simulations/:simulationId', notContentResolver),
|
|
109
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
110
|
-
rest.post('/api/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
111
|
-
rest.post('/api/events/documents', acceptedResolver),
|
|
112
|
-
rest.post('/api/inhabitant-projects/:inhabitantProjectId/documents', uploadDocumentResolver),
|
|
113
|
-
rest.get(
|
|
114
|
-
'/api/inhabitant-projects/:inhabitantProjectId/documents/:documentId/thumbnail',
|
|
111
|
+
'/inhabitant-projects/:inhabitantProjectId/documents/:documentId/thumbnail',
|
|
115
112
|
getDocumentsPdfThumbnailResolver,
|
|
116
113
|
),
|
|
117
114
|
],
|
|
@@ -144,23 +141,20 @@ export const previousState = {
|
|
|
144
141
|
controls: { disable: true },
|
|
145
142
|
storyshots: { disable: true },
|
|
146
143
|
msw: [
|
|
147
|
-
rest.get('/
|
|
148
|
-
rest.get('/
|
|
149
|
-
rest.get(
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
),
|
|
153
|
-
rest.post('/api/inhabitant-projects/:inhabitantProjectId/simulations/:simulationId', notContentResolver),
|
|
154
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
144
|
+
rest.get('/appointment-qualifications', getAppointmentQualificationWithContextResolver),
|
|
145
|
+
rest.get('/simulations', getConfigurationsByProjectIdResolver),
|
|
146
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/simulations', getEmptyConfigurationsByProjectIdResolver),
|
|
147
|
+
rest.post('/inhabitant-projects/:inhabitantProjectId/simulations/:simulationId', notContentResolver),
|
|
148
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
155
149
|
rest.get(
|
|
156
|
-
'/
|
|
150
|
+
'/inhabitant-projects/:inhabitantProjectId/documents?range=0-6',
|
|
157
151
|
getDocumentsByInhabitantProjectIdResolver,
|
|
158
152
|
),
|
|
159
|
-
rest.post('/
|
|
160
|
-
rest.post('/
|
|
161
|
-
rest.post('/
|
|
153
|
+
rest.post('/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
154
|
+
rest.post('/events/documents', acceptedResolver),
|
|
155
|
+
rest.post('/inhabitant-projects/:inhabitantProjectId/documents', uploadDocumentResolver),
|
|
162
156
|
rest.get(
|
|
163
|
-
'/
|
|
157
|
+
'/inhabitant-projects/:inhabitantProjectId/documents/:documentId/thumbnail',
|
|
164
158
|
getDocumentsPdfThumbnailResolver,
|
|
165
159
|
),
|
|
166
160
|
],
|
|
@@ -97,10 +97,10 @@ The `PbCategories` component to display categories.
|
|
|
97
97
|
parameters={{
|
|
98
98
|
controls: { disable: true },
|
|
99
99
|
msw: [
|
|
100
|
-
rest.get('/
|
|
101
|
-
rest.get('/
|
|
102
|
-
rest.get('/
|
|
103
|
-
rest.put('/
|
|
100
|
+
rest.get('/inhabitant-projects/:projectId', getProjectByIdResolver),
|
|
101
|
+
rest.get('/project-types/:projectTypeId/work-kinds', getWorkKindByProjectTypeResolver),
|
|
102
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/work-kinds', getEmptyWorkKindsByProjectIdResolver),
|
|
103
|
+
rest.put('/inhabitant-projects/:inhabitantProjectId/work-kinds', saveWorkKindResolver),
|
|
104
104
|
],
|
|
105
105
|
}}
|
|
106
106
|
height="512px"
|
|
@@ -117,9 +117,9 @@ The `PbCategories` component to display categories.
|
|
|
117
117
|
parameters={{
|
|
118
118
|
controls: { disable: true },
|
|
119
119
|
msw: [
|
|
120
|
-
rest.get('/
|
|
121
|
-
rest.get('/
|
|
122
|
-
rest.get('/
|
|
120
|
+
rest.get('/inhabitant-projects/:projectId', getProjectByIdResolver),
|
|
121
|
+
rest.get('/project-types/:projectTypeId/work-kinds', internalServerErrorResolver),
|
|
122
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/work-kinds', getEmptyWorkKindsByProjectIdResolver),
|
|
123
123
|
],
|
|
124
124
|
}}
|
|
125
125
|
height="512px"
|
|
@@ -137,9 +137,9 @@ The `PbCategories` component to display categories.
|
|
|
137
137
|
controls: { disable: true },
|
|
138
138
|
storyshots: { disable: true },
|
|
139
139
|
msw: [
|
|
140
|
-
rest.get('/
|
|
141
|
-
rest.get('/
|
|
142
|
-
rest.get('/
|
|
140
|
+
rest.get('/inhabitant-projects/:projectId', getProjectByIdResolver),
|
|
141
|
+
rest.get('/project-types/:projectTypeId/work-kinds', getWorkKindByProjectTypeResolver),
|
|
142
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/work-kinds', internalServerErrorResolver),
|
|
143
143
|
],
|
|
144
144
|
}}
|
|
145
145
|
height="512px"
|
|
@@ -157,10 +157,10 @@ The `PbCategories` component to display categories.
|
|
|
157
157
|
controls: { disable: true },
|
|
158
158
|
storyshots: { disable: true },
|
|
159
159
|
msw: [
|
|
160
|
-
rest.get('/
|
|
161
|
-
rest.get('/
|
|
162
|
-
rest.get('/
|
|
163
|
-
rest.get('/
|
|
160
|
+
rest.get('/inhabitant-projects/:projectId', getProjectByIdResolver),
|
|
161
|
+
rest.get('/project-types/:projectTypeId/work-kinds', getWorkKindByProjectTypeResolver),
|
|
162
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/work-kinds', getWorkKindsByProjectIdResolver),
|
|
163
|
+
rest.get('/work-kinds/:workKindId/products', getProductsByWorkKindResolver),
|
|
164
164
|
],
|
|
165
165
|
}}
|
|
166
166
|
height="512px"
|
|
@@ -54,7 +54,7 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
54
54
|
name="101 Sandbox"
|
|
55
55
|
args={{ showDialog: true }}
|
|
56
56
|
parameters={{
|
|
57
|
-
msw: [rest.get('/
|
|
57
|
+
msw: [rest.get('/simulations', getConfigurationsByProjectIdResolver)],
|
|
58
58
|
storyshots: { disable: true },
|
|
59
59
|
}}
|
|
60
60
|
inline={false}
|
|
@@ -75,7 +75,7 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
75
75
|
name="Feature - Loading"
|
|
76
76
|
args={{ showDialog: true }}
|
|
77
77
|
parameters={{
|
|
78
|
-
msw: [rest.get('/
|
|
78
|
+
msw: [rest.get('/simulations', getConfigurationsWithDelayByProjectIdResolver)],
|
|
79
79
|
controls: { disable: true },
|
|
80
80
|
}}
|
|
81
81
|
inline={false}
|
|
@@ -96,7 +96,7 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
96
96
|
name="Feature - Empty state"
|
|
97
97
|
args={{ showDialog: true }}
|
|
98
98
|
parameters={{
|
|
99
|
-
msw: [rest.get('/
|
|
99
|
+
msw: [rest.get('/simulations', getEmptyConfigurationsByProjectIdResolver)],
|
|
100
100
|
controls: { disable: true },
|
|
101
101
|
}}
|
|
102
102
|
inline={false}
|
|
@@ -117,7 +117,7 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
117
117
|
name="Feature - With configurations"
|
|
118
118
|
args={{ showDialog: true }}
|
|
119
119
|
parameters={{
|
|
120
|
-
msw: [rest.get('/
|
|
120
|
+
msw: [rest.get('/simulations', getConfigurationsByProjectIdResolver)],
|
|
121
121
|
controls: { disable: true },
|
|
122
122
|
}}
|
|
123
123
|
inline={false}
|
|
@@ -137,7 +137,7 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
137
137
|
<Story
|
|
138
138
|
name="Feature - Error state"
|
|
139
139
|
parameters={{
|
|
140
|
-
msw: [rest.get('/
|
|
140
|
+
msw: [rest.get('/simulations', internalServerErrorResolver)],
|
|
141
141
|
controls: { disable: true },
|
|
142
142
|
}}
|
|
143
143
|
inline={false}
|
|
@@ -52,7 +52,7 @@ The `PbConfigurationsSection` component displays a list of configurations with a
|
|
|
52
52
|
parameters={{
|
|
53
53
|
msw: [
|
|
54
54
|
rest.get(
|
|
55
|
-
'/
|
|
55
|
+
'/inhabitant-projects/:inhabitantProjectId/simulations',
|
|
56
56
|
getConfigurationsWithDelayByProjectIdResolver,
|
|
57
57
|
),
|
|
58
58
|
],
|
|
@@ -75,10 +75,7 @@ The `PbConfigurationsSection` component displays a list of configurations with a
|
|
|
75
75
|
name="Feature - Empty state"
|
|
76
76
|
parameters={{
|
|
77
77
|
msw: [
|
|
78
|
-
rest.get(
|
|
79
|
-
'/api/inhabitant-projects/:inhabitantProjectId/simulations',
|
|
80
|
-
getEmptyConfigurationsByProjectIdResolver,
|
|
81
|
-
),
|
|
78
|
+
rest.get('/inhabitant-projects/:inhabitantProjectId/simulations', getEmptyConfigurationsByProjectIdResolver),
|
|
82
79
|
],
|
|
83
80
|
controls: { disable: true },
|
|
84
81
|
}}
|
|
@@ -97,9 +94,7 @@ The `PbConfigurationsSection` component displays a list of configurations with a
|
|
|
97
94
|
<Story
|
|
98
95
|
name="Feature - With configurations"
|
|
99
96
|
parameters={{
|
|
100
|
-
msw: [
|
|
101
|
-
rest.get('/api/inhabitant-projects/:inhabitantProjectId/simulations', getConfigurationsByProjectIdResolver),
|
|
102
|
-
],
|
|
97
|
+
msw: [rest.get('/inhabitant-projects/:inhabitantProjectId/simulations', getConfigurationsByProjectIdResolver)],
|
|
103
98
|
controls: { disable: true },
|
|
104
99
|
}}
|
|
105
100
|
height="512px"
|
|
@@ -119,7 +114,7 @@ The `PbConfigurationsSection` component displays a list of configurations with a
|
|
|
119
114
|
parameters={{
|
|
120
115
|
msw: [
|
|
121
116
|
rest.get(
|
|
122
|
-
'/
|
|
117
|
+
'/inhabitant-projects/:inhabitantProjectId/simulations',
|
|
123
118
|
getConfigurationsWithUpdatedPricesByProjectIdResolver,
|
|
124
119
|
),
|
|
125
120
|
],
|
|
@@ -140,7 +135,7 @@ The `PbConfigurationsSection` component displays a list of configurations with a
|
|
|
140
135
|
<Story
|
|
141
136
|
name="Feature - Error state"
|
|
142
137
|
parameters={{
|
|
143
|
-
msw: [rest.get('/
|
|
138
|
+
msw: [rest.get('/inhabitant-projects/:inhabitantProjectId/simulations', internalServerErrorResolver)],
|
|
144
139
|
controls: { disable: true },
|
|
145
140
|
}}
|
|
146
141
|
height="512px"
|
|
@@ -53,7 +53,7 @@ The `PbEstimatesList` Vue component.
|
|
|
53
53
|
<Story
|
|
54
54
|
name="Showcase - With estimates"
|
|
55
55
|
parameters={{
|
|
56
|
-
msw: [rest.get('/
|
|
56
|
+
msw: [rest.get('/estimates', getEstimatesByProjectIdResolver)],
|
|
57
57
|
controls: { disable: true },
|
|
58
58
|
storyshots: { disable: true },
|
|
59
59
|
}}
|
|
@@ -77,7 +77,7 @@ The `PbEstimatesList` Vue component.
|
|
|
77
77
|
<Story
|
|
78
78
|
name="Showcase - Empty state"
|
|
79
79
|
parameters={{
|
|
80
|
-
msw: [rest.get('/
|
|
80
|
+
msw: [rest.get('/estimates', getEmptyEstimatesByProjectIdResolver)],
|
|
81
81
|
controls: { disable: true },
|
|
82
82
|
storyshots: { disable: true },
|
|
83
83
|
}}
|
|
@@ -101,7 +101,7 @@ The `PbEstimatesList` Vue component.
|
|
|
101
101
|
<Story
|
|
102
102
|
name="Showcase - Empty state read only"
|
|
103
103
|
parameters={{
|
|
104
|
-
msw: [rest.get('/
|
|
104
|
+
msw: [rest.get('/estimates', getEmptyEstimatesByProjectIdResolver)],
|
|
105
105
|
controls: { disable: true },
|
|
106
106
|
storyshots: { disable: true },
|
|
107
107
|
}}
|
|
@@ -125,7 +125,7 @@ The `PbEstimatesList` Vue component.
|
|
|
125
125
|
<Story
|
|
126
126
|
name="Showcase - With error"
|
|
127
127
|
parameters={{
|
|
128
|
-
msw: [rest.get('/
|
|
128
|
+
msw: [rest.get('/estimates', internalServerErrorResolver)],
|
|
129
129
|
controls: { disable: true },
|
|
130
130
|
storyshots: { disable: true },
|
|
131
131
|
}}
|
|
@@ -81,12 +81,12 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
81
81
|
parameters={{
|
|
82
82
|
controls: { disabled: true },
|
|
83
83
|
msw: [
|
|
84
|
-
rest.patch('/
|
|
85
|
-
rest.post('/
|
|
86
|
-
rest.post('/
|
|
87
|
-
rest.get('/
|
|
88
|
-
rest.get('/
|
|
89
|
-
rest.get('/
|
|
84
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
85
|
+
rest.post('/events/media', acceptedResolver),
|
|
86
|
+
rest.post('/media', uploadMediaResolver),
|
|
87
|
+
rest.get('/media/:mediaId/thumbnail', getMediaThumbnailResolver),
|
|
88
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
89
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
90
90
|
],
|
|
91
91
|
}}
|
|
92
92
|
height="512px"
|
|
@@ -112,14 +112,11 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
112
112
|
parameters={{
|
|
113
113
|
controls: { disabled: true },
|
|
114
114
|
msw: [
|
|
115
|
-
rest.post('/
|
|
116
|
-
rest.get('/
|
|
117
|
-
rest.get(
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
),
|
|
121
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
122
|
-
rest.post('/api/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
115
|
+
rest.post('/events/documents', acceptedResolver),
|
|
116
|
+
rest.get('/inhabitant-projects/:projectId/documents/', getDocumentsByInhabitantProjectIdResolver),
|
|
117
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/thumbnail', getDocumentsImageThumbnailResolver),
|
|
118
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
119
|
+
rest.post('/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
123
120
|
],
|
|
124
121
|
}}
|
|
125
122
|
height="512px"
|
|
@@ -156,12 +153,12 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
156
153
|
parameters={{
|
|
157
154
|
controls: { disabled: true },
|
|
158
155
|
msw: [
|
|
159
|
-
rest.patch('/
|
|
160
|
-
rest.get('/
|
|
161
|
-
rest.get('/
|
|
162
|
-
rest.get('/
|
|
163
|
-
rest.post('/
|
|
164
|
-
rest.delete('/
|
|
156
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
157
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
158
|
+
rest.get('/media/:mediaId/thumbnail', getMediaThumbnailResolver),
|
|
159
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
160
|
+
rest.post('/media', uploadMediaResolver),
|
|
161
|
+
rest.delete('/media/:mediaId', notContentResolver),
|
|
165
162
|
],
|
|
166
163
|
}}
|
|
167
164
|
height="512px"
|
|
@@ -187,9 +184,9 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
187
184
|
parameters={{
|
|
188
185
|
controls: { disabled: true },
|
|
189
186
|
msw: [
|
|
190
|
-
rest.patch('/
|
|
191
|
-
rest.get('/
|
|
192
|
-
rest.get('/
|
|
187
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
188
|
+
rest.get('/media/:mediaId/thumbnail', getMediaThumbnailResolver),
|
|
189
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
193
190
|
],
|
|
194
191
|
}}
|
|
195
192
|
height="512px"
|
|
@@ -215,12 +212,12 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
215
212
|
parameters={{
|
|
216
213
|
controls: { disabled: true },
|
|
217
214
|
msw: [
|
|
218
|
-
rest.patch('/
|
|
219
|
-
rest.get('/
|
|
220
|
-
rest.get('/
|
|
221
|
-
rest.get('/
|
|
222
|
-
rest.post('/
|
|
223
|
-
rest.delete('/
|
|
215
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
216
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
217
|
+
rest.get('/media/:mediaId/thumbnail', getMediaThumbnailResolver),
|
|
218
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
219
|
+
rest.post('/media', uploadMediaResolver),
|
|
220
|
+
rest.delete('/media/:mediaId', notContentResolver),
|
|
224
221
|
],
|
|
225
222
|
}}
|
|
226
223
|
height="512px"
|
|
@@ -70,9 +70,9 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
70
70
|
parameters={{
|
|
71
71
|
controls: { disabled: true },
|
|
72
72
|
msw: [
|
|
73
|
-
rest.patch('/
|
|
74
|
-
rest.get('/
|
|
75
|
-
rest.get('/
|
|
73
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
74
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
75
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
76
76
|
],
|
|
77
77
|
}}
|
|
78
78
|
inline={false}
|
|
@@ -98,7 +98,7 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
98
98
|
name="Showcase Media - Verification refused"
|
|
99
99
|
parameters={{
|
|
100
100
|
controls: { disabled: true },
|
|
101
|
-
msw: [rest.get('/
|
|
101
|
+
msw: [rest.get('/media/:mediaId/file', getMediaFileResolver)],
|
|
102
102
|
storyshots: { disable: true },
|
|
103
103
|
}}
|
|
104
104
|
inline={false}
|
|
@@ -125,8 +125,8 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
125
125
|
parameters={{
|
|
126
126
|
controls: { disabled: true },
|
|
127
127
|
msw: [
|
|
128
|
-
rest.patch('/
|
|
129
|
-
rest.get('/
|
|
128
|
+
rest.patch('/media/:mediaId', internalServerErrorResolver),
|
|
129
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
130
130
|
],
|
|
131
131
|
storyshots: { disable: true },
|
|
132
132
|
}}
|
|
@@ -154,8 +154,8 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
154
154
|
parameters={{
|
|
155
155
|
controls: { disabled: true },
|
|
156
156
|
msw: [
|
|
157
|
-
rest.patch('/
|
|
158
|
-
rest.get('/
|
|
157
|
+
rest.patch('/media/:mediaId', nameAlreadyUsedResolver),
|
|
158
|
+
rest.get('/media/:mediaId/file', getMediaFileResolver),
|
|
159
159
|
],
|
|
160
160
|
storyshots: { disable: true },
|
|
161
161
|
}}
|
|
@@ -200,9 +200,9 @@ export const imageDocument = {
|
|
|
200
200
|
parameters={{
|
|
201
201
|
controls: { disable: true },
|
|
202
202
|
msw: [
|
|
203
|
-
rest.get('/
|
|
204
|
-
rest.get('/
|
|
205
|
-
rest.patch('/
|
|
203
|
+
rest.get('/inhabitant-projects/:projectId/documents/', getDocumentsByInhabitantProjectIdResolver),
|
|
204
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
205
|
+
rest.patch('/inhabitant-projects/:projectId/documents/:documentId', notContentResolver),
|
|
206
206
|
],
|
|
207
207
|
}}
|
|
208
208
|
inline={false}
|
|
@@ -242,12 +242,9 @@ export const pdfDocument = {
|
|
|
242
242
|
parameters={{
|
|
243
243
|
controls: { disable: true },
|
|
244
244
|
msw: [
|
|
245
|
-
rest.get('/
|
|
246
|
-
rest.get(
|
|
247
|
-
|
|
248
|
-
getDocumentsPdfThumbnailResolver,
|
|
249
|
-
),
|
|
250
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsPdfFileResolver),
|
|
245
|
+
rest.get('/inhabitant-projects/:projectId/documents/', getDocumentsByInhabitantProjectIdResolver),
|
|
246
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/thumbnail', getDocumentsPdfThumbnailResolver),
|
|
247
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsPdfFileResolver),
|
|
251
248
|
],
|
|
252
249
|
}}
|
|
253
250
|
inline={false}
|
|
@@ -270,12 +267,9 @@ export const pdfDocument = {
|
|
|
270
267
|
parameters={{
|
|
271
268
|
controls: { disable: true },
|
|
272
269
|
msw: [
|
|
273
|
-
rest.get('/
|
|
274
|
-
rest.get(
|
|
275
|
-
|
|
276
|
-
getDocumentsPdfThumbnailResolver,
|
|
277
|
-
),
|
|
278
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsPdfFileResolver),
|
|
270
|
+
rest.get('/inhabitant-projects/:projectId/documents/', getDocumentsByInhabitantProjectIdResolver),
|
|
271
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/thumbnail', getDocumentsPdfThumbnailResolver),
|
|
272
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsPdfFileResolver),
|
|
279
273
|
],
|
|
280
274
|
}}
|
|
281
275
|
inline={false}
|
|
@@ -90,9 +90,9 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
90
90
|
parameters={{
|
|
91
91
|
controls: { disabled: true },
|
|
92
92
|
msw: [
|
|
93
|
-
rest.patch('/
|
|
94
|
-
rest.get('/
|
|
95
|
-
rest.get('/
|
|
93
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
94
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
95
|
+
rest.get('/media/:mediaId/thumbnail', getMediaThumbnailResolver),
|
|
96
96
|
],
|
|
97
97
|
}}
|
|
98
98
|
args={{
|
|
@@ -137,9 +137,9 @@ export const TemplateSandbox = (args, { argTypes }) => {
|
|
|
137
137
|
parameters={{
|
|
138
138
|
controls: { disabled: true },
|
|
139
139
|
msw: [
|
|
140
|
-
rest.patch('/
|
|
141
|
-
rest.get('/
|
|
142
|
-
rest.get('/
|
|
140
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
141
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
142
|
+
rest.get('/media/:mediaId/thumbnail', getMediaThumbnailResolver),
|
|
143
143
|
],
|
|
144
144
|
}}
|
|
145
145
|
args={{
|
|
@@ -79,11 +79,11 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
79
79
|
parameters={{
|
|
80
80
|
controls: { disabled: true },
|
|
81
81
|
msw: [
|
|
82
|
-
rest.post('/
|
|
83
|
-
rest.get('/
|
|
84
|
-
rest.get('/
|
|
85
|
-
rest.post('/
|
|
86
|
-
rest.patch('/
|
|
82
|
+
rest.post('/events/media', acceptedResolver),
|
|
83
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
84
|
+
rest.get('/media/:mediaId', successResolver),
|
|
85
|
+
rest.post('/media', uploadMediaResolver),
|
|
86
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
87
87
|
],
|
|
88
88
|
storyshots: { disable: true },
|
|
89
89
|
}}
|
|
@@ -105,7 +105,7 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
105
105
|
name="Name already used"
|
|
106
106
|
parameters={{
|
|
107
107
|
controls: { disabled: true },
|
|
108
|
-
msw: [rest.post('/
|
|
108
|
+
msw: [rest.post('/events/media', acceptedResolver), rest.post('/media', nameAlreadyUsedResolver)],
|
|
109
109
|
storyshots: { disable: true },
|
|
110
110
|
}}
|
|
111
111
|
inline={false}
|
|
@@ -127,11 +127,11 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
127
127
|
parameters={{
|
|
128
128
|
controls: { disabled: true },
|
|
129
129
|
msw: [
|
|
130
|
-
rest.post('/
|
|
131
|
-
rest.get('/
|
|
132
|
-
rest.get('/
|
|
133
|
-
rest.post('/
|
|
134
|
-
rest.patch('/
|
|
130
|
+
rest.post('/events/media', acceptedResolver),
|
|
131
|
+
rest.get('/media', getAllMediaPaginationResolver),
|
|
132
|
+
rest.get('/media/:mediaId', successResolver),
|
|
133
|
+
rest.post('/media', uploadMediaResolver),
|
|
134
|
+
rest.patch('/media/:mediaId', notContentResolver),
|
|
135
135
|
],
|
|
136
136
|
storyshots: { disable: true },
|
|
137
137
|
}}
|
|
@@ -154,14 +154,11 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
154
154
|
parameters={{
|
|
155
155
|
controls: { disabled: true },
|
|
156
156
|
msw: [
|
|
157
|
-
rest.post('/
|
|
158
|
-
rest.get('/
|
|
159
|
-
rest.get(
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
),
|
|
163
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
164
|
-
rest.post('/api/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
157
|
+
rest.post('/events/documents', acceptedResolver),
|
|
158
|
+
rest.get('/inhabitant-projects/:projectId/documents/', getDocumentsByInhabitantProjectIdResolver),
|
|
159
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/thumbnail', getDocumentsImageThumbnailResolver),
|
|
160
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', getDocumentsImageFileResolver),
|
|
161
|
+
rest.post('/inhabitant-projects/:projectId/documents', uploadDocumentResolver),
|
|
165
162
|
],
|
|
166
163
|
storyshots: { disable: true },
|
|
167
164
|
}}
|
|
@@ -186,14 +183,11 @@ export const TemplateSandbox = (args, { argTypes }) => ({
|
|
|
186
183
|
parameters={{
|
|
187
184
|
controls: { disabled: true },
|
|
188
185
|
msw: [
|
|
189
|
-
rest.post('/
|
|
190
|
-
rest.get('/
|
|
191
|
-
rest.get(
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
),
|
|
195
|
-
rest.get('/api/inhabitant-projects/:projectId/documents/:documentId/file', uploadDocumentResolver),
|
|
196
|
-
rest.post('/api/inhabitant-projects/:projectId/documents', internalServerErrorResolver),
|
|
186
|
+
rest.post('/events/documents', acceptedResolver),
|
|
187
|
+
rest.get('/inhabitant-projects/:projectId/documents/', getDocumentsByInhabitantProjectIdResolver),
|
|
188
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/thumbnail', getDocumentsImageThumbnailResolver),
|
|
189
|
+
rest.get('/inhabitant-projects/:projectId/documents/:documentId/file', uploadDocumentResolver),
|
|
190
|
+
rest.post('/inhabitant-projects/:projectId/documents', internalServerErrorResolver),
|
|
197
191
|
],
|
|
198
192
|
storyshots: { disable: true },
|
|
199
193
|
}}
|
|
@@ -73,8 +73,8 @@ The `PbProducts` component to display products.
|
|
|
73
73
|
parameters={{
|
|
74
74
|
controls: { disable: true },
|
|
75
75
|
msw: [
|
|
76
|
-
rest.get('/
|
|
77
|
-
rest.get('/
|
|
76
|
+
rest.get('/project-types/:projectTypeId/work-kinds', getWorkKindByProjectTypeResolver),
|
|
77
|
+
rest.get('/work-kinds/:workKindId/products', getProductsByWorkKindResolver),
|
|
78
78
|
],
|
|
79
79
|
}}
|
|
80
80
|
height="512px"
|
|
@@ -102,8 +102,8 @@ The `PbProducts` component to display products.
|
|
|
102
102
|
controls: { disable: true },
|
|
103
103
|
storyshots: { disable: true },
|
|
104
104
|
msw: [
|
|
105
|
-
rest.get('/
|
|
106
|
-
rest.get('/
|
|
105
|
+
rest.get('/project-types/:projectTypeId/work-kinds', getWorkKindByProjectTypeResolver),
|
|
106
|
+
rest.get('/work-kinds/:workKindId/products', notFoundResolver),
|
|
107
107
|
],
|
|
108
108
|
}}
|
|
109
109
|
height="512px"
|