Merge branch 'version-14-hotfix' into mergify/bp/version-14-hotfix/pr-38250

This commit is contained in:
Gursheen Kaur Anand
2023-11-30 14:15:12 +05:30
committed by GitHub
4 changed files with 18 additions and 5 deletions

View File

@@ -1809,6 +1809,8 @@ class QueryPaymentLedger(object):
.where(ple.delinked == 0)
.where(Criterion.all(filter_on_against_voucher_no))
.where(Criterion.all(self.common_filter))
.where(Criterion.all(self.dimensions_filter))
.where(Criterion.all(self.voucher_posting_date))
.groupby(ple.against_voucher_type, ple.against_voucher_no, ple.party_type, ple.party)
.orderby(ple.posting_date, ple.voucher_no)
.having(qb.Field("amount_in_account_currency") > 0)

View File

@@ -15,6 +15,9 @@ from erpnext.stock.doctype.purchase_receipt.test_purchase_receipt import make_pu
class TestAssetValueAdjustment(unittest.TestCase):
def setUp(self):
create_asset_data()
frappe.db.set_value(
"Company", "_Test Company", "capital_work_in_progress_account", "CWIP Account - _TC"
)
def test_current_asset_value(self):
pr = make_purchase_receipt(

View File

@@ -705,8 +705,8 @@ def get_mapped_subcontracting_order(source_name, target_doc=None):
@frappe.whitelist()
def is_subcontracting_order_created(po_name) -> bool:
count = frappe.db.count(
"Subcontracting Order", {"purchase_order": po_name, "status": ["not in", ["Draft", "Cancelled"]]}
return (
True
if frappe.db.exists("Subcontracting Order", {"purchase_order": po_name, "docstatus": ["=", 1]})
else False
)
return True if count else False

View File

@@ -45,6 +45,7 @@
"subcontracting_receipt_item",
"section_break_45",
"bom",
"include_exploded_items",
"serial_no",
"col_break5",
"batch_no",
@@ -465,12 +466,19 @@
"fieldname": "accounting_details_section",
"fieldtype": "Section Break",
"label": "Accounting Details"
},
{
"default": "0",
"fieldname": "include_exploded_items",
"fieldtype": "Check",
"label": "Include Exploded Items",
"print_hide": 1
}
],
"idx": 1,
"istable": 1,
"links": [],
"modified": "2023-11-14 18:38:26.459669",
"modified": "2023-11-30 12:05:51.920705",
"modified_by": "Administrator",
"module": "Subcontracting",
"name": "Subcontracting Receipt Item",