Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2004
    Posts
    38
    Plugin Contributions
    0

    Default Custom price calculation from many attributes

    I have searched the forum and can't find any discussion of what I am trying to do. My apologies if this has been covered before ... if it has, please point me to the relevant thread.

    My products are picture frames. A frame is priced based on its total length, rounded up to the nearest foot. There are 4 attributes collected that define the width in inches, width fraction of an inch, height in inches, and height fraction of an inch. From those 4 values the total length can be calculated, and which is used to do a table lookup to get the price. For example, frames less than 5 feet are $30, less than 10 feet are $55, and so on. (Actually, there are 5 lookup tables since there are 5 levels of pricing for the different frame products).

    I know this will require some custom programming and have spent many hours studying to determine the best way to implement this type of pricing. I don't see any straightforward way to do it. It looks like Zen is set up to do the pricing based on the product price (in the product table) and attribute pricing if any has been defined. The attribute pricing is done one attribute at a time and I don't see any way to easily calculate a price by looking at all the attributes together rather than individually.

    Can anyone offer advice as to the best way to approach this that would fit best with how Zen does pricing?

    Thanks ... Bowen

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Custom price calculation from many attributes

    The attribute pricing is done one attribute at a time and I don't see any way to easily calculate a price by looking at all the attributes together rather than individually.
    What you are describing is one attribute dependant upon another or dependant attributes
    There is no default facility for handling dependant attributes in ZenCart
    Additionally, "width/height in fraction of an inch" is not directly calulatable and would need to be entered in decimal or converted programatically
    It looks like Zen is set up to do the pricing based on the product price (in the product table) and attribute pricing if any has been defined.
    One can select "priced by attributes" in the product entry, but this still does not attain the dependency
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Jan 2004
    Posts
    38
    Plugin Contributions
    0

    Default Re: Custom price calculation from many attributes

    That's what I concluded as well. Given that I will need to make some changes to how pricing works, can anyone recommend the best way to make this change? How would a veteran Zen developer go about doing it? I looked at notifiers/observers and didn't see a hook that would meet my needs.

    Thanks ... Bowen

  4. #4
    Join Date
    Sep 2009
    Posts
    23
    Plugin Contributions
    0

    Default Re: Custom price calculation from many attributes

    Did you have any luck with this? I have the same need.

    Thanks,

    Peter

 

 

Similar Threads

  1. Custom Prices from Changing attributes
    By Guybrush in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 23 Feb 2012, 10:16 PM
  2. USPS Shipping charge calculation, many items = less accuracy
    By Olof Holte in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 11 Mar 2009, 09:29 PM
  3. How many attributes is too many?
    By steveyork136 in forum Setting Up Categories, Products, Attributes
    Replies: 9
    Last Post: 15 Jan 2009, 09:20 AM
  4. Price calculation with attributes
    By Spectral in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 17 Oct 2006, 03:40 PM

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