fix(asset): recompute reference doc reqd on asset type change

The asset_type change handler no longer called toggle_reference_doc, so
switching the asset type never cleared the mandatory flags on
purchase_receipt/purchase_invoice, throwing a mandatory error on the
first save.
This commit is contained in:
khushi8112
2026-09-10 20:10:07 +05:30
parent 7238ecb306
commit 6d447f6847

View File

@@ -571,6 +571,7 @@ frappe.ui.form.on("Asset", {
frm.set_df_property("net_purchase_amount", "read_only", 0);
}
}
frm.trigger("toggle_reference_doc");
},
create_asset_maintenance: function (frm) {