Merge pull request #24301 from rohitwaghchaure/fixed-allow-to-override-basic-rate-for-fg

fix: allow to override the basic rate for the finished good
This commit is contained in:
rohitwaghchaure
2021-01-05 14:55:42 +05:30
committed by GitHub

View File

@@ -460,7 +460,7 @@ class StockEntry(StockController):
scrap_material_cost += flt(d.basic_amount)
number_of_fg_items = len([t.t_warehouse for t in self.get("items") if t.t_warehouse])
if number_of_fg_items == 1 or update_finished_item_rate:
if (fg_basic_rate == 0.0 and number_of_fg_items == 1) or update_finished_item_rate:
self.set_basic_rate_for_finished_goods(raw_material_cost, scrap_material_cost)
def get_args_for_incoming_rate(self, item):