HomePhabricator

Add View, Edit and Join policies to PhabricatorProject

Description

Add View, Edit and Join policies to PhabricatorProject

Summary:

  • In ProjectQuery, always load the viewer's membership in the project because we need it to perform a CAN_VIEW test.
  • Add storage for the view, edit and join policies.
  • A user can always view a project if they are a member.
  • A user can always join a project if they can edit it.
  • Editing a project requires both "view" and "edit" permissions, and edit does not imply view.
  • This has no effect on the application yet.

Test Plan: See next diff.

Reviewers: vrana, btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T603

Differential Revision: https://secure.phabricator.com/D3219

Details

Provenance
epriestleyAuthored on
Reviewer
btrahan
Differential Revision
D3219: Add View, Edit and Join policies to PhabricatorProject
Parents
rP6cbc67ea7501: Improve PolicyFilter and PolicyQuery
Branches
Unknown
Tags
Unknown

Event Timeline