Page 1 of 4 123 ... LastLast
Results 1 to 10 of 38
  1. #1
    Join Date
    Apr 2007
    Posts
    24
    Plugin Contributions
    0

    Default Is it possible to enable a shipping method for only a certain customer group?

    Hi

    I would like to know if it is possible to enable a shipping method (example store pickup) but only for a certain pricing group or on an individual customer bases?

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

    Default Re: How to enable a shipping method but for only...

    Each shipping module has a setting for the $this->enabled ... when false, that module with hide, or basically not show ...

    If you look at the shipping modules such as Item Rate item you will see:
    Code:
          // disable only when entire cart is free shipping
          if (zen_get_shipping_enabled($this->code)) {
              $this->enabled = ((MODULE_SHIPPING_ITEM_STATUS == 'True') ? true : false);
          }
    This is running a function that returns true or false based on if the shipping is free ...

    You could do something similar by identifying the customer and return true or false if the customer should see the module you need to do this for ...
    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: v1.5.5]
    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
    Sep 2009
    Location
    Victoria
    Posts
    88
    Plugin Contributions
    0

    Default Re: How to enable a shipping method but for only...

    I'm using Zen Cart 1.3.8

    I'm confused.

    I have three customer groups set up. Gold members, VIP and Friends under group pricing.

    I have set up a test customer and enabled them to my friends group which has no discount.

    How do I set it up so that only the store pick up will show in their shopping cart when they are signed in and no one else.

    Under that shipping option in admin>modules>shipping I only see the option to remove or edit with the settings:

    Enable store pick up : true
    Shipping cost: 0.00
    Tax Class: none
    Tax basis: shipping
    Shipping Zone: none
    Sort order: 6

    How exactly do I set it so that it is only made true to the customers I select and false to every one else?

    Is there something I'm missing?

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

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    You would have to customize the shipping module code ... it is not built in to work off customer group settings ...
    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: v1.5.5]
    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!

  5. #5
    Join Date
    Sep 2009
    Location
    Victoria
    Posts
    88
    Plugin Contributions
    0

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    Quote Originally Posted by Ajeh View Post
    You would have to customize the shipping module code
    Any ideas on how I would do this.

    I'm not real good at coding.

    I wouldn't know where to start or which files to customize.

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

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    Can the Friends Group see all off the other shipping modules plus the Store Pickup?

    What is the customers_group_pricing for the Friends Group?
    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: v1.5.5]
    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!

  7. #7
    Join Date
    Sep 2009
    Location
    Victoria
    Posts
    88
    Plugin Contributions
    0

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    Quote Originally Posted by Ajeh View Post
    Can the Friends Group see all off the other shipping modules plus the Store Pickup?
    Yes. My test customer that I have linked to my friends group can.

    Quote Originally Posted by Ajeh View Post
    What is the customers_group_pricing for the Friends Group?
    Group Name: Friends
    Discount: 0.00%

    These are the only 2 options under group pricing (admin>customers>group pricing) and my answers are shown above.

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

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    Let me try the questions in a different way ...

    When you go to the Catalog ... Group Pricing ... you will see, if you click on the Friends group ... in the URL ... the:
    gID=

    What is the number after it?

    IF a customer is in the Friends Group ... *should* they be able to see all of the regular shipping methods *and* be able to see the Store Pick Up in *addition* to all of the other *regular* shipping methods?
    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: v1.5.5]
    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!

  9. #9
    Join Date
    Sep 2009
    Location
    Victoria
    Posts
    88
    Plugin Contributions
    0

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    Quote Originally Posted by Ajeh View Post
    Let me try the questions in a different way ...

    When you go to the Catalog ... Group Pricing ... you will see, if you click on the Friends group ... in the URL ... the:
    gID=

    What is the number after it?
    I'm assuming you mean admin>customers>group pricing. The ID number to the far left. If that is the case then it is 3.

    If that's not where you meant I did look under admin>catalog but there is no listing for group pricing there.

    Quote Originally Posted by Ajeh View Post
    IF a customer is in the Friends Group ... *should* they be able to see all of the regular shipping methods *and* be able to see the Store Pick Up in *addition* to all of the other *regular* shipping methods?
    I want my friends to be able to see all delivery options.

    But want to make the store pick up option only available / visible to them and not the general public.

    I hope I'm making sense.

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

    Default Re: Is it possible to enable a shipping method for only a certain customer group?

    You can customize the Store Pickup storepickup shipping module with the code changes:
    Code:
        if ( ($this->enabled == true) && ((int)MODULE_SHIPPING_STOREPICKUP_ZONE > 0) ) {
          $check_flag = false;
          $check = $db->Execute("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . "
                                 where geo_zone_id = '" . MODULE_SHIPPING_STOREPICKUP_ZONE . "'
                                 and zone_country_id = '" . $order->delivery['country']['id'] . "'
                                 order by zone_id");
          while (!$check->EOF) {
            if ($check->fields['zone_id'] < 1) {
              $check_flag = true;
              break;
            } elseif ($check->fields['zone_id'] == $order->delivery['zone_id']) {
              $check_flag = true;
              break;
            }
            $check->MoveNext();
          }
    
          if ($check_flag == false) {
            $this->enabled = false;
          }
        }
    
        $chk_group = $db->Execute("select customers_group_pricing from " . TABLE_CUSTOMERS . " where customers_id = '" . (int)$_SESSION['customer_id'] . "'");
        if ($chk_group->fields['customers_group_pricing'] == 3) {
          $this->enabled = true;
        } else {
          $this->enabled = false;
        }
      }
      /**
       * Obtain quote from shipping system/calculations
    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: v1.5.5]
    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!

 

 
Page 1 of 4 123 ... LastLast

Similar Threads

  1. Replies: 6
    Last Post: 16 Jul 2015, 04:29 AM
  2. Is it possible to enable free shipping for only a certain customer group?
    By green couch designs in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 19 Apr 2011, 04:35 PM
  3. Store pick up for certain customer or group only
    By Kayz in forum Built-in Shipping and Payment Modules
    Replies: 2
    Last Post: 16 Mar 2010, 10:38 AM
  4. How to enable only one shipping method to some products?
    By hankliu in forum Built-in Shipping and Payment Modules
    Replies: 10
    Last Post: 3 Sep 2009, 06:05 PM
  5. Possible to enable/disable shipping options for certain objects?
    By litepockets in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 19 Sep 2008, 12:03 AM

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR