- Cataloghi: BestSeller, Novità

This commit is contained in:
Surya Paolo
2024-11-28 16:04:48 +01:00
parent e10ff192bf
commit 6932590f3e
30 changed files with 1086 additions and 456 deletions

View File

@@ -48,9 +48,7 @@
</q-tabs>
<q-tab-panels v-model="tabvisu" animated class="">
<q-tab-panel name="categorie">
<div
class="row justify-center q-mx-auto bg-blue-1"
>
<div class="row justify-center q-mx-auto bg-blue-1">
<div v-for="(reccat, index) in getCatProds()" :key="index">
<span
:class="{
@@ -168,7 +166,7 @@
<q-select
v-model="filter.sort"
dense
:options="costanti.ORDINAMENTO_CATALOGHI"
:options="shared_consts.ORDINAMENTO_CATALOGHI"
label="Ordinamento"
placeholder=""
emit-value
@@ -209,32 +207,16 @@
<div
v-if="
optcatalogo.first_page &&
optcatalogo.first_page.text_html &&
optcatalogo.first_page.text_html.contenuto
"
:style="{
backgroundImage: `url(${
costanti.DIR_UPLOAD +
costanti.DIR_CATALOGO +
optcatalogo.first_page.imgsfondo.imagefile
})`,
backgroundSize: `${optcatalogo.first_page.imgsfondo.fit}`,
backgroundRepeat: 'no-repeat',
height:
tools.adjustSize(
optcatalogo,
optcatalogo.first_page.size.height
) + 'px',
width:
tools.adjustSize(
optcatalogo,
optcatalogo.first_page.size.width
) + 'px',
}"
:style="
generateStyleByPageDim(optcatalogo, optcatalogo.first_page)
"
>
<div
v-html="optcatalogo.first_page.text_html.contenuto"
></div>
\
</div>
<div :style="generateStyleCatalogo(optcatalogo)">
<div class="flex-container-book">
@@ -250,10 +232,7 @@
class="row items-start"
style="place-content: center"
>
<div
v-for="(product, index) in arrLoaded"
:key="index"
>
<div v-for="(product, index) in arrLoaded" :key="index">
<CContainerCatalogoCard
v-if="
product.active ||
@@ -263,6 +242,7 @@
))
"
:id="product._id"
:product="product"
:complete="false"
:cosa="cosa"
:optcatalogo="optcatalogo"
@@ -278,6 +258,7 @@
<CProductCard
v-else-if="product.active || show_hide"
:id="product._id"
:product="product"
:complete="false"
:cosa="cosa"
/>
@@ -319,6 +300,30 @@
)
"
>
<div
v-if="
recscheda.scheda.dimensioni.pagina?.testo_up
?.contenuto
"
:style="{
'--scalecatalog':
optcatalogo.areadistampa.scale,
'line-height':
recscheda.scheda.dimensioni.pagina?.testo_up
?.font.line_height,
display: 'flex',
flexDirection: 'column',
}"
>
<div
v-html="
recscheda.scheda.dimensioni.pagina?.testo_up
?.contenuto
"
style="display: flex; flex-direction: row"
></div>
</div>
<!-- Itera sulle righe di ogni pagina -->
<div
v-for="(row, rowIndex) in page"
@@ -333,34 +338,15 @@
<div class="row justify-center">
<div
v-for="(indprod, colIndex) in row"
v-for="(prod, colIndex) in row"
:key="`${pageIndex}-${rowIndex}-${colIndex}`"
class="flex-item-book"
:style="getStyleSchedaProdotto(recscheda)"
>
<CContainerCatalogoCard
v-if="
getProdBySchedaRigaCol(
recscheda,
pageIndex,
rowIndex,
colIndex
) &&
getProdBySchedaRigaCol(
recscheda,
pageIndex,
rowIndex,
colIndex
).active
"
:id="
getProdBySchedaRigaCol(
recscheda,
pageIndex,
rowIndex,
colIndex
)._id
"
v-if="prod && prod.active"
:id="prod._id"
:product="prod"
:complete="false"
:cosa="cosa"
:optcatalogo="optcatalogo"
@@ -376,28 +362,9 @@
/>
<CProductCard
v-else-if="
getProdBySchedaRigaCol(
recscheda,
pageIndex,
rowIndex,
colIndex
) &&
(getProdBySchedaRigaCol(
recscheda,
pageIndex,
rowIndex,
colIndex
).active ||
show_hide)
"
:id="
getProdBySchedaRigaCol(
recscheda,
pageIndex,
rowIndex,
colIndex
)._id
prod && (prod.active || show_hide)
"
:id="prod._id"
:complete="false"
:cosa="cosa"
/>
@@ -407,12 +374,17 @@
<!-- Separatore -->
<div
v-if="recscheda.scheda?.show_separatore && rowIndex !== page.length - 1"
v-if="
recscheda.scheda?.show_separatore &&
rowIndex !== page.length - 1
"
class="text-center"
:style="getStyleRow(recscheda)"
>
<q-separator inset :size="tools.adjustSize(optcatalogo, '1px')"></q-separator>
<q-separator
inset
:size="tools.adjustSize(optcatalogo, '1px')"
></q-separator>
</div>
</div>
<!-- Card Row -->
@@ -428,27 +400,12 @@
<div
v-if="
optcatalogo.last_page &&
optcatalogo.last_page.text_html &&
optcatalogo.last_page.text_html.contenuto
"
:style="{
backgroundImage: `url(${
costanti.DIR_UPLOAD +
costanti.DIR_CATALOGO +
optcatalogo.last_page.imgsfondo.imagefile
})`,
backgroundSize: `${optcatalogo.last_page.imgsfondo.fit}`,
backgroundRepeat: 'no-repeat',
height:
tools.adjustSize(
optcatalogo,
optcatalogo.last_page.size.height
) + 'px',
width:
tools.adjustSize(
optcatalogo,
optcatalogo.last_page.size.width
) + 'px',
}"
:style="
generateStyleByPageDim(optcatalogo, optcatalogo.last_page)
"
>
<div v-html="optcatalogo.last_page.text_html.contenuto"></div>
</div>