Nick Clemens [Mon, 17 Apr 2023 19:24:18 +0000 (19:24 +0000)]
Bug 33206: Unit test
Signed-off-by: Nick <nick@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 82eb5d7d262a686ad6d3573e3e86a57e051c4f4c) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit be7df5dc0db7d02597ddeec2899a17fb63613536) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Janusz Kaczmarek [Sat, 11 Mar 2023 16:03:10 +0000 (17:03 +0100)]
Bug 33206: Bad title__sort made of multifield 245
In MARC 21, having title search field defined in mappings.yaml as 245abp
(more than one subfield), the Koha generated title__sort will have not
only $a, but also other subfields cut by ind2 characters, i.e.:
This is because copying an array of pointers in Perl causes you to
point to the same (anonymous) element. Therefore, the intended
modification only for subfield "a"
(Koha/SearchEngine/Elasticsearch.pm, ~line 1157) causes in fact
modification for all the subfields sharing the same mapping
definition and introduction of the nonfiling_characters_indicator to
all subfields 245 when processing 245abp. And this is obviously not
what is intended and results (in some cases) with bad sort order
when sorting by titles.
Test plan
=========
1. Have a standard Koha ES installation. In mappings.yaml
you should have 245abp for title search field.
2. Insert / download / modify a record with 245 $b or $p,
an article at the beginning of the title, and correctly
set 2nd indicator. For instance:
Signed-off-by: Nick <nick@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1330bd7c8d2ac256c93e38b95a6040c3fda3db92) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit d210a26306eb43869f5115b65072182c1b6a4127)
Katrin Fischer [Fri, 21 Apr 2023 19:46:19 +0000 (19:46 +0000)]
Bug 33586: Fix sequence of fields for memberresultst in table configuration
The sequence of options actually matters, not the name.
Library and category were switched, this patch fixes it and
now it should all hide/show as expected:
* Go to administration > table configuration
* Hide library in memberresultst
* Go to patron search and search
* Verify that category was hidden instead
* Apply patch
* Verify now label and columns for library and category
match with configuration.
Signed-off-by: Lisette Scheer <lisette.scheer@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 2ef95d91424d8c45228a1ffb30ed1388a086ca84) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 61ba63a52c1a0550f390d22122ce8cc90f1079ad) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Philip Orr [Tue, 25 Apr 2023 10:34:09 +0000 (10:34 +0000)]
Bug 28315: Remove duplicate function definition
This patch removes the unnecessary second definition of the JS function PopupMARCFieldDoc from addbiblio.tt.
To test:
1. Apply the patch
2. Check that addbiblio.tt contains only one function definition for PopupMARCFieldDoc
3. Navigate to "Cataloging" -> "Add MARC record"
4. Check that after clicking on the question mark symbol next to any MARC field, the loc description of that MARC field is opened in a new tab
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a2b880e57bb1ccd4b8270ec8bfdcdc86e18a2e48) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 4a9be2cbe3da28bb73b1268f27d6ea0c7710f3fe) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
David Cook [Mon, 17 Apr 2023 00:34:05 +0000 (00:34 +0000)]
Bug 32232: Ignore DST when calculating patron age
This change calculates patron age using the floating timezone, so that
datetimes missing midnight don't cause fatal errors in the comparison.
Test plan:
0. Apply patch
1. Change <timezone></timezone> in koha-conf.xml to include Canada/Eastern
2. koha-plack --restart kohadev
3. Create a patron, setting the date of birth to one of these three dates
- 1947-04-27
- 1948-04-25
- 1949-04-24
4. Save the patron
5. Patron detail page loads instead of producing fatal error
Signed-off-by: Marius Mandrescu <marius.mandrescu@inLibro.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 5771e6f463c72e17d42478c9970df1c7fb2286f8) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit beaf8076cf3a801cd680f794fee65c9e58f950df) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Lucas Gass [Tue, 11 Apr 2023 20:41:28 +0000 (20:41 +0000)]
Bug 33233: Don't allow disabled attribute to remain when using browser's back button
To test:
1. Go to OPAC advanced search and do a search using only one of the inputs.
2. Once the search is complete use the browser's back button to return to the advanced search.
3. Notice the unused inputs are disabled.
4. Apply patch and try again. Now the inputs should not be disabled.
Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 3811bb4381e34db7da1fd4593560fef519c4fde4) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c9b0106bd9d24ac7d11529023630f801284cd63b) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
David Cook [Tue, 2 May 2023 00:16:30 +0000 (00:16 +0000)]
Bug 33645: Make koha-foreach return 0 if it completes successfully
This patch adds an "exit 0" to the end of koha-foreach, so that it
returns a successful exit code if it reaches the bottom of the script
without errors.
Test plan:
0) `koha-foreach echo`
1) `echo $?`
2) Note that the exit status is 1
3) Apply patch
4) `./debian/scripts/koha-foreach echo`
5) `echo $?`
6) Note that the exit status is 0
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit e8a187eb7422419592899ea12903f9ff29f96cfd) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ef3985df0673304117f8c90fc673482d81410c06) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Fri, 17 Mar 2023 22:42:47 +0000 (22:42 +0000)]
Bug 33196: Generalize pseudonymization system preference description
The Pseudonymization system preference description in
the staff interface is: "Disable/Enable pseudonymization
to comply with GDPR for personal information. Patrons and
transactions will be copied to a separate table for
statistics purpose."
GDPR is a European Union (and, at time of writing, UK) law;
it makes the system preference look irrelevant for
libraries outside this area. However, this is not correct:
pseudonymization may be useful for libraries anywhere.
This generalized the system preference description and
only uses GDPR as an example instead of the only purpose.
It also updates the fields listed to more closely reflect
the labels on the patron form.
To test:
* Search for "Pseudonymization" in the systme preferences
* Verify that the description of the system preference is
very GDPR
* Apply patch
* Verify the system preference description is improved
https://bugs.koha-community.org/show_bug.cgi?id=33196 Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 54cdae763365636e71a231432d5afff637796963) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b6a8c6ce59173ab95494a8a1571c55591af4c59a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Sat, 4 Feb 2023 23:54:22 +0000 (23:54 +0000)]
Bug 31405: Set focus for cursor to setSpec input when adding a new OAI set
Makes sure the focus is in the first form field when adding
a new OAI set: setSpec
To test:
* Go to administration > OAI sets
* Add a new set, verify the focus is still in the search bar on top
* Apply patch
* Repeat and verify the focus is now in the first form field
* Save set
* Edit set and verify the focus is in the search field at the top
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 5a5034792c5269ef11f2acddd3d6055886cded06) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b9abcea244ecc43762fab6a607ea3564b2da1291) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Marcel de Rooy [Fri, 17 Feb 2023 08:33:41 +0000 (08:33 +0000)]
Bug 32990: Prevent deadlock in _update_batch_record_counts
Resolves:
C4::ImportBatch::_update_batch_record_counts(): DBI Exception: DBD::mysql::st execute failed: Deadlock found when trying to get lock; try restarting transaction at /usr/share/koha/C4/ImportBatch.pm line 392
See also bug 32558.
Test plan:
If you apply 32558 first, run multiple processes that stage a marc import.
Without this patch, you can trigger the deadlock.
With this patch, it works.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 9a6d10dc312cd6fe5e33a72af6259ac9b05f6db7) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5e838f4327aa0d9da51f607691db5adea260b20f) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Sun, 5 Feb 2023 00:17:01 +0000 (00:17 +0000)]
Bug 31410: Set focus for cursor to Server name when adding a new Z39.50/SRU server
This makes sure that the focus is in the first form field when
adding a new Z39.50 or SRU server.
To test:
* Administration > Z39.50/SRU servers
* Add a new server for each
* Verify the focus is not in the form
* Apply patch
* Verify the focus is now in the first form field
* Edit an existing server
* Verify the focus is not in the form
Not having the focus when editing is to avoid accidental changes.
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 2504a282b5890168616c1a87206f8762c38a660d) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 71f20a1c3513759393a9bae3654eb295fcb4016e) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Wed, 3 May 2023 10:58:22 +0000 (10:58 +0000)]
Bug 30367: (follow-up) Same adjustment for gitlab
This adds the same update for gitlab code. I was unable to trigger the error,
however, I confirm searching for 'PayPal' returns a result after this patch
as well as before.
JD amended patch: fix indentation
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 88000fbccbcfe707ee3d8bf72f549c1ac11be3f3) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1d5d0cbde7fcc5afebd7c7d98aabded55d046c34) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
2. Restart all services:
$ restart_all
3. Search for the term 'barclaycard'
The search will give an error:
malformed JSON string, neither tag, array, object, number, string or atom, at character offset 0 (before "(end of string)") at /usr/share/perl5/JSON.pm line 190
4. Apply patch
5. Repeat
6. No error
Note: The barclaycard plugin won't install even though it is returned as of this note - the plugin needs an update I believe, I don't think it's a Koha issue Signed-off-by: David Nind <david@davidnind.com>
JD amended patch: fix indentation
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b12aa543e2e2fe1c46eca4a0e07daa369b033793) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 63289fb34ca01a18ad0dca9c064ac07923a99f19) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Thu, 27 Apr 2023 11:23:03 +0000 (11:23 +0000)]
Bug 33626: Remove invalid params
This patch reformats the params passed to scroll_helper as defined here:
https://metacpan.org/pod/Search::Elasticsearch::Client::7_0::Scroll
To test:
1 - perl misc/maintenance/compare_es_to_db.pl
2 - It dies:
[Param] ** Unknown param (scroll_in_qs) in (search) request. , called from sub Search::Elasticsearch::Client::7_0::Direct::scroll_helper at misc/maintenance/compare_es_to_db.pl line 55.
3 - Apply patch
4 - Repeat
5 - It succeeds!
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit daa92a937193321c49c97cca5bad8809d7889d21) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 38666a8bd784dafe2934bdbd6fb3f1693f9ae442) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Jonathan Druart [Wed, 3 May 2023 09:16:14 +0000 (11:16 +0200)]
Bug 32412: Do not reload COCE image for biblio
We do not want to fetch again the new image for the biblio record. We
only want to fetch those for the shelf browser.
Note that the third parameter 'covernewwindow' was not used.
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 13dccaaf055b49473c1cc4a6ac34c0a23eb182a0) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3da06bdd73fa576b735303205c8124d8580b6ec4) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Lucas Gass [Tue, 4 Apr 2023 21:50:39 +0000 (21:50 +0000)]
Bug 32412: Empty coce container before appending image
To test:
1. Apply patch and clear browser cache
2. Turn on Coce for the OPAC.
3. OPACShelfBrowser must be on
4. Find a record that returns a cover image and open it's detail page.
5. Use the next/previous navigation links in the OPACShelfBrowser
6. Notice that no extra image is being added to the biblio-cover-slider.
7. Make sure that Coce images still load correctly in on the OPAC detail page, OPAC results page, and in the shelf browser.
Signed-off-by: Andrew Auld <andrew.auld@ptfs-europe.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit fec0bd18ae1e982232bf5b5d7d000c2bc6984589) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 7b53a7fef584eedf3f134c6442a3a7de3bf8f00a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Sun, 23 Apr 2023 21:16:52 +0000 (21:16 +0000)]
Bug 32701: Fix I18N JavaScript libraries on self checkout help page
The help page was missing the fixes from bug 28488. The missing
libraries are causing a JavaScript error on the page and likely
other issues.
To test:
* Make sure WebBasedSelfCheck is activated and configured
Note: In ktd you don't need to configure anything, it's already set up.
* In the OPAC, go to:
/cgi-bin/koha/sco/sco-main.pl
* Click on the link to the help in the top right corner
* Verify you see the error in the console:
jQuery.Deferred exception: __ is not defined
* Apply patch
* Restart things
* Reload the page
* Veriy the errors are gone
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 289f0e80517713814fb0752b932fe612ba2d0bc4) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5c92a40cf1ffcda1dda65fa358dc6c46794c271d) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Sun, 9 Apr 2023 18:25:41 +0000 (18:25 +0000)]
Bug 33470: Don't calculate overridden hold limits
This patch can largely be checked in the code to ensure it makes sense, it
moves a conditional up one level for the two different checks that could prevent holds
To test:
1 - Attempt to place a hold via the REST API with an invalid pickup location
Set pickup location as no in branches to make this easy
2 - Confirm you get an error
3 - Attempt again with header (bug 27760):
x-koha-override: any
4 - Hold is placed
5 - Repeat 1-4 above but with an item that cannot be held
6 - Apply patch
7 - Repeat 1-4 above
8 - Results should be the same
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit e3c31212df4d1917004a20998f47777ef0aea35d) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 309e1b0cb8df29265919080e8c772fe3997a69e3) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Jonathan Druart [Wed, 10 May 2023 05:37:57 +0000 (07:37 +0200)]
Bug 33702: Prevent ILL requests to be modified by somebody else
Same as previous patch, but for 'update' and 'cancreq'.
We remove the redirect, but here we only want to focus on the security
fix.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Confirmed. Without this patch a patron can modify and cancel any ILL
request in the OPAC. With this patch the patron is redirected to the
404 page if modification or cancellation is attempted.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Magnus Enger [Tue, 9 May 2023 13:37:51 +0000 (15:37 +0200)]
Bug 33702: Patrons should only see their own ILLs in the OPAC
To reproduce:
- Enable the ILL module
- Install the FreeForm backend as described here:
https://wiki.koha-community.org/wiki/ILL_backends
- Go to the ILL module and add two different ILL requests by
clicking on "New ILL request" and entering the necessary details.
- Make sure you connect the two requests to two *different* patrons
in the field marked "Card number, username or surname"
- Make the two titles different, and make a not of which title is
connected to which patron
- Log in as one of the two patrons who now have an ILL request each,
in the OPAC
- Go to the "Interlibrary loan requests" tab
- Click on "View" for the request connected to this patron. The URL
will look like something like this:
http://<opac>/cgi-bin/koha/opac-illrequests.pl?method=view&illrequest_id=2
- Now change the number at the end to correspond to the the ILL request
connected to the *other* patron
- Verify you can see the details of an ILL request conncted to another
patron than the patron you are logged in as
To test:
- Apply the patch
- Restart all the things if you are testing with ktd
- Reload the detail view of the ILL request that belongs to the patron
you are not logged in as
- Verify you are redirect to the 404 page and can not see the details
of the request that belongs to the patron you are not logged in as
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Lucas Gass [Wed, 8 Feb 2023 23:28:59 +0000 (23:28 +0000)]
Bug 32921: Honor SelfCheckTimeout when modal is open
To test:
1. Set the 'SelfCheckTimeout' system preference to something low for testing.
2. Make sure 'SelfCheckReceiptPrompt' is set to 'Show'.
3. Log in to SCO and press finish but leave the modal open.
4. Wait until the 'SelfCheckTimeout' time has expired, nothing happens.
5. Apply patch and try again. You should be logged out when SelfCheckTimeout expires.
Signed-off-by: Marius Mandrescu <marius.mandrescu@inLibro.com>
JD amended patch - fix indentation
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit e074ffa6be15c97e6724041b12d930ed70855f1d) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3d75bf866bb05e0a8ab457ed3f48a2e84243bfb9) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 4ab67c196debf387f2053c3916f4cdac76901db3) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 53722e6c3172d0e04d5e7b8d2576a93ddeded2f0) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Thu, 4 May 2023 13:08:54 +0000 (13:08 +0000)]
Bug 33262: Unit tests
prove t/db_dependent/Biblio.t
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 177b53d79492f7636c5e9e37a6e1f3c3f8fa8707) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit f79ae8283d10852bf2974efd2ea0f4bff5c63d6b) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Thu, 4 May 2023 12:15:36 +0000 (12:15 +0000)]
Bug 33262: Store the biblionumber of a deleted record in the order line
When a bibliographic record is deleted and linked to an order
in the acquisition module, the biblionumber in the order line is
currently deleted as well. This makes it impossible to tell what
was ordered in the first place. This is a big issue for libraries
that need to be able to track how money was spent over long periods
of time.
With this patch the biblionumber of the deleted record will be moved
to a new column deleted_biblionumber in the order line, keeping the FK
on biblionumber.
To test:
* Apply patch, run dataase update
* Create a order/basket in the acquisitions module
* Order several things, you can use existing records from the sample data
* Make sure you order one of the records at least twice
* Take a look at the aqorders table in your database, using a report:
SELECT biblionumber, deleted_biblionumber, ordernumber from aqorders;
* From the catalog, delete the items on the records and then the records
Note: There is a warning about attached orders warning about consequences
for acquisitions. I have chosen to keep it at this point in time, as
there are still visible side effects of deleting the record, like bug 10758.
* Re-run the report and compare results to the first run. deleted_biblionumber
should now be filled with the biblionumber of the deleted record.
biblionumber should be NULL/empty.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c8faeac4cd4cfdeab04c25bedb534d3823bbe83c) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 508fbb0fafc7efe6b03af624784492eb4edee8a0) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Thu, 4 May 2023 13:23:31 +0000 (13:23 +0000)]
Bug 33262: Add deleted_biblionumber column to aqorders table
This adds a new column deleted_biblionumber to the aqorders table.
This will allow us to store the biblionumber of a deleted record,
so we will still be able to tell what has been ordered once the
record is deleted.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 0cf7687e833986d95ce9fa49bdb33252944fbbea) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 16464ef65688f8566db38766698d25b6df1d063e) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Lucas Gass [Mon, 1 May 2023 22:13:02 +0000 (22:13 +0000)]
Bug 32253: Load all CodeMirror lines initially when using advanced editor
To test:
1. Have advanced editor turned on.
2. Load a record with many lines and see that not all the lines appear until you click on the visible ones.
3. Apply patch and try again
4. All lines should load.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 827df32798cd8046d62cb6630fd33395d78fb3ef) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 278d0bf18a6169b7b5b6b304df318b38fca1894c) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Wed, 12 Apr 2023 20:59:34 +0000 (20:59 +0000)]
Bug 33505: Improve styling of scan index page
This patch makes some changes to the 'scan index' page.
* Updates second h1 heading "Scan index:" to h2 level heading "Scan index"
* Removes table from the search form
* Moves search index pull down and search term into one line
* Reorders options with search index first and search term after, matching
the advanced search form
* Removes the catalog results toolbar from the top, card hold etc. are not needed
here.
* Fixes doubled up id attribute: scan-index by turning one into scan-index-term.
To test:
* Go to advanced search in staff interface
* Activate 'More options'
* Check checkbox for scan indexes
* Switch to author (especially when using Elasticsearch)
* Search for C
* Check display, especially search options, options at the top of the page etc.
* Apply patch
* Verify changes listed above
* Regression test the normal search results, all should look the same with and without patch.
* If you think the scan index page is nicer now - sign off.
Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 358cb91a72e85d6ec0e85b8d88b1793062113bd3) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a0d28c0620da21e18af660acde0b9e2eb223333e) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Wed, 12 Apr 2023 20:19:38 +0000 (20:19 +0000)]
Bug 33506: Fix false index for series and keep selected index on scan index page
The pull down with search options had the wrong index
linked to the Series entry: su instead of se
To test:
* Go to advanced search in staff interface
* Activate 'More options'
* Check checkbox for scan indexes
* Switch to author (especially when using Elasticsearch)
* Search for C
* Verify search results link to authors using c
* Switch to series
* Verify search results use 'su' for subject
* Verify that search option pull down always jumps back to first
entry: Any word
* Apply patch
* Verify the search results for series now use correct index se
* Verify that coming from advanced search, the correct search option is selected
* Verify that changing the search option also keeps the selection after searching
Note: with Elasticsearch and default configuration author, title and series will
give you results.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 970fe62f785ce06ca57a8bae8936158c632069ea) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d2d6761e95827edb0d6d56df65a44f39aa397d62) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Bug 33597: (follow-up) Two other occurrences for holdfor
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit f99bcfb6521835e6d21cad3c83973aefb0f16cf4) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 41557555a9ceff4bc70e4fa1a53d270d3acf7143) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Resolve:
Cookie “holdfor” does not have a proper “SameSite” attribute value. Soon, cookies without the “SameSite” attribute or with an invalid value will be treated as “Lax”. This means that the cookie will no longer be sent in third-party contexts. If your application depends on this cookie being available in such contexts, please add the “SameSite=None“ attribute to it.
Did not see warning for holdforclub. But since it is created with Lax, we should remove it with Lax.
Test plan:
Similar to previous patch. Check console on logout page.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 7e5e311cb0c88b9223ce98d685668962edc7baee) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d8567143eea4dde52cce0c856e3c12a6154eda0b) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Bug 33597: Get rid of warning about intranet_bib_list
Resolve:
Cookie “intranet_bib_list” does not have a proper “SameSite” attribute value. Soon, cookies without the “SameSite” attribute or with an invalid value will be treated as “Lax”. This means that the cookie will no longer be sent in third-party contexts. If your application depends on this cookie being available in such contexts, please add the “SameSite=None“ attribute to it.
basket_22.1200022.js:67:65
Test plan:
Do not apply this patch.
Logout from staff.
Check browser console warnings.
Apply this patch.
Login and logout again.
Check warnings again.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 95de1f3e92947f157dbbbf789d88beb48645648b) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d11c9fec33f6ebb072094437240408bd8f300a9f) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Lucas Gass [Fri, 28 Apr 2023 15:53:19 +0000 (15:53 +0000)]
Bug 33634: Correct anchors in system preference submenu
To test:
1. Go to Koha Administration -> Global system preferences
2. Go to a tab with a few headings like Circulation
3. Click on a heading in the sidebar navigation under Circulation that takes you a bit down the page, like Recalls
4. Notice this anchor link does not work, you are not taken to the recalls preferences
5. Apply patch
6. Try again, the links should take you to the proper place.
Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 0d1278aa14bf2a161df87c9d73f105b2c96c5022) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b0a196e115e6cb07ebc12653463d52a4a3252a30) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Martin Renvoize [Wed, 12 Apr 2023 10:49:51 +0000 (11:49 +0100)]
Bug 33504: Update patron_to_html to deal with null
In the patron_to_html function we were dealing explicitly with the case
where patron may be passed undefined, but forgetting that it may be
returned as 'null' from the api too. Changing from `( patron ===
undefined )` to `( patron == null )` is the recommended approach for
detecting 'undefined or null' in javascript.
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Works as advertised. Martin's test plan from Bugzilla:
To test.
1) Use ILS-DI to renew an checkout
2) View the circulation history for the item
3) Click the 'View' button next to the count of renewals
4) Note that the modal just stalls at 'Retrieving renewals'
5) Apply the patch
6) Now the 'retrieving renewals' message should list the renewals instead.
Note that step 2 should be something like "Go to the "Circulation
history" of the patron.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 744ac4825ba9a346e2ad1c8e413d3d9423658512) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 31db36fb34843efe42ef3257d3d187c8611a53f7) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Sun, 19 Mar 2023 22:06:12 +0000 (22:06 +0000)]
Bug 33156: Fix JS error on batch patron modification
The error currently breaks some of the functionality for
updating patron attributes linked to AV values. With the
bug, the input field will not change to the AV list when selected
from the pull down of patron attributes.
It was probably bug 29648 that changed the data structure
without adapting for the additional data that is pushed
to the object for the patron attribute columns.
To test:
* Create several extended patron attributes
* Make sure at least one is linked to an AV
* Repeatable and unique patron attributes can't be
updated in batch patron modification, so you need some
that can be modified.
* Go to tools > batch patron modification
* Enter one or more cardnumbers to update
* Verify the table is missing columns, export and configure
* Verify when selecting the AV tied patron attribute, the input
remains a text one
* Apply patch
* Both should work now as expected
Note: I believe there are some more errors on this page,
but they should better be handled separately. So with this
patch we push configuration again for each column to table
columns, but the very last column keeps missing from the
columns settings.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 7ca83d4b8c5581646af50d8378003b4233ad5fa2) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1cd959c68b6e463fc504410919f009879e1e34f8) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Mason James [Thu, 27 Apr 2023 14:15:05 +0000 (02:15 +1200)]
Bug 33629: allow pbuilder to use network via build-git-snapshot
to test...
- build master packages, observe failure :(
debian/build-git-snapshot -d -v 22.12.00-24~git1 -D dev -b base_22.12.00+deb10 --noautoversion
"/usr/bin/perl" build-resources.PL
yarn install v1.22.19
warning You don't appear to have an internet connection. Try the --offline flag to use the cache for registry queries.
- apply patch
- build master packages, observe success :)
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 0a0c6554d72ea5acec1a6c4fe63b77e9383e2e56) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e65aa28abe52341277861551d4a356eaacc6c389) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Bug 33603: Fix misc/maintenance/search_for_data_inconsistencies.pl when biblio.biblionumber on control field
Since bug 29486, misc/maintenance/search_for_data_inconsistencies.pl search for biblio.biblionumber in MARC record with $record->subfield().
This fails when field is a control field (< 10).
Idem for biblioitems.biblioitemnumber
Test plan :
1.0) On a UNIMARC database (biblio.biblionumber is on 001)
1.1) Run misc/maintenance/search_for_data_inconsistencies.pl
=> Without patch you get error : Control fields (generally, just tags below 010) do not have subfields, use data()
=> With patch no error
2.0) On a MARC21 database (biblio.biblionumber is on 999c)
2.1) Run misc/maintenance/search_for_data_inconsistencies.pl
=> Check you see no error
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit cc1695ba96b79d85fe778af1c60b092b149dd449) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 9971011fb9271ee2c8bae9e979c15b51a7fdaad2) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Bug 30352: Add a comment to the substatus translation
The tric of combining the XPath union operator (|) with the
value-of instruction works as a sort of ternary operation.
The value-of only picks the string value of the first node
from the union in document order.
So, if there is a translation, it will be the first node. If there
is no translation, the original substatus will be used. Note that
there will be no translation for authorised values like Staff
collection, etc.
Test plan:
None. Just comments.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c652ed4b1dcc204d36921d55120d91c758803632) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 105b9fc3138fd606e850d7efcd28f1269b52c53a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Bug 30352: Allow translation of Not for loan in OPAC XSLT results
Note: Test plan below can be followed in English. If you would like
to see the vernacular results, you need to update PO files and
translate 'Not for loan', and update templates (xslt files) accordingly.
The bootstrap PO does not yet include that string without %s suffix
in the current codebase.
Test plan:
[1] Apply this patch and make the following change in
MARC21slim2OPACResults.xsl, line 1207.
Change:
<status english="Not for loan">Not for loan</status>
to:
<status english="Not for loan">NOT for loan</status>
Important: Change text inside, not the attribute!
Restart all.
[2] Pick a biblio, add some items with different statuses: Checked out,
Damaged, Not for loan, Staff collection.
[3] Make it appear in a OPAC results display (not detail).
[4] You should see the different statuses, including NOT for loan. The
uppercase NOT serves to prove that the string has been translated. Also
verify that you see Staff collection as-is.
[5] Bonus: Toggle with values in Reference_NFL_Statuses to move results
from Reference section to Not available section v.v.
[6] Revert the change from step 1. Sign off :)
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 8d7e3cec32dffa5f96de696f8707bf8e015c49d2) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 9871a02b26bea775b03090d65e633a260ea10baf) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Janusz Kaczmarek [Mon, 13 Mar 2023 14:06:52 +0000 (15:06 +0100)]
Bug 33210: (Bug 31963 follow-up) No hold fee message on OPAC should be displayed when there is no fee
After resolving Bug 31963 everything works as expected when there is
hold fee defined (!= 0). But in case when the fee for given patron
category is set to 0.00, the user will always see the message "You will
be charged a hold fee of 0,00 ...", which is obviously not intended.
This is because categories.reservefee is returned from database as
'0.000000' and as such, without type casting, is interpreted as string
in Perl. Prior to Bug 31963 the result was compared to 0 before sending
anything to the template, so the casting was done, now it is not.
To test:
========
1. Go to Administration -> Patron categories
2. Edit your patron category and give a hold fee of 0.
3. HoldFeeMode does not matter - you can set it to any value.
4. In another tab, open the OPAC.
5. Search the OPAC for any record with an item.
6. Go to place a hold on this record. You will see "You will be
charged a hold fee of 0,00" --> This is a bug.
7. Apply patch and restart services.
6. Repeat step 6.
8. You should NOT see the hold fee message.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit e4b94e4d82d5f96a0b1125f41fc8e41a47826627) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 56f4586290e32dc4acccf32a7ab9c4a4928f0233) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Janusz Kaczmarek [Fri, 24 Mar 2023 16:17:20 +0000 (17:17 +0100)]
Bug 33210: Add unit test
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 203646418a75efb86f513e33a0f3d4e13675c50d) Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 181f54a0ac9ff89c9a04e0c6ef314bc46abb4b91) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
To test:
1. Turn on SyndeticsCoverImages and SyndeticsEnabled.
2. Check the staff results page and make sure you can change the image size via SyndeticsCoverImageSize.
3. Check the OPAC results page.
4. Turn on 'OPACShelfBrowser' and make sure you change the image sizes within the shelf browser.
5. Test the OPAC checkout history page. ( opac-readingrecord.tt )
6. Have a checkout and an overdue to test the 2 tables on the OPAC summary pahe. ( opac-user.tt )
Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit daac367f300cea09688aa184c6ead1cd9a978f15) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit a48ed69eb2c33c660854d3cf560e121a0731161a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Magnus Enger [Fri, 21 Apr 2023 06:39:56 +0000 (08:39 +0200)]
Bug 33579: Typo: record record
To reproduce:
- Search for records
- Select two or more records
- Select "Edit" > "Batch delete records"
- Click "Delete selcted records"
- Click "View detail of the enqueued job"
- Verify the page says "Type: Batch bibliographic record record deletion"
To test:
- Repeat the steps above
- The page should now say "Type: Batch bibliographic record deletion"
Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 180de413c92e6bee5ac0e65e6ac255d780dab72d) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit 9f92f880639a69076cc70792d956a788bb4b56fb) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Sat, 18 Feb 2023 11:53:49 +0000 (11:53 +0000)]
Bug 31432: Make 245$n$p visible by default in frameworks
$n (part_number) and $p (part_name) now have their own
columns in the database, but we are still hiding them
by default. It woudl ease testing and cataloguig if
we changed them to be visible by default in new installations.
To test:
* Check that in your current frameworks when adding a new
record, 245 n and p are hidden
* Apply the patch and start over: drop your db and run the
web installer
* Verify that the fields are now visible
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 340880253042d36e429ee0805039fa2589241180) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit bc4b29dfaa064c57644b59f73de547be2b5335c7) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
See comment on former patch too. We need to activate the spinner
early and we can simplify the code to remove it.
Note: unfortunately this is kind of a workaround, since using
load would be nicer but currently hard to implement since the cover
image code is scattered/widespread.
This code still checks the complete attribute, we could argue that
it should just remove the spinner. Note too that the spinner belongs
to a div where multiple img may be part of. If we do not remove the
spinner now, something went wrong at load time, but if you can
actually see the spinner is another thing.
Test plan:
See former patch.
Check few cover images on detail page, enable various providers.
Bonus: I tested with a sleep statement in opac-image.pl.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1bd4f53e9015f9dc764d51618acbaaec8ad275ff) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit ee4cc43b97d1c234379feb558ff1b2e38bf69cb1) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Bug 32642: Loading spinner always visible when cover image is short (OPAC)
We noticed that if the cover image is somewhat short (i.e. the height is under 80-90 px), the loading spinner indicating that the image is currently loading still appears after the image is loaded.
this patch remove the spinner when the image is loaded,.
To test:
1. Make sure the OPACLocalCoverImages system preference is enabled
1.1. Go to Administration > Global system preferences
1.2. Search for Coverimages
1.3. Set OPACLocalCoverImages to 'Show'
1.4. Click 'Save all Enhanced content preferences'
2. Add a short local cover image to a record (I added one which is just a grey rectangle with the size printed on it, to facilitate the test)
2.1. Download the attached image
2.2. Find a record without an image
2.3. Click the 'Images' tab
2.4. Click 'Upload'
2.5. Click 'Drop files here or click to select a file' and choose the downloaded image
2.6. Click 'Process images'
3. View the record in the OPAC
3.1. From the image upload page, click on the title of the record in the page heading to access the detailed record in the staff interface
3.2. Click on 'OPAC view: Open in new window.'
--> Note that the image is displayed normally, but the spinner is also displayed
4. Apply the patch
5. View the record in the OPAC
--> Note that the spinner is no more displayed
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
This needs a follow-up; the code in this template activates the spinner
actually when the job has been done already and did not remove it.
And we did not see that but only with a short image like above.
The construction with .one, .each is not needed given the execution
context.
Kyle Hall [Tue, 14 Mar 2023 11:06:21 +0000 (07:06 -0400)]
Bug 33216: Catch and handle RegisterRequired exceptions for SIP fee paid messages
If registers are being used in Koha, they are required. If a SIP account has no register and a fee paid message is sent, the SIP server crashes and the client never gets a response. It would be much better if Koha would response with 38 response where "payment accepted" is N, and an AF field stating that the SIP account needs to be associated with a register.
Test Plan:
1) Enable UseCashRegisters, set RequireCashRegister to "always require a
cash register". Do *not* set a cash register for the SIP account you
will be testing with.
2) Using the SIP cli tester, send a fee paid message for a patron owing
fees.
3) Note the lack of a SIP response
4) Apply this patch
5) Restart the SIP server
6) Repeat step 2, you should now get a SIP response with the error
message in it!
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 0411bf0573708327a9c0271f4d01c2996641bb3f) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit c6610d5ed97c03a090039606aecfe7f5d6917876) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Martin Renvoize [Tue, 28 Mar 2023 11:35:05 +0000 (12:35 +0100)]
Bug 18398: (follow-up) Update POD & Unit tests
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 488e67656ffa3016a32f39eb68c5a3aa7fb8a68e) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit fc4d7c3d4deeec4f9bfae2dd31e83be7527e2887) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Martin Renvoize [Fri, 10 Mar 2023 10:02:19 +0000 (10:02 +0000)]
Bug 18398: Update C4::Message enqueue to use $patron->notice_email_address
This patch updates the enque method in C4::Message to expect a
Koha::Patron object in the parameters and then uses that patron object
to select the correct email address for notices as defined by
AutoEmailPrimaryAddress.
Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit f7cfe3a705b4c594e1e9b70c1e7e1ffa0b39a073) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit f58b41460b41cfc034e15baabda1dc1ab5f88b81) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Janusz Kaczmarek [Wed, 15 Mar 2023 19:25:53 +0000 (20:25 +0100)]
Bug 33238: Fix bad suggestions query (Bug 29886 follow-up)
With IndependentBranches Koha explodes with Error 500 when a non
superlibrarian tries to add to basket from suggestions. In errorlog you
would find "DBIx::Class::Storage::DBI::_dbh_execute(): DBI Exception:
DBD::mysql::st execute failed: Column 'branchcode' in where clause is
ambiguous".
Test plan:
==========
1. Have a Koha instance with IndependentBranches, some accepted
suggestions, and a vendor defined.
2. Be a non superlibrarian librarian with permissions to
manage acquisitions.
3. Create a new basket and try to add an item to the basket
"From a suggestion".
4. Koha would generate error 500.
5. Apply the patch.
6. Try to add an item to the basket "From a suggestion".
7. You should succeed.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 68b2f29d483290d5dfd859dce9b9fe7a387f3ab1) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit d4fb68703098f25bd587a8fdfc6cd5b4d884c4f9) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Wed, 12 Apr 2023 19:58:03 +0000 (19:58 +0000)]
Bug 33509: Don't show Other holdings when there are no alternate holdings
With bug 33509 alternate holdings defined in AlternateHoldingsField
are shown in the staff interface result list. This works greatly
when there are items or when there is are alternate holdings (the
configured field/subfields exist in the record), but not when there
are no items and no alternate holdings.
To test:
* Add 100a to AlternateHoldingsField
* Make a search with some records without items
Sample data: perl
* Make sure the alternate holdings show when there are no items
and 100a exists
* Change to 100z
* Verify the result list now shows "Other holdings:" with nothing below
* Apply patch
* Repeat
* Alternate holdings should still show nicely
* Without alternate holdings 'no items' is displayed
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 2ce97da0e77812300bbfaa7fe579732da80364dd) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit a6d93137b0878b858a36746de6f6678cfce00a74) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Fridolin Somers [Wed, 5 Oct 2022 20:21:14 +0000 (10:21 -1000)]
Bug 31695: Type standard number is missing field ci_raw in field_config.yaml
In Elasticsearch fields config field_config.yaml, default type as a field 'ci_raw'. This is used for exact search.
This field is missing for type standard number 'stdno'.
Test plan :
1) In the staff interface, go to Administration, and search for SearchEngine
2) Make sure that the SearchEngine preference is set to Elasticsearch and save
3) Return to Administration and select "Search engine configuration"
4) Change the type of "Heading-Main" to "Std. Number" and save
5) Rebuild the index (e.g. "koha-elasticsearch --rebuild -d kohadev")
6) Go to the main staff page and select Authorities
7) Search for a heading (e.g. "A Dual-language book")
=> Result is found with or without patch
8) Click on the sliders and select "is exactly" for the operator and search
=> Result is found only with patch
9) Apply the patch
10) Rebuild the index (e.g. "koha-elasticsearch --rebuild -d kohadev")
11) Click on the sliders and select "is exactly" for the operator and search
=> Result is found only with patch
Signed-off-by: Kevin Carnes <kevin.carnes@ub.lu.se> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 106adb320ca0c3dbee3b43cf0afff7b41bb67a96) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 085a11b3dd854b0533ef0cce1d8299d3bfba587d) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
David Cook [Fri, 31 Mar 2023 00:55:56 +0000 (00:55 +0000)]
Bug 33375: Quote reserved keyword 'rank' in advanced editor
This change quotes the 'rank' keyword in the advanced editor,
so that it doesn't cause fatal crashes when using MySQL 8
Test plan:
0. Apply patch and koha-plack --restart kohadev
1. Enable advanced editor
http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=EnableAdvancedCatalogingEditor
2. Go to http://localhost:8081/cgi-bin/koha/cataloguing/editor.pl#new/
3. Click on "Advanced" on the left nav
4. Note that "LIBRARY OF CONGRESS" is ordered before "NATIONAL LIBRARY OF FRANCE"
5. Rejoice!
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 99f8273673b7e2189fff5846bdeacff70e0a48ed) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 30260ece2f567823da7189abf5ebd0a43caa526a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Fridolin Somers [Sat, 18 Mar 2023 03:08:56 +0000 (17:08 -1000)]
Bug 33088: Remove background-job-progressbar.js in batch_record_modification.tt
It must be removed, we don't need it since bug 22417
Test plan :
Play with batch record modification and check there is no JS error
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 668252503d3893391d0399537fd6f787cce507c4) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 397354e4bb9d18b797ad96a5d906bab0b985cda1) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Fridolin Somers [Wed, 29 Mar 2023 08:52:08 +0000 (22:52 -1000)]
Bug 32127: Add unit test
Run prove t/db_dependent/Template/Plugin/Categories.t
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c101afb0a036a460b1a585574151de80e2afd43a) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit acac2251616a2e26a4a1159222c0c12733b3d067) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Fridolin Somers [Mon, 7 Nov 2022 21:42:49 +0000 (11:42 -1000)]
Bug 32127: Sort by description in Koha::Template::Plugin::Categories
Like in Koha::Template::Plugin::Branches, methods in
Koha::Template::Plugin::Categories must return categories sorted by
description.
Test plan :
1) Create a new patron category with code ZZZ and description AAAAAA
2) Go to patron search /cgi-bin/koha/members/members-home.pl
3) Look at filter by category :
=> Without patch the value AAAAAA is last
=> With patch the value AAAAAA is first
4) Click on 'New patron'
=> Without patch the value AAAAAA is last
=> With patch the value AAAAAA is first
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 4f37c5bc7710619f297c356a7b19aa1767de7071) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 79e0674da62daf618d15da158117b69ab3bb413b) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Galen Charlton [Tue, 24 Jan 2023 19:10:32 +0000 (14:10 -0500)]
Bug 32716: larger proxy_buffer_size in NGINX example config
This patch updates the example NGINX config to increase the
proxy_buffer_size to 16k. The default value of 4k (on some platforms)
has empirically been shown to be a bit too small for the Link
headers emitted by the REST API when pagination is requested.
To test
-------
[1] Set up a Koha system with NGINX as a reverse proxy in
front of it (either in front of Apache or in front of
of Starman).
[2] Perform a patron search that returns at least two pages
of results and navigate to the second page.
[3] Note that the navigation can fail with a 502 HTTP error
and an "upstream sent too big header while reading response
header from upstream" error in the NGINX log.
The problem is most likely when the pagesize of the server
running NGINX is 4096 bytes.
[4] Update the NGINX configuration per this patch and restart
NGINX.
[5] This time, repeating step 2 should work.
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a29964778a44ef6f7f4a8400df4ef12ab80f5ed6) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 18c75b9bf9b0ea206f159ed1f94fa8b1eada4c12) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Owen Leonard [Mon, 27 Feb 2023 11:33:22 +0000 (11:33 +0000)]
Bug 33077: Improve ease of translating template title tags
This patch uses the cities administration page as a proof-of-concept for
using the [% t() %] construction to wrap translatable string in template
<title> tags. This should result in a significant improvement in
translatability.
To test, apply the patch and run the translation script to update the
.po files, e.g.
perl misc/translator/translate update fr-FR
Check the updated .po files:
- In fr-FR-staff-prog.po you should no longer see a reference to
cities.tt line 6, "#: koha-tmpl/intranet-tmpl/prog/en/modules/admin/cities.tt:6"
- In fr-FR-messages.po you should see several strings which have been
pulled individually from the <title> tag:
- cities.tt:9, msgid "Modify city"
- cities.tt:11, msgid "New city"
- cities.tt:15, msgid "Confirm deletion of city"
- cities.tt:19, msgid "Administration", msgid "Cities", msgid "Koha",
and msgid "Administration"
Translate the strings in fr-FR-messages.po and install the updated
translation:
perl misc/translator/translate install fr-FR
Swith to the update language in the staff interface and confirm that the
Cities page title is translated correctly.
Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 7020b90f305fbdf584b57f61e39d259d3f9e0d22) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 66b7de2ec2ee429b40831cdef68161ab18bb0035) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Owen Leonard [Thu, 23 Mar 2023 17:42:46 +0000 (17:42 +0000)]
Bug 33323: Select button in patron search modal is not translatable
This patch modifies the JS which generates some markup during some kinds
of patron searches so that the strings labeling submit buttons can be
translated.
To test, apply the patch and go to Administration -> Funds.
- Add a fund or edit an existing one.
- Test the "Select owner" link
- A popup should appear, and after performing a patron search which
returns results you should see a "Select" column in the last column
of the patron search results table.
- Test the "Add users" link
- Perform the same test as above. The button in the last column should
be "Add"
- The template accommodates two other cases, "Edit" and "Check out" but
I was unable to find a place where they were used.
- To test translatability, run the translation tool for any language,
e.g.
perl misc/translator/translate update fr-FR
Search the regenerated po file (in this example
misc/translator/po/fr-FR-staff-prog.po) to confirm that the
correct strings are there: "Select", "Add", "Edit, and "Check out"
should each have entries for line 234, e.g.
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a9d736ba74aadbc409597b58608ae33120efb368) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit d716d4c0e19d3cd7f83cc306ef35bc178b98be4e) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c3a40d3801d8f70fa865e22962f7ae7e9cc18bee) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit bc2c8b16f88c43ac778aed904a288e77561a7033) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Fri, 17 Mar 2023 11:20:31 +0000 (11:20 +0000)]
Bug 32301: Fix default search sorting in advanced search when not editing a search
Bug 22605 changed the sorting to expect the passed parameter from the
previous search, this broke default when the search page was loaded
fresh.
We should simply fallback from the edited search to the default if it is
not set
To test:
1) Go to staff client
2) Go to Advanced Search
3) Notice the default Sort By value is "Relevance"
4) Go to system preferences
5) Go to "defaultSortField"
6) Change the value of the system preference
7) Go back to Advanced Search and refresh the page
8) Notice that there are no changes, the default Sort By is still
"Relevance"
9) Apply patch
10) Notice that changing the system preference now changes the default
Sort By in Advanced Search
11) Perform a search, change the sorting, then edit the search
12) Confirm the correct sorting from the search is preserved
Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 3489cdca1fd77272deca0ff6bda90e1cc40dddb1) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 38d615959c00a2a4468245e18c1099aaf3455cf0) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
The test was checking for the value of an input field.
But with this patch set, there is no longer an input, but
a link element with the title. This adjusts the patch to look
for the correct element.
Katrin Fischer [Mon, 10 Apr 2023 16:08:32 +0000 (16:08 +0000)]
Bug 29311: (follow-up) Add id to span elements
The input fields in the form have ids, these are useful
for styling, but also for the Selenium tests. This patch
adds the ids from the former inputs to the now spans.
Bug 29311: Forbid editing biblio info when creating suggestion for biblio
When creating a suggestion for an existing biblio, biblio info like
title or author should not be editable.
Test plan:
1. Enable system preference 'suggestion'
2. Log in at OPAC
3. Go to a biblio record detail page
4. Click 'suggest for purchase'
5. Notice that all fields can be modified (title, author, ...)
6. Apply patch
7. Repeat steps 2 and 3 or refresh the page
8. Verify that the biblio fields cannot be modified now. The only fields
that should be editable are: quantity, item type, library, reason for
suggestion, and notes
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d96393a52ab047939c97b5b5b496f2ed85f58893) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit ca33ff04d66cf26b4030504f632dbce74841250e) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Kyle Hall [Wed, 22 Feb 2023 15:55:41 +0000 (10:55 -0500)]
Bug 33040: Add "Date published (text)" to serials tab on record view (detail.pl)
Some libraries would like to see the "Date published (text)" in the serials tab on the "Normal" record view ( aka catalogue/detail.pl ).
Test Plan:
1) View the serials tab on detail.pl for a subscription where the latest
serial has a "Date published (text)" field populated.
2) Apply this patch
3) Restart all the thigns!
4) Browse to detail.pl for that record
5) View the Subscriptions tab
6) Note the "Date published (text)" column exists now!
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b3b33960dac85015d4f6e73604a8f7d21ed31e5b) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit e640ddc20e6dd44a679f6e738943bdfb69fc4dab) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Philip Orr [Fri, 31 Mar 2023 07:12:48 +0000 (07:12 +0000)]
Bug 27513: Add notes to variables for report parameters template
This patch adds the TT variable 'notes' to the variables
that guided_reports.pl passes to the template guided_reports_start.tt
during SQL parameters entry in the phase 'Run this report'.
To test:
1. apply the patch
2. navigate to Reports -> Guided Reports -> Create from SQL
3. create an SQL report that includes at least one parameter, e.g.:
SELECT barcode FROM items WHERE homebranch=<<Select library|branches>>
the actual SQL and name of the report doesn't matter much, just make
sure that you also put a note e.g. "Test text for display" in the
field "Notes:" before you save the report.
4. run the report
5. the note you entered should now be displayed below the heading
"Enter parameters for report..."
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit fa534d464c63739f4c836a43966802caa09b0ca8) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit 5de9cb41df412317ee4d907502043cc00530aceb) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Fridolin Somers [Fri, 31 Mar 2023 22:16:43 +0000 (12:16 -1000)]
Bug 33285: (QA follow-up) add POD and fix some code style
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 6221538b6d54d85b403296191a9d2fb27d34116c) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit 4a1c87fe361cf20c41df2da1596341069cb3962a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Mon, 20 Mar 2023 20:08:56 +0000 (20:08 +0000)]
Bug 33285: Allow specifying the delimeter for runreport.pl
To test:
1 - Write a report in koha
2 - perl misc/cronjobs/runreport.pl --format csv 1 (or correct report number)
3 - Note you get commas
4 - Apply patch
5 - Repeat #2 - no change
6 - perl misc/cronjobs/runreport.pl --format csv --separator "|" 1
7 - Now it is pipe delimited
8 - perl misc/cronjobs/runreport.pl --format tsv --separator "|" 1
9 - Error is reported, you cannot set separator unless csv
10 - Try other separators
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org> Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit bad0d52245ebf7fe73131e3721a99f7ec9a965ce) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit 94077abab8c9c0f5fb5ad08966acd3ff8e44bd31) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
C4::AuthoritiesMarc method GetAuthorizedHeading is not exported thus it is called in other modules :
> git grep GetAuthorizedHeading
C4/AuthoritiesMarc.pm:=head2 GetAuthorizedHeading
C4/AuthoritiesMarc.pm: $heading = &GetAuthorizedHeading({ record => $record, authid => $authid })
C4/AuthoritiesMarc.pm:sub GetAuthorizedHeading {
C4/Breeding.pm: $heading = C4::AuthoritiesMarc::GetAuthorizedHeading({ record => $marcrecord });
C4/ImportBatch.pm: $row->{'authorized_heading'} = C4::AuthoritiesMarc::GetAuthorizedHeading( { authid => $row->{'candidate_match_id'} } );
C4/ImportBatch.pm: my $authorized_heading = C4::AuthoritiesMarc::GetAuthorizedHeading({ record => $marc_record });
This patch adds it to be exported.
For example for use in Koha plugins.
Test plan :
Check import of authorities from a file is OK
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 2d0eca8a0df0e34535d12e40c4247ec99a493619) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit 6833e1b3f70a356bc9ba6ae50ed048324e60664f) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Fridolin Somers [Sat, 19 Nov 2022 03:54:32 +0000 (17:54 -1000)]
Bug 32280: Export method ImportBreedingAuth from C4::Breeding
In C4::Breeding method ImportBreedingAuth() should be exported to be used for example by plugins.
No test plan needed i bet.
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Looks like a harmless and useful enhancement. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 97a100d19ded4c1297b44c65587b419ca8710cfc) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit e28fd04eff488349b17ad178b43fce1457b4ab08) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Mon, 23 Jan 2023 12:51:48 +0000 (12:51 +0000)]
Bug 31259: Escape infinite loop when lime cannot wrap enough
It seems the wrapping here works with words, not characters. If a line is too long,
or too far over, we can't trim it enough. We need to escape if successive loops are
not changing the line
To test:
1 - Using sample data, edit the layout to match picture in comment 9
2 - Add some borrowers to a batch
3 - Attempt to export batch and save PDF
4 - Staff client waits
5 - ps aux | grep card
6 - Note the job keeps running
7 - Kill it
8 - Apply patch
9 - Restart_all
10 - Export batch again
11 - Success, you get a badly formatted PDF, rather than nothing
12 - Note the PDF does not show "Yakama Nation Library"
13 - Edit layout, male "Lower left X" 20 instead of 220
14 - Export again and note text field 1 shows correctly
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a18f65cdcc51571bc9eae1e903a6b7b676e6a89e) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit f1010ee062263c84be1cf8f9117730c536f9c8f5) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Mon, 21 Nov 2022 19:12:46 +0000 (19:12 +0000)]
Bug 13976: Sort popularity numerically in Zebra
To test:
1 - Create a new template at Tools->Marc modification template
2 - Add action: Copy 999$c to 942$0
3 - Create a report:
SELECT biblionuber FROM biblios
4 - Run report, show all, do a batch modification to all records using template above
5 - Search for 'a' (make sure you are using Zebra)
6 - Sort by popularity
7 - Note records are sorted wrong
8 - Apply patch
9 - Restart all
10 - Reload search results
11 - Success! Sorted correctly
Signed-off-by: Anke <anke.bruns@gwdg.de> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 45cea7c7ba548ffc24976c1b574de295792d0793) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit feea08b03c51648b5a53a021edc726833f475e8f) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Pedro Amorim [Thu, 2 Feb 2023 17:55:10 +0000 (17:55 +0000)]
Bug 28641: ILLHiddenRequestStatuses does not consider custom statuses
This patch adds the status_alias column to the ILLHiddenRequestStatuses sys pref check.
Because requests will have status_alias NULL by default, we also check for that.
Test plan:
Create multiple ILL requests of different backends and place them in different status (NEW, COMP, REQ, etc)
Create multiple ILLSTATUS entries
Add and remove a mix of both status and status_alias codes in ILLHiddenRequestStatuses and refresh the ILL requests page to confirm the result is according to expectation.
Sponsored-by: PTFS Europe Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit aaa5bcd16bc5c4e50986961ad79d29801e67c889) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit feea30d42bdce19cee6c7f2f7b89dbd4a51bf810) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Mason James [Fri, 31 Mar 2023 14:21:54 +0000 (03:21 +1300)]
Bug 33168: (follow-up) Swap spaces for tabs
Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit f74a353097710cf33b3b75b9912b2b00d2aa1a30) Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
(cherry picked from commit cff59f18d5ef4b5a07ce1a4b4160daea00d8ea31) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
David Cook [Tue, 21 Mar 2023 23:09:20 +0000 (23:09 +0000)]
Bug 33168: Prevent debhelper from renaming history.txt to changelog
This change prevents debhelper from renaming history.txt to changelog,
since that renaming was breaking the Timeline feature in Koha.
Another option would've been to rename history.txt to something else
but that filename is already embedded in Koha and the Koha release
tools, so this seems the safer option.
Test plan:
0. Apply patch
1. Build Debian package
2. Confirm that /usr/share/doc/koha-common/history.txt is created
and /usr/share/doc/koha-common/changelog.gz is not created
Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b6f9241d66b8a857dba51d747cb8fb67d2115433) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 3b6aac190cacc407472bba24b72154e6b487a35b) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Some old-style code is making our tests fail when run in Debian Testing.
This patch addresses this.
To test:
1. Launch bookworm KTD:
$ KOHA_IMAGE=master-bookworm ktd up -d
2. Run:
$ ktd --shell
k$ prove t/00-testcritic.t
=> FAIL: It fails!
3. Apply the patch
4. Repeat 2
=> SUCCESS: Tests now pass!
5. Sign off :-D
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 10d12f999f9b8bff228c9c20f1ca4f0c7144201f) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit c1c5420afae84e86938d4a7ecaf2adb7074a2cc1) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
For single bibs we use an ajax select2 dropdown, and we don't use this
value
To test:
1 - Place some holds on single bibs
2 - Confirm dropdowns for pickup location work as expected
3 - Do the same for multiple bibs selected from search results
4 - Apply patch
5 - Confirm there is no change after the patch
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 63772a9cb25e58ff221540c2a76a7f447bbdeecc) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit dd7b6e528a18f19ef3a05e36436602416de8bf09) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Johanna Raisa [Fri, 29 Jul 2022 05:37:50 +0000 (08:37 +0300)]
Bug 30966: Record Overlay Rules - can't use Z39.50 filter
This patch fixes overlay rules on z39.50 import
Test plan:
1) Create protection overlay rule to some fields for z39.50.
2) Import a record via z39.50.
3) See that the protected fields are replaced on the editor.
4) Apply the patch.
5) Import a record again.
6) See that the protected fields are in place on the editor.
Sponsored-by: Koha-Suomi Oy Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 0970eef56df1ac8fee1f3c5f0216a164be5048ec) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 207349be3ae6793ee83141da2648e695b5f711aa) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Wed, 22 Mar 2023 19:12:01 +0000 (19:12 +0000)]
Bug 33309: Index items after renewal transaction completes
This patch ensures a record is indexed only after the renewal transaction
has completed successfully. Otherwise the job cannot be found by the background process
worker, becaue it was not yet in the DB
To test:
1 - Make sure you are using ES, and the es indexer is running
2 - tail -f /var/log/koha/kohadev/*.log
3 - Issue an item to a patron and renew it
4 - Note error in es-indexer-output.log like:
[2023/03/21 12:22:36] [WARN] No job found for id=157 main:: /kohadevbox/koha/misc/workers/es_indexer_daemon.pl (129)
5 - Apply patch
6 - Renew again
7 There should be no error
8 - Search for the record and confirm items info displays correctly
9 - View the background jobs in admin, confirm the most recent job has completed
Signed-off-by: Janusz Kaczmarek <januszop@gmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a63b0d00306d639241a400cecbe3b0125ee8d303) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit ff03813f9fcf79e32dd95a1f4913ba64392a1610) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Lucas Gass [Wed, 8 Mar 2023 16:24:26 +0000 (16:24 +0000)]
Bug 33137: Add Home library to pay-fines-table and table settings
To test:
1. Apply patch and restart_All
2. From a patron's Accounting tab add some invoices that are related to an item.
3. From the 'Make a payemnt' notice the new Home library column. Make sure it displays correctly and is the same as what you see on the 'Transactions' tab.
4. Using Table settings, make sure you can properly hide the column.
Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit eae0a7e065f867b9ba729281ba83b2568045ad50) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 656a179adb06b06e5367784cd39f5e2567ae4763) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Owen Leonard [Mon, 6 Mar 2023 18:02:28 +0000 (18:02 +0000)]
Bug 33151: Improve translation of string in cities.tt and desks.tt
This patch adds a <span> tag around a string in both cities.tt and
desks.tt in order to improve translatability.
To test apply the patch and run the translation script to update the .po
files, e.g.
perl misc/translator/translate update fr-FR
Check the updated .po files:
- Before the patch you would have found 'msgid "%s Searching: %s %s %s'
- After the patch you should find 'msgid "Searching: %s'
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 289400379213dea3169ba30196ff4ef8f87a4b03) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit fdc10bcbf81b42a2340f6fef2a1b4345d940145e) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Tue, 7 Mar 2023 20:05:36 +0000 (20:05 +0000)]
Bug 33100: Remove all punctuation at end of record
This could potentially be overkill - if you have two records that only
differ in ending punctuation, you might get a false result - I don't
know how likely that is ( as I have mentioned before '!!!' is a band )
This seems a reasonable fix
To test:
1 - Set sysprefs as in bug 33159
2 - Edit a record, biblionumebr 3 is fine
3 - Add a comma to end of author subfield a
4 - Save and note relinked
5 - Apply patch, restart all
6 - Save again
7 - Linked to original record
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 928a4cb465d7891157b1b061d144db6a808ada14) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit c2f2c68a07a21f6fefd3be4682f9acd5405b5f5b) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Nick Clemens [Tue, 7 Mar 2023 20:05:28 +0000 (20:05 +0000)]
Bug 33100: Unit test
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 749045366310fe4269bb1c39a93adc5eb20a4f22) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 39d6ee4399a03fb4eb645024dbaf83acb3da1501) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Katrin Fischer [Mon, 27 Feb 2023 22:13:01 +0000 (22:13 +0000)]
Bug 33076: Add context to "Quotes"
A quote as a part of quoted text and a quote as
part of the acquisition process need to be
translated differently at least in German.
This patch adds context to the terms, so we can
do that.
To test:
* Go to Tools > Quote editor
* Verify the heading of the page reads "Quotes"
* Enable EDIFACT system preference
* Go to Administration > EDI accounts
* Add a new account save
* Verify the table heading reads "Quotes"
* Apply patch - nothing should change
Verify the translation process:
* Run: gulp po:update --lang de-DE
* Verify the "Quotes" appear now separated by
different context in
misc/translator/po/de-DE-messages.po
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 2413ab7e7986c39d5469e8f16d7be9d62bd775d8) Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit f37d7f3f13319ddf1828e7267971b54a855c4b5a) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>