Merge lp:~joao-gama/partner-contact-management/6.1-partner_auto_salesman into lp:~partner-contact-core-editors/partner-contact-management/6.1

Proposed by Joao Alfredo Gama Batista
Status: Merged
Merged at revision: 5
Proposed branch: lp:~joao-gama/partner-contact-management/6.1-partner_auto_salesman
Merge into: lp:~partner-contact-core-editors/partner-contact-management/6.1
Diff against target: 101 lines (+86/-0)
3 files modified
partner_auto_salesman/__init__.py (+22/-0)
partner_auto_salesman/__openerp__.py (+35/-0)
partner_auto_salesman/res_partner.py (+29/-0)
To merge this branch: bzr merge lp:~joao-gama/partner-contact-management/6.1-partner_auto_salesman
Reviewer Review Type Date Requested Status
Maxime Chambreuil (http://www.savoirfairelinux.com) Approve
Review via email: mp+152002@code.launchpad.net

Description of the change

This is a teeny-tiny module that sets the default value for the salesman field with the current user id.

To post a comment you must log in.
Revision history for this message
Maxime Chambreuil (http://www.savoirfairelinux.com) (max3903) wrote :

LGTM. No test.

review: Approve
Revision history for this message
Guewen Baconnier @ Camptocamp (gbaconnier-c2c) wrote :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== added directory 'partner_auto_salesman'
=== added file 'partner_auto_salesman/__init__.py'
--- partner_auto_salesman/__init__.py 1970-01-01 00:00:00 +0000
+++ partner_auto_salesman/__init__.py 2013-03-06 16:26:20 +0000
@@ -0,0 +1,22 @@
1# -*- coding: utf-8 -*-
2##############################################################################
3#
4# OpenERP, Open Source Management Solution
5# Copyright (C) 2013 Savoir-faire Linux (<http://www.savoirfairelinux.com>).
6#
7# This program is free software: you can redistribute it and/or modify
8# it under the terms of the GNU Affero General Public License as
9# published by the Free Software Foundation, either version 3 of the
10# License, or (at your option) any later version.
11#
12# This program is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15# GNU Affero General Public License for more details.
16#
17# You should have received a copy of the GNU Affero General Public License
18# along with this program. If not, see <http://www.gnu.org/licenses/>.
19#
20##############################################################################
21
22import res_partner
023
=== added file 'partner_auto_salesman/__openerp__.py'
--- partner_auto_salesman/__openerp__.py 1970-01-01 00:00:00 +0000
+++ partner_auto_salesman/__openerp__.py 2013-03-06 16:26:20 +0000
@@ -0,0 +1,35 @@
1# -*- coding: utf-8 -*-
2##############################################################################
3#
4# OpenERP, Open Source Management Solution
5# Copyright (C) 2013 Savoir-faire Linux (<http://www.savoirfairelinux.com>).
6#
7# This program is free software: you can redistribute it and/or modify
8# it under the terms of the GNU Affero General Public License as
9# published by the Free Software Foundation, either version 3 of the
10# License, or (at your option) any later version.
11#
12# This program is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15# GNU Affero General Public License for more details.
16#
17# You should have received a copy of the GNU Affero General Public License
18# along with this program. If not, see <http://www.gnu.org/licenses/>.
19#
20##############################################################################
21
22{
23 'name': 'Partner auto salesman',
24 'version': '1.0',
25 'category': 'Customer Relationship Management',
26 'complexity': "easy",
27 'description': """Fill the salesman field with the current user id""",
28 'author': 'Savoir-faire Linux',
29 'website': 'http://www.savoirfairelinux.com',
30 'license': 'AGPL-3',
31 'depends': ['base'],
32 'installable': True,
33 'auto_install': False,
34}
35# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
036
=== added file 'partner_auto_salesman/res_partner.py'
--- partner_auto_salesman/res_partner.py 1970-01-01 00:00:00 +0000
+++ partner_auto_salesman/res_partner.py 2013-03-06 16:26:20 +0000
@@ -0,0 +1,29 @@
1# -*- coding: utf-8 -*-
2##############################################################################
3#
4# OpenERP, Open Source Management Solution
5# Copyright (C) 2013 Savoir-faire Linux (<http://www.savoirfairelinux.com>).
6#
7# This program is free software: you can redistribute it and/or modify
8# it under the terms of the GNU Affero General Public License as
9# published by the Free Software Foundation, either version 3 of the
10# License, or (at your option) any later version.
11#
12# This program is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15# GNU Affero General Public License for more details.
16#
17# You should have received a copy of the GNU Affero General Public License
18# along with this program. If not, see <http://www.gnu.org/licenses/>.
19#
20##############################################################################
21
22from openerp.osv import osv
23
24
25class res_partner(osv.osv):
26 _inherit = 'res.partner'
27 _defaults = {'user_id': lambda self, cr, uid, context: uid}
28
29res_partner()

Subscribers

People subscribed via source and target branches

to status/vote changes: