ERPNext Foundation ERPNext Cloud Chat Blog Discuss Frappé* Donate

How can I expand/collapse a section from custom script/runtime?


#1

Hi everyone, i’ve been searching everywhere for a reference code on how to expand/collapse a doctype section from runtime, couldn’t find any.

Can anyone tell me how I can expand/collapse a section from custom script?


#3

execute below code in browser console when in sales order form
cur_frm.fields_dict[“contact_info”].collapse(0)
cur_frm.fields_dict[“contact_info”].collapse(1)


#4

It works! Much thanks!


#5