Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 294941 Details for
Bug 406171
3.7: Description field in the bug status table.
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Bug status description patch (dkl)
status_desc.patch (text/plain), 8.28 KB, created by
David Lawrence
on 2008-02-14 20:00:47 UTC
(
hide
)
Description:
Bug status description patch (dkl)
Filename:
MIME Type:
Creator:
David Lawrence
Created:
2008-02-14 20:00:47 UTC
Size:
8.28 KB
patch
obsolete
>Index: editvalues.cgi >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/editvalues.cgi,v >retrieving revision 1.5 >diff -u -r1.5 editvalues.cgi >--- editvalues.cgi 28 Jan 2008 04:47:31 -0000 1.5 >+++ editvalues.cgi 14 Feb 2008 19:50:59 -0000 >@@ -132,6 +132,10 @@ > my $action = trim($cgi->param('action') || ''); > my $token = $cgi->param('token'); > >+# REDHAT EXTENSION START 406171 >+my $description = trim($cgi->param('description') || ''); >+# REDHAT EXTENSION END 406171 >+ > # Gives the name of the parameter associated with the field > # and representing its default value. > local our %defaults; >@@ -172,11 +176,12 @@ > sub display_field_values { > my $template = Bugzilla->template; > my $field = $vars->{'field'}->name; >+ > my $fieldvalues = > Bugzilla->dbh->selectall_arrayref("SELECT value AS name, sortkey" > . " FROM $field ORDER BY sortkey, value", > {Slice =>{}}); >- >+ > $vars->{'values'} = $fieldvalues; > $vars->{'default'} = Bugzilla->params->{$defaults{$field}} if defined $defaults{$field}; > $vars->{'static'} = $static{$field} if exists $static{$field}; >@@ -250,6 +255,11 @@ > # The bug status is a closed state, but they are open by default. > $dbh->do('UPDATE bug_status SET is_open = 0 WHERE value = ?', undef, $value); > } >+ # REDHAT EXTENSION START 406171 >+ unless ($cgi->param('description')) { >+ $dbh->do('UPDATE bug_status SET description = 0 WHERE value = ?', undef, $value); >+ } >+ # REDHAT EXTENSION END 406171 > # Allow the transition from this new bug status to the one used > # by the 'duplicate_or_move_bug_status' parameter. > Bugzilla::Status::add_missing_bug_status_transitions(); >@@ -385,6 +395,10 @@ > if ($field eq 'bug_status') { > $vars->{'is_open'} = $dbh->selectrow_array('SELECT is_open FROM bug_status > WHERE value = ?', undef, $value); >+ # REDHAT EXTENSION START 406171 >+ $vars->{'description'} = $dbh->selectrow_array('SELECT description FROM bug_status >+ WHERE value = ?', undef, $value); >+ # REDHAT EXTENSION END 406171 > } > > $template->process("admin/fieldvalues/edit.html.tmpl", $vars) >@@ -402,6 +416,10 @@ > my $valueold = trim($cgi->param('valueold') || ''); > my $sortkeyold = trim($cgi->param('sortkeyold') || '0'); > >+ # REDHAT EXTENSION START 406171 >+ my $descriptionold = trim($cgi->param('descriptionold') || ''); >+ # REDHAT EXTENSION END 406171 >+ > ValueMustExist($field, $valueold); > trick_taint($valueold); > >@@ -467,6 +485,17 @@ > > $vars->{'updated_value'} = 1; > } >+ >+ # REDHAT EXTENSION START 406171 >+ if ( $field eq 'bug_status' and $description ne $descriptionold ) { >+ trick_taint($value); >+ trick_taint($description); >+ $dbh->do("UPDATE $field SET description = ? WHERE value = ?", >+ undef, $description, $value); >+ $vars->{'updated_description'} = 1; >+ $vars->{'description'} = $description; >+ } >+ # REDHAT EXTENSION END 406171 > > $dbh->bz_commit_transaction(); > >Index: Bugzilla/Status.pm >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/Bugzilla/Status.pm,v >retrieving revision 1.3 >diff -u -r1.3 Status.pm >--- Bugzilla/Status.pm 12 Feb 2008 19:45:14 -0000 1.3 >+++ Bugzilla/Status.pm 14 Feb 2008 19:50:59 -0000 >@@ -37,6 +37,7 @@ > sortkey > isactive > is_open >+ description > ); > > use constant NAME_FIELD => 'value'; >@@ -50,6 +51,9 @@ > sub sortkey { return $_[0]->{'sortkey'}; } > sub is_active { return $_[0]->{'isactive'}; } > sub is_open { return $_[0]->{'is_open'}; } >+# REDHAT EXTENSION START 406171 >+sub description { return $_[0]->{'description'}; } >+# REDHAT EXTENSION START 406171 > > ############################### > ##### Methods #### >Index: template/en/default/admin/fieldvalues/edit.html.tmpl >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/template/en/default/admin/fieldvalues/edit.html.tmpl,v >retrieving revision 1.1.1.1 >diff -u -r1.1.1.1 edit.html.tmpl >--- template/en/default/admin/fieldvalues/edit.html.tmpl 19 Nov 2007 22:11:21 -0000 1.1.1.1 >+++ template/en/default/admin/fieldvalues/edit.html.tmpl 14 Feb 2008 19:50:59 -0000 >@@ -50,6 +50,14 @@ > [%- sortkey FILTER html %]"></td> > </tr> > [% IF field.name == "bug_status" %] >+ [%# REDHAT EXTENSION START 406171 %] >+ <tr> >+ <th align="right"><label for="description">Description:</label></th> >+ <td><input id="description" size="60" maxlength="255" name="description" value=" >+ [%- description FILTER html %]"> >+ <input type="hidden" name="descriptionold" value="[% description FILTER html %]"></td> >+ </tr> >+ [%# REDHAT EXTENSION END 406171 %] > <tr> > <th align="right"><label for="is_open">Status Type:</label></th> > <td>[% IF is_open %]Open[% ELSE %]Closed[% END %]</td> >Index: template/en/default/admin/fieldvalues/list.html.tmpl >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/template/en/default/admin/fieldvalues/list.html.tmpl,v >retrieving revision 1.1.1.1 >diff -u -r1.1.1.1 list.html.tmpl >--- template/en/default/admin/fieldvalues/list.html.tmpl 19 Nov 2007 22:11:21 -0000 1.1.1.1 >+++ template/en/default/admin/fieldvalues/list.html.tmpl 14 Feb 2008 19:50:59 -0000 >@@ -39,7 +39,6 @@ > [% delete_contentlink = BLOCK %]editvalues.cgi?action=del&field= > [%- field.name FILTER url_quote %]&value=%%name%%[% END %] > >- > [% columns = [ > { > name => "name" >Index: template/en/default/bug/knob.html.tmpl >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/template/en/default/bug/knob.html.tmpl,v >retrieving revision 1.2 >diff -u -r1.2 knob.html.tmpl >--- template/en/default/bug/knob.html.tmpl 13 Feb 2008 16:44:32 -0000 1.2 >+++ template/en/default/bug/knob.html.tmpl 14 Feb 2008 19:50:59 -0000 >@@ -38,9 +38,11 @@ > || !bug.everconfirmed && bug_status.name == "REOPENED") %] > [% PROCESS initial_action %] > [% NEXT IF bug_status.name == bug.bug_status %] >+ [%# REDHAT EXTENSION 406171 >+ # Added bug status description %] > <input type="radio" id="knob_[% bug_status.id FILTER html %]" name="knob" > value="[% bug_status.name FILTER html %]"> >- <label for="knob_[% bug_status.id FILTER html %]"> >+ <label for="knob_[% bug_status.id FILTER html %]" title="[% bug_status.description FILTER html %]"> > Change status to <b>[% get_status(bug_status.name) FILTER html %]</b> > </label> > [% IF bug.isopened && !bug_status.is_open %] >Index: template/en/default/global/messages.html.tmpl >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/template/en/default/global/messages.html.tmpl,v >retrieving revision 1.7 >diff -u -r1.7 messages.html.tmpl >--- template/en/default/global/messages.html.tmpl 12 Feb 2008 19:44:49 -0000 1.7 >+++ template/en/default/global/messages.html.tmpl 14 Feb 2008 19:50:59 -0000 >@@ -307,7 +307,9 @@ > > [% ELSIF message_tag == "field_value_updated" %] > [% title = "Field Value Updated" %] >- [% IF updated_value || updated_sortkey %] >+ [%# REDHAT EXTENSION START 406171 >+ # Added updated_description %] >+ [% IF updated_value || updated_sortkey || updated_description %] > Changes to the <em>[% value FILTER html %]</em> value of the > <em>[% field.description FILTER html %]</em> > (<em>[% field.name FILTER html %]</em>) field have been changed: >@@ -322,10 +324,14 @@ > [% IF updated_sortkey %] > <li>Field value sortkey updated to <em>[% sortkey FILTER html %]</em></li> > [% END %] >+ [% IF updated_description %] >+ <li>Field value description updated to <em>[% description FILTER html %]</em></li> >+ [% END %] > </ul> > [% ELSE %] > No changes made to the field value <em>[% value FILTER html %]</em>. > [% END %] >+ [%# REDHAT EXTENSION END 406171 %] > > [% ELSIF message_tag == "flag_cleared" %] > Some flags didn't apply in the new product/component
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 406171
:
290035
|
294687
|
294911
| 294941