Skip to content

Commit

Permalink
[FIX] l10n_ve_withholding_src: Solved unittests issues
Browse files Browse the repository at this point in the history
  • Loading branch information
suniagajose committed Dec 17, 2015
1 parent f8cf7bc commit a479e79
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 10 deletions.
2 changes: 1 addition & 1 deletion l10n_ve_withholding_muni/__openerp__.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
'test/awm_customer.yml',
'test/awm_supplier.yml',
],
'data': [
'data': [
'security/wh_muni_security.xml',
'security/ir.model.access.csv',
'data/wh_muni_sequence.xml',
Expand Down
2 changes: 0 additions & 2 deletions l10n_ve_withholding_muni/model/invoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,6 @@ def _get_move_lines(self, cr, uid, ids, to_wh, period_id,
'in_refund': -1
}
direction = types[invoice.type]
print '====================== payable', acc_part_brw.property_wh_munici_payable
print ' ===================== receiva', acc_part_brw.property_wh_munici_receivable
if to_wh.retention_id.type == 'in_invoice':
acc = acc_part_brw.property_wh_munici_payable and \
acc_part_brw.property_wh_munici_payable.id or False
Expand Down
1 change: 0 additions & 1 deletion l10n_ve_withholding_src/model/invoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ def _get_move_lines(self, cr, uid, ids, to_wh, period_id,
'in_invoice': 1,
'out_refund': 1, 'in_refund': -1}
direction = types[invoice.type]

for tax_brw in to_wh:
acc = False
coll = tax_brw.wh_id.company_id.wh_src_collected_account_id
Expand Down
8 changes: 2 additions & 6 deletions l10n_ve_withholding_src/model/wh_src.py
Original file line number Diff line number Diff line change
Expand Up @@ -430,13 +430,9 @@ def action_move_create(self, cr, uid, ids, context=None):
""" Build account moves related to withholding invoice
"""
inv_obj = self.pool.get('account.invoice')
if context is None:
context = {}

dict(context).update({'wh_src': True})

context = dict(context or {})
context.update({'wh_src': True})
ret = self.browse(cr, uid, ids[0], context)

for line in ret.line_ids:
if line.move_id:
raise osv.except_osv(
Expand Down

0 comments on commit a479e79

Please sign in to comment.