fix: use ValueWrapper consistently

(cherry picked from commit a2fadd9347)
This commit is contained in:
Smit Vora
2025-11-28 13:33:24 +05:30
committed by Mergify
parent 9f07579a05
commit 79181e307c
2 changed files with 3 additions and 4 deletions

View File

@@ -7,6 +7,7 @@ import frappe
from frappe import _
from frappe.model.document import Document
from frappe.utils import cint, flt, sbool
from pypika.terms import ValueWrapper
from erpnext.manufacturing.doctype.bom.bom import get_bom_item_rate
@@ -360,8 +361,6 @@ class BOMCreator(Document):
@frappe.whitelist()
def get_children(doctype=None, parent=None, **kwargs):
from pypika.terms import ValueWrapper
if isinstance(kwargs, str):
kwargs = frappe.parse_json(kwargs)

View File

@@ -1,5 +1,5 @@
import frappe
from pypika.terms import LiteralValue
from pypika.terms import ValueWrapper
from erpnext.accounts.general_ledger import make_reverse_gl_entries
@@ -40,7 +40,7 @@ def execute():
"payment_amount",
# at the time of creating this dunning, the full amount was outstanding
"payment_amount as outstanding",
LiteralValue(0).as_("paid_amount"),
ValueWrapper(0).as_("paid_amount"),
"discounted_amount",
],
)