Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/phabricator
Path: blob/master/src/applications/differential/customfield/DifferentialManiphestTasksField.php
12256 views
1
<?php
2
3
final class DifferentialManiphestTasksField
4
extends DifferentialCoreCustomField {
5
6
public function getFieldKey() {
7
return 'differential:maniphest-tasks';
8
}
9
10
public function canDisableField() {
11
return false;
12
}
13
14
public function getFieldName() {
15
return pht('Maniphest Tasks');
16
}
17
18
public function getFieldDescription() {
19
return pht('Lists associated tasks.');
20
}
21
22
public function shouldAppearInPropertyView() {
23
return true;
24
}
25
26
public function renderPropertyViewLabel() {
27
return $this->getFieldName();
28
}
29
30
protected function readValueFromRevision(DifferentialRevision $revision) {
31
if (!$revision->getPHID()) {
32
return array();
33
}
34
35
return PhabricatorEdgeQuery::loadDestinationPHIDs(
36
$revision->getPHID(),
37
DifferentialRevisionHasTaskEdgeType::EDGECONST);
38
}
39
40
public function getRequiredHandlePHIDsForPropertyView() {
41
return $this->getValue();
42
}
43
44
public function renderPropertyViewValue(array $handles) {
45
return $this->renderHandleList($handles);
46
}
47
48
}
49
50