Will secondary group "no memberlist" be overridden by primary?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • RobFerrari
    Senior Member
    • Feb 2003
    • 774

    Will secondary group "no memberlist" be overridden by primary?

    User with secondary group that has show on memberlist turned off is showing up on the memberlist when I look and when they look. Is that because...

    1) Primary permission overrides secondary?

    2) A user can always find themselves?

    3) As admin I can find anyone?

    Thanks,
    rob
  • RobFerrari
    Senior Member
    • Feb 2003
    • 774

    #2
    I just confirmed with a test account that you can still find these users on the memberlist even though their secondary account is set to "don't show on memberlist".

    Maybe not a bug, but this is unacceptable. How to you set this so these secondary usergroup permissions override the primary?

    Should happen list this anyway. These users get access to the extra forum for this secondary group with no problem.

    Comment

    • Steve Machol
      Former Customer Support Manager
      • Jul 2000
      • 154488

      #3
      There is currently no function to do this. This requires modifying the code. You can try searching or asking for help with this over at www.vbulletin.org.
      Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
      Change CKEditor Colors to Match Style (for 4.1.4 and above)

      Steve Machol Photography


      Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


      Comment

      • RobFerrari
        Senior Member
        • Feb 2003
        • 774

        #4
        Originally posted by Steve Machol
        There is currently no function to do this. This requires modifying the code. You can try searching or asking for help with this over at www.vbulletin.org.
        How in the heck do the secondary permissions work at all or why have them? Some override Primary, but some don't? Please explain how this all works.

        Thanks.

        Comment

        • RobFerrari
          Senior Member
          • Feb 2003
          • 774

          #5
          What good does this usergroup option do?...

          "Allow Users to have Member Groups
          (Sets whether or not permissions from the user's member (secondary) user group memberships are inherited or not)"

          Comment

          • Steve Machol
            Former Customer Support Manager
            • Jul 2000
            • 154488

            #6
            When a user is in multiple groups, a 'yes' permission will always override a 'no' permission.
            Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
            Change CKEditor Colors to Match Style (for 4.1.4 and above)

            Steve Machol Photography


            Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


            Comment

            • RobFerrari
              Senior Member
              • Feb 2003
              • 774

              #7
              Originally posted by Steve Machol
              When a user is in multiple groups, a 'yes' permission will always override a 'no' permission.
              So if a user has multiple groups, the final permissions are set by looking at all groups and taking the "yes" no matter if primary or secondary?

              Hmm, interesting dilemma, but I guess this is a rare case where the secondary group is actually taking something away, instead of adding it.

              Comment

              • Steve Machol
                Former Customer Support Manager
                • Jul 2000
                • 154488

                #8
                Correct. A 'yes' permission overrides a 'no' permission.
                Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
                Change CKEditor Colors to Match Style (for 4.1.4 and above)

                Steve Machol Photography


                Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


                Comment

                • Farcaster
                  New Member
                  • Dec 2005
                  • 28
                  • 3.6.x

                  #9
                  A Suggestion Regarding the Schema

                  I encountered this same problem trying to setup a particular permissions scheme. After looking at the code, I have a suggestion. The problem exists because of the way secondary user groups are stored.

                  The problem is here in this WHERE clause of the SQL query that returns members who should be visible on the memberlist:
                  Code:
                  WHERE $condition AND user.usergroupid IN ($ids)
                  This is only checking the primary user group. The problem is that there is no intermediary table of user IDs to secondary groups, so there is no clean way to check the secondary user groups for a user on the SQL server side. You could bring it out into an array in PHP, but then you wouldn't be able to take advantage of the SQL server row processing, which could be a problem on larger boards. This could be far easier implemented if a "user_memberships" table existed to be joined. Thus the above statement could be rewritten to:

                  Code:
                  WHERE $condition AND user.usergroupid IN ($ids)
                  AND EXISTS (
                       SELECT * FROM user_memberships AS um
                       WHERE  um.userid = user.userid
                                  AND um.usergroupid IN ($ids))

                  Comment

                  widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                  Working...