Page 84 of 85 FirstFirst ... 347482838485 LastLast
Results 831 to 840 of 849
  1. #831
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,145
    Plugin Contributions
    11

    Default Re: Quantity Discounts for 1.3

    1.5.7
    PHP 7.3.21
    MySQL 5.7.31
    OPC
    News Box Manager
    Sitemap XML
    Quick Updates
    Edit Orders

    Base Item Price =$5 Looking to have the following for the category so that the discount is for any Suncatcher (ID #27)
    Attachment 19151

    In ot_quantity_discount.php, set to
    Code:
       // Add categories with special discounting policies to this list.   // Note that 99999, 99998 and 99997 are just given as examples.
       // Note that the Discounting Units you specified in Admin
       // (percentage, currency, currency/item) are also used here.
       function apply_special_category_discount($category, $count, &$disc_amount) {
          switch ($category) {
             case 27:
                if ($count > 2) {
                   $disc_amount = 4.5000;
                }
                if ($count > 5) {
                   $disc_amount = 4.2500;
                }
                if ($count > 8) {
                   $disc_amount = 4.0000;
                }
                break;
          }
       }
    Settings in admin are
    Attachment 19152

    Discounts do not appear.

    Could it be that I have all items by theme using the multilink?

  2. #832
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,684
    Plugin Contributions
    123

    Default Re: Quantity Discounts for 1.3

    When you say "discounts do not appear" you mean they don't show up on the checkout payment page?
    If so, the issue is that the products in question do not have a master category id of 27. Check your database.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  3. #833
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,145
    Plugin Contributions
    11

    Default Re: Quantity Discounts for 1.3

    All items are master ID 27

    I see now that the discount is showing (incorrectly) at checkout. I was hoping it would give the chart as shown in the first image rather than wait to show up at the "last minute".

    Also, the settings do not reflect unit cost. e.g., any combination of suncatchers, $5 base price, add 12 to the cart. I need the price to drop to $4 each. With the current settings, the result is not $4 each but a $4 total discount.

  4. #834
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,684
    Plugin Contributions
    123

    Default Re: Quantity Discounts for 1.3

    The chart you are showing is from the native Quantity Discounts feature, not my Quantity Discounts plugin.

    You can build something similar - look at the help on my site for Quantity Discounts, and search for "Marketing Text." You can also get Discount Preview to show the discount in the cart.

    As for the calculation, you would have to multiply the $count variable by the unit price reduction to get the discount you want.

    if ($count > 8) {
    $disc_amount = 1 * $count;
    }

    etc.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  5. #835
    Join Date
    Apr 2006
    Location
    Ohio
    Posts
    6,162
    Plugin Contributions
    0

    Default Re: Quantity Discounts for 1.3

    Getting the following warning!

    [20-Nov-2020 16:28:05 America/Chicago] PHP Warning: Use of undefined constant MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_TITLE - assumed 'MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_TITLE' (this will throw an Error in a future version of PHP) in /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php on line 89

    [20-Nov-2020 16:28:05 America/Chicago] Request URI: /index.php?main_page=shopping_cart, IP address: 204.95.11.126
    #1 ot_quantity_discount->__construct() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:5]
    #2 include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php) called at [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3 require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php) called at [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4 require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php) called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 16:28:05 America/Chicago] PHP Warning: Use of undefined constant MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_DESCRIPTION - assumed 'MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_DESCRIPTION' (this will throw an Error in a future version of PHP) in /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php on line 90
    [20-Nov-2020 16:28:05 America/Chicago] Request URI: /index.php?main_page=shopping_cart, IP address: 204.95.11.126
    #1 ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]

    [20-Nov-2020 16:28:05 America/Chicago] PHP Warning: Use of undefined constant YOUR_CURRENT_QUANTITY_DISCOUNT - assumed 'YOUR_CURRENT_QUANTITY_DISCOUNT' (this will throw an Error in a future version of PHP) in /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php on line 238
    [20-Nov-2020 16:28:05 America/Chicago] Request URI: /index.php?main_page=shopping_cart, IP address: 204.95.11.126
    #1 ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]

    [20-Nov-2020 16:28:05 America/Chicago] PHP Warning: Use of undefined constant PER_ITEM_OFF - assumed 'PER_ITEM_OFF' (this will throw an Error in a future version of PHP) in /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php on line 345
    [20-Nov-2020 16:28:05 America/Chicago] Request URI: /index.php?main_page=shopping_cart, IP address: 204.95.11.126
    #1 ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]

    [20-Nov-2020 16:28:05 America/Chicago] PHP Warning: Use of undefined constant ITEMS - assumed 'ITEMS' (this will throw an Error in a future version of PHP) in /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php on line 345
    [20-Nov-2020 16:28:05 America/Chicago] Request URI: /index.php?main_page=shopping_cart, IP address: 204.95.11.126
    #1 ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]

    [20-Nov-2020 16:28:05 America/Chicago] PHP Warning: Use of undefined constant TOTAL_DISCOUNT - assumed 'TOTAL_DISCOUNT' (this will throw an Error in a future version of PHP) in /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php on line 352
    Mark
    Hare Do

  6. #836
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,684
    Plugin Contributions
    123

    Default Re: Quantity Discounts for 1.3

    You are running old copies of Quantity Discounts and/or Discount Preview. You need to update both.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  7. #837
    Join Date
    Apr 2006
    Location
    Ohio
    Posts
    6,162
    Plugin Contributions
    0

    Default Re: Quantity Discounts for 1.3

    Quantity Discount: running latest Zen Cart® Versions v1.5.4, v1.5.5, v1.5.6, v1.5.7
    Preview subtotal: Paid module, Version 1.13

    Zen Cart Version: 156c
    PHP Version: 7.2.34 (Zend: 3.2.0)

    Getting the following Warning below:
    PHP Code:
    [20-Nov-2020 23:04:26 America/ChicagoRequest URI: /index.php?main_page=shopping_cartIP address216.177.186.199
    #1  ot_quantity_discount->__construct() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:5]
    #2   include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php)  called at  [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3   require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php)  called at  [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4   require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php)  called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 23:04:26 America/ChicagoPHP Warning:  Use of undefined  constant MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_TITLE assumed  'MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_TITLE' (this will throw an Error  in a future version of PHPin  /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php  on line 89
    [20-Nov-2020 23:04:26 America/ChicagoRequest URI: /index.php?main_page=shopping_cartIP address216.177.186.199
    #1  ot_quantity_discount->__construct() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:5]
    #2   include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php)  called at  [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3   require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php)  called at  [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4   require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php)  called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 23:04:26 America/ChicagoPHP Warning:  Use of undefined  constant MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_DESCRIPTION assumed  'MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_DESCRIPTION' (this will throw an  Error in a future version of PHPin  /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php  on line 90
    [20-Nov-2020 23:04:26 America/ChicagoRequest URI: /index.php?main_page=shopping_cartIP address216.177.186.199
    #1  ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]
    #2   include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php)  called at  [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3   require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php)  called at  [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4   require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php)  called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 23:04:26 America/ChicagoPHP Warning:  Use of undefined  constant YOUR_CURRENT_QUANTITY_DISCOUNT assumed  'YOUR_CURRENT_QUANTITY_DISCOUNT' (this will throw an Error in a future  version of PHPin  /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php  on line 238
    [20-Nov-2020 23:04:26 America/ChicagoRequest URI: /index.php?main_page=shopping_cartIP address216.177.186.199
    #1  ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]
    #2   include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php)  called at  [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3   require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php)  called at  [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4   require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php)  called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 23:04:26 America/ChicagoPHP Warning:  Use of undefined  constant PER_ITEM_OFF assumed 'PER_ITEM_OFF' (this will throw an Error  in a future version of PHPin  /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php  on line 345
    [20-Nov-2020 23:04:26 America/ChicagoRequest URI: /index.php?main_page=shopping_cartIP address216.177.186.199
    #1  ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]
    #2   include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php)  called at  [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3   require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php)  called at  [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4   require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php)  called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 23:04:26 America/ChicagoPHP Warning:  Use of undefined  constant ITEMS assumed 'ITEMS' (this will throw an Error in a future  version of PHPin  /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php  on line 345
    [20-Nov-2020 23:04:26 America/ChicagoRequest URI: /index.php?main_page=shopping_cartIP address216.177.186.199
    #1  ot_quantity_discount->calculate_deductions() called at [/home/haremark/public_html/includes/modules/haredo/inc_qd.php:7]
    #2   include_once(/home/haremark/public_html/includes/modules/haredo/inc_qd.php)  called at  [/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php:175]
    #3   require(/home/haremark/public_html/includes/templates/haredo/templates/tpl_shopping_cart_default.php)  called at  [/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php:171]
    #4   require(/home/haremark/public_html/includes/templates/haredo/common/tpl_main_page.php)  called at [/home/haremark/public_html/index.php:97]

    [20-Nov-2020 23:04:26 America/ChicagoPHP Warning:  Use of undefined  constant TOTAL_DISCOUNT assumed 'TOTAL_DISCOUNT' (this will throw an  Error in a future version of PHPin  /home/haremark/public_html/includes/modules/order_total/ot_quantity_discount.php  on line 352 
    Mark
    Hare Do

  8. #838
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,684
    Plugin Contributions
    123

    Default Re: Quantity Discounts for 1.3

    All those constants are defined in ./includes/languages/english/modules/order_total/ot_quantity_discount.php.
    - have you changed this file?
    - have you created a new language and not copied in an updated version of this file?
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  9. #839
    Join Date
    Apr 2006
    Location
    Ohio
    Posts
    6,162
    Plugin Contributions
    0

    Default Re: Quantity Discounts for 1.3

    Thank you Scott,

    The preview_subtotal was the FIX !!

    Mark
    Mark
    Hare Do

  10. #840
    Join Date
    Aug 2006
    Location
    North Carolina
    Posts
    279
    Plugin Contributions
    0

    Default Re: Quantity Discounts for 1.3

    Hi Scott,

    I have these errors in 157 using your updated plugin code and also after I compare the modifications for my site.
    Can you help?

    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined offset: 68 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 207
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined offset: 68 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 208
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined index: 11001649:caff8fa231126a9775e9fcbad8c09ab1 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 212
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined index: 11001649:caff8fa231126a9775e9fcbad8c09ab1 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 213
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined variable: ccnum in /Users/macminiserver/Sites/websites/MC2020/includes/modules/payment/paypaldp.php on line 330
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined variable: ccnum in /Users/macminiserver/Sites/websites/MC2020/includes/modules/payment/paypaldp.php on line 330
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined offset: 68 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 207
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined offset: 68 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 208
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined index: 11001649:caff8fa231126a9775e9fcbad8c09ab1 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 212
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined index: 11001649:caff8fa231126a9775e9fcbad8c09ab1 in /Users/macminiserver/Sites/websites/MC2020/includes/modules/order_total/ot_quantity_discount.php on line 213
    [01-Dec-2020 09:42:06 America/New_York] PHP Notice: Undefined variable: ccnum in /Users/macminiserver/Sites/websites/MC2020/includes/modules/payment/paypaldp.php on line 330
    Jeff Michaels,
    pres of Musical Creations Ltd.

 

 
Page 84 of 85 FirstFirst ... 347482838485 LastLast

Similar Threads

  1. v153 quantity discounts for attributes
    By delia in forum General Questions
    Replies: 1
    Last Post: 14 Oct 2014, 02:34 PM
  2. v150 Quantity Discounts for shipping 1.5
    By jpmill in forum Built-in Shipping and Payment Modules
    Replies: 7
    Last Post: 7 Apr 2013, 05:28 PM
  3. v150 Quantity Discounts for 1.5?
    By mobishelf in forum All Other Contributions/Addons
    Replies: 2
    Last Post: 21 Feb 2012, 12:40 AM
  4. Hide quantity discounts for general customers, show for groups only?
    By swamyg1 in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 3
    Last Post: 16 Nov 2009, 09:22 PM
  5. Quantity Discounts for Sets?
    By mwlahn in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 1
    Last Post: 30 Mar 2008, 07:39 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