Merge lp:~vauxoo/openerp-venezuela-localization/javy-islr-fact-cli into lp:~openerp-venezuela/openerp-venezuela-localization/6.0-trunk

Proposed by Javier Duran
Status: Merged
Merged at revision: 482
Proposed branch: lp:~vauxoo/openerp-venezuela-localization/javy-islr-fact-cli
Merge into: lp:~openerp-venezuela/openerp-venezuela-localization/6.0-trunk
Diff against target: 33 lines (+12/-1)
2 files modified
l10n_ve_withholding_islr/invoice.py (+11/-0)
l10n_ve_withholding_islr/workflow/account_workflow.xml (+1/-1)
To merge this branch: bzr merge lp:~vauxoo/openerp-venezuela-localization/javy-islr-fact-cli
Reviewer Review Type Date Requested Status
Javier Duran (community) Approve
Gabriela Quilarque Pending
Nhomar - Vauxoo Pending
Review via email: mp+83038@code.launchpad.net

Description of the change

Mejora en el flujo de trabajo de las retenciones de ISLR para generar el documento de retención solo a facturas de proveedores.

To post a comment you must log in.
Revision history for this message
Javier Duran (javieredm) wrote :

Merged en la localización:
revno:482
revision-id: javier@squezee-vir-20111122162601-s82dxa582gs7yb9z

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'l10n_ve_withholding_islr/invoice.py'
2--- l10n_ve_withholding_islr/invoice.py 2011-11-17 22:24:35 +0000
3+++ l10n_ve_withholding_islr/invoice.py 2011-11-22 15:49:23 +0000
4@@ -653,6 +653,17 @@
5
6 return True
7
8+ def check_invoice_type(self, cr, uid, ids, context=None):
9+ '''
10+ This method test the invoice types to create a new withholding document
11+ '''
12+ if context is None:
13+ context={}
14+ obj = self.browse(cr, uid, ids[0],context=context)
15+ if obj.type in ('in_invoice', 'in_refund'):
16+ return True
17+ return False
18+
19 account_invoice()
20
21
22
23=== modified file 'l10n_ve_withholding_islr/workflow/account_workflow.xml'
24--- l10n_ve_withholding_islr/workflow/account_workflow.xml 2011-10-31 08:24:34 +0000
25+++ l10n_ve_withholding_islr/workflow/account_workflow.xml 2011-11-22 15:49:23 +0000
26@@ -45,7 +45,7 @@
27 <record id="trans_wh_router_wh_islr" model="workflow.transition">
28 <field name="act_from" ref="l10n_ve_withholding.act_wh_router"/>
29 <field name="act_to" ref="act_islr_router"/>
30- <field name="condition">True</field>
31+ <field name="condition">check_invoice_type()</field>
32 <field name="signal"></field>
33 </record>
34