Changeset View
Changeset View
Standalone View
Standalone View
src/applications/conpherence/controller/ConpherenceController.php
| Show First 20 Lines • Show All 72 Lines • ▼ Show 20 Lines | if ($conpherence->getID()) { | ||||
| PhabricatorPolicyCapability::CAN_EDIT); | PhabricatorPolicyCapability::CAN_EDIT); | ||||
| if ($can_edit) { | if ($can_edit) { | ||||
| $header->setImageURL( | $header->setImageURL( | ||||
| $this->getApplicationURI('picture/'.$conpherence->getID().'/')); | $this->getApplicationURI('picture/'.$conpherence->getID().'/')); | ||||
| } | } | ||||
| $participating = $conpherence->getParticipantIfExists($viewer->getPHID()); | $participating = $conpherence->getParticipantIfExists($viewer->getPHID()); | ||||
| $can_join = PhabricatorPolicyFilter::hasCapability( | |||||
| $viewer, | |||||
| $conpherence, | |||||
| PhabricatorPolicyCapability::CAN_JOIN); | |||||
| $header->addActionItem( | $header->addActionItem( | ||||
| id(new PHUIIconCircleView()) | id(new PHUIIconCircleView()) | ||||
| ->setHref( | ->setHref( | ||||
| $this->getApplicationURI('update/'.$conpherence->getID()).'/') | $this->getApplicationURI('update/'.$conpherence->getID()).'/') | ||||
| ->setIcon('fa-pencil') | ->setIcon('fa-pencil') | ||||
| ->addClass('hide-on-device') | ->addClass('hide-on-device') | ||||
| ->setColor('violet') | ->setColor('violet') | ||||
| Show All 31 Lines | if ($conpherence->getID()) { | ||||
| $header->addActionItem( | $header->addActionItem( | ||||
| id(new PHUIIconCircleView()) | id(new PHUIIconCircleView()) | ||||
| ->addSigil('conpherence-search-toggle') | ->addSigil('conpherence-search-toggle') | ||||
| ->setIcon('fa-search') | ->setIcon('fa-search') | ||||
| ->setHref('#') | ->setHref('#') | ||||
| ->setColor('green') | ->setColor('green') | ||||
| ->addClass('conpherence-search-toggle')); | ->addClass('conpherence-search-toggle')); | ||||
| if ($can_join && !$participating) { | if (!$participating) { | ||||
| $action = ConpherenceUpdateActions::JOIN_ROOM; | $action = ConpherenceUpdateActions::JOIN_ROOM; | ||||
| $uri = $this->getApplicationURI('update/'.$conpherence->getID().'/'); | $uri = $this->getApplicationURI('update/'.$conpherence->getID().'/'); | ||||
| $button = phutil_tag( | $button = phutil_tag( | ||||
| 'button', | 'button', | ||||
| array( | array( | ||||
| 'type' => 'SUBMIT', | 'type' => 'SUBMIT', | ||||
| 'class' => 'button green mlr', | 'class' => 'button green mlr', | ||||
| ), | ), | ||||
| ▲ Show 20 Lines • Show All 85 Lines • Show Last 20 Lines | |||||