@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Maniphest - add conduit method to get status information

Summary: Ref T4938. `arc close` needs to know about custom statuses and this conduit method is step 1 of letting it know

Test Plan: See next diff, which works!

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: epriestley, Korvin

Maniphest Tasks: T4938

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

+37
+2
src/__phutil_library_map__.php
··· 201 201 'ConduitAPI_maniphest_gettasktransactions_Method' => 'applications/maniphest/conduit/ConduitAPI_maniphest_gettasktransactions_Method.php', 202 202 'ConduitAPI_maniphest_info_Method' => 'applications/maniphest/conduit/ConduitAPI_maniphest_info_Method.php', 203 203 'ConduitAPI_maniphest_query_Method' => 'applications/maniphest/conduit/ConduitAPI_maniphest_query_Method.php', 204 + 'ConduitAPI_maniphest_querystatuses_Method' => 'applications/maniphest/conduit/ConduitAPI_maniphest_querystatuses_Method.php', 204 205 'ConduitAPI_maniphest_update_Method' => 'applications/maniphest/conduit/ConduitAPI_maniphest_update_Method.php', 205 206 'ConduitAPI_nuance_Method' => 'applications/nuance/conduit/ConduitAPI_nuance_Method.php', 206 207 'ConduitAPI_nuance_createitem_Method' => 'applications/nuance/conduit/ConduitAPI_nuance_createitem_Method.php', ··· 2814 2815 'ConduitAPI_maniphest_gettasktransactions_Method' => 'ConduitAPI_maniphest_Method', 2815 2816 'ConduitAPI_maniphest_info_Method' => 'ConduitAPI_maniphest_Method', 2816 2817 'ConduitAPI_maniphest_query_Method' => 'ConduitAPI_maniphest_Method', 2818 + 'ConduitAPI_maniphest_querystatuses_Method' => 'ConduitAPI_maniphest_Method', 2817 2819 'ConduitAPI_maniphest_update_Method' => 'ConduitAPI_maniphest_Method', 2818 2820 'ConduitAPI_nuance_Method' => 'ConduitAPIMethod', 2819 2821 'ConduitAPI_nuance_createitem_Method' => 'ConduitAPI_nuance_Method',
+35
src/applications/maniphest/conduit/ConduitAPI_maniphest_querystatuses_Method.php
··· 1 + <?php 2 + 3 + final class ConduitAPI_maniphest_querystatuses_Method 4 + extends ConduitAPI_maniphest_Method { 5 + 6 + public function getMethodDescription() { 7 + return "Retrieve information about possible Maniphest Task status values."; 8 + } 9 + 10 + public function defineParamTypes() { 11 + return array(); 12 + } 13 + 14 + public function defineReturnType() { 15 + return 'nonempty dict<string, wild>'; 16 + } 17 + 18 + public function defineErrorTypes() { 19 + return array(); 20 + } 21 + 22 + protected function execute(ConduitAPIRequest $request) { 23 + $results = array( 24 + 'defaultStatus' => ManiphestTaskStatus::getDefaultStatus(), 25 + 'defaultClosedStatus' => ManiphestTaskStatus::getDefaultClosedStatus(), 26 + 'duplicateStatus' => ManiphestTaskStatus::getDuplicateStatus(), 27 + 'openStatuses' => ManiphestTaskStatus::getOpenStatusConstants(), 28 + 'closedStatuses' => ManiphestTaskStatus::getClosedStatusConstants(), 29 + 'allStatuses' => array_keys(ManiphestTaskStatus::getTaskStatusMap()), 30 + 'statusMap' => ManiphestTaskStatus::getTaskStatusMap() 31 + ); 32 + return $results; 33 + } 34 + 35 + }