Search default chart of account properties only for the company
issue10924 review375901002 (grafted from 54994e1bdde91e324ab05d3b24715510c1549a89) --HG-- branch : 6.0
This commit is contained in:
1 parent
b042c699dd
commit
1bc1474843
2 files changed
+13
No files matched your search
@@ -2822,9 +2822,11 @@ class CreateChart(Wizard):
|
||||
|
||||
receivable_accounts = Account.search([
|
||||
('type.receivable', '=', True),
|
||||
('company', '=', self.account.company.id),
|
||||
], limit=2)
|
||||
payable_accounts = Account.search([
|
||||
('type.payable', '=', True),
|
||||
('company', '=', self.account.company.id),
|
||||
], limit=2)
|
||||
|
||||
if len(receivable_accounts) == 1:
|
||||
|
||||
@@ -205,6 +205,17 @@ class AccountTestCase(
|
||||
update_chart.start.account = root
|
||||
update_chart.transition_update()
|
||||
|
||||
@with_transaction()
|
||||
def test_account_chart_many_companies(self):
|
||||
"Test creation of chart of accounts for many companies"
|
||||
company1 = create_company()
|
||||
with set_company(company1):
|
||||
create_chart(company1, tax=True)
|
||||
|
||||
company2 = create_company()
|
||||
with set_company(company2):
|
||||
create_chart(company2, tax=True)
|
||||
|
||||
@with_transaction()
|
||||
def test_fiscalyear(self):
|
||||
'Test fiscalyear'
|
||||
|
||||
Reference in new issue
Block a user