summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/promotion/promotion_program_line.py
diff options
context:
space:
mode:
authorIT Fixcomart <it@fixcomart.co.id>2024-03-12 02:49:52 +0000
committerIT Fixcomart <it@fixcomart.co.id>2024-03-12 02:49:52 +0000
commit8899771cb6e4d39752a506e7aa95e5e388ff3a9f (patch)
treef436cda35f861b8017823fe36e674fe5687d4fbb /indoteknik_custom/models/promotion/promotion_program_line.py
parent29dfec334ebf6a15a8a66e4af564fd5d812d8d67 (diff)
parent41056a3fcf9cf80ac3609ab32223ffbac5b3ad83 (diff)
Merged in production (pull request #135)
Production
Diffstat (limited to 'indoteknik_custom/models/promotion/promotion_program_line.py')
-rw-r--r--indoteknik_custom/models/promotion/promotion_program_line.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/indoteknik_custom/models/promotion/promotion_program_line.py b/indoteknik_custom/models/promotion/promotion_program_line.py
index cb231889..4bf50ac9 100644
--- a/indoteknik_custom/models/promotion/promotion_program_line.py
+++ b/indoteknik_custom/models/promotion/promotion_program_line.py
@@ -101,8 +101,8 @@ class PromotionProgramLine(models.Model):
weight = sum(x['package_weight'] for x in merged_products)
# Sum of products and free products in 1 package quantity
- products_total = sum(x['price']['price_discount'] * x['qty'] / qty for x in products)
- free_products_total = sum(x['price']['price_discount'] * x['qty'] / qty for x in free_products)
+ products_total = sum(x['price']['price'] * x['qty'] / qty for x in products)
+ free_products_total = sum(x['price']['price'] * x['qty'] / qty for x in free_products)
package_price = products_total + free_products_total
response = {