Path: blob/master/src/applications/dashboard/install/PhabricatorDashboardFavoritesInstallWorkflow.php
12242 views
<?php12final class PhabricatorDashboardFavoritesInstallWorkflow3extends PhabricatorDashboardApplicationInstallWorkflow {45const WORKFLOWKEY = 'favorites';67public function getOrder() {8return 4000;9}1011protected function newWorkflowMenuItem() {12return $this->newMenuItem()13->setHeader(pht('Add to Favorites Menu'))14->setImageIcon('fa-bookmark')15->addAttribute(16pht(17'Add this dashboard to the favorites menu in the main '.18'menu bar.'));19}2021protected function newProfileEngine() {22return new PhabricatorFavoritesProfileMenuEngine();23}2425protected function newApplication() {26return new PhabricatorFavoritesApplication();27}2829protected function newApplicationModeDialog() {30return $this->newDialog()31->setTitle(pht('Add Dashboard to Favorites Menu'));32}3334protected function newPersonalMenuItem() {35return $this->newMenuItem()36->setHeader(pht('Add to Personal Favorites'))37->setImageIcon('fa-user')38->addAttribute(39pht(40'Add this dashboard to your list of personal favorite menu items, '.41'visible to only you.'));42}4344protected function newGlobalMenuItem() {45return $this->newMenuItem()46->setHeader(pht('Add to Global Favorites'))47->setImageIcon('fa-globe')48->addAttribute(49pht(50'Add this dashboard to the global favorites menu, visible to all '.51'users.'));52}5354protected function newGlobalPermissionDialog() {55return $this->newDialog()56->setTitle(pht('No Permission'))57->appendParagraph(58pht(59'You do not have permission to install items on the global '.60'favorites menu.'));61}6263protected function newGlobalConfirmDialog() {64return $this->newDialog()65->setTitle(pht('Add Dashboard to Global Favorites'))66->appendParagraph(67pht(68'Add dashboard %s as a global menu item in the favorites menu?',69$this->getDashboardDisplayName()))70->addSubmitButton(pht('Add to Favorites'));71}7273protected function newPersonalConfirmDialog() {74return $this->newDialog()75->setTitle(pht('Add Dashboard to Personal Favorites'))76->appendParagraph(77pht(78'Add dashboard %s as a personal menu item in the favorites menu?',79$this->getDashboardDisplayName()))80->addSubmitButton(pht('Add to Favorites'));81}828384}858687