Merge lp:~vauxoo/openerp-venezuela-localization/miguel-url-seniat into lp:~openerp-venezuela/openerp-venezuela-localization/6.0-trunk

Proposed by Miguel Delgado (Vauxoo)
Status: Merged
Merged at revision: 427
Proposed branch: lp:~vauxoo/openerp-venezuela-localization/miguel-url-seniat
Merge into: lp:~openerp-venezuela/openerp-venezuela-localization/6.0-trunk
Diff against target: 123 lines (+75/-6)
5 files modified
l10n_ve_fiscal_requirements/__init__.py (+1/-0)
l10n_ve_fiscal_requirements/__openerp__.py (+1/-0)
l10n_ve_fiscal_requirements/res_company.py (+0/-6)
l10n_ve_fiscal_requirements/seniat_url.py (+44/-0)
l10n_ve_fiscal_requirements/view/seniat_url_view.xml (+29/-0)
To merge this branch: bzr merge lp:~vauxoo/openerp-venezuela-localization/miguel-url-seniat
Reviewer Review Type Date Requested Status
Israel Fermin Montilla Pending
Review via email: mp+78642@code.launchpad.net

Description of the change

[ADD] a new module to load the Seniat from URL for no dependency from a particular company if the URL change

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'l10n_ve_fiscal_requirements/__init__.py'
2--- l10n_ve_fiscal_requirements/__init__.py 2011-10-03 23:31:07 +0000
3+++ l10n_ve_fiscal_requirements/__init__.py 2011-10-07 17:17:27 +0000
4@@ -21,6 +21,7 @@
5 import invoice
6 import partner
7 import res_company
8+import seniat_url
9 import l10n_ut
10 import wizard
11 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
12
13=== modified file 'l10n_ve_fiscal_requirements/__openerp__.py'
14--- l10n_ve_fiscal_requirements/__openerp__.py 2011-10-06 15:10:28 +0000
15+++ l10n_ve_fiscal_requirements/__openerp__.py 2011-10-07 17:17:27 +0000
16@@ -55,6 +55,7 @@
17 'view/res_company_view.xml',
18 'view/l10n_ut_view.xml',
19 'view/partner_view.xml',
20+ 'view/seniat_url_view.xml',
21 'wizard/wizard_invoice_nro_ctrl_view.xml',
22 'wizard/wizard_nro_ctrl_view.xml',
23 ],
24
25=== modified file 'l10n_ve_fiscal_requirements/res_company.py'
26--- l10n_ve_fiscal_requirements/res_company.py 2011-10-06 17:08:59 +0000
27+++ l10n_ve_fiscal_requirements/res_company.py 2011-10-07 17:17:27 +0000
28@@ -36,12 +36,6 @@
29 _columns = {
30 'jour_id': fields.many2one('account.journal', 'Journal',required=False,help="Default journal for damaged invoices"),
31 'acc_id': fields.many2one('account.account', 'Account',required=False,help="Default account used for invoices and lines from damaged invoices"),
32- 'url_seniat1_company':fields.char('URL Seniat for Partner Information',size=64, required=True, readonly=False,help='In this field enter the URL from Seniat for search the fiscal information from partner'),
33- 'url_seniat2_company':fields.char('URL Seniat for Retention Rate',size=64, required=True, readonly=False,help='In this field enter the URL from Seniat for search the retention rate from partner'),
34 }
35- _defaults = {
36- 'url_seniat1_company':'http://contribuyente.seniat.gob.ve/getContribuyente/getrif?rif=',
37- 'url_seniat2_company':'http://contribuyente.seniat.gob.ve/BuscaRif/BuscaRif.jsp?p_rif=',
38- }
39 res_company()
40
41
42=== added file 'l10n_ve_fiscal_requirements/seniat_url.py'
43--- l10n_ve_fiscal_requirements/seniat_url.py 1970-01-01 00:00:00 +0000
44+++ l10n_ve_fiscal_requirements/seniat_url.py 2011-10-07 17:17:27 +0000
45@@ -0,0 +1,44 @@
46+#!/usr/bin/python
47+# -*- encoding: utf-8 -*-
48+###########################################################################
49+# Module Writen to OpenERP, Open Source Management Solution
50+# Copyright (C) OpenERP Venezuela (<http://openerp.com.ve>).
51+# All Rights Reserved
52+###############Credits######################################################
53+# Coded by: Miguel Delgado <miguel@openerp.com.ve>
54+#############################################################################
55+# This program is free software: you can redistribute it and/or modify
56+# it under the terms of the GNU General Public License as published by
57+# the Free Software Foundation, either version 3 of the License, or
58+# (at your option) any later version.
59+#
60+# This program is distributed in the hope that it will be useful,
61+# but WITHOUT ANY WARRANTY; without even the implied warranty of
62+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
63+# GNU General Public License for more details.
64+#
65+# You should have received a copy of the GNU General Public License
66+# along with this program. If not, see <http://www.gnu.org/licenses/>.
67+##############################################################################
68+
69+from osv import fields, osv
70+import tools
71+from tools.translate import _
72+from tools import config
73+
74+class seniat_url(osv.osv):
75+ """
76+ OpenERP Model : seniat_url
77+ """
78+
79+ _name = 'seniat.url'
80+ _description = __doc__
81+ _columns = {
82+ 'url_seniat1_company':fields.char('URL Seniat for Partner Information',size=64, required=True, readonly=False,help='In this field enter the URL from Seniat for search the fiscal information from partner'),
83+ 'url_seniat2_company':fields.char('URL Seniat for Retention Rate',size=64, required=True, readonly=False,help='In this field enter the URL from Seniat for search the retention rate from partner'),
84+ }
85+ _defaults = {
86+ 'url_seniat1_company':'http://contribuyente.seniat.gob.ve/getContribuyente/getrif?rif=',
87+ 'url_seniat2_company':'http://contribuyente.seniat.gob.ve/BuscaRif/BuscaRif.jsp?p_rif=',
88+ }
89+seniat_url()
90
91=== added file 'l10n_ve_fiscal_requirements/view/seniat_url_view.xml'
92--- l10n_ve_fiscal_requirements/view/seniat_url_view.xml 1970-01-01 00:00:00 +0000
93+++ l10n_ve_fiscal_requirements/view/seniat_url_view.xml 2011-10-07 17:17:27 +0000
94@@ -0,0 +1,29 @@
95+<?xml version="1.0"?>
96+<openerp>
97+ <data>
98+
99+ <record id="view_seniat_url_form" model="ir.ui.view">
100+ <field name="name">seniat.url.form</field>
101+ <field name="model">seniat.url</field>
102+ <field name="type">form</field>
103+ <field name="arch" type="xml">
104+ <form string="Seniat URL">
105+ <field name="url_seniat1_company"/>
106+ <field name="url_seniat2_company"/>
107+ </form>
108+ </field>
109+ </record>
110+
111+ <record id="action_seniat_url" model="ir.actions.act_window">
112+ <field name="name">Seniat URL</field>
113+ <field name="type">ir.actions.act_window</field>
114+ <field name="res_model">seniat.url</field>
115+ <field name="view_type">form</field>
116+ <field name="view_mode">form,form</field>
117+ <field name="view_id" ref="view_seniat_url_form"/>
118+ </record>
119+
120+ <menuitem action="action_seniat_url" string="Seniat URL" id="seniat_url_menu" parent="base.menu_res_company_global"/>
121+
122+ </data>
123+</openerp>