Add option to update bugs from classic interface

git-svn-id: svn://10.0.0.236/trunk@221351 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
ghendricks%novell.com 2007-03-05 22:36:45 +00:00
parent c3ad3fcc63
commit dc298dff2d
4 changed files with 10 additions and 7 deletions

View File

@ -84,9 +84,9 @@
</table>
<table>
[% IF run %]
<tr>
<th align="right">Build</th>
[% IF run %]
<td>
[% PROCESS select sel = { name => "caserun_build",
list => build_list,
@ -106,17 +106,19 @@
value="[% caserun.environment.id FILTER none %]"
[% END %]>
</td>
</tr>
[% END %]
<tr>
<th align="right">Assignee</th>
<td><input name="assignee" value="[% dotweak ? "--Do Not Change--" : caserun.assignee.login FILTER html %]"></td>
<th align="right" colspan="2">Attach [% terms.Bugs %]</th>
<th align="right">Attach [% terms.Bugs %]</th>
<td><input name="bugs">&nbsp;<a href="enter_bug.cgi?product=[% caserun.run.plan.product.name FILTER url_quote %]&caserun_id=[% caserun.id FILTER none %]" target="_blank"><img src="testopia/img/snew.gif" alt="Log a New Bug" title="Log a New Bug" style="vertical-align:text-bottom;" /></a>
<br><input type="checkbox" value="1" name="update_bug" id="update_bug">Update [% terms.bug %] status </td>
</tr>
</table>
<table>
<tr>
<td colspan="2">
<td colspan="2" valign="top">
<table>
<tr>
<th colspan="3" class="bz_row_header">Status</th>

View File

@ -109,7 +109,7 @@
[%##### Bugs #####%]
<div class="cc_xx">
<div style="float:left;">
Update bug status <input type="checkbox" value="1" name="up_bugs[% index %]" id="up_bugs[% index %]">
Update [% terms.bug %] status <input type="checkbox" value="1" name="up_bugs[% index %]" id="up_bugs[% index %]">
<div style="float:left;font-weight:bold;">[% terms.Bugs %] detected (all runs):</div>
<div class="cc_i">
[<span id="bgl[% index %]">

View File

@ -115,11 +115,12 @@
</tr>
[% END %]
</table>
<h3>Attributes</h3>
<h3>Attachments</h3>
<form action="[% action FILTER none %]" method="POST" enctype="multipart/form-data">
[% PROCESS testopia/attachment/table.html.tmpl
item = caserun.case
%]
<h3>Attributes</h3>
[% PROCESS testopia/caserun/form.html.tmpl %]
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@ -332,7 +332,7 @@ sub do_update {
# If there is not one, it will create it and switch to that.
$caserun = $caserun->switch($build,$env);
$caserun->set_status($status) if ($caserun->status_id != $status);
$caserun->set_status($status, $cgi->param('update_bug')) if ($caserun->status_id != $status);
$caserun->set_assignee($assignee) if ($caserun->assignee && $caserun->assignee->id != $assignee);
$caserun->append_note($notes) if ($notes && $caserun->notes !~ /$notes/);