[IMP] account_loan: add multi-company ir_rule for 'account_loan_line'
This commit is contained in:
parent
dedd873814
commit
458f4d5d40
@ -26,7 +26,10 @@ class AccountLoanLine(models.Model):
|
||||
ondelete="cascade",
|
||||
)
|
||||
company_id = fields.Many2one(
|
||||
"res.company", readonly=True, related="loan_id.company_id"
|
||||
"res.company",
|
||||
readonly=True,
|
||||
related="loan_id.company_id",
|
||||
store=True,
|
||||
)
|
||||
partner_id = fields.Many2one(
|
||||
"res.partner", readonly=True, related="loan_id.partner_id"
|
||||
|
@ -8,4 +8,13 @@
|
||||
['|',('company_id','=',False),('company_id','in',company_ids)]
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="account_loan_line_multi_company_rule" model="ir.rule">
|
||||
<field name="name">Account loan line multi-company</field>
|
||||
<field ref="model_account_loan_line" name="model_id" />
|
||||
<field eval="True" name="global" />
|
||||
<field name="domain_force">
|
||||
['|',('company_id','=',False),('company_id','in',company_ids)]
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
|
Loading…
Reference in New Issue
Block a user