summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/website_user_cart.py
diff options
context:
space:
mode:
authorRafi Zadanly <zadanlyr@gmail.com>2023-08-01 11:32:11 +0700
committerRafi Zadanly <zadanlyr@gmail.com>2023-08-01 11:32:11 +0700
commitf8e0259289c728b11a373601e569f6e64ca803f8 (patch)
tree6a97c8c8d735230bdcf5026af0847a94efb27293 /indoteknik_custom/models/website_user_cart.py
parentf785e7605f4d0151a0f48e3d871b996c40e51351 (diff)
Update voucher can't combined with other promotions
Diffstat (limited to 'indoteknik_custom/models/website_user_cart.py')
-rw-r--r--indoteknik_custom/models/website_user_cart.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/indoteknik_custom/models/website_user_cart.py b/indoteknik_custom/models/website_user_cart.py
index 4d85e64d..9b82aa93 100644
--- a/indoteknik_custom/models/website_user_cart.py
+++ b/indoteknik_custom/models/website_user_cart.py
@@ -27,6 +27,8 @@ class WebsiteUserCart(models.Model):
product['selected'] = self.is_selected
product['program'] = None
product['can_buy'] = True
+ product_flashsale = self.product_id._get_active_flash_sale()
+ product['has_flashsale'] = True if len(product_flashsale) > 0 else False
if self.program_line_id:
product['program'] = self.program_line_id.res_format_cart(user=user_data, quantity=self.qty)