Results 1 to 7 of 7
  1. #1
    Join Date
    Oct 2005
    Location
    Connectiuct
    Posts
    70
    Plugin Contributions
    1

    Default Adding forumla into weight field

    The shipping per item is close to what I'm looking for but I desperately need to tweak it and need some collaboration.

    I have a client with per item shipping needs but those include formulas. He wants to do this on the cheap so I'm stuck doing this myself.

    His shipping needs are based on prices per quantities. For example, for one product, for up to 500 widgets, it costs $4 shipping and 501-1000 is $8, etc. I could set up a formula:
    if (qtty < 500) = $4
    if (qtty >500 < 1000) +$8
    etc.

    Other items have different formulas. I tried to change the weight field to text which now will take a formula but it still processes it as the initial number.

    Any suggestions on how to hack the weight field to accept a formula related to the quantity value rather than just using a number?

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

    Default Re: Adding forumla into weight field

    Are all products based this way or do each have their own charges based on qty for shipping?
    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
    Oct 2005
    Location
    Connectiuct
    Posts
    70
    Plugin Contributions
    1

    Default Re: Adding formula into weight field

    Hi Linda. This is the client with vast shipping variation needs <grin>. And, yes, many products have unique formulas. In looking at his existing shopping cart, I realized that in addition to having individual shipping costs per item, it was possible to include formulas into those. If there is a way to do this in ZenCart, that might solve a lot of issues that people have with shipping costs.

    The formulas don't need to be pretty nor understandable to the client. I just need to be able to put something like:

    $3+($4 for each 100 qtty)

    for some products,

    $3+($4 for each 500 qtty)

    for other products, and

    $15 for other products (I can do that one).

    So a variable weight field seemed like a possible solution. Or is there a better solution?

    Thanks. js

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

    Default Re: Adding forumla into weight field

    Oh ... that client ...

    Nasty bit of work on those shipping ideas ...

    You might be able to build a special shipping module where you can treat the products_weight as if it were a table rate ...

    But you would need to processes that totally different and it would make messies and you'd have to touch a herd of files ...

    Or make a new field ... and use that for this sliding scale of shipping per product ... then processes that per product to produce the shipping costs ...

    To be safe, I'd go for the new field ...

    First try the concept ... before re-writting the Admin for it ...

    Then make a shipping module that grabs all the products in the cart and loop through the list and grab the products_shipping_table_rates field and you may be able to come up with a final result on this premise ...

    Still rather scary ...
    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!

  5. #5
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: Adding forumla into weight field

    Oh ... that client ...
    oh linda your to funny
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

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

    Default Re: Adding forumla into weight field

    You should of seen the specs on that one ... scary scary scary stuff ... did I mention it was scary?
    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!

  7. #7
    Join Date
    Oct 2005
    Location
    Connectiuct
    Posts
    70
    Plugin Contributions
    1

    Default Re: Adding forumla into weight field

    Scary?? Let's just say that Halloween in the States pales in comparison to the customization this shipping module could take . I would love to find a less frightful solution but likely I'm fighting a losing battle.

    Thanks anyway.

    Jim

 

 

Similar Threads

  1. Adding Product - don't see field for weight.
    By rowby in forum Setting Up Categories, Products, Attributes
    Replies: 6
    Last Post: 24 Nov 2010, 11:24 AM
  2. Adding a new Field into the Product DB
    By dukie6675 in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 19 Sep 2008, 03:18 AM
  3. Easy or Hard? Adding Weight attribute without Quantity affecting the weight
    By dharma in forum Setting Up Categories, Products, Attributes
    Replies: 7
    Last Post: 11 Mar 2007, 06:29 PM

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