catalogo, avanti, grafica
This commit is contained in:
@@ -12,6 +12,7 @@
|
|||||||
|
|
||||||
.prod_price {
|
.prod_price {
|
||||||
font-size: 1.1rem;
|
font-size: 1.1rem;
|
||||||
|
font-style: bold;
|
||||||
|
|
||||||
@media (max-width: 718px) {
|
@media (max-width: 718px) {
|
||||||
font-size: 1rem;
|
font-size: 1rem;
|
||||||
@@ -20,6 +21,7 @@
|
|||||||
|
|
||||||
.prod_sale_price {
|
.prod_sale_price {
|
||||||
font-size: 1.10rem;
|
font-size: 1.10rem;
|
||||||
|
font-style: bold;
|
||||||
|
|
||||||
@media (max-width: 718px) {
|
@media (max-width: 718px) {
|
||||||
font-size: 1.05rem;
|
font-size: 1.05rem;
|
||||||
@@ -146,6 +148,11 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.book-image-fixed{
|
||||||
|
max-width: 300px;
|
||||||
|
max-height: 600px;
|
||||||
|
}
|
||||||
|
|
||||||
.img-pic {
|
.img-pic {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -165,6 +172,11 @@
|
|||||||
background-color: #f8f8f8;
|
background-color: #f8f8f8;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.book-card {
|
||||||
|
width: 300px;
|
||||||
|
background-color: #f8f8f8;
|
||||||
|
}
|
||||||
|
|
||||||
.book-card-section {
|
.book-card-section {
|
||||||
display: flex;
|
display: flex;
|
||||||
}
|
}
|
||||||
@@ -182,7 +194,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.book-info {
|
.book-info {
|
||||||
flex: 2;
|
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -193,19 +205,18 @@
|
|||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
color: #333;
|
color: #333;
|
||||||
display: flex;
|
display: block;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.book-author {
|
.book-author {
|
||||||
color: #263238;
|
font-size: 1.1em; /* Dimensione del font leggermente più grande per enfatizzare l'importanza del nome dell'autore */
|
||||||
display: flex;
|
color: darkblue; /* Colore scuro per garantire una buona leggibilità */
|
||||||
font-family: Poppins, sans-serif;
|
text-transform: capitalize; /* Capitalizzazione delle iniziali per ogni parola del nome */
|
||||||
font-size: 1em;
|
background-color: #f9f9f9; /* Sfondo leggermente diverso per evidenziare il nome */
|
||||||
font-weight: 400;
|
border-radius: 2px; /* Bordi arrotondati per un aspetto più soft-edged */
|
||||||
line-height: 18px;
|
display: inline-block; /* Tratta il blocco come elementi inline-block per adattarlo al contenuto */
|
||||||
text-align: center;
|
font-style: italic; /* Stile del testo in corsivo per evidenziare l'autore */
|
||||||
font-style: italic;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.book-description {
|
.book-description {
|
||||||
@@ -213,14 +224,59 @@
|
|||||||
color: #777;
|
color: #777;
|
||||||
}
|
}
|
||||||
|
|
||||||
.block-variazione{
|
.block-variazione {
|
||||||
border: 1px solid gray;
|
border: 1px solid gray;
|
||||||
|
// effetto 3d
|
||||||
|
box-shadow: 0 0 5px gray;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
padding: 2px;
|
padding: 2px;
|
||||||
margin: 2px;
|
margin: 2px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
.block-variazione-selected{
|
.block-variazione-selected {
|
||||||
border: 1px solid red !important;
|
border: 2px solid red !important;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.book-isbn {
|
||||||
|
font-size: 0.85rem;
|
||||||
|
color: #A0A0A0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Stilizzazione per descrizione breve del libro */
|
||||||
|
.book-short-descr {
|
||||||
|
font-size: 1.1em; /* Leggermente più grande per enfatizzare l'importanza */
|
||||||
|
color: #666; /* Colore del testo in tono grigio scuro per un look sobrio */
|
||||||
|
padding: 8px; /* Padding per dare spazio intorno al testo */
|
||||||
|
border-left: 4px solid #007BFF; /* Linea verticale a sinistra come decorazione tradizionale delle citazioni */
|
||||||
|
margin: 10px 0; /* Margine sopra e sotto per distanziare dalla restante contenuto */
|
||||||
|
font-style: italic; /* Stile del font in corsivo per indicare che si tratta di un estratto o citazione */
|
||||||
|
background-color: #f4f4f4; /* Sfondo leggermente diverso per evidenziare la sezione */
|
||||||
|
display: block; /* Assicura che l'elemento sia trattato come blocco, occupando l'intera larghezza */
|
||||||
|
text-align: center; /* Giustifica il testo per una lettura più fluida */
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Opzionale: Transizione per l'hover su descrizione */
|
||||||
|
.book-short-descr:hover {
|
||||||
|
background-color: #e9e9e9; /* Cambio di sfondo al passaggio del mouse per un effetto interattivo */
|
||||||
|
}
|
||||||
|
|
||||||
|
.ingrandisci:hover {
|
||||||
|
// fai lo scale
|
||||||
|
transform: scale(1.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.title-descr{
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 1.1rem;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.scheda-book {
|
||||||
|
text-align: center;
|
||||||
|
margin-left: 20px;
|
||||||
|
@media (max-width: 718px) {
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -238,6 +238,10 @@ export default defineComponent({
|
|||||||
return isOrdineChiuso()
|
return isOrdineChiuso()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function checkifCartEnable() {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
function getQtyWarn() {
|
function getQtyWarn() {
|
||||||
if (myorder.quantity > 0) {
|
if (myorder.quantity > 0) {
|
||||||
return t('ecomm.di_cui_x_in_carrello', { qty: myorder.quantity })
|
return t('ecomm.di_cui_x_in_carrello', { qty: myorder.quantity })
|
||||||
@@ -288,6 +292,10 @@ export default defineComponent({
|
|||||||
function mounted() {
|
function mounted() {
|
||||||
load()
|
load()
|
||||||
|
|
||||||
|
if (props.complete && myproduct.value && myproduct.value.arrvariazioni) {
|
||||||
|
indvariazSel.value = 0
|
||||||
|
}
|
||||||
|
|
||||||
// Start the timer when the component is mounted
|
// Start the timer when the component is mounted
|
||||||
startTimer();
|
startTimer();
|
||||||
}
|
}
|
||||||
@@ -426,7 +434,10 @@ export default defineComponent({
|
|||||||
}
|
}
|
||||||
|
|
||||||
function setvariazioneSelected(indvariaz: number) {
|
function setvariazioneSelected(indvariaz: number) {
|
||||||
indvariazSel.value = indvariaz
|
if (indvariazSel.value === indvariaz)
|
||||||
|
indvariazSel.value = -1
|
||||||
|
else
|
||||||
|
indvariazSel.value = indvariaz
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(mounted)
|
onMounted(mounted)
|
||||||
@@ -481,6 +492,7 @@ export default defineComponent({
|
|||||||
apriSchedaPDF,
|
apriSchedaPDF,
|
||||||
setvariazioneSelected,
|
setvariazioneSelected,
|
||||||
indvariazSel,
|
indvariazSel,
|
||||||
|
checkifCartEnable,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -281,6 +281,16 @@ function getRoutesEcomm(site: ISites) {
|
|||||||
inmenu: false,
|
inmenu: false,
|
||||||
infooter: false
|
infooter: false
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
active: true,
|
||||||
|
order: 1000,
|
||||||
|
path: '/catalogo/:idprod/:cosa',
|
||||||
|
materialIcon: 'event',
|
||||||
|
name: 'otherpages.catalogo',
|
||||||
|
component: () => import('@/views/ecommerce/catalogoInfo/catalogoInfo.vue'),
|
||||||
|
inmenu: false,
|
||||||
|
infooter: false
|
||||||
|
},
|
||||||
{
|
{
|
||||||
active: true,
|
active: true,
|
||||||
order: 1000,
|
order: 1000,
|
||||||
|
|||||||
@@ -95,6 +95,7 @@ const msg_it = {
|
|||||||
productInfo: 'Info Prodotto',
|
productInfo: 'Info Prodotto',
|
||||||
link_scheda: 'Link Scheda',
|
link_scheda: 'Link Scheda',
|
||||||
addtocart_ext: 'Aggiungi',
|
addtocart_ext: 'Aggiungi',
|
||||||
|
formato: 'Formato',
|
||||||
},
|
},
|
||||||
storehouses: {
|
storehouses: {
|
||||||
name: 'Magazzino',
|
name: 'Magazzino',
|
||||||
@@ -115,6 +116,7 @@ const msg_it = {
|
|||||||
myactivities: 'Attività',
|
myactivities: 'Attività',
|
||||||
myactivities2: 'Mie Attività',
|
myactivities2: 'Mie Attività',
|
||||||
product: 'Prodotto',
|
product: 'Prodotto',
|
||||||
|
catalogo: 'Catalogo',
|
||||||
orderscart: 'Ordini',
|
orderscart: 'Ordini',
|
||||||
sito_offline: 'Sito in Aggiornamento',
|
sito_offline: 'Sito in Aggiornamento',
|
||||||
modifprof: 'Modifica',
|
modifprof: 'Modifica',
|
||||||
@@ -1738,6 +1740,7 @@ const msg_it = {
|
|||||||
tutti: 'Tutti',
|
tutti: 'Tutti',
|
||||||
paga: 'Paga',
|
paga: 'Paga',
|
||||||
consegna: 'Consegna',
|
consegna: 'Consegna',
|
||||||
|
disponibilita: 'Disponibilità',
|
||||||
},
|
},
|
||||||
gas: {
|
gas: {
|
||||||
name: 'Ordine Gas',
|
name: 'Ordine Gas',
|
||||||
@@ -1787,7 +1790,8 @@ const msg_it = {
|
|||||||
mipiace: 'Mi piace',
|
mipiace: 'Mi piace',
|
||||||
tipiace: 'Ti piace',
|
tipiace: 'Ti piace',
|
||||||
condividi: 'Condividi',
|
condividi: 'Condividi',
|
||||||
}
|
},
|
||||||
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -3375,13 +3375,17 @@ export const tools = {
|
|||||||
return myval.charAt(0).toUpperCase() + myval.slice(1)
|
return myval.charAt(0).toUpperCase() + myval.slice(1)
|
||||||
},
|
},
|
||||||
|
|
||||||
firstchars(value: any, numchars = 200) {
|
firstchars(value: any, numchars = 200, capitalizeFirst = false) {
|
||||||
if (!value) {
|
if (!value) {
|
||||||
return ''
|
return ''
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
let mycar = value.substring(0, numchars)
|
let mycar = value.substring(0, numchars)
|
||||||
if (value.length > numchars) mycar += '...'
|
if (value.length > numchars) mycar += '...'
|
||||||
|
|
||||||
|
if (capitalizeFirst) {
|
||||||
|
mycar = mycar.charAt(0).toUpperCase() + mycar.slice(1);
|
||||||
|
}
|
||||||
return mycar
|
return mycar
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
return value
|
return value
|
||||||
@@ -8532,6 +8536,54 @@ export const tools = {
|
|||||||
window.location.reload();
|
window.location.reload();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
disponibStr(quantita: any) {
|
||||||
|
if (!quantita) {
|
||||||
|
// Disponibilità non pervenuta, non scrivere niente
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
quantita = parseInt(quantita)
|
||||||
|
let ris = ''
|
||||||
|
if (quantita < 0) {
|
||||||
|
ris = 'Disponibile per il Pre-Ordine'
|
||||||
|
} else if (quantita === 0) {
|
||||||
|
ris = 'Terminato!'
|
||||||
|
} else if ((quantita > 0) && (quantita <= 3)) {
|
||||||
|
if (quantita === 1)
|
||||||
|
ris = 'Ultimo pezzo !'
|
||||||
|
else
|
||||||
|
ris = 'Ultimi ' + quantita + ' pezzi'
|
||||||
|
} else if ((quantita > 3) && (quantita <= 10)) {
|
||||||
|
ris = 'Media'
|
||||||
|
} else {
|
||||||
|
ris = 'Alta'
|
||||||
|
}
|
||||||
|
|
||||||
|
return ris
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
colordisponib(quantita: any) {
|
||||||
|
if (!quantita) {
|
||||||
|
// Disponibilità non pervenuta, non scrivere niente
|
||||||
|
return 'gray'
|
||||||
|
}
|
||||||
|
quantita = parseInt(quantita)
|
||||||
|
let color = ''
|
||||||
|
if (quantita < 0) {
|
||||||
|
color = 'blue'
|
||||||
|
} else if (quantita === 0) {
|
||||||
|
color = 'gray'
|
||||||
|
} else if ((quantita > 0) && (quantita <= 3)) {
|
||||||
|
color = 'red'
|
||||||
|
} else if ((quantita > 3) && (quantita <= 10)) {
|
||||||
|
color = 'orange'
|
||||||
|
} else if (quantita > 10) {
|
||||||
|
color = 'green'
|
||||||
|
}
|
||||||
|
|
||||||
|
return color
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// FINE !
|
// FINE !
|
||||||
|
|
||||||
|
|||||||
5
src/views/ecommerce/catalogoInfo/catalogoInfo.scss
Executable file
5
src/views/ecommerce/catalogoInfo/catalogoInfo.scss
Executable file
@@ -0,0 +1,5 @@
|
|||||||
|
$heightBtn: 100%;
|
||||||
|
|
||||||
|
.card .product-image {
|
||||||
|
height: 300px;
|
||||||
|
}
|
||||||
59
src/views/ecommerce/catalogoInfo/catalogoInfo.ts
Executable file
59
src/views/ecommerce/catalogoInfo/catalogoInfo.ts
Executable file
@@ -0,0 +1,59 @@
|
|||||||
|
import { defineComponent, onMounted, ref } from 'vue'
|
||||||
|
import { tools } from '@store/Modules/tools'
|
||||||
|
import { useUserStore } from '@store/UserStore'
|
||||||
|
import { useRouter } from 'vue-router'
|
||||||
|
import { useRoute } from 'vue-router'
|
||||||
|
import { useGlobalStore } from '@store/globalStore'
|
||||||
|
import { useProducts } from '@store/Products'
|
||||||
|
import { useI18n } from '@/boot/i18n'
|
||||||
|
import { toolsext } from '@store/Modules/toolsext'
|
||||||
|
import { useQuasar } from 'quasar'
|
||||||
|
import { costanti } from '@costanti'
|
||||||
|
import { shared_consts } from '@src/common/shared_vuejs'
|
||||||
|
// import MixinBase from '@src/mixins/mixin-base'
|
||||||
|
import { CCatalogoCard } from '@src/components/CCatalogoCard'
|
||||||
|
|
||||||
|
|
||||||
|
export default defineComponent({
|
||||||
|
name: 'catalogoInfo',
|
||||||
|
components: { CCatalogoCard },
|
||||||
|
props: {},
|
||||||
|
setup() {
|
||||||
|
const userStore = useUserStore()
|
||||||
|
const globalStore = useGlobalStore()
|
||||||
|
const productStore = useProducts()
|
||||||
|
const $router = useRouter()
|
||||||
|
const $route = useRoute()
|
||||||
|
const $q = useQuasar()
|
||||||
|
const { t } = useI18n();
|
||||||
|
const id = ref('')
|
||||||
|
const cosa = ref(0)
|
||||||
|
|
||||||
|
// const { setValDb, getValDb } = MixinBase()
|
||||||
|
|
||||||
|
function mounted() {
|
||||||
|
// Inizializza
|
||||||
|
console.log('created productInfo')
|
||||||
|
console.log($route)
|
||||||
|
if (!!$route.params.idprod) {
|
||||||
|
id.value = $route.params.idprod.toString()
|
||||||
|
}
|
||||||
|
if (!!$route.params.idprod) {
|
||||||
|
cosa.value = tools.strToVal($route.params.cosa.toString())
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(mounted)
|
||||||
|
|
||||||
|
return {
|
||||||
|
userStore,
|
||||||
|
costanti,
|
||||||
|
tools,
|
||||||
|
toolsext,
|
||||||
|
shared_consts,
|
||||||
|
id,
|
||||||
|
cosa,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
19
src/views/ecommerce/catalogoInfo/catalogoInfo.vue
Executable file
19
src/views/ecommerce/catalogoInfo/catalogoInfo.vue
Executable file
@@ -0,0 +1,19 @@
|
|||||||
|
<template>
|
||||||
|
<q-page class="q-pa-md">
|
||||||
|
<div class="panel">
|
||||||
|
<div class="container">
|
||||||
|
<div class="row justify-center">
|
||||||
|
<CCatalogoCard :id="id" :cosa="cosa" :complete="true"/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</q-page>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" src="./catalogoInfo.ts">
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
@import './catalogoInfo';
|
||||||
|
</style>
|
||||||
1
src/views/ecommerce/catalogoInfo/index.ts
Executable file
1
src/views/ecommerce/catalogoInfo/index.ts
Executable file
@@ -0,0 +1 @@
|
|||||||
|
export {default as catalogoInfo} from './catalogoInfo.vue'
|
||||||
Reference in New Issue
Block a user