Commit graph

57 commits

Author SHA1 Message Date
a16a750180 Bug 17642: Add and use get_descriptions_by_koha_field
Ok I am silly, we needed to replace to use the cache mechanism for
search_by_koha_field, not find_by_koha_field...
Let's create another subroutine

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-11-18 15:52:00 +00:00
baf78b2a33 Bug 17253: Koha::AuthorisedValues - Remove GetKohaAuthorisedValues
This patch replaces the call to C4::Koha::GetKohaAuthorisedValues with
Koha::AuthorisedValues->search_by_koha_field

Test plan:
AV descriptions should be displayed on the following pages:
- XSLT view - location and ccode
- Bibliographic detail, moredetail and OPAC pages - location, ccode, copynumber
- returns - location
- opac-basket - ccode, location
- The 3 reports: catalogue_stats.pl, issues_stats.pl and
  reserves_stats.pl - location, ccode

Signed-off-by: Claire Gravely <claire_gravely@hotmail.com>

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-10-21 15:35:34 +00:00
9b9803b69c Bug 15758: Koha::Libraries - Remove GetBranchesLoop
Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-09-08 14:36:02 +00:00
66aacace08 Bug 16154: CGI->multi_param - Declare a list
This patch replaces the occurrences of
  my @foo = $cgi->param('foo');
with
  my @foo = $cgi->multi_param('foo');

perl -p -i -e
's/^(\s*my\s*@\w+\s*=\s*)\$(cgi|input|query)\->param\(/$1\$$2\->multi_param\(/xms'
**/*.pl

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
2016-04-26 23:16:42 +00:00
Julian Maurice
c6bddb9efd Bug 7683: Relabel "acquired date" and "removed date"
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-01-27 06:37:29 +00:00
Julian Maurice
7d03001c35 Bug 7683: Catalog statistics wizard: QA fixes
1/ Do not allow invalid date ranges (from > to) (datepicker only)
2/ Relabel "From:" to "From" for consistency
3/ Fix MIME type for CSV
4/ Use Koha::DateUtils instead of C4::Dates
5/ Use placeholders in SQL query

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-01-27 06:37:28 +00:00
Julian Maurice
45e3b57fcd Bug 7683: Fix a shift in date filter indexes
Date filter indexes are 13, 14, 15, 16,
not 14, 15, 16, 17

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>

Works, no koha-qa errors (some message for the deleted file)

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-01-27 06:37:28 +00:00
Julian Maurice
b8848f6aed Bug 7683: Remove dead code about dewey and lccn filters
$hasdewey and $haslccn were hardcoded to 0

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-01-27 06:37:28 +00:00
Julian Maurice
84ea840232 Bug 7683: Cataloguing statistics wizard improvements
- Add 3 options for cells value
  - Titles count "COUNT (biblionumber)"
  - Items count "COUNT (itemnumber)" (current behavior)
  - Deleted items count "COUNT (deleteditems.itemnumber)"

- Add to selectable rows, colums and filters:
  - items.notforloan
  - items.materials

  For each of these fields, retrieve the label in the default cataloging
  framework.
  If no MARC field is mapped to the field in question, it does not show
  this line in the wizard.
  If the MARC field is associated with a list of authorized values, it
  displays a dropdown list for the filter, otherwise it displays a text
  field.

- Add to selectable rows, columns and filters:
  - items.dateaccessioned (creation date)
  - deleteditems.timestamp (deletion date) (Only if the third option (eg
    count deleted items) is selected)

- Add unit tests for GetMarcSubfieldStructureFromKohaField

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-01-27 06:37:27 +00:00
30667f0555 Bug 14100: (follow-up) Language overlay for item types
Display the translated description for item types in the following pages:
> admin/smart-rules.pl
> catalogue/detail.pl
> catalogue/itemsearch.pl
> catalogue/moredetail.pl
> reports/acquisitions_stats.pl
> reports/bor_issues_top.pl
> reports/cat_issues_top.pl
> reports/catalogue_out.pl
> reports/catalogue_stats.pl
> reports/issues_avg_stats.pl
> reports/issues_stats.pl
> reports/itemslost.pl
> reports/manager.pl
> reports/reserves_stats.pl
> suggestion/suggestion.pl
> tools/export.pl

> Opac:
> opac-detail.pl
> opac-MARCdetail.pl
> opac-search.pl

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2015-10-27 12:34:06 -03:00
Jonathan Druart
a6c9bd0eb5 Bug 9978: Replace license header with the correct license (GPLv3+)
Signed-off-by: Chris Nighswonger <cnighswonger@foundations.edu>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
2015-04-20 09:59:38 -03:00
Jonathan Druart
e20270fec4 Bug 11944: use CGI( -utf8 ) everywhere
Signed-off-by: Paola Rossi <paola.rossi@cineca.it>
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Dobrica Pavlinusic <dpavlin@rot13.org>

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
2015-01-13 13:07:21 -03:00
Katrin Fischer
865996d097 Bug 12567: Make catalog statistics wizard publication year work for MARC21
Publication year was useless for MARC21, as it was using the
biblioitems.publicationyear (UNIMARC) instead of biblio.copyrightdate
(MARC21).

This patch tries to fix the search options to work for both MARC
flavours.

To test:
In Reports > Statistics wizards > Catalog:
- Test the publication year search options on a UNIMARC and
  a MARC21 installation.
- Make sure search results make sense for both.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
The changes are fine with me, but this script is certainly not bug free.
Also note that all its SQL should be moved out according to our
coding guidelines. When doing so, a rewrite would be appropriate.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
2014-12-01 10:18:29 -03:00
Bernardo Gonzalez Kriegel
9626daa220 Bug 12707: Remove CGI::scrolling_list from some Reports
This patch removes similar instances on 5 files, same code.
Also removes a commented one, changed in case some plan to
resurrect the code.

This bug depends on Bug 12696.

In all cases but the commented one, what was replaced
is a pulldown with one value, 'CSV'

To test:
1. Apply patch for Bug 12696
2. Apply this patch

Check for the pulldown 'Into an application'

3. Go to Reports > Statistics wizard > Borrowers
4. Go to Reports > Statistics wizard > Circulation
5. Go to Reports > Statistics wizard > Holds
6. Go to Reports > Top lists > Most-circulated items
7. Go to Reports > Inactive > Patrons who haven't checked out

8. There is also a commented code on catalogue_stats, no fuctional
changes.

Followed test plan. Patch behaves as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, passes tests and QA script.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
2014-08-15 14:47:23 -03:00
afd2418d73 Bug 11349: Change .tmpl -> .tt in scripts using templates
Since we switched to Template Toolkit we don't need to stick with the
sufix we used for HTML::Template::Pro.

This patch changes the occurences of '.tmpl' in favour of '.tt'.

To test:
- Apply the patch
- Install koha, and verify that every page can be accesed

Regards
To+

P.S. a followup will remove the glue code.

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
2014-07-17 11:05:49 -03:00
Dobrica Pavlinusic
95bf6fb012 Bug 7829 - reports/ remove all exit(1) for plack
In Bug 7772 Ian correctly noted that reports have exit(1) all over the place.
This is left over from old code, and this patch changes them to exit(0).

I decided to use plain exit as opposed to explicit exit(0) since it produces
cleaner code, but I'm welcoming suggestion on this.

Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-03-28 16:25:24 +02:00
b49a0a30a1 bug 4176: remove references to unimplemented system preference MIME
The intended functionality of this system preference was never
implemented.  To avoid template changes prior to 3.2.0, put in
hard-coded string 'CSV' to (accurately) identify the type of
the output files in the affected reports.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2010-10-21 21:36:45 -04:00
Donovan Jones
f1598406e5 Bug 2505 - Add commented use warnings where missing in the reports/ directory 2010-04-21 20:19:57 +12:00
Nahuel ANGELINETTI
c5dabb4ad1 (bug #4339) fix catalog stats
This fix the catalog stats to count items that have no barcode.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2010-04-16 07:17:11 -04:00
Lars Wirzenius
6e7a4d3a3d Fix FSF address in directory reports/
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
2010-03-16 20:17:55 -04:00
Matthias Meusburger
9a43a47755 MT 2051 : granular permissions for guided reports 2009-10-16 23:55:50 +02: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
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
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
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
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
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
Jesse Weaver
ac0d340bd5 kohabug 2345: bad comparisons pervade reports
This patch changes all $foo eq undef's to !defined($foo). It also makes misc/spellcheck_suggest/build_spellcheck_suggest.pl have proper syntax.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-07-27 06:11:08 -05:00
Ryan Higgins
a5eb233c0c Remove commented deprecated code and a useless query on items.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-06-02 00:50:32 -05:00
Ryan Higgins
dc7a542deb Update Catalog Stats report: / Remove lccn/loc filter, which seems to conflate marc21 010 and 050. / Update labels to reflect 3.0 terminology.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-05-27 07:33:32 -05:00
Joe Atzberger
bde1ac3e13 Add authorised values descriptions to selector for "location".
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-11 16:56:37 -05:00
Joe Atzberger
60262720f0 Item-level_itypes fix, addition of ccode vector and filter.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-11 16:56:27 -05:00
Joe Atzberger
63dd9232e8 reports subdir - Dates.pm integration and warnings fixes.
Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2007-12-04 18:21:02 -06:00
Chris Cormack
606ecb532a Patch from Joe Atzberger to remove $Id$ and $Log$ from scripts
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2007-10-18 16:27:04 -05:00
kados
4af7e13c70 Cleaning up perldocs for make utility that MJ wrote. I was getting a bunch
of warnings:

Manifying blib/man3/reports::cat_issues_top.3pm
reports/cat_issues_top.pl:40: Unknown command paragraph "=over2"
Manifying blib/man3/reports::acquisitions_stats.3pm
reports/acquisitions_stats.pl:40: Unknown command paragraph "=over2"
Manifying blib/man3/C4::Koha.3pm
C4/Koha.pm:1227: Unmatched =back
Manifying blib/man3/reports::catalogue_stats.3pm
reports/catalogue_stats.pl:38: Unknown command paragraph "=over2"
Manifying blib/man3/opac::opac-topissues.3pm
opac/opac-topissues.pl:39: Unknown command paragraph "=over2"
Manifying blib/man3/reports::issues_avg_stats.3pm
reports/issues_avg_stats.pl:39: Unknown command paragraph "=over2"
Manifying blib/man3/reports::borrowers_stats.3pm
reports/borrowers_stats.pl:40: Unknown command paragraph "=over2"
Manifying blib/man3/reports::bor_issues_top.3pm
reports/bor_issues_top.pl:40: Unknown command paragraph "=over2"
Manifying blib/man3/reports::catalogue_out.3pm
reports/catalogue_out.pl:39: Unknown command paragraph "=over2"
Manifying blib/man3/reports::borrowers_out.3pm
reports/borrowers_out.pl:39: Unknown command paragraph "=over2"
Manifying blib/man3/C4::Languages.3pm
C4/Languages.pm:445: Unmatched =back
Manifying blib/man3/reports::issues_stats.3pm
reports/issues_stats.pl:39: Unknown command paragraph "=over2"
Manifying blib/man3/C4::Acquisition.3pm
C4/Acquisition.pm:772: Unmatched =back
2007-07-08 15:36:59 +00:00
hdl
100e6a9808 functions that were in C4::Interface::CGI::Output are now in C4::Output.
So this implies quite a change for files.
Sorry about conflicts which will be caused.
directory Interface::CGI should now be dropped.
I noticed that many scripts (reports ones, but also some circ/stats.pl or opac-topissues) still use Date::Manip.
2007-04-24 13:54:28 +00:00
tipaul
8456bee398 improving issues_stats by adding location & itemcallnumber filters 2007-04-18 14:19:52 +00:00
tipaul
c596d55374 HUGE COMMIT : code cleaning circulation.
some stuff to do, i'll write a mail on koha-devel NOW !
2007-04-04 16:46:22 +00:00
tipaul
fc1342f73d rel_3_0 moved to HEAD 2007-03-09 15:12:54 +00:00
tgarip1957
5b41a8e262 New XML API 2006-09-11 17:41:54 +00:00
toins
4ce63a1391 sub getbranches renamed to GetBranches according to the coding guidelines 2006-07-21 09:44:37 +00:00
btoumi
83021c9219 bug fixing : modify variable name and delete condition useless now 2006-05-24 13:14:04 +00:00
tipaul
b38997925f big commit, still breaking things...
* synch with rel_2_2. Probably the last non manual synch, as rel_2_2 should not be modified deeply.
* code cleaning (cleaning warnings from perl -w) continued
2005-10-26 09:11:02 +00:00
hdl
7c8e0bd653 Bug Fixing : taking alphanumeric itemcallnumber into accounts. 2005-08-09 12:06:46 +00:00
hdl
60c06f16c7 Bug fixing :
Using holdingbranch and not Location to locate an item.
2005-08-02 15:49:25 +00:00
tipaul
64cd740d2b synch'ing 2.2 and head 2005-05-04 08:58:30 +00:00
hdl
2a9029faf1 Performance Improvements : Publisher lists and Item Codes becomes free input. 2005-03-29 14:21:37 +00:00
hdl
2506cd5dda fixing length on publishernames 2005-03-09 16:14:03 +00:00
hdl
6c3f4a3e58 Modifying 0 value display in templates 2005-03-09 12:31:45 +00:00
hdl
b6724d9442 including Null Values and improving result display 2005-03-08 18:14:40 +00:00