Path: blob/master/src/applications/conpherence/policyrule/ConpherenceThreadMembersPolicyRule.php
12256 views
<?php12final class ConpherenceThreadMembersPolicyRule3extends PhabricatorPolicyRule {45public function getObjectPolicyKey() {6return 'conpherence.members';7}89public function getObjectPolicyName() {10return pht('Room Participants');11}1213public function getPolicyExplanation() {14return pht('Participants in this room can take this action.');15}1617public function getRuleDescription() {18return pht('room participants');19}2021public function getObjectPolicyIcon() {22return 'fa-comments';23}2425public function canApplyToObject(PhabricatorPolicyInterface $object) {26return ($object instanceof ConpherenceThread);27}2829public function applyRule(30PhabricatorUser $viewer,31$value,32PhabricatorPolicyInterface $object) {33$viewer_phid = $viewer->getPHID();34if (!$viewer_phid) {35return false;36}3738return (bool)$object->getParticipantIfExists($viewer_phid);39}4041public function getValueControlType() {42return self::CONTROL_TYPE_NONE;43}4445}464748