1
0
Fork 0

Set receivable_bank_account manual when create a party

Proteus not set owners and is required to find a party and set default bank accounts
This commit is contained in:
Raimon Esteve 2022-12-02 14:09:56 +01:00
parent e3b56c4a8f
commit 071e38764e
1 changed files with 8 additions and 8 deletions

View File

@ -91,16 +91,9 @@ Create payment type::
>>> both = PaymentType(name='Both', kind='both')
>>> both.save()
Create party::
>>> Party = Model.get('party.party')
>>> party = Party(name='Party')
>>> party.customer_payment_type = receivable
>>> party.supplier_payment_type = payable
>>> party.save()
Create bank account::
>>> Party = Model.get('party.party')
>>> Bank = Model.get('bank')
>>> BankAccount = Model.get('bank.account')
>>> BankNumber = Model.get('bank.account.number')
@ -118,7 +111,14 @@ Create bank account::
>>> bank_number.type = 'other'
>>> bank_number.number = 'not IBAN'
>>> bank_account.save()
Create party::
>>> party = Party(name='Party')
>>> party.customer_payment_type = receivable
>>> party.supplier_payment_type = payable
>>> party.bank_accounts.append(bank_account)
>>> party.receivable_bank_account = bank_account
>>> party.save()
Sale with payment type payable::