Restrict Access Logic Seems Buggy/Backwards with Certain User Profile Fields

Restrict Access Logic Seems Buggy/Backwards with Certain User Profile Fields

by Becka M -
Number of replies: 1

Background Material/Info:

  • I'm using Moodle v. 2.8.10

  • The group I'm working with is a non-profit, and charges no tuition fees for schooling.  All we charge is a small fee to help maintain the Moodle system we run.  Whether or not that fee is paid is up to the individual student, and has no affect on access to school materials or classes.

  • User Profile Fields: (Both are Dropdown Menus)

    • Admin Fee Agreement 
      • Options: "Yes" or "No" (Default is No.)
      • This field can be changed by the user, and indicates the student has read and agreed to the Fee Policy (explained on a separate page.)
      • May periodically (no more than 1 time per month) get reset so the user must review and reaccept the policy (in case of policy updates, for example.)

    • Admin Fee Waiver
      • This field, only changeable by admin, indicates whether or not the student has submitted a Fee Waiver Form (a form which is separate from the Moodle system), and whether or not the form was accepted.
      • Options:  (Bold is default)
        • N/A
        • Accepted (Exempt)
        • Denied
        • Automatically Exempt (Policy Version 2015.01.01)
        • Student Has Not Applied


Scenario:

I'm trying to create a label that reminds students to keep their Admin Fee up-to-date. It should appear under one of two conditions:

  1. Admin Fee Agreement is set to "No"
  2. Admin Fee Waiver is set to something other than "Accepted (Exempt)" or "Automatically Exempt ...."

You either see it, or you don't, no "visible but greyed out" stuff -- that will only confuse our students. So, the "eye" must be crossed out. It seems simple enough to set up, but I keep running into a problem with the interaction between Admin Fee Waiver and Restrict Access.


Problem:

Jane Tutorial's Admin Fee Waiver is set to "Student Has Not Applied."


What I expect to happen is that the label should show up if:

  • Student [must] match the following: User profile field [Admin Fee Waiver] [doesn't contain] [Exempt]
OR if I instead set it to:

  • Student [must not] match the following: User profile field [Admin Fee Waiver] [contains] [Exempt]


BUT IT DOESN'T!  If I change "Jane Tutorial's" Admin Fee Waiver setting to something containing "Exempt"... It doesn't go away either! This makes no sense to me, and I don't understand why the underlying logic seems to be flipped!  It doesn't seem to have that issue when I use "is equal to" ("Yes" or "No") with the Admin Fee Agreement field, though.

This issue is driving me crazy, and I'm quite tech-savvy; but I feel like it's such a noob thing to not be able to get this! mixed  Is my brain fried and in need of a break, or is this an actual bug in the programming?


Average of ratings: -
In reply to Becka M

Re: Restrict Access Logic Seems Buggy/Backwards with Certain User Profile Fields

by John Provasnik -
Picture of Particularly helpful Moodlers Picture of Testers

A screenshot of how you have set it up would be very useful, to see the restriction sets you've created.