|
@@ -47,26 +47,28 @@
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="product-item__price-action">
|
|
<div class="product-item__price-action">
|
|
|
- <q-btn v-if="!basketItem && product.inventory > 0"
|
|
|
|
|
- class="product-btn-add-to-cart"
|
|
|
|
|
- :loading="addToCartLoading"
|
|
|
|
|
- color="primary"
|
|
|
|
|
- @click="addToCart">
|
|
|
|
|
- افزودن به سبد
|
|
|
|
|
- </q-btn>
|
|
|
|
|
- <q-btn v-if="!basketItem && product.inventory === 0"
|
|
|
|
|
|
|
+ <template v-if="product.is_add_to_basket_disabled">
|
|
|
|
|
+ <q-btn v-if="!basketItem && product.inventory > 0"
|
|
|
|
|
+ class="product-btn-add-to-cart"
|
|
|
|
|
+ :loading="addToCartLoading"
|
|
|
|
|
+ color="primary"
|
|
|
|
|
+ @click="addToCart">
|
|
|
|
|
+ افزودن به سبد
|
|
|
|
|
+ </q-btn>
|
|
|
|
|
+ <cart-count-action v-else
|
|
|
|
|
+ :basket-item="basketItem"
|
|
|
|
|
+ :loading="addToCartLoading"
|
|
|
|
|
+ @increase="onIncrease"
|
|
|
|
|
+ @decrease="onDecrease"
|
|
|
|
|
+ @remove="onRemove" />
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <q-btn v-if="product.inventory === 0"
|
|
|
class="product-btn-add-to-cart"
|
|
class="product-btn-add-to-cart"
|
|
|
:loading="addToCartLoading"
|
|
:loading="addToCartLoading"
|
|
|
disable
|
|
disable
|
|
|
color="primary">
|
|
color="primary">
|
|
|
ناموجود
|
|
ناموجود
|
|
|
</q-btn>
|
|
</q-btn>
|
|
|
- <cart-count-action v-else
|
|
|
|
|
- :basket-item="basketItem"
|
|
|
|
|
- :loading="addToCartLoading"
|
|
|
|
|
- @increase="onIncrease"
|
|
|
|
|
- @decrease="onDecrease"
|
|
|
|
|
- @remove="onRemove" />
|
|
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|