Page MenuHomePhabricator

D10282.id24762.diff
No OneTemporary

D10282.id24762.diff

diff --git a/src/applications/maniphest/controller/ManiphestController.php b/src/applications/maniphest/controller/ManiphestController.php
--- a/src/applications/maniphest/controller/ManiphestController.php
+++ b/src/applications/maniphest/controller/ManiphestController.php
@@ -44,7 +44,8 @@
}
protected function renderSingleTask(ManiphestTask $task) {
- $user = $this->getRequest()->getUser();
+ $request = $this->getRequest();
+ $user = $request->getUser();
$phids = $task->getProjectPHIDs();
if ($task->getOwnerPHID()) {
@@ -58,7 +59,7 @@
$view = id(new ManiphestTaskListView())
->setUser($user)
- ->setShowSubpriorityControls(true)
+ ->setShowSubpriorityControls(!$request->getStr('ungrippable'))
->setShowBatchControls(true)
->setHandles($handles)
->setTasks(array($task));
diff --git a/src/applications/maniphest/controller/ManiphestTaskEditController.php b/src/applications/maniphest/controller/ManiphestTaskEditController.php
--- a/src/applications/maniphest/controller/ManiphestTaskEditController.php
+++ b/src/applications/maniphest/controller/ManiphestTaskEditController.php
@@ -547,6 +547,7 @@
->addHiddenInput('template', $template_id)
->addHiddenInput('responseType', $response_type)
->addHiddenInput('order', $order)
+ ->addHiddenInput('ungrippable', $request->getStr('ungrippable'))
->addHiddenInput('columnPHID', $request->getStr('columnPHID'));
if ($parent_task) {
diff --git a/src/applications/maniphest/view/ManiphestTaskListView.php b/src/applications/maniphest/view/ManiphestTaskListView.php
--- a/src/applications/maniphest/view/ManiphestTaskListView.php
+++ b/src/applications/maniphest/view/ManiphestTaskListView.php
@@ -90,11 +90,15 @@
));
if ($this->showBatchControls) {
+ $href = new PhutilURI('/maniphest/task/edit/'.$task->getID().'/');
+ if (!$this->showSubpriorityControls) {
+ $href->setQueryParam('ungrippable', 'true');
+ }
$item->addAction(
id(new PHUIListItemView())
->setIcon('fa-pencil')
->addSigil('maniphest-edit-task')
- ->setHref('/maniphest/task/edit/'.$task->getID().'/'));
+ ->setHref($href));
}
$list->addItem($item);

File Metadata

Mime Type
text/plain
Expires
Sat, Mar 22, 3:06 PM (1 w, 2 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7225406
Default Alt Text
D10282.id24762.diff (2 KB)

Event Timeline