I want to make rate field readonly for first row and editable for second row base on condition. Condition is if item group is service rate must be editable and for other it should be readonly as rate is predefined.
I tried following way from custom script but it makes all row readonly
var df1 = frappe.meta.get_docfield(“Child Table Name”,“field_name”, cur_frm.doc.name);
df1.read_only = 1;
It would be best if we have option like Display Depends On within every field for readonly (Readonly Depends On) property. I tried display depends on using some value of that particular row of child table , it worked perfectly and it does not affect second row.