Commit graph

46316 commits

Author SHA1 Message Date
Julian Maurice
66dbdf5da8
Bug 30941: Add cataloguing plugins for 146$bcdef (UNIMARC)
Test plan:
1. Configure the default MARC framework to use those value builders:
   - unimarc_field_146b for 146$b
   - unimarc_field_146c for 146$c
   - unimarc_field_146d for 146$d
   - unimarc_field_146e for 146$e
   - unimarc_field_146f for 146$f
2. Verify that they all work correctly according to
https://www.ifla.org/files/assets/uca/unimarc_updates/BIBLIOGRAPHIC/u-b_146.pdf

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:55:09 -03:00
jeremy breuillard
9b2bf04e09
Bug 30507: Value builder for field 183
This patch provides values builders for the subfields $a and $2. Those are unimarc official codes who help to
identify the kind of items
Test plan:
1)Go to Home > Cataloging > New record
2)Section 1 - field 183 : it contains subfields $a & $2
3)Inputs are writable but notice that no plugins are suggested
4)Apply patch and repeat 1) to 3)
5)Values builders plugins are available for $a and $2

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:46:27 -03:00
jeremy breuillard
94423e6d63
Bug 30506: Value builder for field 182
This patch provides values builders for the subfields $a, $c and $2. Those are unimarc official codes who help to
identify the kind of items
Test plan:
1)Go to Home > Cataloging > New record
2)Section 1 - field 182 : it contains subfields $a, $c & $2
3)Inputs are writable but notice that no plugins are suggested
4)Apply patch and repeat 1) to 3)
5)Values builders plugins are available for $a, $c and $2

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:45:50 -03:00
jeremy breuillard
c3ae151d93
Bug 30504: Value builder for field 181
This patch provides values builders for the subfields $a, $b, $c and $2. Those are unimarc official codes who help to identify the kind of items

Test plan:
1)Go to Home > Cataloging > New record
2)Section 1 - field 181 : it contains subfields $a, $b, $c & $2
3)Inputs are writable but notice that no plugins are suggested
4)Apply patch and repeat 1) to 3)
5)Values builders plugins are available for $a, $b, $c and $2

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:45:22 -03:00
e94665bba5
Bug 30718: (QA follow-up) Remove double use KohaDates
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:40 -03:00
1b96a5f588
Bug 30718: (QA follow-up) KohaDates filter on inputs
Found another one on a visible input. Replaced with html filter.
koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep2.tt:                                            <input type="text" class="enrolmentperioddate" name="enrolmentperioddate" id="enrolmentperioddate" value="[% category.enrolmentperioddate | $KohaDates %]" />

But we also have a few hidden ones. First verified that cleanborrowers did not work anymore with expirydate.
Fixed it with passing iso dateformat to resolve.
intranet-tmpl/prog/en/modules/acqui/parcels.tt:            <input type="hidden" name="shipmentdate" value="[% shipmentdate | $KohaDates %]" />
intranet-tmpl/prog/en/modules/serials/subscription-add.tt:                                          <input type="hidden" id="acqui_date" name="firstacquidate" value="[% firstacquidate | $KohaDates %]"/>
intranet-tmpl/prog/en/modules/tools/batch_extend_due_dates.tt:                                    <input type="hidden" name="new_hard_due_date" value="[% new_hard_due_date | $KohaDates %]" />
intranet-tmpl/prog/en/modules/tools/cleanborrowers.tt:            <input type="hidden" name="not_borrowed_since" value="[% not_borrowed_since | $KohaDates %]" />
intranet-tmpl/prog/en/modules/tools/cleanborrowers.tt:            <input type="hidden" name="last_issue_date" value="[% last_issue_date | $KohaDates %]" />
intranet-tmpl/prog/en/modules/tools/cleanborrowers.tt:            <input type="hidden" name="borrower_dateexpiry" value="[% borrower_dateexpiry | $KohaDates %]" />
intranet-tmpl/prog/en/modules/tools/cleanborrowers.tt:                <input type="hidden" name="borrower_lastseen" value="[% borrower_lastseen | $KohaDates %]" />

Test plan:
Try cleanborrowers with expiry date.
cd koha-tmpl; git grep "<input.*\$KohaDates" | grep -v iso

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:40 -03:00
3a85da0db6
Bug 30718: (QA follow-up) Apply prevent duplication on OPAC too
See former intranet side patch.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:40 -03:00
7b0567a3ab
Bug 30718: Fix serial claims filters
https://bugs.koha-community.org/show_bug.cgi?id=30718
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:40 -03:00
5f471308ad
Bug 30718: Fix renewal with due date
This was a test added by the following commit:

commit 99eccc18ed
Date:   Thu Jun 16 10:10:09 2011 +0100
    Bug 5549 : Handle datetimes on return

It's no longer needed now, we can pass a DateTime or an ISO-formatted
date

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:39 -03:00
55c5f1fd47
Bug 30718: Fix dates display at the OPAC
Found dateofbirth so far, do we have others?

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:39 -03:00
c59bb7874c
Bug 30718: Apply flatpickr changes to OPAC
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:39 -03:00
97a4b3c61d
Bug 30718: Prevent 'reset' icon to appear twice
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:39 -03:00
41a1806143
Bug 30718: Fix time display
Especifically when timeformat=12h

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:38 -03:00
71da008363
Bug 30718: Fix scheduler
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:38 -03:00
9f50ac9963
Bug 30718: Fix holidays
Template process failed: undef error - The given date (07/18/2022) does not match the date format (iso)

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:38 -03:00
11a76929d7
Bug 30718: Add missing USE KohaDates
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:38 -03:00
bd71767fcc
Bug 30718: Fix serials/showpredictionpattern.pl
Can't locate object method "ymd" via package "2022-02-01" (perhaps you forgot to load "2022-02-01"?) at /kohadevbox/koha/serials/showpredictionpattern.pl line 100
eval {...} at /kohadevbox/koha/serials/showpredictionpattern.pl line 2

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:37 -03:00
8352a4ebd6
Bug 30718: Fix today's date on overdue
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:37 -03:00
c07ce1a1bf
Bug 30718: Pass DT to filter_by_lates
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:37 -03:00
48bf9b1d91
Bug 30718: Use flatpickr's altInput
The idea rely on the KohaDates TT plugin for the date formatting. We
should not have any output_pref calls in pl or pm (there are some
exceptions, for ILSDI for instance).

Also flatpickr will deal with the places where dates are inputed. We
will pass the raw SQL value (what we call 'iso' in Koha::DateUtils), and
the controller will receive the same value, no need to additional
conversion.
Note that DBIC has the capability to auto-deflate DateTime objects,
which makes things way easier. We can either pass the value we receive
from the controller, or pass a DT object to our methods.

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-19 08:26:31 -03:00
b02b66acf5
Bug 30779: Remove _update_import_record_marc and update tests
This patch removes the now unused: _update_import_record_marc

Additionally, as items are already present in import biblio we no longer need to embed
them, so that parameter is removed and the option removed from the sub and pod and everywhere
it was used

In all cases, we were embedding, so we don't need a way to get without

Tests updated

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-18 09:02:04 -03:00
b1ec071866
Bug 30779: Do not update import marc after importing items
We are stripping the marc item tags at import - we save them when not importing items, but
strip when importing items

I think we can save on writes by leaving them in the record. This also allows comparison to what was staged
versus items created

To test:
 1 - Stage a marc record with items, but do not look for items
 2 - Confirm the item tags remain in staged marc
 3 - Import the record
 4 - Confirm items are nto in imported marc record
 5 - Stage the record again, but look for items
 6 - Confirm the item tags are stipped from imported record
 7 - Import and confirm imported record has no item tags
 8 - Apply patch and repeat 1-5
 9 - Confirm item tags remain in record
10 - Import and confirm item tags not in imported marc

Signed-off-by: Andrew <andrewfh@dubcolib.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-18 09:02:04 -03:00
c88120688f
Bug 30684: (follow-up) Use log_warning_msg for the "not running" warning
Also, return 0 rather than return 1 in else clause of koha-zebra

Sponsored-by: Catalyst IT, New Zealand

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-18 09:00:39 -03:00
3227b6136d
Bug 30684: When a service isn't running koha-* scripts --restart should start it
Test plan:
1. Stop plack, indexer, sip, worker, z3950 and zebra.

Note: To test Z39.50 restarting you will need to setup the server: https://wiki.koha-community.org/wiki/Setting_up_the_Z39.50_and_SRU_Server#Setting_up_the_Z39.50_and_SRU_Server

2. Run restart command for each service:
- [Plack] sudo koha-plack --restart {instance}
- [Indexer] sudo koha-indexer --restart {instance}
- [SIP] sudo koha-sip --restart {instance}
- [Worker] sudo koha-worker --restart {instance}
- [z3950] sudo koha-z3950-responder --restart {instance}
- [Zebra] sudo koha-zebra --restart {instance}

3. Observe the services do not get restarted.
Instead you get an error saying the service is not running

4. Apply patch

5. If you are using kohadevbox you must copy koha-* scripts to /usr/sbin/:
sudo cp debian/scripts/koha-plack /usr/sbin/koha-plack
sudo cp debian/scripts/koha-indexer /usr/sbin/koha-indexer
sudo cp debian/scripts/koha-sip /usr/sbin/koha-sip
sudo cp debian/scripts/koha-worker /usr/sbin/koha-worker
sudo cp debian/scripts/koha-z3950-responder /usr/sbin/koha-z3950-responder
sudo cp debian/scripts/koha-zebra /usr/sbin/koha-zebra

6. Repeat step 2

7. This time confirm that each service is restarted

Sponsored-by: Catalyst IT

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>
2022-08-18 09:00:38 -03:00
cbe50d798a
Bug 31217: OPAC coce.js is not hiding the coce-coverimg div for single-pixel images
This is because opac-detail.tt has coce-coverimg as an ID, but OPAC
coce.js targets coce-coverimg as a class.

opac-detail.tt should be changed to have coce-coverimg as a class.

Test plan:
1. Set your system preferences:
- CoceHost = https://coce.mykoha.co.nz
- CoceProviders = Select all
- OpacCoce = Enable

2. Add the ISBN of '9780262336499' to a biblio

3. Open a "Incognito" window in your browser (recommended to use Google
Chrome to test this)

4. View the biblio detail page in the OPAC. Observe a 'Coce image from
Amazon' box loads with a spinner

5. Apply patch and restart services

6. Clear your browser cache

7. Reload the same biblio detail page in the OPAC. Observe no image is
displayed.

8. View another OPAC biblio detail page that does have a successfully
loading coce image and confirm the source of that image is listed: For
example 'Coce image from Amazon.com' is displayed

Sponsored-by: Toi Ohomai Institute of Technology, New Zealand
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-18 08:59:48 -03:00
52734ca9be
Bug 28854: (follow-up) Remove errant warning
Oops, I left in a bare warn from debugging.. this simply removes it; it
is unrequired.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-18 08:57:30 -03:00
218419ce2c
Bug 31382: Pass password_has_expired param to templte
This patch restores the param, while still leaving the check against invalid
login credentials to ensure we don't leak information.

To test:
 1 - enable  EnableExpiredPasswordReset
 2 - Edit a patron to set password to expire in the past
 3 - Attempt opac login as patron
 4 - It fails, but you are redirected to login screen with no info
 5 - Apply patch
 6 - Attempt login
 7 - You are notified password expired and given reset link
 8 - Go back to login screen
 9 - Login with correct username,, wrong password
10 - You are notified of incorrect credentials, not password expiration

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 15:52:07 -03:00
217e953ffb
Bug 31382: Regression tests
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 15:52:02 -03:00
7343e404b7
Bug 31222: Reduce query size for batchMod
The object search is currently:
Koha::Items->search({ barcode => \@contentlist }

Which generate code like:
barcode = 1 OR barcode = 2 OR barcode = 3 ....

This can get quite large

We can reduce the query size by using -in:
Koha::Items->search({ barcode => { -in => \@contentlist } }

Which generates code like:
barcode in ( 1, 2, 3 )

To test:
1 - Apply patch
2 - Perform batch modifications
3 - Confirm nothing has changed

Signed-off-by: Rachael Laritz <rachael.laritz@inlibro.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 15:51:23 -03:00
89e65657b1
Bug 29782: Fix handling records without title or content
Test plan:
Save a new record with only a title in the non-default tab (english).
Check if you see it on the list. Edit.
Save a new record without title but only content in non-default lang.
Check if you see it.
Do the same 2 edits on the default tab only. Verify too.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 15:50:55 -03:00
5ec01dd326
Bug 27342: Fix C4::ILSDI::Services::AuthenticatePatron
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 10:33:07 -03:00
daef044b6f
Bug 31228: Intranet coce.js is not hiding the coce-coverimg div for single-pixel image
This is because the intranet detail.tt has coce-coverimg as an ID.
Intranet results.tt has coce-coverimg as a class. Intranet coce.js
targets coce-coverimg as a class.

Intranet detail.tt should be changed to have coce-coverimg as a class.
This is inline with the change made to the OPAC in bug 31217

Test plan:
1. Set your system preferences:
- CoceHost = https://coce.mykoha.co.nz
- CoceProviders = Select all
- IntranetCoce = Enable

2. Add the ISBN of '9780262336499' to a biblio

3. Open a "Incognito" window in your browser (recommended to use Google
Chrome to test this)

4. View the biblio detail page in the intranet. Observe a 'Coce image
from Amazon' box loads with a spinner

5. Apply patch and restart services

6. Clear your browser cache

7. Reload the same biblio detail page in the intranet. Observe no image
is displayed.

8. Do an intranet search to get the biblio returned in search results
page. Confirm no cover image box is displayed

9. View the intranet search result and detail pages for a different
biblio that you know Coce should be displaying the cover image of and
confirm that it is correctly displayed with the source of that image
listed: For example 'Coce image from Amazon.com' is displayed

Sponsored-by: Catalyst IT, New Zealand

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 10:01:13 -03:00
0198560543
Bug 19540: Tell the patron why a hold cannot be placed on items
This patch adds an explanation when a hold cannot be placed, in some situation:
tooManyReserves
tooManyHoldsForThisRecord
tooManyReservesToday
itemAlreadyOnHold

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 10:00:01 -03:00
089f5a4cf5
Bug 26632: Remove two more occurrences
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 09:24:09 -03:00
66c5ab528c
Bug 26632: (Bug 22532 follow-up) Remove random variables
AddBiblioToBatch and AddAuthToBatch were btoh passing a random number for the
parameter $update_counts

This simply removes that value as should have been done on 22532

To test:
1 - Stage a marc file
2 - Confirm it works befor and after patch

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 09:24:09 -03:00
Johanna Raisa
d2d78e2581
Bug 23202: Fix screen freeze when ordereing several items
This patch fixes adding multiple items on order acquisitions

The error is: Uncaught TypeError: $(...).parent(...).attr(...) is undefined

Test plan:
1) Set dateaccessioned.pl plugin to ACQ framework's 952$d field.
2) Create basket to a vendor and add order from a new empty record.
3) Add date acquired value from calendar.
4) Add multiple items and see that the view freezes.
5) Apply the patch
6) Reload the page and repeat the steps 3 and 4.
7) See that the items are added.

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

JD Amended patch: adjust commit title
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 09:23:10 -03:00
f433875363
Bug 31313: Fix holds_count and priority
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-17 09:19:49 -03:00
Aleisha Amohia
01091c8089
Bug 15326: (follow-up) Fix staff permissions and consider library limits
To test:
1. Take note of what your logged in library is
2. Add a new page that can be viewed on the OPAC and staff interface.
Limit the library to a different library, not your logged in library
3. Use a News item to create a hyperlink to your new page on the OPAC
and staff interface.
4. Confirm that a page error shows if you try to view the new page.
5. Edit the new page and set the library to All libraries.
6. Try to go to the new page again and confirm it shows.
7. Log out and log back into the staff interface as a staff user that
isn't a superlibrarian
8. Confirm you can view the new page as this user

Sponsored-by: Horowhenua Libraries Trust

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 15:42:33 -03:00
Aleisha Amohia
e55864db27
Bug 15326: (follow-up) Hide RSS feed if no news items
If there are pages but no news items showing on the OPAC, the RSS feed container
should not show.

Sponsored-by: Horowhenua Libraries Trust

Signed-off-by: Lisette Scheer <lisettePalouse+Koha@gmail.com>

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 15:42:29 -03:00
Aleisha Amohia
8de80449dd
Bug 15326: Using AdditionalContents for custom pages on OPAC
This page utilises the Additional Contents feature to add custom pages
to the staff client and the OPAC in the user's desired language.

To test:
1. Apply patch and restart services
2. In the staff client, go to Tools, then go to the new 'Pages' page
3. Add a new page to display on both the staff client and OPAC.
4. Confirm the URLs in the Page URL column work as expected.
5. Confirm that any pages made for the staff client only do not show in
the OPAC, and that any pages made for the OPAC only do not show in the
staff client.
6. Confirm that pages do not show on the OPAC main page where news items
show. Confirm news items show on the OPAC main page as expected.

Sponsored-by: Chartered Accountants Australia and New Zealand

Signed-off-by: Thibault Kero <thibault.keromnes@univ-paris8.fr>

Signed-off-by: Lisette Scheer <lisettePalouse+Koha@gmail.com>

Signed-off-by: Lisette Scheer <lisettePalouse+Koha@gmail.com>

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 15:42:24 -03:00
5c1db538e6
Bug 31294: Show "Required" label on mandatory fields
This patch adds "Required" label on mandatory fields for Article Requests

0. Apply the patch
1. koha-plack --restart kohadev
2. Change syspref 'ArticleRequests' to 'Enable'
3. Change syspref 'ArticleRequestsMandatoryFields' to '[Select all]'
4. Go to http://localhost:8080/cgi-bin/koha/opac-search.pl?idx=&q=test&weight_search=1
5. Click "Request article" for "Gairm"
6. Note that "Title", "Author", "Volume", "Issue", "Date", "Pages", and
   "Chapters" all say required
7. Change syspref 'ArticleRequestsMandatoryFields' to 'Title' and
   'Author'
8. Go to http://localhost:8080/cgi-bin/koha/opac-request-article.pl?biblionumber=29
9. Note that only "Title" and "Author" say required

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 14:32:21 -03:00
21e4995a31
Bug 27342: (QA follow-up) Fix test
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:50:47 -03:00
a433573054
Bug 27342: (QA follow-up) Remove dbh from new tests
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:45:42 -03:00
1b92fd78fd
Bug 27342: Remove dbh from C4::Auth
We must not pass $dbh but retrieve it when needed instead

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:45:41 -03:00
4c44dd5eb4
Bug 27342: Improve test for OPAC
We don't need to build allowed_scripts_for_private_opac for staff

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:45:41 -03:00
18211bf233
Bug 30901: Add Unit Tests
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:43:10 -03:00
58f401de9c
Bug 30901: Add POD for Koha::Template::Plugin::CirculationRules
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:43:10 -03:00
32475570c4
Bug 30901: Add Renewals method to CirculationRules template plugin
It would be useful to be able to report renewals used/remaining in some notices and slips.

Test Plan:
1) Apply this patch
2) Add the following to the RENEWAL notices:
--
[% USE CirculationRules %]
[% SET renewals = CirculationRules.Renewals( borrower.id, item.id ) %]
You have used [% renewals.count %] of [% renewals.allowed %], you have [% renewals.remaining %] renewals left.
--
3) Trigger a renewal notice
4) Verify the text is correct!

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:43:10 -03:00
bd70e8989f
Bug 31312: Remove GetItemsInfo from misc/migration_tools/rebuild_zebra.pl
Hum... Item2Marc ok here?

Bug 27272 is going to remove C4::Items::GetItemsInfo in favour of Koha::Items->search.

Here we are going to deal with misc/migration_tools/rebuild_zebra.pl

Test plan:
I am not sure, what do we want to test here? Items' info indexed
correctly?

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>
2022-08-16 10:40:17 -03:00
Shi Yao Wang
db42939885
Bug 30922: Make the "Relative's checkouts" table configurable by the table settings
Adds "relatives-issues-table" in table settings.

Test plan:
1- Apply the patch
2- Check out an item to a patron with a guarantor
3- Go to the guarantor's "details" and "check out" page > relatives'
checkouts and look at the different columns (you should see collection
and location)
4- Go to
    admin > table settings > patron > moremember > relatives-issues-table
 or
    admin > table settings > circulation > circulation >
relatives-issues-table
to hide some columns (e.g. collection and location) and click save
5- Do step 3 again and notice some columns (e.g. collection and location) are hidden
6- Also notice the "Columns" and "Export" buttons that should work as
intended

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-08-16 10:26:18 -03:00