-
-
Notifications
You must be signed in to change notification settings - Fork 291
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
[MIG] port mgmtsystem hazard to V9 #164
Conversation
------------ | ||
|
||
* Maxime Chambreuil <maxime.chambreuil@savoirfairelinux.com> | ||
* Loïc Lacroix <loic.lacroix@savoirfairelinux.com> |
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.
@ngrandjean Please add yourself to the list.
mgmtsystem_hazard/__openerp__.py
Outdated
"version": "1.1", | ||
"author": "Savoir-faire Linux,Odoo Community Association (OCA)", | ||
"name": "Hazard", | ||
"version": "9.0.1.1.0", |
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.
9.0.1.0.0
# You should have received a copy of the GNU Affero General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
# | ||
############################################################################## |
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.
Please use the shorter version of the header:
# -*- coding: utf-8 -*-
# Copyright <YEAR(S)> <AUTHOR(S)>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
Hey @ngrandjean, thank you for your Pull Request. It looks like some users haven't signed our Contributor License Agreement, yet.
Appreciation of efforts, |
company_id = fields.Many2one( | ||
'res.company', | ||
'Company', | ||
default=lambda s: s.env['res.users'].browse(s._uid).company_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.
I think this can be just s.env.user.company_id
.
Can you check that?
_name = "mgmtsystem.hazard.origin" | ||
_description = "Origin of hazard" | ||
|
||
name = fields.Char('Origin', size=50, required=True, translate=True) |
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.
Remove size
_name = "mgmtsystem.hazard.probability" | ||
_description = "Probability of hazard" | ||
|
||
name = fields.Char('Probability', size=50, required=True, translate=True) |
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.
Remove size
_name = "mgmtsystem.hazard.severity" | ||
_description = "Severity of hazard" | ||
|
||
name = fields.Char('Severity', size=50, required=True, translate=True) |
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.
Remove size
_name = "mgmtsystem.hazard.test" | ||
_description = "Implementation Tests of hazard" | ||
|
||
name = fields.Char('Test', size=50, required=True, translate=True) |
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.
Remove size
_description = "Usage of hazard" | ||
name = fields.Char( | ||
'Occupation / Usage', | ||
size=50, |
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.
Remove size
Migration from v8.0 to 9.0
Align files to most recent version of branch 8.0 (code version of branch to migrate was quite old)
Change indicated version to 9.0
Replace by in xml files and remove
Make module installable