Merge lp:~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos into lp:addons-vauxoo/6.1

Proposed by Juan Carlos Hernandez
Status: Merged
Merged at revision: 560
Proposed branch: lp:~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos
Merge into: lp:addons-vauxoo/6.1
Diff against target: 150 lines (+130/-0)
4 files modified
account_move_line_group_by_extend/__init__.py (+23/-0)
account_move_line_group_by_extend/__openerp__.py (+41/-0)
account_move_line_group_by_extend/account_move_line.py (+48/-0)
account_move_line_group_by_extend/account_move_line.xml (+18/-0)
To merge this branch: bzr merge lp:~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos
Reviewer Review Type Date Requested Status
Rodolfo Lopez Pending
Isaac López Zúñiga Pending
Moisés López - http://www.vauxoo.com Pending
Review via email: mp+131712@code.launchpad.net

Description of the change

Se agrupo por campo production_id y stock_move_id en account_move_line search y vista tree

To post a comment you must log in.
Revision history for this message
Moisés López - http://www.vauxoo.com (moylop260) wrote :
Download full text (8.8 KiB)

Aprobado
El 26/10/2012 19:24, "Juan Carlos Hernandez Funes" <email address hidden>
escribió:

> Juan Carlos Hernandez Funes has proposed merging
> lp:~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos
> into lp:addons-vauxoo/6.1.
>
> Requested reviews:
> Rodolfo Lopez - http://www.vauxoo.com (el-rodo-1)
> Isaac López Zúñiga - http://www.vauxoo.com (isaako34)
> Moisés López - http://www.vauxoo.com (moylop260)
>
> For more details, see:
>
> https://code.launchpad.net/~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos/+merge/131712
>
> Se agrupo por campo production_id y stock_move_id en account_move_line
> search y vista tree
> --
>
> https://code.launchpad.net/~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos/+merge/131712
> You are requested to review the proposed merge of
> lp:~vauxoo/addons-vauxoo/addons-vauxoo-6.1-group_production_stock_move_dev_carlos
> into lp:addons-vauxoo/6.1.
>
> === added directory 'account_move_line_group_by_extend'
> === added file 'account_move_line_group_by_extend/__init__.py'
> --- account_move_line_group_by_extend/__init__.py 1970-01-01
> 00:00:00 +0000
> +++ account_move_line_group_by_extend/__init__.py 2012-10-27
> 00:23:23 +0000
> @@ -0,0 +1,23 @@
> +#!/usr/bin/python
> +# -*- encoding: utf-8 -*-
>
> +###########################################################################
> +# Module Writen to OpenERP, Open Source Management Solution
> +# Copyright (C) Vauxoo (<http://vauxoo.com>).
> +# All Rights Reserved
>
> +###############Credits######################################################
> +# Coded by: Juan Carlos Funes(<email address hidden>)
>
> +#############################################################################
> +# This program is free software: you can redistribute it and/or modify
> +# it under the terms of the GNU Affero General Public License as
> published by
> +# the Free Software Foundation, either version 3 of the License, or
> +# (at your option) any later version.
> +#
> +# This program 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 Affero General Public License for more details.
> +#
> +# 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/
> >.
>
> +################################################################################
> +import account_move_line
>
> === added file 'account_move_line_group_by_extend/__openerp__.py'
> --- account_move_line_group_by_extend/__openerp__.py 1970-01-01
> 00:00:00 +0000
> +++ account_move_line_group_by_extend/__openerp__.py 2012-10-27
> 00:23:23 +0000
> @@ -0,0 +1,41 @@
> +#!/usr/bin/python
> +# -*- encoding: utf-8 -*-
>
> +###########################################################################
> +# Module Writen to OpenERP, Open Source Management Solution
> +# Copyright (C) Vauxoo (<http://vauxoo.com>).
> +# All Rights Reserved
>
> +###############Credit...

Read more...

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added directory 'account_move_line_group_by_extend'
2=== added file 'account_move_line_group_by_extend/__init__.py'
3--- account_move_line_group_by_extend/__init__.py 1970-01-01 00:00:00 +0000
4+++ account_move_line_group_by_extend/__init__.py 2012-10-27 00:23:23 +0000
5@@ -0,0 +1,23 @@
6+#!/usr/bin/python
7+# -*- encoding: utf-8 -*-
8+###########################################################################
9+# Module Writen to OpenERP, Open Source Management Solution
10+# Copyright (C) Vauxoo (<http://vauxoo.com>).
11+# All Rights Reserved
12+###############Credits######################################################
13+# Coded by: Juan Carlos Funes(juan@vauxoo.com)
14+#############################################################################
15+# This program is free software: you can redistribute it and/or modify
16+# it under the terms of the GNU Affero General Public License as published by
17+# the Free Software Foundation, either version 3 of the License, or
18+# (at your option) any later version.
19+#
20+# This program is distributed in the hope that it will be useful,
21+# but WITHOUT ANY WARRANTY; without even the implied warranty of
22+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23+# GNU Affero General Public License for more details.
24+#
25+# You should have received a copy of the GNU Affero General Public License
26+# along with this program. If not, see <http://www.gnu.org/licenses/>.
27+################################################################################
28+import account_move_line
29
30=== added file 'account_move_line_group_by_extend/__openerp__.py'
31--- account_move_line_group_by_extend/__openerp__.py 1970-01-01 00:00:00 +0000
32+++ account_move_line_group_by_extend/__openerp__.py 2012-10-27 00:23:23 +0000
33@@ -0,0 +1,41 @@
34+#!/usr/bin/python
35+# -*- encoding: utf-8 -*-
36+###########################################################################
37+# Module Writen to OpenERP, Open Source Management Solution
38+# Copyright (C) Vauxoo (<http://vauxoo.com>).
39+# All Rights Reserved
40+###############Credits######################################################
41+# Coded by: Juan Carlos Funes(juan@vauxoo.com)
42+#############################################################################
43+# This program is free software: you can redistribute it and/or modify
44+# it under the terms of the GNU Affero General Public License as published by
45+# the Free Software Foundation, either version 3 of the License, or
46+# (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 Affero General Public License for more details.
52+#
53+# You should have received a copy of the GNU Affero General Public License
54+# along with this program. If not, see <http://www.gnu.org/licenses/>.
55+################################################################################
56+{
57+ "name" : "Grouped by production and stock move in model account_move_line",
58+ "version" : "1.0",
59+ "depends" : ['account_relation_move'],
60+ "author" : "Vauxoo",
61+ #"license" : "AGPL-3",
62+ "description" : """Grouped by production and stock move in model account_move_line
63+ """,
64+ "website" : "http://vauxoo.com",
65+ "category" : "Generic Modules",
66+ "init_xml" : [],
67+ "demo_xml" : [],
68+ "test": [],
69+ "update_xml" : ['account_move_line.xml',
70+ ],
71+ "active": False,
72+ "installable": True,
73+}
74+
75
76=== added file 'account_move_line_group_by_extend/account_move_line.py'
77--- account_move_line_group_by_extend/account_move_line.py 1970-01-01 00:00:00 +0000
78+++ account_move_line_group_by_extend/account_move_line.py 2012-10-27 00:23:23 +0000
79@@ -0,0 +1,48 @@
80+#!/usr/bin/python
81+# -*- encoding: utf-8 -*-
82+###########################################################################
83+# Module Writen to OpenERP, Open Source Management Solution
84+# Copyright (C) Vauxoo (<http://vauxoo.com>).
85+# All Rights Reserved
86+###############Credits######################################################
87+# Coded by: Juan Carlos Funes(juan@vauxoo.com)
88+#############################################################################
89+# This program is free software: you can redistribute it and/or modify
90+# it under the terms of the GNU Affero General Public License as published by
91+# the Free Software Foundation, either version 3 of the License, or
92+# (at your option) any later version.
93+#
94+# This program is distributed in the hope that it will be useful,
95+# but WITHOUT ANY WARRANTY; without even the implied warranty of
96+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
97+# GNU Affero General Public License for more details.
98+#
99+# You should have received a copy of the GNU Affero General Public License
100+# along with this program. If not, see <http://www.gnu.org/licenses/>.
101+################################################################################
102+
103+from osv import osv, fields, orm
104+from lxml import etree
105+import tools
106+
107+class account_move_line(osv.osv):
108+ _inherit = 'account.move.line'
109+ _columns = {
110+
111+ }
112+
113+ def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
114+ result = super(account_move_line, self).fields_view_get(cr, uid, view_id, view_type, context=context, toolbar=toolbar, submenu=submenu)
115+ #fields_get = self.fields_get(cr, uid, ['stock_move_id'], context)
116+ xml_form = etree.fromstring(result['arch'])
117+ placeholder = xml_form.xpath("//field[@name='period_id']")
118+ placeholder[0].addnext(etree.Element('field', {'name': 'stock_move_id'}))
119+ placeholder[0].addnext(etree.Element('field', {'name': 'production_id'}))
120+ result['arch'] = etree.tostring(xml_form)
121+ result['fields'].update({
122+ 'stock_move_id':{'domain': [], 'string': u'Stock Move', 'readonly': False, 'relation': 'stock.move', 'context': {}, 'selectable': True, 'type': 'many2one', 'select': 2},
123+ 'production_id':{'domain': [], 'string': u'Production', 'readonly': False, 'relation': 'mrp.production', 'context': {}, 'selectable': True, 'type': 'many2one', 'select': 2}})
124+ return result
125+
126+account_move_line()
127+
128
129=== added file 'account_move_line_group_by_extend/account_move_line.xml'
130--- account_move_line_group_by_extend/account_move_line.xml 1970-01-01 00:00:00 +0000
131+++ account_move_line_group_by_extend/account_move_line.xml 2012-10-27 00:23:23 +0000
132@@ -0,0 +1,18 @@
133+<?xml version="1.0" encoding="utf-8"?>
134+<openerp>
135+ <data>
136+ <record id="view_account_move_line_group_production_stock_move" model="ir.ui.view">
137+ <field name="name">account.move.line.group.production.stock.move</field>
138+ <field name="model">account.move.line</field>
139+ <field name="type">search</field>
140+ <field name="inherit_id" ref="account.view_account_move_line_filter"/>
141+ <field name="arch" type="xml">
142+ <xpath expr="/search/group[@string='Group By...']/filter[@string='Period']" position="after">
143+ <filter string="Stock Move" icon="terp-stock" domain="[]" context="{'group_by':'stock_move_id'}"/>
144+ <filter string="Production" icon="terp-mrp" domain="[]" context="{'group_by':'production_id'}"/>
145+ </xpath>
146+ </field>
147+ </record>
148+
149+ </data>
150+</openerp>