Bugzilla – Attachment 80740 Details for
Bug 21005
Missing row/column defaults cause unexpected results in report wizards
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21005: Missing row/column defaults cause unexpected results in report wizards
Bug-21005-Missing-rowcolumn-defaults-cause-unexpec.patch (text/plain), 6.32 KB, created by
Jonathan Druart
on 2018-10-17 16:39:45 UTC
(
hide
)
Description:
Bug 21005: Missing row/column defaults cause unexpected results in report wizards
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2018-10-17 16:39:45 UTC
Size:
6.32 KB
patch
obsolete
>From 6a09ff8dbcff91209b768d8a840d91c0d964c733 Mon Sep 17 00:00:00 2001 >From: David Cook <dcook@prosentient.com.au> >Date: Fri, 10 Aug 2018 18:08:13 +1000 >Subject: [PATCH] Bug 21005: Missing row/column defaults cause unexpected > results in report wizards > >Some report wizards are missing row/column defaults, which sometimes return blank >pages (borrowers_stats.pl) or results always equalling 0, which a non-discerning >user may interpret incorrectly. > >If the DEBUG environmental variable is enabled, missing row/column choices will >actually cause fatal software errors as well, which is also undesirable for users. > >This patch adds default choices for row and column on >report wizards that had no radio buttons selected, so that a user >can't submit the form without choosing a row and column. This >prevents errors. > >To test: >1) Apply patch >2) Visit /cgi-bin/koha/reports/issues_avg_stats.pl >3) Visit /cgi-bin/koha/reports/borrowers_stats.pl >4) Visit /cgi-bin/koha/reports/catalogue_stats.pl >5) Visit /cgi-bin/koha/reports/issues_stats.pl >6) Observe that default choices for row/column are there > >Signed-off-by: Mark Tompsett <mtompset@hotmail.com> > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/reports/borrowers_stats.tt | 4 ++-- > koha-tmpl/intranet-tmpl/prog/en/modules/reports/catalogue_stats.tt | 4 ++-- > koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_avg_stats.tt | 4 ++-- > koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_stats.tt | 4 ++-- > 4 files changed, 8 insertions(+), 8 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/borrowers_stats.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/borrowers_stats.tt >index 984aa1744b..e6986fa628 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/borrowers_stats.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/borrowers_stats.tt >@@ -77,7 +77,7 @@ > <tr> > <td>Patron category</td> > <td><input type="radio" name="Line" value="categorycode" /></td> >- <td><input type="radio" name="Column" value="categorycode" /></td> >+ <td><input type="radio" checked="checked" name="Column" value="categorycode" /></td> > <td> > <select name="Filter" size="1" id="catcode"> > <option value=""></option> >@@ -137,7 +137,7 @@ > > <tr> > <td>Library</td> >- <td><input type="radio" name="Line" value="branchcode" /></td> >+ <td><input type="radio" checked="checked" name="Line" value="branchcode" /></td> > <td><input type="radio" name="Column" value="branchcode" /></td> > <td> > <select name="Filter" size="1" id="branch"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/catalogue_stats.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/catalogue_stats.tt >index a3462d6f2c..692b05ceaa 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/catalogue_stats.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/catalogue_stats.tt >@@ -99,7 +99,7 @@ > <tr> > <td>Item type</td> > <td><input type="radio" name="Line" value="[% item_itype | html %]" /></td> >- <td><input type="radio" name="Column" value="[% item_itype | html %]" /></td> >+ <td><input type="radio" checked="checked" name="Column" value="[% item_itype | html %]" /></td> > <td><select name="Filter" id="[% item_itype | html %]"> > <option value=""> </option> > [% FOREACH itemtype IN itemtypes %] >@@ -122,7 +122,7 @@ > </tr> > <tr> > <td>Home library</td> >- <td><input type="radio" name="Line" value="items.homebranch" /></td> >+ <td><input type="radio" checked="checked" name="Line" value="items.homebranch" /></td> > <td><input type="radio" name="Column" value="items.homebranch" /></td> > <td><select name="Filter" id="branch"> > <option value=""> </option> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_avg_stats.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_avg_stats.tt >index 8dcefd4b41..09d3966629 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_avg_stats.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_avg_stats.tt >@@ -77,7 +77,7 @@ > <tr class="hilighted"> > <td>Checkout date</td> > <td><input type="radio" name="Line" value="timestamp" /></td> >- <td><input type="radio" name="Column" value="timestamp" /></td> >+ <td><input type="radio" checked="checked" name="Column" value="timestamp" /></td> > <td > <label for="from">From</label> <input type="text" size="10" id="from" name="Filter" /> > <label for="to">To</label> <input size="10" id="to" name="Filter" value="" type="text" /> > <span class="hint">[% INCLUDE 'date-format.inc' %]</span> >@@ -118,7 +118,7 @@ > </tr> > <tr class="hilighted"> > <td>Patron category</td> >- <td><input type="radio" name="Line" value="borrowers.categorycode" /></td> >+ <td><input type="radio" checked="checked" name="Line" value="borrowers.categorycode" /></td> > <td><input type="radio" name="Column" value="borrowers.categorycode" /></td> > <td> > <select name="Filter" size="1" id="borcat"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_stats.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_stats.tt >index 5d13e19cf0..c39a606683 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_stats.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/issues_stats.tt >@@ -164,7 +164,7 @@ > <tr> > <td>Item type</td> > <td><input type="radio" name="Line" value="itemtype" /></td> >- <td><input type="radio" name="Column" value="itemtype" /></td> >+ <td><input type="radio" checked="checked" name="Column" value="itemtype" /></td> > <td><select name="Filter" id="itemtype"> > <option value=""> </option> > [% FOREACH itemtype IN itemtypes %] >@@ -175,7 +175,7 @@ > </tr> > <tr> > <td>Issuing library</td> >- <td><input type="radio" name="Line" value="branch" /></td> >+ <td><input type="radio" checked="checked" name="Line" value="branch" /></td> > <td><input type="radio" name="Column" value="branch" /></td> > <td><select name="Filter" id="branch"> > <option value=""> </option> >-- >2.11.0
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
|
Splinter Review
Attachments on
bug 21005
:
77644
|
80686
|
80687
| 80740 |
80741