ajustes cart

This commit is contained in:
Jaume Solís 2024-04-18 15:37:31 +02:00
parent 08fb7fa2e2
commit c66d6b4c97
1 changed files with 2 additions and 2 deletions

View File

@ -194,7 +194,7 @@ export const useCartStore = defineStore("cart", () => {
const params = transformOptionsToParams(
availabilityForm.value || availability.value
);
const { correctProduct: { data }, } = await apiBack.get(`products/${product.id}`, { params });
const correctProduct = await apiBack.get(`products/${product.id}`, { params });
//await getProducts(params);
const hasCurrentProduct = computed(() => {
@ -202,7 +202,7 @@ export const useCartStore = defineStore("cart", () => {
});
//if (isEmpty.value) {
if (correctProduct.length === 0) {
if (correctProduct.data.length === 0) {
push("/");
return quasarNotify({
message: