payment type for customer roles

Posted: March 24, 2010 at 7:54 AM Quote #13240
Is it possible to filter the payment method based on role? Or is there another solution for my problem?

I have 2 roles. Internal & External

Internal has Purchase Order payment method only
External has Worldpay only.

Can I filter?

Also, need 1 set of pricing for internal and one for external?
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: April 04, 2010 at 8:02 PM Quote #14631
sure this can be done.

just add some if clause in the checking out page.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
fter a nop theme? pm me for a quote.
Website: www.osshop.biz
Ajax template v1.9.1: http://13dects191.noptemplate.com/
Posted: May 18, 2010 at 10:44 AM Quote #17668
To the developers - is this something you'd consider adding as an official feature?

I demoed NopCommerce to my bosses today and they were very impressed, so much so that they wondered if we could use it not just for a public store but for taking orders from our resellers. Resellers need to pay by purchase order, general customers don't. If we could filter the payment providers by role that would be great.

I know I can hack this into my own copy with some conditional code but it seems like a very useful feature to me and I want to avoid making too many changes from the official files so as to smooth the upgrade path.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Stephen Kennedy
Gloucester Software Ltd.
All opinions stated and advice given are my own and do not represent the views of my employer.
Posted: November 15, 2010 at 2:26 PM Quote #29986
kingboyk wrote:
To the developers - is this something you'd consider adding as an official feature?

I demoed NopCommerce to my bosses today and they were very impressed, so much so that they wondered if we could use it not just for a public store but for taking orders from our resellers. Resellers need to pay by purchase order, general customers don't. If we could filter the payment providers by role that would be great.

I know I can hack this into my own copy with some conditional code but it seems like a very useful feature to me and I want to avoid making too many changes from the official files so as to smooth the upgrade path.


+1

It will a be great feature.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: November 16, 2010 at 12:39 PM Quote #30087
Here is my solution ;)

(1) In \NopCommerceStore\Modules\CheckoutPaymentMethod.ascx.cs  (~ Line 162)

(2) Search for :

bool hasButtonMethods = false;
var boundPaymentMethods = new List<PaymentMethod>();
var paymentMethods = PaymentMethodManager.GetAllPaymentMethods(filterByCountryId);


(3) Add your filter conditions (something like)

var filterPm = PaymentMethodManager.GetPaymentMethodById(25); // Filtred Payment method ID
if (!Page.User.IsInRole("User role to filter")) // Name of the role to filter
{  
    paymentMethods.Remove(filterPm);        
}


(4) Compile and Run ;)

I'm working on something like the filter by country in the admin. To be more useful and less hard code ;) comming soon.
This post/answer is useful
1
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: February 16, 2014 at 6:18 PM Quote #116376
any new updates on this, just ran into it and need this. Thanks
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Evelio Gonzalez
Suncity Marketing Group Inc.
www.suncitymarketinggroup.com
http://www.facebook.com/SunCityMGroup
Posted: February 16, 2014 at 6:18 PM Quote #116377
any new updates on this, just ran into it and need this. Thanks
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Evelio Gonzalez
Suncity Marketing Group Inc.
www.suncitymarketinggroup.com
http://www.facebook.com/SunCityMGroup
Posted: February 16, 2014 at 8:35 PM Quote #116380
If you need it now, Payment Director has Conditional payment methods
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
www.noptools.com
Posted: April 02, 2014 at 10:52 AM Quote #119572
That's feasible!
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
nopCommerce on facebook