@revenexx/cover 0.2.41 → 0.2.42
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.
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import CartApprovalsPanel from "./CartApprovalsPanel.vue";
|
|
3
3
|
import CartWorkflowPickerModal from "../actions/CartWorkflowPickerModal.vue";
|
|
4
4
|
import PunchoutTransferAction from "../../punchout/action/PunchoutTransferAction.vue";
|
|
5
|
+
import CartQuoteRequestModal from "../quote/CartQuoteRequestModal.vue";
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Cart summary 2.0: the calculated totals block in document order, the
|
|
@@ -40,6 +41,12 @@ const totals = computed(() =>
|
|
|
40
41
|
const isRequester = computed(() => role.value === "requester");
|
|
41
42
|
const orderable = computed(() => calculation.value?.orderable ?? true);
|
|
42
43
|
|
|
44
|
+
// A cart the shop cannot order as it is, but can quote (RX-783): the checkout
|
|
45
|
+
// button becomes the quotation request, because that is the one way on.
|
|
46
|
+
const quoteMessage = computed(() =>
|
|
47
|
+
(calculation.value?.messages ?? []).find(message => message.action === "request-quote") ?? null);
|
|
48
|
+
const quoteOpen = ref(false);
|
|
49
|
+
|
|
43
50
|
/* ---- CTA (spec 5 / 5a) -------------------------------------------- */
|
|
44
51
|
const workflowModalOpen = ref(false);
|
|
45
52
|
const noWorkflowModalOpen = ref(false);
|
|
@@ -228,6 +235,26 @@ const trustItems = computed(() => {
|
|
|
228
235
|
<CartApprovalsPanel :limits="calculation?.approvalLimits ?? []" />
|
|
229
236
|
|
|
230
237
|
<PunchoutTransferAction v-if="isPunchout" />
|
|
238
|
+
<template v-else-if="quoteMessage">
|
|
239
|
+
<UButton
|
|
240
|
+
color="primary"
|
|
241
|
+
variant="solid"
|
|
242
|
+
size="lg"
|
|
243
|
+
class="w-full justify-center mt-2"
|
|
244
|
+
:icon="icon('file')"
|
|
245
|
+
:loading="pending"
|
|
246
|
+
:label="t('cart.quote.action')"
|
|
247
|
+
tabindex="0"
|
|
248
|
+
@click="quoteOpen = true"
|
|
249
|
+
/>
|
|
250
|
+
<p class="text-xs text-muted text-center">
|
|
251
|
+
{{ t('cart.quote.ctaHint') }}
|
|
252
|
+
</p>
|
|
253
|
+
<CartQuoteRequestModal
|
|
254
|
+
v-model:open="quoteOpen"
|
|
255
|
+
:reason="quoteMessage.code"
|
|
256
|
+
/>
|
|
257
|
+
</template>
|
|
231
258
|
<template v-else>
|
|
232
259
|
<UButton
|
|
233
260
|
color="primary"
|
|
@@ -218,6 +218,7 @@
|
|
|
218
218
|
},
|
|
219
219
|
"quote": {
|
|
220
220
|
"action": "Angebot anfordern",
|
|
221
|
+
"ctaHint": "Versand auf Anfrage – wir kalkulieren die Fracht, bestellt wird anschließend aus Ihrem Kundenkonto.",
|
|
221
222
|
"title": "Angebot anfordern",
|
|
222
223
|
"description": "Wir kalkulieren die Fracht für Ihre Sendung und schicken Ihnen ein Angebot.",
|
|
223
224
|
"shippingAddress": "Lieferadresse",
|
|
@@ -218,6 +218,7 @@
|
|
|
218
218
|
},
|
|
219
219
|
"quote": {
|
|
220
220
|
"action": "Request a quote",
|
|
221
|
+
"ctaHint": "Shipping on request – we price the carriage, you order from your account afterwards.",
|
|
221
222
|
"title": "Request a quote",
|
|
222
223
|
"description": "We price the carriage for your consignment and send you a quote.",
|
|
223
224
|
"shippingAddress": "Shipping address",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@revenexx/cover",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.42",
|
|
4
4
|
"description": "Cover \u2014 revenexx design system for Nuxt. Distributed as a Nuxt layer: generic UI components, theming tokens and stores shared by the demo shop, custom storefronts and the Blokkli theme.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./nuxt.config.ts",
|