[FIX] sale: onchange task_work
The unticked option in Sales settings "Prepare invoices based on task's activities" doesn't have to uninstall the options "Record timesheet lines per tasks" and "Generate tasks from sale orders" in Project settings. When "Prepare invoices based on task's activities" is unticked, this fix avoid to uninstall these options each time we go to Sales settings because "onchange_task_work" is triggered each time we go to Sales settings. opw:645833
This commit is contained in:
parent
b4de311b0c
commit
f10c03ac68
|
@ -119,6 +119,8 @@ Example: Product: this product is deprecated, do not purchase more than 5.
|
|||
return {}
|
||||
|
||||
def onchange_task_work(self, cr, uid, ids, task_work, context=None):
|
||||
if not task_work:
|
||||
return {'value': {}}
|
||||
return {'value': {
|
||||
'module_project_timesheet': task_work,
|
||||
'module_project_mrp': task_work,
|
||||
|
|
Loading…
Reference in New Issue