flake8
This commit is contained in:
parent
b5ca9344bb
commit
8cf103cf5c
@ -37,7 +37,9 @@ class test_account_partner_required(common.TransactionCase):
|
|||||||
|
|
||||||
def _create_move(self, with_partner, amount=100):
|
def _create_move(self, with_partner, amount=100):
|
||||||
date = datetime.now()
|
date = datetime.now()
|
||||||
period_id = self.registry('account.period').find(self.cr, self.uid, date, context={'account_period_prefer_normal': True})[0]
|
period_id = self.registry('account.period').find(
|
||||||
|
self.cr, self.uid, date,
|
||||||
|
context={'account_period_prefer_normal': True})[0]
|
||||||
move_vals = {
|
move_vals = {
|
||||||
'journal_id': self.ref('account.sales_journal'),
|
'journal_id': self.ref('account.sales_journal'),
|
||||||
'period_id': period_id,
|
'period_id': period_id,
|
||||||
@ -49,16 +51,15 @@ class test_account_partner_required(common.TransactionCase):
|
|||||||
'name': '/',
|
'name': '/',
|
||||||
'debit': 0,
|
'debit': 0,
|
||||||
'credit': amount,
|
'credit': amount,
|
||||||
'account_id': self.ref('account.a_sale'),
|
'account_id': self.ref('account.a_sale')})
|
||||||
})
|
move_line_id = self.move_line_obj.create(
|
||||||
move_line_id = self.move_line_obj.create(self.cr, self.uid,
|
self.cr, self.uid,
|
||||||
{'move_id': move_id,
|
{'move_id': move_id,
|
||||||
'name': '/',
|
'name': '/',
|
||||||
'debit': amount,
|
'debit': amount,
|
||||||
'credit': 0,
|
'credit': 0,
|
||||||
'account_id': self.ref('account.a_recv'),
|
'account_id': self.ref('account.a_recv'),
|
||||||
'partner_id': self.ref('base.res_partner_1') if with_partner else False,
|
'partner_id': self.ref('base.res_partner_1') if with_partner else False})
|
||||||
})
|
|
||||||
return move_line_id
|
return move_line_id
|
||||||
|
|
||||||
def _set_partner_policy(self, policy, aref='account.a_recv'):
|
def _set_partner_policy(self, policy, aref='account.a_recv'):
|
||||||
|
Loading…
Reference in New Issue
Block a user