1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 08:52:39 +01:00

Normalize renderControl API

Summary: Make Maniphest use the standard API, `renderEditControl`. Removes custom method `renderControl`.

Test Plan: Created/edited tasks with custom fields.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Differential Revision: https://secure.phabricator.com/D7034
This commit is contained in:
epriestley 2013-09-19 11:55:45 -07:00
parent 45ff6077a7
commit 30159d9ad9
4 changed files with 3 additions and 11 deletions

View file

@ -108,7 +108,7 @@ class ManiphestAuxiliaryFieldDefaultSpecification
return $this->checkboxValue;
}
public function renderControl() {
public function renderEditControl() {
$control = null;
$type = $this->getFieldType();
@ -223,7 +223,7 @@ class ManiphestAuxiliaryFieldDefaultSpecification
$type = $this->getFieldType();
switch ($type) {
case self::TYPE_DATE:
$control = $this->renderControl();
$control = $this->renderEditControl();
$value = $control->readValueFromRequest($request);
break;
case self::TYPE_USER:

View file

@ -80,10 +80,6 @@ abstract class ManiphestAuxiliaryFieldSpecification
return $this->type;
}
public function renderControl() {
return null;
}
public function renderForDetailView() {
return $this->getValue();
}

View file

@ -496,7 +496,7 @@ final class ManiphestTaskEditController extends ManiphestController {
$aux_field->setError(true);
}
$aux_control = $aux_field->renderControl();
$aux_control = $aux_field->renderEditControl();
$form->appendChild($aux_control);
}

View file

@ -40,10 +40,6 @@ abstract class ManiphestCustomField
return false;
}
public function renderControl() {
return $this->renderEditControl();
}
public function validate() {
return true;
}