From 3b80bcf52146ecc6ac6cb3e72c357dc8a129ddb2 Mon Sep 17 00:00:00 2001 From: Ludovic CHEVALIER Date: Fri, 6 Nov 2015 16:11:50 +0100 Subject: [PATCH] [MODULE][VIEW] ~multiple customization --- __init__.py | 19 ++++++++++--------- __openerp__.py | 18 ++++++++++-------- velocampus_nantes.py | 45 ++++++++++++++++++++++++++++++++++++++++++++ view/bikecoop.xml | 35 ++++++++++++++++++++++++++++++++++ 4 files changed, 100 insertions(+), 17 deletions(-) create mode 100644 velocampus_nantes.py create mode 100644 view/bikecoop.xml diff --git a/__init__.py b/__init__.py index ba6f153..672e4cd 100644 --- a/__init__.py +++ b/__init__.py @@ -2,24 +2,25 @@ ############################################################################## # # velocampus_nantes module for OpenERP, Vélocampus Nantes specifities -# Copyright (C) 2013-2014 Vélocampus Nantes () +# Copyright (C) 2013-2015 Vélocampus Nantes () # # This file is a part of velocampus_nantes # -# velocampus_nantes module is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. +# velocampus_nantes module is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as published +# by the Free Software Foundation, either version 3 of the License, or (at +# your option) any later version. # -# velocampus_nantes module is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# velocampus_nantes module is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General +# Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # ############################################################################## +import velocampus_nantes # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/__openerp__.py b/__openerp__.py index 720c39d..7dc3207 100644 --- a/__openerp__.py +++ b/__openerp__.py @@ -2,19 +2,19 @@ ############################################################################## # # velocampus_nantes module for OpenERP, Vélocampus Nantes specifities -# Copyright (C) 2013-2014 Vélocampus Nantes () +# Copyright (C) 2013-2015 Vélocampus Nantes () # # This file is a part of velocampus_nantes # -# velocampus_nantes module is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or +# velocampus_nantes module is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as published +# by the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # -# velocampus_nantes module is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# velocampus_nantes module is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General +# Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . @@ -45,6 +45,8 @@ It installs the profile for bike co-ops to manage some features like: 'data/base.xml', 'data/products_categories.xml', 'data/products_products.xml', + 'data/bikecoop.xml', + 'view/bikecoop.xml', ], 'installable': True, 'auto_install': False, diff --git a/velocampus_nantes.py b/velocampus_nantes.py new file mode 100644 index 0000000..38c221d --- /dev/null +++ b/velocampus_nantes.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# velocampus_nantes module for OpenERP, Vélocampus Nantes specifities +# Copyright (C) 2013-2015 Vélocampus Nantes () +# +# This file is a part of velocampus_nantes +# +# velocampus_nantes module is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as published +# by the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# velocampus_nantes module is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General +# Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . +# +############################################################################## + +from openerp.osv import fields, osv + + +class Partner(osv.osv): + _inherit = 'res.partner' + + _columns = { + 'crous': fields.boolean('Logement CROUS?'), + 'highschool_years': fields.selection([('1', '1'), + ('2', '2'), + ('3', '3'), + ('4', '4'), + ('5', '5'), + ('6', '6'), + ('7', '7'), + ('8', '8'), + ('9', '9')], 'Highschool years'), + 'is_volunteer': fields.boolean('Is volunteer'), + } + + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/view/bikecoop.xml b/view/bikecoop.xml new file mode 100644 index 0000000..e9d0c10 --- /dev/null +++ b/view/bikecoop.xml @@ -0,0 +1,35 @@ + + + + + res.partner.form + res.partner + + + + + + + + + + + + + + + + + + + + -- 2.20.1