first push message
This commit is contained in:
@@ -0,0 +1 @@
|
||||
from . import survey_survey
|
||||
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,19 @@
|
||||
# Copyright 2022 Tecnativa - David Vidal
|
||||
# Copyright 2025 Upgraded to Odoo 19.0
|
||||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
|
||||
from odoo import fields, models
|
||||
|
||||
|
||||
class SurveySurvey(models.Model):
|
||||
_inherit = "survey.survey"
|
||||
|
||||
# In Odoo 19 Community, survey.survey does not include company_id natively.
|
||||
# This field adds multi-company support so surveys can be scoped per company.
|
||||
# If a future Odoo version adds company_id natively, redefining it here via
|
||||
# _inherit is safe — Odoo's ORM keeps the existing field and ignores the duplicate.
|
||||
company_id = fields.Many2one(
|
||||
comodel_name="res.company",
|
||||
string="Company",
|
||||
index=True,
|
||||
default=lambda self: self.env.company,
|
||||
)
|
||||
Reference in New Issue
Block a user