[FIX] sale_timesheet_margin: sale order line cost
Set Default UoM on Timesheet Settings page: Hours
Set [Employee] Timesheet Cost (HR Settings tab): 65.00/hour
Create a product [TEST] as follows:
- Product type: service
- Invoicing Policy: Based on Timesheets
- Create on Order: Project & Task
- Unit of Measure: Days
- Purchase UoM: Days
- Sales Price: 1.00
- Cost: 0.00
Create a sales order
Add an order line with product [TEST], quantity 1
Confirm. Project and task will be created
On the task add a 1 hour timesheet entry for [Employee]
Save and go back to the SO
Issue: SO line cost is incorrectly computed.
opw-3378688
closes odoo/odoo#133448
Signed-off-by:
Xavier Bol (xbo) <xbo@odoo.com>
Showing
- addons/sale_timesheet_margin/models/sale_order_line.py 6 additions, 5 deletionsaddons/sale_timesheet_margin/models/sale_order_line.py
- addons/sale_timesheet_margin/tests/__init__.py 4 additions, 0 deletionsaddons/sale_timesheet_margin/tests/__init__.py
- addons/sale_timesheet_margin/tests/test_sale_timesheet_margin.py 65 additions, 0 deletions...sale_timesheet_margin/tests/test_sale_timesheet_margin.py