[IMP] account: remove redundant domain.
Linked to the changes made in https://github.com/odoo/odoo/commit/26b2472f4977ccedbb0b5ed5f08be2c04313fd21 closes odoo/odoo#103944 X-original-commit: a9ec1b746bbbda779323caf43cb8bea3bedb1ad7 Signed-off-by: William André (wan) <wan@odoo.com>
This commit is contained in:
@@ -92,7 +92,6 @@ class AccountJournal(models.Model):
|
||||
help="Bank statements transactions will be posted on the suspense account until the final reconciliation "
|
||||
"allowing finding the right account.", string='Suspense Account',
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), \
|
||||
('account_type', 'not in', ('asset_receivable', 'liability_payable')), \
|
||||
('account_type', '=', 'asset_current')]")
|
||||
restrict_mode_hash_table = fields.Boolean(string="Lock Posted Entries with Hash",
|
||||
help="If ticked, the accounting entry or invoice receives a hash as soon as it is posted and cannot be modified anymore.")
|
||||
@@ -149,14 +148,12 @@ class AccountJournal(models.Model):
|
||||
help="Used to register a profit when the ending balance of a cash register differs from what the system computes",
|
||||
string='Profit Account',
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), \
|
||||
('account_type', 'not in', ('asset_receivable', 'liability_payable')), \
|
||||
('account_type', 'in', ('income', 'income_other'))]")
|
||||
loss_account_id = fields.Many2one(
|
||||
comodel_name='account.account', check_company=True,
|
||||
help="Used to register a loss when the ending balance of a cash register differs from what the system computes",
|
||||
string='Loss Account',
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), \
|
||||
('account_type', 'not in', ('asset_receivable', 'liability_payable')), \
|
||||
('account_type', '=', 'expense')]")
|
||||
|
||||
# Bank journals fields
|
||||
|
||||
@@ -83,12 +83,12 @@ class ResCompany(models.Model):
|
||||
income_currency_exchange_account_id = fields.Many2one(
|
||||
comodel_name='account.account',
|
||||
string="Gain Exchange Rate Account",
|
||||
domain="[('account_type', 'not in', ('asset_receivable','liability_payable','asset_cash', 'liability_credit_card')), ('deprecated', '=', False), ('company_id', '=', id), \
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', id), \
|
||||
('account_type', 'in', ('income', 'income_other'))]")
|
||||
expense_currency_exchange_account_id = fields.Many2one(
|
||||
comodel_name='account.account',
|
||||
string="Loss Exchange Rate Account",
|
||||
domain="[('account_type', 'not in', ('asset_receivable','liability_payable','asset_cash', 'liability_credit_card')), ('deprecated', '=', False), ('company_id', '=', id), \
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', id), \
|
||||
('account_type', '=', 'expense')]")
|
||||
anglo_saxon_accounting = fields.Boolean(string="Use anglo-saxon accounting")
|
||||
property_stock_account_input_categ_id = fields.Many2one('account.account', string="Input Account for Stock Valuation")
|
||||
|
||||
@@ -21,14 +21,14 @@ class ResConfigSettings(models.TransientModel):
|
||||
related="company_id.income_currency_exchange_account_id",
|
||||
string="Gain Account",
|
||||
readonly=False,
|
||||
domain="[('account_type', 'not in', ('asset_receivable','liability_payable','asset_cash','liability_credit_card')), ('deprecated', '=', False), ('company_id', '=', company_id),\
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id),\
|
||||
('account_type', 'in', ('income', 'income_other'))]")
|
||||
expense_currency_exchange_account_id = fields.Many2one(
|
||||
comodel_name="account.account",
|
||||
related="company_id.expense_currency_exchange_account_id",
|
||||
string="Loss Account",
|
||||
readonly=False,
|
||||
domain="[('account_type', 'not in', ('asset_receivable','liability_payable','asset_cash','liability_credit_card')), ('deprecated', '=', False), ('company_id', '=', company_id),\
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id),\
|
||||
('account_type', '=', 'expense')]")
|
||||
has_chart_of_accounts = fields.Boolean(compute='_compute_has_chart_of_accounts', string='Company has a chart of accounts')
|
||||
chart_template_id = fields.Many2one('account.chart.template', string='Template', default=lambda self: self.env.company.chart_template_id,
|
||||
@@ -42,7 +42,7 @@ class ResConfigSettings(models.TransientModel):
|
||||
string='Bank Suspense Account',
|
||||
readonly=False,
|
||||
related='company_id.account_journal_suspense_account_id',
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), ('account_type', 'not in', ('asset_receivable', 'liability_payable')), ('account_type', 'in', ('asset_current', 'liability_current'))]",
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), ('account_type', 'in', ('asset_current', 'liability_current'))]",
|
||||
help='Bank Transactions are posted immediately after import or synchronization. '
|
||||
'Their counterparty is the bank suspense account.\n'
|
||||
'Reconciliation replaces the latter by the definitive account(s).')
|
||||
@@ -51,7 +51,7 @@ class ResConfigSettings(models.TransientModel):
|
||||
string='Outstanding Receipts Account',
|
||||
readonly=False,
|
||||
related='company_id.account_journal_payment_debit_account_id',
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), ('account_type', 'not in', ('asset_receivable', 'liability_payable')), ('account_type', '=', 'asset_current')]",
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), ('account_type', '=', 'asset_current')]",
|
||||
help='Incoming payments are posted on an Outstanding Receipts Account. '
|
||||
'In the bank reconciliation widget, they appear as blue lines.\n'
|
||||
'Bank transactions are then reconciled on the Outstanding Receipts Accounts rather than the Receivable '
|
||||
@@ -61,7 +61,7 @@ class ResConfigSettings(models.TransientModel):
|
||||
string='Outstanding Payments Account',
|
||||
readonly=False,
|
||||
related='company_id.account_journal_payment_credit_account_id',
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), ('account_type', 'not in', ('asset_receivable', 'liability_payable')), ('account_type', '=', 'asset_current')]",
|
||||
domain="[('deprecated', '=', False), ('company_id', '=', company_id), ('account_type', '=', 'asset_current')]",
|
||||
help='Outgoing Payments are posted on an Outstanding Payments Account. '
|
||||
'In the bank reconciliation widget, they appear as blue lines.\n'
|
||||
'Bank transactions are then reconciled on the Outstanding Payments Account rather the Payable Account.')
|
||||
|
||||
Reference in New Issue
Block a user