@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.

Update Config to new UI

Summary: Converts Config to new UI, updates to `newPage`

Test Plan: Review all pages in Config, setup issues, ignore an issue, edit a config option

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: Korvin

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

authored by

Chad Little and committed by
chad
839e7e2f 72d12be8

+65 -81
+3 -5
src/applications/config/controller/PhabricatorConfigAllController.php
··· 64 64 $nav->setCrumbs($crumbs); 65 65 $nav->appendChild($panel); 66 66 67 + return $this->newPage() 68 + ->setTitle($title) 69 + ->appendChild($nav); 67 70 68 - return $this->buildApplicationPage( 69 - $nav, 70 - array( 71 - 'title' => $title, 72 - )); 73 71 } 74 72 75 73 }
+3 -5
src/applications/config/controller/PhabricatorConfigCacheController.php
··· 25 25 $data_box, 26 26 )); 27 27 28 - return $this->buildApplicationPage( 29 - $nav, 30 - array( 31 - 'title' => $title, 32 - )); 28 + return $this->newPage() 29 + ->setTitle($title) 30 + ->appendChild($nav); 33 31 } 34 32 35 33 private function renderCodeBox() {
+3 -5
src/applications/config/controller/PhabricatorConfigDatabaseIssueController.php
··· 159 159 $table_box, 160 160 )); 161 161 162 - return $this->buildApplicationPage( 163 - $nav, 164 - array( 165 - 'title' => $title, 166 - )); 162 + return $this->newPage() 163 + ->setTitle($title) 164 + ->appendChild($nav); 167 165 } 168 166 169 167 }
+3 -5
src/applications/config/controller/PhabricatorConfigDatabaseStatusController.php
··· 94 94 $nav->setCrumbs($crumbs); 95 95 $nav->appendChild($body); 96 96 97 - return $this->buildApplicationPage( 98 - $nav, 99 - array( 100 - 'title' => $title, 101 - )); 97 + return $this->newPage() 98 + ->setTitle($title) 99 + ->appendChild($nav); 102 100 } 103 101 104 102
+17 -11
src/applications/config/controller/PhabricatorConfigEditController.php
··· 227 227 ->setValue($examples)); 228 228 } 229 229 230 - $title = pht('Edit %s', $key); 230 + $title = pht('Edit Option: %s', $key); 231 + $header_icon = 'fa-pencil'; 231 232 $short = pht('Edit'); 232 233 233 234 $form_box = id(new PHUIObjectBoxView()) 234 - ->setHeaderText($title) 235 + ->setHeaderText(pht('Config Option')) 236 + ->setBackground(PHUIObjectBoxView::BLUE_PROPERTY) 235 237 ->setForm($form); 236 238 237 239 if ($error_view) { ··· 246 248 } 247 249 248 250 $crumbs->addTextCrumb($key, '/config/edit/'.$key); 251 + $crumbs->setBorder(true); 249 252 250 253 $timeline = $this->buildTransactionTimeline( 251 254 $config_entry, 252 255 new PhabricatorConfigTransactionQuery()); 253 256 $timeline->setShouldTerminate(true); 254 257 255 - return $this->buildApplicationPage( 256 - array( 257 - $crumbs, 258 - $form_box, 259 - $timeline, 260 - ), 261 - array( 262 - 'title' => $title, 263 - )); 258 + $header = id(new PHUIHeaderView()) 259 + ->setHeader($title) 260 + ->setHeaderIcon($header_icon); 261 + 262 + $view = id(new PHUITwoColumnView()) 263 + ->setHeader($header) 264 + ->setFooter($form_box); 265 + 266 + return $this->newPage() 267 + ->setTitle($title) 268 + ->setCrumbs($crumbs) 269 + ->appendChild($view); 264 270 } 265 271 266 272 private function readRequest(
+14 -10
src/applications/config/controller/PhabricatorConfigGroupController.php
··· 17 17 $list = $this->buildOptionList($options->getOptions()); 18 18 19 19 $box = id(new PHUIObjectBoxView()) 20 - ->setHeaderText($title) 21 20 ->setObjectList($list); 22 21 23 22 $crumbs = $this 24 23 ->buildApplicationCrumbs() 25 24 ->addTextCrumb(pht('Config'), $this->getApplicationURI()) 26 - ->addTextCrumb($options->getName(), $this->getApplicationURI()); 25 + ->addTextCrumb($options->getName(), $this->getApplicationURI()) 26 + ->setBorder(true); 27 27 28 - return $this->buildApplicationPage( 29 - array( 30 - $crumbs, 31 - $box, 32 - ), 33 - array( 34 - 'title' => $title, 35 - )); 28 + $header = id(new PHUIHeaderView()) 29 + ->setHeader($title) 30 + ->setHeaderIcon('fa-sliders'); 31 + 32 + $view = id(new PHUITwoColumnView()) 33 + ->setHeader($header) 34 + ->setFooter($box); 35 + 36 + return $this->newPage() 37 + ->setTitle($title) 38 + ->setCrumbs($crumbs) 39 + ->appendChild($view); 36 40 } 37 41 38 42 private function buildOptionList(array $options) {
+3 -7
src/applications/config/controller/PhabricatorConfigHistoryController.php
··· 40 40 $nav->setCrumbs($crumbs); 41 41 $nav->appendChild($timeline); 42 42 43 - return $this->buildApplicationPage( 44 - array( 45 - $nav, 46 - ), 47 - array( 48 - 'title' => $title, 49 - )); 43 + return $this->newPage() 44 + ->setTitle($title) 45 + ->appendChild($nav); 50 46 } 51 47 52 48 }
+1 -3
src/applications/config/controller/PhabricatorConfigIgnoreController.php
··· 32 32 throw new Exception(pht('Unrecognized verb: %s', $verb)); 33 33 } 34 34 35 - $dialog = id(new AphrontDialogView()) 36 - ->setUser($request->getUser()) 35 + return $this->newDialog() 37 36 ->setTitle($title) 38 37 ->appendChild($body) 39 38 ->addSubmitButton($submit_title) 40 39 ->addCancelButton($issue_uri); 41 40 42 - return id(new AphrontDialogResponse())->setDialog($dialog); 43 41 } 44 42 45 43 public function manageApplication($issue) {
+3 -5
src/applications/config/controller/PhabricatorConfigIssueListController.php
··· 66 66 67 67 $nav->setCrumbs($crumbs); 68 68 69 - return $this->buildApplicationPage( 70 - $nav, 71 - array( 72 - 'title' => $title, 73 - )); 69 + return $this->newPage() 70 + ->setTitle($title) 71 + ->appendChild($nav); 74 72 } 75 73 76 74 private function buildIssueList(array $issues, $group) {
+4 -8
src/applications/config/controller/PhabricatorConfigIssueViewController.php
··· 36 36 ->addTextCrumb(pht('Setup Issues'), $this->getApplicationURI('issue/')) 37 37 ->addTextCrumb($title, $request->getRequestURI()); 38 38 39 - return $this->buildApplicationPage( 40 - array( 41 - $crumbs, 42 - $content, 43 - ), 44 - array( 45 - 'title' => $title, 46 - )); 39 + return $this->newPage() 40 + ->setTitle($title) 41 + ->setCrumbs($crumbs) 42 + ->appendChild($content); 47 43 } 48 44 49 45 private function renderIssue(PhabricatorSetupIssue $issue) {
+3 -5
src/applications/config/controller/PhabricatorConfigListController.php
··· 35 35 36 36 $nav->setCrumbs($crumbs); 37 37 38 - return $this->buildApplicationPage( 39 - $nav, 40 - array( 41 - 'title' => $title, 42 - )); 38 + return $this->newPage() 39 + ->setTitle($title) 40 + ->appendChild($nav); 43 41 } 44 42 45 43 private function buildConfigOptionsList(array $groups, $type) {
+5 -7
src/applications/config/controller/PhabricatorConfigModuleController.php
··· 14 14 15 15 $module = $all_modules[$key]; 16 16 $content = $module->renderModuleStatus($request); 17 - $name = $module->getModuleName(); 17 + $title = $module->getModuleName(); 18 18 19 19 $crumbs = $this->buildApplicationCrumbs(); 20 - $crumbs->addTextCrumb($name); 20 + $crumbs->addTextCrumb($title); 21 21 22 22 $nav = $this->buildSideNavView(); 23 23 $nav->selectFilter('module/'.$key.'/'); ··· 27 27 $content, 28 28 )); 29 29 30 - return $this->buildApplicationPage( 31 - $nav, 32 - array( 33 - 'title' => $name, 34 - )); 30 + return $this->newPage() 31 + ->setTitle($title) 32 + ->appendChild($nav); 35 33 } 36 34 37 35 }
+3 -5
src/applications/config/controller/PhabricatorConfigWelcomeController.php
··· 18 18 $nav->setCrumbs($crumbs); 19 19 $nav->appendChild($this->buildWelcomeScreen($request)); 20 20 21 - return $this->buildApplicationPage( 22 - $nav, 23 - array( 24 - 'title' => $title, 25 - )); 21 + return $this->newPage() 22 + ->setTitle($title) 23 + ->appendChild($nav); 26 24 } 27 25 28 26 public function buildWelcomeScreen(AphrontRequest $request) {