Skip to content

Resolve "Enqueue Room image disappears"

Thijs Nulle requested to merge 133-enqueue-room-image-disappears into development

What does this mr do?

This merge request solves the issue that if someone switches either from submission to question or chooses a different question, the map associated with the currently selected room disappears.

The bug happened by whenever a select option got changed, it took the index of the recently changed to select an image. E.g. option 1 = Submission, option 2 = Question. You switched from submission to question, the map of room with index 2 would be shown, regardless which one was selected. If only the first room had a map, the map would disappear if any option with another index of 1 was chosen.

Actions taken to fix bug

Changed map_loader.js by checking the currently selected room instead of the most recently changed select option. Also introduced an error function such that there is a fallback if the get request doesn't return anything. Finally did some minor 6refactoring in the lab/enqueue.html such that there is consistency when selecting any of the options.

Does this MR meet the acceptance criteria?

  • I have added a changelog entry to reflect the significant changes I made and the bug I fixed.
  • A test was created to test the bug.
  • I have updated the documentation accordingly.
  • I adhere to the style guide.
Edited by Thijs Nulle

Merge request reports