Modularize workboard column transactions

Summary: Depends on D20279. Ref T5474. Modernize these transactions before I add a new "TriggerTransaction" for setting triggers.

Test Plan: Created a column. Edited a column name and point limit. Hid and un-hid a column. Grepped for removed symbols.

Reviewers: amckinley

Reviewed By: amckinley

Maniphest Tasks: T5474

Differential Revision: https://secure.phabricator.com/D20286
This commit is contained in:
epriestley
2019-03-14 08:11:08 -07:00
parent 252b6f2260
commit 0204489a52
9 changed files with 209 additions and 194 deletions

View File

@@ -76,8 +76,8 @@ final class PhabricatorProjectColumnEditController
$xactions = array();
$type_name = PhabricatorProjectColumnTransaction::TYPE_NAME;
$type_limit = PhabricatorProjectColumnTransaction::TYPE_LIMIT;
$type_name = PhabricatorProjectColumnNameTransaction::TRANSACTIONTYPE;
$type_limit = PhabricatorProjectColumnLimitTransaction::TRANSACTIONTYPE;
if (!$column->getProxy()) {
$xactions[] = id(new PhabricatorProjectColumnTransaction())
@@ -93,7 +93,6 @@ final class PhabricatorProjectColumnEditController
$editor = id(new PhabricatorProjectColumnTransactionEditor())
->setActor($viewer)
->setContinueOnNoEffect(true)
->setContinueOnMissingFields(true)
->setContentSourceFromRequest($request)
->applyTransactions($column, $xactions);
return id(new AphrontRedirectResponse())->setURI($view_uri);

View File

@@ -82,7 +82,9 @@ final class PhabricatorProjectColumnHideController
$new_status = PhabricatorProjectColumn::STATUS_HIDDEN;
}
$type_status = PhabricatorProjectColumnTransaction::TYPE_STATUS;
$type_status =
PhabricatorProjectColumnStatusTransaction::TRANSACTIONTYPE;
$xactions = array(
id(new PhabricatorProjectColumnTransaction())
->setTransactionType($type_status)