[REF] account_voucher: code cleaning
bzr revid: qdp-launchpad@tinyerp.com-20100921111945-dij9cmqegah9h9tx
This commit is contained in:
@@ -819,10 +819,7 @@ class account_bank_statement(osv.osv):
|
||||
def create_move_from_st_line(self, cr, uid, st_line_id, company_currency_id, next_number, context=None):
|
||||
st_line = self.pool.get('account.bank.statement.line').browse(cr, uid, st_line_id, context=context)
|
||||
if st_line.voucher_id:
|
||||
res = self.pool.get('account.voucher').proforma_voucher(cr, uid, [st_line.voucher_id.id], context={'force_name': next_number})
|
||||
#force refresh of the cache
|
||||
#st_line = self.pool.get('account.bank.statement.line').browse(cr, uid, st_line.id, context=context)
|
||||
|
||||
self.pool.get('account.voucher').proforma_voucher(cr, uid, [st_line.voucher_id.id], context={'force_name': next_number})
|
||||
return self.pool.get('account.move.line').write(cr, uid, [x.id for x in st_line.voucher_id.move_ids], {'statement_id': st_line.statement_id.id}, context=context)
|
||||
return super(account_bank_statement, self).create_move_from_st_line(cr, uid, st_line, company_currency_id, next_number, context=context)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user