Restriction by single quiz question

Availability restriction ::: availability_quizquestion
Maintained by TimTim Hunt, Shamim Rezaie, Benjamin Schröder, Martin Hanusch
This is a Moodle conditional availability rule, which makes it possible to show or hide another resource, based on the state of one particular question in one quiz.
Latest release:
434 sites
90 downloads
30 fans
Current versions available: 1

This is a Moodle conditional availability rule, which makes it possible to show or hide another resource, based on the state of one particular question in one quiz. So, if you want show a particular help document to students who got Question 2 in the quiz wrong, well this plugin lets you do that.

At the moment, this only supports non-random questions, but it may be possible to extend it in the future.

Screenshots

Screenshot #0
Screenshot #1

Contributors

Tim
Tim Hunt (Lead maintainer)
Shamim Rezaie: Developer
Benjamin Schröder: Developer
Martin Hanusch: Developer
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Tim
    Tue, 10 Aug 2021, 2:55 PM
    The latest version of the plugin works with Moodle 3.11. I just checked. (Sorry it took so long.)
  • Jeff Lewis
    Wed, 1 June 2022, 9:59 AM
    Hi Tim, FYI - It does NOT work with Moodle 4.01. Unable to choose a specific question, so previous restrictions based on this no longer work in 4.01.
    Great plugin! I hope you get a chance to update it.
  • Tim
    Wed, 1 June 2022, 3:13 PM
    That observation is correct.

    I started working on this some time ago https://github.com/timhunt/moodle-availability_quizquestion/commit/a0dc93223a55b23d4b49adc87d194157423447ed, but I ran out of time before it was actually working: https://github.com/timhunt/moodle-availability_quizquestion/actions/runs/2012129139.

    I have now made filter_embedquestion work, and the fixes required here are probably similar. However, what I don't have at the moment is time to work on it.
  • Jeff Lewis
    Thu, 2 June 2022, 5:02 AM
    Hi Tim, thanks for the update. Sincerely appreciate that it's in the works as your time allows. Sorry I don't have the necessary expertise to help. Regards.
  • Jeff Lewis
    Sat, 10 Sept 2022, 7:17 AM
    Hi Tim, hope you're doing well. Any possible ETA on when this might be updated for Moodle 4? We'd love to update to Moodle 4, but rely on this great Plugin too much for that to be possible until it's compatible. Much appreciated!
  • Tim
    Sat, 10 Sept 2022, 6:20 PM
    I am sorry, but I cannot promise anything at the moment. I seem to have many thing to do.

    I made a start at https://github.com/timhunt/moodle-availability_quizquestion/commit/a0dc93223a55b23d4b49adc87d194157423447ed#diff-68cf389f000a345b3f9a3fa48127930c19fe5ff4e108d37b835754cc2eef0c86, but this does not work yet. I think the failing automated tests point roughly towards what needs to be fixed.

    If anyone else is able to work on this, that would be very helpful.
  • Jeff Lewis
    Sun, 11 Sept 2022, 8:29 AM
    Thanks for the update Tim. Good luck with all that you have going.

    If there is anyone else who can help with this, it would be greatly appreciated. As previously stated, we can't upgrade to Moodle 4 without it. Unfortunately, we're new to this, so don't have the necessary expertise. Best to all, regardless.
  • Tim
    Tue, 20 Sept 2022, 12:41 AM
    OK, I managed to update the plugin. I think it now workes with 4.0 - but it coudl do with some more testing before I release it.

    @Jeff, are you able to test the lastest version on the main branch in git?
  • Jeff Lewis
    Tue, 20 Sept 2022, 4:17 AM
    Hi Tim, that's exciting news. Unfortunately, I have no idea what "test the latest version on the main branch in git" actually means or entails. If it's simple enough, I'm happy to do it though; just let me know how.
  • Tim
    Tue, 20 Sept 2022, 4:55 AM
    Sorry. If you go to https://github.com/timhunt/moodle-availability_quizquestion, Click the green 'Code' button top right of the middle of the page, there should be a 'Download ZIP' option there. You should be able to feed that zip to Moodle plugin update system in the admin screens of your site - I think.

    (Other, geeker, methods exist. With git version control system, there are always a million ways to do anything.)
  • Jeff Lewis
    Tue, 20 Sept 2022, 5:04 AM
    No worries; will do! Thanks again!
  • Jeff Lewis
    Fri, 30 Sept 2022, 8:34 AM
    Hi Tim,

    I did a thorough check through its many instances in one of our Courses and the Plugin worked great, once each instance was reset. Unfortunately, every Restriction did need to be reset to the specific Question desired. The reference to the Activity the Question was contained within remained intact, just not the actual question itself.

    Sincere thanks for everything; you've certainly got your hands full! You're everywhere!! smile)
  • Tim
    Sat, 1 Oct 2022, 12:40 AM
    Thanks for testing it out and reporting back. So, clearly something has gone wrong in the upgrade code (which is a pain, becuase it is the hardest bit to test). I'll see if I can fix it some time, although it is probably too late for your site.
  • Jeff Lewis
    Sat, 1 Oct 2022, 4:11 AM
    No worries, thanks for making it work as it does thus far.
    FYI, all sorts of things have gotten weird with my upgrade to 4.04 since I Reset the Course in my attempt to fix the 403 Forbidden error I've been getting when I try to add/edit certain questions, (like one quiz still showing an Attempt has been made after the Course was completely Reset; and the Course Summary block no longer showing any courses now), so I'm going to try another upgrade from 3.11. I need to get to it shortly, so if that works for you in terms of testing the upgrade code for this, happy to do it. If not, it's not a big deal for me to reset the Single Question Restrictions again.
    Thanks again!!
  • Jeff Lewis
    Sat, 1 Oct 2022, 4:21 AM
    Sorry, I meant the "Course overview" block under "My courses", not "Course Summary block."
1 2
Please login to post comments