Skip to Content Skip to Menu

Auto Actions & Group/ACL Permissions in Frontend

  • GUEST
12 years 2 months ago #208460 by
Following Scenario:
  • Auto Actions changes Group of User under certain conditions when profile is updated by user from frontend.
  • The new group has different permissions regarding visible content in frontend, of course.
  • These changes seem to need logout & login of user in order to take effect, otherwise OLD group permissions persist.

How is it possible to avoid this logout/login?

BTW, we tried to create a auto-logout by redirecting user with auto actions to the CB logout link - is somehow works, but is undesireable to 'throw-out' users everytime.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48444
  • Thanks: 8279
  • Karma: 1443
12 years 2 months ago #208477 by krileon
Known issue fixed for next release. Quick fix as follows (assumes you're using latest!).

IN: components/com_comprofiler/plugin/user/plug_cbautoactions/models/usergroup.php
ON: Line 45, 65, 86, and 114
FROM:
Code:
$session->set( 'user', new JUser( $user->id ) );
TO:
Code:
JAccess::clearStatics(); $session->set( 'user', new JUser( $user->id ) );


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • GUEST
12 years 2 months ago #208491 by
Thanks, changed the file, see below - but it did not work, so far.

Please Log in or Create an account to join the conversation.

  • GUEST
12 years 2 months ago - 12 years 2 months ago #208492 by
file

[MOD EDIT]: File removed, please don't post subscriber content..
Last edit: 12 years 2 months ago by krileon.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48444
  • Thanks: 8279
  • Karma: 1443
12 years 2 months ago #208503 by krileon
Don't know what to tell you. That's the Joomla API to do it. It only works if the person triggering the profile update or registration is the person being edited. For example it won't update the session of a user if it's a moderator editing the user.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum