[FIX] Account : Wrong calculation for payment date corrected
bzr revid: jvo@tinyerp.com-20100601105022-2ifz2piufgu3r79v
This commit is contained in:
parent
40fd622559
commit
7470d1da1a
|
@ -530,9 +530,8 @@ class account_move_line(osv.osv):
|
|||
date = datetime.now().strftime('%Y-%m-%d')
|
||||
part = self.pool.get('res.partner').browse(cr, uid, partner_id)
|
||||
|
||||
if part.property_payment_term and part.property_payment_term.line_ids:
|
||||
payterm = part.property_payment_term.line_ids[0]
|
||||
res = self.pool.get('account.payment.term').compute(cr, uid, payterm.id, 100, date)
|
||||
if part.property_payment_term:
|
||||
res = self.pool.get('account.payment.term').compute(cr, uid, part.property_payment_term.id, 100, date)
|
||||
if res:
|
||||
val['date_maturity'] = res[0][0]
|
||||
if not account_id:
|
||||
|
|
Loading…
Reference in New Issue