aggiornamento visualizzazione Ordini e Carrello
This commit is contained in:
@@ -37,7 +37,7 @@ import { useCircuitStore } from '@store/CircuitStore'
|
||||
import { routesAdmin } from '@src/router/routesAdmin'
|
||||
import { routesECommerce } from '@src/router/routesECommerce'
|
||||
import LandingFooter from '@src/components/LandingFooter/LandingFooter'
|
||||
|
||||
import { useProducts } from '@store/Products'
|
||||
|
||||
const stateConnDefault = 'online'
|
||||
|
||||
@@ -283,6 +283,7 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
const userStore = useUserStore()
|
||||
const messageStore = useMessageStore()
|
||||
const notifStore = useNotifStore()
|
||||
|
||||
|
||||
if (table === costanti.TABEVENTS)
|
||||
return calendarStore.eventlist
|
||||
@@ -1498,6 +1499,8 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
const userStore = useUserStore()
|
||||
const calendarStore = useCalendarStore()
|
||||
const circuitStore = useCircuitStore()
|
||||
const Products = useProducts()
|
||||
|
||||
// console.log('calendarStore: loadAfterLogin')
|
||||
// Load local data
|
||||
const showall = userStore.isAdmin || userStore.isManager ? '1' : '0'
|
||||
@@ -1550,13 +1553,13 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
|
||||
// console.log('res.data.cart', res.data.cart)
|
||||
|
||||
/* if (res.data.cart)
|
||||
if (res.data.cart)
|
||||
Products.cart = (res.data.cart) ? { ...res.data.cart } : {}
|
||||
else
|
||||
Products.cart = { items: [], totalPrice: 0, totalQty: 0, userId: '' }
|
||||
|
||||
Products.orders = (res.data.orders) ? [...res.data.orders] : []
|
||||
*/
|
||||
|
||||
|
||||
if (showall) {
|
||||
this.newstosent = (res.data.newstosent) ? [...res.data.newstosent] : []
|
||||
|
||||
Reference in New Issue
Block a user