kartrisimport

4.5.4.4. K:product.unitsize

Most items you sell will probably be sold as individual pieces, in which case the unit size is 1. This means the basket allows only values divisible by 1 (i.e. integer values).

But for some items, you may want to change this. If you sell cloth for example, it may be that you price it in metres, but can provide it in any length to the nearest centimetre. In this case, you can set the 'unitsize' object config for this item to 0.01 (1cm = 0.01m, the unit you're pricing in).

It can also work in the other direction. If you sell screws or bolts, you may price them individually, but being small items, only provide them in multiples of 50. In this case, you can price the item per piece, but set the unit size to 50.

The unit size can be any value, you could set it to 12 if bread rolls are priced individually but only available in 'dozens' or 0.25 if you price an item in kilograms but actually deliver it in multiples of a quarter kilo.

If a user tries to add an incompatible quantity, either from the product page, or by editing quantities in the basket, a warning is displayed indicating that the item can only be ordered in multiples of whatever value you have set.
 
powered by tomehost