project-booster-vue 9.17.4 → 9.18.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
CHANGED
|
@@ -56,9 +56,10 @@
|
|
|
56
56
|
<m-flex class="pb-configurations-section__link-container" v-if="readOnly && project">
|
|
57
57
|
<m-link
|
|
58
58
|
class="pb-configurations-section__link-portal-oaa"
|
|
59
|
-
label="
|
|
59
|
+
label="Accéder au portail des OAA"
|
|
60
60
|
size="s"
|
|
61
|
-
|
|
61
|
+
:href="linkPortalOaa"
|
|
62
|
+
target="_blank"
|
|
62
63
|
/>
|
|
63
64
|
</m-flex>
|
|
64
65
|
</m-flex>
|
|
@@ -111,9 +112,7 @@ export default defineComponent({
|
|
|
111
112
|
project: 'getProject',
|
|
112
113
|
}),
|
|
113
114
|
linkPortalOaa() {
|
|
114
|
-
return this.project
|
|
115
|
-
? `http://rcloset.fr.corp.leroymerlin.com:81/page_tunnel_oaa/?mag=${this.project.store}`
|
|
116
|
-
: null;
|
|
115
|
+
return this.project ? `https://portailoaa.fr.corp.leroymerlin.com/search?store=${this.project.store}` : null;
|
|
117
116
|
},
|
|
118
117
|
},
|
|
119
118
|
|
|
@@ -186,7 +186,10 @@
|
|
|
186
186
|
</div>
|
|
187
187
|
</m-flex>
|
|
188
188
|
<m-flex
|
|
189
|
-
v-if="
|
|
189
|
+
v-if="
|
|
190
|
+
isEstimatesDisplayed &&
|
|
191
|
+
(isLoadingEstimates || estimatesLoadError || (estimates && estimates.length > 0))
|
|
192
|
+
"
|
|
190
193
|
class="pb-project-hub__section"
|
|
191
194
|
direction="column"
|
|
192
195
|
full-width
|
|
@@ -16,72 +16,84 @@ export default {
|
|
|
16
16
|
parameters: { storyshots: { disable: true }, layout: 'fullscreen' },
|
|
17
17
|
};
|
|
18
18
|
|
|
19
|
-
const generateStory =
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
runtimeOptions: {
|
|
25
|
-
type: Object,
|
|
26
|
-
default: () => object('Runtime options', { projectMode: true }),
|
|
19
|
+
const generateStory =
|
|
20
|
+
(jsonLocation, headers = {}) =>
|
|
21
|
+
() => ({
|
|
22
|
+
components: {
|
|
23
|
+
PbScenario,
|
|
27
24
|
},
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
}
|
|
25
|
+
props: {
|
|
26
|
+
runtimeOptions: {
|
|
27
|
+
type: Object,
|
|
28
|
+
default: () => object('Runtime options', { projectMode: true }),
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
setup() {
|
|
32
|
+
const store = useStore();
|
|
33
|
+
store.dispatch('documentsPlans/updateContext', { type: 'DOCUMENT', subType: 'PLAN' });
|
|
34
|
+
store.dispatch('documentsPictures/updateContext', { type: 'DOCUMENT', subType: 'PHOTO' });
|
|
35
|
+
store.dispatch('estimates/setSummary', {
|
|
36
|
+
cost: {},
|
|
37
|
+
});
|
|
38
|
+
const scenarios = ref(null);
|
|
39
|
+
const hasScenario = ref(false);
|
|
40
|
+
axios.get(jsonLocation, { headers }).then((result) => {
|
|
41
|
+
scenarios.value = result.data.scenario ?? result.data;
|
|
42
|
+
hasScenario.value = true;
|
|
43
|
+
});
|
|
44
|
+
const handleScenarioEvent = (event) => {
|
|
45
|
+
console.log('Event', event);
|
|
46
|
+
};
|
|
47
|
+
return {
|
|
48
|
+
scenarios,
|
|
49
|
+
hasScenario,
|
|
50
|
+
handleScenarioEvent,
|
|
51
|
+
};
|
|
52
|
+
},
|
|
53
|
+
// eslint-disable-next-line
|
|
54
|
+
template:
|
|
55
|
+
'<pb-scenario v-if="hasScenario" :scenarios="scenarios" :runtime-options="runtimeOptions" @scenario-event="handleScenarioEvent" />',
|
|
56
|
+
});
|
|
55
57
|
|
|
56
58
|
export const estimateNewConstructionPrep = generateStory(
|
|
57
59
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/6e3e9d6d-a019-4c1c-8d25-002a4ebfcb46',
|
|
60
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
58
61
|
);
|
|
59
62
|
export const estimateDressingPrep = generateStory(
|
|
60
63
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/10df6aa4-4ae0-41a0-93e3-dc66eb9d39c8',
|
|
64
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
61
65
|
);
|
|
62
66
|
export const estimateBookcasePrep = generateStory(
|
|
63
67
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/88d96e4c-685b-4275-8eae-f50828fe4755',
|
|
68
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
64
69
|
);
|
|
65
70
|
export const estimateKitchenPrep = generateStory(
|
|
66
71
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/068160b2-b28a-46fa-8fd6-4775450fa7b4',
|
|
72
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
67
73
|
);
|
|
68
74
|
export const estimateInsulationPrep = generateStory(
|
|
69
75
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/60100496-92ea-49ab-8a43-c08afa57cd60',
|
|
76
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
70
77
|
);
|
|
71
78
|
export const estimateTvPrep = generateStory(
|
|
72
79
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/dc5370cf-0761-43a0-8309-ced76be08d8b',
|
|
80
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
73
81
|
);
|
|
74
82
|
export const estimateStoragePrep = generateStory(
|
|
75
83
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/e39126db-03f7-4b07-975a-97b4cf603ef1',
|
|
84
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
76
85
|
);
|
|
77
86
|
export const estimateHeatingPrep = generateStory(
|
|
78
87
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/eaba8264-620d-475e-830f-89166b49a667',
|
|
88
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
79
89
|
);
|
|
80
90
|
export const estimateBathroomPrep = generateStory(
|
|
81
91
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/c9c4df50-cbcb-4265-b9a7-6645d3adb03b',
|
|
92
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
82
93
|
);
|
|
83
94
|
export const estimateFloorPrep = generateStory(
|
|
84
95
|
'https://api-prep.adeo.cloud/api-project-booster-budget-estimate/v1/scenarios/LMFR_FLOOR',
|
|
96
|
+
{ 'X-gateway-apikey': 'nII0D8gvbudmDONHRJo0wbYKJAytn97x' },
|
|
85
97
|
);
|
|
86
98
|
|
|
87
99
|
export const projectDeclarationGenericPrep = generateStory(
|