Merge lp:~vauxoo/addons-vauxoo/account_tax_category_dev_carlos into lp:addons-vauxoo

Proposed by Juan Carlos Hernandez
Status: Rejected
Rejected by: Moisés López - http://www.vauxoo.com
Proposed branch: lp:~vauxoo/addons-vauxoo/account_tax_category_dev_carlos
Merge into: lp:addons-vauxoo
Diff against target: 310 lines (+273/-0)
7 files modified
account_tax_category/__init__.py (+24/-0)
account_tax_category/__openerp__.py (+47/-0)
account_tax_category/account_tax_category.py (+51/-0)
account_tax_category/account_tax_category_view.xml (+77/-0)
account_tax_category/data/account_tax_category.xml (+57/-0)
account_tax_category/security/account_tax_category_security.xml (+14/-0)
account_tax_category/security/ir.model.access.csv (+3/-0)
To merge this branch: bzr merge lp:~vauxoo/addons-vauxoo/account_tax_category_dev_carlos
Reviewer Review Type Date Requested Status
Moisés López - http://www.vauxoo.com Pending
Review via email: mp+117150@code.launchpad.net

Description of the change

SE creo modulo account_tax_category

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

Esto va a la l10n_mx

Unmerged revisions

357. By Juan Carlos Hernandez

[IMP][account_tax_category] add rule of access

356. By Juan Carlos Hernandez

[ADD][account_tax_category] add group and data

355. By Juan Carlos Hernandez

[ADD][account_tax_category] add data

354. By Juan Carlos Hernandez

[ADD][account_tax_category] add security

353. By Juan Carlos Hernandez

[ADD][account_tax_category]add module account_tax_category

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added directory 'account_tax_category'
2=== added file 'account_tax_category/__init__.py'
3--- account_tax_category/__init__.py 1970-01-01 00:00:00 +0000
4+++ account_tax_category/__init__.py 2012-07-28 00:16:19 +0000
5@@ -0,0 +1,24 @@
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: carlos(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+
29+import account_tax_category
30
31=== added file 'account_tax_category/__openerp__.py'
32--- account_tax_category/__openerp__.py 1970-01-01 00:00:00 +0000
33+++ account_tax_category/__openerp__.py 2012-07-28 00:16:19 +0000
34@@ -0,0 +1,47 @@
35+#!/usr/bin/python
36+# -*- encoding: utf-8 -*-
37+###########################################################################
38+# Module Writen to OpenERP, Open Source Management Solution
39+# Copyright (C) Vauxoo (<http://vauxoo.com>).
40+# All Rights Reserved
41+###############Credits######################################################
42+# Coded by: carlos(juan@vauxoo.com)
43+#############################################################################
44+# This program is free software: you can redistribute it and/or modify
45+# it under the terms of the GNU Affero General Public License as published by
46+# the Free Software Foundation, either version 3 of the License, or
47+# (at your option) any later version.
48+#
49+# This program is distributed in the hope that it will be useful,
50+# but WITHOUT ANY WARRANTY; without even the implied warranty of
51+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
52+# GNU Affero General Public License for more details.
53+#
54+# You should have received a copy of the GNU Affero General Public License
55+# along with this program. If not, see <http://www.gnu.org/licenses/>.
56+################################################################################
57+{
58+ "name" : "Add category to taxes",
59+ "version" : "1.0",
60+ "depends" : ["account"],
61+ "author" : "Vauxoo",
62+ "license" : "AGPL-3",
63+ "description" : """This module add to the taxes category
64+ """,
65+ "website" : "http://vauxoo.com",
66+ "category" : "Generic Modules",
67+ "init_xml" : [],
68+ "demo_xml" : [],
69+ "test": [],
70+ "update_xml" : [
71+ 'security/account_tax_category_security.xml',
72+ 'security/ir.model.access.csv',
73+ 'account_tax_category_view.xml',
74+ 'data/account_tax_category.xml'
75+
76+
77+ ],
78+ "active": False,
79+ "installable": True,
80+}
81+
82
83=== added file 'account_tax_category/account_tax_category.py'
84--- account_tax_category/account_tax_category.py 1970-01-01 00:00:00 +0000
85+++ account_tax_category/account_tax_category.py 2012-07-28 00:16:19 +0000
86@@ -0,0 +1,51 @@
87+#!/usr/bin/python
88+# -*- encoding: utf-8 -*-
89+###########################################################################
90+# Module Writen to OpenERP, Open Source Management Solution
91+# Copyright (C) Vauxoo (<http://vauxoo.com>).
92+# All Rights Reserved
93+###############Credits######################################################
94+# Coded by: Carlos Funes(juan@vauxoo.com)
95+#############################################################################
96+# This program is free software: you can redistribute it and/or modify
97+# it under the terms of the GNU Affero General Public License as published by
98+# the Free Software Foundation, either version 3 of the License, or
99+# (at your option) any later version.
100+#
101+# This program is distributed in the hope that it will be useful,
102+# but WITHOUT ANY WARRANTY; without even the implied warranty of
103+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
104+# GNU Affero General Public License for more details.
105+#
106+# You should have received a copy of the GNU Affero General Public License
107+# along with this program. If not, see <http://www.gnu.org/licenses/>.
108+################################################################################
109+from osv import fields, osv, orm
110+
111+class account_tax_category(osv.osv):
112+ _name='account.tax.category'
113+
114+ _columns = {
115+ 'name': fields.char('Name', size=64, required=True),
116+ 'code': fields.char('Code', size=32, required=True),
117+ 'active': fields.boolean('Active'),
118+ 'sign': fields.integer('Sign'),
119+ 'category_ids': fields.one2many('account.tax', 'acc_tax_tagetory_id', 'Category'),
120+
121+ }
122+
123+ _defaults = {
124+ 'active': 1,
125+ #'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'account.account', context=c),
126+ }
127+
128+account_tax_category()
129+
130+class account_tax(osv.osv):
131+ _inherit = 'account.tax'
132+
133+ _columns = {
134+ 'acc_tax_tagetory_id': fields.many2one('account.tax.category','Tax Category',required=False),
135+ }
136+
137+account_tax()
138
139=== added file 'account_tax_category/account_tax_category_view.xml'
140--- account_tax_category/account_tax_category_view.xml 1970-01-01 00:00:00 +0000
141+++ account_tax_category/account_tax_category_view.xml 2012-07-28 00:16:19 +0000
142@@ -0,0 +1,77 @@
143+<?xml version="1.0" encoding="utf-8"?>
144+<openerp>
145+ <data>
146+ <record id="view_account_tax_category_form" model="ir.ui.view">
147+ <field name="name">view.account.tax.category.form</field>
148+ <field name="model">account.tax.category</field>
149+ <field name="type">form</field>
150+ <field name="arch" type="xml">
151+ <form string="Categories">
152+ <separator string="Categories" colspan="4"/>
153+ <field name="name" colspan="4"/>
154+ <newline/>
155+ <field name="code" colspan="4"/>
156+ <newline/>
157+ <field name="active"/>
158+ <newline/>
159+ <field name="sign" colspan="4"/>
160+ </form>
161+ </field>
162+ </record>
163+
164+
165+ <record id="view_account_tax_category_tree" model="ir.ui.view">
166+ <field name="name">view.account.tax.category.tree</field>
167+ <field name="model">account.tax.category</field>
168+ <field name="type">tree</field>
169+ <field name="arch" type="xml">
170+ <tree string="Categories">
171+ <field name="name" />
172+ <field name="code" />
173+ <field name="active"/>
174+ <field name="sign" />
175+ </tree>
176+ </field>
177+ </record>
178+
179+ <record id="action_account_tax_category_tree" model="ir.actions.act_window">
180+ <field name="name">Tax Category</field>
181+ <field name="res_model">account.tax.category</field>
182+ <field name="type">ir.actions.act_window</field>
183+ <field name="view_type">form</field>
184+ <field name="view_id" ref="view_account_tax_category_tree"/>
185+ </record>
186+
187+ <menuitem action="action_account_tax_category_tree"
188+ id="menu_account_tax_category" sequence="50"
189+ parent="account.next_id_27"
190+ />
191+
192+ <record id="view_account_tax_category_search" model="ir.ui.view">
193+ <field name="name">view.account.tax.category.search</field>
194+ <field name="model">account.tax.category</field>
195+ <field name="type">search</field>
196+ <field name="arch" type="xml">
197+ <search string="Categories">
198+ <filter string="Inactive" icon="terp-personal+" domain="[('active','=',False)]"/>
199+ <field name="name"/>
200+ <field name="code"/>
201+ </search>
202+ </field>
203+ </record>
204+
205+
206+ <record model="ir.ui.view" id="view_account_tax_category_form_inh">
207+ <field name="name">view.account.tax.category.form.inh</field>
208+ <field name="inherit_id" ref="account.view_tax_form"/>
209+ <field name="model">account.tax</field>
210+ <field name="type">form</field>
211+ <field name="arch" type="xml">
212+ <xpath expr='/form[@string="Account Tax"]/group/field[@name="company_id"]' position="after">
213+ <field name='acc_tax_tagetory_id' widget="selection"/>
214+ </xpath>
215+ </field>
216+ </record>
217+
218+ </data>
219+</openerp>
220
221=== added directory 'account_tax_category/data'
222=== added file 'account_tax_category/data/account_tax_category.xml'
223--- account_tax_category/data/account_tax_category.xml 1970-01-01 00:00:00 +0000
224+++ account_tax_category/data/account_tax_category.xml 2012-07-28 00:16:19 +0000
225@@ -0,0 +1,57 @@
226+<?xml version="1.0" ?>
227+<openerp>
228+ <data noupdate="1">
229+ <record id="tax_category_iva_ret" model="account.tax.category">
230+ <field name="name">IVA-RET</field>
231+ <field name="code">IVA</field>
232+ <field name="active">1</field>
233+ <field name="sign">-1</field>
234+ </record>
235+ </data>
236+
237+ <data>
238+ <record id="tax_category_iva" model="account.tax.category">
239+ <field name="name">IVA</field>
240+ <field name="code">IVA</field>
241+ <field name="active">1</field>
242+ <field name="sign">1</field>
243+ </record>
244+ </data>
245+
246+ <data>
247+ <record id="tax_category_isr" model="account.tax.category">
248+ <field name="name">ISR</field>
249+ <field name="code">ISR</field>
250+ <field name="active">1</field>
251+ <field name="sign">1</field>
252+ </record>
253+ </data>
254+
255+ <data>
256+ <record id="tax_category_isr_ret" model="account.tax.category">
257+ <field name="name">ISR-RET</field>
258+ <field name="code">ISR</field>
259+ <field name="active">1</field>
260+ <field name="sign">-1</field>
261+ </record>
262+ </data>
263+
264+ <data>
265+ <record id="tax_category_ieps" model="account.tax.category">
266+ <field name="name">IEPS</field>
267+ <field name="code">IEPS</field>
268+ <field name="active">1</field>
269+ <field name="sign">1</field>
270+ </record>
271+ </data>
272+
273+ <data>
274+ <record id="tax_category_ietu" model="account.tax.category">
275+ <field name="name">IETU</field>
276+ <field name="code">IETU</field>
277+ <field name="active">1</field>
278+ <field name="sign">1</field>
279+ </record>
280+ </data>
281+
282+</openerp>
283
284=== added directory 'account_tax_category/security'
285=== added file 'account_tax_category/security/account_tax_category_security.xml'
286--- account_tax_category/security/account_tax_category_security.xml 1970-01-01 00:00:00 +0000
287+++ account_tax_category/security/account_tax_category_security.xml 2012-07-28 00:16:19 +0000
288@@ -0,0 +1,14 @@
289+<?xml version="1.0" encoding="utf-8"?>
290+<openerp>
291+ <data>
292+
293+ <record model="res.groups" id="group_account_tax_category_manager">
294+ <field name="name">Account Tax Category / Manager</field>
295+ </record>
296+
297+ <record model="res.groups" id="group_account_tax_category_user">
298+ <field name="name">Account Tax Category / User</field>
299+ </record>
300+
301+ </data>
302+</openerp>
303
304=== added file 'account_tax_category/security/ir.model.access.csv'
305--- account_tax_category/security/ir.model.access.csv 1970-01-01 00:00:00 +0000
306+++ account_tax_category/security/ir.model.access.csv 2012-07-28 00:16:19 +0000
307@@ -0,0 +1,3 @@
308+id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
309+access_account_tax_category_manager,account.tax.category.manager,model_account_tax_category,,1,1,1,1
310+access_account_tax_category_user,account.tax.category.user,model_account_tax_category,,1,0,0,0