diff options
-rw-r--r-- | Bugzilla/Attachment.pm | 9 | ||||
-rw-r--r-- | Bugzilla/User.pm | 6 | ||||
-rw-r--r-- | template/en/default/admin/components/edit-common.html.tmpl | 15 | ||||
-rw-r--r-- | template/en/default/admin/components/edit.html.tmpl | 4 | ||||
-rw-r--r-- | template/en/default/admin/milestones/edit.html.tmpl | 6 | ||||
-rw-r--r-- | template/en/default/admin/versions/edit.html.tmpl | 4 | ||||
-rw-r--r-- | template/en/default/global/user-error.html.tmpl | 4 |
7 files changed, 26 insertions, 22 deletions
diff --git a/Bugzilla/Attachment.pm b/Bugzilla/Attachment.pm index a39dc3af4..3a8e7d5d5 100644 --- a/Bugzilla/Attachment.pm +++ b/Bugzilla/Attachment.pm @@ -565,7 +565,14 @@ sub _check_filename { my ($invocant, $filename) = @_; $filename = clean_text($filename); - $filename || ThrowUserError('file_not_specified'); + if (!$filename) { + if (ref $invocant) { + ThrowUserError('filename_not_specified'); + } + else { + ThrowUserError('file_not_specified'); + } + } # Remove path info (if any) from the file name. The browser should do this # for us, but some are buggy. This may not work on Mac file names and could diff --git a/Bugzilla/User.pm b/Bugzilla/User.pm index 8ad84cec7..c4a042cf6 100644 --- a/Bugzilla/User.pm +++ b/Bugzilla/User.pm @@ -2489,12 +2489,6 @@ Returns true if the user wants mail for a given set of events. This method is more general than C<wants_bug_mail>, allowing you to check e.g. permissions for flag mail. -=item C<is_mover> - -Returns true if the user is in the list of users allowed to move bugs -to another database. Note that this method doesn't check whether bug -moving is enabled. - =item C<is_insider> Returns true if the user can access private comments and attachments, diff --git a/template/en/default/admin/components/edit-common.html.tmpl b/template/en/default/admin/components/edit-common.html.tmpl index 069b56cfd..3e489af74 100644 --- a/template/en/default/admin/components/edit-common.html.tmpl +++ b/template/en/default/admin/components/edit-common.html.tmpl @@ -23,15 +23,16 @@ #%] <tr> - <td valign="top">Component:</td> - <td><input size="64" maxlength="64" name="component" + <th class="field_label"><label for="component">Component:</label></th> + <td><input size="64" maxlength="64" name="component" id="component" value="[%- comp.name FILTER html %]"></td> </tr> <tr> - <td valign="top">Component Description:</td> + <th class="field_label"><label for="[% desc_name FILTER html %]">Component Description:</label></th> <td> [% INCLUDE global/textarea.html.tmpl name = 'description' + id = 'description' minrows = 4 cols = 64 wrap = 'virtual' @@ -40,7 +41,7 @@ </td> </tr> <tr> - <td valign="top"><label for="initialowner">Default Assignee:</label></td> + <th class="field_label"><label for="initialowner">Default Assignee:</label></th> <td> [% INCLUDE global/userselect.html.tmpl name => "initialowner" @@ -52,7 +53,7 @@ </tr> [% IF Param('useqacontact') %] <tr> - <td valign="top"><label for="initialqacontact">Default QA contact:</label></td> + <th class="field_label"><label for="initialqacontact">Default QA contact:</label></th> <td> [% INCLUDE global/userselect.html.tmpl name => "initialqacontact" @@ -65,9 +66,7 @@ </tr> [% END %] <tr> - <td valign="top"> - <label for="initialcc">Default CC List:</label> - </td> + <th class="field_label"><label for="initialcc">Default CC List:</label></th> <td> [% INCLUDE global/userselect.html.tmpl name => "initialcc" diff --git a/template/en/default/admin/components/edit.html.tmpl b/template/en/default/admin/components/edit.html.tmpl index b5fc3c321..5236186cc 100644 --- a/template/en/default/admin/components/edit.html.tmpl +++ b/template/en/default/admin/components/edit.html.tmpl @@ -43,12 +43,12 @@ [% PROCESS "admin/components/edit-common.html.tmpl" %] <tr> - <td><label for="isactive">Enabled For [% terms.Bugs %]:</label></td> + <th class="field_label"><label for="isactive">Enabled For [% terms.Bugs %]:</label></th> <td><input id="isactive" name="isactive" type="checkbox" value="1" [% 'checked="checked"' IF comp.isactive %]></td> </tr> <tr> - <td>[% terms.Bugs %]:</td> + <th class="field_label">[% terms.Bugs %]:</th> <td> [% IF comp.bug_count > 0 %] <a title="[% terms.Bugs %] in component '[% comp.name FILTER html %]'" diff --git a/template/en/default/admin/milestones/edit.html.tmpl b/template/en/default/admin/milestones/edit.html.tmpl index 6a2be869e..ef4b7fcc4 100644 --- a/template/en/default/admin/milestones/edit.html.tmpl +++ b/template/en/default/admin/milestones/edit.html.tmpl @@ -38,17 +38,17 @@ <table border="0" cellpadding="4" cellspacing="0"> <tr> - <th valign="top"><label for="milestone">Milestone:</label></th> + <th class="field_label"><label for="milestone">Milestone:</label></th> <td><input id="milestone" size="20" maxlength="20" name="milestone" value=" [%- milestone.name FILTER html %]"></td> </tr> <tr> - <th align="right"><label for="sortkey">Sortkey:</label></th> + <th class="field_label"><label for="sortkey">Sortkey:</label></th> <td><input id="sortkey" size="20" maxlength="20" name="sortkey" value=" [%- milestone.sortkey FILTER html %]"></td> </tr> <tr> - <th><label for="isactive">Enabled For [% terms.Bugs %]:</label></th> + <th class="field_label"><label for="isactive">Enabled For [% terms.Bugs %]:</label></th> <td><input id="isactive" name="isactive" type="checkbox" value="1" [% 'checked="checked"' IF milestone.isactive %]></td> </tr> diff --git a/template/en/default/admin/versions/edit.html.tmpl b/template/en/default/admin/versions/edit.html.tmpl index 1de233567..497d67e2e 100644 --- a/template/en/default/admin/versions/edit.html.tmpl +++ b/template/en/default/admin/versions/edit.html.tmpl @@ -37,12 +37,12 @@ <table border="0" cellpadding="4" cellspacing="0"> <tr> - <th valign="top"><label for="version">Version:</label></th> + <th class="field_label"><label for="version">Version:</label></th> <td><input id="version" size="64" maxlength="64" name="version" value=" [%- version.name FILTER html %]"></td> </tr> <tr> - <th><label for="isactive">Enabled For [% terms.Bugs %]:</label></th> + <th class="field_label"><label for="isactive">Enabled For [% terms.Bugs %]:</label></th> <td><input id="isactive" name="isactive" type="checkbox" value="1" [% 'checked="checked"' IF version.isactive %]></td> </tr> diff --git a/template/en/default/global/user-error.html.tmpl b/template/en/default/global/user-error.html.tmpl index 5310952f2..636e26500 100644 --- a/template/en/default/global/user-error.html.tmpl +++ b/template/en/default/global/user-error.html.tmpl @@ -599,6 +599,10 @@ [% title = "No File Specified" %] You did not specify a file to attach. + [% ELSIF error == "filename_not_specified" %] + [% title = "No Filename Specified" %] + You must specify a filename for this attachment. + [% ELSIF error == "file_too_large" %] [% title = "File Too Large" %] [%# Convert maxlocalattachment from Mb to Kb %] |