Hi, I’m trying to hide a field in the Quotation doctype called customer_name of type Data. It’s not mandatory and it’s read-only.
I checked ‘Hidden’ in the Customize Form but doesn’t work.
I wrote a script to hide but also didn’t hide.
All fields can be hidden except this
frappe.ui.form.on('Quotation', {
refresh: function (frm) {
//hide customer_name field always on loading page
frm.toggle_display("customer_name", true);
})
NCP
April 22, 2022, 11:01am
2
Hi @Mohsin1990 ,
Please apply and check it.
frappe.ui.form.on("Quotation",{
refresh(frm){
frm.toggle_display("customer_name", false);
}
});
Thank You!
1 Like
Well I type this impossible condition in the Depends On section and it works
but is there a better way?
1 Like
NCP
April 22, 2022, 11:06am
4
Mohsin1990:
is there a better way?
Can’t use unnecessary conditions because when a new update comes then hidden button will work properly.
Thanks.
Hi @Mohsin1990 @NCP I am also stucked with the same issue. I want to hide the customer_name field. I have checked hidden but it didn’t worked. Created client script still didn’t worked. As of now I have also made it hidden temporarily by your eval condition but did you got any other solution?