fix: Section collapse in modal (#12536)
Co-authored-by: Suraj Shetty <13928957+surajshetty3416@users.noreply.github.com>
This commit is contained in:
parent
b44ee08a19
commit
c1ab5b8479
2 changed files with 3 additions and 1 deletions
|
|
@ -289,7 +289,7 @@ frappe.ui.form.Layout = Class.extend({
|
|||
},
|
||||
|
||||
refresh_section_collapse: function () {
|
||||
if (!this.doc) return;
|
||||
if (!(this.sections && this.sections.length)) return;
|
||||
|
||||
for (var i = 0; i < this.sections.length; i++) {
|
||||
var section = this.sections[i];
|
||||
|
|
|
|||
|
|
@ -52,6 +52,8 @@ frappe.ui.Dialog = class Dialog extends frappe.ui.FieldGroup {
|
|||
// make fields (if any)
|
||||
super.make();
|
||||
|
||||
this.refresh_section_collapse();
|
||||
|
||||
// show footer
|
||||
this.action = this.action || { primary: { }, secondary: { } };
|
||||
if (this.primary_action || (this.action.primary && this.action.primary.onsubmit)) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue