If the quiz is closed the Take Quiz tab should be disabled for "takers" and only left available for admins.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | quiz_availability_status_1.patch | 3.07 KB | kscheirer |
| #1 | quiz_availability_status.patch | 3.24 KB | add1sun |
If the quiz is closed the Take Quiz tab should be disabled for "takers" and only left available for admins.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | quiz_availability_status_1.patch | 3.07 KB | kscheirer |
| #1 | quiz_availability_status.patch | 3.24 KB | add1sun |
Comments
Comment #1
add1sun commentedGot this fixed up. Ended up pulling the availability stuff out to a new function so this also touches theme_quiz_availability.
Comment #2
kscheirerlooks good to me!
although purely as a style matter in _quiz_status_access()
I'd leave $access uninitialized, or initialized to FALSE rather than an empty string.
Just seems a little weird to start off with a string, and then return a boolean.
Comment #3
kscheirerwhat about adding a test in _quiz_status_access()
for the quiz being published? then checking against this status could be used to
solve http://drupal.org/node/158966 ?
Comment #4
kscheirerthis is the same patch as addi's,
but with $access defaulting to false,
and an extra check that the quiz is published in addition to 'access quiz' permissions.
Comment #5
kscheirercommitted to 5.x-1.x-dev
Comment #6
(not verified) commented