[FIX] point_of_sale: properly unlink bank statements

Deleting of pos sessions wasn't possible before because
statement.unlink(context=context) doesn't work anymore.
This commit is contained in:
Joren Van Onder
2015-09-23 10:21:27 +02:00
parent f8877c16ab
commit 166289230b
+1 -2
View File
@@ -542,8 +542,7 @@ class pos_session(osv.osv):
def unlink(self, cr, uid, ids, context=None):
for obj in self.browse(cr, uid, ids, context=context):
for statement in obj.statement_ids:
statement.unlink(context=context)
self.pool.get('account.bank.statement').unlink(cr, uid, obj.statement_ids.ids, context=context)
return super(pos_session, self).unlink(cr, uid, ids, context=context)
def login(self, cr, uid, ids, context=None):