Skip to content

[17.0][IMP-FIX] survey_multi_company: run survey access with correct company context#194

Merged
OCA-git-bot merged 1 commit intoOCA:17.0from
Tecnativa:17.0-imp-survey_multi_company
Jul 23, 2025
Merged

[17.0][IMP-FIX] survey_multi_company: run survey access with correct company context#194
OCA-git-bot merged 1 commit intoOCA:17.0from
Tecnativa:17.0-imp-survey_multi_company

Conversation

@pilarvargas-tecnativa
Copy link
Copy Markdown

fwp of #191

@Tecnativa

@pedrobaeza @victoralmau please review

…y context

Web survey requests in multi-company environments may lack an explicitly active
company in the context, causing request.env.company to fall back to the user's
default company or the first allowed one. This can lead to access errors,
misapplied record rules, or incorrect business logic execution.
To prevent this, the company set on the survey is enforced via with_company()
on both the survey and the user input. This ensures that all company-dependent
operations behave as expected during the survey flow.
@pedrobaeza pedrobaeza added this to the 17.0 milestone Jul 23, 2025
@pedrobaeza
Copy link
Copy Markdown
Member

/ocabot merge patch

@OCA-git-bot
Copy link
Copy Markdown
Contributor

On my way to merge this fine PR!
Prepared branch 17.0-ocabot-merge-pr-194-by-pedrobaeza-bump-patch, awaiting test results.

OCA-git-bot added a commit that referenced this pull request Jul 23, 2025
Signed-off-by pedrobaeza
@OCA-git-bot
Copy link
Copy Markdown
Contributor

It looks like something changed on 17.0 in the meantime.
Let me try again (no action is required from you).
Prepared branch 17.0-ocabot-merge-pr-194-by-pedrobaeza-bump-patch, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 4cfca78 into OCA:17.0 Jul 23, 2025
5 of 7 checks passed
@OCA-git-bot
Copy link
Copy Markdown
Contributor

Congratulations, your PR was merged at b7b3ec1. Thanks a lot for contributing to OCA. ❤️

@pedrobaeza pedrobaeza deleted the 17.0-imp-survey_multi_company branch July 23, 2025 15:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants