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

Split "Create Another Task" button into "Similar Task" and "Empty Task"

Summary: Looping on this interface is pretty useful but you don't always want to
keep the projects/owners.

Test Plan: Clicked both buttons.

Reviewers: btrahan

Reviewed By: btrahan

CC: anjali, aran, epriestley

Differential Revision: https://secure.phabricator.com/D1593
This commit is contained in:
epriestley 2012-02-08 09:44:22 -08:00
parent 3f46d30e8f
commit 7a5ec015d9
2 changed files with 20 additions and 2 deletions

View file

@ -1,7 +1,7 @@
<?php <?php
/* /*
* Copyright 2011 Facebook, Inc. * Copyright 2012 Facebook, Inc.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -225,6 +225,7 @@ class ManiphestTaskDetailController extends ManiphestController {
'</strong>'); '</strong>');
} else if ($workflow == 'create') { } else if ($workflow == 'create') {
$context_bar = new AphrontContextBarView(); $context_bar = new AphrontContextBarView();
$context_bar->addButton('<label>Create Another:</label>');
$context_bar->addButton( $context_bar->addButton(
phutil_render_tag( phutil_render_tag(
'a', 'a',
@ -232,7 +233,15 @@ class ManiphestTaskDetailController extends ManiphestController {
'href' => '/maniphest/task/create/?template='.$task->getID(), 'href' => '/maniphest/task/create/?template='.$task->getID(),
'class' => 'green button', 'class' => 'green button',
), ),
'Create Another Task')); 'Similar Task'));
$context_bar->addButton(
phutil_render_tag(
'a',
array(
'href' => '/maniphest/task/create/',
'class' => 'green button',
),
'Empty Task'));
$context_bar->appendChild('New task created.'); $context_bar->appendChild('New task created.');
} }

View file

@ -21,3 +21,12 @@
.aphront-contextbar-buttons { .aphront-contextbar-buttons {
float: right; float: right;
} }
.aphront-contextbar-buttons label {
font-weight: bold;
color: #666666;
}
.aphront-contextbar-buttons a {
margin: 0 0 0 .5em;
}