]> git.koha-community.org Git - koha.git/log
koha.git
6 years agoBug 20949: (follow-up) debian/control
Mirko Tietgen [Fri, 15 Jun 2018 10:34:51 +0000 (12:34 +0200)]
Bug 20949: (follow-up) debian/control

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 00b732db48d209908bd1982bbb007678335e7593)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20949: Koha depends on Clone
Mirko Tietgen [Fri, 15 Jun 2018 10:10:19 +0000 (12:10 +0200)]
Bug 20949: Koha depends on Clone

Clone was not declared a dependency before. It used to be a dependency
of Hash::Merge but isn't in the recent version.

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit f1a54e09d99eea391b71ceafc291cbca8c838da2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19502: Add POD for max_result_window
Julian Maurice [Mon, 25 Jun 2018 12:14:43 +0000 (14:14 +0200)]
Bug 19502: Add POD for max_result_window

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c3576b1adedc4dbcabb1eb833f33194f66db63bf)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19502: Remove debug warn
Julian Maurice [Mon, 25 Jun 2018 12:14:32 +0000 (14:14 +0200)]
Bug 19502: Remove debug warn

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1b01e7db0e19f69ab77660cd3a26b1636a7b01e1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19502: Retrieve index.max_result_window from ES
Julian Maurice [Tue, 5 Jun 2018 13:11:34 +0000 (15:11 +0200)]
Bug 19502: Retrieve index.max_result_window from ES

This avoid hardcoding '10000' in two different places and allow users to
adjust this setting.

Also, this patch fixes a bug when the search return less than 10000
results

Test plan:
1. Do a search that returns 10000+ records.
2. Note the warning above the pagination buttons
3. Go to the last page, no error
4. Change the ES setting:
   curl -XPUT http://elasticsearch/koha_master_biblios/_settings -d \
     '{"index": {"max_result_window": 20000}}'
5. Do another search that returns more than 10000 but less than 20000
6. Note that the warning does not show up
7. Go to the last page, still no error

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 619d693908b1eb5de3da0d1bb80cc6c3cbf51ab3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19502: (follow-up) Pass parameters to avoid making templates depend on search...
Nick Clemens [Thu, 19 Apr 2018 23:13:49 +0000 (23:13 +0000)]
Bug 19502: (follow-up) Pass parameters to avoid making templates depend on search engine

https://bugs.koha-community.org/show_bug.cgi?id=19502

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5e98e913dc98ced7167e73932ce865a952db6b1c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19502: Limit pagination to first 10000 results when using ES
Nick Clemens [Fri, 16 Mar 2018 11:10:37 +0000 (11:10 +0000)]
Bug 19502: Limit pagination to first 10000 results when using ES

This patch is to avoid hitting an error page. We should eventually make the
max number returned configurable for ES.

To test:
1 - Have Koha running ES with 10,000+ records
2 - Search for '*'
3 - Click 'Last' to view last page of results
4 - 'Cannot perform search' error
5 - Apply patch
6 - Search again
7 - View 'Last' page
8 - No error, you go to the last of 10000
9 - Note the warning above the pagination buttons

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 7bff14830df7eab4b9a6c57d017846af4f79da5e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 21009: Fix max length of inputs on editing/adding items
Jonathan Druart [Fri, 29 Jun 2018 17:09:07 +0000 (14:09 -0300)]
Bug 21009: Fix max length of inputs on editing/adding items

There is a "max length" value you can define at framework level to
limit the size of the input. But it is not taken into account on the
add/edit item form.

It is a regression that has been introduced by
  commit 47d2de9c024bfb93d56184f298f334b20685cd86
  Bug 12176: Remove HTML from additem.pl

max_length vs maxlength

Test plan:
- Define a maximum length for an item subfield
- Add or edit an item
=> Without this patch the maxlength attribute of the inputs are not
defined (maxlength="")
=> With this fix you will see the maxlength attributes correctly set
with the value you defined in the framework

Note:
We could/should set this value to the size of the DB column when mapped
For instance 952$u is mapped with items.uri, which is a varchar(255).
This length restriction should done at framework level

Signed-off-by: Pierre-Luc Lapointe <pierreluc.lapointe@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 73e9c077f6543a4b08f3d2e7394c1e667f0d24e5)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20710: Update MARC21 frameworks to Update 26 (April 2018)
Bernardo Gonzalez Kriegel [Fri, 4 May 2018 22:49:07 +0000 (19:49 -0300)]
Bug 20710: Update MARC21 frameworks to Update 26 (April 2018)

This bug add update 26 changes.

Update 26
http://www.loc.gov/marc/bibliographic/bdapndxg.html

New subfields 377$3, 380$3, 381$3, 383$3, 730$4

Codes
    Map 007/04 'x' new
    Map 007/06 'c' renamed

No auth changes

To test:
1) Apply Bug 19835
2) Apply this patch
3) Reload marc21 bibliografic frameworks, check loads ok
4) Clean your browser cache
5) Edit a new bib record, fire 007 plugin,
    for Map, 04 position, check new 'x'
    for Map, 06 position, check renamed 'c'

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b056933a366c46e16d92d36ee3976fa647f31186)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 12001: [17.11.X] correct ILSDI_Services.t UT
Fridolin Somers [Thu, 26 Jul 2018 11:26:16 +0000 (13:26 +0200)]
Bug 12001: [17.11.X] correct ILSDI_Services.t UT

extracted from commit in master :
6355791848 Bug 12001: Move GetMemberAccountBalance to Koha::Account->non_issues_charges

6 years agoBug 12001: [17.11.X] Remove simple calls to GetMemberAccountRecords
Nick Clemens [Wed, 18 Jul 2018 11:36:36 +0000 (11:36 +0000)]
Bug 12001: [17.11.X] Remove simple calls to GetMemberAccountRecords

I chose not to backport the main patchset as it was big and didn't apply
clean, however, this problem seems to be an issue in 17.11.x

This patchset removes the calls where only the total is fetched/used

Please consider for backport

To test:
1 - Have a patron with some fines
2 - View these pages and confirm fine amounts display:
    circ/circulation.pl
    opac/opac-main.pl
    opac/opac-reserve.pl
    opac/opac-user.pl
    reserve/request.pl
3 - Apply patch
4 - View pages again, confirm fines display correctly and no errors

6 years agoUpdate release notes for 17.11.08 release v17.11.08
Fridolin Somers [Thu, 26 Jul 2018 08:31:37 +0000 (10:31 +0200)]
Update release notes for 17.11.08 release

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoIncrement version for 17.11.08 release
Fridolin Somers [Thu, 26 Jul 2018 08:22:56 +0000 (10:22 +0200)]
Increment version for 17.11.08 release

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoTranslation updates for Koha 17.11.08
Koha translators [Thu, 26 Jul 2018 08:13:34 +0000 (05:13 -0300)]
Translation updates for Koha 17.11.08

6 years agoBug 20084: Fix Industrial2of5 and COOP2of5 patron card layouts
Victor Grousset [Thu, 25 Jan 2018 13:37:56 +0000 (14:37 +0100)]
Bug 20084: Fix Industrial2of5 and COOP2of5 patron card layouts

== Test plan ==
This is an oversimplification of a full patron card setup used in production.

1. Create a batch with 1 patron
2. Create a layout and set
     the name
     "Print card number as barcode"
     "Barcode type:" to "Code 39"
3. Create a card template without filling anything
4. Export the batch using the layout and template
5. You should have a white page with a barcode
     And no errors in the relevant log file
     This show that this setup isn't completely bogus
     (although Code 39 is the only type working...)
6. Layout: set "Barcode type:" to Industrial2of5
7. Export the batch
8. You should have a white page with no barcode
     And errors in the relevant log file
     "Invalid Characters"
     This is the bug.
9. Layout: set "Barcode type:" to COOP2of5
10. Export the batch
11. You should have a white page with no barcode
      And errors in the relevant log file
      "Invalid Characters"
      This is the bug.
12. Apply this patch
13. Retry with both non-working patches
    1. You should have a white page with a barcode
    2. And no errors in the relevant log file

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 2e237ce6fb02d82fae9d1162bbcfaf9dc2f25bb0)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 21054: Remove extraneous </body> tag from sco-main.tt
Nick Clemens [Mon, 9 Jul 2018 13:24:44 +0000 (13:24 +0000)]
Bug 21054: Remove extraneous </body> tag from sco-main.tt

To test:
1 - Enable sco and setup AutoSelfCheck
2 - Try to use self checkout and print receipt
3 - You shoudl be redirected to the login page
4 - Apply patch and restart all the things
5 - Try to use self checkout and print a receipt
6 - Success!

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d9a94cc7e5fbcf924a1368423179c7d05fa49c8b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20979: Fix confirm deletion popup when deleting a biblio
Jonathan Druart [Thu, 21 Jun 2018 21:06:00 +0000 (18:06 -0300)]
Bug 20979: Fix confirm deletion popup when deleting a biblio

When deleting an empty bib, error messages pops up "1 order(s) are
using this record. You need order managing permissions to delete this
record." even though user has superlibrarian permissions.  Prevents the
deletion of the bib record.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 48cecf7935728420567f62214c672c30e5fdfd7a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 21046: Return the correct borrowernumber when there is empty cardnumber(s)
Alex Arnaud [Fri, 6 Jul 2018 13:40:53 +0000 (13:40 +0000)]
Bug 21046: Return the correct borrowernumber when there is empty cardnumber(s)

Test plan:
  - Use a patron with an empty cardnumber to authenticate with ILSDI
    AuthenticatePatron
    (cgi-bin/koha/ilsdi.pl?service=AuthenticatePatron&username=userid&password=pass),
  - make sure you have other patron(s) with empty cardnumber and there
    borrowernumber is
    smaller than the one you authenticate with,
  - you should get a wrong borrowernumber,
  - apply this patch,
  - test again, you should get the right one

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e7501a92aa6b4ca91a55f984443cfcfbeb76a797)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19873: (QA follow-up) Prevent warnings
Julian Maurice [Fri, 20 Apr 2018 11:55:50 +0000 (13:55 +0200)]
Bug 19873: (QA follow-up) Prevent warnings

"Use of uninitialized value $operands[X] in string ne"

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 268ba1d5ec7ef66790583c877d5641f007550ad2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19873: Add unit tests
Alex Arnaud [Thu, 1 Mar 2018 13:23:44 +0000 (13:23 +0000)]
Bug 19873: Add unit tests

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 2fa350014905c43636c6bdf8df7eee54e1b7d901)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19873: Ability to search on 0 value
Alex Arnaud [Fri, 22 Dec 2017 14:18:44 +0000 (14:18 +0000)]
Bug 19873: Ability to search on 0 value

Test plan:
  - create a st-numeric index in zebra conf related to
    a numeric field
    i.e:
    yourindex 1=yourindex 4=109
  - fill a field with 0 in a biblio,
  - reindex your biblios,
  - search yourindex=0,
  - should not work,
  - apply this patch,
  - test again,
  - should work

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit bc41a490a1ecd14e31b36a4531ced1203c0ed608)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 17373: Add mappings for unimarc authorities - Match index
Alex Arnaud [Mon, 12 Mar 2018 16:12:20 +0000 (16:12 +0000)]
Bug 17373: Add mappings for unimarc authorities - Match index

Test plan:

1. apply patches

2. switch  SearchEngine syspref to ElasticSearch

3. load new mapping
(admin/searchengine/elasticsearch/mappings.pl?op=reset&i_know_what_i_am_doing=1)

4. load some unimarc authorities like the sample attached to bug 17373

5. reindex authorities
(./misc/search_tools/rebuild_elastic_search.pl -d -a -v)

6. search entire notice for shalev or שלו

7. you should find stuff

Signed-off-by: Nicolas Legrand <nicolas.legrand@bulac.fr>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 199c2f33d93a33bb56d422a6abdeb334fd988faf)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 17373: Elasticsearch - Authority mappings for UNIMARC - patch1
Fridolin Somers [Thu, 13 Oct 2016 07:45:40 +0000 (09:45 +0200)]
Bug 17373: Elasticsearch - Authority mappings for UNIMARC - patch1

This patch starts the UNIMARC mapping for ES.
It is needed to test.
More patches will come.

Signed-off-by: Nicolas Legrand <nicolas.legrand@bulac.fr>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 6271f6c1374ac2dad573ae6784d1632d626b14be)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20216: Correctly populate values in itemtype editor
Nick Clemens [Thu, 15 Feb 2018 17:05:29 +0000 (17:05 +0000)]
Bug 20216: Correctly populate values in itemtype editor

Caused by a bad merge conflict on bug 12768.

To test:
1 - Edit an item type, define a replacement cost,processing fee, and
remote image url
2 - Save the item type
3 - Values are correct in list
4 - Edit again
5 - note values in fields are not populated
6 - Save itemtype, values are lost
7 - Apply patch
8 - Repeat 1-4
9 - Values should be correctly populated and saved now

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Bug 20216: (follow-up) - Fix other use of remote_image

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e4301a52b83ca24876ff58fd78bee863df5ce398)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20008: Fix restrictions added from memberentry.pl if TimeFormat is 12hr
Kyle M Hall [Wed, 17 Jan 2018 19:30:06 +0000 (14:30 -0500)]
Bug 20008: Fix restrictions added from memberentry.pl if TimeFormat is 12hr

Test Plan:
1) Set TimeFormat to 12 hour
2) Add a restriction with an expiration date via memberentry.pl
3) Note the restriction exists, but has no expiration date
4) Apply this patch
5) Repeat step 2
6) Note the restriction exists and has an expiration date!

Signed-off-by: Roch D'Amour <roch.damour@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e2214f2b256e0a44e0936d3eb8e87ac02b40917e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 18856: (QA follow-up) Rename method to avoid confusion
Kyle M Hall [Thu, 11 Jan 2018 14:44:08 +0000 (09:44 -0500)]
Bug 18856: (QA follow-up) Rename method to avoid confusion

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Hmm. I would have liked the opac parameter even better ;)

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 1cb0147affce54f19004173456ff2f8027767b30)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 18856: Don't show cancel option for waiting holds in OPAC
Jonathan Druart [Wed, 10 Jan 2018 19:49:33 +0000 (16:49 -0300)]
Bug 18856: Don't show cancel option for waiting holds in OPAC

This is the alternative patch of Kyle's
"""
If a hold is 'waiting' for the patron to collect then the patron should
be prevented from cancelling the hold via their account in the opac.
If a patron tries to cancel the hold, Koha will give an 'are you sure'
alert and when you click Yes the page just refreshes and the hold
remains.
Staff can cancel the hold from the staff interface but they can then
action the waiting hold.
I think therefore that it is correct behaviour that a patron cannot
cancel a hold when it reaches waiting state via the opac but it would be
useful to either have a warning to prevent the cancellation or a useful
message when they attempt to do so.

The template was using a method that tells Koha if *staff* can cancel a
hold,
instead of patron.

Test Plan:
1) Set up a waiting hold
2) Try to cancel it from the opac
3) Note you cannot
4) Apply this patch
5) Reload the page
6) Note the cancel button has disappeared for found holds
"""

It sounds better to keep the ->is_cancelable method, for readability

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 710c0e5df644731cee15f91b4ebc62924f7f85c9)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19849: Make a string translatable again after a rebase error
Victor Grousset [Wed, 20 Dec 2017 16:13:40 +0000 (17:13 +0100)]
Bug 19849: Make a string translatable again after a rebase error

Bug 16621 reverted part of bug 12509
1. Log in the OPAC and staff interface
2. Restrict the user logged in the OPAC (restricting yourself works)
   Staff interface → Patron page → Restrictions → Add manual restriction
   Put this comment the "OVERDUES_PROCESS Give the books back or we're comming!"
3. Install the fr_FR locale and switch the interface to it
4. Go to OPAC: /cgi-bin/koha/opac-user.pl
5. Then you should see the ugly comment with "OVERDUES_PROCESS"
6. Apply this patch
7. Update the translation: ./translate update or equivalent
8. Open misc/translator/po/fr-FR-opac-bootstrap.po
9. Find the string containing "Restriction added by overdues process"
10. Remove the fuzzy flag
11. Install the language
12. Refresh the page in the OPAC
13. Then you should see the translation + the comment instead of "OVERDUES_PROCESS" + the comment

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5205359a5ada493eac34e1c14b7cd8bd1b1a24d5)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19849: Minor fixes & refactor of opac-reserve.tt & opac-user.tt
Victor Grousset [Wed, 20 Dec 2017 14:15:49 +0000 (15:15 +0100)]
Bug 19849: Minor fixes & refactor of opac-reserve.tt & opac-user.tt

- make next patch easely reviewable.
- fix lone quote. (Replace by <strong>
- add forgotten condition for 9999-12-31

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 418eae24ccdb6b85b70cb302735770ce986c3593)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 7136: Correct description of Grace period for subscriptions
Katrin Fischer [Wed, 16 May 2018 02:25:38 +0000 (02:25 +0000)]
Bug 7136: Correct description of Grace period for subscriptions

The grace period is used with the serialsUpdate.pl cronjob. It will
generate the next issue and set the one before to 'Late' with
an optional note.

There is on trace of a 'waiting' status for serials.

To test:
- check help file on the subscription edit form for
  the description of the 'Grace period'.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 51adaebe3d6b9be575159cb5e957894d3a2d4d2d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20507: Shelf browser does not update image sources when paging
Owen Leonard [Tue, 26 Jun 2018 13:05:42 +0000 (13:05 +0000)]
Bug 20507: Shelf browser does not update image sources when paging

This patch updates the shelfbrowser include so that the system
preference check for Coce will function correctly.

To test, apply the patch and test the OPAC shelf browser with each of
the enhanced content options enabled: Coce, Amazon, Google. In each
case, page through the shelf browser to confirm that covers load
correctly.

Signed-off-by: Cab Vinton <bibliwho@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 062cda474a09494325b69c95bbd1f95799044993)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 21029: Make "Suspend until:" translatable
Jonathan Druart [Wed, 4 Jul 2018 17:55:14 +0000 (14:55 -0300)]
Bug 21029: Make "Suspend until:" translatable

The label was part of the holds.js file. As .js files are never
translatable it needs to be moved to template level.

Test plan:
- Place a hold on an item
- Go to the patron account
- Click on the Suspend button on the holds tab
- View the modal, the label before the date field "Suspend until:" is
now translatable.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ad004d366b5a1210dfa0cd80ea9bc6dc280e400c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 21020: Fix return branch on transfer - SIP
Jonathan Druart [Fri, 29 Jun 2018 13:06:31 +0000 (10:06 -0300)]
Bug 21020: Fix return branch on transfer - SIP

Caused by
  commit 546379cc92b733cb29a0b70247a72c770afdad26
  Bug 17680: C4::Circulation - Remove GetItemIssue, simple calls

Since this commit AddReturn return a Koha::Issue object, not a hashref
with item's info.

Test plan:
1 - Enable SIP server on your test instance
   For kohadevbox:
   cp /etc/koha/SIPConfig.xml /etc/koha/sites/kohadev/
   create patron with user/pass term1/term1 and grant circulation
   privileges
2 - enable AutomaticItemReturn
3 - Checkin an item which will generate a transfer via SIP2:
   perl /home/vagrant/kohaclone/misc/sip_cli_emulator.pl -a localhost -p
   6001 -su term1 -sp term1 -l LPL --item {BARCODE} -m checkin -t
   CR
4 - Note no CT field
5 - Apply patch
6 - Repeate checkin via SIP2
7 - Transfer destination is correctly returned in CT

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a80f02df557d55f455c32d1d614352aa1961bfff)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20175: DBRev 17.11.07.001
Jonathan Druart [Mon, 12 Feb 2018 20:52:49 +0000 (17:52 -0300)]
Bug 20175: DBRev 17.11.07.001

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 5373bbaf5d1bdfcf997e0f9b2e67962c40374220)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20175: [sql_modes] (follow-up) Set a correct default value for club_enrollments...
Jonathan Druart [Wed, 7 Feb 2018 14:58:02 +0000 (11:58 -0300)]
Bug 20175: [sql_modes] (follow-up) Set a correct default value for club_enrollments.date_created

From comment 6:
"""
Can't recreate database, when creating table structure, I got:
there can be only one TIMESTAMP column with CURRENT_TIMESTAMP in DEFAULT
or ON UPDATE clause

I am on mysql 5.5.59, which is still default in jessie, more timestamp
columns are possible from mysql 5.6.5:
https://dev.mysql.com/doc/relnotes/mysql/5.6/en/news-5-6-5.html
"""

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit ffd7fa3a068ff60976b1cf6f94fd2a48ae2d619c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20175: [sql_modes] Set a correct default value for club_enrollments.date_created
Jonathan Druart [Mon, 5 Feb 2018 17:22:59 +0000 (14:22 -0300)]
Bug 20175: [sql_modes] Set a correct default value for club_enrollments.date_created

0000-00-00 00:00:00 is not a valid timestamp.

It will fix the installer and upgrade process

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 5a43228c547200e4b6d9f03fe25e98d124889226)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20977: Javascript vars used in confirm_deletion in catalog.js do not match string...
Kyle M Hall [Thu, 21 Jun 2018 15:11:54 +0000 (11:11 -0400)]
Bug 20977: Javascript vars used in confirm_deletion in catalog.js do not match strings in catalog-strings.inc

The naming mismatch can cause javascript errors.

Test Plan:
1) Confirm the string vars used in catalog.js match the ones in
   catalog-strings.inc

Signed-off-by: Pierre-Luc Lapointe <pierreluc.lapointe@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
6 years agoBug 20745: koha-zebra doesn't return the correct error codes
Tomas Cohen Arazi [Thu, 10 May 2018 15:37:53 +0000 (12:37 -0300)]
Bug 20745: koha-zebra doesn't return the correct error codes

This patch makes koha-zebra return 0 (or 1) even when verbose mode is
off. This made koha-zebra --start always return a failure even when the
daemon was correctly launched.

To test:
- Have Zebra running for kohadev instance on your KohaDevBox
- Run:
  $ sudo koha-zebra --stop kohadev && echo yay || echo doh
=> FAIL: 'doh' is printed
- Run:
  $ sudo koha-zebra --start kohadev e&& echo yay || echo doh
=> FAIL: 'doh' is printed as well
- Apply this patch
- Run:
  $ sudo perl misc4dev/cp_debian_files.pl
  $ sudo koha-zebra --stop kohadev && echo yay || echo doh
=> SUCCESS: 'yay' is printed
- Run:
  $ sudo koha-zebra --start kohadev e&& echo yay || echo doh
=> SUCCESS: 'yay' is printed
- Sign off :-D

Sponsored-by: ByWater Solutions
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 6ea48ca9345862fc655e0ef418ea91d040ead03a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20700: MARC21 add/update leader/007/008 codes (17.11.x version)
Bernardo Gonzalez Kriegel [Thu, 14 Jun 2018 14:42:20 +0000 (11:42 -0300)]
Bug 20700: MARC21 add/update leader/007/008 codes (17.11.x version)

For Koha 17.11.x version

This add/updates some codes from updates 22 (Apr/16)
and 23 (Nov/16)

Update 22 https://www.loc.gov/marc/up22bibliographic/bdapndxg.html

Sound Recording 007/03 n (new)
Sound Recording 007/10 n (new)
Sound Recording 007/01 r (new)
Sound Recording 007/01 s (new)

Update 23 https://www.loc.gov/marc/up23bibliographic/bdapndxg.html

Leader/18 n (new)
Music 008/20 p (new), b (renamed)

To test:
1) Apply the patch
2) Clean your browser cache
3) Go to cataloguing -> new record
4) Leader plugin: check leader/18, new option 'n'
5) 007 Plugin:
a) Sound recording
check 007/01 new 'r'
check 007/03 new 'n'
check 007/10 new 'n'
b) Electronic resource
check 007/01 new 's'
6) 008 Plugin: Music, check 008/20 renamed 'b', new 'p'

6 years agoBug 20709: (follow-up) Update GERMAN MARC frameworks to Update 26 (April 2018)
Katrin Fischer [Fri, 11 May 2018 05:52:51 +0000 (07:52 +0200)]
Bug 20709: (follow-up) Update GERMAN MARC frameworks to Update 26 (April 2018)

A follow-up in line with bug 20710.

Again, the files used here have been generated automatically
from the po files on translate.koha-community.org.

To test:
- Make sure the de-DE installer can install all mandatory files cleanly.

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Tested using de-DE installer, all files load Ok
No errors

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c058a4a4858d5c03841b88ba65d232a03046304d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20709: Update GERMAN MARC frameworks to Updates 23+24+25 (Nov 2016, May and Dec...
Katrin Fischer [Thu, 3 May 2018 22:32:26 +0000 (22:32 +0000)]
Bug 20709: Update GERMAN MARC frameworks to Updates 23+24+25 (Nov 2016, May and Dec 2017)

Translation of bibliographic and authority frameworks can be done
using translate.koha-community.org.

Updated and translated files will then be provided for download.

See: http://lists.koha-community.org/pipermail/koha-translate/2018-April/002721.html

To test:
- Verify SQL is correct and frameworks load without problem

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3f1f212553a329a5fbda51e2746fac91ec4fc37c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19835: (follow-up) Correct formatting in a few places
Katrin Fischer [Sat, 28 Apr 2018 20:54:14 +0000 (20:54 +0000)]
Bug 19835: (follow-up) Correct formatting in a few places

In some places - was used insted of --, changed for
consistency with existing descriptions.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1b8b3a7390f785b2fda403e679a1b34a730327c3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19835: Fix MARC21 frameworks revision date
Bernardo Gonzalez Kriegel [Thu, 26 Apr 2018 15:36:35 +0000 (12:36 -0300)]
Bug 19835: Fix MARC21 frameworks revision date

This followup updates revison number and date

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 77159706ca0226dccc56c2c50c161b5bd37e64ad)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19835: Fix repeatability on MARC21 subfields
Bernardo Gonzalez Kriegel [Thu, 26 Apr 2018 13:52:50 +0000 (10:52 -0300)]
Bug 19835: Fix repeatability on MARC21 subfields

This followup fixes all repeatability cases, from
updates 23+24+25 and a few older ones.

To test:
0) Apply both patches
1) Remove all your frameworks
2) Check mandatory bibliographic and authority files load without problem
3) Check repeatability...

Bibs and auth frameworks checked against LOC description.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c1f916c1aa6e4937eca2dcf5b6493368d18cbcae)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19835: Update MARC frameworks to Updates 23+24+25 (Nov 2016, May and Dec 2017)
Bernardo Gonzalez Kriegel [Thu, 26 Apr 2018 02:57:40 +0000 (23:57 -0300)]
Bug 19835: Update MARC frameworks to Updates 23+24+25 (Nov 2016, May and Dec 2017)

There are a bunch of updates, summary below

1) Update 23
1.a) Bibs
New fields: 647 885
New subfields
e in 752
0 in 257 377
3 in 382
4 in 752

Changes
028 redefined
a renamed in 028
b renamed in 046
d renamed in 046

1.b) Auth
New Fields: 075 147 447 547 677 747 885
New Subfields: 0 in 377

2) Update 24
2.a) Bibs
New subfields
b in 567
g in 340
i in 370 386
0 in many fields
2 in 567
3 in 370
4 in 370 386

Changes
g renamed in 370
4 'Relationship code' -> 'Relationship' many fields
4 'Relator code'      -> 'Relationship' many fields

2.b) Auth
New subfields
i in 370 386
0 in 050 052 053 055 060 065 070 080 087
3 in 370
4 in 370 386

Changes
g in 370
4 'Relationship code' -> 'Relationship' many fields
4 'Relator code'      -> 'Relationship' in 371

3) Update 25
3.a) Bibs
New fields: 758
New subfields
r in 777
u in 777
z in 777
1 in many fields

Changes
d renamed in 111 611 711 811
s repeatable in many fields

3.b) Auth
New subfields
1 in many fields

Changes
d in 111 411 511 711
s repeatable in many fields

For more detail:
Update 23
bibs https://www.loc.gov/marc/up23bibliographic/bdapndxg.html
auth https://www.loc.gov/marc/up23authority/adapndxf.html

Update 24
bibs https://www.loc.gov/marc/up24bibliographic/bdapndxg.html
auth https://www.loc.gov/marc/up24authority/adapndxf.html

Update 25
bibs https://www.loc.gov/marc/bibliographic/bdapndxg.html
auth https://www.loc.gov/marc/authority/adapndxf.html

To test:
1) Remove all your frameworks
2) Check mandatory bibliographic and authority files load without problem
3) Check new fields/subfields

Repeatability checks on followup

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5d79a95226d71482a1070e994746785ec7278542)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20793: (follow-up) Add style to the non-link hold count on detail page
Owen Leonard [Tue, 22 May 2018 16:29:09 +0000 (16:29 +0000)]
Bug 20793: (follow-up) Add style to the non-link hold count on detail page

This small follow-up changes the style on the bibliographic detail page
of the hold count so that it looks similar whether it's a link to holds
or not.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 05e612525bf8d92562ae9e17904a974913819125)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20793: Don't show a holds link in staff for users without permission
Katrin Fischer [Sun, 20 May 2018 00:42:28 +0000 (02:42 +0200)]
Bug 20793: Don't show a holds link in staff for users without permission

On the results list in staff the 'Holds (x)' link always shows
independent of the permissions of the staff user.

This patch tightens the permission checks on the result page
to explicitly check for the place_holds permission.

To test:
- Create a staff user with place_holds permission
- Check the result list, you should see 2 links to the
  holds page:
  - 'Place holds' on top of the results list
  - 'Holds (x)' at the bottom of each entry in the results
     list
  - Verify both links work
- Create a staff user without place_holds_permission
  - Without the patch you'll see the second link,
    but it will lead to a permission error
  - With the patch you'll still see the 'Holds (x)', but
    it will no longer be a link.
- Go to the detail page of a record with an existing hold.
  - Repeat test with both staff users.
  - One time the Hold information in the bibliographic information
    should show as a link, the other time as a simple text.

Displaying the information about existing holds still make sense
as this is the current beheviour.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e98d4d30cad78715e613f833ed2356070f9985ad)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20999: Remove invalid 'style="block"' from OPAC templates
Owen Leonard [Tue, 26 Jun 2018 15:17:21 +0000 (15:17 +0000)]
Bug 20999: Remove invalid 'style="block"' from OPAC templates

This patch removes an invalid attribute from OPAC template markup. There
should be no visible change to the OPAC.

To test, apply the patch and confirm that the following pages still look
correct when using various cover image sources: Coce, Amazon, Google:

 - Bibliographic detail page (opac-detail.pl)
   - The shelf browser
 - Catalog search results
 - Recent comments

Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d7ae1d65a461ed9f5052d45f3069a30f671660f1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20920: (follow-up) generated d/control
Mirko Tietgen [Fri, 29 Jun 2018 20:25:33 +0000 (22:25 +0200)]
Bug 20920: (follow-up) generated d/control

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit da51f6bcc9eb2bff48da2d7ca0efb7b791c62192)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20920: Add missing dependency on CGI::Compile
Jérôme Charaoui [Wed, 20 Jun 2018 18:25:20 +0000 (14:25 -0400)]
Bug 20920: Add missing dependency on CGI::Compile

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3b02a8d2da4b3a20bc3a4970b537066ff389b959)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20693: Update control file
Mirko Tietgen [Tue, 15 May 2018 11:58:03 +0000 (13:58 +0200)]
Bug 20693: Update control file

Auto-generated file.

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 2a6cad2fa9d8e4419be7538949b4ce9a758d0e9b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed
Mirko Tietgen [Tue, 15 May 2018 11:47:10 +0000 (13:47 +0200)]
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed

Add CGI::Emulate::PSGI to PerlDependencies.pm

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit f9e06c38495ad9b7c14a9866414c229da92833db)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20559: Occurrences of loading-small.gif still exist
Owen Leonard [Mon, 25 Jun 2018 14:54:08 +0000 (14:54 +0000)]
Bug 20559: Occurrences of loading-small.gif still exist

This patch removes some leftover references to a file which no longer
exists. In the OPAC, loading-small.gif was included in CSS which was
never used. In the staff client, loading-small.gif should have been
corrected to spinner-small.gif.

To test, apply the patch and go to Tools -> Batch record modification.

 - Submit a batch of records to modify
 - In the table of titles which will be modified, click the 'Show MARC'
   button.
   - The modal preview window should show "Loading" and an animated
     spinner before the MARC record is loaded.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6f047049ca973fe2cf02c7ce124fec0366c3f4fd)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20991: Do not lost patron's category when editing a patron
Jonathan Druart [Tue, 26 Jun 2018 16:04:01 +0000 (13:04 -0300)]
Bug 20991: Do not lost patron's category when editing a patron

If there is an error in the edit patron form the patron's category is
lost.
This seems to be a long standing bug.

Test plan:
- Edit an existing patron
- Change the patron category to a category that triggers the error that
the user is not in the right age range for that new category
- Save, error is triggered
=> Without this patch the patron category has been reset

You should also test different ways to edit/add a patron (quick add,
step 1)

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b3cd4a382ffad36668164749dafb58d48c00d7f1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 17886: Don't show option to add to existing list if there are no lists
Caitlin Goodger [Tue, 29 May 2018 17:32:12 +0000 (17:32 +0000)]
Bug 17886: Don't show option to add to existing list if there are no lists

This patch modifies the page for adding a title to a list so that the
"Add to existing list" option doesn't appear if there are no lists
defined.

TEST PLAN
---------
1) Make sure no lists exist at all.
2) Make there is at least one findable biblio record entered
3) Find that biblio record in the OPAC
4) Click 'Save to your lists'
   -- Notice that the whole save to list section is there.
5) Apply this patch
6) Click 'Cancel'
7) Click 'Save to your lists'
   -- Notice you can only add now, which makes sense.
8) Run koha qa test tools.

Perform the same tests in the staff client.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Followed the test plan and the patch works.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b6010314dfed0f35c87de1a6c8209cd3e8f8b3c8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20945: Escape SQL parameters when constructing download links
Nick Clemens [Thu, 14 Jun 2018 14:20:44 +0000 (14:20 +0000)]
Bug 20945: Escape SQL parameters when constructing download links

TO test:
1 - Create a report that takes a parameter
2 - Enter a parameter containing '%'
3 - Attempt to download report, note link is misconstructed
4 - Apply patch
5 - Reload
6 - Note URL is now correct

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 0557c0fd9c468fb32011897318fb239dcdc30bc8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20697: Bind calling GetAnalyticsCount to pref EasyAnalyticalRecords
Marcel de Rooy [Thu, 3 May 2018 10:33:19 +0000 (12:33 +0200)]
Bug 20697: Bind calling GetAnalyticsCount to pref EasyAnalyticalRecords

If you do not use the EasyAnalyticalRecords feature (introduced with
bug 5528), you will have a lot of warnings in zebra-output.log like:

zebrasrv(1096) [request] Search biblios ERROR 114 1 1+0 RPN @attrset Bib-1 @attr 1=8911 259186

They come from C4::Items::GetAnalyticsCount called by catalogue/detail.pl.
This sub starts a Zebra search on index 'hi' (Host-Item-Number).
If you do not use this field at all (related to 773$9 in MARC21), Zebra
returns an Unsupported Use attribute error (114).

In making this change, I added one minor change:
[1] Remove the commented GetAnalyticsCount in additem.pl and correcting
    indentation in that loop (removing tabs). So no change at all there.

NOTE: I will propose to bind the GetHostItemsInfo call in detail.pl and two
other scripts to this preference too on report 20702.

Test plan:
[1] If you use EasyAnalytics, verify that there is no change.
[2] If you do not, check the zebra-output.log. You should no longer see
    searches for Host-Item-Number with 1=8911. (As well as ERROR 114 on
    this index.)

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6ad2c1402fa3a8d419a357233a6e4ad19e58a3db)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 17869: Don't show pick-up library for list of holds in OPAC account when there...
Owen Leonard [Mon, 18 Jun 2018 18:29:57 +0000 (18:29 +0000)]
Bug 17869: Don't show pick-up library for list of holds in OPAC account when there is only one branch

This patch modifies the user summary page in the OPAC so that the
"pick up location" column isn't shown in the table of holds if there is
only one library defined.

To test, apply the patch and log into the OPAC as a user with one or
more holds.

 - In a system with more than one library defined the "Holds" tab of
   opac-user.pl should show a "Pick up location" column.

 - In a system with only one library defined there should be now "Pick
   up location" column.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 9d96e2142140b8184e77da038fde51c0f7000c87)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20893: batchRebuildItemsTables.pl has incorrect parameter
Nick Clemens [Thu, 7 Jun 2018 14:03:11 +0000 (14:03 +0000)]
Bug 20893: batchRebuildItemsTables.pl has incorrect parameter

To test:
1 - run batchRebuildItemsTables.pl with a valid biblionumber
   perl /usr/share/koha/bin/batchRebuildItemsTables.pl --where biblio.biblionumber=38483  -c
2 - Note it says 'undefined biblionumber
3 - Apply patch
4 - Do it again
5 - It works!

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 737702f9756f89f6f75b2a3323e03738234fa143)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 16653: (QA follow-up) Avoid a warning and remove unused variables
Julian Maurice [Mon, 25 Jun 2018 12:58:17 +0000 (14:58 +0200)]
Bug 16653: (QA follow-up) Avoid a warning and remove unused variables

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 73f37b3a561efe61832bde372ffc42fb9dd47f54)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 16653: Display number of checkouts when exporting 'Most-circulated items' as CSV
Jonathan Druart [Thu, 7 Jun 2018 14:47:46 +0000 (11:47 -0300)]
Bug 16653: Display number of checkouts when exporting 'Most-circulated items' as CSV

reports/cat_issues_top.pl does not export "Count of checkouts" column as CSV

To replicate:

1/ Make sure that test instance has circulation in a given date range
2/ Go to Home › Reports › Most-circulated items
3/ Select a date range
4/ Select 'To screen into the browser' radio button, click submit.
5/ Note that Columns 'Rank/Biblioitemnumbers', 'Global' and 'Count of checkouts' appear in screen output.
6/ Click the browser's back button
7/ Change output to 'To a file', click submit.

Without this patch:
the columns "100/", "Global" and "Total" are exported to the CSV file.
"100/" contains the rank, "Global" is still global, and the "Total" column is empty.

With this patch patch applied, the last column is filled and the "Total" line is removed

(This script is really dirty)

Signed-off-by: Pierre-Luc Lapointe <pierreluc.lapointe@inLibro.com>
(Yes it is)

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5bb6b6581c9385d693194338db3e7865d2c28409)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20903: Remove unnecessary category code parameters
Josef Moravec [Fri, 8 Jun 2018 09:43:13 +0000 (09:43 +0000)]
Bug 20903: Remove unnecessary category code parameters

Test plan:
0) Do no apply the patch
1) Have only one adults patrons category defined
2) Add a fine to child patron and pay it
3) Try to print the payment receipt (file printfeercpt.pl)
4) You see only ISE
5) Apply the patch
6) Try the printing again
7) Now you should see right receipt

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5f03b21cf3a7141dc0f2ae2b1922505d55d4cd34)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20998: Simplify the conditional statement
Jonathan Druart [Tue, 26 Jun 2018 15:37:19 +0000 (12:37 -0300)]
Bug 20998: Simplify the conditional statement

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d874e52cdc6bcb20ee12885b9ecec0f339d315db)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20998: Only perform quicksearch if patron found with cardnumber
Nick Clemens [Tue, 26 Jun 2018 15:02:02 +0000 (15:02 +0000)]
Bug 20998: Only perform quicksearch if patron found with cardnumber

This patch makes sure we have a patron before we try to access their
branchcode and allows search to work

To recreate:
1 - Enable 'IndependentBranches'
2 - Setup a patron with all permissions, but not a superlibrarian
3 - Login to staff client as that patron
4 - Click 'Patrons' in the toolbar and try a search
5 - Internal server error
6 - Apply patch
7 - Try the search again
8 - Success!

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3afc24c776a30fc510c23177548b8b26fd44c4c7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 21019: Fix display of patron's address on reserve pop-up on returns.pl
Jonathan Druart [Fri, 29 Jun 2018 12:53:27 +0000 (09:53 -0300)]
Bug 21019: Fix display of patron's address on reserve pop-up on returns.pl

Caused by
  commit 2b90ea2cb0e5e976de7ddef0151ae83d8ac578e6
  Bug 17829: Move GetMember to Koha::Patron

address variable has been replaced by boraddress (wrong resolution
conflict?)

It does not affect master (thanks bug 18789)

Test plan:
Confirm the address of the patron with a hold placed on the item is now
displayed when this item is checked in

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 years agoBug 18521: Fix key binding in the header
Alex Buckley [Thu, 24 May 2018 10:10:05 +0000 (10:10 +0000)]
Bug 18521: Fix key binding in the header

Moving the conditional block [% IF (CAN_user_circulate_circulate_remaining_permissions ) %] block up the checkin-search.inc file above the CAN_user_catalogue IF conditional block fixes this bug.

Test plan:
1. Go to the circ home page and confirm the following
keyboard shortcuts work:

Alt+q = goes to search catalog
Alt+w = goes to renew

2. Go to returns.pl and confirm the following  keyboard shortcuts work:

Alt+q = goes to renew
Alt+w = goes to search catalog

3. Apply patch

4. Restart apache2, memchached and plack

5. Confirm on the returns.pl the following keyboard shortcuts work:
Alt+q = goes to search catalog
Alt+w = goes to renew

Sponsored-By: Catalyst IT
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Followed the test plan and it works.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5c6c65476838d701b1f44199407efbade349967b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20879: Fix regression in shibboleth when ldap enabled
Martin Renvoize [Thu, 21 Jun 2018 07:28:08 +0000 (08:28 +0100)]
Bug 20879: Fix regression in shibboleth when ldap enabled

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c528c05f303d1d4c99680ebf61fb78a79b92bedf)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20972: Add a testcase for bug 20972
Colin Campbell [Fri, 22 Jun 2018 14:02:01 +0000 (15:02 +0100)]
Bug 20972: Add a testcase for bug 20972

Ensure all 10 characters of ISBN are preserved

And that ISBNs and EANs are correctly identidied in the PIA segment

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 82ce10dd2817e99aa138d87287d903e5c7539a0a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20972: If ISBN has 10 numbers only the first 9 numbers are used
xljoha [Thu, 21 Jun 2018 07:58:55 +0000 (09:58 +0200)]
Bug 20972: If ISBN has 10 numbers only the first 9 numbers are used

If ISBN has 10 numbers only the first 9 numbers are being added to the Edifact-message (PIA+5+3540556753:IB')

This is caused by wrong positioning of capturing parentheses in a regular expression.

Sponsored-by: Gothenburg University Library
Signed-off-by: Colin Campbell <colin.campbell@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b9bd93e9205d4b8344a77214fefb8efe2c84792e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20876: The form_serialized_itype cookie is not used and should be removed
Owen Leonard [Mon, 4 Jun 2018 14:40:03 +0000 (14:40 +0000)]
Bug 20876: The form_serialized_itype cookie is not used and should be removed

This patch removes references to a form_serialized_itype cookie which
appears in the code as part of the process of storing information used
in the generation of the "Return to the last advanced search" link.

To test, apply the patch and perform an advanced search in the OPAC
using several search options including a limit by item type. From the
search results page, follow the "Return to the last advanced search"
link. The advanced search form should appear with all the search options
you submitted before.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3b9a81e394c4f47433b3f0057b9b819549f583b8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20702: Bind results of GetHostItemsInfo to the EasyAnalyticalRecords pref
Marcel de Rooy [Thu, 3 May 2018 11:12:19 +0000 (13:12 +0200)]
Bug 20702: Bind results of GetHostItemsInfo to the EasyAnalyticalRecords pref

Triggered by the finding on bug 20697.
The three calls of GetHostItemsInfo should be controlled by the pref. This
patch makes the sub return an empty list when the pref is disabled.

The patch simplifies the sub by merging the two identical foreach loops
depending on the field number in MARC21/UNIMARC.

Will add a unit test on a follow-up patch.

Test plan:
See next patch.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 7861cc07ba8afdf09079c7b51fdb99ad99132688)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20702: Add unit tests for GetHostItemsInfo
Marcel de Rooy [Thu, 3 May 2018 12:08:01 +0000 (14:08 +0200)]
Bug 20702: Add unit tests for GetHostItemsInfo

Unfortunately, we did not have unit tests yet.
Adding some simple tests that test basic operation of the sub when the
pref is enabled/disabled and for MARC21/UNIMARC.

Test plan:
[1] Run t/db_dependent/Items/GetHostItemsInfo.t

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5462c1a88b2652fb25c67f40946436eb243d6ed1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20794: Hide holds tab on details when user lacks circulate_remaining_permissions
Katrin Fischer [Sun, 20 May 2018 02:23:47 +0000 (04:23 +0200)]
Bug 20794: Hide holds tab on details when user lacks circulate_remaining_permissions

If a user doesn't have circulate_remaining permissions, but has borrowers:
- checkouts tab is hidden
- details tab is visible
- holds tab on details is visible, but results in an error

The problem is that the svc/holds script requires circulate_remaining_permissions.

To test:
- Create 2 staff users with and without circulate_remaining_permissions
  Both need borrowers permission
- Go to the details tab in a patron's account who has holds
- Verify that you get a datatables error for the staff patron without
  circulate_remaining_permissions
- Apply patch
- Verify that now the holds tab is no longer displayed for this patron

Signed-off-by: Amit Gupta <amit.gupta@informaticsglobal.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b3d1a5bfecbfbac4af8335757414def1ee3e2df5)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20881: Order receiving: Price filter missing on_editing
Pasi Kallinen [Tue, 5 Jun 2018 10:26:43 +0000 (13:26 +0300)]
Bug 20881: Order receiving: Price filter missing on_editing

When the Price-filter is used on editable data, it should have the
on_editing -tag. Add it to the orderreceive.tt

Signed-off-by: Pasi Kallinen <pasi.kallinen@joensuu.fi>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
To test:
- Set CurrencyFormat to FR
- Create a basket with orders in acq
- Close it
- Receive shipment and pick order line to receive
- On this screen verify that the actual cost appears as comma-separated
- Apply patch
- Refresh page
- Verify that the actual cost now appears .-separated

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 279e328cdda0e3e17c244a39b933ce898bc5bee2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge
Fridolin Somers [Fri, 15 Jun 2018 10:56:36 +0000 (12:56 +0200)]
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge

Koha::Patron::Discharge was missing use Koha::Patron::Debarments used in discharge() method.

Test plan :
1) Enable pref useDischarge
2) Go to OPAC user page
3) Go to 'ask for a discharge' tab
4) Click on 'Ask for a discharge'
5) Go to staff interface : /cgi-bin/koha/members/discharges.pl
6) Click on Allow
=> Without patch you get software error
=> With patch the discharge is validated

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 842abeb423b81c61d2774f8446a5bcbb2d0a258c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20906: Fix translatable-templates.t
Jonathan Druart [Fri, 8 Jun 2018 16:06:58 +0000 (13:06 -0300)]
Bug 20906: Fix translatable-templates.t

From Jenkins:
koha_1       | #   Failed test 'staff_prog templates are translatable'
koha_1       | #   at xt/author/translatable-templates.t line 87.
koha_1       | # Can't locate TmplTokenizer.pm in @INC (you may need to install the TmplTokenizer module) (@INC contains: /kohadevbox/koha /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at ./tmpl_process3.pl line 20.

On Stretch, '.' is not longer added to @INC, see bug 17717 for more info

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1600d82c610aba303ea0cb1f31f1a81d36483ffb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20906: Prevent test failures due to precision changes (2)
Martin Renvoize [Fri, 8 Jun 2018 14:21:22 +0000 (15:21 +0100)]
Bug 20906: Prevent test failures due to precision changes (2)

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a19c161675840c7a5f6546da3d678149d31e260b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20906: Prevent test failures due to stricter perl
Martin Renvoize [Fri, 8 Jun 2018 13:32:02 +0000 (14:32 +0100)]
Bug 20906: Prevent test failures due to stricter perl

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit baf43e6a5b1ddd57306ef779d725e05534aad92b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20906: Prevent test failures due to precision changes
Martin Renvoize [Fri, 8 Jun 2018 11:50:31 +0000 (12:50 +0100)]
Bug 20906: Prevent test failures due to precision changes

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b13429395830f3f84bc551d769e2ee28c7a740ed)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoUpdate release notes for 17.11.07 release v17.11.07
Fridolin Somers [Mon, 25 Jun 2018 13:04:03 +0000 (15:04 +0200)]
Update release notes for 17.11.07 release

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoIncrement version for 17.11.07 release
Fridolin Somers [Mon, 25 Jun 2018 12:22:08 +0000 (14:22 +0200)]
Increment version for 17.11.07 release

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoTranslation updates for Koha 17.11.07
Koha translators [Mon, 25 Jun 2018 12:14:05 +0000 (09:14 -0300)]
Translation updates for Koha 17.11.07

6 years agoBug 17111 - Automatic debian/control updates (oldstable/17.11.x)
Nightly Build Bot [Fri, 15 Jun 2018 11:34:10 +0000 (13:34 +0200)]
Bug 17111 - Automatic debian/control updates (oldstable/17.11.x)

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
6 years agoBug 19970: (17.11.x) Revise change of bug 19413 to work better for translations
Owen Leonard [Mon, 18 Jun 2018 12:05:06 +0000 (12:05 +0000)]
Bug 19970: (17.11.x) Revise change of bug 19413 to work better for translations

This patch changes how the submit and cancel buttons appear in the MARC
008 plugin window. The controls are now displayed as buttons in a
floating toolbar.

To test you must have MARC tag 008 configured to use the
marc21_field_008.pl plugin.

- Apply the patch and open an existing or blank record in cataloging.
- Click the plugin link next to tag 008 to trigger the popup window.
- Confirm that "Save" and "Cancel" appear correctly in a toolbar.
- Scroll down the page to confirm that the toolbar "sticks" to the top
  of the window.
- Confirm that the "Save" and "Cancel" buttons work correctly.

6 years agoBug 20285: Lost item refund won't always pay down lost item fee first
Kyle M Hall [Fri, 23 Feb 2018 13:44:45 +0000 (08:44 -0500)]
Bug 20285: Lost item refund won't always pay down lost item fee first

Due to a simple typo, the accountline passed to Koha::Account::pay from _FixAccountForLostAndReturned is not used. That means that the credit for the lost item fee may be applied to other fees before it is used on the lost fee itself.

Test Plan:
1) Find a patron with existing fines
2) Ensure your settings will charge patrons for lost items
3) Check out an item to a patron with existing fees that need paid
4) Mark the item lost, charging the lost item fee
5) Return the item
6) Note the fee was refunded, but it paid down earlier fines first,
   and not the lost item fee first
7) Apply this patch set
8) Repeat steps 1 - 5
9) Note the lost item fee is the first fee to be paid off by the lost
   item fee refund

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Followed the test plan and it works as expected.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 2f2a5b2c58f49e2635a38040fa0130d5f2677488)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20285: Unit Test
Kyle M Hall [Fri, 23 Feb 2018 13:44:24 +0000 (08:44 -0500)]
Bug 20285: Unit Test

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 096ba7d34cd08fcafed0aef2fcf272907cba55f0)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20760: Fill authorised values in svc framework
Jonathan Druart [Mon, 4 Jun 2018 16:02:33 +0000 (13:02 -0300)]
Bug 20760: Fill authorised values in svc framework

To test:
 1 - Map a marc field to an authorised value in the default framework -
say 300$c -> CCODE
 2 - Open the advanced cataloguing editor
 3 - Create a new field 300$c - note there is no dropdown
 4 - browse to: /cgi-bin/koha/svc/cataloguing/framework?callback=define
 5 - Note the many instance of
Koha::Schema::ResultSet::AuthorisedValueCategory->HASH...
 6 - Apply patch
 7 - Restart memcached and plack
 8 - reload/recreate record in rancor
 9 - Note that 300$c is now a dropdown as expected
10 - repeate 4
11 - note the authorised values look correct in response

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ac390bd228c6ea7eab7c8b694a378a837f8da464)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20911: Use 'POST' to submit search history forms
Nick Clemens [Mon, 11 Jun 2018 15:28:19 +0000 (15:28 +0000)]
Bug 20911: Use 'POST' to submit search history forms

To test:
1 - Enable EnableOpacSearchHistory and EnableSearchHistory
2 - Do some searches
3 - View your search history in staff/opac
4 - Confirm you can delete single or multiple rows
5 - Confirm other page functionality has not changed

Signed-off-by: Ed Veal <eveal@mckinneytexas.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e4c26c44d3c70cf62225361a4cce94e1f5aa16c8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20892: Correct basketgroup link in histsearch.pl
Fridolin Somers [Thu, 7 Jun 2018 13:59:39 +0000 (15:59 +0200)]
Bug 20892: Correct basketgroup link in histsearch.pl

When searching an order, histsearch.pl page, you see if exists the backetgroup as a link.
This link is composed of "basketgroup.pl?booksellerid=xxx", it must also contain "basketgroupid=xxx" and "opa=add".

See Bug 11429 for example.

Test plan :
1) Create an order in a basket and add it to a basketgroup
2) Search for this order, you get to page histsearch.pl
3) Check clicking on basketgroup id leads to basketgroup details page

Signed-off-by: Amit Gupta <amit.gupta@informaticsglobal.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e60226e40117e50a5fcc51b125cac22036dfb32f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20922: Remove use of Koha::Number::Price in updatedatabase.pl
Jonathan Druart [Tue, 12 Jun 2018 16:12:25 +0000 (13:12 -0300)]
Bug 20922: Remove use of Koha::Number::Price in updatedatabase.pl

Koha::Number::Format->round use Number::Format->round with a precision=2
We should use it directly instead of Koha::* modules. It will avoid the
DB entry to fail because schema changes.

From the koha-devel list:

http://lists.koha-community.org/pipermail/koha-devel/2018-June/044608.html

16.06.00.042

Upgrade to 16.06.00.041 done (Bug 14629 - Add aggressive ISSN matching
feature equivalent to the aggressive ISBN matcher)
DBD::mysql::st execute failed: Unknown column 'me.p_sep_by_space' in
'field list' [for Statement "SELECT `me`.`currency`, `me`.`symbol`,
`me`.`isocode`, `me`.`timestamp`, `me`.`rate`, `me`.`active`,
`me`.`archived`, `me`.`p_sep_by_space` FROM `currency` `me` WHERE (
`active` = ? )" with ParamValues: 0=1] at
/usr/local/share/perl/5.24.1/DBIx/Class/Storage/DBI.pm line 1836.
DBIx::Class::Storage::DBI::_dbh_execute(): Unknown column
'me.p_sep_by_space' in 'field list' at
/inlibro/git/koha-csf-prod-inlibro/Koha/Objects.pm line 209

Basically, the update code uses Koha::Number::Price, which in full
modern object mode goes for its newly added *p_sep_by_space* _in the
18.05 code_.  But the DB doesn't have it yet (it comes with 17.12.00.022).

Signed-off-by: Blou <philippe.blouin@inlibro.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 93de5885098b9982a3ab9ad73ff73111d71ac3ef)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20851: Add module to circ/article-request-slip.pl
Marcel de Rooy [Fri, 1 Jun 2018 07:21:48 +0000 (09:21 +0200)]
Bug 20851: Add module to circ/article-request-slip.pl

See bug 20468, comment7.
Although the script seems to compile well, we better add the module here.
Trivial change.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 84fd5b109e24e7c1ee67d7bb0c7ff1fb9776c8de)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20829: Handle non-existent barcode when linking to host item
Jonathan Druart [Wed, 30 May 2018 15:10:58 +0000 (12:10 -0300)]
Bug 20829: Handle non-existent barcode when linking to host item

Since commit 2c9aeb9b0f4449d1a25274b8fbf8dae4ec11d3bf
  Bug 18277: Remove GetBiblionumberFromItemnumber - linkitem

$item is not defined if the barcode is invalid, we should not call
method on it in that case.

Test plan:
- Turn on EasyAnalyticalRecords
- Go to a detail page
- Edit > Link to host item
- Enter an invalid barcode
=> With the patch you get a friendly error message
=> Without this patch it explodes with
Can't call method "itemnumber" on an undefined value at
/home/vagrant/kohaclone/cataloguing/linkitem.pl line 86.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b004818515a5b5fbc7748da614b758d1516c0ff2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 19972: Make holds to pull list honors item-level_itypes syspref
Victor Grousset [Tue, 16 Jan 2018 09:06:20 +0000 (10:06 +0100)]
Bug 19972: Make holds to pull list honors item-level_itypes syspref

And reflect that in the UI strings + variable names

Test plan:
1. Set syspref "item-level_itypes" to "specific item"
2. Create a hold on a record with one item
3. Change the document type of the item
4. Check that the item edition page and the record page show 2 different
     types.
5. Go to /cgi-bin/koha/circ/pendingreserves.pl
6. Check that the displayed type is the item one
7. Set syspref "item-level_itypes" to "biblio record"
8. Go to /cgi-bin/koha/circ/pendingreserves.pl
9. See that the displayed type is the item one. When the sysopref says
     "record"
     This is the bug.
10. Apply this patch
11. Go to /cgi-bin/koha/circ/pendingreserves.pl
12. See that the displayed type now follows the syspref
13. Set syspref "item-level_itypes" to "specific item"
14. Go to /cgi-bin/koha/circ/pendingreserves.pl
15. See that the displayed type still follows the syspref

Signed-off-by: Lucie Gay <lucie.gay@ens-paris-saclay.fr>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 4c9b26e437f70f9ad422586cc3a40812aa660aff)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 18821: (QA follow-up) Last tweaks for performance
Marcel de Rooy [Fri, 1 Jun 2018 09:00:57 +0000 (11:00 +0200)]
Bug 18821: (QA follow-up) Last tweaks for performance

[1] passing unsafe has no use since it is a scalar, removed it to unconfuse
[2] remove caching when pref is disabled
[3] caching userid removes the need for calling Patron->find each time
[4] subsequent changes in unit test
[5] cosmetic renames to move from session to daily basis (changed dev angle)

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
First call going thru Koha::Patron takes about 0.0150 sec.
Subsequent calls only use caching and take about 0.0006 sec.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 2bae585fcd4d5a5e31c0503cc8ea1cd3ea0f29ba)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 18821: Convert to using cache with date checking
Kyle M Hall [Sat, 26 May 2018 06:40:24 +0000 (06:40 +0000)]
Bug 18821: Convert to using cache with date checking

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1e19bb32844dedc3d2d4d506e22f60bfac2b4057)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 18821: TrackLastPatronActivity is a performance killer
Kyle M Hall [Mon, 7 May 2018 17:29:12 +0000 (17:29 +0000)]
Bug 18821: TrackLastPatronActivity is a performance killer

Test Plan:
1) Apply this patch
2) Start a new session ( a private browser window works well )
3) Note the lastseen column in the borrowers table is updated
4) Browse a few pages, not the lastseen column is not updated again
5) Close the browser window and repeat steps 2-4
6) prove t/db_dependent/Auth.t

Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 0aa5eec2332f0e0ae7f6adefebc274b02f8830c5)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20546: Display shelving location on checkin
Magnus Enger [Mon, 9 Apr 2018 10:39:23 +0000 (12:39 +0200)]
Bug 20546: Display shelving location on checkin

Currently, the sehlving location is not being displayed in the table
of checked in items on <intranet>/cgi-bin/koha/circ/returns.pl

To test:
- Make sure you have a couple of books with a value for shelving location (952$c)
- Check the books out
- Check the books in
- Verify nothing is displayed in the "Shelving location" column
- Apply this patch
- Check the books out and in again
- Verify the shelving location is now being displayed

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e5220bc6a130e7fe8a31739b98993b203cfee2b6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 20685: Escape letter template content in textarea
Jonathan Druart [Thu, 3 May 2018 18:40:11 +0000 (15:40 -0300)]
Bug 20685: Escape letter template content in textarea

Test plan:
enter the following text into the Email template for 'HOLD_SLIP'
in Home › Tools › Notices & Slips › Modify notice

<div style='max-width: 4in;'>
<h3><<borrowers.surname>>, <<borrowers.firstname>></h3><br />
<<borrowers.streetnumber>> <<borrowers.address>><br />
<<borrowers.address2>><br />
<<borrowers.city>>, <<borrowers.state>> <<borrowers.zipcode>><br />
<br />
<br />
<img src="/cgi-bin/koha/svc/barcode?barcode=<<borrowers.cardnumber>>&type=Industrial2of5&notext=1">

Edit it again
Without this patch you will get:
<img src="/cgi-bin/koha/svc/barcode?barcode=<<borrowers.cardnumber>>&type=Industrial2of5¬ext=1">

Signed-off-by: Barton Chittenden <barton@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 305d3c36cb685fabce3ec4357ed769c25b12eb73)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 17561: (follow-up) Pass itemnumber on returns and correct itemnumber param in...
Nick Clemens [Wed, 30 May 2018 13:07:39 +0000 (13:07 +0000)]
Bug 17561: (follow-up) Pass itemnumber on returns and correct itemnumber param in circulation

To test:
1 - Place two holds on a bib for a single patron
2 - Check in both items, confirm the screen message and slip are correct
3 - Checkout both items to another patron, confirm the screen message
and slip are correct

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 183e10c13f6366b29dd79a7a9549f7d105d73f73)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
6 years agoBug 17561: (QA follow-up) Update existing unit tests
Kyle M Hall [Fri, 18 May 2018 12:00:03 +0000 (08:00 -0400)]
Bug 17561: (QA follow-up) Update existing unit tests

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 9c4040f37d705f2705fafc7a338695ddd76c1999)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>