Hi,
We have on our website several customers assigned to two Shopper groups, and we need to disable some payment method if a shopper have a particular group assigned.
By default we can only assign payment method to shopper groups, but it's not working since these customes have at least one group allowing it.
Is there a way to do this ?
Thanks,
Cam
It is working as designed.
You have:- Shoppers, Shopper groups, Payment methods.
Shopper --> shopper group/s
Payment method --> shopper group/s
You need to give more detail - but here is an example
I have a payment method that is only available for a particular group of people
So I do the following.
Create a shopper group - "Cash on delivery shoppers"
Create a "dummy payment shopper group - "Cash on delivery group"
Limit the new payment method to the --> "Cash on delivery shoppers"
Assign the shopper group to the shoppers that are allowed to pay "cash on delivery"
Shopper --> assigned to --> "Cash on delivery shoppers" -->> they get the payment method "cash on delivery"
More informations on our groups :
Currently we have 2 main shoppers groups :
- "With VAT"
- "Withou VAT"
These groups are managed with EU VAT CHECKER who automatically move a shopper in one of these groups depending of his country and/or his VAT number, each time a shopper update his personnal informations.
We have several others shoppers group :
- "Distributor 5%"
- "Distributor 10%"
- etc ...
These groups are assigned manually to a shopper, they should have the following effect :
- x% discount on all products (done with a price rule)
- Access only to quote as Payment method (invoice and payment are handled with a SAP software)
here the possible combination :
- "With VAT"
- "Withou VAT"
- "With VAT" + "Distributor x%"
- "Withou VAT" + "Distributor x%"
By default, a shopper is in the group "With VAT".
I can't really touch the main Shopper groups, since they are handled with a specific plugin.
I would like to avoid manual assignment of shoppers group, the current website have a database of 25.000 Shoppers.
Thanks for the additional information.
You may require some bespoke coding for your requirement.
Would you know the function or the class who's managing the available payment method for the current users ?
I've taken a look in my template files, but the variables used return only formated HTML, nothing i could filter.
Thanks.
The list of payment plugin methods is determined by this:-
\administrator\components\com_virtuemart\plugins\vmpsplugin.php
protected function getPluginMethods
The table - _virtuemart_paymentmethod_shoppergroups
Determines for which shopper groups a payment method is valid. If no entries in this table - then it is valid for all groups
Thanks i'll take a look.