Differential D21684 Diff 51699 src/applications/harbormaster/editor/HarbormasterBuildTransactionEditor.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/harbormaster/editor/HarbormasterBuildTransactionEditor.php
Show First 20 Lines • Show All 87 Lines • ▼ Show 20 Lines | if (!$issuable) { | ||||
return; | return; | ||||
} | } | ||||
$actor = $this->getActor(); | $actor = $this->getActor(); | ||||
if (!$build->canIssueCommand($actor, $command)) { | if (!$build->canIssueCommand($actor, $command)) { | ||||
return; | return; | ||||
} | } | ||||
id(new HarbormasterBuildCommand()) | HarbormasterBuildMessage::initializeNewMessage($actor) | ||||
->setAuthorPHID($xaction->getAuthorPHID()) | ->setAuthorPHID($xaction->getAuthorPHID()) | ||||
->setTargetPHID($build->getPHID()) | ->setReceiverPHID($build->getPHID()) | ||||
->setCommand($command) | ->setType($command) | ||||
->save(); | ->save(); | ||||
PhabricatorWorker::scheduleTask( | PhabricatorWorker::scheduleTask( | ||||
'HarbormasterBuildWorker', | 'HarbormasterBuildWorker', | ||||
array( | array( | ||||
'buildID' => $build->getID(), | 'buildID' => $build->getID(), | ||||
), | ), | ||||
array( | array( | ||||
Show All 18 Lines |