Skip to content

Commit

Permalink
Merge pull request #3152 from ONE-F-M/186991394
Browse files Browse the repository at this point in the history
Chore: Make Item Table Read Only if the status is Approved.
  • Loading branch information
pjamsheer authored Feb 12, 2024
2 parents 742de85 + c2c80bd commit e711e52
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,10 @@ frappe.ui.form.on('Request for Material', {
frm.set_df_property('type', 'options', "\nIndividual\nDepartment\nProject\nOnboarding");
}
}
if(frm.doc.workflow_state == "Approved" || frm.doc.workflow_state == "Rejected"){
frm.set_df_property('items', 'allow_on_submit', 0);
frm.set_df_property('items', 'read_only', 1);
}
if(frm.is_new()){
frappe.call({
doc: frm.doc,
Expand Down

0 comments on commit e711e52

Please sign in to comment.