diff options
| author | Azka Nathan <darizkyfaz@gmail.com> | 2024-07-30 15:17:07 +0700 |
|---|---|---|
| committer | Azka Nathan <darizkyfaz@gmail.com> | 2024-07-30 15:17:07 +0700 |
| commit | fb45665e9598297dfd77054c1c3ff7c2ca9bc67d (patch) | |
| tree | 3428d52ba654d8c853e9791f9018b83417c75e17 | |
| parent | 17ca05da0a12eb2f1207b0c559aab1ff3d49f0b7 (diff) | |
fix bug email reminder
| -rw-r--r-- | indoteknik_custom/models/website_user_cart.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/indoteknik_custom/models/website_user_cart.py b/indoteknik_custom/models/website_user_cart.py index ff8cf65d..e4b10178 100644 --- a/indoteknik_custom/models/website_user_cart.py +++ b/indoteknik_custom/models/website_user_cart.py @@ -178,10 +178,9 @@ class WebsiteUserCart(models.Model): discount_amount = line.discount_amount break - product_discount = subtotal_promo if cart.program_line_id else subtotal + product_discount = subtotal_promo if cart.program_line_id or check['is_flashsale'] else subtotal total_discount += product_discount if check['is_flashsale'] == False and cart.product_id.default_code and not 'BOM' in cart.product_id.default_code: - product_discount = subtotal - (subtotal * (discount_amount / 100.0)) voucher_product = subtotal * (discount_amount / 100.0) total_voucher += voucher_product |
