1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-20 20:40:56 +01:00

Clean up logged out prompt on TransactionComments

Summary: We were getting a weird double box here, missed it my first pass

Test Plan: Review logged in Maniphest and Paste, as well as logged out versions. Test Login flow.

Reviewers: epriestley

Reviewed By: epriestley

CC: Korvin, epriestley, aran

Differential Revision: https://secure.phabricator.com/D7716
This commit is contained in:
Chad Little 2013-12-05 08:44:43 -08:00
parent 205ddcf134
commit 00c6e60c27
2 changed files with 7 additions and 6 deletions

View file

@ -382,10 +382,15 @@ final class ManiphestTaskDetailController extends ManiphestController {
if (!$user->isLoggedIn()) {
// TODO: Eventually, everything should run through this. For now, we're
// only using it to get a consistent "Login to Comment" button.
$comment_form = id(new PhabricatorApplicationTransactionCommentView())
$comment_box = id(new PhabricatorApplicationTransactionCommentView())
->setUser($user)
->setRequestURI($request->getRequestURI());
$preview_panel = null;
} else {
$comment_box = id(new PHUIObjectBoxView())
->setFlush(true)
->setHeaderText($comment_header)
->appendChild($comment_form);
}
$object_box = id(new PHUIObjectBoxView())
@ -396,11 +401,6 @@ final class ManiphestTaskDetailController extends ManiphestController {
$object_box->addPropertyList($description);
}
$comment_box = id(new PHUIObjectBoxView())
->setFlush(true)
->setHeaderText($comment_header)
->appendChild($comment_form);
return $this->buildApplicationPage(
array(
$crumbs,

View file

@ -85,6 +85,7 @@ class PhabricatorApplicationTransactionCommentView extends AphrontView {
$uri = id(new PhutilURI('/login/'))
->setQueryParam('next', (string) $this->getRequestURI());
return id(new PHUIObjectBoxView())
->setFlush(true)
->setHeaderText(pht('Add Comment'))
->appendChild(
javelin_tag(