From 4a75c66267397d5d68a6aa3ea65a0aa8f9032121 Mon Sep 17 00:00:00 2001 From: A1Gard Date: Mon, 25 Nov 2024 17:51:41 +0330 Subject: [PATCH] fixed add to card bug for yasamin theme part --- resources/js/client-vue/QuantitiesAddToCard.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/js/client-vue/QuantitiesAddToCard.vue b/resources/js/client-vue/QuantitiesAddToCard.vue index 4d8ba32..db8cbda 100644 --- a/resources/js/client-vue/QuantitiesAddToCard.vue +++ b/resources/js/client-vue/QuantitiesAddToCard.vue @@ -102,9 +102,9 @@ export default { select(i) { document.querySelector('#price').innerText = commafy(this.qz[i].price.toString()) + ' ' + this.currency; let index = this.qz[i].image; + this.selected = i; document.querySelector('#preview a').setAttribute('href', document.querySelector(`#hidden-images a:nth-child(${index + 1})`).getAttribute('href')); document.querySelector('#preview img').setAttribute('src', document.querySelector(`#hidden-images a:nth-child(${index + 1}) img`).getAttribute('src')); - this.selected = i; }, async add2card() { if (this.selected == null) {