Commit graph

49493 commits

Author SHA1 Message Date
9c1d1383e6 Bug 34106: Retain searchtype parameter in member-search-box
To test:

1. In the main search header switch to 'Search patrons'. Bring up the dropdown and look at 'Search type:'.
2. It defaults to 'Starts with'.
3. Go to '/cgi-bin/koha/members/members-home.pl' and look at the 'Search type:' on the left side.
4. It defaults to 'Contains'
5. Do a patron search from both these places, setting the 'Search type' to contains.
6. The search bar in the header always resets to 'Starts with'
7. Apply patch
8. Try everything again. By default both places should default to contain.
9. If you change the 'Search type' the search in the main header should always retain that value.

Signed-off-by: Ed Veal <eveal@mckinneytexas.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 6f1d3883c8)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e27e5cd886)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
2023-07-18 13:00:04 +00:00
0bc90deeee Bug 34106: Update header search box searchtype when form is submitted
We're updating the side menu searchtype when the search header is submitted,
we should also update the searchtype in the search header when the form is submitted

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b9ffc47100)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 252f297a5a)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
2023-07-18 13:00:04 +00:00
fc6d2d4dd7 Bug 33720: Also flush in install
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 41c43449c6)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1961490c2e)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
2023-07-18 13:00:03 +00:00
08d0727020 Bug 33720: Update the updatedatabase.pl script to flush caches before running
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.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 4391e23ea5)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 834245b709)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
2023-07-18 13:00:03 +00:00
7ebdb10573 Bug 34029: DBRev 22.11.07.003
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 532cf4ab9f)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit a0cc737bc6)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:53:29 +00:00
ad4bb3e14f Bug 34029: DBIC schema
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 16ad89bb96)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 41a86239d2)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:52:29 +00:00
36b267bd07 Bug 34029: (QA follow-up) Fix pushing undef to biblio_ids
See comment1. Although we now fix the error on publishercode, it
is good to verify the result before pushing.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 377e2a70de)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 561f6e5bd8)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:52:20 +00:00
e6d8add0b7 Bug 34029: Extend datatypes of biblioitems.columns to text to avoid breaking import
This updated the datatype of the following columns from varchar(255) to text
to avoid import problems if the mapped MARC field's data exceeds 255
characters.

This is for:
* place (260$a and 264$a)
* publishercode (260$b and 264$b)
* size (300$c)
* illus (300$b)
* pages (300$a)

To test:
* Edit a bibliographic record and enter more than 255 characters into
  the MARC fields listed above. Try to save.
* Run the updatedatabase script to modify the DB structure
* restart_all
* Edit a bibliographic record and enter more than 255 characters into
  the MARC fields listed above.
* Save
* Export the record
* Import the record using staging tools, all should work well

Signed-off-by: Sam Lau <samalau@gmail.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 00545f8780)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ad93540d59)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:52:12 +00:00
Caroline Cyr La Rose
580f8903c3 Bug 34103: Capitalization: Currencies & Exchange rates
This patch corrects the breadcrumbs in the Administration > Currencies
and exchange rates page to follow current capitalization and
typographical guidelines.

To test:
0. Apply patch
1. Go to Administration > Currencies and exchange rates
2. Verify that the breadcrumb has no spelling errors, and that
   capitalization and typography guidelines are applied
3. Click 'Delete' next to one of the currencies
4. Verify that the breadcrumb has no spelling errors, and that
   capitalization and typography guidelines are applied

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1a29ff17a5)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 10cd6dc584)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:51:47 +00:00
Caroline Cyr La Rose
a0913f7928 Bug 34015: Terminology: Relative issues should be Relative's checkouts
This patch changes the term 'issues' in a screen reader caption in the
OPAC to the correct term 'checkouts'.

To test:
Setup:
- Have a patron with a guarantee
- Check out an item to the guarantee
- Make sure the guarantee allows their guarantor to see their checkouts
  (AllowStaffToSetCheckoutsVisibilityForGuarantor must be on for you to
  be able to set this)

1. In the OPAC, log in with the guarantor patron
2. Click on the Relatives' checkouts tab
3. Open a screen reader (in Ubuntu, Super + Alt + S to turn on/off)
4. Navigate to the table in the Relative's checkouts tab
   --> The screen reader should say 'Relative issue table with...'
5. Apply patch
6. Refresh the page
7. Restart the screen reader (if it was off)
   --> The screen reader should now say 'Relatives' checkouts table
   with...'

Alternatively, open the page inspector and inspect the table, the
caption is in the table tag, before the thead tag.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b77e8d1b37)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 32c5ed5099)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:50:40 +00:00
Katrin Fischer
3c27f11d24 Bug 33968: Add missing colons to guarantor related labels
Fixes some inconsistencies with the labels on the
patron detail page and patron edit form.

To test:
* Activate AllowStaffToSetCheckoutsVisibilityForGuarantor
  and AllowStaffToSetFinesVisibilityForGuarantor system
  preferences
* Link a patron to a guarantor
* Verify on the details tab the options for showing fines
  and checkouts show and are missing colons on the label
* Edit the patorn and verify the same is true for the form
* Apply patch
* Verify missing colons have been added :)

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d7e189b5bf)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit fd24231407)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:50:08 +00:00
Sam Lau
00946f6ed3 Bug 34071: Change the phrasing of 'automatic checkin' to fit consistent terminology
This patch simply changes 'Automatic checkin' to be 'Automatic
check-in'.

Test plan:
1) Go to administration -> item types and click the edit button on an
   item.
2) Notice there is a checkbox labeled 'Automatic checkin'.
3) Apply patch.
4) Refresh the page and notice the checkbox now says 'Automatic
   check-in'.
5) prove t/db_dependent/Koha/Checkouts.t
6) Sign-off :)

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit e2e236fa9e)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d6cf2b91ac)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:49:20 +00:00
6130a7482d Bug 31253: Item search in staff interface should call barcodedecode if the search index is a barcode
We should run any inputted barcode through barcodedecode before passing it to any subroutines.
This was missed during the initial development of bug 26351.

Test Plan:
1) Set itemBarcodeInputFilter to "Remove spaces from"
2) Create an item with the barcode "MYTEST"
3) Browse to the staff side advanced search
4) Run a barcode search for "MY TEST"
5) Note no results are round
6) Apply this patch
7) Restart all the things!
8) Repeat your search
9) Note the item was found!

Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Edit: fixed typo in comment
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d735a5804b)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 41d9b86323)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:48:26 +00:00
d024f6a225 Bug 33972: Remove settings of batch status to importing
This change was done in a transaction - it would either be set as imported
on success, or rolled back to staged on failure

There is no need for the intermediate status which is never committed

Signed-off-by: Nick Clemens <nick@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 52917c63ab)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c77c03a3ae)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:47:33 +00:00
dc4aba6a46 Bug 34130: Make requested_date nullable in api definition
This patch allows the requested_date for an ILL request to be NULL to accomodate
older data

To test:
1 - Install the Koha 2 Koha ILL plugin:
    https://gitlab.com/koha-community/plugins/koha-plugin-ill-koha
2 - Enable the ILL  system preference
3 - Force an ILL request with minimal data from backend:
    INSERT INTO illrequests (borrowernumber,biblio_id,branchcode,backend,status) VALUES (5,3,'CPL','Koha','placed');
4 - View the ILL table
5 - Error:
    {"message":"Expected string - got null.","path":"\/body\/0\/requested_date"}
6 - Apply patch
7 - Table loads successfully

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a8633a5812)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5edd76121b)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:40:27 +00:00
3aa5d5ad5b Bug 33989: Only look up authorized value descriptions for items in results
This patch changes the inventory tool so that it only populates the
authorized value descriptions for items that show up in the results.
That is, items that will be viewed by a human.

This change saves a lot of time by not performing unnecessary
database lookups.

Test plan:

0. Apply patch and koha-plack --restart kohadev
1. Go to create a SQL report from SQL
/cgi-bin/koha/reports/guided_reports.pl?phase=Create%20report%20from%20SQL
2. Save a report with the following SQL:
SELECT barcode FROM items where barcode <> '';
3. Run the report
4. Download as CSV
5. Edit the CSV and remove the "barcode" heading

6. Go to edit item for barcode 3999900000001
/cgi-bin/koha/cataloguing/additem.pl?op=edititem&biblionumber=1&itemnumber=1
7. Add "Damaged status" of "Damaged"
8. Click "Save changes"

9. koha-mysql kohadev
10. update items set notforloan = 9 where barcode = 3999900000001;

11. Go to inventory tool
http://localhost:8081/cgi-bin/koha/tools/inventory.pl
12. Upload barcode file via "Choose file"
13. Uncheck "Compare barcodes list to results"
14. Open F12 tools
15. Click "Submit"
16. Click "OK" on confirm box

17. Note that the inventory job takes around 30 seconds to run
instead of 60 seconds
17b. The exact figures may vary. If you compare with before patch
inventory runs, you'll be saving roughly 18 seconds.
18. Note that "Damaged" appears in the "Damaged" column, which
demonstrates that the authorized value lookup was completed for
the item in the result list

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 30be338c24)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 64c328b9e1)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:33:35 +00:00
Emily Lamancusa
56f9c98e38 Bug 33976: Disable claims returned option in moredetail.pl when another lost status is selected
Prevent "claims returned" from being selectable from moredetail.pl, even
if another lost status is already set

To test:
1. Configure Claims returned
    i. Go to Administration > Authorized Values > LOST
    ii. Add a new authorized value with value:6 and description:Claims returned
    iii. Go to Administration > System Preferences
    iv. Set ClaimReturnedLostValue to 6 and save
2. Go to any title record and click the barcode for any item
3. Click the Lost status drop-down.
   Note that the Claims Returned option is disabled.
4. Select a Lost status and click "Set status"
5. Click the Lost status drop-down.
   Note that the Claims Returned option is now selectable.
6. Apply the patch and refresh the page
7. Note that the Claims Returned option is now disabled.
8. Find a different item and check it out to a customer.
9. On that customer's account, click "Claim Returned" for that item
10. Click the barcode to view moredetail for that item
    Note that the Lost status drop-down is disabled with Claims Returned selected

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 6857d4f896)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5d8ae3f316)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:32:17 +00:00
f56a8a59a2 Bug 34080: Make suggestions_batch_ops a class
To test:
1. Make some suggestions with different statuses.
2. Try moving some suggestion to different statuses.
3. Going from PENDING to another status works fine.
4. Moving from other status (REJECTED, ORDERED, etc ) will cause a 500 error.
5. Apply patch
6. Try 2 - 4 again, no more 500 errors, yay!

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1d60fd79a4)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6656b66741)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:31:09 +00:00
adfefa270c Bug 34083: (follow-up) Prevent showing 'null'
In patron lists, if the patron added is an organization without the firstname, it presents 'null'. This fixes that

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 17e19fe311)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit fd372ddcd3)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:28:58 +00:00
5cea24df5c Bug 34083: Add searching for full term on patron auto-complete
To reproduce, on k-t-d:
1) Create a new patron of category 'School'
2) Enter 'Middle school high school' on the mandatory 'Name' field and put something in 'Card number:'
3) Visit patron lists at /cgi-bin/koha/patron_lists/lists.pl and click 'New patron list'
4) Put something in 'Name:' and click 'Save'
5) On the 'Patron search' input, enter 'middle school high school' slowly and observe the auto-complete behaviour
6) Notice how after you start typing the second word, the auto complete results vanish.
7) Apply patch, repeat plan and verify it now works as expected.

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a8e9b25d8e)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c93e7167f6)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:28:46 +00:00
efe0faccdc Bug 33578: Fix controller when editing a restriction type
Do not display a warning when we are editing a restriction type and no
other types with this description exists.

Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b5de15c4b8)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 61b9002848)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:24:05 +00:00
8a69164c5b Bug 33578: Fix patron restriction types edition
When editing an existing patron restriction type you'll always get an error on saving:

Label is already in use

To test:
* Activate use of patron restriction types
* Edit any of the system types
* Create new ones

Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 9e32945f20)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 87864a5ccf)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:23:55 +00:00
99239d0f7e Bug 33894: Use template wrapper for tabs: OPAC search history
This patch updates the OPAC search history page so that it uses
the new WRAPPER syntax to generate tabs markup.

To test, apply the patch and view the OPAC search history page. With the
OpacAuthorities system preference enabled you should see two tabs:
Catalog and Authority. Confirm that each tab shows the correct
information.

Deactivate OpacAuthorities and reload the search history page. The
bibliographic search history should display without tabs.

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 2c6e64ba96)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d53d0f6537)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:22:35 +00:00
6a399fb0ba Bug 33894: Restructuring: Use BLOCKs for biblio and authority sections
In order to make the conversion to the tab wrapper markup easier I'm
putting the biblio search history and authority search history sections
into blocks. This will make it easier to include or not include the
sections using template logic.

To test, apply the patch and, if necessary, perform some searches for
bibliographic and authority records. The OPAC search history page should
be unchanged, with the correct information showing under each tab and in
each section for current and previous searches.

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 f3def0d264)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5121269535)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:22:26 +00:00
97bc408f3e Bug 34013: Recalls awaiting pickup doesn't show count on each tab
This patch modifies recalls_waiting.pl so that it defines template
variables for 'recalls waiting' and 'recalls waiting over x days'
counts in the same way that waitingreserves.pl handles it.

To test you must have UseRecalls enabled, and some recalls data that
will allow you to see content under each tab.

Go to Circulation -> Recalls awaiting pickup and confirm that both tabs
show the correct count.

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 44759b4be3)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit cdaa88d9c0)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:21:31 +00:00
28354b300f Bug 34012: Use template wrapper for tabs: Recalls awaiting pickup
This patch updates the recalls awaiting pickup template so that it uses
the new WRAPPER directive to build tabbed navigation.

Note: this patch includes indentation changes, so check the diff
accordingly.

To test you must have UseRecalls enabled. Apply the patch and go to
Circulation -> Recalls awaiting pickup.

Both the "Recalls waiting" and "Recalls waiting over X days" tabs should
look correct and work correctly.

Signed-off-by: Sam Lau <samalau@gmail.com>
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 309148160b)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 4e2b346b07)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:20:43 +00:00
75a1c7966d Bug 33896: Check whether index is defined before string match
This patch checks that $indexes[$i] is defined before testing whether the string matches to remove the logged warning when searching

Test plan:
1) In the intranet, search the catalog from the top search bar
2) Check plack-intranet-error.log
3) There should be a warning "[WARN] Use of uninitialized value within @indexes in string eq"
4) Apply patch
5) restart_all and then re-try the search
6) The warning should no longer appear

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit e0c09d230c)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 596d63b426)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:20:10 +00:00
Sam Lau
a25d826d08 Bug 31618: Fix typo in POD for C4::ImportBatch::RecordsFromMARCXMLFile
To test:
1) Apply the patch
2) Visit C4::ImportBatch::RecordsFromMARCXMLFile
3) See that in the POD (mine was somewhere around line 1592) the line starting with '@PARAM1' now says '@PARAM1, String, absolute path to the MARCXML file.'
4) Sign off :)

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 74bd332051)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 68a146ab49)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:18:55 +00:00
da76c54dbd Bug 33117: DBRev 22.11.07.002
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 5f1c5a04fa)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 073744284a)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:16:36 +00:00
63bb0cbd2e Bug 33117: (follow-up) Rename preference
As it's been requested that we keep the search defaults consistent, I
think this preference is better names DefaultPatronSearchMethod and
appear next to DefaultPatronSearchFields. This patch makes that change,
though actually applying it to the other search area's (outside of
autocomplete) has been left for another bug.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c50fab16b5)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6ea0111ef8)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:15:45 +00:00
Laura Escamilla
d1be3c746b Bug 33117: Adding new PatronAutoCompleteSearchMethod system preference
This patch adds a new system preference called "PatronAutoCompleteSearchMethod"
which allows staff to choose between "Starts with" or "Contains" when
searching for patrons.

The "Contains" option should be useful when searching for patrons that have
multiple surnames or when searching using a patron's middle name.

New Test Plan:
 0. Ensure system preference PatronAutoComplete is set to Try
 1. Create a patron that has a first name, middle name and two surnames.
    (i.e. Adela Maria, Hernandez Acosta).
 2. In patron or checkout search, enter their first name and first
    surname without submitting.
 3. Confirm that a record is found in the autocomplete results
 4. In patron or checkout search, enter their first name and second
    surname without submitting.
 5. Confirm that no record is found.
 6. Enter their middle name and first surname. Confirm that no record is
    found.
 7. Enter their middle name and second surname. Confirm that no record
    is found.
 8. Apply the patch, update database
 9. Under Administration > Global System Preferences > search for
    "PatronAutocompleteSearchMethod"
10. Choose "Contains" instead of "Starts with" for the system
    preference, reload your search page
11. Repeat steps 2-4. The patron record should appear for all search
    methods.
12. Sign off!

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 7b675997b4)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit e5e9f2c203)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:15:34 +00:00
04463e39ff Bug 34052: Use root relative URL for subscription-detail.pl
This patch replaces a same directory relative URL with a root
relative URL, so that the navigation to subscription-detail.pl
works correctly after deleting a serial.

To test:
0. Apply patch
1. Go to http://localhost:8081/cgi-bin/koha/serials/serials-home.pl
2. Click "New subscription"
3. Click "Search for a vendor"
4. Click "OK"
5. Click "Choose"
6. Click "Search for record"
7. Type "e" into "Keyword:" box
8. Click "Search"
9. Click "Choose" on top result
10. Click "Next"
11. Fill in "Serials planning" however you like, and click
"Test prediction pattern"
12. Click "Save subscription"
13. Click "Serial collection" in left nav menu
14. Click "Delete selected issues"
15. Click "Yes, delete"
16. Click the link under the "Subscription num." table column
17. Note that you're taken to the subscription detail page

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b7f89dcca3)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit ffca4b86ad)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:12:06 +00:00
96411ad9d2 Bug 33944: Don't fetch item object unless using recalls
To test:
1 - Check someitems out to a patron
2 - View thier checkouts
3 - Apply patch, restart_all
4 - Confirm checkouts load as before
5 - Enable recalls
6 - Recall an item checked out to this patron
7 - Confirm recall shows as expected

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 4610bc64eb)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 9df75ef0cb)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 11:11:10 +00:00
7408ac070f Bug 33973: Restore sorting on Vue tables
Regression from the KohaTable Vue component added by bug 33066.

_dt_default_ajax expects options.columns to contain the columns.

Test plan:
Add some agreements, go the the agreement list view and confirm that you
can now sort the agreements using the header columns.

Note that the CSS is not correct yet. My understanding is that the
DataTable Vue component keep the 'sorting' class on the th which display
the grey up/down icon over the blue icon which indicate the current sort
column.

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 7990f3e741)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 5799f4bed2)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:49:32 +00:00
bd3f6844b5 Bug 32245: Fix delete news item from staff home page
Simple fix: op was named incorrectly in URL.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a9389b60d3)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c7f28fbc93)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:48:56 +00:00
516929e60e Bug 34010: Template corrections to recall pages
This patch makes some corrections to recall pages:
- Update breadcrumbs menu to use wrapper.
- Add <div class="page-section"> where it is missing.
- Use biblio-title include to show links to bibliographic record titles.
- Correct Bootstrap button dropdown markup for consistent style
- Change some submit buttons to <button> elements for consistent style

To test you must have UseRecalls enabled. Having some sample recalls
data will help. Check the following pages to confirm that everything
looks correct:

- Circulation ->
  - Recalls queue
  - Recalls to pull
  - Overdue recalls
  - Recalls awaiting pickup
  - Old recalls
  - Existing recalls: View a bibliographic record with a recall and
    click "Recalls" in the sidebar.

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit ec6f8186ae)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit f19eab5752)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:47:43 +00:00
66df7371ac Bug 24517: Add missing 6th position to date-entered-on-file index
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Adding the biblio-zebra-indexdefs.xsl on same patch (as should
be generated with xsltproc).
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 12a986e668)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d8f339dda7)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:47:02 +00:00
3f2effb2a7 Bug 31651: Adjust tests
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c93df98068)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d1e538c2cb)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:45:32 +00:00
Jacob O'Mara
39f46d9969 Bug 31651: Replaced duplicate error message
The duplicated error message on ln119 has now been replaced for clarity.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.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 d6566f41e9)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 4ed02e7de5)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:45:19 +00:00
4f66174249 Bug 33500: Add tests for RecordLocalUseOnReturn
To test:
1. Turn on RecordLocalUseOnReturn
2. prove -v /kohadevbox/koha/t/db_dependent/Circulation.t
3. Tests fail.
4. Apply patch
5. prove -v /kohadevbox/koha/t/db_dependent/Circulation.t
6. Tests pass.

Signed-off-by: Sam Lau <samalau@gmail.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 2238d9f096)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b07fa2af06)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:40:25 +00:00
4e3d80ab3b Bug 33993: Add order_receive to GET orders endpoints
This adds order_receive to the list of permissions that allow the
endpoint to return orders.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Sharon Dugdale <Sharon.Dugdale@cumberland.gov.uk>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1f0cd38d56)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d89d452a9d)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:37:36 +00:00
874bf73b7c Bug 34051: Cache empty hashref for non-existent authorised values
When fetching authorised value descriptions, we need to handle
scenarios where a value doesn't exist in the cache and doesn't
exist in the database. In this situation, we return an empty
hashref, and this patch makes us cache this empty hashref.

This is important because otherwise the function
Koha::AuthorisedValues->get_description_by_koha_field will
do a database call every time it encounters the same value that
doesn't exist in the authorised values table.

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 a3a0aaec10)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 25230f4cf9)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:31:49 +00:00
a1c0c3ec6b Bug 34033: (bug 30649 follow-up) Fix update typos
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 96794db659)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit d636c81cd6)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:30:09 +00:00
444a519f09 Bug 33987: Combine multiple db updates one in BatchCommitRecords
When replacing existing records BatchCommitRecords will the table import_records will be updated three times for three different fields by three different queries. Not only is this inefficient ( especially for large batches ), it seems that this is causing the dreaded "Lock wait timeout exceeded; try restarting transaction" error on some mysql/mariadb configurations.

1) Test plan
2) Download a marc record from Koha
3) Modify the title of that same bib in Koha
4) Stage the downloaded record and overlay the existing record
5) Verify the title has reverted to the original title from the
   downloaded record!

Signed-off-by: Sam Lau <samalau@gmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit ab91409f7f)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 818ee1c312)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:29:00 +00:00
2d594b64eb Bug 33417: Fix translation in toolbar
This commit allows the string to be translated - tested using fr-FR and a dummy string in the .po file

Test plan as above

Signed-off-by: Martin Renvoize <martin.renvoize@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 62b2609e86)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 1ba4c8b129)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:23:03 +00:00
78c45e8363 Bug 33417: Remove old components
This commit deletes the old toolbar components as they are no longer
necessary

Test plan as above

Signed-off-by: Martin Renvoize <martin.renvoize@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 bd9255d849)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 11d27b0a4a)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:22:37 +00:00
2e1b74bd6c Bug 33417: Add toolbar imports and options
This commit amends the required files to import the toolbar and add the
correct options

Test plan as above

Signed-off-by: Martin Renvoize <martin.renvoize@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 c10d6c6b00)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 9352f0aff1)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:22:29 +00:00
23f0dd3c19 Bug 33417: Create standard toolbar component
This commit introduces a standard Toolbar component that can be used
throughout ERM

Test plan:
1) Apply patch
2) Navigate to Agreements and click the "Add agreement" button - this
   should work as normal
3) Navigate to Licenses and repeat
4) Navigate to Local packages and repeat
5) Navigate to local titles - there should be two buttons, one to add and
   one to import. These should work as normal

Signed-off-by: Martin Renvoize <martin.renvoize@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 09666ecf4e)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit c7d3cad286)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:22:21 +00:00
63962d152e Bug 33897: (QA follow-up) Correct code for tab selection
This patch corrects the code for selecting tabs other than the first
tab.

To test, apply the patch and view the bibliographic detail page for a
serial record and with various settings of the opacSerialDefaultTab
system preference.

If you select "subscriptions tab" the subscriptions tab should be active
by default.

You can also enable html5media and view a record with html5media
information and no holdings. The media tab should be displayed by
default.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 5308697ab8)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 6e99fa4ec7)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:10:42 +00:00
8693820fff Bug 33897: Use template wrapper for tabs: OPAC bibliographic detail page
This patch updates the OPAC bibliographic detail page so that it uses
the new WRAPPER syntax to generate tabs markup.

To test, apply the patch and locate a bibliographic record. View the
detail page. Verify that tabs are working, including all the options:

  - Holdings
  - Other holdings (If OpacSeparateHoldings is enabled)
  - Descriptions (MARC notes)
  - Subscriptions
  - Serial collection (UNIMARC, untested)
  - Components (If ShowComponentRecords is enabled. See Bug 11175 for
    sample record)
  - Comments
  - Editions (OPACFRBRizeEditions)
  - Html5media (If HTML5MediaEnabled is on. See Bug 8377 for sample
    records)
  - Images (If OPACLocalCoverImages is enabled)
  - NovelistSelect
  - Author identifiers (Witgh OPACAuthorIdentifiers enabled, see Bug
    29897)

Bonus points for testing these tabs for which I don't have credentials:
- Syndetics TOC
- Syndetics Excerpt
- Syndetics Reviews
- Syndetics AuthorNotes
- LibraryThing for Libraries (with LibraryThingForLibrariesTabbedView
  set to "in tabs.")

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 59c2a77ab7)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 3f8a4a4756)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-07-18 10:10:33 +00:00