Alex Rivera | Logout

magento payment methods - enable for admin only

Asked 2010-01-18T11:30:04.550
9

I need to enable the Cheque / Money Order payment method to enable our clients call centre team to create orders in the admin.

However we do not want customers buying online through the website to use this payment method.

Does anybody know how I might be able to do this?

Regards, Fiona

Edit
Report

1 Answer

14

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;
      }

 }
answered 2012-09-20T15:00:20.400

Your Answer