From 853ca1fcee8a5176fa700599c0bb34813858d177 Mon Sep 17 00:00:00 2001 From: ruthra kumar Date: Tue, 22 Oct 2024 10:15:28 +0530 Subject: [PATCH] chore: resolve conflict --- erpnext/accounts/doctype/pricing_rule/utils.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/erpnext/accounts/doctype/pricing_rule/utils.py b/erpnext/accounts/doctype/pricing_rule/utils.py index 98ef8910143..572529580e8 100644 --- a/erpnext/accounts/doctype/pricing_rule/utils.py +++ b/erpnext/accounts/doctype/pricing_rule/utils.py @@ -728,22 +728,11 @@ def get_pricing_rule_items(pr_doc, other_items=False) -> list: def validate_coupon_code(coupon_name): coupon = frappe.get_doc("Coupon Code", coupon_name) -<<<<<<< HEAD - - if coupon.valid_from: - if coupon.valid_from > getdate(today()): - frappe.throw(_("Sorry, this coupon code's validity has not started")) - elif coupon.valid_upto: - if coupon.valid_upto < getdate(today()): - frappe.throw(_("Sorry, this coupon code's validity has expired")) - elif coupon.used >= coupon.maximum_use: -======= if coupon.valid_from and coupon.valid_from > getdate(today()): frappe.throw(_("Sorry, this coupon code's validity has not started")) elif coupon.valid_upto and coupon.valid_upto < getdate(today()): frappe.throw(_("Sorry, this coupon code's validity has expired")) elif coupon.maximum_use and coupon.used >= coupon.maximum_use: ->>>>>>> d04257a32d (fix: coupon code validation logic) frappe.throw(_("Sorry, this coupon code is no longer valid"))