Skip to content

Conversation

@mav-adhoc
Copy link

@mav-adhoc mav-adhoc commented Oct 29, 2025

Module error for not having company_id in stock_landed_cost_line:
File "/home/odoo/src/odoo/odoo/models.py", line 3857, in read
self._origin.fetch(fields)
File "/home/odoo/src/odoo/odoo/models.py", line 4133, in fetch
fields_to_fetch = self._determine_fields_to_fetch(field_names, ignore_when_in_cache=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/odoo/src/odoo/odoo/models.py", line 4187, in _determine_fields_to_fetch
raise ValueError(f"Invalid field {field_name!r} on model {self._name!r}")
ValueError: Invalid field 'company_id' on model 'stock.landed.cost.lines'

@mav-adhoc mav-adhoc force-pushed the 18.0-h-102941-mav-2 branch from e76bd9a to 28d3268 Compare October 29, 2025 13:53
@mav-adhoc mav-adhoc force-pushed the 18.0-h-102941-mav-2 branch from 28d3268 to 36e1e47 Compare October 29, 2025 15:14
"res.company",
string="Company",
related="cost_id.company_id",
readonly=True,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't it readonly by default?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants