Zen Cart Logo
If this is your first visit, check our documentation. To post, register or login.
Forums / Configuring the Zen Cart Admin / Built-in Shipping and Payment Modules / subtract weight or tare per item in cart

subtract weight or tare per item in cart

Locked
This thread is locked. New replies are disabled.
11 Jun 2009, 1:55 PM
#1
mental_piracy avatar

mental_piracy

New Zenner

Join Date:
Jun 2009
Posts:
11
Plugin Contributions:
0

Post #1 by mental_piracy

is there a way i can change some script to tell zen cart to multiply the tare or negative tare rather, by how many items are in the shopping cart?

11 Jun 2009, 2:22 PM
#2
mental_piracy avatar

mental_piracy

New Zenner

Join Date:
Jun 2009
Posts:
11
Plugin Contributions:
0

Post #2 by mental_piracy

per additional item after the first item,
like 1.5 lbs per item after first.

11 Jun 2009, 3:10 PM
#3
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Post #3 by ajeh

Using the Developers Tool Kit ... do a search on:
SHIPPING_BOX_WEIGHT

This will show you all of the files where the Tare is addressed and you can customize that the way you need it ...

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!

15 Jun 2009, 2:07 PM
#4
mental_piracy avatar

mental_piracy

New Zenner

Join Date:
Jun 2009
Posts:
11
Plugin Contributions:
0

Post #4 by mental_piracy

can anyone give me any idea of the code format i would use for taking off 1.5 lbs per each additional item in shopping cart after the first item?

15 Jun 2009, 2:20 PM
#5
mental_piracy avatar

mental_piracy

New Zenner

Join Date:
Jun 2009
Posts:
11
Plugin Contributions:
0

Post #5 by mental_piracy

maybe multiplying the tare by -1.5?

15 Jun 2009, 6:15 PM
#6
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Post #6 by ajeh

In the shipping.php class the Tare is handled:

      switch (true) {
        // large box add padding
        case(SHIPPING_MAX_WEIGHT <= $shipping_weight):
          $shipping_weight = $shipping_weight + ($shipping_weight*($zc_large_percent/100)) + $zc_large_weight;
          break;
        default:
        // add tare weight < large
          $shipping_weight = $shipping_weight + ($shipping_weight*($zc_tare_percent/100)) + $zc_tare_weight;
          break;
      }

you need to adjust the formula for how the $shipping_weight is managed based on the Tare ...

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!

16 Jun 2009, 6:27 AM
#7
mental_piracy avatar

mental_piracy

New Zenner

Join Date:
Jun 2009
Posts:
11
Plugin Contributions:
0

Post #7 by mental_piracy

well, i'm retarded, all I had to do was set the product weight to 1.5 lbs less, and put in a positive tare weight of 1.5 lbs; I swear I tried that before and it didn't work, oh well, I only lost 3 days worth of work. Se la vi.