Skip to content
Snippets Groups Projects
Commit 3aea7e7a authored by rhenck's avatar rhenck
Browse files

[editor] Fix transfered elements not updating static/dynamic

parent 97f5cfbf
No related branches found
No related tags found
No related merge requests found
...@@ -183,7 +183,10 @@ export class UnitService { ...@@ -183,7 +183,10 @@ export class UnitService {
/* Move element between sections */ /* Move element between sections */
transferElement(elements: UnitUIElement[], previousSection: UnitPageSection, newSection: UnitPageSection): void { transferElement(elements: UnitUIElement[], previousSection: UnitPageSection, newSection: UnitPageSection): void {
previousSection.elements = previousSection.elements.filter(element => !elements.includes(element)); previousSection.elements = previousSection.elements.filter(element => !elements.includes(element));
elements.forEach(element => newSection.elements.push(element)); elements.forEach(element => {
newSection.elements.push(element);
element.dynamicPositioning = newSection.dynamicPositioning;
});
this._unit.next(this._unit.value); this._unit.next(this._unit.value);
this.veronaApiService.sendVoeDefinitionChangedNotification(); this.veronaApiService.sendVoeDefinitionChangedNotification();
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment