-
-
Notifications
You must be signed in to change notification settings - Fork 777
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP][10.0] add project_timesheet_currency #272
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks.
just some "cosmetic" minor changes
<field name="global" eval="True"/> | ||
<field name="domain_force">['|', | ||
('company_id', '=', False), | ||
('company_id', 'in', [c.id for c in user.company_ids]), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can be ('company_id', 'in', user.company_ids.ids)
<field name="global" eval="True"/> | ||
<field name="domain_force">['|', | ||
('company_id', '=', False), | ||
('company_id', 'in', [c.id for c in user.company_ids]), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can be ('company_id', 'in', user.company_ids.ids)
self.task_USD = task_model.create( | ||
{ | ||
'name': 'Task USD', | ||
'user_id': self.user_fr.id, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set the project_id
to self.project_USD
?
|
||
# I check that the currency conversion worked as expected and both | ||
# amount and amount_currency fields values are correct | ||
self.assertEqual(total_amount, -4734.5199999999995) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better use self.assertAlmostEqual(...)
see here https://docs.python.org/2/library/unittest.html#unittest.TestCase.assertAlmostEqual
same for line 150
runbot is failing because of this warning:
|
superseeded by #275 |
* [ADD] initial rev * [IMP] per project currency cost computation * [IMP] override default record rules * [ADD] readme * [IMP] dependencies * [FIX] amount_currency computation * [ADD] tests * fix comments on #272 * proof read README.rst * FIX typo in record rule * Change some stylistic details
This module allows user to work on a multi-company / multi-currency project
management scenario.
The module changes the default record rules in order to let the users to work
simultaneously on projects and tasks of all the companies they're allowed to.
If the currency of the project is different from the one set on the current
company, the module takes care of the conversion based on the current currency
rate.