- caaloghi, categorie

This commit is contained in:
Surya Paolo
2024-05-08 16:07:42 +02:00
parent 84e7f6e9f4
commit 58f53f8c52
20 changed files with 704 additions and 415 deletions

View File

@@ -4,51 +4,7 @@
<q-spinner v-if="!loadpage" color="primary" size="3em" :thickness="2" />
</div>
<div v-if="loadpage" class="panel">
<div v-if="true">
<!--<CSelectUserActive></CSelectUserActive>-->
<!-- <div class="text-center text-h7 text-blue">Filtra Prodotti per:</div>
<div class="text-center">
<q-btn-toggle
v-model="cosa"
push
:size="tools.isMobile() ? '0.75rem' : '1rem'"
rounded
glossy
toggle-color="primary"
:options="[
{ value: shared_consts.PROD.GAS, slot: 'gas' },
{ value: shared_consts.PROD.BOTTEGA, slot: 'bottega' },
]"
>
<template v-slot:tutti>
<div class="row items-center no-wrap">
<div class="text-center">
{{ t('ecomm.tutti') }}
</div>
<q-icon right name="fas fa-check-square" />
</div>
</template>
<template v-slot:gas>
<div class="row items-center no-wrap">
<div class="text-center">
{{ t('gas.ordina_sul_gas') }}
</div>
<q-icon right name="fas fa-user-friends" />
</div>
</template>
<template v-slot:bottega>
<div class="row items-center no-wrap">
<div class="text-center">
{{ t('gas.bottega') }}
</div>
<q-icon right name="fas fa-store" />
</div>
</template>
</q-btn-toggle>
</div> -->
</div>
<div v-if="true"></div>
<div class="container">
<q-slide-transition>
@@ -163,9 +119,19 @@
</div>
</div>
<div v-else>
<div class="row q-gutter-xs justify-center q-mx-auto">
<div class="category-title">Categorie</div>
<div class="row q-gutter-xs justify-center q-mx-auto bg-blue-1">
<div v-for="(reccat, index) in getCatProds()" :key="index">
<q-btn
<span
:class="{
category: true,
category_sel: cat === reccat.value,
}"
@click="cat = reccat.value"
>{{ reccat.label }}
</span>
|
<!--<q-btn
:push="cat === reccat.value"
dense
:size="tools.isMobile() ? '0.70rem' : '1rem'"
@@ -176,7 +142,7 @@
:label="reccat.label"
@click="cat = reccat.value"
>
</q-btn>
</q-btn>-->
</div>
</div>
<div class="text-center q-py-sm prod_trov">
@@ -264,6 +230,13 @@
:id="product._id"
:complete="false"
:cosa="cosa"
:options="{
show_short_descr: false,
show_price: false,
show_cat: false,
quante_col: 'c2',
in_3d: false,
}"
/>
<CProductCard
v-else-if="product.active || show_hide"