Post move when posting sale point transfer

Closes #12563
This commit is contained in:
Sergi Almacellas Abellana
2023-10-07 19:55:15 +02:00
parent 81c3d0c95c
commit b5ae87d422
2 changed files with 3 additions and 2 deletions
+1
View File
@@ -1285,6 +1285,7 @@ class POSCashTransfer(Workflow, ModelSQL, ModelView):
transfer.move = move
moves.append(move)
Move.save(moves)
Move.post(moves)
cls.save(transfers)
def get_move(self, account):
@@ -129,8 +129,8 @@ Create an initial cash session::
>>> transfer, = session.transfers
>>> transfer.state
'posted'
>>> bool(transfer.move)
True
>>> transfer.move.state
'posted'
>>> accounts['bank'].reload()
>>> accounts['bank'].balance
Decimal('-100.00')