Differential D17349 Diff 41723 src/applications/dashboard/controller/PhabricatorDashboardPanelEditController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/dashboard/controller/PhabricatorDashboardPanelEditController.php
Show First 20 Lines • Show All 137 Lines • ▼ Show 20 Lines | if ($request->isFormPost() && $request->getBool('edit')) { | ||||
try { | try { | ||||
$editor = id(new PhabricatorDashboardPanelTransactionEditor()) | $editor = id(new PhabricatorDashboardPanelTransactionEditor()) | ||||
->setActor($viewer) | ->setActor($viewer) | ||||
->setContinueOnNoEffect(true) | ->setContinueOnNoEffect(true) | ||||
->setContentSourceFromRequest($request) | ->setContentSourceFromRequest($request) | ||||
->applyTransactions($panel, $xactions); | ->applyTransactions($panel, $xactions); | ||||
// If we're creating a panel directly on a dashboard, add it now. | // If we're creating a panel directly on a dashboard, add it now. | ||||
if ($dashboard) { | if ($dashboard && $is_create) { | ||||
PhabricatorDashboardTransactionEditor::addPanelToDashboard( | PhabricatorDashboardTransactionEditor::addPanelToDashboard( | ||||
$viewer, | $viewer, | ||||
PhabricatorContentSource::newFromRequest($request), | PhabricatorContentSource::newFromRequest($request), | ||||
$panel, | $panel, | ||||
$dashboard, | $dashboard, | ||||
$request->getInt('column', 0)); | $request->getInt('column', 0)); | ||||
} | } | ||||
▲ Show 20 Lines • Show All 196 Lines • Show Last 20 Lines |