Merge lp:~dreis-pt/department-mgmt/project-v7b into lp:~department-core-editors/department-mgmt/7.0

Proposed by Daniel Reis
Status: Superseded
Proposed branch: lp:~dreis-pt/department-mgmt/project-v7b
Merge into: lp:~department-core-editors/department-mgmt/7.0
Diff against target: 742 lines (+264/-386)
13 files modified
analytic_department/LICENSE (+18/-0)
analytic_department/__init__.py (+0/-31)
analytic_department/__openerp__.py (+10/-50)
analytic_department/analytic.py (+7/-49)
analytic_department/analytic_view.xml (+73/-86)
hr_timesheet_department/LICENSE (+18/-0)
hr_timesheet_department/__init__.py (+1/-0)
hr_timesheet_department/__openerp__.py (+16/-0)
hr_timesheet_department/hr_timesheet_view.xml (+46/-0)
project_department/LICENSE (+18/-0)
project_department/__init__.py (+1/-32)
project_department/__openerp__.py (+10/-51)
project_department/project_view.xml (+46/-87)
To merge this branch: bzr merge lp:~dreis-pt/department-mgmt/project-v7b
Reviewer Review Type Date Requested Status
Guewen Baconnier @ Camptocamp Needs Fixing
Review via email: mp+151006@code.launchpad.net

This proposal has been superseded by a proposal from 2013-03-04.

Description of the change

Migrating "project_department" to v7.
Timesheet features were split into a separate module.
Both these modules will auto-install if "analytic_department" is also installed.

To post a comment you must log in.
Revision history for this message
Guewen Baconnier @ Camptocamp (gbaconnier-c2c) wrote :

Nitpicking:

l.299,314,326,338,350,429,441,453,702,714,729
The <field name="type">...</field> is now useless in v7, they can be removed.

Otherwise, it seems good to me, so I approve.

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

hmm, not noticed that before, can you remove the +x flag on some .py files ?

=== modified file 'analytic_department/__init__.py' (properties changed: -x to +x)
=== modified file 'analytic_department/__openerp__.py' (properties changed: -x to +x)
=== modified file 'analytic_department/analytic.py' (properties changed: -x to +x)

review: Needs Fixing

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file 'analytic_department/LICENSE'
2--- analytic_department/LICENSE 1970-01-01 00:00:00 +0000
3+++ analytic_department/LICENSE 2013-02-28 12:30:30 +0000
4@@ -0,0 +1,18 @@
5+OpenERP, Open Source Management Solution
6+
7+Original author: Joël Grand-Guillaume
8+Copyright © 2011 Camptocamp SA (http://www.camptocamp.com)
9+Copyright © 2013 Daniel Reis (SECURITAS)
10+
11+This program is free software: you can redistribute it and/or modify
12+it under the terms of the GNU Affero General Public License as
13+published by the Free Software Foundation, either version 3 of the
14+License, or (at your option) any later version.
15+
16+This program is distributed in the hope that it will be useful,
17+but WITHOUT ANY WARRANTY; without even the implied warranty of
18+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19+GNU Affero General Public License for more details.
20+
21+You should have received a copy of the GNU Affero General Public Lice
22+along with this program. If not, see <http://www.gnu.org/licenses/>.
23
24=== modified file 'analytic_department/__init__.py' (properties changed: -x to +x)
25--- analytic_department/__init__.py 2011-08-12 12:53:16 +0000
26+++ analytic_department/__init__.py 2013-02-28 12:30:30 +0000
27@@ -1,32 +1,1 @@
28-# -*- coding: utf-8 -*-
29-##############################################################################
30-#
31-# Copyright (c) 2011 Camptocamp SA (http://www.camptocamp.com)
32-# All Right Reserved
33-#
34-# Author : Joel Grand-guillaume (Camptocamp)
35-#
36-# WARNING: This program as such is intended to be used by professional
37-# programmers who take the whole responsability of assessing all potential
38-# consequences resulting from its eventual inadequacies and bugs
39-# End users who are looking for a ready-to-use solution with commercial
40-# garantees and support are strongly adviced to contract a Free Software
41-# Service Company
42-#
43-# This program is Free Software; you can redistribute it and/or
44-# modify it under the terms of the GNU General Public License
45-# as published by the Free Software Foundation; either version 2
46-# of the License, or (at your option) any later version.
47-#
48-# This program is distributed in the hope that it will be useful,
49-# but WITHOUT ANY WARRANTY; without even the implied warranty of
50-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
51-# GNU General Public License for more details.
52-#
53-# You should have received a copy of the GNU General Public License
54-# along with this program; if not, write to the Free Software
55-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
56-#
57-##############################################################################
58-
59 import analytic
60
61=== modified file 'analytic_department/__openerp__.py' (properties changed: -x to +x)
62--- analytic_department/__openerp__.py 2013-01-04 10:32:58 +0000
63+++ analytic_department/__openerp__.py 2013-02-28 12:30:30 +0000
64@@ -1,55 +1,15 @@
65 # -*- coding: utf-8 -*-
66-##############################################################################
67-#
68-# Copyright (c) 2011 Camptocamp SA (http://www.camptocamp.com)
69-# All Right Reserved
70-#
71-# Author : Joel Grand-guillaume (Camptocamp)
72-#
73-# WARNING: This program as such is intended to be used by professional
74-# programmers who take the whole responsability of assessing all potential
75-# consequences resulting from its eventual inadequacies and bugs
76-# End users who are looking for a ready-to-use solution with commercial
77-# garantees and support are strongly adviced to contract a Free Software
78-# Service Company
79-#
80-# This program is Free Software; you can redistribute it and/or
81-# modify it under the terms of the GNU General Public License
82-# as published by the Free Software Foundation; either version 2
83-# of the License, or (at your option) any later version.
84-#
85-# This program is distributed in the hope that it will be useful,
86-# but WITHOUT ANY WARRANTY; without even the implied warranty of
87-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
88-# GNU General Public License for more details.
89-#
90-# You should have received a copy of the GNU General Public License
91-# along with this program; if not, write to the Free Software
92-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
93-#
94-##############################################################################
95-
96 {
97- "name" : "Analytic Account Department Categorization",
98- "version" : "1.0",
99- "author" : "Camptocamp",
100- "category" : "Generic Modules/Projects & Services",
101- "description":
102-"""
103- Add the department on Analytic Account and Analytical line as well as the related filter and button in the search form of
104- both object.
105-
106+ "name": "Analytic Account Department Categorization",
107+ "version": "1.0",
108+ "author": "Camptocamp, Daniel Reis",
109+ "license": "AGPL-3",
110+ "category": "Generic Modules/Projects & Services",
111+ "description": """\
112+Add Department to Analytic Account and Analytical Line models, and to
113+corresponding tree, search and form views.
114 """,
115 "website": "http://camptocamp.com",
116- "depends" : [
117- "account",
118- "hr",
119- ],
120- "init_xml" : [],
121- "demo_xml" : [],
122- "update_xml" : [
123- "analytic_view.xml",
124- ],
125- "active": False,
126- 'installable': False
127+ "depends": ["account", "hr"],
128+ "data": ["analytic_view.xml"],
129 }
130
131=== modified file 'analytic_department/analytic.py' (properties changed: -x to +x)
132--- analytic_department/analytic.py 2011-08-12 12:53:16 +0000
133+++ analytic_department/analytic.py 2013-02-28 12:30:30 +0000
134@@ -1,58 +1,16 @@
135 # -*- coding: utf-8 -*-
136-##############################################################################
137-#
138-# Copyright (c) 2010 Camptocamp SA (http://www.camptocamp.com)
139-# All Right Reserved
140-#
141-# Author : Joel Grand-guillaume (Camptocamp)
142-#
143-# WARNING: This program as such is intended to be used by professional
144-# programmers who take the whole responsability of assessing all potential
145-# consequences resulting from its eventual inadequacies and bugs
146-# End users who are looking for a ready-to-use solution with commercial
147-# garantees and support are strongly adviced to contract a Free Software
148-# Service Company
149-#
150-# This program is Free Software; you can redistribute it and/or
151-# modify it under the terms of the GNU General Public License
152-# as published by the Free Software Foundation; either version 2
153-# of the License, or (at your option) any later version.
154-#
155-# This program is distributed in the hope that it will be useful,
156-# but WITHOUT ANY WARRANTY; without even the implied warranty of
157-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
158-# GNU General Public License for more details.
159-#
160-# You should have received a copy of the GNU General Public License
161-# along with this program; if not, write to the Free Software
162-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
163-#
164-##############################################################################
165-
166-from osv import osv
167-from osv import fields
168-
169-class analytic_account(osv.osv):
170+from openerp.osv import fields, orm
171+
172+
173+class AnalyticAccount(orm.Model):
174 _inherit = "account.analytic.account"
175-
176 _columns = {
177 'department_id': fields.many2one('hr.department', 'Department'),
178 }
179- _defaults = {
180- 'department_id': lambda s,cr,uid,c: s.pool.get('res.users').browse(cr,uid,uid).context_department_id.id,
181- }
182-
183-analytic_account()
184-
185-class analytic_line(osv.osv):
186+
187+
188+class AnalyticLine(orm.Model):
189 _inherit = "account.analytic.line"
190-
191 _columns = {
192 'department_id': fields.many2one('hr.department', 'Department'),
193 }
194- _defaults = {
195- 'department_id': lambda s,cr,uid,c: s.pool.get('res.users').browse(cr,uid,uid).context_department_id.id,
196- }
197-
198-analytic_line()
199-
200
201=== modified file 'analytic_department/analytic_view.xml'
202--- analytic_department/analytic_view.xml 2012-07-23 06:52:34 +0000
203+++ analytic_department/analytic_view.xml 2013-02-28 12:30:30 +0000
204@@ -1,86 +1,73 @@
205-<openerp>
206- <data>
207-
208-
209- <record id="view_account_analytic_account_search" model="ir.ui.view">
210- <field name="name">account.analytic.account.search</field>
211- <field name="model">account.analytic.account</field>
212- <field name="inherit_id" ref="account.view_account_analytic_account_search" />
213- <field name="type">search</field>
214- <field name="arch" type="xml">
215- <xpath expr="/search/group/field[@name='user_id']" position="after">
216- <field name="department_id" widget="selection" >
217- <filter icon="terp-personal+" domain="[('department_id','=',context.get('department_id',False))]" string="My Departments Employee"/>
218- </field>
219- </xpath>
220- <xpath expr="/search/group/filter[@string='Manager']" position="after">
221- <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
222- </xpath>
223- </field>
224- </record>
225-
226- <record id="view_account_analytic_account_tree" model="ir.ui.view">
227- <field name="name">account.analytic.account.tree</field>
228- <field name="model">account.analytic.account</field>
229- <field name="inherit_id" ref="account.view_account_analytic_account_tree" />
230- <field name="type">tree</field>
231- <field name="arch" type="xml">
232- <xpath expr="/tree/field[@name='code']" position="after">
233- <field name="department_id" />
234- </xpath>
235- </field>
236- </record>
237-
238- <record id="view_account_analytic_account_form" model="ir.ui.view">
239- <field name="name">account.analytic.account.form</field>
240- <field name="model">account.analytic.account</field>
241- <field name="inherit_id" ref="account.view_account_analytic_account_form" />
242- <field name="type">form</field>
243- <field name="arch" type="xml">
244- <xpath expr="/form/notebook/page/group/field[@name='partner_id']" position="after">
245- <field name="department_id" />
246- </xpath>
247- </field>
248- </record>
249-
250-
251- <record id="view_account_analytic_line_form" model="ir.ui.view">
252- <field name="name">account.analytic.line.form</field>
253- <field name="model">account.analytic.line</field>
254- <field name="inherit_id" ref="account.view_account_analytic_line_form" />
255- <field name="type">form</field>
256- <field name="arch" type="xml">
257- <xpath expr="/form/group/field[@name='company_id']" position="after">
258- <field name="department_id" />
259- </xpath>
260- </field>
261- </record>
262-
263- <record id="view_account_analytic_line_tree" model="ir.ui.view">
264- <field name="name">account.analytic.line.tree</field>
265- <field name="model">account.analytic.line</field>
266- <field name="inherit_id" ref="account.view_account_analytic_line_tree" />
267- <field name="type">tree</field>
268- <field name="arch" type="xml">
269- <xpath expr="/tree/field[@name='user_id']" position="after">
270- <field name="department_id" />
271- </xpath>
272- </field>
273- </record>
274- <record id="view_account_analytic_line_filter" model="ir.ui.view">
275- <field name="name">account.analytic.line.select</field>
276- <field name="model">account.analytic.line</field>
277- <field name="inherit_id" ref="account.view_account_analytic_line_filter" />
278- <field name="type">search</field>
279- <field name="arch" type="xml">
280- <xpath expr="/search/group/field[@name='user_id']" position="before">
281- <field name="department_id" widget="selection" />
282- </xpath>
283- <xpath expr="/search/group/filter[@string='User']" position="after">
284- <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
285- </xpath>
286- </field>
287- </record>
288-
289- </data>
290-</openerp>
291+<openerp>
292+ <data>
293+
294+
295+ <record id="view_account_analytic_account_search" model="ir.ui.view">
296+ <field name="name">account.analytic.account.search</field>
297+ <field name="model">account.analytic.account</field>
298+ <field name="inherit_id" ref="account.view_account_analytic_account_search"/>
299+ <field name="type">search</field>
300+ <field name="arch" type="xml">
301+ <field name="user_id" position="after">
302+ <field name="department_id"/>
303+ </field>
304+ <xpath expr="/search/group/filter[1]" position="after">
305+ <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
306+ </xpath>
307+ </field>
308+ </record>
309+
310+ <record id="view_account_analytic_account_tree" model="ir.ui.view">
311+ <field name="name">account.analytic.account.tree</field>
312+ <field name="model">account.analytic.account</field>
313+ <field name="inherit_id" ref="account.view_account_analytic_account_tree"/>
314+ <field name="type">tree</field>
315+ <field name="arch" type="xml">
316+ <field name="code" position="after">
317+ <field name="department_id"/>
318+ </field>
319+ </field>
320+ </record>
321+
322+ <record id="view_account_analytic_line_form" model="ir.ui.view">
323+ <field name="name">account.analytic.line.form</field>
324+ <field name="model">account.analytic.line</field>
325+ <field name="inherit_id" ref="account.view_account_analytic_line_form"/>
326+ <field name="type">form</field>
327+ <field name="arch" type="xml">
328+ <field name="company_id" position="after">
329+ <field name="department_id"/>
330+ </field>
331+ </field>
332+ </record>
333+
334+ <record id="view_account_analytic_line_tree" model="ir.ui.view">
335+ <field name="name">account.analytic.line.tree</field>
336+ <field name="model">account.analytic.line</field>
337+ <field name="inherit_id" ref="account.view_account_analytic_line_tree"/>
338+ <field name="type">tree</field>
339+ <field name="arch" type="xml">
340+ <field name="company_id" position="after">
341+ <field name="department_id"/>
342+ </field>
343+ </field>
344+ </record>
345+
346+ <record id="view_account_analytic_line_filter" model="ir.ui.view">
347+ <field name="name">account.analytic.line.select</field>
348+ <field name="model">account.analytic.line</field>
349+ <field name="inherit_id" ref="account.view_account_analytic_line_filter"/>
350+ <field name="type">search</field>
351+ <field name="arch" type="xml">
352+ <field name="user_id" position="before">
353+ <field name="department_id" widget="selection"/>
354+ </field>
355+ <xpath expr="/search/group/filter[@string='User']" position="after">
356+ <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
357+ </xpath>
358+ </field>
359+ </record>
360+
361+ </data>
362+</openerp>
363+
364
365=== modified file 'analytic_department/i18n/analytic_department.pot' (properties changed: +x to -x)
366=== modified file 'analytic_department/i18n/es.po' (properties changed: +x to -x)
367=== removed directory 'analytic_department/security'
368=== added directory 'hr_timesheet_department'
369=== added file 'hr_timesheet_department/LICENSE'
370--- hr_timesheet_department/LICENSE 1970-01-01 00:00:00 +0000
371+++ hr_timesheet_department/LICENSE 2013-02-28 12:30:30 +0000
372@@ -0,0 +1,18 @@
373+OpenERP, Open Source Management Solution
374+
375+Original author: Joël Grand-Guillaume (in module project_department)
376+Copyright © 2011 Camptocamp SA (http://www.camptocamp.com)
377+Copyright © 2013 Daniel Reis (SECURITAS)
378+
379+This program is free software: you can redistribute it and/or modify
380+it under the terms of the GNU Affero General Public License as
381+published by the Free Software Foundation, either version 3 of the
382+License, or (at your option) any later version.
383+
384+This program is distributed in the hope that it will be useful,
385+but WITHOUT ANY WARRANTY; without even the implied warranty of
386+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
387+GNU Affero General Public License for more details.
388+
389+You should have received a copy of the GNU Affero General Public Lice
390+along with this program. If not, see <http://www.gnu.org/licenses/>.
391
392=== added file 'hr_timesheet_department/__init__.py'
393--- hr_timesheet_department/__init__.py 1970-01-01 00:00:00 +0000
394+++ hr_timesheet_department/__init__.py 2013-02-28 12:30:30 +0000
395@@ -0,0 +1,1 @@
396+#empty
397
398=== added file 'hr_timesheet_department/__openerp__.py'
399--- hr_timesheet_department/__openerp__.py 1970-01-01 00:00:00 +0000
400+++ hr_timesheet_department/__openerp__.py 2013-02-28 12:30:30 +0000
401@@ -0,0 +1,16 @@
402+# -*- coding: utf-8 -*-
403+{
404+ "name": "Analytic Accounts / Contracts Department Categorization",
405+ "version": "1.0",
406+ "author": "Camptocamp, Daniel Reis",
407+ "license": "AGPL-3",
408+ "category": "Generic Modules/Projects & Services",
409+ "description": """\
410+Add Department to Timesheets (hr.analytic.timesheet) and to corresponding tree,
411+search and form views.
412+""",
413+ "website": "http://camptocamp.com",
414+ "depends": ["hr_timesheet", "analytic_department"],
415+ "data": ["hr_timesheet_view.xml"],
416+ "auto_install": True,
417+}
418
419=== added file 'hr_timesheet_department/hr_timesheet_view.xml'
420--- hr_timesheet_department/hr_timesheet_view.xml 1970-01-01 00:00:00 +0000
421+++ hr_timesheet_department/hr_timesheet_view.xml 2013-02-28 12:30:30 +0000
422@@ -0,0 +1,46 @@
423+<openerp>
424+ <data>
425+
426+ <record id="hr_timesheet_line_tree" model="ir.ui.view">
427+ <field name="name">hr.analytic.timesheet.tree</field>
428+ <field name="model">hr.analytic.timesheet</field>
429+ <field name="type">tree</field>
430+ <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_tree"/>
431+ <field name="arch" type="xml">
432+ <field name="user_id" position="after">
433+ <field name="department_id"/>
434+ </field>
435+ </field>
436+ </record>
437+
438+ <record id="hr_timesheet_line_form" model="ir.ui.view">
439+ <field name="name">hr.analytic.timesheet.form</field>
440+ <field name="model">hr.analytic.timesheet</field>
441+ <field name="type">form</field>
442+ <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_form"/>
443+ <field name="arch" type="xml">
444+ <field name="date" position="after">
445+ <field name="department_id"/>
446+ </field>
447+ </field>
448+ </record>
449+
450+ <record id="hr_timesheet_line_search" model="ir.ui.view">
451+ <field name="name">hr.analytic.timesheet.search</field>
452+ <field name="model">hr.analytic.timesheet</field>
453+ <field name="type">search</field>
454+ <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_search"/>
455+ <field name="arch" type="xml">
456+ <field name="user_id" position="after">
457+ <field name="department_id"/>
458+ </field>
459+ <xpath expr="/search/group/filter[@string='Users']" position="after">
460+ <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
461+ </xpath>
462+ </field>
463+
464+ </record>
465+
466+ </data>
467+</openerp>
468+
469
470=== added file 'project_department/LICENSE'
471--- project_department/LICENSE 1970-01-01 00:00:00 +0000
472+++ project_department/LICENSE 2013-02-28 12:30:30 +0000
473@@ -0,0 +1,18 @@
474+OpenERP, Open Source Management Solution
475+
476+Original author: Joël Grand-Guillaume
477+Copyright © 2011 Camptocamp SA (http://www.camptocamp.com)
478+Copyright © 2013 Daniel Reis (SECURITAS)
479+
480+This program is free software: you can redistribute it and/or modify
481+it under the terms of the GNU Affero General Public License as
482+published by the Free Software Foundation, either version 3 of the
483+License, or (at your option) any later version.
484+
485+This program is distributed in the hope that it will be useful,
486+but WITHOUT ANY WARRANTY; without even the implied warranty of
487+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
488+GNU Affero General Public License for more details.
489+
490+You should have received a copy of the GNU Affero General Public Lice
491+along with this program. If not, see <http://www.gnu.org/licenses/>.
492
493=== modified file 'project_department/__init__.py'
494--- project_department/__init__.py 2011-08-12 12:53:16 +0000
495+++ project_department/__init__.py 2013-02-28 12:30:30 +0000
496@@ -1,32 +1,1 @@
497-# -*- coding: utf-8 -*-
498-##############################################################################
499-#
500-# Copyright (c) 2011 Camptocamp SA (http://www.camptocamp.com)
501-# All Right Reserved
502-#
503-# Author : Joel Grand-guillaume (Camptocamp)
504-#
505-# WARNING: This program as such is intended to be used by professional
506-# programmers who take the whole responsability of assessing all potential
507-# consequences resulting from its eventual inadequacies and bugs
508-# End users who are looking for a ready-to-use solution with commercial
509-# garantees and support are strongly adviced to contract a Free Software
510-# Service Company
511-#
512-# This program is Free Software; you can redistribute it and/or
513-# modify it under the terms of the GNU General Public License
514-# as published by the Free Software Foundation; either version 2
515-# of the License, or (at your option) any later version.
516-#
517-# This program is distributed in the hope that it will be useful,
518-# but WITHOUT ANY WARRANTY; without even the implied warranty of
519-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
520-# GNU General Public License for more details.
521-#
522-# You should have received a copy of the GNU General Public License
523-# along with this program; if not, write to the Free Software
524-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
525-#
526-##############################################################################
527-
528-import project
529+#empty
530
531=== modified file 'project_department/__openerp__.py'
532--- project_department/__openerp__.py 2013-01-04 10:32:58 +0000
533+++ project_department/__openerp__.py 2013-02-28 12:30:30 +0000
534@@ -1,56 +1,15 @@
535 # -*- coding: utf-8 -*-
536-##############################################################################
537-#
538-# Copyright (c) 2011 Camptocamp SA (http://www.camptocamp.com)
539-# All Right Reserved
540-#
541-# Author : Joel Grand-guillaume (Camptocamp)
542-#
543-# WARNING: This program as such is intended to be used by professional
544-# programmers who take the whole responsability of assessing all potential
545-# consequences resulting from its eventual inadequacies and bugs
546-# End users who are looking for a ready-to-use solution with commercial
547-# garantees and support are strongly adviced to contract a Free Software
548-# Service Company
549-#
550-# This program is Free Software; you can redistribute it and/or
551-# modify it under the terms of the GNU General Public License
552-# as published by the Free Software Foundation; either version 2
553-# of the License, or (at your option) any later version.
554-#
555-# This program is distributed in the hope that it will be useful,
556-# but WITHOUT ANY WARRANTY; without even the implied warranty of
557-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
558-# GNU General Public License for more details.
559-#
560-# You should have received a copy of the GNU General Public License
561-# along with this program; if not, write to the Free Software
562-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
563-#
564-##############################################################################
565-
566 {
567- "name" : "Project and Timesheet Department Categorization",
568- "version" : "1.0",
569- "author" : "Camptocamp",
570- "category" : "Generic Modules/Projects & Services",
571- "description":
572-"""
573- Add the department on Project and Timesheet (hr.analytic.timesheet) as well as the related filter and button in the search form of
574- both object.
575-
576+ "name": "Project Department Categorization",
577+ "version": "1.0",
578+ "author": "Camptocamp, Daniel Reis",
579+ "license": "AGPL-3",
580+ "category": "Generic Modules/Projects & Services",
581+ "description": """\
582+Add Department to Projects and to corresponding tree, search and form views.
583 """,
584 "website": "http://camptocamp.com",
585- "depends" : [
586- "hr_timesheet",
587- "project",
588- "analytic_department",
589- ],
590- "init_xml" : [],
591- "demo_xml" : [],
592- "update_xml" : [
593- "project_view.xml",
594- ],
595- "active": False,
596- 'installable': False
597+ "depends": ["project", "analytic_department"],
598+ "data": ["project_view.xml"],
599+ "auto_install": True,
600 }
601
602=== removed directory 'project_department/i18n'
603=== modified file 'project_department/project_view.xml'
604--- project_department/project_view.xml 2011-08-12 12:53:16 +0000
605+++ project_department/project_view.xml 2013-02-28 12:30:30 +0000
606@@ -1,87 +1,46 @@
607-<openerp>
608- <data>
609-
610- <record id="edit_project" model="ir.ui.view">
611- <field name="name">project.project.form</field>
612- <field name="model">project.project</field>
613- <field name="inherit_id" ref="project.edit_project" />
614- <field name="type">form</field>
615- <field name="arch" type="xml">
616- <xpath expr="/form/notebook/page/group/field[@name='company_id']" position="after">
617- <field name="department_id" widget="selection"/>
618- </xpath>
619- </field>
620- </record>
621-
622- <record id="view_project_project_filter" model="ir.ui.view">
623- <field name="name">project.project.select</field>
624- <field name="model">project.project</field>
625- <field name="inherit_id" ref="project.view_project_project_filter" />
626- <field name="type">search</field>
627- <field name="arch" type="xml">
628- <xpath expr="/search/group/field[@name='partner_id']" position="before">
629- <field name="department_id" widget="selection" />
630- </xpath>
631- <xpath expr="/search/group/filter[@string='Manager']" position="after">
632- <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
633- </xpath>
634- </field>
635- </record>
636-
637- <record id="view_project" model="ir.ui.view">
638- <field name="name">project.project.tree</field>
639- <field name="model">project.project</field>
640- <field name="inherit_id" ref="project.view_project" />
641- <field name="type">tree</field>
642- <field name="field_parent">child_ids</field>
643- <field name="arch" type="xml">
644- <xpath expr="/tree/field[@name='user_id']" position="after">
645- <field name="department_id" />
646- </xpath>
647- </field>
648- </record>
649-
650-
651- <record id="hr_timesheet_line_tree" model="ir.ui.view">
652- <field name="name">hr.analytic.timesheet.tree</field>
653- <field name="model">hr.analytic.timesheet</field>
654- <field name="type">tree</field>
655- <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_tree" />
656- <field name="arch" type="xml">
657- <xpath expr="/tree/field[@name='user_id']" position="after">
658- <field name="department_id" />
659- </xpath>
660- </field>
661- </record>
662- <record id="hr_timesheet_line_form" model="ir.ui.view">
663- <field name="name">hr.analytic.timesheet.form</field>
664- <field name="model">hr.analytic.timesheet</field>
665- <field name="type">form</field>
666- <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_form" />
667- <field name="arch" type="xml">
668- <xpath expr="/form/group/field[@name='user_id']" position="after">
669- <field name="department_id" widget="selection"/>
670- </xpath>
671- </field>
672- </record>
673-
674- <record id="hr_timesheet_line_search" model="ir.ui.view">
675- <field name="name">hr.analytic.timesheet.search</field>
676- <field name="model">hr.analytic.timesheet</field>
677- <field name="type">search</field>
678- <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_search" />
679- <field name="arch" type="xml">
680- <xpath expr="/search/group/field[@name='user_id']" position="after">
681- <field name="department_id" widget="selection" />
682- </xpath>
683- <xpath expr="/search/group/filter[@string='Users']" position="after">
684- <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
685- </xpath>
686- </field>
687-
688- </record>
689-
690-
691-
692- </data>
693-</openerp>
694\ No newline at end of file
695+<openerp>
696+ <data>
697+
698+ <record id="edit_project" model="ir.ui.view">
699+ <field name="name">project.project.form</field>
700+ <field name="model">project.project</field>
701+ <field name="inherit_id" ref="project.edit_project"/>
702+ <field name="type">form</field>
703+ <field name="arch" type="xml">
704+ <field name="partner_id" position="after">
705+ <field name="department_id"/>
706+ </field>
707+ </field>
708+ </record>
709+
710+ <record id="view_project_project_filter" model="ir.ui.view">
711+ <field name="name">project.project.select</field>
712+ <field name="model">project.project</field>
713+ <field name="inherit_id" ref="project.view_project_project_filter"/>
714+ <field name="type">search</field>
715+ <field name="arch" type="xml">
716+ <field name="partner_id" position="before">
717+ <field name="department_id"/>
718+ </field>
719+ <xpath expr="/search/group/filter[@string='Manager']" position="after">
720+ <filter string="Department" icon="terp-folder-orange" domain="[]" context="{'group_by':'department_id'}"/>
721+ </xpath>
722+ </field>
723+ </record>
724+
725+ <record id="view_project" model="ir.ui.view">
726+ <field name="name">project.project.tree</field>
727+ <field name="model">project.project</field>
728+ <field name="inherit_id" ref="project.view_project"/>
729+ <field name="type">tree</field>
730+ <field name="field_parent">child_ids</field>
731+ <field name="arch" type="xml">
732+ <field name="user_id" position="after">
733+ <field name="department_id"/>
734+ </field>
735+ </field>
736+ </record>
737+
738+ </data>
739+</openerp>
740+
741
742=== removed directory 'project_department/security'

Subscribers

People subscribed via source and target branches