Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I installed the modules (product_cost_incl_bom and product_get_cost_field). When I go to the top level BOM, which includes an other BOM within it, then on the PRODUCT COST STRUCTURE print out the cost is listed as 0.00 GBP for each of the sub BOMs. This seems to be an error as the cost field in each individual sub BOM is populated correctly.
The module appears to fail to transfer the costs into the BOM cost structure.
This leads to that the cost price for a BOM, which includes as sub-BOM, is calculated incorrectly. The final cost price only includes items that are not in any sub BOM. Is it possible to calculate the final cost price of a product including all sub BOMs without having to manually add them up?
You can build your own custom module for this requirement instead of using those modules for just one thing. You can proceed in these ways: You should first inherit mrp.bom and add a new field 'price_unit': fields.float('Unit Price') and redefine the onchange_product_id function define compute_price and compute_total function to calculate "line price" and "total price" Then you have to inherit mrp.production and define compute_production_cost function to update cost_price from BOM. We have created this custom module and it works perfect , in my module it takes avg purcahse price in BOM and we added an extra tab to manufactring form to compute Production Cost , in that tab you can add extra charges like electicity etc.. , that charges also added to cost by calculating per_unit charge depending on UOM. for any help you can contact us email@example.com, firstname.lastname@example.org
I meet a new problem, when I defined product AãBãCãDã
The BOM Struct is Like: A<--2B+C C<--0.2D (that means one D can produce five C)
If the cost price of D is 10$, I hope see the cost price of C is 2$, but I see "Cost Price (incl. BoM)" is 0. why ?And the bom cost of report is also wrong, you can see the cost price of sub-product C is 0 in the report.
I find this bug only happens when I try to define a sub-material that it's quantity is float. ( C<--0.2D) , That is, if i define like C<--2Dï¼ all things looks fine!
The real problem is not the module itself, but the fact that this report "Product cost structure" isn't modified by the module. So you have to modify mrp/report/price.py and change two things:
line 68 "std_price = product_uom_pool._compute_price(cr, uid, prod.uom_id.id, prod.standard_price, to_uom_id=product_uom.id)" by "std_price = product_uom_pool._compute_price(cr, uid, prod.uom_id.id, prod.cost_price, to_uom_id=product_uom.id)"
line 150 "total_strd = number * product.standard_price" by "total_strd = number * product.cost_price"
The module product_cost_incl_bom also have to be modified (!) by changing line 62 "std_price = sub_product.standard_price" by "std_price = sub_product.cost_price" Hope this help.
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 5/23/13, 11:56 AM|
|Seen: 4621 times|
|Last updated: 3/16/15, 8:10 AM|