Page MenuHomePhabricator

D16000.diff
No OneTemporary

D16000.diff

diff --git a/src/applications/project/controller/PhabricatorProjectMembersAddController.php b/src/applications/project/controller/PhabricatorProjectMembersAddController.php
--- a/src/applications/project/controller/PhabricatorProjectMembersAddController.php
+++ b/src/applications/project/controller/PhabricatorProjectMembersAddController.php
@@ -21,12 +21,17 @@
}
$this->setProject($project);
+ $done_uri = "/project/members/{$id}/";
if (!$project->supportsEditMembers()) {
- return new Aphront404Response();
- }
+ $copy = pht('Parent projects and milestones do not support adding '.
+ 'members. You can add members directly to any non-parent subproject.');
- $done_uri = "/project/members/{$id}/";
+ return $this->newDialog()
+ ->setTitle(pht('Unsupported Project'))
+ ->appendParagraph($copy)
+ ->addCancelButton($done_uri);
+ }
if ($request->isFormPost()) {
$member_phids = $request->getArr('memberPHIDs');
diff --git a/src/applications/project/controller/PhabricatorProjectUpdateController.php b/src/applications/project/controller/PhabricatorProjectUpdateController.php
--- a/src/applications/project/controller/PhabricatorProjectUpdateController.php
+++ b/src/applications/project/controller/PhabricatorProjectUpdateController.php
@@ -32,11 +32,17 @@
return new Aphront404Response();
}
+ $done_uri = "/project/members/{$id}/";
+
if (!$project->supportsEditMembers()) {
- return new Aphront404Response();
- }
+ $copy = pht('Parent projects and milestones do not support adding '.
+ 'members. You can add members directly to any non-parent subproject.');
- $done_uri = "/project/members/{$id}/";
+ return $this->newDialog()
+ ->setTitle(pht('Unsupported Project'))
+ ->appendParagraph($copy)
+ ->addCancelButton($done_uri);
+ }
if ($request->isFormPost()) {
$edge_action = null;

File Metadata

Mime Type
text/plain
Expires
Mon, Dec 23, 4:47 AM (15 h, 45 m)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6918574
Default Alt Text
D16000.diff (1 KB)

Event Timeline