Moodle
  1. Moodle
  2. MDL-32048

Quiz: Question bank - select/deselect all shows strange behaviour (IE7/8)

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2
    • Fix Version/s: 2.1.6, 2.2.3
    • Component/s: Questions, Quiz
    • Labels:
    • Testing Instructions:
      Hide

      1) create at least two questions.
      2) create a quiz (this is not necessary, but it will demo the functionality on "Editing quiz" page where question bank is displayed)
      3) go to question bank page and click on the checkbox in the table header using following browsers (It works in Firefox, chrome and IE9, and it is cnfusing on IE7 / IE8. For details see Description section in this bug.

      Show
      1) create at least two questions. 2) create a quiz (this is not necessary, but it will demo the functionality on "Editing quiz" page where question bank is displayed) 3) go to question bank page and click on the checkbox in the table header using following browsers (It works in Firefox, chrome and IE9, and it is cnfusing on IE7 / IE8. For details see Description section in this bug.
    • Workaround:
      Hide

      in questions/qbank.js

      YAHOO.util.Event.addListener(question_bank.headercheckbox, 'chnage', question_bank.header_checkbox_click);

      needs to be changed to:
      YAHOO.util.Event.addListener(question_bank.headercheckbox, 'click', question_bank.header_checkbox_click);

      Show
      in questions/qbank.js YAHOO.util.Event.addListener(question_bank.headercheckbox, 'chnage', question_bank.header_checkbox_click); needs to be changed to: YAHOO.util.Event.addListener(question_bank.headercheckbox, 'click', question_bank.header_checkbox_click);
    • Affected Branches:
      MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE
    • Pull from Repository:
    • Rank:
      38732

      Description

      At the top of the question bank there is a select all/deselect all tick box next to the 'T' sort option.

      Firefox, Chrome, IE9: Ticking and unticking this box had the expected outcome. It selects or deselects all the questions in the list so the tick boxes for the questions are either all empty or all ticked.

      IE7, IE8: Behaviour is different and not as expected. Ticking or unticking this box initially seemed to have no effect on the individual tick boxes below. What you need to do to get it to work is the following:
      1. Click in the box to either select or deselect all (nothing appears to happen to the individual questions)
      2. Now mouse click somewhere else on the page (you now see the expected reponse - individual question tick boxes are now all ticked or not as appropriate).

        Activity

        Hide
        Mahmoud Kassaei added a comment -
        Show
        Mahmoud Kassaei added a comment - here is the diff for review https://github.com/mkassaei/moodle/compare/MOODLE_22_STABLE...MDL-32048
        Hide
        Tim Hunt added a comment -

        Nice one. Thanks Mahmoud. Submitting for integration.

        To INTEGRATORS, please cherry-pick this fix to the 21, 22 and master branches. Thanks.

        Show
        Tim Hunt added a comment - Nice one. Thanks Mahmoud. Submitting for integration. To INTEGRATORS, please cherry-pick this fix to the 21, 22 and master branches. Thanks.
        Hide
        Sam Hemelryk added a comment -

        Thanks Mahmoud this has been integrated now.
        Just as small request for the future, can you please structure your commit messages as laid out in our coding guidelines.

        MDL-XXXXX component: commit message

        Cheers
        Sam

        Show
        Sam Hemelryk added a comment - Thanks Mahmoud this has been integrated now. Just as small request for the future, can you please structure your commit messages as laid out in our coding guidelines. MDL-XXXXX component: commit message Cheers Sam
        Hide
        Michael de Raadt added a comment -

        Test result: Success.

        This now works consistenly in IE8 and other browsers. Tested in 2.1, 2.2 and master.

        Show
        Michael de Raadt added a comment - Test result: Success. This now works consistenly in IE8 and other browsers. Tested in 2.1, 2.2 and master.
        Hide
        Sam Hemelryk added a comment -

        Congratulations are in order, you've made it, or at least your code has!
        It's now part of Moodle and both the git and cvs repositories have been updated.

        This issue is being marked as fixed and closed.

        Thank you.

        Show
        Sam Hemelryk added a comment - Congratulations are in order, you've made it, or at least your code has! It's now part of Moodle and both the git and cvs repositories have been updated. This issue is being marked as fixed and closed. Thank you.

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: