Magento Forum

   
Can Magento restrict payment method to certain people? 
 
Fearghal
Jr. Member
 
Total Posts:  8
Joined:  2012-07-29
 

Basically I want to use the cheque / money order payment method to put through offline sales however I only want an administrator to be able to do this.

So far the only way I am able to do this is by overriding the original price to 0.00 so that the order goes through for free and then I just comment on the order.

Is it possible to use the money payment method only if logged in as an admin?

Thanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
iKantam_
Sr. Member
 
Avatar
Total Posts:  89
Joined:  2012-05-20
 

Some premium extension like http://www.magentocommerce.com/magento-connect/payment-restrictions-3940.html should help with this.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Amasty
Mentor
 
Avatar
Total Posts:  3756
Joined:  2009-11-10
 

Hey Fearghal,

Is it possible to use the money payment method only if logged in as an admin?

you can restrict payment method to certain customer groups with an extension like Payment Restrictions. Thus you can restrict payment for every body but admin user. Also there are some other nice features like payment restrictions based on country, state, other shipping data, product and order info.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Jase007
Guru
 
Total Posts:  388
Joined:  2013-11-05
 

Hi,

Two options:

1)Override (using never change the original or add a /local/Mage/ override) the payment method (or just modify it if it\’s your own method), and add this:

protected $_canUseInternal              true;
protected 
$_canUseCheckout              false
protected 
$_canUseForMultishipping      false;

2)Create an observer on the frontend for \"payment_method_is_active\" event, and set to inactive the methods you don\’t want to show on the frontend:

<config>
       <
frontend>
           <
events>
        <
payment_method_is_active>
            <
observers>
                       ... 
your observer here


 
public function your_observer($event){

      $method 
$event->getMethodInstance();
      
$result $event->getResult();

      if( 
$method should not be active in frontend ){

            $result
->isAvailable false;
      
}

 }

Thanks

iLoveMage

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top