Skip to content

Commit

Permalink
Fix second save nested layout agentejo#1485
Browse files Browse the repository at this point in the history
  • Loading branch information
flommy committed Jan 8, 2024
1 parent f7cd602 commit e7691de
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions modules/Cockpit/assets/components/field-layout.tag
Original file line number Diff line number Diff line change
Expand Up @@ -468,8 +468,17 @@
remove(e) {
this.items.splice(e.item.idx, 1);

function checkParent(child) {
if (!child.parent) {
child.update();
} else {
checkParent(child.parent);
}
}

if (opts.child) {
this.parent.update()
checkParent(this);
}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/Collections/views/entry.php
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@

App.ui.notify("Saving successful", "success");

_.extend($this.entry, entry);
_.extend(entry, $this.entry);

$this.fields.forEach(function(field){

Expand Down

0 comments on commit e7691de

Please sign in to comment.