Skip to content

Commit

Permalink
Merge pull request #12160 from AllanOXDi/fix_user_selection_getting_lost
Browse files Browse the repository at this point in the history
fixes user selection getting lost on closing the sidepanel
  • Loading branch information
AlexVelezLl authored May 21, 2024
2 parents c47d734 + a97c588 commit 28b1ba3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ export default function useQuizCreation() {
section_id: activeSection.value.section_id,
questions: [...questionsNotSelectedToBeReplaced, ...replacements.value],
});
set(replacements, []);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -204,11 +204,13 @@
const showReplacementConfirmation = ref(false);
function handleConfirmClose() {
replacements.value = [];
context.emit('closePanel');
}
function submitReplacement() {
handleReplacement();
this.clearSelectedQuestions();
const count = replacements.value.length;
router.replace({
name: PageNames.EXAM_CREATION_ROOT,
Expand Down Expand Up @@ -333,7 +335,6 @@
this.showCloseConfirmation = true;
next(false);
} else {
this.clearSelectedQuestions();
next();
}
},
Expand Down

0 comments on commit 28b1ba3

Please sign in to comment.