Commit graph

199 commits

Author SHA1 Message Date
Matthias Meusburger
b529f00aa3 MT 2050 : Fast cataloging 2009-11-19 23:09:46 +01:00
Matthias Meusburger
9a43a47755 MT 2051 : granular permissions for guided reports 2009-10-16 23:55:50 +02:00
Matthias Meusburger
b87b3273a9 MT 1443 : better reports on items 2009-09-30 11:30:32 +02:00
Matthias Meusburger
90396d6fc5 Fix broken guided_reports.pl 2009-09-30 11:30:31 +02:00
Paul Poulain
95e571df60 check errors (not new_acq related) 2009-09-30 11:30:22 +02:00
Paul Poulain
11eb4b57af replace bookfunds by budgets & remove warns 2009-09-30 11:30:22 +02:00
Nahuel ANGELINETTI
ceefe1ad6a (bug #3557) fix bor_issues_top
Just add the condition where column is "None".
2009-09-30 11:30:12 +02:00
Nahuel ANGELINETTI
5feefe497d (bug #3512) fix acquisition reports and group by
This fix, just change a grep value that make different way to calculate the table depending on the choosen column and line.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2009-09-30 11:30:06 +02:00
Nahuel ANGELINETTI
8ef619bf74 (bug #3546) fix issues_stats
This fix the order of columns.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2009-08-25 20:23:24 -04:00
Garry Collum
c89ed2ca1d Bug 3420: Revised follow-up patch for 'patrons with no checkouts'
Comments out all warnings that were used for debugging.

Enables warnigns and fixes the resulting warnings.

This patch replaces the previous follow-up patch for bug 3420.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2009-08-20 21:01:16 -04:00
Garry Collum
315a541682 Bug 3420: Fixes 'Patrons with no checkouts' report.
Fixed typo in SQL statement.  Commented out some unused SQL statements.

Removed limit for itemtype (column not available in results) and added limit for branchcode.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2009-08-15 09:56:03 -04:00
Garry Collum
5d23aafbee Bug 2553: Alphabetizes library and itemtype dropdown lists in Lost Items report.
Form - Fixes alphabetization of dropdowns.

Results - Fixes format of "Date last seen" to be the system date preference.  Adds highlighting to the table.

Enables warnings. Pages generated no warnings.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2009-08-15 09:38:59 -04:00
Garry Collum
be1ef2b2fa Bug 2553: Alphabetization of branches in the catalogue stats report.
Improvement on previous patch by using GetBranchesLoop.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-22 10:17:53 -04:00
Garry Collum
8c1b8b47c5 Bug 2553: Alphabetization of branches in Checkout Statistics form.
Improvement of previous patch through the use of GetBranchLoop.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-22 10:17:51 -04:00
Garry Collum
88c0bbcef8 Bug 2553: Fixes the alphabetization of the drop-down lists for the Most-Circulated items report.
This patch alphabetizes the descriptions that appear in the  Library, Item type, and patron category drop-down lists of the Most-Circulated Items report form.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-20 21:14:30 -04:00
Garry Collum
aa79cce602 Bug 2553: Fixes the location drop-down alphabetization for the catalog statistics report form.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-20 21:14:24 -04:00
Garry Collum
50ddd8d060 Bug 2553: Fixes drop-down alphabetization for Circulation Statistics report form.
Fixes alphabetization for the item type, library and collection drop-down lists in the Checkout Statistics wizard form.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-20 21:14:22 -04:00
Garry Collum
36e0248231 Bug 2553: Fixes location drop-down alphabetization in Serials Statistics wizard form.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-20 21:14:16 -04:00
Garry Collum
b9a0c1644f Bug 3392: Fixes highlighting in Patrons with no Checkouts report.
Fixed class definition and moved the definition from the <td> tags to the <tr> tags.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-07-13 00:00:00 -04:00
b216babdf8 Fix bug 3330 - Report notes modification
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-06-15 12:43:18 -05:00
Henri-Damien LAURENT
89b537273d bug 3097: statistics on itemcount not working
replacing issues.itemnumber by statistics.itemnumber
since issues was not included in the query.
All statistics on circulation for item count were zeroed.

[RM note: specifically, this patch fixes the results
 when you set the 'cell value' to 'count unique items']

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-06-06 18:43:48 -05:00
Garry Collum
22b55a4a1d Bug 3022: Cataloging statistic wizard not pulling the itemtype data correctly.
Added code to detect if the syspref for item-level_itypes is being used.  The report now correctly returns data based on the syspref.  There are some pre-existing XML errors with the FORM view of catalogue_stats.pl.  I'll send a subsequent patch to deal with these.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-05-27 07:06:24 -05:00
a89c3085cf Bug 1542, fixing filter by area in reports dictionary
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-05-14 06:59:52 -05:00
Nahuel ANGELINETTI
b1180360a8 (bug #3196) fix itemlost.pl
This patch fix 3 things:
* fix order by
* take care of item_level-itype
* use join in sql query

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-05-11 08:34:07 -05:00
Nahuel ANGELINETTI
4dbe34f231 (bug #3174) fill borrower number, and show author and creation date in saved reports
This patch add 2 columns in "Use Saved" page whith creation date, and the creator id.
It fix the creation of a report, to save the borrowernumber in reports table(to show it after).

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-05-01 16:25:36 -05:00
60fc079cfb Update for bug 1545 allowing for the title to be edited
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-04-18 18:36:16 -05:00
834001ffbb Allowing users to edit saved sql in guided reports. Bug 1545
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-04-18 14:59:02 -05:00
Galen Charlton
ffe51d1c15 restored tab-delimited report download
Previous patch broke this, always providing the
guided report download in CSV format regardless of
whether CSV or tab-delimited was requested.

Also, default name of downloaded file is reportresults.csv
for CSV output and reportresults.tab for tab-delimited.

Also removed a couple subroutine prototypes that
were leading to unnecessary compile-time warnings
under use warnings.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-04-05 11:32:28 -05:00
Joe Atzberger
14be4400d8 Bug 3066 - Overhaul guided reports
execute_query now refactored, returns reliable results, does
zero presentation-layer crap.  Arguments reduced, client scripts
adapted to new API and performance improved.  Text::CSV now used
to generate CSV output, ensuring portability, encoding and accuracy.

Replaced tools/runreport.pl with misc/cronjobs/runreport.pl:
    ~ security fixed
    ~ documentation improved
    ~ TODO: finish sendmail option.

Bug 3077 also fixed.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-04-03 20:17:55 -05:00
Joe Atzberger
76d0e8d05b Condense inarticulate construction of TMPL structures.
Use map to replace multiple temporary hash constructions.
Also a minor POD fix.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-04-03 20:17:47 -05:00
Joe Atzberger
964e18e472 Sort collection codes by description for dropdown.
Collection code descriptions were otherwise displaying in an
unsorted order.  The result was not readable for any sufficiently
large number of ccodes.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-03-11 08:37:16 -05:00
Joe Atzberger
01b146d921 Fixing catalogue_out errors.
This script ran against biblioitems.itemtype instead of items.itype.
With that corrected, biblioitems is not used by the query.

Report also failed to check whether the item was currently checked out
(i.e., in the issues table) before declaring it an inactive,
uncirculating item!

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-03-11 08:36:47 -05:00
Nahuel Angelinetti
b61e083301 (bug #2854) add the possibility to make a fuzzy search on the barcode
This patch add a field that permit to make a "like" and "not like" filter on barcode in the catalog report.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-03-06 14:29:04 -06:00
Joe Atzberger
5a4032b2e3 catalogue_out report cleanup.
Warnings enabled, comparison adjusted to accomodate undef.
Hardcoded CGI::scrolling_list removed.
Sort order on item types corrected.  Unused dependencies commented out.
GetBranchesLoop used instead of copy/paste code.

NOTE: CSV output is not fixed by this patch.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-03-06 12:56:19 -06:00
Nahuel ANGELINETTI
6c5bf09326 (bug #2939) delete a warning
just add a default value to $sep

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-02-12 17:09:06 -06:00
Nahuel ANGELINETTI
720cddeca6 (bug #2938) add a serials subscriptions report
this patch add a report for serials.
It's have to limit branch/bookseller, and excluding expired serials.
It's possible to export in CSV format.
This patch will have another, to add this report in menus.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-02-02 08:41:48 -06:00
Nahuel Angelinetti
e5adbdcbd1 a more readable way to test an array size.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 19:59:12 -06:00
Allen Reinmeyer
338e0a0dd5 Bug #2760 wrong permissions for guided reports
Guided reports and dictionary access was dependant on the editcatalogue permission instead of the report permission.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-11-06 15:37:38 -06:00
Galen Charlton
da1085ccfa bug 2543: follow-up patch
Add 'use C4::Reports' lines that original patch
omitted.

Note that original patch prevented these two reports
from even compiling.  Not good.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-10-23 12:06:47 -05:00
Jesse Weaver
b8d8a0ec5a fix for bug 2543: report output by tabulation a bit too literal
This repurposes the Reports module for general reports, and moves its functionality to a different module, Reports::Guided. It also updates all of the reports that can export to correctly treat the 'tabulation' value of the 'delimiter' syspref.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-10-23 11:44:28 -05:00
Joe Atzberger
feed19f154 Patch security hole in vestigial report.
IMHO, this report should be removed in entirity because of its faulty
construction and total inability to distinguish between register "tills".
That is, it appears to be a valid accounting measure but isn't.
In any case, it let's not let just anybody run it!

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-10-23 11:15:28 -05:00
Nahuel Angelinetti
f6027eb426 Fix the CSV export, provide it in UTF-8
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-10-16 10:58:02 -05:00
Galen Charlton
851a693be4 bugfix: fixed reference to sort2 column in query
Fixes following error when using the patron statistics report:

DBD::mysql::st execute failed: Unknown column 'sort' in 'where clause' at /home/gmc/koha/dev/reports/borrowers_stats.pl line 127

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-10-16 10:39:29 -05:00
Nahuel Angelinetti
f620ced0b5 Add the feature to create reports with borrower's sex information(Men/Women) (bug #2671)
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-10-16 10:15:06 -05:00
Joe Atzberger
ee48f60a93 DHTMLcalendar should not be imported.
Changing these scripts as precursor to removing it from C4::Dates @EXPORT_OK

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-09-16 22:21:57 -05:00
Galen Charlton
c9d7c42a60 bug 2540: allow download of report
$error return C4::Reports::execute_query is
always defined.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-08-21 18:50:16 -05:00
Joe Atzberger
225e115a85 issues_stats returns empty results if row/column = items.ccode/datetime
Also added ESCAPE="HTML" to column/row headers because users may define
collections that include ampersands, like:
    B&T Rental--Fiction
The Tidy error associated would be:
    line 574 column 29 - Error: general entity "T" not defined and no default entity

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-08-21 16:50:43 -05:00
Vincent Danjean
c52357edc6 Still fixing permission and first line of scripts
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-08-20 20:23:54 -05:00
Chris Nighswonger
860f1f70e5 kohabug 2458 Disallowing non-SELECT SQL in reports module
This patch enforces SELECT-only SQL in the reports module.
It introduces code to check SQL in two places. The first is
when a save is attempted on a user constructed SQL statement.
If a non-SELECT SQL statement is entered, the user will be
presented with an error message and a button giving the
option of editing the SQL. The second is when any SQL is
executed. If execution of a non-SELECT SQL statement is
attempted, the user is presented with an error message and
instructed to delete that report as the SQL is invalid.

The second check is intended as a safety net as no non-SELECT
SQL should ever be saved.

It may be well to document the proper usage of the direct SQL
entry type report.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-08-08 10:52:34 -05:00
Chris Nighswonger
953a46a088 kohabug 2417 Removing hardcoded query limit from reports
This patch removes a hardcoded 'LIMIT 20' which was added to all report queries
thus limiting all reports to only the first twenty rows of applicable data. In
its place this patch introduces code to paginate through all applicable data,
regardless of how many rows are available. The code will also honor any user
defined 'LIMIT' in reports based on SQL entered directly by the user.

This patch also adds column labels to 'tab' and 'csv' files generated by reports.
NOTE: Only user defined 'LIMIT's apply to 'tab,' 'csv,' and 'text' files.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-08-04 15:26:50 -05:00