Page MenuHomePhabricator

D11260.diff
No OneTemporary

D11260.diff

diff --git a/src/applications/project/events/PhabricatorProjectUIEventListener.php b/src/applications/project/events/PhabricatorProjectUIEventListener.php
--- a/src/applications/project/events/PhabricatorProjectUIEventListener.php
+++ b/src/applications/project/events/PhabricatorProjectUIEventListener.php
@@ -54,12 +54,23 @@
require_celerity_resource('maniphest-task-summary-css');
- $positions = id(new PhabricatorProjectColumnPositionQuery())
+ $positions_query = id(new PhabricatorProjectColumnPositionQuery())
->setViewer($user)
->withBoardPHIDs($project_phids)
->withObjectPHIDs(array($object->getPHID()))
- ->needColumns(true)
+ ->needColumns(true);
+
+ // This is important because positions will be created "on demand"
+ // based on the set of columns. If we don't specify it, positions
+ // won't be created.
+ $columns = id(new PhabricatorProjectColumnQuery())
+ ->setViewer($user)
+ ->withProjectPHIDs($project_phids)
->execute();
+ if ($columns) {
+ $positions_query->withColumns($columns);
+ }
+ $positions = $positions_query->execute();
$positions = mpull($positions, null, 'getBoardPHID');
foreach ($project_phids as $project_phid) {

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 9, 9:23 PM (1 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6714935
Default Alt Text
D11260.diff (1 KB)

Event Timeline