Correct a parameter order swap in "diffusion.historyquery" for Mercurial
[phabricator.git] / src / applications / herald / application / PhabricatorHeraldApplication.php
blob0de1c0273716a62d3b7db7d9617ffe22f276258e
1 <?php
3 final class PhabricatorHeraldApplication extends PhabricatorApplication {
5 public function getBaseURI() {
6 return '/herald/';
9 public function getIcon() {
10 return 'fa-bullhorn';
13 public function getName() {
14 return pht('Herald');
17 public function getShortDescription() {
18 return pht('Create Notification Rules');
21 public function getTitleGlyph() {
22 return "\xE2\x98\xBF";
25 public function getHelpDocumentationArticles(PhabricatorUser $viewer) {
26 return array(
27 array(
28 'name' => pht('Herald User Guide'),
29 'href' => PhabricatorEnv::getDoclink('Herald User Guide'),
31 array(
32 'name' => pht('User Guide: Webhooks'),
33 'href' => PhabricatorEnv::getDoclink('User Guide: Webhooks'),
38 public function getFlavorText() {
39 return pht('Watch for danger!');
42 public function getApplicationGroup() {
43 return self::GROUP_UTILITIES;
46 public function getRemarkupRules() {
47 return array(
48 new HeraldRemarkupRule(),
52 public function getRoutes() {
53 return array(
54 '/H(?P<id>[1-9]\d*)' => 'HeraldRuleViewController',
55 '/herald/' => array(
56 '(?:query/(?P<queryKey>[^/]+)/)?' => 'HeraldRuleListController',
57 'new/' => 'HeraldNewController',
58 'create/' => 'HeraldNewController',
59 'edit/(?:(?P<id>[1-9]\d*)/)?' => 'HeraldRuleController',
60 'disable/(?P<id>[1-9]\d*)/(?P<action>[^/]+)/'
61 => 'HeraldDisableController',
62 'test/' => 'HeraldTestConsoleController',
63 'transcript/' => array(
64 '' => 'HeraldTranscriptListController',
65 '(?:query/(?P<queryKey>[^/]+)/)?' => 'HeraldTranscriptListController',
66 '(?P<id>[1-9]\d*)/(?:(?P<view>[^/]+)/)?'
67 => 'HeraldTranscriptController',
69 'webhook/' => array(
70 $this->getQueryRoutePattern() => 'HeraldWebhookListController',
71 'view/(?P<id>\d+)/(?:request/(?P<requestID>[^/]+)/)?' =>
72 'HeraldWebhookViewController',
73 $this->getEditRoutePattern('edit/') => 'HeraldWebhookEditController',
74 'test/(?P<id>\d+)/' => 'HeraldWebhookTestController',
75 'key/(?P<action>view|cycle)/(?P<id>\d+)/' =>
76 'HeraldWebhookKeyController',
82 protected function getCustomCapabilities() {
83 return array(
84 HeraldManageGlobalRulesCapability::CAPABILITY => array(
85 'caption' => pht('Global rules can bypass access controls.'),
86 'default' => PhabricatorPolicies::POLICY_ADMIN,
88 HeraldCreateWebhooksCapability::CAPABILITY => array(
89 'default' => PhabricatorPolicies::POLICY_ADMIN,