mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-03 04:09:11 +00:00
fix: Remove Add Row and Delete Row options for Packed Items table
This commit is contained in:
@@ -578,6 +578,9 @@ frappe.ui.form.on('Sales Invoice', {
|
|||||||
frm.add_fetch('payment_term', 'invoice_portion', 'invoice_portion');
|
frm.add_fetch('payment_term', 'invoice_portion', 'invoice_portion');
|
||||||
frm.add_fetch('payment_term', 'description', 'description');
|
frm.add_fetch('payment_term', 'description', 'description');
|
||||||
|
|
||||||
|
frm.set_df_property('packed_items', 'cannot_add_rows', true);
|
||||||
|
frm.set_df_property('packed_items', 'cannot_delete_rows', true);
|
||||||
|
|
||||||
frm.set_query("account_for_change_amount", function() {
|
frm.set_query("account_for_change_amount", function() {
|
||||||
return {
|
return {
|
||||||
filters: {
|
filters: {
|
||||||
|
|||||||
@@ -43,6 +43,9 @@ frappe.ui.form.on("Sales Order", {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
frm.set_df_property('packed_items', 'cannot_add_rows', true);
|
||||||
|
frm.set_df_property('packed_items', 'cannot_delete_rows', true);
|
||||||
},
|
},
|
||||||
refresh: function(frm) {
|
refresh: function(frm) {
|
||||||
if(frm.doc.docstatus === 1 && frm.doc.status !== 'Closed'
|
if(frm.doc.docstatus === 1 && frm.doc.status !== 'Closed'
|
||||||
|
|||||||
Reference in New Issue
Block a user