Differential D20154 Diff 48161 src/applications/files/controller/PhabricatorFileLightboxController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/files/controller/PhabricatorFileLightboxController.php
Show First 20 Lines • Show All 64 Lines • ▼ Show 20 Lines | return id(new AphrontAjaxResponse()) | ||||
->setContent($content); | ->setContent($content); | ||||
} | } | ||||
private function renderCommentForm(PhabricatorFile $file) { | private function renderCommentForm(PhabricatorFile $file) { | ||||
$viewer = $this->getViewer(); | $viewer = $this->getViewer(); | ||||
if (!$viewer->isLoggedIn()) { | if (!$viewer->isLoggedIn()) { | ||||
$login_href = id(new PhutilURI('/auth/start/')) | $login_href = id(new PhutilURI('/auth/start/')) | ||||
->setQueryParam('next', '/'.$file->getMonogram()); | ->replaceQueryParam('next', '/'.$file->getMonogram()); | ||||
return id(new PHUIFormLayoutView()) | return id(new PHUIFormLayoutView()) | ||||
->addClass('phui-comment-panel-empty') | ->addClass('phui-comment-panel-empty') | ||||
->appendChild( | ->appendChild( | ||||
id(new PHUIButtonView()) | id(new PHUIButtonView()) | ||||
->setTag('a') | ->setTag('a') | ||||
->setText(pht('Log In to Comment')) | ->setText(pht('Log In to Comment')) | ||||
->setHref((string)$login_href)); | ->setHref((string)$login_href)); | ||||
} | } | ||||
Show All 28 Lines |