import dati prodotti + fornitore + produttore
This commit is contained in:
@@ -43,7 +43,8 @@ export default defineComponent({
|
||||
const myorder = ref(<IOrder>{
|
||||
idapp: process.env.APP_ID,
|
||||
quantity: 0,
|
||||
idStorehouse: ''
|
||||
idStorehouse: '',
|
||||
idProvider: ''
|
||||
})
|
||||
|
||||
const myproduct = ref(<IProduct>{})
|
||||
@@ -166,8 +167,8 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
function getQtyWarn() {
|
||||
if (myorder.value.quantity > 0){
|
||||
return t('ecomm.di_cui_x_in_carrello', {qty: myorder.value.quantity})
|
||||
if (myorder.value.quantity > 0) {
|
||||
return t('ecomm.di_cui_x_in_carrello', { qty: myorder.value.quantity })
|
||||
}
|
||||
return ''
|
||||
}
|
||||
@@ -196,12 +197,13 @@ export default defineComponent({
|
||||
if (myproduct.value.storehouses && myproduct.value.storehouses.length === 1) {
|
||||
myorder.value.idStorehouse = myproduct.value.storehouses[0]._id
|
||||
}
|
||||
|
||||
const ord = products.getOrderProductInCart(myproduct.value._id)
|
||||
if (ord) {
|
||||
myorder.value.quantity = ord.quantity
|
||||
}
|
||||
}
|
||||
|
||||
const ord = products.getOrderProductInCart(myproduct.value._id)
|
||||
if (ord) {
|
||||
myorder.value.quantity = ord.quantity
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -209,8 +211,8 @@ export default defineComponent({
|
||||
return (props.complete) ? 'my-card-big' : 'my-card-prod'
|
||||
}
|
||||
|
||||
function getclimg() {
|
||||
return (props.complete) ? 'myimgtitle centermydiv' : 'centermydiv'
|
||||
function getclimgproduct() {
|
||||
return 'myimgproduct centermydiv'
|
||||
}
|
||||
|
||||
function enableSubQty() {
|
||||
@@ -229,7 +231,7 @@ export default defineComponent({
|
||||
addtoCart,
|
||||
iconWhishlist,
|
||||
getmycardcl,
|
||||
getclimg,
|
||||
getclimgproduct,
|
||||
getnumstore,
|
||||
getSingleStorehouse,
|
||||
getStorehouses,
|
||||
|
||||
Reference in New Issue
Block a user