Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-41394

Clean up polls events

    Details

    • Type: Bug
    • Status: RESOLVED
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 20.0
    • Fix Version/s: 20.0
    • Component/s: Polls
    • Labels:
    • Test Plan:
      Hide
      • create a new poll, add two options, vote for one option, view the results, delete the poll
      • check the sakai_event table, you should see just one of each of the following events:
        • poll.add (for creating the poll)
        • poll.update (for adding the options)
        • poll.vote
        • poll.viewResult
        • poll.delete
      • the ref for each of the above events should be the same and follow the format "poll/site/<site_id>/poll/<integer_poll_id>"
      • create a second poll, set the max to a value greater than one, vote on the poll selecting at least two options
      • check the sakai_event table, you should see one poll.vote event for each option you selected
      Show
      create a new poll, add two options, vote for one option, view the results, delete the poll check the sakai_event table, you should see just one of each of the following events: poll.add (for creating the poll) poll.update (for adding the options) poll.vote poll.viewResult poll.delete the ref for each of the above events should be the same and follow the format "poll/site/<site_id>/poll/<integer_poll_id>" create a second poll, set the max to a value greater than one, vote on the poll selecting at least two options check the sakai_event table, you should see one poll.vote event for each option you selected

      Description

      Events fired by the polls tool do not have a consistent ref format, and are sometimes duplicated or misnamed because the LRS support added to polls creates its own events in addition to the existing polls events.

      After this patch:

      • all polls event refs will use the same format: poll/site/<site_id>/poll/<integer_poll_id>
      • events with LRS support will not fire any additional events, and the LRS events will use a proper poll ref instead of simple strings like "vote" and "edit poll"
      • the "poll.edit" event fired by the LRS support code will use the original event name, "poll.update" instead
      • the "poll.vote" event will fire once for each selected option (for polls that allow multiple selection), as this is how the LRS support works. This differs from legacy behaviour of one event for the entire voting action but has likely been the case since the LRS support was added.

        Gliffy Diagrams

          Zeplin

            Attachments

              Issue Links

                Activity

                  People

                  Assignee:
                  plukasew Paul Lukasewych
                  Reporter:
                  plukasew Paul Lukasewych
                  Votes:
                  0 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                    Dates

                    Created:
                    Updated:
                    Resolved:

                      Git Integration