project-booster-vue 10.23.3 → 10.23.5

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "project-booster-vue",
3
- "version": "10.23.3",
3
+ "version": "10.23.5",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -18,10 +18,10 @@
18
18
 
19
19
  <m-flex class="pb-products__body" direction="column" align-items="center" v-if="product">
20
20
  <m-flex class="pb-products__body__item" direction="column" align-items="center" justify-content="center">
21
- <div class="pb-products__body__item__thumbnail">
21
+ <div class="pb-products__body__item__thumbnail" v-if="product.photo">
22
22
  <img :src="product.photo" alt="" />
23
23
  </div>
24
- <div class="pb-products__body__item__title">{{ product.designation }}</div>
24
+ <div class="pb-products__body__item__title" v-if="product.designation">{{ product.designation }}</div>
25
25
  </m-flex>
26
26
 
27
27
  <m-flex class="pb-products__container--button" direction="column" align-items="center" justify-content="center">
@@ -85,7 +85,7 @@
85
85
  <div v-if="selectedCity" class="pb-city-search__selected-city">
86
86
  <!-- prettier-ignore -->
87
87
  <span>
88
- Votre construction sera réalisée dans la commune de&nbsp;<strong>{{ selectedCity.name }}</strong>,&nbsp;<strong>{{ selectedCity.region }}</strong>.
88
+ Votre chantier sera réalisée dans la commune de&nbsp;<strong>{{ selectedCity.name }}</strong>,&nbsp;<strong>{{ selectedCity.region }}</strong>.
89
89
  </span>
90
90
  </div>
91
91
  <m-flex class="pb-city-search__buttons-container" direction="column">
@@ -12,22 +12,22 @@
12
12
  </m-link>
13
13
  </div>
14
14
 
15
- <div class="pb-products__body row-flex column" v-if="product">
15
+ <div class="pb-products__body row-flex column">
16
16
  <div class="pb-products__title">
17
17
  {{ payload.viewModel.label }}
18
18
  </div>
19
19
 
20
- <div class="pb-products__body__item" v-if="product.designation">
21
- <div class="pb-products__body__item__thumbnail" v-if="product?.photo">
22
- <img :src="product.photo" alt="" />
20
+ <div class="pb-products__body__item" v-if="product">
21
+ <div class="pb-products__body__item__thumbnail" v-if="product.photo">
22
+ <img :src="product.photo" alt="photo du produit" />
23
23
  </div>
24
- <div class="pb-products__body__item__title">{{ product.designation }}</div>
24
+ <div class="pb-products__body__item__title" v-if="designation">{{ designation }}</div>
25
25
  </div>
26
26
  <div class="pb-products__body__item" v-else>
27
- <div class="pb-products__body__item__thumbnail">
28
- <img :src="payload.viewModel.defaultProduct.photo" alt="" />
27
+ <div class="pb-products__body__item__thumbnail" v-if="payload.viewModel.defaultProduct.photo">
28
+ <img :src="payload.viewModel.defaultProduct.photo" alt="photo du produit" />
29
29
  </div>
30
- <div class="pb-products__body__item__title">{{ payload.viewModel.defaultProduct.designation }}</div>
30
+ <div class="pb-products__body__item__title">{{ designation }}</div>
31
31
  </div>
32
32
 
33
33
  <div class="pb-products__container--button">
@@ -50,6 +50,7 @@
50
50
  </template>
51
51
 
52
52
  <script lang="ts" setup>
53
+ import { Product } from '@/types/pb/Estimate';
53
54
  import { ScenarioStepAnswer } from '@/types/pb/Scenario';
54
55
  import { MButton, MLink } from '@mozaic-ds/vue-3';
55
56
  import { PropType, defineProps, onMounted, ref } from 'vue';
@@ -60,14 +61,11 @@ const emit = defineEmits(['go-back', 'step-completed']);
60
61
 
61
62
  const store = useStore();
62
63
  const metadata = store.getters['metaData/metaData'];
63
- const refProduct = store.getters['products/getRefProduct'];
64
- const product = ref(store.getters['products/getCurrentProduct']);
65
64
 
66
- if (!product.value) {
67
- product.value = {
68
- designation: 'Désignation par défaut',
69
- };
70
- }
65
+ const refProduct = ref<string>();
66
+ const product = ref<Product>();
67
+
68
+ const designation = ref<string>();
71
69
 
72
70
  const props = defineProps({
73
71
  /**
@@ -133,6 +131,11 @@ onMounted(() => {
133
131
  storeId: metadata && metadata.storeId ? metadata.storeId : '',
134
132
  });
135
133
  }
134
+
135
+ refProduct.value = store.getters['products/getRefProduct'];
136
+ product.value = store.getters['products/getCurrentProduct'];
137
+
138
+ designation.value = product.value?.designation || props.payload.viewModel.defaultProduct.designation || '';
136
139
  });
137
140
 
138
141
  /**
@@ -144,20 +147,21 @@ const callAction = (action: PayloadAction) => {
144
147
  if (action.code === '__BACK__') {
145
148
  emit('go-back');
146
149
  } else {
147
- let productToSend = null;
148
-
149
- if (refProduct) {
150
- productToSend = product.value;
150
+ if (refProduct.value && product.value) {
151
+ emit('step-completed', {
152
+ answers: [
153
+ {
154
+ product: product.value,
155
+ },
156
+ ],
157
+ nextStep: action,
158
+ });
159
+ } else {
160
+ emit('step-completed', {
161
+ answers: [{}],
162
+ nextStep: action,
163
+ });
151
164
  }
152
-
153
- emit('step-completed', {
154
- answers: [
155
- {
156
- product: productToSend,
157
- },
158
- ],
159
- nextStep: action,
160
- });
161
165
  }
162
166
  }
163
167
  };
@@ -64,7 +64,7 @@
64
64
  <div v-if="selectedCity" class="pb-city-search__selected-city">
65
65
  <!-- prettier-ignore -->
66
66
  <span>
67
- Votre construction sera réalisée dans la commune de&nbsp;<strong>{{ selectedCity.name }}</strong>,&nbsp;<strong>{{ selectedCity.region }}</strong>.
67
+ Votre chantier sera réalisée dans la commune de&nbsp;<strong>{{ selectedCity.name }}</strong>,&nbsp;<strong>{{ selectedCity.region }}</strong>.
68
68
  </span>
69
69
  </div>
70
70
 
@@ -8,7 +8,8 @@
8
8
  "projectName": "Estimation pompe à chaleur air-eau",
9
9
  "webAnalytics": {
10
10
  "category": "Pompe à chaleur air-eau",
11
- "scenario": "Estimation-budget-hpaw"
11
+ "scenario": "Estimation-budget-hpaw",
12
+ "tracking": true
12
13
  }
13
14
  },
14
15
  "stepCode": "HEAT_PUMP_AIR_WATER"
@@ -18,16 +19,15 @@
18
19
  "type": "SCENARIO",
19
20
  "stepCode": "LMFR_HEAT_PUMP_AIR_WATER_DISPLAY_PRODUCT"
20
21
  },
21
-
22
22
  "LMFR_HEAT_PUMP_AIR_WATER_DISPLAY_PRODUCT": {
23
23
  "code": "LMFR_HEAT_PUMP_AIR_WATER_DISPLAY_PRODUCT",
24
24
  "type": "STEP",
25
25
  "component": "MPbProducts",
26
26
  "payload": {
27
27
  "viewModel": {
28
- "label": "Estimation pompe à chaleur",
28
+ "label": "Estimation pompe à chaleur Air / Eau",
29
29
  "defaultProduct": {
30
- "designation": "Installation d'une pompe à chaleur"
30
+ "designation": "Estimez le cout de votre projet en moins de deux minutes"
31
31
  }
32
32
  },
33
33
  "callToActions": [
@@ -36,13 +36,14 @@
36
36
  "label": "Commencer",
37
37
  "action": {
38
38
  "type": "STEP",
39
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION"
39
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HOUSING_TYPE"
40
40
  },
41
41
  "bordered": false
42
42
  }
43
43
  ]
44
44
  }
45
45
  },
46
+
46
47
  "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HOUSING_TYPE": {
47
48
  "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HOUSING_TYPE",
48
49
  "type": "STEP",
@@ -58,7 +59,7 @@
58
59
  },
59
60
  "payload": {
60
61
  "viewModel": {
61
- "label": "Que souhaitez-vous rénover ?",
62
+ "label": "Quel type de logement souhaitez-vous rénover ?",
62
63
  "answersComponent": "MPbCard"
63
64
  },
64
65
  "answers": {
@@ -73,118 +74,67 @@
73
74
  "code": "APARTMENT",
74
75
  "viewModel": {
75
76
  "title": "Un appartement",
76
- "image": "https://storage.googleapis.com/project-booster-media/energyrenovation/apartement.jpg"
77
+ "image": "https://storage.googleapis.com/project-booster-media/energyrenovation/apartement.jpg",
78
+ "disabledNextStepButton": true
77
79
  },
78
80
  "notification": {
79
81
  "type": "info",
80
82
  "title": "Nous attirons votre attention !",
81
- "content": "Nous ne réalisons pas de projets d’isolation de murs par l’extérieur dans les appartements. Nous vous invitons à vous rapporcher de votre copropriété pour poursuivre les démarches de rénovation énergétique."
83
+ "content": "Nous ne réalisons pas de projets d'installation de pompe à chaleur air / eau dans les appartements. Nous vous invitons à vous rapprocher de votre copropriété pour poursuivre les démarches de rénovation énergétique.",
84
+ "buttonText": "Voir d'autres solutions pour faire des économies de chauffage",
85
+ "buttonStep": {
86
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APARTMENT_INSTALLATION"
87
+ }
82
88
  }
83
89
  }
84
90
  }
85
91
  },
86
92
  "nextStep": {
87
93
  "conditionals": [
88
- {
89
- "conditions": ["isAnswerMatching('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HOUSING_TYPE', 'APARTMENT')"],
90
- "nextStep": {
91
- "code": "LMFR_HEAT_PUMP_AIR_WATER_WARNING_FOR_APARTEMENT"
92
- }
93
- },
94
94
  {
95
95
  "conditions": ["isAnswerMatching('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HOUSING_TYPE', 'HOUSE')"],
96
96
  "nextStep": {
97
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE"
97
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION"
98
98
  }
99
99
  }
100
100
  ]
101
101
  }
102
102
  },
103
- "LMFR_HEAT_PUMP_AIR_WATER_WARNING_FOR_APARTEMENT": {
104
- "code": "LMFR_HEAT_PUMP_AIR_WATER_WARNING_FOR_APARTEMENT",
105
- "type": "STEP",
106
- "component": "PbWarningMessage",
107
- "payload": {
108
- "viewModel": {
109
- "actionLabel": "Terminer",
110
- "backLabel": "Retour",
111
- "label": "Vos travaux dans un appartement",
112
- "subtitle": "Nous attirons votre attention !",
113
- "content": "Installer une pompe à chaleur dans un appartement nécessite certaines précautions.",
114
- "explainLink": {
115
- "type": "link",
116
- "label": "Voir les précautions pour installer une pompe à chaleur",
117
- "action": {
118
- "viewModelDialog": {
119
- "headerTitle": "Les précautions avant d’installer une pompe à chaleur en appartement",
120
- "contentHtml": "<p>Avant d'installer un pompe à chaleur air-eau dans un appartement, voici quelques précautions à prendre :</p><ul><li>Informez-vous sur le <strong>système de chauffage</strong> de votre immeuble : est-il collectif ou individuel ?</li><li>Vérifiez si <strong>votre commune autorise l'installation</strong> de groupes extérieurs sur votre balcon ou façade dans le plan local d'urbanisme</li><li><strong>Informez les voisins</strong> de votre projet, et notamment du bruit que peut générer le groupe extérieur</li></ul>"
121
- }
122
- }
123
- }
124
- },
125
- "callToActions": [
126
- {
127
- "type": "button",
128
- "label": "Ok, poursuivre l’estimation",
129
- "bordered": false,
130
- "action": {
131
- "type": "STEP",
132
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE"
133
- }
134
- },
135
- {
136
- "type": "button",
137
- "label": "Quitter l’estimation",
138
- "bordered": true,
139
- "action": {
140
- "type": "STEP",
141
- "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APPARTEMENT_INSTALLATION"
142
- }
143
- }
144
- ]
145
- }
146
- },
147
- "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APPARTEMENT_INSTALLATION": {
148
- "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APPARTEMENT_INSTALLATION",
103
+ "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION": {
104
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION",
149
105
  "type": "STEP",
150
- "component": "MPbQuestion",
106
+ "component": "MPbCitySearch",
151
107
  "slots": {
152
108
  "beforeContent": {
153
109
  "display": true,
154
110
  "component": "MPbProgress",
155
111
  "totalStep": 11,
156
- "currentStep": 1,
112
+ "currentStep": 2,
157
113
  "sizeXlWidth": true
158
114
  }
159
115
  },
160
116
  "payload": {
161
- "viewModel": {
162
- "label": "Pour aller plus loin dans votre projet",
163
- "answersComponent": "MPbCard",
164
- "disableNavigation": true
117
+ "value": {
118
+ "city": {
119
+ "inseeCode": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.inseeCode')}",
120
+ "postalCode": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.postalCode')}",
121
+ "name": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.name')}",
122
+ "region": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.region')}"
123
+ }
165
124
  },
166
- "answers": {
167
- "DISCOVER_HEAT_PUMPS": {
168
- "code": "DISCOVER_HEAT_PUMPS",
169
- "viewModel": {
170
- "title": "Découvrez nos gammes de chauffages",
171
- "image": "https://storage.googleapis.com/project-booster-media/energyrenovation/discover_our_heaters.jpg",
172
- "cardLink": "https://www.leroymerlin.fr/produits/chauffage-plomberie/"
173
- }
174
- },
175
- "LEARN_MORE_RENOV_AIDS": {
176
- "code": "LEARN_MORE_RENOV_AIDS",
177
- "viewModel": {
178
- "title": "Mieux comprendre les aides pour votre projet",
179
- "image": "https://storage.googleapis.com/project-booster-media/energyrenovation/learn_more_about_aids.jpg",
180
- "cardLink": "https://www.leroymerlin.fr/magazine/conseils-pratiques/les-aides-financieres-pour-renovation-energetique.html?isautocompleted=true"
181
- }
125
+ "viewModel": {
126
+ "label": "Où se situe le logement concerné par les travaux ?",
127
+ "subtitle": "Cette information nous aide à identifier les aides dont vous pourriez profiter",
128
+ "placeholder": "Code postal, Ville",
129
+ "actionLabel": "Continuer",
130
+ "nextStep": {
131
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION"
182
132
  }
183
133
  }
184
134
  }
185
135
  },
186
- "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE": {
187
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE",
136
+ "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION": {
137
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION",
188
138
  "type": "STEP",
189
139
  "component": "MPbQuestion",
190
140
  "slots": {
@@ -192,33 +142,35 @@
192
142
  "display": true,
193
143
  "component": "MPbProgress",
194
144
  "totalStep": 11,
195
- "currentStep": 1,
145
+ "currentStep": 3,
196
146
  "sizeXlWidth": true
197
147
  }
198
148
  },
199
149
  "payload": {
200
150
  "viewModel": {
201
- "label": "À quand remonte la construction de votre logement ?",
151
+ "label": "Dans ce logement, vous êtes ?",
202
152
  "answersComponent": "MPbCard"
203
153
  },
204
154
  "answers": {
205
- "NEW": {
206
- "code": "NEW",
207
- "viewModel": {
208
- "title": "Moins de 2 ans",
209
- "text": "Si votre logement à moins de 2 ans, vous ne serez pas éligible aux aides"
210
- }
211
- },
212
- "RECENT": {
213
- "code": "RECENT",
155
+ "OWNER": {
156
+ "code": "OWNER",
214
157
  "viewModel": {
215
- "title": "Entre 2 ans et 15 ans"
158
+ "title": "Propriétaire"
216
159
  }
217
160
  },
218
- "OLD": {
219
- "code": "OLD",
161
+ "LESSEE": {
162
+ "code": "LESSEE",
220
163
  "viewModel": {
221
- "title": "Plus de 15 ans"
164
+ "title": "Locataire"
165
+ },
166
+ "notification": {
167
+ "type": "info",
168
+ "title": "Le calcul des aides se base sur les revenus de votre propriétaire. La plupart des aides sont destinées aux propriétaires.",
169
+ "content": "Nous vous conseillons donc de vous rapprocher de votre propriétaire, c'est lui qui pourra monter le dossier d'obtention des aides pour votre projet.",
170
+ "buttonText": "Voir d'autres solutions pour faire des économies de chauffage",
171
+ "buttonStep": {
172
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APARTMENT_INSTALLATION"
173
+ }
222
174
  }
223
175
  }
224
176
  }
@@ -236,7 +188,7 @@
236
188
  "display": true,
237
189
  "component": "MPbProgress",
238
190
  "totalStep": 11,
239
- "currentStep": 1,
191
+ "currentStep": 4,
240
192
  "sizeXlWidth": true
241
193
  }
242
194
  },
@@ -267,45 +219,11 @@
267
219
  }
268
220
  },
269
221
  "nextStep": {
270
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION"
222
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE"
271
223
  }
272
224
  },
273
- "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION": {
274
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION",
275
- "type": "STEP",
276
- "component": "MPbCitySearch",
277
- "slots": {
278
- "beforeContent": {
279
- "display": true,
280
- "component": "MPbProgress",
281
- "totalStep": 11,
282
- "currentStep": 1,
283
- "sizeXlWidth": true
284
- }
285
- },
286
- "payload": {
287
- "value": {
288
- "city": {
289
- "inseeCode": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.inseeCode')}",
290
- "postalCode": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.postalCode')}",
291
- "name": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.name')}",
292
- "region": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION', 'city.region')}"
293
- }
294
- },
295
- "viewModel": {
296
- "label": "Où ce situe le logement ?",
297
- "subtitle": "Cette information nous aide à identifier les aides dont vous pourriez profiter",
298
- "placeholder": "Code postal, Ville",
299
- "image": "https://storage.googleapis.com/project-booster-media/new-house/Estimation%20Construction%20Neuve%20-%20Localisation.png",
300
- "actionLabel": "Continuer",
301
- "nextStep": {
302
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION"
303
- }
304
- }
305
- }
306
- },
307
- "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION": {
308
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION",
225
+ "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE": {
226
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE",
309
227
  "type": "STEP",
310
228
  "component": "MPbQuestion",
311
229
  "slots": {
@@ -313,87 +231,39 @@
313
231
  "display": true,
314
232
  "component": "MPbProgress",
315
233
  "totalStep": 11,
316
- "currentStep": 1,
234
+ "currentStep": 5,
317
235
  "sizeXlWidth": true
318
236
  }
319
237
  },
320
238
  "payload": {
321
239
  "viewModel": {
322
- "label": "Dans ce logement, vous êtes ?",
240
+ "label": "À quand remonte la construction de votre logement ?",
323
241
  "answersComponent": "MPbCard"
324
242
  },
325
243
  "answers": {
326
- "OWNER": {
327
- "code": "OWNER",
244
+ "NEW": {
245
+ "code": "NEW",
328
246
  "viewModel": {
329
- "title": "Propriétaire"
247
+ "title": "Moins de 2 ans",
248
+ "text": "Si votre logement à moins de 2 ans, vous ne serez pas éligible aux aides"
330
249
  }
331
250
  },
332
- "LESSEE": {
333
- "code": "LESSEE",
251
+ "RECENT": {
252
+ "code": "RECENT",
334
253
  "viewModel": {
335
- "title": "Locataire",
336
- "disabledNextStepButton": true
337
- },
338
- "notification": {
339
- "type": "informations",
340
- "title": "Le calcul des aides se base sur les revenus de votre propriétaire La plupart des aides sont destinées aux propriétaires.",
341
- "content": "Nous vous conseillons donc de vous rapprocher de votre propriétaire, c'est lui qui pourra monter le dossier d'obtention des aides pour votre projet.",
342
- "buttonText": "Voir d'autres solutions pour faire des économies de chauffage",
343
- "buttonStep": {
344
- "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_LESSEE"
345
- }
254
+ "title": "Entre 2 ans et 15 ans"
255
+ }
256
+ },
257
+ "OLD": {
258
+ "code": "OLD",
259
+ "viewModel": {
260
+ "title": "Plus de 15 ans"
346
261
  }
347
262
  }
348
263
  }
349
264
  },
350
265
  "nextStep": {
351
- "conditionals": [
352
- {
353
- "conditions": ["isAnswerMatching('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION', 'OWNER')"],
354
- "nextStep": {
355
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INHABITANTS_COUNT"
356
- }
357
- },
358
- {
359
- "conditions": ["isAnswerMatching('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION', 'LESSEE')"],
360
- "nextStep": {
361
- "code": "LMFR_HEAT_PUMP_AIR_WATER_WARNING_FOR_LESSEE"
362
- }
363
- }
364
- ]
365
- }
366
- },
367
- "LMFR_HEAT_PUMP_AIR_WATER_WARNING_FOR_LESSEE": {
368
- "code": "LMFR_HEAT_PUMP_AIR_WATER_WARNING_FOR_LESSEE",
369
- "type": "STEP",
370
- "component": "PbWarningMessage",
371
- "payload": {
372
- "viewModel": {
373
- "actionLabel": "Terminer",
374
- "label": "Vous êtes locataire",
375
- "subtitle": "Le calcul des aides se base sur les revenus de votre propriétaire",
376
- "content": "La plupart des aides sont destinées aux propriétaires. Nous vous conseillons donc de vous rapprocher de votre propriétaire, c’est lui qui pourra monter le dossier d’obtention des aides pour votre projet.",
377
- "backLabel": "Retour"
378
- },
379
- "callToActions": [
380
- {
381
- "label": "Ok, poursuivre l’estimation",
382
- "bordered": false,
383
- "action": {
384
- "type": "STEP",
385
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INHABITANTS_COUNT"
386
- }
387
- },
388
- {
389
- "label": "Quitter l’estimation",
390
- "bordered": true,
391
- "action": {
392
- "type": "STEP",
393
- "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APPARTEMENT_INSTALLATION"
394
- }
395
- }
396
- ]
266
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INHABITANTS_COUNT"
397
267
  }
398
268
  },
399
269
  "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INHABITANTS_COUNT": {
@@ -404,7 +274,7 @@
404
274
  "display": true,
405
275
  "component": "MPbProgress",
406
276
  "totalStep": 11,
407
- "currentStep": 2,
277
+ "currentStep": 6,
408
278
  "sizeXlWidth": true
409
279
  }
410
280
  },
@@ -437,14 +307,14 @@
437
307
  "display": true,
438
308
  "component": "MPbProgress",
439
309
  "totalStep": 11,
440
- "currentStep": 3,
310
+ "currentStep": 7,
441
311
  "sizeXlWidth": true
442
312
  }
443
313
  },
444
314
  "payload": {
445
315
  "viewModel": {
446
- "label": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION', 'code') != 'OWNER' ? 'Quel est le revenu fiscal de référence annuel de votre propriétaire ?' : 'Quel est votre revenu fiscal de référence annuel de votre foyer fiscal ?'}",
447
- "subtitle": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION', 'code') != 'OWNER' ? 'Posez la question à votre propritétaire, cette information est utile pour le calcul des aides.' : 'Le revenu fiscal de référence du foyer concerne la somme des revenus des conjoints. Cette information est utile pour le calcul des aides.'}",
316
+ "label": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION', 'code') != 'OWNER' ? 'Quel est le revenu fiscal de référence annuel de votre propriétaire ?' : 'Quel est votre revenu fiscal de référénce ?'}",
317
+ "subtitle": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION', 'code') != 'OWNER' ? 'Posez la question à votre propritétaire, cette information est utile pour le calcul des aides.' : 'Le revenu fiscal de référence du foyer prend en compte la somme renseignée dans votre déclaration de revenus, imposables ou non. Cette information est calculée par les services fiscaux et est utile pour le calcul des aides.'}",
448
318
  "answersComponent": "MPbCard"
449
319
  },
450
320
  "answers": {
@@ -2057,7 +1927,7 @@
2057
1927
  "type": "MODAL",
2058
1928
  "viewModelDialog": {
2059
1929
  "headerTitle": "Ou trouver votre revenu fiscal de référence ?",
2060
- "subTitle": "Sur votre dernier avis d’imposition disponible dans votre espace impots-gouv.fr",
1930
+ "htmlContent": "<b style='font-size:18px;'>Sur votre dernier avis d’imposition disponible dans votre espace impots-gouv.fr</b>",
2061
1931
  "imgUrl": "https://storage.googleapis.com/project-booster-media/energyrenovation/reference_tax_income.png"
2062
1932
  }
2063
1933
  }
@@ -2065,60 +1935,7 @@
2065
1935
  ]
2066
1936
  },
2067
1937
  "nextStep": {
2068
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA"
2069
- }
2070
- },
2071
- "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA": {
2072
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA",
2073
- "type": "STEP",
2074
- "component": "MPbSpaceInput",
2075
- "slots": {
2076
- "stickyBottom": {
2077
- "display": false
2078
- },
2079
- "beforeContent": {
2080
- "display": true,
2081
- "component": "MPbProgress",
2082
- "totalStep": 11,
2083
- "currentStep": 4,
2084
- "sizeXlWidth": true
2085
- }
2086
- },
2087
- "payload": {
2088
- "value": {
2089
- "space": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA', 'space')}"
2090
- },
2091
- "viewModel": {
2092
- "validation": {
2093
- "thresholdsIncluded": true,
2094
- "minValue": 1,
2095
- "minErrorMessage": "La surface doit être supérieure à 1m²",
2096
- "maxValue": 1000,
2097
- "maxErrorMessage": "La surface doit être inférieure à 1000m²",
2098
- "notValidNumberMessage": "Veuillez saisir un nombre entier positif"
2099
- },
2100
- "backLabel": "Question précédente",
2101
- "label": "Quelle surface sera chauffée par la pompe à chaleur ?",
2102
- "unitLabel": "m²",
2103
- "placeholder": "Surface",
2104
- "actionLabel": "Continuer",
2105
- "nextStep": {
2106
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_REPLACEMENT"
2107
- }
2108
- },
2109
- "helpArea": [
2110
- {
2111
- "type": "link",
2112
- "label": "Voir le guide pour calculer sa surface",
2113
- "action": {
2114
- "type": "MODAL",
2115
- "dialogViewModel": {
2116
- "headerTitle": "Comment calculer la surface chauffée par la pompe à chaleur?",
2117
- "htmlContent": "<p>Pour calculer la surface chauffée c’est facile.</p><p> Il suffit de déduire de <strong>la surface habitable</strong> de votre habitation, <strong>les surfaces des pièces non chauffées</strong> par la pompe à chaleur. </p><p> Les pièces non chauffées peuvent être des pièces annexes (buanderie, véranda, …) ou des pièces chauffées par un autre mode de chauffage (radiateurs électriques par exemple). </p><p> <strong>Attention :</strong> le garage et le grenier ne sont pas pris en compte dans la surface habitable de base, il ne faut donc pas les déduire.</p>"
2118
- }
2119
- }
2120
- }
2121
- ]
1938
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_REPLACEMENT"
2122
1939
  }
2123
1940
  },
2124
1941
  "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_REPLACEMENT": {
@@ -2130,13 +1947,13 @@
2130
1947
  "display": true,
2131
1948
  "component": "MPbProgress",
2132
1949
  "totalStep": 11,
2133
- "currentStep": 5,
1950
+ "currentStep": 8,
2134
1951
  "sizeXlWidth": true
2135
1952
  }
2136
1953
  },
2137
1954
  "payload": {
2138
1955
  "viewModel": {
2139
- "label": "Quel équipement voulez-vous remplacer ?",
1956
+ "label": "Quel équipement de chauffage voulez-vous remplacer ?",
2140
1957
  "answersComponent": "MPbCard"
2141
1958
  },
2142
1959
  "answers": {
@@ -2199,7 +2016,60 @@
2199
2016
  }
2200
2017
  },
2201
2018
  "nextStep": {
2202
- "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HEATED_FLOOR"
2019
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA"
2020
+ }
2021
+ },
2022
+ "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA": {
2023
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA",
2024
+ "type": "STEP",
2025
+ "component": "MPbSpaceInput",
2026
+ "slots": {
2027
+ "stickyBottom": {
2028
+ "display": false
2029
+ },
2030
+ "beforeContent": {
2031
+ "display": true,
2032
+ "component": "MPbProgress",
2033
+ "totalStep": 11,
2034
+ "currentStep": 9,
2035
+ "sizeXlWidth": true
2036
+ }
2037
+ },
2038
+ "payload": {
2039
+ "value": {
2040
+ "space": "${getAnswerValue('LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SURFACE_AREA', 'space')}"
2041
+ },
2042
+ "viewModel": {
2043
+ "validation": {
2044
+ "thresholdsIncluded": true,
2045
+ "minValue": 1,
2046
+ "minErrorMessage": "La surface doit être supérieure à 1m²",
2047
+ "maxValue": 1000,
2048
+ "maxErrorMessage": "La surface doit être inférieure à 1000m²",
2049
+ "notValidNumberMessage": "Veuillez saisir un nombre entier positif"
2050
+ },
2051
+ "backLabel": "Question précédente",
2052
+ "label": "Quelle surface sera chauffée par la pompe à chaleur ?",
2053
+ "unitLabel": "m²",
2054
+ "placeholder": "Surface",
2055
+ "actionLabel": "Continuer",
2056
+ "nextStep": {
2057
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HEATED_FLOOR"
2058
+ }
2059
+ },
2060
+ "helpArea": [
2061
+ {
2062
+ "type": "link",
2063
+ "label": "Voir le guide pour calculer sa surface",
2064
+ "action": {
2065
+ "type": "MODAL",
2066
+ "dialogViewModel": {
2067
+ "headerTitle": "Comment calculer la surface chauffée par la pompe à chaleur?",
2068
+ "htmlContent": "<p>Pour calculer la surface chauffée c’est facile.</p><p> Il suffit de déduire de <strong>la surface habitable</strong> de votre habitation, <strong>les surfaces des pièces non chauffées</strong> par la pompe à chaleur. </p><p> Les pièces non chauffées peuvent être des pièces annexes (buanderie, véranda, …) ou des pièces chauffées par un autre mode de chauffage (radiateurs électriques par exemple). </p><p> <strong>Attention :</strong> le garage et le grenier ne sont pas pris en compte dans la surface habitable de base, il ne faut donc pas les déduire.</p>"
2069
+ }
2070
+ }
2071
+ }
2072
+ ]
2203
2073
  }
2204
2074
  },
2205
2075
  "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HEATED_FLOOR": {
@@ -2211,13 +2081,13 @@
2211
2081
  "display": true,
2212
2082
  "component": "MPbProgress",
2213
2083
  "totalStep": 11,
2214
- "currentStep": 6,
2084
+ "currentStep": 10,
2215
2085
  "sizeXlWidth": true
2216
2086
  }
2217
2087
  },
2218
2088
  "payload": {
2219
2089
  "viewModel": {
2220
- "label": "Avez vous un plancher chauffant ?",
2090
+ "label": "Avez-vous un plancher chauffant ?",
2221
2091
  "answersComponent": "MPbCard"
2222
2092
  },
2223
2093
  "answers": {
@@ -2267,7 +2137,7 @@
2267
2137
  "display": true,
2268
2138
  "component": "MPbProgress",
2269
2139
  "totalStep": 11,
2270
- "currentStep": 7,
2140
+ "currentStep": 11,
2271
2141
  "sizeXlWidth": true
2272
2142
  }
2273
2143
  },
@@ -2308,6 +2178,46 @@
2308
2178
  }
2309
2179
  },
2310
2180
 
2181
+ "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APARTMENT_INSTALLATION": {
2182
+ "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_APARTMENT_INSTALLATION",
2183
+ "type": "STEP",
2184
+ "component": "MPbQuestion",
2185
+ "slots": {
2186
+ "beforeContent": {
2187
+ "display": true,
2188
+ "component": "MPbProgress",
2189
+ "totalStep": 11,
2190
+ "currentStep": 11,
2191
+ "sizeXlWidth": true
2192
+ }
2193
+ },
2194
+ "payload": {
2195
+ "viewModel": {
2196
+ "label": "Pour aller plus loin dans votre projet",
2197
+ "answersComponent": "MPbCard",
2198
+ "hideNextStep": true
2199
+ },
2200
+ "answers": {
2201
+ "DISCOVER_HEAT_PUMPS": {
2202
+ "code": "DISCOVER_HEAT_PUMPS",
2203
+ "viewModel": {
2204
+ "title": "Découvrez nos gammes de chauffages",
2205
+ "image": "https://storage.googleapis.com/project-booster-media/energyrenovation/discover_our_heaters.jpg",
2206
+ "cardLink": "https://www.leroymerlin.fr/produits/chauffage-plomberie/"
2207
+ }
2208
+ },
2209
+ "LEARN_MORE_RENOV_AIDS": {
2210
+ "code": "LEARN_MORE_RENOV_AIDS",
2211
+ "viewModel": {
2212
+ "title": "Mieux comprendre les aides pour votre projet",
2213
+ "image": "https://storage.googleapis.com/project-booster-media/energyrenovation/learn_more_about_aids.jpg",
2214
+ "cardLink": "https://www.leroymerlin.fr/magazine/conseils-pratiques/les-aides-financieres-pour-renovation-energetique.html?isautocompleted=true"
2215
+ }
2216
+ }
2217
+ }
2218
+ }
2219
+ },
2220
+
2311
2221
  "SUMMARY": {
2312
2222
  "code": "SUMMARY",
2313
2223
  "type": "STEP",
@@ -2402,7 +2312,7 @@
2402
2312
  "display": true,
2403
2313
  "component": "MPbProgress",
2404
2314
  "totalStep": 11,
2405
- "currentStep": 8,
2315
+ "currentStep": 11,
2406
2316
  "sizeXlWidth": true
2407
2317
  }
2408
2318
  },
@@ -2502,6 +2412,66 @@
2502
2412
  }
2503
2413
  },
2504
2414
  "metadata": [
2415
+ {
2416
+ "attribut": "productRef",
2417
+ "type": "string",
2418
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_DISPLAY_PRODUCT",
2419
+ "path": "product.code"
2420
+ },
2421
+ {
2422
+ "attribut": "housingType",
2423
+ "type": "string",
2424
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HOUSING_TYPE",
2425
+ "path": "code"
2426
+ },
2427
+ {
2428
+ "attribut": "zipcode",
2429
+ "type": "string",
2430
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_LOCATION",
2431
+ "path": "city.postalCode"
2432
+ },
2433
+ {
2434
+ "attribut": "situation",
2435
+ "type": "string",
2436
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_SITUATION",
2437
+ "path": "code"
2438
+ },
2439
+ {
2440
+ "attribut": "isMainResidence",
2441
+ "type": "string",
2442
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_MAIN_RESIDENCE",
2443
+ "path": "code"
2444
+ },
2445
+ {
2446
+ "attribut": "constructionAge",
2447
+ "type": "string",
2448
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_CONSTRUCTION_AGE",
2449
+ "path": "code"
2450
+ },
2451
+ {
2452
+ "attribut": "familyComposition",
2453
+ "type": "string",
2454
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INHABITANTS_COUNT",
2455
+ "path": "value"
2456
+ },
2457
+ {
2458
+ "attribut": "taxIncome",
2459
+ "type": "string",
2460
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INCOME",
2461
+ "path": "code"
2462
+ },
2463
+ {
2464
+ "attribut": "equipmentToReplace",
2465
+ "type": "string",
2466
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_REPLACEMENT",
2467
+ "path": "code"
2468
+ },
2469
+ {
2470
+ "attribut": "dpe",
2471
+ "type": "string",
2472
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_DPE",
2473
+ "path": "code"
2474
+ },
2505
2475
  {
2506
2476
  "attribut": "surface",
2507
2477
  "type": "float",
@@ -2509,10 +2479,16 @@
2509
2479
  "path": "space"
2510
2480
  },
2511
2481
  {
2512
- "attribut": "productRef",
2482
+ "attribut": "haveHeatedFloor",
2513
2483
  "type": "string",
2514
- "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_DISPLAY_PRODUCT",
2515
- "path": "product.code"
2484
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_HEATED_FLOOR",
2485
+ "path": "code"
2486
+ },
2487
+ {
2488
+ "attribut": "insulationLevel",
2489
+ "type": "string",
2490
+ "answerCode": "LMFR_HEAT_PUMP_AIR_WATER_QUESTION_INSULATION_LEVEL",
2491
+ "path": "code"
2516
2492
  }
2517
2493
  ]
2518
2494
  },
@@ -2614,20 +2590,11 @@
2614
2590
  "code": "LMFR_HEAT_PUMP_AIR_WATER_ADVICE_FOR_LESSEE",
2615
2591
  "type": "STEP",
2616
2592
  "component": "MPbQuestion",
2617
- "slots": {
2618
- "beforeContent": {
2619
- "display": true,
2620
- "component": "MPbProgress",
2621
- "totalStep": 11,
2622
- "currentStep": 1,
2623
- "sizeXlWidth": true
2624
- }
2625
- },
2626
2593
  "payload": {
2627
2594
  "viewModel": {
2628
2595
  "label": "Pour aller plus loin dans votre projet",
2629
2596
  "answersComponent": "MPbCard",
2630
- "disableNavigation": true
2597
+ "hideNextStep": true
2631
2598
  },
2632
2599
  "answers": {
2633
2600
  "DISCOVER_OUR_HEATERS": {
@@ -1,5 +1,5 @@
1
+ import { Product } from '@/types/pb/Estimate';
1
2
  import axios from 'axios';
2
- import { escape } from '../../services/htmlEscape';
3
3
 
4
4
  export const clientApi = axios.create({
5
5
  baseURL: '/project-booster/api',
@@ -19,15 +19,11 @@ export const updateProductApiClient = (config: { apiKey: string; baseUrl: string
19
19
  }
20
20
  };
21
21
 
22
- export const getProductById = async (productId: string, storeId: string) => {
22
+ export async function getProductById(productId: string, storeId: string): Promise<Product | null> {
23
23
  try {
24
24
  const response = await clientApi.get(`/products/${productId}${storeId ? '?storeId=' + storeId : ''}`);
25
- return JSON.parse(
26
- JSON.stringify(response.data).replace(/:"([^"]+)"/g, (match, $1) => {
27
- return `: "${escape($1)}"`;
28
- }),
29
- );
25
+ return response.data ? response.data : null;
30
26
  } catch (e) {
31
- return false;
27
+ return null;
32
28
  }
33
- };
29
+ }
@@ -1,13 +1,8 @@
1
- import { ActionContext } from 'vuex';
2
1
  import { State } from '@/stores/state';
3
- import { getProductById } from '../../services/api/productApi';
2
+ import { Product, ProductState } from '@/types/pb/Estimate';
4
3
  import { ProductPayload } from '@/types/pb/Product';
5
-
6
- export interface ProductState {
7
- // eslint-disable-next-line @typescript-eslint/ban-types
8
- refProduct: string;
9
- currentProduct: object;
10
- }
4
+ import { ActionContext } from 'vuex';
5
+ import { getProductById } from '../../services/api/productApi';
11
6
 
12
7
  type ProductContext = ActionContext<ProductState, State>;
13
8
 
@@ -15,10 +10,10 @@ export default {
15
10
  namespaced: true,
16
11
  state: {
17
12
  refProduct: null,
18
- currentProduct: {},
13
+ currentProduct: null,
19
14
  },
20
15
  getters: {
21
- getRefProduct(state: ProductState) {
16
+ getRefProduct(state: ProductState): string {
22
17
  return state.refProduct;
23
18
  },
24
19
  getCurrentProduct(state: ProductState) {
@@ -29,7 +24,7 @@ export default {
29
24
  setRefProduct(state: ProductState, ref: string) {
30
25
  state.refProduct = ref;
31
26
  },
32
- setCurrentProduct(state: ProductState, product: object) {
27
+ setCurrentProduct(state: ProductState, product: Product) {
33
28
  state.currentProduct = product;
34
29
  },
35
30
  },
@@ -37,26 +32,17 @@ export default {
37
32
  updateRefProduct({ commit }: ProductContext, { ref }: { ref: string }) {
38
33
  commit('setRefProduct', ref);
39
34
  },
35
+
40
36
  async loadProduct(
41
37
  { commit, state }: ProductContext,
42
38
  { payload, storeId }: { payload: ProductPayload; storeId: string },
43
- ) {
39
+ ): Promise<void> {
44
40
  if (state.refProduct) {
45
- const product = await getProductById(state.refProduct, storeId);
41
+ const product: Product | null = await getProductById(state.refProduct, storeId);
46
42
 
47
43
  if (product) {
48
- const formattedProduct = {
49
- code: product.code || null,
50
- photo: product.photo || payload.photo,
51
- designation: product.designation || payload.designation,
52
- price: product.price || null,
53
- };
54
- commit('setCurrentProduct', formattedProduct);
55
- } else {
56
- commit('setCurrentProduct', payload);
44
+ commit('setCurrentProduct', product);
57
45
  }
58
- } else {
59
- commit('setCurrentProduct', payload);
60
46
  }
61
47
  },
62
48
  },
@@ -6,7 +6,6 @@ import { InhabitantsState } from '@/stores/modules/inhabitantsStore';
6
6
  import { MetaDataState } from '@/stores/modules/metaDataStore';
7
7
  import { ProjectsState } from '@/stores/modules/projectsStore';
8
8
  import { ToolsState } from '@/stores/modules/toolsStore';
9
- import { ProductState } from './modules/productsStore';
10
9
  import { TrezorState } from './modules/trezorStore';
11
10
 
12
11
  export interface State {
@@ -18,6 +17,5 @@ export interface State {
18
17
  metaData: MetaDataState;
19
18
  projects: ProjectsState;
20
19
  tools: ToolsState;
21
- products: ProductState;
22
20
  trezor: TrezorState;
23
21
  }
@@ -34,3 +34,24 @@ export interface Estimate {
34
34
  toolLink: string;
35
35
  summary: Summary;
36
36
  }
37
+
38
+ export interface Product {
39
+ code: string;
40
+ designation: string;
41
+ photo: string;
42
+ price: Price;
43
+ }
44
+
45
+ export interface Price {
46
+ unitAmount: number;
47
+ initialUnitAmount: number;
48
+ unitAmountNoTax: number;
49
+ initialUnitAmountNoTax: number;
50
+ currency: string;
51
+ discount?: any;
52
+ }
53
+
54
+ export interface ProductState {
55
+ refProduct: string;
56
+ currentProduct: Product;
57
+ }