Selling in Different Units - The problem

webERP only allows the business to have a single unit which is recorded in the stockmaster. Everywhere we look at accumulated sales quantities and quantity demand we refer to this unit. Some businesses wish to be able to sell the item in different units - e.g. flour - could have a unit of 25kg bag, but also we sold in the pallet of 15 sacks, or by the retail unit of 1kg bag.

We can emulate this using the assembly which has a new assembly item created for each unit to be sold in. The new assembly item has a bill of material containing a quantity of the item. For some this solution will achieve all they need. Also, using assembly items defined in a specific unit means thant sales analysis can be run by each item and the value associated with selling in different units can be determined, it also avoids a lot of complexity in the code. Using assembly items for selling in different units is actually quite an elegant solution involving few compromises. For this reason I prefer not to include functionality to have prices by unit as described below.

To allow the item to be sold directly in different units, pricing could be held in the same prices table simply by adding a unit field to the prices table, an additional field to store the conversionfactor between the unit in the prices table and the default stockmaster unit would also be required - the scripts that manipulate prices PricesByCost.php and Prices.php (and some others) would need modifiations to be able to cater for the additional field. The logic to get prices from include/GetPrice.php would need modification.

My feeling is that is would be good to leave tables and existing planning/MRP logic in tact so far as possible. This would require storing the quantities in all tables as the stockmaster unit quantity. However, in the same way as purchorderdetails stores a conversionfactor against salesorderdetails - I think it would be best to read this from the prices table and store it also in salesorderdetails, so if the units of sale change at some future time the unit conversionfactor for this sale is retained.

The unit for the sale would need to be selected at the SelectOrderItems.php stage, the system would pull up the conversion factor and price from the prices table. However, the price stored against the salesorderdetails would be the unit price retrieved but converted to the stockmaster unit price using the conversion factor. The user would see the unit selected and the price for this unit, but this data is not stored - it is calculated from the stockmaster unit price which is stored as multiplied by the unit conversionfactor (which is also stored).

Using this logic - existing logic could remain in tact but sales in any unit accomodated.
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki