[14.0][FIX] account_asset_management: pre-commit
This commit is contained in:
parent
69299744f2
commit
6d49df0ddf
@ -70,7 +70,10 @@ class AccountAssetLine(models.Model):
|
||||
"for which Odoo has not generated accounting entries.",
|
||||
)
|
||||
company_id = fields.Many2one(
|
||||
"res.company", store=True, readonly=True, related="asset_id.company_id",
|
||||
"res.company",
|
||||
store=True,
|
||||
readonly=True,
|
||||
related="asset_id.company_id",
|
||||
)
|
||||
|
||||
@api.depends("amount", "previous_id", "type")
|
||||
|
@ -152,10 +152,13 @@ class AccountMoveLine(models.Model):
|
||||
_inherit = "account.move.line"
|
||||
|
||||
asset_profile_id = fields.Many2one(
|
||||
comodel_name="account.asset.profile", string="Asset Profile",
|
||||
comodel_name="account.asset.profile",
|
||||
string="Asset Profile",
|
||||
)
|
||||
asset_id = fields.Many2one(
|
||||
comodel_name="account.asset", string="Asset", ondelete="restrict",
|
||||
comodel_name="account.asset",
|
||||
string="Asset",
|
||||
ondelete="restrict",
|
||||
)
|
||||
|
||||
@api.onchange("account_id")
|
||||
|
Loading…
Reference in New Issue
Block a user