[FIX] account_voucher: VAT warning

VAT error shouldn't be displayed as it doesn't look deep enough for information.
It is better to raise this kind of exception at the creation of a VAT than at its use.

opw:631769
This commit is contained in:
Goffin Simon 2015-04-10 10:37:54 +02:00
parent 8ac8281a7f
commit a41d8ef937
1 changed files with 0 additions and 5 deletions

View File

@ -1237,11 +1237,6 @@ class account_voucher(osv.osv):
'account_tax_id': voucher.tax_id.id,
})
if move_line.get('account_tax_id', False):
tax_data = tax_obj.browse(cr, uid, [move_line['account_tax_id']], context=context)[0]
if not (tax_data.base_code_id and tax_data.tax_code_id):
raise osv.except_osv(_('No Account Base Code and Account Tax Code!'),_("You have to configure account base code and account tax code on the '%s' tax!") % (tax_data.name))
# compute the amount in foreign currency
foreign_currency_diff = 0.0
amount_currency = False