fix(replace): change from standard to multi loop characteristics

Closes #1673
This commit is contained in:
Beatriz Mendes
2022-06-09 11:02:16 +02:00
committed by fake-join[bot]
parent 6eb9aceb84
commit f81f9e534b
2 changed files with 64 additions and 6 deletions

View File

@ -427,18 +427,19 @@ ReplaceMenuProvider.prototype._getLoopEntries = function(element) {
var translate = this._translate;
function toggleLoopEntry(event, entry) {
var loopCharacteristics = getBusinessObject(element).loopCharacteristics;
var newLoopCharacteristics = getBusinessObject(element).loopCharacteristics;
if (entry.active) {
loopCharacteristics = undefined;
newLoopCharacteristics = undefined;
} else {
if (isUndefined(entry.options.isSequential) || !loopCharacteristics) {
loopCharacteristics = self._moddle.create(entry.options.loopCharacteristics);
if (isUndefined(entry.options.isSequential) || !newLoopCharacteristics
|| !is(newLoopCharacteristics, entry.options.loopCharacteristics)) {
newLoopCharacteristics = self._moddle.create(entry.options.loopCharacteristics);
}
loopCharacteristics.isSequential = entry.options.isSequential;
newLoopCharacteristics.isSequential = entry.options.isSequential;
}
self._modeling.updateProperties(element, { loopCharacteristics: loopCharacteristics });
self._modeling.updateProperties(element, { loopCharacteristics: newLoopCharacteristics });
}
var businessObject = getBusinessObject(element),