mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-13 02:01:21 +00:00
fix: patch to set grand total to default mop if old column exists (#47731)
* fix: patch to set grand total to default mop if old column exists * chore: patches.txt
This commit is contained in:
@@ -2,8 +2,9 @@ import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
POSProfile = frappe.qb.DocType("POS Profile")
|
||||
if frappe.db.has_column("POS Profile", "disable_grand_total_to_default_mop"):
|
||||
POSProfile = frappe.qb.DocType("POS Profile")
|
||||
|
||||
frappe.qb.update(POSProfile).set(POSProfile.set_grand_total_to_default_mop, 1).where(
|
||||
POSProfile.disable_grand_total_to_default_mop == 0
|
||||
).run()
|
||||
frappe.qb.update(POSProfile).set(POSProfile.set_grand_total_to_default_mop, 1).where(
|
||||
POSProfile.disable_grand_total_to_default_mop == 0
|
||||
).run()
|
||||
|
||||
Reference in New Issue
Block a user