- Uscita PRIMA VERSIONE PiuCheBuono.app
This commit is contained in:
@@ -142,7 +142,7 @@ export default defineComponent({
|
|||||||
+ ' ' + t('gas.data_arrivo_merce') + ': ' + tools.getstrDateShort(mygas.data_arrivo_merce)
|
+ ' ' + t('gas.data_arrivo_merce') + ': ' + tools.getstrDateShort(mygas.data_arrivo_merce)
|
||||||
+ ' ' + t('gas.dataora_ritiro') + ': ' + tools.getstrDateShort(mygas.dataora_ritiro)*/
|
+ ' ' + t('gas.dataora_ritiro') + ': ' + tools.getstrDateShort(mygas.dataora_ritiro)*/
|
||||||
|
|
||||||
return mygas.name
|
return mygas.name
|
||||||
else
|
else
|
||||||
return ''
|
return ''
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
@@ -352,6 +352,17 @@ export default defineComponent({
|
|||||||
}, 0))
|
}, 0))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function isOrdGas(): boolean {
|
||||||
|
return myproduct.value && myproduct.value.idGasordines ? myproduct.value.idGasordines.length > 0 : false
|
||||||
|
}
|
||||||
|
|
||||||
|
function getpercqtaraggiunta(): number {
|
||||||
|
if (myproduct.value)
|
||||||
|
return tools.calcperc(myproduct.value.bookedGASQtyOrdered, myproduct.value.qtyToReachForGas) / 100
|
||||||
|
else
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
onMounted(mounted)
|
onMounted(mounted)
|
||||||
onBeforeUnmount(beforeDestroy)
|
onBeforeUnmount(beforeDestroy)
|
||||||
|
|
||||||
@@ -389,6 +400,8 @@ export default defineComponent({
|
|||||||
timerLabelScadenza,
|
timerLabelScadenza,
|
||||||
labelDataRitiro,
|
labelDataRitiro,
|
||||||
labelDataArrivoMerce,
|
labelDataArrivoMerce,
|
||||||
|
getpercqtaraggiunta,
|
||||||
|
isOrdGas,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -136,13 +136,127 @@
|
|||||||
</q-item-label>
|
</q-item-label>
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
</q-item>
|
</q-item>
|
||||||
|
<q-item v-if="myproduct.note">
|
||||||
|
<q-item-section avatar>
|
||||||
|
<q-icon color="black" name="fas fa-book" />
|
||||||
|
</q-item-section>
|
||||||
|
|
||||||
|
<q-item-section>
|
||||||
|
<q-item-label class="">
|
||||||
|
<span v-html="myproduct.note"></span>
|
||||||
|
</q-item-label>
|
||||||
|
</q-item-section>
|
||||||
|
<q-item-section
|
||||||
|
v-if="
|
||||||
|
tools.isManager() &&
|
||||||
|
products.getQtyBloccataAvailable(myproduct) > 0
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<q-item-section avatar>
|
||||||
|
<q-icon
|
||||||
|
name="fas fa-store"
|
||||||
|
style="padding-right: 16px !important"
|
||||||
|
/>
|
||||||
|
</q-item-section>
|
||||||
|
<q-item-section
|
||||||
|
v-if="
|
||||||
|
tools.isManager() &&
|
||||||
|
products.getQtyBloccataAvailable(myproduct) > 0
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<q-item-label> {{ t('ecomm.bloccati') }}: </q-item-label>
|
||||||
|
<q-item-label>
|
||||||
|
<span class="text-black q-ml-xs text-h8">
|
||||||
|
{{ products.getQtyBloccataAvailable(myproduct) }}</span
|
||||||
|
>
|
||||||
|
</q-item-label>
|
||||||
|
</q-item-section>
|
||||||
|
</q-item-section>
|
||||||
|
</q-item>
|
||||||
|
<q-item v-if="isOrdGas() && myproduct.qtyToReachForGas > 0">
|
||||||
|
<q-item-section avatar>
|
||||||
|
<q-icon
|
||||||
|
v-if="getpercqtaraggiunta() < 1"
|
||||||
|
color="orange"
|
||||||
|
name="fas fa-lightbulb"
|
||||||
|
/>
|
||||||
|
<q-icon v-else color="green" name="fas fa-check" />
|
||||||
|
</q-item-section>
|
||||||
|
|
||||||
|
<q-item-section>
|
||||||
|
<q-item-label class="subtit_prod text-blue text-bold">
|
||||||
|
<span v-if="getpercqtaraggiunta() >= 1">{{
|
||||||
|
t('ecomm.offerta_gas_raggiunta', {
|
||||||
|
qta: myproduct.qtyToReachForGas,
|
||||||
|
unit: tools.getUnitsMeasure(myproduct.productInfo.unit, true),
|
||||||
|
})
|
||||||
|
}}</span>
|
||||||
|
<span v-else>{{
|
||||||
|
t('ecomm.offerta_gas', {
|
||||||
|
qta: myproduct.qtyToReachForGas,
|
||||||
|
unit: tools.getUnitsMeasure(myproduct.productInfo.unit, true),
|
||||||
|
})
|
||||||
|
}}</span>
|
||||||
|
</q-item-label>
|
||||||
|
<q-item-label>
|
||||||
|
<span class="prod_disp">
|
||||||
|
{{
|
||||||
|
t('ecomm.bookedGASQtyOrdered_str', {
|
||||||
|
qta: myproduct.bookedGASQtyOrdered,
|
||||||
|
qtatot: myproduct.qtyToReachForGas,
|
||||||
|
})
|
||||||
|
}}
|
||||||
|
<q-linear-progress size="10px" :value="getpercqtaraggiunta()" />
|
||||||
|
</span>
|
||||||
|
<div class="prod_qtywarn">
|
||||||
|
<div
|
||||||
|
v-if="
|
||||||
|
tools.isManager() && !!myproduct.QuantitaOrdinateInAttesa
|
||||||
|
"
|
||||||
|
>
|
||||||
|
{{
|
||||||
|
t('ecomm.qta_in_attesa', {
|
||||||
|
qty: myproduct.QuantitaOrdinateInAttesa,
|
||||||
|
})
|
||||||
|
}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</q-item-label>
|
||||||
|
</q-item-section>
|
||||||
|
<q-item-section
|
||||||
|
v-if="
|
||||||
|
tools.isManager() &&
|
||||||
|
products.getQtyBloccataAvailable(myproduct) > 0
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<q-item-section avatar>
|
||||||
|
<q-icon
|
||||||
|
name="fas fa-store"
|
||||||
|
style="padding-right: 16px !important"
|
||||||
|
/>
|
||||||
|
</q-item-section>
|
||||||
|
<q-item-section
|
||||||
|
v-if="
|
||||||
|
tools.isManager() &&
|
||||||
|
products.getQtyBloccataAvailable(myproduct) > 0
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<q-item-label> {{ t('ecomm.bloccati') }}: </q-item-label>
|
||||||
|
<q-item-label>
|
||||||
|
<span class="text-black q-ml-xs text-h8">
|
||||||
|
{{ products.getQtyBloccataAvailable(myproduct) }}</span
|
||||||
|
>
|
||||||
|
</q-item-label>
|
||||||
|
</q-item-section>
|
||||||
|
</q-item-section>
|
||||||
|
</q-item>
|
||||||
<q-item v-if="myproduct.gasordines && myproduct.gasordines.length >= 1">
|
<q-item v-if="myproduct.gasordines && myproduct.gasordines.length >= 1">
|
||||||
<q-item-section avatar>
|
<q-item-section avatar>
|
||||||
<q-icon color="blue" name="fas fa-hourglass-half" />
|
<q-icon color="blue" name="fas fa-hourglass-half" />
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
|
|
||||||
<q-item-section>
|
<q-item-section>
|
||||||
<q-item-label class="subtit_prod">
|
<q-item-label class="subtit_prod">
|
||||||
{{ t('gas.dataora_chiusura_ordini') }}
|
{{ t('gas.dataora_chiusura_ordini') }}
|
||||||
</q-item-label>
|
</q-item-label>
|
||||||
<q-item-label class="countdown_scadenza">
|
<q-item-label class="countdown_scadenza">
|
||||||
@@ -207,79 +321,10 @@
|
|||||||
|
|
||||||
<div>
|
<div>
|
||||||
<q-list>
|
<q-list>
|
||||||
<q-item
|
|
||||||
v-if="
|
|
||||||
cosa === shared_consts.PROD.BOTTEGA ||
|
|
||||||
(cosa === shared_consts.PROD.GAS &&
|
|
||||||
products.getQtyAvailable(myproduct) > 0)
|
|
||||||
"
|
|
||||||
:clickable="tools.isManager()"
|
|
||||||
@click="
|
|
||||||
tools.isManager() &&
|
|
||||||
myproduct.QuantitaOrdinateInAttesa &&
|
|
||||||
myproduct.QuantitaOrdinateInAttesa > 0
|
|
||||||
? visuListDisponibili()
|
|
||||||
: null
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<q-item-section avatar>
|
|
||||||
<q-icon color="green" name="fas fa-store" />
|
|
||||||
</q-item-section>
|
|
||||||
|
|
||||||
<q-item-section>
|
|
||||||
<q-item-label class="subtit_prod">
|
|
||||||
{{ t('ecomm.available') }}
|
|
||||||
</q-item-label>
|
|
||||||
<q-item-label>
|
|
||||||
<span class="prod_disp">
|
|
||||||
{{ products.getQtyAvailable(myproduct) }}
|
|
||||||
</span>
|
|
||||||
<div class="prod_qtywarn">
|
|
||||||
<div
|
|
||||||
v-if="
|
|
||||||
tools.isManager() && !!myproduct.QuantitaOrdinateInAttesa
|
|
||||||
"
|
|
||||||
>
|
|
||||||
{{
|
|
||||||
t('ecomm.qta_in_attesa', {
|
|
||||||
qty: myproduct.QuantitaOrdinateInAttesa,
|
|
||||||
})
|
|
||||||
}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</q-item-label>
|
|
||||||
</q-item-section>
|
|
||||||
<q-item-section
|
|
||||||
v-if="
|
|
||||||
tools.isManager() &&
|
|
||||||
products.getQtyBloccataAvailable(myproduct) > 0
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<q-item-section avatar>
|
|
||||||
<q-icon
|
|
||||||
name="fas fa-store"
|
|
||||||
style="padding-right: 16px !important"
|
|
||||||
/>
|
|
||||||
</q-item-section>
|
|
||||||
<q-item-section
|
|
||||||
v-if="
|
|
||||||
tools.isManager() &&
|
|
||||||
products.getQtyBloccataAvailable(myproduct) > 0
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<q-item-label> {{ t('ecomm.bloccati') }}: </q-item-label>
|
|
||||||
<q-item-label>
|
|
||||||
<span class="text-black q-ml-xs text-h8">
|
|
||||||
{{ products.getQtyBloccataAvailable(myproduct) }}</span
|
|
||||||
>
|
|
||||||
</q-item-label>
|
|
||||||
</q-item-section>
|
|
||||||
</q-item-section>
|
|
||||||
</q-item>
|
|
||||||
<q-item
|
<q-item
|
||||||
v-if="
|
v-if="
|
||||||
products.getQtyBookableAvailable(myproduct) > 0 ||
|
products.getQtyBookableAvailable(myproduct) > 0 ||
|
||||||
myproduct.bookableQty > 0
|
myproduct.maxbookableGASQty > 0
|
||||||
"
|
"
|
||||||
:clickable="tools.isManager()"
|
:clickable="tools.isManager()"
|
||||||
@click="
|
@click="
|
||||||
@@ -330,10 +375,14 @@
|
|||||||
/>
|
/>
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
<q-item-section>
|
<q-item-section>
|
||||||
<q-item-label class="subtit_prod"> {{ t('ecomm.bloccati') }}: </q-item-label>
|
<q-item-label class="subtit_prod">
|
||||||
|
{{ t('ecomm.bloccati') }}:
|
||||||
|
</q-item-label>
|
||||||
<q-item-label>
|
<q-item-label>
|
||||||
<span class="text-black q-ml-xs text-h8">
|
<span class="text-black q-ml-xs text-h8">
|
||||||
{{ products.getQtyBloccataBookableAvailable(myproduct) }}</span
|
{{
|
||||||
|
products.getQtyBloccataBookableAvailable(myproduct)
|
||||||
|
}}</span
|
||||||
>
|
>
|
||||||
</q-item-label>
|
</q-item-label>
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ export interface IProductInfo {
|
|||||||
color?: string,
|
color?: string,
|
||||||
size?: string,
|
size?: string,
|
||||||
weight?: number,
|
weight?: number,
|
||||||
unit?: number,
|
unit: number,
|
||||||
stars?: number,
|
stars?: number,
|
||||||
date?: Date,
|
date?: Date,
|
||||||
icon?: string,
|
icon?: string,
|
||||||
@@ -40,15 +40,22 @@ export interface IProduct {
|
|||||||
bookableAvailableQty?: number,
|
bookableAvailableQty?: number,
|
||||||
QuantitaOrdinateInAttesa?: number,
|
QuantitaOrdinateInAttesa?: number,
|
||||||
QuantitaPrenotateInAttesa?: number,
|
QuantitaPrenotateInAttesa?: number,
|
||||||
stockQty: number,
|
note?: string
|
||||||
stockBloccatiQty: number,
|
|
||||||
minBuyQty: number,
|
stockQty: number, // UPDATING
|
||||||
minStepQty: number,
|
stockBloccatiQty: number, // UPDATING
|
||||||
maxBookableQty: number,
|
bookedQtyConfirmed: number // UPDATING
|
||||||
bookableQty: number,
|
|
||||||
bookableBloccatiQty: number,
|
qtyToReachForGas: number
|
||||||
canBeShipped?: boolean,
|
maxbookableGASQty: number
|
||||||
canBeBuyOnline?: boolean,
|
bookedGASQtyOrdered: number // UPDATING
|
||||||
|
bookableGASBloccatiQty: number // UPDATING
|
||||||
|
|
||||||
|
minBuyQty: number
|
||||||
|
minStepQty: number
|
||||||
|
maxBookableSinglePersQty: number
|
||||||
|
canBeShipped?: boolean
|
||||||
|
canBeBuyOnline?: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface IBaseOrder {
|
export interface IBaseOrder {
|
||||||
@@ -136,8 +143,11 @@ export interface IStorehouse {
|
|||||||
email_html_header?: string,
|
email_html_header?: string,
|
||||||
email_html_footer?: string,
|
email_html_footer?: string,
|
||||||
email_html_makeorder?: string,
|
email_html_makeorder?: string,
|
||||||
|
email_html_GAS_makeorder?: string,
|
||||||
email_html_order_confirmed?: string,
|
email_html_order_confirmed?: string,
|
||||||
|
email_html_GAS_order_confirmed?: string,
|
||||||
email_html_order_consegnato?: string,
|
email_html_order_consegnato?: string,
|
||||||
|
email_html_GAS_order_consegnato?: string,
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface IProvider {
|
export interface IProvider {
|
||||||
@@ -204,8 +214,8 @@ export interface IOrderCart {
|
|||||||
nameSurname?: string
|
nameSurname?: string
|
||||||
status: number
|
status: number
|
||||||
modify_at?: Date
|
modify_at?: Date
|
||||||
evaso: boolean
|
confermato: boolean
|
||||||
date_evaso?: Date
|
date_confermato?: Date
|
||||||
consegnato: boolean
|
consegnato: boolean
|
||||||
date_consegnato?: Date
|
date_consegnato?: Date
|
||||||
pagato: boolean
|
pagato: boolean
|
||||||
|
|||||||
@@ -337,21 +337,28 @@ export default defineComponent({
|
|||||||
return importNoSpazi(cmd, testo);
|
return importNoSpazi(cmd, testo);
|
||||||
}
|
}
|
||||||
|
|
||||||
function addfield(col: number, field: string, rec: any, conv_euro: boolean, isnumero?: boolean, strinput?: string, primo?: boolean) {
|
function addfield(col: number, field: string, rec: any, opt: any) {
|
||||||
let risultato = ''
|
let risultato = ''
|
||||||
let valstr = strinput ? strinput : rec[col]
|
try {
|
||||||
if (isnumero) {
|
let valstr = opt.strinput ? opt.strinput : rec[col]
|
||||||
valstr = valstr.replace(',', '.');
|
|
||||||
}
|
|
||||||
if (conv_euro) {
|
|
||||||
valstr = tools.convertPriceEurToValue(valstr)
|
|
||||||
}
|
|
||||||
valstr = tools.removeescape(tools.addslashes(valstr))
|
|
||||||
if (!primo)
|
|
||||||
risultato += ', '
|
|
||||||
|
|
||||||
risultato += '"' + field + '":"' + valstr + '"'
|
if (opt.isnumero) {
|
||||||
return risultato;
|
if (valstr === '')
|
||||||
|
valstr = '0';
|
||||||
|
valstr = valstr.replace(',', '.');
|
||||||
|
}
|
||||||
|
if (opt.iseuro) {
|
||||||
|
valstr = tools.convertPriceEurToValue(valstr)
|
||||||
|
}
|
||||||
|
valstr = tools.removeescape(tools.addslashes(valstr))
|
||||||
|
if (!opt.primo)
|
||||||
|
risultato += ', '
|
||||||
|
|
||||||
|
risultato += '"' + field + '":"' + valstr + '"'
|
||||||
|
return risultato;
|
||||||
|
} catch (e) {
|
||||||
|
console.error('err', e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const myarr = tools.CSVToArray(testo, delim)
|
const myarr = tools.CSVToArray(testo, delim)
|
||||||
@@ -395,29 +402,32 @@ export default defineComponent({
|
|||||||
if (!primo) {
|
if (!primo) {
|
||||||
strris += ', '
|
strris += ', '
|
||||||
}
|
}
|
||||||
|
|
||||||
strris += '{ '
|
strris += '{ '
|
||||||
let col = 0;
|
let col = 0;
|
||||||
strris += addfield(col, 'idapp', rec, false, false, tools.appid(), true);
|
strris += addfield(col, 'idapp', rec, { strinput: tools.appid(), primo: true });
|
||||||
strris += addfield(col, 'code', rec, false); col++;
|
strris += addfield(col, 'code', rec, {}); col++;
|
||||||
strris += addfield(col, 'name', rec, false); col++;
|
strris += addfield(col, 'name', rec, {}); col++;
|
||||||
strris += addfield(col, 'price', rec, true); col++;
|
strris += addfield(col, 'price', rec, { iseuro: true }); col++;
|
||||||
strris += addfield(col, 'stockQty', rec, true); col++;
|
strris += addfield(col, 'stockQty', rec, { isnumero: true }); col++;
|
||||||
col++;
|
col++;
|
||||||
strris += addfield(col, 'weight', rec, false, true); col++;
|
strris += addfield(col, 'weight', rec, { isnumero: true }); col++;
|
||||||
strris += addfield(col, 'unit', rec, false); col++;
|
strris += addfield(col, 'unit', rec, {}); col++;
|
||||||
strris += addfield(col, 'link', rec, false); col++;
|
strris += addfield(col, 'link', rec, {}); col++;
|
||||||
strris += addfield(col, 'perc_iva', rec, false); col++;
|
strris += addfield(col, 'perc_iva', rec, {}); col++;
|
||||||
strris += addfield(col, 'price_acquistato', rec, true); col++;
|
strris += addfield(col, 'price_acquistato', rec, { isnumero: true }); col++;
|
||||||
strris += addfield(col, 'minBuyQty', rec, false, true); col++;
|
strris += addfield(col, 'minBuyQty', rec, { isnumero: true }); col++;
|
||||||
strris += addfield(col, 'minStepQty', rec, false, true); col++;
|
strris += addfield(col, 'minStepQty', rec, { isnumero: true }); col++;
|
||||||
strris += addfield(col, 'cat_name', rec, false); col++;
|
strris += addfield(col, 'cat_name', rec,{}); col++;
|
||||||
strris += addfield(col, 'producer_name', rec, false); col++;
|
strris += addfield(col, 'producer_name', rec, {}); col++;
|
||||||
strris += addfield(col, 'provider_name', rec, false); col++;
|
strris += addfield(col, 'provider_name', rec, {}); col++;
|
||||||
strris += addfield(col, 'magazzino_name', rec, false); col++;
|
strris += addfield(col, 'magazzino_name', rec, {}); col++;
|
||||||
strris += addfield(col, 'bookableQty', rec, false, true); col++;
|
strris += addfield(col, 'qtyToReachForGas', rec, { isnumero: true }); col++;
|
||||||
strris += addfield(col, 'sconto1', rec, false, true); col++;
|
strris += addfield(col, 'maxbookableGASQty', rec, { isnumero: true }); col++;
|
||||||
strris += addfield(col, 'sconto2', rec, false, true); col++;
|
strris += addfield(col, 'sconto1', rec, {}); col++;
|
||||||
strris += addfield(col, 'gas_name', rec, false, true); col++;
|
strris += addfield(col, 'sconto2', rec, {}); col++;
|
||||||
|
strris += addfield(col, 'gas_name', rec, {}); col++;
|
||||||
|
strris += addfield(col, 'note', rec, {}); col++;
|
||||||
strris += '} '
|
strris += '} '
|
||||||
|
|
||||||
} else if (cmd === shared_consts.Cmd.CITIES_SERVER) {
|
} else if (cmd === shared_consts.Cmd.CITIES_SERVER) {
|
||||||
@@ -450,7 +460,7 @@ export default defineComponent({
|
|||||||
|
|
||||||
return risultato
|
return risultato
|
||||||
}
|
}
|
||||||
|
|
||||||
function loadTextFromFile(ev: any) {
|
function loadTextFromFile(ev: any) {
|
||||||
console.log('ev', ev)
|
console.log('ev', ev)
|
||||||
const file = ev.target.files[0]
|
const file = ev.target.files[0]
|
||||||
|
|||||||
@@ -65,8 +65,9 @@ const msg_it = {
|
|||||||
stockBloccatiQty: 'Bloccati In Magazzino',
|
stockBloccatiQty: 'Bloccati In Magazzino',
|
||||||
minBuyQty: 'Qta minima acquistabile',
|
minBuyQty: 'Qta minima acquistabile',
|
||||||
minStepQty: 'Step Minimo',
|
minStepQty: 'Step Minimo',
|
||||||
maxBookableQty: 'Qtà massima prenotabile singolarm.',
|
maxBookableSinglePersQty: 'Qtà massima prenotabile singolarm.',
|
||||||
bookableQty: 'Prenotabili',
|
maxbookableGASQty: 'Prenotabili',
|
||||||
|
bookedQtyConfirmed: 'Quantità Confermate',
|
||||||
bookableAvailableQty: 'Disponib. Prenotabili',
|
bookableAvailableQty: 'Disponib. Prenotabili',
|
||||||
weight: 'Peso',
|
weight: 'Peso',
|
||||||
unit: 'Unità di Misura',
|
unit: 'Unità di Misura',
|
||||||
@@ -367,7 +368,7 @@ const msg_it = {
|
|||||||
incorrect_input: 'Inserimento incorretto.',
|
incorrect_input: 'Inserimento incorretto.',
|
||||||
link_sent: 'Apri la tua casella di posta, trova la email "Confermare la Registrazione: {sitename}" e clicca su "Verifica Registrazione"',
|
link_sent: 'Apri la tua casella di posta, trova la email "Confermare la Registrazione: {sitename}" e clicca su "Verifica Registrazione"',
|
||||||
reg_ok: 'Registrazione Avvenuta. Esegui il Login inserendo le tue credenziali',
|
reg_ok: 'Registrazione Avvenuta. Esegui il Login inserendo le tue credenziali',
|
||||||
se_non_ricevo: 'Se non ricevi la email, prova a controllare nella spam, oppure contattaci',
|
se_non_ricevo: 'Se non ricevi la email, <strong>prova a controllare nella spam</strong>, oppure contattaci',
|
||||||
title_unsubscribe: 'Disiscrizione alla newsletter',
|
title_unsubscribe: 'Disiscrizione alla newsletter',
|
||||||
title_unsubscribe_done: 'Disiscrizione completata correttamente',
|
title_unsubscribe_done: 'Disiscrizione completata correttamente',
|
||||||
},
|
},
|
||||||
@@ -1123,8 +1124,11 @@ const msg_it = {
|
|||||||
email_html_header: 'Instestazione',
|
email_html_header: 'Instestazione',
|
||||||
email_html_footer: 'Footer',
|
email_html_footer: 'Footer',
|
||||||
email_html_makeorder: '1) Ordine Ricevuto',
|
email_html_makeorder: '1) Ordine Ricevuto',
|
||||||
|
email_html_GAS_makeorder: '1) Ordine GAS Ricevuto',
|
||||||
email_html_order_confirmed: '2) Ordine Confermato da noi',
|
email_html_order_confirmed: '2) Ordine Confermato da noi',
|
||||||
email_html_order_consegnato: '3) Ordine Completato Correttamente',
|
email_html_GAS_order_confirmed: '2) Ordine GAS Confermato da noi',
|
||||||
|
email_html_order_consegnato: '3) Ordine Consegnato',
|
||||||
|
email_html_GAS_order_consegnato: '3) Ordine GAS Consegnato',
|
||||||
},
|
},
|
||||||
sectors: {
|
sectors: {
|
||||||
name: 'Settore',
|
name: 'Settore',
|
||||||
@@ -1664,13 +1668,13 @@ const msg_it = {
|
|||||||
order: 'Ordine',
|
order: 'Ordine',
|
||||||
ord_confirmed: 'Ordine Confermato',
|
ord_confirmed: 'Ordine Confermato',
|
||||||
ord_not_confirmed: 'E\' avvenuto un errore. Ordine non Confermato. Ricaricare la pagina e riprovare.',
|
ord_not_confirmed: 'E\' avvenuto un errore. Ordine non Confermato. Ricaricare la pagina e riprovare.',
|
||||||
btn_cassa: 'Vai alla Cassa',
|
btn_cassa: 'Procedi all\'Ordine',
|
||||||
btn_ordini: 'Vai agli Ordini',
|
btn_ordini: 'I tuoi Ordini',
|
||||||
available: 'Disponibili',
|
available: 'Disponibili',
|
||||||
preorders: 'Quantità Pre-Ordinabili',
|
preorders: 'Quantità Massima Pre-Ordinabili',
|
||||||
preord: 'Pre-Ordinate',
|
preord: 'Pre-Ordinate',
|
||||||
di_cui_x_in_carrello: '(nel tuo carrello: {qty})',
|
di_cui_x_in_carrello: '(nel tuo carrello: {qty})',
|
||||||
evaso: 'Ordine Evaso',
|
confermato: 'Ordine Confermato',
|
||||||
consegnato: 'Ordine Consegnato',
|
consegnato: 'Ordine Consegnato',
|
||||||
pagato: 'Ordine Pagato',
|
pagato: 'Ordine Pagato',
|
||||||
spedito: 'Ordine Spedito',
|
spedito: 'Ordine Spedito',
|
||||||
@@ -1689,6 +1693,13 @@ const msg_it = {
|
|||||||
qta_prenotate_in_attesa: '(Preordinate In attesa {qty})',
|
qta_prenotate_in_attesa: '(Preordinate In attesa {qty})',
|
||||||
prodotti_trovati: '{qta} Prodotti trovati su {qtatot}',
|
prodotti_trovati: '{qta} Prodotti trovati su {qtatot}',
|
||||||
bloccati: 'Bloccati',
|
bloccati: 'Bloccati',
|
||||||
|
bookedGASQtyOrdered: 'Prenotate',
|
||||||
|
bookedGASQtyOrdered_str: 'Prenotati {qta} su {qtatot} {unit}',
|
||||||
|
booked_su_str: '{qta} su {qtatot}',
|
||||||
|
qtyToReachForGas: 'Qta da raggiungere',
|
||||||
|
offerta_gas: 'Offerta valida al raggiungimento di {qta} {unit}',
|
||||||
|
offerta_gas_raggiunta: 'Complimenti! Gli ordini hanno superato il minimo quantitativo di {qta} {unit}',
|
||||||
|
note: 'Note',
|
||||||
},
|
},
|
||||||
gas: {
|
gas: {
|
||||||
name: 'Ordine Gas',
|
name: 'Ordine Gas',
|
||||||
|
|||||||
@@ -352,8 +352,8 @@ export const getcolorderscart = [
|
|||||||
AddCol({ name: 'items', label_trans: 'order.items' }),
|
AddCol({ name: 'items', label_trans: 'order.items' }),
|
||||||
AddCol({ name: 'userId', label_trans: 'order.users', fieldtype: costanti.FieldType.select, jointable: 'users' }),
|
AddCol({ name: 'userId', label_trans: 'order.users', fieldtype: costanti.FieldType.select, jointable: 'users' }),
|
||||||
AddCol({ name: 'note', label_trans: 'order.note' }),
|
AddCol({ name: 'note', label_trans: 'order.note' }),
|
||||||
AddCol({ name: 'evaso', label_trans: 'order.evaso', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'confermato', label_trans: 'order.confermato', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({ name: 'date_evaso', label_trans: 'order.date_evaso', fieldtype: costanti.FieldType.date }),
|
AddCol({ name: 'date_confermato', label_trans: 'order.date_confermato', fieldtype: costanti.FieldType.date }),
|
||||||
AddCol({ name: 'consegnato', label_trans: 'order.consegnato', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'consegnato', label_trans: 'order.consegnato', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({ name: 'date_consegnato', label_trans: 'order.date_consegnato', fieldtype: costanti.FieldType.date }),
|
AddCol({ name: 'date_consegnato', label_trans: 'order.date_consegnato', fieldtype: costanti.FieldType.date }),
|
||||||
AddCol({ name: 'pagato', label_trans: 'order.pagato', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'pagato', label_trans: 'order.pagato', fieldtype: costanti.FieldType.boolean }),
|
||||||
@@ -438,8 +438,11 @@ export const colTableStorehouse = [
|
|||||||
AddCol({ name: 'email_html_header', label_trans: 'store.email_html_header', fieldtype: costanti.FieldType.html }),
|
AddCol({ name: 'email_html_header', label_trans: 'store.email_html_header', fieldtype: costanti.FieldType.html }),
|
||||||
AddCol({ name: 'email_html_footer', label_trans: 'store.email_html_footer', fieldtype: costanti.FieldType.html }),
|
AddCol({ name: 'email_html_footer', label_trans: 'store.email_html_footer', fieldtype: costanti.FieldType.html }),
|
||||||
AddCol({ name: 'email_html_makeorder', label_trans: 'store.email_html_makeorder', fieldtype: costanti.FieldType.html }),
|
AddCol({ name: 'email_html_makeorder', label_trans: 'store.email_html_makeorder', fieldtype: costanti.FieldType.html }),
|
||||||
|
AddCol({ name: 'email_html_GAS_makeorder', label_trans: 'store.email_html_GAS_makeorder', fieldtype: costanti.FieldType.html }),
|
||||||
AddCol({ name: 'email_html_order_confirmed', label_trans: 'store.email_html_order_confirmed', fieldtype: costanti.FieldType.html }),
|
AddCol({ name: 'email_html_order_confirmed', label_trans: 'store.email_html_order_confirmed', fieldtype: costanti.FieldType.html }),
|
||||||
|
AddCol({ name: 'email_html_GAS_order_confirmed', label_trans: 'store.email_html_GAS_order_confirmed', fieldtype: costanti.FieldType.html }),
|
||||||
AddCol({ name: 'email_html_order_consegnato', label_trans: 'store.email_html_order_consegnato', fieldtype: costanti.FieldType.html }),
|
AddCol({ name: 'email_html_order_consegnato', label_trans: 'store.email_html_order_consegnato', fieldtype: costanti.FieldType.html }),
|
||||||
|
AddCol({ name: 'email_html_GAS_order_consegnato', label_trans: 'store.email_GAS_html_order_consegnato', fieldtype: costanti.FieldType.html }),
|
||||||
AddCol(DeleteRec),
|
AddCol(DeleteRec),
|
||||||
AddCol(DuplicateRec),
|
AddCol(DuplicateRec),
|
||||||
]
|
]
|
||||||
@@ -2057,8 +2060,8 @@ export const colTableProducts = [
|
|||||||
fieldtype: costanti.FieldType.number
|
fieldtype: costanti.FieldType.number
|
||||||
}),
|
}),
|
||||||
AddCol({
|
AddCol({
|
||||||
name: 'maxBookableQty',
|
name: 'maxBookableSinglePersQty',
|
||||||
label_trans: 'products.maxBookableQty',
|
label_trans: 'products.maxBookableSinglePersQty',
|
||||||
fieldtype: costanti.FieldType.number
|
fieldtype: costanti.FieldType.number
|
||||||
}),
|
}),
|
||||||
AddCol({
|
AddCol({
|
||||||
@@ -2066,21 +2069,43 @@ export const colTableProducts = [
|
|||||||
label_trans: 'products.stockQty',
|
label_trans: 'products.stockQty',
|
||||||
fieldtype: costanti.FieldType.number
|
fieldtype: costanti.FieldType.number
|
||||||
}),
|
}),
|
||||||
AddCol({
|
|
||||||
name: 'bookableQty',
|
|
||||||
label_trans: 'products.bookableQty',
|
|
||||||
fieldtype: costanti.FieldType.number
|
|
||||||
}),
|
|
||||||
AddCol({
|
AddCol({
|
||||||
name: 'stockBloccatiQty',
|
name: 'stockBloccatiQty',
|
||||||
label_trans: 'products.stockBloccatiQty',
|
label_trans: 'products.stockBloccatiQty',
|
||||||
fieldtype: costanti.FieldType.number
|
fieldtype: costanti.FieldType.number
|
||||||
}),
|
}),
|
||||||
AddCol({
|
AddCol({
|
||||||
name: 'bookableBloccatiQty',
|
name: 'bookedQtyConfirmed',
|
||||||
label_trans: 'products.bookableBloccatiQty',
|
label_trans: 'products.bookedQtyConfirmed',
|
||||||
fieldtype: costanti.FieldType.number
|
fieldtype: costanti.FieldType.number
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
AddCol({
|
||||||
|
name: 'qtyToReachForGas',
|
||||||
|
label_trans: 'ecomm.qtyToReachForGas',
|
||||||
|
fieldtype: costanti.FieldType.number
|
||||||
|
}),
|
||||||
|
AddCol({
|
||||||
|
name: 'note',
|
||||||
|
label_trans: 'ecomm.note',
|
||||||
|
fieldtype: costanti.FieldType.html
|
||||||
|
}),
|
||||||
|
AddCol({
|
||||||
|
name: 'maxbookableGASQty',
|
||||||
|
label_trans: 'ecomm.maxbookableGASQty',
|
||||||
|
fieldtype: costanti.FieldType.number
|
||||||
|
}),
|
||||||
|
AddCol({
|
||||||
|
name: 'bookedGASQtyOrdered',
|
||||||
|
label_trans: 'ecomm.bookedGASQtyOrdered',
|
||||||
|
fieldtype: costanti.FieldType.number
|
||||||
|
}),
|
||||||
|
AddCol({
|
||||||
|
name: 'bookableGASBloccatiQty',
|
||||||
|
label_trans: 'ecomm.bookableGASBloccatiQty',
|
||||||
|
fieldtype: costanti.FieldType.number
|
||||||
|
}),
|
||||||
|
|
||||||
AddCol({ name: 'canBeShipped', label_trans: 'products.canBeShipped', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'canBeShipped', label_trans: 'products.canBeShipped', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({ name: 'canBeBuyOnline', label_trans: 'products.canBeBuyOnline', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'canBeBuyOnline', label_trans: 'products.canBeBuyOnline', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol(DeleteRec),
|
AddCol(DeleteRec),
|
||||||
|
|||||||
@@ -8274,7 +8274,8 @@ export const tools = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
convertPriceEurToValue(inputString: string): string {
|
convertPriceEurToValue(inputString: string): string {
|
||||||
|
if (inputString === '')
|
||||||
|
return '0';
|
||||||
// Rimuovi il simbolo della valuta (€) e sostituisci la virgola con un punto
|
// Rimuovi il simbolo della valuta (€) e sostituisci la virgola con un punto
|
||||||
return inputString.replace(/[^\d.,]/g, '').replace(',', '.');
|
return inputString.replace(/[^\d.,]/g, '').replace(',', '.');
|
||||||
},
|
},
|
||||||
@@ -8316,6 +8317,13 @@ export const tools = {
|
|||||||
|
|
||||||
return (`${strgg} ${this.pad(hours)}:${this.pad(minutes)}:${this.pad(seconds)}`);
|
return (`${strgg} ${this.pad(hours)}:${this.pad(minutes)}:${this.pad(seconds)}`);
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
calcperc(val1: number, valmax: number): number {
|
||||||
|
if (valmax > 0)
|
||||||
|
return (val1 / valmax * 100)
|
||||||
|
else
|
||||||
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
// FINE !
|
// FINE !
|
||||||
|
|||||||
@@ -32,18 +32,45 @@ function getRecordProductInfoEmpty(): IProductInfo {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function getRecordProductEmpty() {
|
function getRecordProductEmpty(): IProduct {
|
||||||
return {
|
|
||||||
active: false,
|
|
||||||
productInfo: {
|
|
||||||
img: '', code: '', name: '',
|
|
||||||
|
|
||||||
},
|
const tomorrow = tools.getDateNow()
|
||||||
storehouses: [], scontisticas: [],
|
tomorrow.setDate(tomorrow.getDate() + 1)
|
||||||
price: 0, stockQty: 0, bookableQty: 0, gasordines: [],
|
|
||||||
stockBloccatiQty: 0, bookableBloccatiQty: 0,
|
return {
|
||||||
idGasordines: [], minBuyQty: 1, maxBookableQty: 0,
|
productInfo: getRecordProductInfoEmpty(),
|
||||||
|
// _id: tools.getDateNow().toISOString(), // Create NEW
|
||||||
|
active: false,
|
||||||
|
idProducer: '',
|
||||||
|
idStorehouses: [],
|
||||||
|
idGasordines: [],
|
||||||
|
idScontisticas: [],
|
||||||
|
scontisticas: [],
|
||||||
|
gasordines: [],
|
||||||
|
idProvider: '',
|
||||||
|
producer: {},
|
||||||
|
storehouses: [],
|
||||||
|
provider: {},
|
||||||
|
price: 0.0,
|
||||||
|
quantityAvailable: 0,
|
||||||
|
bookableAvailableQty: 0,
|
||||||
|
minBuyQty: 1,
|
||||||
minStepQty: 1,
|
minStepQty: 1,
|
||||||
|
maxBookableSinglePersQty: 0,
|
||||||
|
|
||||||
|
stockQty: 0,
|
||||||
|
stockBloccatiQty: 0,
|
||||||
|
bookedQtyConfirmed: 0,
|
||||||
|
|
||||||
|
qtyToReachForGas: 0,
|
||||||
|
maxbookableGASQty: 0,
|
||||||
|
bookedGASQtyOrdered: 0,
|
||||||
|
bookableGASBloccatiQty: 0,
|
||||||
|
|
||||||
|
canBeShipped: false,
|
||||||
|
QuantitaOrdinateInAttesa: 0,
|
||||||
|
QuantitaPrenotateInAttesa: 0,
|
||||||
|
canBeBuyOnline: false,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -283,39 +310,7 @@ export const useProducts = defineStore('Products', {
|
|||||||
|
|
||||||
|
|
||||||
getRecordEmpty: (state: IProductsState) => (): IProduct => {
|
getRecordEmpty: (state: IProductsState) => (): IProduct => {
|
||||||
|
return getRecordProductEmpty()
|
||||||
const tomorrow = tools.getDateNow()
|
|
||||||
tomorrow.setDate(tomorrow.getDate() + 1)
|
|
||||||
|
|
||||||
return {
|
|
||||||
productInfo: getRecordProductInfoEmpty(),
|
|
||||||
// _id: tools.getDateNow().toISOString(), // Create NEW
|
|
||||||
active: false,
|
|
||||||
idProducer: '',
|
|
||||||
idStorehouses: [],
|
|
||||||
idGasordines: [],
|
|
||||||
idScontisticas: [],
|
|
||||||
scontisticas: [],
|
|
||||||
gasordines: [],
|
|
||||||
idProvider: '',
|
|
||||||
producer: {},
|
|
||||||
storehouses: [],
|
|
||||||
provider: {},
|
|
||||||
price: 0.0,
|
|
||||||
quantityAvailable: 0,
|
|
||||||
bookableAvailableQty: 0,
|
|
||||||
stockQty: 0,
|
|
||||||
stockBloccatiQty: 0,
|
|
||||||
minBuyQty: 1,
|
|
||||||
minStepQty: 1,
|
|
||||||
maxBookableQty: 0,
|
|
||||||
bookableQty: 0,
|
|
||||||
bookableBloccatiQty: 0,
|
|
||||||
canBeShipped: false,
|
|
||||||
QuantitaOrdinateInAttesa: 0,
|
|
||||||
QuantitaPrenotateInAttesa: 0,
|
|
||||||
canBeBuyOnline: false,
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
},
|
},
|
||||||
@@ -380,12 +375,15 @@ export const useProducts = defineStore('Products', {
|
|||||||
ris = await Api.SendReq('/products', 'POST', { userId: userStore.my._id })
|
ris = await Api.SendReq('/products', 'POST', { userId: userStore.my._id })
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
if (res.data.products) {
|
if (res.data.products) {
|
||||||
|
console.log('aggiorna prodotti')
|
||||||
|
this.products = []
|
||||||
this.products = res.data.products
|
this.products = res.data.products
|
||||||
} else {
|
} else {
|
||||||
this.products = []
|
this.products = []
|
||||||
}
|
}
|
||||||
|
|
||||||
if (res.data.orders) {
|
if (res.data.orders) {
|
||||||
|
this.orders = []
|
||||||
this.orders = res.data.orders
|
this.orders = res.data.orders
|
||||||
} else {
|
} else {
|
||||||
this.orders = []
|
this.orders = []
|
||||||
@@ -831,7 +829,7 @@ export const useProducts = defineStore('Products', {
|
|||||||
},
|
},
|
||||||
|
|
||||||
getQtyBloccataBookableAvailable(myproduct: IProduct): number {
|
getQtyBloccataBookableAvailable(myproduct: IProduct): number {
|
||||||
let qty = myproduct.bookableBloccatiQty
|
let qty = myproduct.bookableGASBloccatiQty
|
||||||
return qty
|
return qty
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -844,17 +842,17 @@ export const useProducts = defineStore('Products', {
|
|||||||
const globalStore = useGlobalStore()
|
const globalStore = useGlobalStore()
|
||||||
if (globalStore.site.ecomm && globalStore.site.ecomm.enablePreOrders) {
|
if (globalStore.site.ecomm && globalStore.site.ecomm.enablePreOrders) {
|
||||||
return (this.getQtyBookableAvailable(myproduct) > 0
|
return (this.getQtyBookableAvailable(myproduct) > 0
|
||||||
&& (myproduct.maxBookableQty === 0
|
&& (myproduct.maxBookableSinglePersQty === 0
|
||||||
|| (myorder.quantitypreordered + 1 < myproduct.maxBookableQty))
|
|| (myorder.quantitypreordered + 1 < myproduct.maxBookableSinglePersQty))
|
||||||
)
|
)
|
||||||
|| (this.getQtyAvailable(myproduct) > 0)
|
|| (this.getQtyAvailable(myproduct) > 0)
|
||||||
&& (myproduct.maxBookableQty === 0
|
&& (myproduct.maxBookableSinglePersQty === 0
|
||||||
|| (myorder.quantity + 1 < myproduct.maxBookableQty))
|
|| (myorder.quantity + 1 < myproduct.maxBookableSinglePersQty))
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
return (this.getQtyAvailable(myproduct) > 0)
|
return (this.getQtyAvailable(myproduct) > 0)
|
||||||
&& (myproduct.maxBookableQty === 0
|
&& (myproduct.maxBookableSinglePersQty === 0
|
||||||
|| (myorder.quantity + 1 < myproduct.maxBookableQty))
|
|| (myorder.quantity + 1 < myproduct.maxBookableSinglePersQty))
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -261,6 +261,14 @@
|
|||||||
></q-btn>
|
></q-btn>
|
||||||
<br />
|
<br />
|
||||||
</div>
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<q-btn
|
||||||
|
label="10. Elimina la Tabella CATPROD !)"
|
||||||
|
color="negative"
|
||||||
|
@click="EseguiFunz('dropCatProd')"
|
||||||
|
></q-btn>
|
||||||
|
<br />
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<q-btn
|
<q-btn
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ $heightBtn: 100%;
|
|||||||
padding: 5px;
|
padding: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.evaso {
|
.confermato {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
color: green;
|
color: green;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ export default defineComponent({
|
|||||||
{
|
{
|
||||||
name: 'items',
|
name: 'items',
|
||||||
required: true,
|
required: true,
|
||||||
label: 'Articoli',
|
label: '',
|
||||||
field: 'items',
|
field: 'items',
|
||||||
sortable: true
|
sortable: true
|
||||||
},
|
},
|
||||||
@@ -157,7 +157,6 @@ export default defineComponent({
|
|||||||
|
|
||||||
function getOrdersCart(): IOrderCart[] | undefined {
|
function getOrdersCart(): IOrderCart[] | undefined {
|
||||||
const hasGasordine: any = (cosa.value === shared_consts.PROD.TUTTI) ? undefined : (cosa.value === shared_consts.PROD.GAS)
|
const hasGasordine: any = (cosa.value === shared_consts.PROD.TUTTI) ? undefined : (cosa.value === shared_consts.PROD.GAS)
|
||||||
console.log('hasgas', hasGasordine)
|
|
||||||
const ris = productStore.getOrdersCart(taborders.value, hasGasordine)
|
const ris = productStore.getOrdersCart(taborders.value, hasGasordine)
|
||||||
|
|
||||||
return ris
|
return ris
|
||||||
@@ -180,8 +179,12 @@ export default defineComponent({
|
|||||||
totalPrice: orderscart.reduce((total: number, rec: any) => total + rec.totalPrice, 0),
|
totalPrice: orderscart.reduce((total: number, rec: any) => total + rec.totalPrice, 0),
|
||||||
};
|
};
|
||||||
|
|
||||||
// Combine orders and totals
|
let rowsWithTotals: any = [...orderscart];
|
||||||
const rowsWithTotals = [...orderscart, totals];
|
|
||||||
|
if (tools.isManager()) {
|
||||||
|
// Combine orders and totals
|
||||||
|
rowsWithTotals.push(totals);
|
||||||
|
}
|
||||||
|
|
||||||
return rowsWithTotals;
|
return rowsWithTotals;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -210,9 +210,9 @@
|
|||||||
shared_consts.getStatusStr(props.row.status)
|
shared_consts.getStatusStr(props.row.status)
|
||||||
}}</span>
|
}}</span>
|
||||||
<br />
|
<br />
|
||||||
<div v-if="props.row.evaso" class="ordstat">
|
<div v-if="props.row.confermato" class="ordstat">
|
||||||
{{ tools.getstrDateTime(props.row.date_evaso) }}:
|
{{ tools.getstrDateTime(props.row.date_confermato) }}:
|
||||||
<span class="ordstat evaso">{{ $t('ecomm.evaso') }}</span>
|
<span class="ordstat confermato">{{ $t('ecomm.confermato') }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="props.row.pagato" class="ordstat">
|
<div v-if="props.row.pagato" class="ordstat">
|
||||||
{{ tools.getstrDateTime(props.row.date_pagato) }}:
|
{{ tools.getstrDateTime(props.row.date_pagato) }}:
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ export default defineComponent({
|
|||||||
|
|
||||||
const cosa = ref(0)
|
const cosa = ref(0)
|
||||||
const cat = ref('')
|
const cat = ref('')
|
||||||
|
const loadpage = ref(false)
|
||||||
|
|
||||||
watch(() => cosa.value, (newval, oldval) => {
|
watch(() => cosa.value, (newval, oldval) => {
|
||||||
tools.setCookie(tools.COOK_COSA_PRODOTTI, cosa.value.toString())
|
tools.setCookie(tools.COOK_COSA_PRODOTTI, cosa.value.toString())
|
||||||
@@ -67,10 +68,12 @@ export default defineComponent({
|
|||||||
});
|
});
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
function mounted() {
|
async function mounted() {
|
||||||
|
loadpage.value = false
|
||||||
|
await productStore.loadProducts()
|
||||||
cosa.value = tools.getCookie(tools.COOK_COSA_PRODOTTI, shared_consts.PROD.BOTTEGA, true)
|
cosa.value = tools.getCookie(tools.COOK_COSA_PRODOTTI, shared_consts.PROD.BOTTEGA, true)
|
||||||
// Inizializza
|
// Inizializza
|
||||||
productStore.loadProducts()
|
loadpage.value = true
|
||||||
}
|
}
|
||||||
|
|
||||||
function getCatProds() {
|
function getCatProds() {
|
||||||
@@ -99,6 +102,7 @@ export default defineComponent({
|
|||||||
cat,
|
cat,
|
||||||
productStore,
|
productStore,
|
||||||
t,
|
t,
|
||||||
|
loadpage,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<q-page>
|
<q-page>
|
||||||
<div class="panel">
|
<q-spinner v-if="!loadpage" color="primary" size="3em" :thickness="2" />
|
||||||
|
<div v-if="loadpage" class="panel">
|
||||||
<div>
|
<div>
|
||||||
<div class="q-gutter-md text-center q-mb-md">
|
<div class="q-gutter-md text-center q-mb-md">
|
||||||
<q-btn-toggle
|
<q-btn-toggle
|
||||||
|
|||||||
BIN
upload/products/GAS00002.jpg
Normal file
BIN
upload/products/GAS00002.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 76 KiB |
BIN
upload/products/GAS00003.jpg
Normal file
BIN
upload/products/GAS00003.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 178 KiB |
Reference in New Issue
Block a user