aggiornamento ordini

This commit is contained in:
Surya Paolo
2023-12-14 15:20:27 +01:00
parent ba7fffdc23
commit 4ec5b12d64
11 changed files with 97 additions and 42 deletions

View File

@@ -154,8 +154,8 @@ export default defineComponent({
if (myorder.value.quantity > 0) {
myproduct.value.quantityAvailable -= myorder.value.quantity
}
if (myproduct.value.tempTotalQty > 0) {
myproduct.value.quantityAvailable -= myproduct.value.tempTotalQty
if (myproduct.value.QuantitaOrdinateInAttesa > 0) {
myproduct.value.quantityAvailable -= myproduct.value.QuantitaOrdinateInAttesa
}
}

View File

@@ -1,8 +1,7 @@
<template>
<div class="q-pa-md row items-start q-gutter-md">
<q-card :class="getmycardcl()" v-if="!!myproduct" bordered>
<!--<q-img :src="`` + myproduct.img" :alt="myproduct.name" :class="getclimg()"></q-img>-->
<img src="https://cdn.quasar.dev/img/parallax2.jpg" />
<q-img :src="`` + myproduct.img" :alt="myproduct.name" :class="getclimg()"></q-img>
<q-list>
<q-item>
@@ -46,7 +45,6 @@
myproduct.after_price
}}</span>
tempTotalQty : {{ myproduct.tempTotalQty }}
</q-item-label>
</q-item-section>
</q-item>
@@ -104,6 +102,9 @@
</span>
<span class="prod_qtywarn">
{{ getQtyWarn() }}
<div v-if="tools.isManager() && myproduct.QuantitaOrdinateInAttesa > 0">Quantita Ordinate In Attesa : {{ myproduct.QuantitaOrdinateInAttesa }}</div>
</span>
</q-item-label>
<q-item-label> </q-item-label>

View File

@@ -1,10 +1,12 @@
<template>
<div class="q-pa-xs q-gutter-xs">
order.product.img: {{ order.product.img }}
<div v-if="order.product" class="row items-center justify-evenly no-wrap">
<div class="col-2 text-h6 ellipsis">
<img
v-if="order.product && order.product.img" :src="`` + order.product.img" :alt="order.product.name" :class="myimgclass">
<q-img v-if="order.product && order.product.img" :src="`` + order.product.img" :alt="order.product.name"
:class="myimgclass">
</q-img>
</div>
<div class="col-4 q-ml-xs">
{{ order.product.name }}
@@ -14,8 +16,7 @@
</div>
<div class="col-3">
<div class="row q-mb-xs no-wrap items-center centeritems">
<q-btn
v-if="showall && !nomodif" round size="xs" text-color="grey" icon="fas fa-minus"
<q-btn v-if="showall && !nomodif" round size="xs" text-color="grey" icon="fas fa-minus"
@click="addsubqty(false, true)"></q-btn>
<!--<q-field outlined dense style="width: 25px; height: 20px; " class="q-mx-xs text-subtitle4">
<template v-slot:control>
@@ -23,8 +24,7 @@
</template>
</q-field>-->
<div :class="`q-mx-sm text-blue-14`">{{ order.quantity }}</div>
<q-btn
v-if="showall && !nomodif" round size="xs" text-color="grey" icon="fas fa-plus"
<q-btn v-if="showall && !nomodif" round size="xs" text-color="grey" icon="fas fa-plus"
@click="addsubqty(true, false)"></q-btn>
</div>
</div>