Notice

The forum is in read only mode.

Support Forum

Welcome! Support Forums have been reactivated
Welcome the Technical Support section. Help us in assisting you by providing us with a concise and descriptive elaboration of your issues. Be specific and if possible, provide us with a step-by-step instruction in replicating your problem.

JomSocial menu broken with JS 3.1.1

10 years 2 months ago
  • nrichard's Avatar
    Topic Author
  • nrichard
  • Visitor
  • Thank you received: 0
Licenses:

Hello,

After upgrading to JS 3.1.1, one of my menu entries in JomSocial menu has disappeared...

Just to show you, I have set jomsocialmenu as the template menu, and the "Abonnement aux Newsletters" menu correctly appears in it. But it does not appear in JomSocial menu. It worked perfectly in JS 3.1.0.4.

Attachment menuBug.png not found



Note that this menu item access is set to a custom Joomla user group (inheriting from Registered group). When I set this menu item access to Registered, it works.

Please help ;-)

Attachments:
10 years 2 months ago
  • David's Avatar
  • David
  • Visitor
  • Thank you received: 0
Licenses:

Hi nrichard,

i have been logged in into your website and i can't replicate your error.. i found everythings in that menu appears and work fine :)
you can see my attachment below.. i logged in on " dev2.xxxxxx.asso.fr/administrator " as backend and " www.dev2.xxxxxx.asso.fr " as frontend..

let me know if i missed something or access wrong url :)

Attachment worksFine.png not found



Warm Regards

David

Attachments:
10 years 2 months ago
  • nrichard's Avatar
    Topic Author
  • nrichard
  • Visitor
  • Thank you received: 0
Licenses:

Hello,

You should login with a user in the "Adhérent" user group only. I've set one for you (username adherent, same password as for the super user account I gave you).
This menu item is set with access to this group (though the "Adhérent" level access).

10 years 2 months ago
  • David's Avatar
  • David
  • Visitor
  • Thank you received: 0
Licenses:

Hi nrichard,

i will inspect this now but maybe take some time because i can't change your frontend language into english :(

Warm Regards,

David

10 years 2 months ago
  • David's Avatar
  • David
  • Visitor
  • Thank you received: 0
Licenses:

Hi nrichard,

this is because some access level from user manager.. i have been fixed it.. please check again and if this issue still persist please let me know..

Warm Regards,

David

10 years 2 months ago
  • nrichard's Avatar
    Topic Author
  • nrichard
  • Visitor
  • Thank you received: 0
Licenses:

I'm sorry, this does not fix it. And this was quite a mess, I had to revert your changes.

Please consider that:
- "Abonnement aux Newsletters" menu item in jomsocialmenu is set with "Adhérent" access level
- "Adhérent" access level is granted to "Adhérent" user group (among other groups)
- adherent user belongs to "Adhérent" group

Therefore adherent user should see this menu item. He does'nt in JomSocial menu (toolbar). But he does in the template menu (when the template is configured to use jomsocialmenu).

To reproduce:
- Go to www.dev2.xxxxxx.asso.fr/index.php?option...ew=profile&Itemid=77
- Log in with adherent user (password given previously)
- Check the "Mon profil" drop down menu in the template menu: "Abonnement aux Newsletters" menu item is present
- Check the "Mon profil" drop down menu in the JomSocial toolbar: "Abonnement aux Newsletters" menu item is missing

For me there is nothing to change in the configuration. This is just a JomSocial toolbar bug. Please escalate this ticket if necessary.

Thank you!

10 years 2 months ago
Licenses:

Hi nrichard,

could you please provide me the FTP access detail? (by editing this Topic)
I need to put static/hack PHP code for your new user access level "Adhérent" at Jomsocial toolbar library.
because currently Jomsocial toolbar still not support ACL yet.

Cheers,
Albert

10 years 2 months ago
  • nrichard's Avatar
    Topic Author
  • nrichard
  • Visitor
  • Thank you received: 0
Licenses:

Done, on 1st message. Please let me know exactly what you did (which files you modified) afterwards. Thanks!

10 years 2 months ago
Licenses:

Hi nrichard,

Done, pls check it. I made changes at /components/com_community/models/toolbar.php

Line 55, before:
$query	.= ' AND a.' . $db->quoteName( 'access' ) . '<' . $db->Quote( 3 ) ;
Line 55, after:
jimport( 'joomla.access.access' );
$AccessGroups = JAccess::getGroupsByUser($my->id);

$adherent = false;
foreach ($AccessGroups AS $AccessGroup) {
    if ($AccessGroup == 10) {
        $adherent = true;
    }
}

if ($adherent == false) $query  .= ' AND a.' . $db->quoteName( 'access' ) . '<' . $db->Quote( 3 ) ;
else $query .= ' AND (a.' . $db->quoteName( 'access' ) . '<' . $db->Quote( 3 ) . ' OR a.' . $db->quoteName( 'access' ) . '= 5) ' ;

That code mean: get user access group, if access group = adherent (the ID = 10) then include menu with access level adherent too (the ID = 5)
becuase by default Jomsocial toolbar only take menu with access level < 3.

Cheers,
Albert

The following user(s) said Thank You: nrichard
10 years 2 months ago
  • nrichard's Avatar
    Topic Author
  • nrichard
  • Visitor
  • Thank you received: 0
Licenses:

I see. And there was indeed a modification in toolbar.php between 3.1.0 and 3.1.1 wich explains why I did not have the problem in 3.1.0:

55c55
< 			$query	.= ' AND a.' . $db->quoteName( 'access' ) . '>=' . $db->Quote( 0 ) ;
---
> 			$query	.= ' AND a.' . $db->quoteName( 'access' ) . '<' . $db->Quote( 3 ) ;

But I was wrong in saying that it did work perfectly well in 3.1.0: my adherent user was seeing the menu correctly, but all my registered users also did...

Is there any plan for JomSocial toolbar to fully support ACL?

10 years 2 months ago
Licenses:

Hi nrichard,

if using ">=" you are correct. that will make are user can see the menu items. so for now we using "< 3". rightnow we still develop our toolbar code to support fully ACL, it will coming soon.

Regards.
Albert

Moderators: Piotr Garasiński
Powered by Kunena Forum

Join 180,000 websites creating Amazing communities

JomSocial is the most complete, easy-to-use addon that turns Joomla CMS into a
full -fledged, social networking site

TRY NOW BUY NOW