- Posts: 79
- Thank you received: 0
how to disable shop function *after* order?
-- Joomla version -- : 3.4.3
-- PHP version -- : 5.5.23
Hi,
i have a webshop for invitees only. My shoppers are already registred (by import) and allowed to shop only once. So, i need to disable the access to the shop after they haved shopped.
Perhaps by changing the acl groups after the last step of the checkout process?
for instance by removing the shopper from the shopper group and placing the shopper in the group "has-already-shopped".
Would this be possible?
Please Log in or Create an account to join the conversation.
You can use the plugin "user group after purchase".
You can also use the HikaShop limitation system to create a general limitation.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Please Log in or Create an account to join the conversation.
is this a hikashop plugin or a third party plugin?
and what do you mean with the limitation system?
Please Log in or Create an account to join the conversation.
If you mean the hikashop plugin, how would i *remove* a user from group? I seem to be only able to add the user to a new group?
And... when would this action (group change) take place, after checkout? (otherwise it wouldn't work of course)
Please Log in or Create an account to join the conversation.
I think the best would be to create a mass action via the menu System>Mass actions.
There, you can configure a mass action like that:
take.ms/H2T5Q
So you could move the user from his user group to another user group, and then configure your shop menu items' access to only the former user group. The rest would then be automatic.
Please Log in or Create an account to join the conversation.
i've just tried this out.
The 'adding to a group' is working properly --> i've placed the user in a "has shopped" group. so, that is fine.
but 'removing' from a group isn't working properly. I need to remove the 'shopper' group but keep all other groups intact. What it actually did, it removed all groups except shopper.
How do i remove a single group (only shopper) and leave the other groups intact? (my users are in different groups)
Please Log in or Create an account to join the conversation.
This action was not implemented. We could only add a user group or replace all the groups by another one.
But I just added this feature, so please install these plugins on your website and enjoy
Please log in or register to see it.
Please log in or register to see it.
Please Log in or Create an account to join the conversation.
So, all groups were removed (shopper and such) the only group left was a registered group.
In my configuration, all webshop functionality is only available for group "shopper".
But... the user (who is no longer in 'shopper') can still access the webshop! Only if he logs out and in again, the rights are changed.
So, how do i force that the change in acl really takes place?
Please Log in or Create an account to join the conversation.
This version of the plugin will delete the user session and log him out in order to force the use of the new groups and so the new ACLs.
Please log in or register to see it.
Please Log in or Create an account to join the conversation.
I've been testen with the 3 new plugins:
plg_hikashop_massaction_user.zip
plg_system_hikashopmassaction.zip
plg_hikashop_massaction_user_2015-11-09
What happens,
1) the massaction is performed, so the condition and filter is working
2) it is adding the new group "reeds geshopt"
3) it should remove groups but it is not doing that. It is actually *adding* the groups it should remove
4) it's not logging out the user. The user can actually shop again (my shop is for registered only)
Please Log in or Create an account to join the conversation.
the biggest issue is that the auto-logout doesn't work after the order.
It stops at the END step of the checkout process and doesn't logout the user. It would be ideal if the system would pauze 2-3 seconds at the END step, then Logout and then switch to a final good-bye page.
So, this part of your last php isn't doing anything:
if(!$app->isAdmin()){
foreach($user_ids as $user_id){
if($user_id != hikashop_loadUser())
continue;
$app->logout( $data->user_cms_id );
}
}
Please Log in or Create an account to join the conversation.
My bad, I gave you the new version of the massaction_user plugin instead of the massaction_order one.
And as you are using an order mass action, that couldn't work as expected.
Here is the new version of the massaction order plugin:
Please log in or register to see it.
Please Log in or Create an account to join the conversation.
it's still not working:
- adding 1 new group = OK
- removing 1 group = NOT OK (it does nothing)
- logout user after order = NOT OK (it does nothing)
Wouldn't you need a "Force user logout on group update" option for the order-plugin like you have for the group-plugin?
Can perhaps one of the other plugins conflict with my order plugin?
regards
Suzanne
Please Log in or Create an account to join the conversation.
The code:
Does the install of the latest plugin has been done correctly ? No errors returned ?
If it is, please provide a backend and a FTP access via our contact form (with a link to that topic).
Please Log in or Create an account to join the conversation.
Shop is non-public and still in maintenance so you can test.
Please Log in or Create an account to join the conversation.
I am not able to log via FTP, please check the sent informations.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
I just tried with the new FTP informations you give, but I have a timeout when trying to reach the FTP.
Don't you have IP restrictions of things like that ?
Please Log in or Create an account to join the conversation.
Encryption-> Only use plain FTP
otherwise same problem
Please Log in or Create an account to join the conversation.
the groups are changed now after the order and status of the order also changed.
But, there is still no forced logout after order.
and I've disabled caching totally (also disabled jotcache)
Please Log in or Create an account to join the conversation.