@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
at recaptime-dev/main 37 lines 933 B view raw
1<?php 2 3final class DrydockResourceListController extends DrydockResourceController { 4 5 public function shouldAllowPublic() { 6 return true; 7 } 8 9 public function handleRequest(AphrontRequest $request) { 10 $viewer = $this->getViewer(); 11 12 $engine = new DrydockResourceSearchEngine(); 13 14 $id = $request->getURIData('id'); 15 if ($id) { 16 $blueprint = id(new DrydockBlueprintQuery()) 17 ->setViewer($viewer) 18 ->withIDs(array($id)) 19 ->executeOne(); 20 if (!$blueprint) { 21 return new Aphront404Response(); 22 } 23 $this->setBlueprint($blueprint); 24 $engine->setBlueprint($blueprint); 25 } 26 27 $querykey = $request->getURIData('queryKey'); 28 29 $controller = id(new PhabricatorApplicationSearchController()) 30 ->setQueryKey($querykey) 31 ->setSearchEngine($engine) 32 ->setNavigation($this->buildSideNavView()); 33 34 return $this->delegateToController($controller); 35 } 36 37}