- Added filters in the Report for BOM ID, Item Code and Workstation
- Converted Raw SQL to frappe.qb and added method to get filtered data
- Changed fieldtype of 'Time in mins' from Int to Float
- Get BOM wise grouped data to keep order and accurate grouping in report
* feat: Operation time can be fixed
* better coding without duplicate code
* change modified date foir doctype
* undo change
* fix varmixing
* fix varmixing
* fix: remove f-string that's not required anymore
* refactor: use ORM instead of raw query
* fix: improve description
* test: basic test for fixed time
Co-authored-by: Ankush Menat <ankush@frappe.io>
* fix: reservation for production incorrect
The query uses case to decide what fields to compute reservation on,
this case is outermost case hence the very first Work order's "Skip
transfer" is considered for ALL work orders.
Solution: move the case inside Sum.
Steps to reproduce:
1. Make work order for more than 1 qty (with | without skip transfer)
2. Create manufacture and transfer entries.
3. Keep checking reserved quantities during this process.
* test: use default warehouse for testing reservation
* fix: fixes in work order doctype
* fix: sider issues and disabled set only once property
* fix: set default qty to manufacture
* fix: dont manually collapse sections
* fix: remove unnecessary messages
* fix: make dependent fields read only
Co-authored-by: Ankush Menat <ankush@frappe.io>
* fix: Closed status error in Work Order Summary
* chore: use get_meta to get status options
* refactor: simplify code
Co-authored-by: Ankush Menat <ankush@frappe.io>
- make `tests_that_skip_setup` a tuple (added comma)
- remove manual teardown in `test_job_card_material_transfer_correctness` to avoid premature committing
- transfer_material_against = "Job Card" while making BOM with mulitple operations
- `get_cached_value` throws a DoesNotExistError if non-existent value, used `get_value` instead
- accomodate production plan items that dont have WO/PO against them as well (blank values)
- added some None value handling to avoid AttributeError
- Fixed transferred qty not back updating on JC if partial transfer
- Partial transfer not mapping pending qty from JC correctly in SE
- tests for above cases
- minor code cleanup