Commit Graph

34990 Commits

Author SHA1 Message Date
Owen Leonard dd6a237ff8 Bug 23122: When searching callnumber in simple search, search option is not retained
This patch copies some code and markup from the staff client where call
number phrase searches are correctly handled. A check for
'ms_callnumcommaphr' is copied from search_indexes.inc. Handling of
commas and dashes is copied from search.pl.

To test, apply the patch and make sure the
OpacAddMastheadLibraryPulldown system preference is enabled.

 - From the OPAC main page, select "Call number" from the search pull
   down at the top of the page.
 - Perform any search (it need not return results).
 - Verify that the search option retains the "Call number" selection.
 - Repeat the test with and without the OPACNumbersPreferPhrase system
   preference enabled.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Nadine Pierre <nadine.pierre@inLibro.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 313a92324a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-15 15:24:16 +02:00
Owen Leonard c00313654a Bug 23061: Add column/print/export feature on checkout history page
This patch adds columns configuration and export features to the
checkout history page.

This patch also removes some inline CSS: "overflow:hidden" from both the
checkout and holds history pages. This was breaking the table controls
tooltips, and didn't appear to me to be necessary.

To test, apply the patch and restart Plack (or restart_all on
kohadevbox).

 - Open a patron's checkout history page in the staff client.
 - The table of checkouts should have controls at the top.
   for columns configuration and export/print.
 - These controls should work correctly.

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 34fc147726)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-15 15:22:54 +02:00
Petter von Krogh 3b9454a562 Bug 22966: Add Norwegian library and patron names for installer
THe Norwegian installer had reused english smaple atrons and libraries,
 this patch fixes this.

 test plan:
 empty database
 install norwegian translation
 run the web-installer and choose norwegian language
 select sample libraries and patrons
 make sure there are no errors

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
I trust Petter with Norwegian names, so I didn't spell check them :)

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ce8169fc21)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-15 15:21:00 +02:00
Martin Renvoize 2070f168d5 Bug 22210: (QA follow-up) Tiny gramatical correction
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6dd40712c1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-12 15:11:16 +02:00
Alex Arnaud 1b356ede1b Bug 22210: Mana config - Replace firstname and lastname with name
I've applied a patch on Mana test server. If you want to
test with your own Mana instance, do the folowing:
  - checkout bug/22210 branch from
    http://git.biblibre.com/biblibre/koha-mana.git
  - run these sql queries on Mana database (we need an update DB method
    i think):
    - ALTER TABLE librarian ADD COLUMN name VARCHAR(50) AFTER email
    - UPDATE librarian SET name = (SELECT CONCAT(firstname, ' ',
      lastname))
    - ALTER TABLE librarian DROP COLUMN firstname
    - ALTER TABLE librarian DROP COLUMN lastname

Test plan
  - set mana_config to "https://mana-test.koha-community.org",
  - go to admin > Share content with Mana KB,
  - set "Use Mana KB for sharing content" to yes,
  - save,
  - in the 2nd fieldset, enter a name and email,
  - click on send to Mana KB,
  - check that you got a token,
  - you should receive an email (Mana KB registration)
  - check the name is correct

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a7513c0dc6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-12 15:11:03 +02:00
Nick Clemens 83fa9ec6c1 Bug 23120: Pass necessary inputs through when transferring item automatically
To test:
 1 - Find an item in you system
 2 - Have syspref  AutomaticItemReturn = Do
 3 - Check in the item at a branch that is not its homebranch
 4 - Click 'Print slip' on the modal popup
 5 - Error!
 6 - Apply patch
 7 - Check the item in at its homebranch (to clear transfers)
 8 - Check it in at another branch again
 9 - Print slip
10 - Success!

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 7b0dbb1363)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-12 15:09:55 +02:00
Mark Tompsett 8ceb3b1dc4 Bug 22783: (follow up) not SET for anonymous BLOCK
Fixed syntax.
http://www.template-toolkit.org/docs/manual/Directives.html#section_BLOCK

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit cc26fefeeb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-02 11:08:19 +02:00
Martin Renvoize fbe1a39a0c Bug 22783: Make 'OPAC News' string translatable
The idea was to use an anonymous block

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b86766a3e2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-02 11:08:14 +02:00
Jonathan Druart 19eae0f228 Bug 23065: Rename "New subscription" button when default to current serial
To make it explicite that the "New subscription" button will create a
subscription based on the current serial it is now labeled "New
subscription for this serial"

Test plan:
1 - Go to Serials module in Koha
2 - Click 'New subscription'
3 - You get a blank form
4 - Fill it out, save it
5 - You are viewing the subscription you created
=> The button is now labeled "New subscription for this serial"

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b2be5b0c65)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-07-02 11:02:53 +02:00
Fridolin Somers 60ff677e14 Update release notes for 19.05.01 release
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-27 10:20:20 +02:00
Fridolin Somers 9bed277578 Increment version for 19.05.01 release
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-27 09:15:34 +02:00
Fridolin Somers b3eacfe48b Merge remote-tracking branch 'translate/19.05.01-translate-20190627' into 19.05.x 2019-06-27 09:13:28 +02:00
Koha translators 10a70f5183 Translation updates for Koha 19.05.01 2019-06-27 04:10:07 -03:00
Jonathan Druart b092d71d0c Bug 23058: Prevent XSS vulnerabiliies when 'tag' is passed to opac-search
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
2019-06-27 09:05:22 +02:00
Jonathan Druart 0d2ebac764 Bug 23082: Fatal error editing a restricted patron
In members/memberentry.pl we have to explicitely remove the template's
params that are not patron's attributes.

Certainly caused by
  commit 1bb6cec902
  Bug 20287: Fix update of patrons, clean the data before ->store

Test plan:
Create a restriction for a patron
Edit patron's details
Remove the restriction
=> Without this patch you get "No property remove_debarment for
Koha::Patron"
=> With this patch applied the restriction is removed

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 8947d5939f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-26 16:19:53 +02:00
Owen Leonard 0529975851 Bug 22945: Markup error in OPAC search results around lists display
This patch makes minor corrections to the template for OPAC search
results. These corrections fix errors returned by the HTML validator.

To reproduce the problem, perform a search in the OPAC which will return
results which are on one or more lists. Run the page through the W3C
validation service: https://validator.w3.org. Either by pasting in the
URL for the search results (if web accessible) or by viewing source,
copying, and pasting into "Validate by Direct Input."

This patch addresses two specific errors:

 - "Text not allowed in element ul in this context."
 - "Stray end tag span."

To test, apply the patch and try again to reproduce the validation
errors. Those errors should no longer be present. There should be no
visible change to the search results view.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1efe0d4606)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 15:13:40 +02:00
Mark Tompsett bf11cd06c5 Bug 17526: Change grep to deal with malformed sortfield
Giving sortfield a malformed value when viewing lists results in
Internal Server Error.

eg.
http://localhost:8080/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=1&sortfield=title(

Note the trailing (

Before Patch: kaboom
apply patch
restart
After Patch: No kaboom

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 42a26a7580)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:59:09 +02:00
Mark Tompsett cf1c06e8f0 Bug 23104: (follow-up) fix display for 0/Unlimited
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6a75f99200)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:52:41 +02:00
Jonathan Druart aeb70dd2d2 Bug 23104: Add tests for maxonsiteissueqty
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5b7e563f4e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:52:36 +02:00
Jonathan Druart 1f0c8fd9bd Bug 23104: (bug 18925 follow-up): Fix null/empty behavior, again
Not kidding, it's again, and will certainly appear more.
The problem is that we should have a NULL value in DB to make things
more readable and logical. Now we need a quick fix.

Test plan:
Set "Current checkouts allowed" to unlimited (empty string)
Try to check an item out
=> Without this patch we are blocked with a "too many" message
=> With this patch applied the correct behavior is back!

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 8c8e36cf7a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:52:30 +02:00
Jonathan Druart 2def4aee18 Bug 23104: Add tests
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1521a5567e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:52:01 +02:00
Martin Renvoize b57aaed3ff Bug 10215: (RM follow-up) Rebuid DBIC classes
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a3cf29c5f7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:50:10 +02:00
Jonathan Druart 8c8d86ef30 Bug 23117: Shortcut additem.pl on nonexistent biblionumber
To prevent additem.pl to crash when called with a nonexistent
biblionumber we are here implementing the blocking_error.inc trick to
display a friendly message instead.

Can't call method "fields" on an undefined value at
/home/vagrant/kohaclone/cataloguing/additem.pl line 736.

Test plan:
hit
/cataloguing/additem.pl?biblionumber=
/cataloguing/additem.pl?biblionumber=424242
You will get a friendly "Bibliographic record not found." message,
instead of a 500

Signed-off-by: Bin Wen <bin.wen@inlibro.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 62ae7ac727)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:44:38 +02:00
Fridolin Somers a8cc9d5f49 Bug 21534: Always compute wildcards
You get no results when searching with an hyphen + with * in query string (or with preference QueryAutoTruncate) :
ie /cgi-bin/koha/opac-search.pl?q=saints-anges*

Looks like query-string by default does not compute wildcards, see analyze_wildcard in :
https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-query-string-query.html

Test plan :
1) Use Elasticsearch
2) Create a record with "saints-anges"
3) Search for "saints-anges" => you get results
4) Search for "saints-anges*" => you get results
5) Search for "saints-ang*" => you get results

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Arthur Bousquet <arthur.bousquet@inlibro.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 001d433b42)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:44:05 +02:00
Martin Renvoize 16858fd5d5 Bug 22358: (RM follow-up) Typo fix
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 0e8a95b4bd)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:36:37 +02:00
Nick Clemens 6a3c93eeeb Bug 22358: (QA follow-up) Clear up phrasing
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a72feaa40c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:36:33 +02:00
Alex Arnaud eecce39379 Bug 22358: fix POD header and typo
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5438355b1d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:36:29 +02:00
Alex Arnaud d017e2f7c4 Bug 22358: Add POD to Koha::SharedContent
Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c6540d1b72)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:36:24 +02:00
Jonathan Druart 7bd5324c58 Bug 23022: Remove the SQl mode NO_AUTO_CREATE_USER
To make our sql mode list compatible with MySQL 8.0.11

NO_AUTO_CREATE_USER has been removed in MySQL 8.0.11
https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-11.html

I do not think we needed it.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 7771618875)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:33:43 +02:00
Martin Renvoize b728906d34 Bug 22770: DBRev 19.05.00.003
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 4452273669)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:29:40 +02:00
Katrin Fischer 9aac2c9051 Bug 22770: Fix typo in German language description of el
Fixes:
Griechisch (Moern [1453- ] ==> Griechisch (Modern 1453-)

To test:
- Install de-DE language and activate it
- Check the language pull down on advanced search has the typo
- Apply patch and run database update
- Check advanced search again
- Verify the description now shows correctly

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit eba980b351)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:27:57 +02:00
Jonathan Druart 5a1a3f0161 Bug 22941: Do not return 500 if sortfield contain parenthesis
Test plan:
Hit /virtualshelves/shelves.pl?op=view&shelfnumber=1&sortfield=author(

You must not get:
Unmatched ( in regex; marked by <-- HERE in m/^author( <-- HERE $/ at /home/vagrant/kohaclone/virtualshelves/shelves.pl line 236

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit f8db499f4a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:24:59 +02:00
Martin Renvoize 62532449a7 Bug 21662: (RM follow-up) Final followup corrections to history
Minor update to ensure we're using commit dates and not author dates

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 510cf514a3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:23:15 +02:00
Katrin Fischer b9131f2763 Bug 22633: Link barcodes in hold summary in patron account to moredetail page
Bug 21070 links the barcode on holds to the item on moredetail.pl.
This patch makes the same change to the hold lists in the staff
patron account.

To test:
- Create some holds, have at least
  - one item level hold
  - one hold waiting for pick-up
- Take a look at the details and checkouts tabs
  in the patron account on staff side
- Verify that the barcodes link to the record detail page
- Apply patch
- Verify the barcodes now link to the moredetail page

Signed-off-by: Axel Amghar <axel.amghar@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ad9338e419)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-20 14:20:38 +02:00
Owen Leonard 8710c15c8a Bug 7890: Highlight required field in MARC editor
This patch modifies the basic MARC editor so that required fields have
the standard "Required" label on them instead of a small red asterisk.

To test, apply the patch and create a new record in the basic MARC
editor. Tags which are marked mandatory in your selected MARC
bibliographic framework should be labeled "Required."

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 93c9b5d553)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 12:02:57 +02:00
Nick Clemens 518856e594 Bug 22585: (follow-up) Fix additional occurences
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 15dcde21fe)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:59:13 +02:00
Justin Rittenhouse d782843a71 Bug 22585: remove double-escape for CAS URL
The return URL that is part of the link to CAS login is double-escaped on the staff login page.

It appears that this is the same issue as bug 21973 but in the staff intranet template.  I have attached an identical patch for the intranet auth.tt file.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a3e047f638)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:58:57 +02:00
Kyle M Hall a539d9c4b6 Bug 16750: Redirect from selectbranchprinter.pl to additem.pl causes software error
How to reproduce:
1) Edit and save an item in the items editor
2) You should be redirected back to the items editor, note that the
biblionumber is passed in the url
3) Choose "set library" from the upper right hand pulldown on the page
4) Choose a different library, click submit
5) You should get the error message:
Software error:

Can't call method "fields" on an undefined value at
/home/vagrant/kohaclone/cataloguing/additem.pl line 736.

Test Plan:
1) Apply this patch
2) Follow plan above
3) No software error should occur at step 5

Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 7d7c8c12e7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:57:28 +02:00
Nick Clemens c41379c0b8 Bug 14794: (follow-up) Add tooltip to filter box
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ac41566cdd)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:53:04 +02:00
Nick Clemens a0d2e4582c Bug 14794: Display JS tooltip whenever dateofbirth is being searched
This updates the code that adds a tooltip for the correct date format
to display after the initial search

To test:
1 - Do a patron search, choosing date of birth as the search field
2 - Note on choosing that field you get a tooltip defining the format
3 - Do a search
4 - Note tooltip is gone, but date fo birth is still selected as the field to search
5 - Apply patch, reload
6 - Note tooltip shows after initial search and until field is changed

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 07d6e9f142)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:52:48 +02:00
Jonathan Druart e0a93f14c9 Bug 23095: Correctly display circulation rules (0 vs undef)
From the following commit:
  commit d1303ca834
  Bug 18925: (follow-up) Fix null/empty behavior

The global test must have been adjusted as well to catch empty strings.

Actually we are expecting the plugin to return undef but the template variable contains an empty string.

So the test should only be [% IF var != '' %] instead of [% IF var.defined && var != '' %]
but I prefer to keep it as it for now.

Test plan:
In the section "Default checkout, hold policy by patron category"
Set total checkouts = blank
    total on-site checkouts = blank
    total holds = 0
Save
=> Without this patch the line will not appear
=> With this patch applied there must be "unlimited, unlimited, 0"

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3de89b98ce)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:51:24 +02:00
Jonathan Druart 3e31200f29 Bug 23093: (bug 22318 follow-up) Use placeholders in query moving OpacNavRight
Placeholders must be used (!) in all SQL queries.

Test plan:
1/ % git checkout 0c95e22afe # commit before bug 22318
2/ Edit the pref OpacNavRight with something with "
  just a " and more '
3/ git checkout master
4/ restart_all
5/ run updatedatabase.pl
=> Boom and the content of the pref has been lost
6/ Repeat 1 to 3
7/ Apply this patch
8/ run updatedatabase.pl
=> The pref has been correctly moved to opac_news

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 18f2074f8d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:50:04 +02:00
Nick Clemens ae0bda4f70 Bug 23053: [follow-up] Same changes for UNIMARC
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ef0c31f735)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-17 09:30:44 +02:00
Katrin Fischer ff651b84e8 Bug 13094: Make it easy to hide 'Cancel all' button on holds over report
This patch makes some small modifications to the 'Holds awaiting pickup'
report:

- Fixes typo sypref
- Fixes 'Home branch' to 'Home library'
- Adds a span to easily hide the cancel all button with CSS

To test:
- Make sure you have a hold appearing on the awaiting pickup list
  second tab: Holds waiting over...
- Verify the 'cancel all' button on top shows
- Verify syspref and Home library changes mentioned above
- Add #holdsover-cancel-all { display:none; } to IntrentUserCSS
- Verify that the button and the text have vanished

Note: If the text doesn't display next to the button, try toggling
      the TransferWhenCancelAllWaitingHolds system preference.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 39e4c6c5d7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:31:35 +02:00
Kyle M Hall 8981df1cf0 Bug 18344: Add unit tests
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 60e24be115)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:29:46 +02:00
Kyle M Hall 9ea56e1cd9 Bug 18344: Allow overdue fines cap at replacement price, and cap by amount to work together
There is no reason that a library shouldn't be able to use the monetary
fines cap and the replacement price cap at the same time. The code is
written in such a way that they already work harmoniously. We have
librarians who wish to use both so they can set a high cap of $10.00 but
also use the replacement price cap so that a $20.00 book would only get
a fine of $10.00, but a $5.00 paperback will only get a fine of $5.00

Test Plan:
1) Apply this patch
2) Create a rule with a fines cap of $10, *and* a cap at replacement price, and a daily fine of $1
3) Create two items, one with a replacement price of $5 and one with a
   replacement price of $15
4) Check out these items to a patron, backdate the checkouts so they are
   already overdue by a couple months
5) Check the items in ( make sure calc fine at checkin is enabled for
    you )
6) Note the one item has a fine of $5 and the other has a fine of $10!

Signed-off-by: David Kuhn <techservspec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e702ff89f7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:29:08 +02:00
Nick Clemens 3cd32c995e Bug 23053: Add phrase index to authority Local-Number
To test:
 1 - Define a matching rule for authorities on field 001 index Local-Number
 2 - In koha-conf.xml raise the zebra_loglevels
     <zebra_loglevels>none,fatal,warn,request,info</zebra_loglevels>
 3 - Export some authorities using the tools->export data
 4 - Import those authorities
 5 - Note no matches found
 6 - View the zebra output log, you should see lots of error 114
 7 - Apply patch
 8 - Copy the indexdefs files to the installed versions
 9 - Reapply matchign rules to staged files
10 - Matches should now be found
11 - Logs should not have errors

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 2e8a6a4b09)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:26:00 +02:00
Owen Leonard c6464d5560 Bug 23076: Include OpacUserJS on OPAC maintenance page
This patch coverts the syntax for embedding OpacUserJS in the global
include file so that it uses 'Koha.Preference' syntax. This makes the
data available in templates, like the OPAC maintenance page, to which
the preference data has not been explicitly provided.

To reproduce: Add some JavaScript to the OPACUserJS system preference
which will let you know it's working. For instance:

alert("OPACUserJS!");

Turn on the OPAC maintenance message using the OpacMaintenance system
preference. Navigate to the OPAC. You should see the system maintenance
page but you should not see an alert.

To test, apply the patch and reload the OPAC page. Your alert should
show.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 82dcb5cf54)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:24:54 +02:00
Alex Arnaud 21cff32783 Bug 22915: fix Mana URL in etc/koha-conf.xml
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 8427b68414)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:22:54 +02:00
Pasi Kallinen 2f9ec9c61f Bug 22910: Do not copy unique patron attributes to duplicated patron
When creating a new patron by duplicating another, all of the patron
attributes are also copied into the form. Some of those value may be
unique, so don't copy those.

1) Create patron attribute types, one with "unique identifier", one without.
2) Create or a patron so it has values in both of those attributes.
3) Duplicate the patron
4) The edit form should retain the values from the "original" patron.
5) Apply patch.
6) Duplicate the patron - this time the attributes with unique values
   are cleared.

Signed-off-by: Pasi Kallinen <pasi.kallinen@koha-suomi.fi>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit f3358e97c8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2019-06-11 17:19:16 +02:00