Differential D14264 Diff 34439 src/applications/maniphest/controller/ManiphestTaskEditController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/maniphest/controller/ManiphestTaskEditController.php
| Show First 20 Lines • Show All 192 Lines • ▼ Show 20 Lines | if ($request->isFormPost()) { | ||||
| $aux_field->readValueFromRequest($request); | $aux_field->readValueFromRequest($request); | ||||
| $aux_new_value = $aux_field->getNewValueForApplicationTransactions(); | $aux_new_value = $aux_field->getNewValueForApplicationTransactions(); | ||||
| // TODO: We're faking a call to the ApplicaitonTransaction validation | // TODO: We're faking a call to the ApplicaitonTransaction validation | ||||
| // logic here. We need valid objects to pass, but they aren't used | // logic here. We need valid objects to pass, but they aren't used | ||||
| // in a meaningful way. For now, build User objects. Once the Maniphest | // in a meaningful way. For now, build User objects. Once the Maniphest | ||||
| // objects exist, this will switch over automatically. This is a big | // objects exist, this will switch over automatically. This is a big | ||||
| // hack but shouldn't be long for this world. | // hack but shouldn't be long for this world. | ||||
| $placeholder_editor = new PhabricatorUserProfileEditor(); | $placeholder_editor = id(new PhabricatorUserProfileEditor()) | ||||
| ->setActor($viewer); | |||||
| $field_errors = $aux_field->validateApplicationTransactions( | $field_errors = $aux_field->validateApplicationTransactions( | ||||
| $placeholder_editor, | $placeholder_editor, | ||||
| PhabricatorTransactions::TYPE_CUSTOMFIELD, | PhabricatorTransactions::TYPE_CUSTOMFIELD, | ||||
| array( | array( | ||||
| id(new ManiphestTransaction()) | id(new ManiphestTransaction()) | ||||
| ->setOldValue($aux_old_value) | ->setOldValue($aux_old_value) | ||||
| ->setNewValue($aux_new_value), | ->setNewValue($aux_new_value), | ||||
| ▲ Show 20 Lines • Show All 546 Lines • Show Last 20 Lines | |||||