Skip to content

Commit

Permalink
feat: Allow to edit Page with referenced content - MEED-6783 - Meeds-…
Browse files Browse the repository at this point in the history
…io/MIPs#131 (#52)

Prior to this change, when editing a page, its preferences isn't
considered. This change will allow to preserve the portlet preferences
in order to keep the same referenced Content.
  • Loading branch information
boubaker authored May 6, 2024
1 parent 0cf6aa0 commit f3d7b8e
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,12 +74,8 @@ export default {
watch: {
pageLoaded() {
if (this.pageLoaded) {
this.$pageLayoutService.getPageLayout(this.pageRef, 'contentId')
.then(layout => {
const draftPageLayout = this.$layoutUtils.cleanAttributes(layout, true, false);
return this.$pageLayoutService.updatePageLayout(this.draftPageRef, draftPageLayout, 'contentId')
.then(draftLayout => this.setDraftLayout(draftLayout));
});
this.$pageLayoutService.getPageLayout(this.draftPageRef, 'contentId')
.then(draftLayout => this.setDraftLayout(draftLayout));
}
},
pageRef: {
Expand Down

0 comments on commit f3d7b8e

Please sign in to comment.