Changeset View
Changeset View
Standalone View
Standalone View
src/applications/project/storage/PhabricatorProject.php
<?php | <?php | ||||
final class PhabricatorProject extends PhabricatorProjectDAO | final class PhabricatorProject extends PhabricatorProjectDAO | ||||
implements | implements | ||||
PhabricatorApplicationTransactionInterface, | PhabricatorApplicationTransactionInterface, | ||||
PhabricatorFlaggableInterface, | PhabricatorFlaggableInterface, | ||||
PhabricatorPolicyInterface, | PhabricatorPolicyInterface, | ||||
PhabricatorExtendedPolicyInterface, | PhabricatorExtendedPolicyInterface, | ||||
PhabricatorSubscribableInterface, | |||||
PhabricatorCustomFieldInterface, | PhabricatorCustomFieldInterface, | ||||
PhabricatorDestructibleInterface, | PhabricatorDestructibleInterface, | ||||
PhabricatorFulltextInterface, | PhabricatorFulltextInterface, | ||||
PhabricatorConduitResultInterface { | PhabricatorConduitResultInterface { | ||||
protected $name; | protected $name; | ||||
protected $status = PhabricatorProjectStatus::STATUS_ACTIVE; | protected $status = PhabricatorProjectStatus::STATUS_ACTIVE; | ||||
protected $authorPHID; | protected $authorPHID; | ||||
▲ Show 20 Lines • Show All 156 Lines • ▼ Show 20 Lines | switch ($capability) { | ||||
); | ); | ||||
} | } | ||||
break; | break; | ||||
} | } | ||||
return $extended; | return $extended; | ||||
} | } | ||||
public function isUserMember($user_phid) { | public function isUserMember($user_phid) { | ||||
if ($this->memberPHIDs !== self::ATTACHABLE) { | if ($this->memberPHIDs !== self::ATTACHABLE) { | ||||
return in_array($user_phid, $this->memberPHIDs); | return in_array($user_phid, $this->memberPHIDs); | ||||
} | } | ||||
return $this->assertAttachedKey($this->sparseMembers, $user_phid); | return $this->assertAttachedKey($this->sparseMembers, $user_phid); | ||||
} | } | ||||
public function setIsUserMember($user_phid, $is_member) { | public function setIsUserMember($user_phid, $is_member) { | ||||
▲ Show 20 Lines • Show All 340 Lines • ▼ Show 20 Lines | $map = array( | ||||
'grey' => 'charcoal', | 'grey' => 'charcoal', | ||||
'checkered' => 'backdrop', | 'checkered' => 'backdrop', | ||||
); | ); | ||||
return idx($map, $color, $color); | return idx($map, $color, $color); | ||||
} | } | ||||
/* -( PhabricatorSubscribableInterface )----------------------------------- */ | |||||
public function isAutomaticallySubscribed($phid) { | |||||
return false; | |||||
} | |||||
public function shouldShowSubscribersProperty() { | |||||
return false; | |||||
} | |||||
/* -( PhabricatorCustomFieldInterface )------------------------------------ */ | /* -( PhabricatorCustomFieldInterface )------------------------------------ */ | ||||
public function getCustomFieldSpecificationForRole($role) { | public function getCustomFieldSpecificationForRole($role) { | ||||
return PhabricatorEnv::getEnvConfig('projects.fields'); | return PhabricatorEnv::getEnvConfig('projects.fields'); | ||||
} | } | ||||
public function getCustomFieldBaseClass() { | public function getCustomFieldBaseClass() { | ||||
▲ Show 20 Lines • Show All 106 Lines • Show Last 20 Lines |