* refactor: bom recursion checking
* fix: dont allow bom recursion
if same item_code is added in child items at any level, it shouldn't be allowed.
* test: add test for bom recursion
* test: fix broken prodplan test using recursive bom
* test: fix recursive bom in tests
* fix: pass planned start date to created workorder
* test: production plan to work order start date
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
* fix: price list with 0 value are ignored
Steps to reproduce:
1. Create 2 item price for two different supplier. One of them should be
zero.
2. Create PO
3. Add supplier with non-zero price and add item.
4. change supplier. Price won't change. If price was non-zero it
would've changed.
Root cause: falsiness check instead of null value check is used for
checking if price list value exists. 0 is evaluated as false.
* refactor: make get_price_list_rate function pure
(cherry picked from commit 16d4de5130)
Co-authored-by: Ankush <ankush@iwebnotes.com>
* fix: price list with 0 value are ignored
Steps to reproduce:
1. Create 2 item price for two different supplier. One of them should be
zero.
2. Create PO
3. Add supplier with non-zero price and add item.
4. change supplier. Price won't change. If price was non-zero it
would've changed.
Root cause: falsiness check instead of null value check is used for
checking if price list value exists. 0 is evaluated as false.
* refactor: make get_price_list_rate function pure
* fix: amount in work order not equal to rate * qty
* fix: patch for amount in work order required items
(cherry picked from commit cd12d95a24)
Co-authored-by: Ankush <ankush@iwebnotes.com>
* fix: wrong operation time in Work Order
Top level item time operation was not considering the BOM.quantity
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
* fix: wrong operation time in Work Order
Top level item time operation was not considering the BOM.quantity
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>