[Koha-bugs] [Bug 14382] datepicker's dateFormat setting for reports is missing

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu Jun 25 05:30:18 CEST 2015


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14382

Amit <amitddng135 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #40594|0                           |1
        is obsolete|                            |

--- Comment #14 from Amit <amitddng135 at gmail.com> ---
Created attachment 40611
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=40611&action=edit
Bug 14382: Non-ISO Date parameters generate empty reports.

Works perfectly..

 Bug 14382: Non-ISO Date parameters generate empty reports.

The issue is that SQL expects ISO dates, but the user may wish to view dates
according to the dateformat system preference.

By detecting a date preference, the non-ISO dates can be converted to ISO dates
before being stuffed back into the SQL query to be executed.

TEST PLAN
---------
1) Add a report with date parameters.
   -- I used 'Holds placed in date range' from
      http://wiki.koha-community.org/wiki/SQL_Reports_Library
2) Set your dateformat to YYYY-MM-DD
3) Run the report
   -- Note the SQL reads
      "... BETWEEN '{date formatted in YYYY-MM-DD}'..."
   -- If there is supposed to be data, there is some.
4) Set your dateformat to MM/DD/YYYY
5) Run the report
   -- Note the SQL reads
      "... BETWEEN '{date formatted in MM/DD/YYYY}'..."
   -- If there is supposed to be data, there is none.
6) Apply patch
7) Repeat steps 2-5
   -- The SQL will always read YYYY-MM-DD (ISO) format.
   -- The report will have data, if there is some.
8) koha qa test tools.

Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg at gmail.com>
Signed-off-by: Amit Gupta <amit.gupta at informaticsglobal.com>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list