3 final class PhabricatorPeopleListController
4 extends PhabricatorPeopleController
{
6 public function shouldAllowPublic() {
10 public function shouldRequireAdmin() {
14 public function handleRequest(AphrontRequest
$request) {
15 $this->requireApplicationCapability(
16 PeopleBrowseUserDirectoryCapability
::CAPABILITY
);
18 $controller = id(new PhabricatorApplicationSearchController())
19 ->setQueryKey($request->getURIData('queryKey'))
20 ->setSearchEngine(new PhabricatorPeopleSearchEngine())
21 ->setNavigation($this->buildSideNavView());
23 return $this->delegateToController($controller);
26 protected function buildApplicationCrumbs() {
27 $crumbs = parent
::buildApplicationCrumbs();
28 $viewer = $this->getRequest()->getUser();
30 if ($viewer->getIsAdmin()) {
32 id(new PHUIListItemView())
33 ->setName(pht('Create New User'))
34 ->setHref($this->getApplicationURI('create/'))
35 ->setIcon('fa-plus-square'));