[IMP][account_banking_payment_transfer] Condider entry_posted flag on account_journal to post the move

This commit is contained in:
Adrien Peiffer (ACSONE)
2015-03-06 13:03:49 +01:00
parent 3469dc8f5b
commit 416c71f11b

View File

@@ -260,8 +260,10 @@ class PaymentOrder(models.Model):
total_amount, move, lines, labels)
aml_obj.create(trf_ml_vals)
# post account move
move.post()
# consider entry_posted on account_journal
if move.journal_id.entry_posted:
# post account move
move.post()
# State field is written by act_sent_wait
self.write({'date_sent': fields.Date.context_today(self)})