Skip to content

[ADD] project_no_portal: new module to block portal access on projects#1741

Open
divad1196 wants to merge 1 commit into
OCA:18.0from
camptocamp:add_project_no_portal
Open

[ADD] project_no_portal: new module to block portal access on projects#1741
divad1196 wants to merge 1 commit into
OCA:18.0from
camptocamp:add_project_no_portal

Conversation

@divad1196
Copy link
Copy Markdown

@divad1196 divad1196 commented May 29, 2026

Context

A project with privacy_visibility = 'portal' ("Invited portal users") lets any portal follower of the project or its tasks read it, and managers can share project/task data via the "Share Project" wizard and the "Share Task" public link.

What it does

A per-company switch block_project_portal_access (res.company, on by default, under Settings > Project).

For a blocking company:

  • A constraint forbids privacy_visibility = 'portal' (default becomes employees).
    A post_init_hook migrates existing portal projects. This alone removes portal read access.
  • A mixin on project.project/project.task also denies portal users in _search/_check_access.
    This adds an additional security without deleting existing ir.model.access
  • The "Share Project" / "Share Task" actions are unbound.
    Calling them, for example from the code, raises an error.
    An uninstall_hook restores them.

Scoped per company (multi-company friendly) and fully reversible.

@divad1196 divad1196 force-pushed the add_project_no_portal branch 2 times, most recently from 672770b to 088581f Compare May 29, 2026 12:23
@divad1196 divad1196 changed the title project_no_portal: new module to block portal access on projects [ADD] project_no_portal: new module to block portal access on projects May 29, 2026
This module add per-company switch block_project_portal_access under Settings > Project.
Active by default.

For a blocking company:

- A constraint forbids privacy_visibility = 'portal' (default becomes employees).
- A post_init_hook migrates existing portal projects. This alone removes portal read access.
- A mixin on project.project/project.task also denies portal users in _search/_check_access.
  This adds an additional security without deleting existing ir.model.access
- The "Share Project" / "Share Task" actions are unbound.
  Calling them, for example from the code, raises an error.
  An uninstall_hook restores them.

Scoped per company (multi-company friendly) and fully reversible.
@divad1196 divad1196 force-pushed the add_project_no_portal branch from c480e0d to f4bf8c1 Compare June 3, 2026 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

mod:project_no_portal Module project_no_portal series:18.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants