summaryrefslogtreecommitdiff
path: root/addons/web/static/tests/fields/basic_fields_tests.js
diff options
context:
space:
mode:
authorNicolas Martinelli <nim@odoo.com>2019-09-27 09:55:12 +0000
committerfw-bot <otis@odoo.com>2019-09-27 17:51:21 +0000
commit01c567c376a595e363633172a38c713c94acd15d (patch)
tree8135a78bee48ef2dbfdd5296085f642850d5178d /addons/web/static/tests/fields/basic_fields_tests.js
parentda5a51eb3213a80f5b3e80d8edc84080a9202354 (diff)
[FIX] mrp: Time Cycle computation
- Create a workcenter with a capacity of 500 units - Create a BOM with a routing generating one work order in the WC created - Create 3 MO with the following real durations: MO 1: 1000 units produced in 420.95 seconds MO 2: 1000 units produced in 120.28 seconds MO 3: 1000 units produced in 60 seconds - Create a MO for 1 unit The Duration expected is computed as The Time Cycle is computed as: (420.95 + 120.28 + 60) / (1000 + 1000 + 1000) = 0.20041 The Total Expected is computed as: 0 + 0 + (1.0 * 0.20041) * (100.0 / 100.0) = 0.20041 0.20041 seconds is not realistic based on the previous MO real durations. This is because the Time Cycle doesn't take into account the workcenter capacity. If we can produce 60 units in parallel in 60 seconds, that doesn't mean we can produce 1 unit in 1 second. Therefore, the Time Cycle should be multiplied by the WC capacity, which gives a Time Cycle: 500 * (420.95 + 120.28 + 60) / (3000) = 100.205 Which is much closer to the real duration. opw-2070759 closes odoo/odoo#37548 X-original-commit: 9d3a73f64feb3b9e71c50a04adb6206b6393c757 Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Diffstat (limited to 'addons/web/static/tests/fields/basic_fields_tests.js')
0 files changed, 0 insertions, 0 deletions