← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 672655] Re: [6.0][HIGH] Regression scheduling the cost of employee project work to analytic account

 

Hello Omar,

Would you please check with the latest revision of code.
The code is already improved what you suggested in the bug specification.

Thanks.

** Changed in: openobject-addons
       Status: New => Fix Released

-- 
[6.0][HIGH] Regression scheduling the cost of employee project work to analytic account
https://bugs.launchpad.net/bugs/672655
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.

Status in OpenObject Addons Modules: Fix Released

Bug description:
Hi,

I'm testing to add project works for an employee, from project_task_work view or timesheet view. It always creates new account.analytic.line but, these lines always have set amount to 0.0, but my employee product is set to 30€. I took a look to source and I see many regressions from "3817 revid:vir@xxxxxxxxxxx-20101020045040-j4y2zre12tos1e9x" revision in on_change_unit_amount() event.

If company_id exists, it always returns amount = 0.0, another bug is that, it computes amount with "amount = amount_unit*unit or 1.0" but from project_timesheet module unit = False, then, if it hasn't company_id it always returns 1.0. The correct will be  "amount = amount_unit*quantity". Another bug is in project_timesheet module because when this module calls to on_change_unit_amount() it doesn't pass journal_id and if journal_id = False this method returns {}.

I attach a patch





References