Results 1 to 4 of 4

Hybrid View

  1. #1
    Join Date
    Apr 2012
    Posts
    1
    Plugin Contributions
    0

    Default Set maximum order price for Cash On Delivery

    I'm trying to work out how to set a maximum order price for the Cash on Delivery option.
    Our courier service only allows Cash on Delivery for deliveries of up to €500. I do not want this option (COD) to appear on the payment page if the order total is more than €500. How do I do this?

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Set maximum order price for Cash On Delivery

    You can customize the file:
    /includes/modules/payment/cod.php with the code in Red:

    Code:
          if ((int)MODULE_PAYMENT_COD_ORDER_STATUS_ID > 0) {
            $this->order_status = MODULE_PAYMENT_COD_ORDER_STATUS_ID;
          }
          
          // bof: disable on total > 500 is subtotal use subtotal
          if (!IS_ADMIN_FLAG) {
           if ($order->info['total'] > 500) {
             $this->enabled = false;
            }
          }
          // eof: disable on total > 500 is subtotal use subtotal
    
          if (is_object($order)) $this->update_status();
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Jan 2010
    Location
    France
    Posts
    291
    Plugin Contributions
    0

    Default Re: Set maximum order price for Cash On Delivery

    thanks and what I wanted and works with version 1.5.1

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Set maximum order price for Cash On Delivery

    Thanks for the update that this is working for you ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

 

 

Similar Threads

  1. v151 cash on delivery depend of price
    By josecaparros in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 8 May 2013, 09:42 AM
  2. v151 cash on delivery depend of price
    By josecaparros in forum Addon Payment Modules
    Replies: 0
    Last Post: 22 Apr 2013, 10:16 AM
  3. Cash on delivery for selected customers only
    By tojo_d in forum Managing Customers and Orders
    Replies: 1
    Last Post: 15 May 2006, 03:54 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg