Purchase invoice and Receipt required for asset creation

we are trying to create an asset, however it requires us to fill in purchase invoice and purchase receipt, even if it is an existing asset.

However, even when I am trying to make them optional, I cannot as in the customize form they are shown as not mandatory, has anybody encountered this problem?

1 Like

-For an existing asset, you can create the asset record directly checking “Is Existing Asset” field. In this case, you also need to enter already booked depreciation amount and number of booked depreciation. And based on the input, the system will create a schedule for remaining depreciation.

-For new assets, you cannot create the asset record directly from the Asset form. You need to create a Purchase Receipt/Invoice for it.

For more details refer link Asset

1 Like

I am facing the same issue.
I cannot create asset directly even if checking “is Existing Asset” it still require Purchase Receipt/Invoice.

I solved it for us using a custom script
for asset client

frappe.ui.form.on(‘Asset’, {
refresh(frm) {
frm.set_df_property(‘purchase_invoice’, ‘reqd’, 0);
frm.set_df_property(‘purchase_receipt’, ‘reqd’, 0);

how can i do this custom script?

Search on your ERPNext for Custom Script or go to
YOUR_ERPNEXT/desk#List/Custom%20Script/List (for example http://erpnext.testing.com//desk#List/Custom%20Script/List)
with your browser

i tried to make the script now i get this error:

issue fixed buy using double quotes instead of single quotes
frappe.ui.form.on(“Asset”, {
frm.set_df_property(“purchase_invoice”, “reqd”, 0);
frm.set_df_property(“purchase_receipt”, “reqd”, 0);