• Resolved philtreeline

    (@philtreeline)


    I notice in the changelog for this plugin on the 26th April
    Fix: Corrected error causing hidden groups to not be displayed.

    I am sure my site used to work but now I can only see my hidden group when I try to create a new group post. It works fine when logged in as an administrator but for my intranet_user account type I don’t see public or private groups in the drop down list.

    Is there a particular user capability that should be enabled for my intranet_user to allow the public and private groups to show in the group dropdown list as well as the hidden group? Or is this a bug introduced by the previous fix?

    Regards,
    Phil.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Venutius

    (@venutius)

    Hi Phil,

    The fix regarding hidden groups was simply that I was setting the class .hidden to not display. BP uses this class to signify a group as hidden in the groups loop so hidden groups would not be displayed due to my code. There would be not impact other group types.

    What’s your configuration? Are you using BP Post Status with this or is it stand-alone? Also are you using multisite wordpress or single site?

    Thread Starter philtreeline

    (@philtreeline)

    Thank you for coming back to me so quickly.

    I have had the same issue with hidden groups having the class .hidden so I can see why that would not have stopped all non hidden groups from showing up. If I inspect the drop down code the public and private groups are not there at all so it is not a CSS issue. Since the correct groups do show for admin accounts I was assuming it was some kind of privilege thing.

    However I have just inspected the HTML for a member who is not in the hidden group and so the drop down is empty and the code shows the following within the <select></select>

    Warning: Invalid argument supplied for foreach() in /home/sites/3b/……../public_html/wp-content/plugins/bp-site-post/views/display.php on line 492.

    Yes, I am using the BP Post Status plugin alongside the BP Site Post plugin. WordPress is single site.

    Regards,
    Phil

    Plugin Author Venutius

    (@venutius)

    Thanks for letting me know that one. It’s doing that because it does not think the user is a member of any groups. that are allowing group posts. would that be the case in this instance?

    Plugin Author Venutius

    (@venutius)

    I think I’ve found the issue. Your members who can’t see groups in Site Post do not have ‘edit_posts’ capability – they are subscribers, from my tests any user with edit_posts can see the groups they are members of.

    Now the plugin does have a setting to allow any member to post, however it seems I never added the code needed to make that work for groups, follow, friends etc.

    I’ll get on it and get it working, shouldn’t take too long.

    Plugin Author Venutius

    (@venutius)

    Ok there’s a new version for you to try. I’m not sure if it will fix your problem as in my tests I was not getting that error, but this now allows users without edit_posts rights to create group posts.

    However your error was a bit more specific that that, users were only seeing hidden groups. so I’m not hopeful that this will fix it. Problem is I can’t replicate it, I’m seeing private, hidden and public groups in the drop down list.

    Thread Starter philtreeline

    (@philtreeline)

    Hi Venutius,

    I have installed the update and tested again. I’m afraid it did not help.

    I have done some more testing of the problem and can give you a little more details.

    1. My intranet_user does have edit_posts.

    2. I logged in as “admin” (administrator). I went to my member menu and opened groups then memberships. It showed I was a member of the following groups: External (public), Legal (private), Development (private). I then went into the external group clicked group posts, clicked add post, changed the publish type to “group post pending” and the group drop down option appeared below. The drop down contained only legal and development. The external group was missing from this list. I tried doing the same in the legal group and the options were the same, external was still missing.

    3. I switched user to “stuart” (administrator). I went to memberships and could see Stuart is a member of the following groups: External, Staff (private), Board (hidden). I went to add a post, selected group post pending and the drop down had all 3 groups so it was working correctly for the Stuart account.

    4. I switched user to “philg” (intranet_user). I looked at his memberships to see he is a member of external, board and staff (same as Stuart). I then attempted to add a new post and the group drop down only shows the hidden board group.

    5. I switched user to “amy” (intranet_user). I looked at her memberships to see she is only in the external group. I tried to add a post and her drop down groups list is empty.

    So it does not appear to me that the problem is related to user capabilities or roles or groups as for Stuart all groups appear fine. It also makes no difference which group I try to post 2 the same groups are always missing for the same members but they are not always the same groups missing.

    You can log into https://intranet.herjustice.com/ with the admin account password same as username. Switch user plugin is installed so you can bounce between users if you want to test it out. I think probably only the users above are already in groups. If you want to add other users to other groups and see how that changes things you can but please let me know which accounts you have modified.

    Thanks again for you help with this.

    Best regards,
    Phil

    Plugin Author Venutius

    (@venutius)

    Hi there Phil,

    Looking at the External Group, it’s set so that only a group administrator can post to the group. So only that groups admin would get that group in the new post form. Currently that excludes site admin who are not admin of that group. Thinking about changing this rule so that it would allow site and group admin to post.

    Thread Starter philtreeline

    (@philtreeline)

    That is correct, the external group is public so the idea was that only the admin could post there so it does make perfect sense that the other users could not see that however if that is the case would it be possible to remove the “Add post” button for them too as that makes it look like they are able to add a post?

    I guess on that topic I also find it confusing that I can post to other groups at all as I would not go into the external group to post to the board group?

    This explains my issue as the staff group is also moderator only to post which is why only the Stuart user could see the staff group in the list.

    Perhaps I can just find some classes that identify the specific group and user level which I can use to hide the Add post button using CSS.

    Many thanks for you help with this.

    Regards,
    Phil

    Plugin Author Venutius

    (@venutius)

    Yep I can do that, should be able to later today.

    Plugin Author Venutius

    (@venutius)

    OK I’ve done that, new version coming

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Only hidden groups showing’ is closed to new replies.