Skip to content

Commit

Permalink
Bug fix: nested selection
Browse files Browse the repository at this point in the history
Signed-off-by: Justin Georgi <justin.georgi@gmail.com>
  • Loading branch information
JustinGeorgi committed Oct 2, 2023
1 parent 62ff8ac commit e0109d8
Showing 1 changed file with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,7 @@ export default {
.filter((i) => (!i.metadata.semantics.config || !i.metadata.semantics.config.isPartOf) && (i.templates & (1 << this.selectedTemplate)))
.map(this.modelItem).sort(compareModelItems)
newModel.forEach(this.getChildren)
this.setCurrentTemplate(newModel)
this.setCurrentModel(newModel)
return newModel
}
Expand Down Expand Up @@ -518,8 +518,8 @@ export default {
return modelItem
},
setCurrentTemplate (model) {
setCurrentModel (model) {
this.currentModel = model
},
getChildren (parent) {
// restore previous selection
Expand Down Expand Up @@ -568,8 +568,10 @@ export default {
} else {
this.checkedItems.splice(this.checkedItems.indexOf(item), 1)
item.children.locations.forEach((i) => {
i.checked = false
this.checkItem(i, false)
if (i.checked) {
i.checked = false
this.checkItem(i, false)
}
})
}
},
Expand Down

0 comments on commit e0109d8

Please sign in to comment.