- poster
This commit is contained in:
@@ -18,9 +18,9 @@ export default defineComponent({
|
||||
default: '',
|
||||
},
|
||||
myheight: {
|
||||
type: String,
|
||||
type: Number,
|
||||
required: false,
|
||||
default: '',
|
||||
default: 0,
|
||||
},
|
||||
myheightmobile: {
|
||||
type: Number,
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
<q-parallax
|
||||
:speed="speed ? speed : 1"
|
||||
:height="myheight"
|
||||
>
|
||||
<template v-slot:media>
|
||||
<img
|
||||
@@ -24,9 +25,9 @@
|
||||
:class="tools.getClassAnim(anim)"
|
||||
:style="
|
||||
logowidth
|
||||
? `width: ` + logowidth + `px; + `
|
||||
: undefined + logoheight
|
||||
? ` height: ` + logoheight + `px`
|
||||
? `width: ` + logowidth + `px !important; + `
|
||||
: undefined
|
||||
? ` height: ` + logoheight + `px !important`
|
||||
: undefined
|
||||
"
|
||||
/>
|
||||
|
||||
@@ -53,14 +53,14 @@ export default defineComponent({
|
||||
|
||||
const site = ref(globalStore.site)
|
||||
|
||||
const myorder = reactive(<IOrder>{
|
||||
let myorder = reactive(<IOrder>{
|
||||
idapp: process.env.APP_ID,
|
||||
quantity: 0,
|
||||
quantitypreordered: 0,
|
||||
idStorehouse: '',
|
||||
idGasordine: '',
|
||||
storehouse: {},
|
||||
gasordine: {},
|
||||
gasordine: {active: false},
|
||||
})
|
||||
|
||||
const storeSelected = ref('')
|
||||
@@ -148,8 +148,22 @@ export default defineComponent({
|
||||
}
|
||||
}
|
||||
|
||||
function initproduct() {
|
||||
|
||||
myorder.quantity = 0
|
||||
myorder.quantitypreordered = 0
|
||||
myorder.idStorehouse = ''
|
||||
myorder.idGasordine = ''
|
||||
|
||||
gasordineSelected.value = ''
|
||||
recgasordineSelected.value = null
|
||||
|
||||
}
|
||||
|
||||
function updateproduct() {
|
||||
|
||||
myproduct.value = products.getProductById(props.id)
|
||||
|
||||
// products.updateQuantityAvailable(myproduct.value._id)
|
||||
}
|
||||
|
||||
@@ -231,9 +245,16 @@ export default defineComponent({
|
||||
})
|
||||
|
||||
function updateLabel() {
|
||||
//labelDataRitiro.value = tools.getstrDateTime(recgasordineSelected.value.dataora_ritiro)
|
||||
labelDataArrivoMerce.value = tools.getstrDateShort(recgasordineSelected.value.data_arrivo_merce)
|
||||
labelDataRitiro.value = tools.getstrDateTime(recgasordineSelected.value.dataora_ritiro)
|
||||
if (recgasordineSelected.value) {
|
||||
//labelDataRitiro.value = tools.getstrDateTime(recgasordineSelected.value.dataora_ritiro)
|
||||
if (recgasordineSelected.value.data_arrivo_merce)
|
||||
labelDataArrivoMerce.value = tools.getstrDateShort(recgasordineSelected.value.data_arrivo_merce)
|
||||
if (recgasordineSelected.value.dataora_ritiro)
|
||||
labelDataRitiro.value = tools.getstrDateTime(recgasordineSelected.value.dataora_ritiro)
|
||||
} else {
|
||||
labelDataArrivoMerce.value = ''
|
||||
labelDataRitiro.value = ''
|
||||
}
|
||||
}
|
||||
|
||||
function mounted() {
|
||||
@@ -260,6 +281,7 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
function load() {
|
||||
initproduct()
|
||||
updateproduct()
|
||||
// console.log('Load', myproduct.value.name)
|
||||
// console.log('created Cproductcard', code)
|
||||
@@ -275,7 +297,7 @@ export default defineComponent({
|
||||
if (myproduct.value.gasordines && myproduct.value.gasordines.length === 1) {
|
||||
myorder.idGasordine = myproduct.value.gasordines[0]._id
|
||||
gasordineSelected.value = myorder.idGasordine!
|
||||
}
|
||||
}
|
||||
|
||||
const ord = products.getOrderProductInCart(myproduct.value._id)
|
||||
if (ord) {
|
||||
@@ -285,7 +307,6 @@ export default defineComponent({
|
||||
if (ord.idGasordine) {
|
||||
gasordineSelected.value = ord.idGasordine!
|
||||
recgasordineSelected.value = myproduct.value.gasordines.find((rec: IGasordine) => rec._id === ord.idGasordine!)
|
||||
updateLabel()
|
||||
}
|
||||
|
||||
// Seleziona il Negozio che avevo già scelto nell'ordine !
|
||||
@@ -296,11 +317,12 @@ export default defineComponent({
|
||||
|
||||
if (gasordineSelected.value) {
|
||||
recgasordineSelected.value = myproduct.value.gasordines.find((rec: IGasordine) => rec._id === gasordineSelected.value)
|
||||
updateLabel()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
updateLabel()
|
||||
|
||||
// console.log('°°° ENDLOAD °°°')
|
||||
endload.value = true
|
||||
}
|
||||
|
||||
@@ -355,8 +355,9 @@ h3 {
|
||||
|
||||
.myimgproduct{
|
||||
max-width: 100%;
|
||||
height: 300px;
|
||||
height: 500px;
|
||||
@media (max-width: 718px) {
|
||||
height: 300px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1571,6 +1572,18 @@ h3 {
|
||||
-webkit-animation-duration: calc(var(--animate-duration) * 20);
|
||||
animation-duration: calc(var(--animate-duration) * 20);
|
||||
}
|
||||
.animate__animated.animate__slow30 {
|
||||
-webkit-animation-duration: calc(1s * 30);
|
||||
animation-duration: calc(1s * 30);
|
||||
-webkit-animation-duration: calc(var(--animate-duration) * 30);
|
||||
animation-duration: calc(var(--animate-duration) * 30);
|
||||
}
|
||||
.animate__animated.animate__slow50 {
|
||||
-webkit-animation-duration: calc(1s * 50);
|
||||
animation-duration: calc(1s * 50);
|
||||
-webkit-animation-duration: calc(var(--animate-duration) * 50);
|
||||
animation-duration: calc(var(--animate-duration) * 50);
|
||||
}
|
||||
|
||||
.animate__animated.animate__ease-in-out {
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
|
||||
@@ -3,6 +3,7 @@ import {
|
||||
} from 'vue-router'
|
||||
|
||||
import { cfgrouter } from './route-config'
|
||||
import { useGlobalStore } from '@src/store/globalStore';
|
||||
|
||||
export default function (/* { store, ssrContext } */) {
|
||||
const routermode = process.env.VUE_ROUTER_MODE === 'history' ? createWebHistory : createWebHashHistory
|
||||
@@ -11,15 +12,32 @@ export default function (/* { store, ssrContext } */) {
|
||||
? createMemoryHistory
|
||||
: routermode
|
||||
|
||||
return createRouter({
|
||||
const router = createRouter({
|
||||
scrollBehavior: () => ({ left: 0, top: 0 }),
|
||||
routes: cfgrouter.getmenu(),
|
||||
|
||||
// Leave this as is and make changes in quasar.conf.js instead!
|
||||
// quasar.conf.js -> build -> vueRouterMode
|
||||
// quasar.conf.js -> build -> publicPath
|
||||
history: createHistory(
|
||||
process.env.MODE === 'ssr' ? void 0 : process.env.VUE_ROUTER_BASE,
|
||||
),
|
||||
})
|
||||
});
|
||||
|
||||
// Add the beforeEach hook
|
||||
router.beforeEach((to, from, next) => {
|
||||
// Execute your command before each navigation
|
||||
// executeCommand();
|
||||
|
||||
const globalStore = useGlobalStore()
|
||||
try {
|
||||
globalStore.editOn = false
|
||||
} catch(e) {
|
||||
|
||||
}
|
||||
|
||||
|
||||
// Continue with the navigation
|
||||
next();
|
||||
});
|
||||
|
||||
return router;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -625,6 +625,14 @@ export const tools = {
|
||||
label: '[Nessuna]',
|
||||
value: '',
|
||||
},
|
||||
{
|
||||
label: 'Slow 50s',
|
||||
value: 'animate__slow50',
|
||||
},
|
||||
{
|
||||
label: 'Slow 30s',
|
||||
value: 'animate__slow30',
|
||||
},
|
||||
{
|
||||
label: 'Slow 20s',
|
||||
value: 'animate__slow20',
|
||||
|
||||
@@ -372,10 +372,8 @@ export const useProducts = defineStore('Products', {
|
||||
|
||||
let ris = null
|
||||
|
||||
console.log('Ottieni Prodotti')
|
||||
ris = await Api.SendReq('/products', 'POST', { userId: userStore.my._id })
|
||||
.then((res) => {
|
||||
console.log('Prodotti scaricati')
|
||||
if (res.data.products) {
|
||||
this.products = res.data.products
|
||||
} else {
|
||||
|
||||
BIN
upload/pages/home/pcb.jpg
Normal file
BIN
upload/pages/home/pcb.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 164 KiB |
Reference in New Issue
Block a user