This patch hides the additional fields input on the library add/edit
page when there are no additional fields defined for libraries.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Test plan, k-t-d:
1) Add a new additional field to 'branches':
<staff_url>/cgi-bin/koha/admin/additional-fields.pl?tablename=branches
2) Click 'New field'. Add a name. Click Save.
3) Repeat step 2 but repeatable. Repeat again for 2 more of AV category
(one repeatable, one not repeatable)
4) Edit a library:
<staff_url>/cgi-bin/koha/admin/branches.pl?op=add_form&branchcode=CPL
5) Input various values in the different additional fields. Click
'Submit'
6) Visit the detail page of the library and verify the additional fields
data is displayed correctly:
<staff_url>/cgi-bin/koha/admin/branches.pl?op=view&branchcode=CPL
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
record_if in the additional_field_values is an int(11)
This works for most cases, but in the branches case, the id column is
actually a varchar (branchcode).
This patch updates the column to accomodate for this.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
To test:
0. Have some bookings that are ready to collect.
1. Load the bookings to collect report.
2. Table does not load.
3. APPLY PATCH
4. Try again, table loads.
5. Make sure you can filter by 'Pickup library'
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Make it consider the possibility of a patron not existing.
This ensures that placing a request with partners does not error and works as expected even if the ILL request's borrowernumber is undef
To test:
1) Run the test file before and after applying this patch:
prove t/db_dependent/Koha/ILL/Requests.t
To test (ILL request is kept after borrower is deleted):
1) Apply all patches except this one
2) Enable ILLModule and create an ILL request.
3) Add a type, valid cardnumber and library.
4) Delete the associated borrower.
5) Confirm the ILL request is still listed and shown as expected
Continue test, confirm follow-up bug is fixed:
6) Click 'Place request with partners'
7) You get a ERR_TOO_MANY_REDIRECTS error
8) Apply this patch and restart plack. Repeat.
9) Confirm the place request with partners libraries page is shown correctly
Sponsored-by: UKHSA - UK Health Security Agency
Signed-off-by: Jeremy Evans <Jeremy.Evans@ukhsa.gov.uk>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Only show this attribute if defined
Sponsored-by: UKHSA - UK Health Security Agency
Signed-off-by: Jeremy Evans <Jeremy.Evans@ukhsa.gov.uk>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Only show this action button if the ILL request has a borrowernumber
Sponsored-by: UKHSA - UK Health Security Agency
Signed-off-by: Jeremy Evans <Jeremy.Evans@ukhsa.gov.uk>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Sponsored-by: UKHSA - UK Health Security Agency
Signed-off-by: Jeremy Evans <Jeremy.Evans@ukhsa.gov.uk>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Sponsored-by: UKHSA - UK Health Security Agency
Signed-off-by: Jeremy Evans <Jeremy.Evans@ukhsa.gov.uk>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Test plan:
Run t/db_dependent/SIP/Message.t
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Test plan:
Pick an item (without holds) with homebranch A and holdingbranch B.
(My SIP examples use RMA for A, NRD for B.)
Enable AutomaticItemReturn.
Check in this item at branch B via SIP.
* 09N20240422 10000020240422 160000APNRD|AONRD|ABperl01|
You should see something like:
* 101YNY20240422 105736AONRD|ABperl01|AQRMA|AJLearning Perl /|CSH|CTRMA|CV04|
Verify too that a transfer was started.
Now disable AutomaticItemReturn. Remove the transfer.
Check in this item at branch B via SIP.
You should see now something like:
101YNY20240422 105515AONRD|ABperl01|AQRMA|AJLearning Perl /|CSH|CTRMA|CV04|AFThis item must still be transferred to RMA branch.|
Verify that no transfer was started.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
See bug 36954. The file sip.log should not be found anymore in
log4perl.conf.
Test plan:
Edit log4perl.conf. Replace sip-output.log by sip.log.
Check About, tab sysinfo. You should see a warn.
Edit again. Switch back to sip-output.log.
Verify that there is no warn anymore on about.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: William Lavoie <william.lavoie@inLibro.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch makes some simple markup and CSS changes to the course
details page in order to improve the layout of the section:
- Add colons after labels.
- Replace fieldset.rows with div.rows (there's no form).
- Make list of instructors line up with other details.
- Do not display fields which are empty.
ALSO: Replaced the "Reserves" heading with course name, matching
breadcrumbs and page title.
To test, apply the patch and go to Course reserves.
- If necessary, create a course.
- View the details of the course.
- Confirm that the list of details looks correct.
- Test with all the optional fields empty: Section, term, instructor,
staff note, public note. There should not be empty lines for these
fields in the course details.
- "Number of students" should show "0" if you left the field empty.
- Add multiple instructors to confirm that they are displayed in
alignment with other course details.
- The page heading should match the page breadcrumb.
Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.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: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Note:
I am using $rs in the script to prevent searching branches again
unneeded. And pass public_count to opac-library.tt to prevent
another call of Branches.all (for bread crumbs), like masthead
already does btw.
Test plan:
[1] Have two (or more) public libraries.
Verify that you see Libraries on the OPAC home page and that when
clicking Libraries, you first have the library list. Are the bread
crumbs as expected?
Click a library on that list. Do you get its details? Are the bread
crumbs as expected?
[2] Now have only one public library.
Verify that you see Contact on the home page.
And that when clicking Contact you go directly to the library details
without the intermediate library list. Are the bread crumbs still
as expected (with Contact instead of Libraries)?
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
To test:
1. Turn on EnableAdvancedCatalogingEditor
2. From the advanced editor, pull up the modal for macros.
3. Notice the size.
4. APPLY PATCH
5. Try step 2 again, this time the modal is wider.
6. Try on different screen sizes.
Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
To test:
-Apply patch
-Run database update
-Install German language
-Activate German translations in system preferences
-Go to advance search
-Check language pull down shows translations for languages included in this patch
Signed-off-by: William Lavoie <william.lavoie@inLibro.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch adds a relator term that was added to the MARC code list for
relators in the Oct. 17, 2024 technical notice. The new term is tad -
Technical advisor.
To test:
1. Apply patch and reset_all
2. Go to Administration > Authorized values
3. Search for the RELTERMS list and click on it
4. Search for tad
--> There should be an entry for tad - Technical advisor
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Updates system preference text MarcFieldsToOrder by adding string "When there is no mapping for price, Koha will use 345$c and 020$c for MARC21 records and 345$c and 010$c for UNIMARC records"
to test:
- go to Admin > System preferences > MarcFieldsToOrder
- check there is no string like "When there is no mapping for price, Koha will use 345$c and 020$c for MARC21 records and 345$c and 010$c for UNIMARC records"
-apply patch
- verify there is the string
Signed-off-by: Andrew Fuerste Henry <andrew@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
It will be a commented line in the debian template and added also
in the crontab.example file.
As mentioned on BZ, the comment can easily be removed automatically
during Docker builds or startups etc.
Test plan:
Just read the patch. Nothing changes here actually.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
To test:
- Go to /api/v1/.html#op-get--acquisitions-baskets-managers
- See 'possibe' misspelling
- Apply patch and revisit
- Spelling is fixed
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch removes a useless autouse line.
Test plan:
0. Apply the patch
1. koha-plack --restart kohadev
2. Go to http://localhost:8081/cgi-bin/koha/mainpage.pl
3. Nothing blows up
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Followed the test plan, works as advertised.
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Test plan:
NOTE: Needs dev_install or ktd.
[1] Add a die in a script somewhere to simulate a crash.
For example in opac-main.pl: die "Line 43";
[2] Run koha-plack --restart YOUR_CLONE (without -dev) and hit that page.
See no dev output?
[3] Run koha-plack --restart -dev YOUR_CLONE and hit page again.
See dev output?
[4] BONUS: Do a koha-plack --reload YOUR_CLONE (without -dev). Hit page.
Verify that environment did not change.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Simply, remove the !=0 test. Test for true.
Test plan:
Restart SIP.
Ask item info (SIP 17) on a waiting hold. It must have a
hold pickup date.
Check that warn disappears with this patch.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Test plan:
Read the patch.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
They were mostly under tab about, but they should be under sysinfo.
Test plan:
If you would move your log4perl file, plack.psgi crashes. So sorry
but we cannot test that.
Note that you cannot simulate logfile_not_writable either, since it
also crashes plack.psgi before reaching about.pl. See 39155.
So a trivial hack remains:
Bonus: Edit about.pl and changed the moved if( !-w $file ) test and
replace it by if ( 1 ) in the new sub log4perl_check.
Restart and verify that you now have an error message on sysinfo.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Test plan:
Try to translate itemtype for an opac language not part of
intranet languages.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Combining opac with pref template is wrong. This pref should
actually be renamed to something like intranetTheme(s) or so.
Replacing the obsolete prog theme in Languages.t by undef. This
achieves the same: getting all themes for that interface.
Test plan:
Add some languages for opac and intranet. Do not enable exactly
the same set.
Enable TranslateNotices.
Verify that you have all OPAC languages on memberentry and
opac-messaging. And all languages on additional contents.
Run t/db_dependent/Languages.t
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested with:
OPAC languages: en, nl-NL, de-DE
Staff languages: en, de-DE, fr-FR
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
To test:
1. Make an item or item type 'Bookable'
2. Place a booking for that item
3. Go the 'Bookings' tab for that item.
4. Edit the booking
5. Submit the edit request and see at the top of the modal "Failure"
6. APPLY PATCH
7. Try editing bookings, now it should work.
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
To test:
1. Set up sysprefs:
- Set any non-empty value for ClaimReturnedLostValue
- Set AutoClaimReturnStatusOnCheckout to "found in library"
- Set AutoClaimReturnStatusOnCheckin to "returned by patron"
2. Check out an item to a patron
3. On the patron's account page, click the "Claim Return" button next to
that checkout
4. Check the item in. Note the message that the claim was auto-resolved.
5. Return to the patron's account page and open the Claims Returned tab
--> Note that the claim is resolved and hidden
6. Click the "Show all 1 claims" link to view the hidden claim. Make a
note of the resolution code and timestamp.
7. Check the item out again
--> Note the message saying that the claim was resolved, even though it
was already resolved previously
8. View the return claim again
--> Note that the timestamp and resolution code have changed
9. Apply patch and restart_all
10. Repeat steps 2-8 with a new item
--> Note you do not get a claim resolved message on checkout this time
--> Note that the timestamp and resolution code remain the same before
and after the checkout
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
When editing a child while Childneedsquarantor active, trying to delete
a guarantor while saving a non-patron guarantor will prevent the user
from saving. However, if an adult has expired, some librarian would like
to remove the account and let some information in non-patron guarantor.
TEST PLAN
Before applying patch
1 - Open Lisa Charles'page, add Henry Acevedo as Guarantor, also fill
Guarantor surname and firstname
2 - Edit the page and try and remove Henry Acevedo, it won't work
however there is still one guarantor
3 - Apply patch
4 - Try and remove Henry Acevedo -> it will work
5 - add HA as a guarantor again
6 - try and remove him AND let guarantor firstname and surname empty ->
you can't
7 - Add HA and Edna Acosta as guarantor
8 - Remove HA and ler guarantor firstname and surname empty -> you can
Signed-off-by: Thibault Keromnes <thibault.keromnes@univ-paris8.fr>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
We have a case here where we have checkout_id pointing at issues and
old_issues tables. We need to trick TestBuilder to NOT automagically
build our related checkout.. This patch passes 'undef' to the foreign
key field and then sets it after the fact to the related Old::Checkouts
objects we've already built above.
This patch should prevent the random failures we were seeing before
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch adds a trigger into the anonymize function of
Koha::Old::Checkouts such that we pass along the anonymize action to
the renewals record.
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch adds a trigger into the anonymize function of
Koha::Old::Checkout such that we pass along the anonymize action to the
renewals record.
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch adds unit tests to ensure renewals properly respect the
patron privacy settings.
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch adds CSRF protection to patron list deletions.
Also changed: The "Delete selected lists" button is now in a floating
toolbar.
To test, apply the patch and go to Tools -> Patron lists.
- If necessary, create a few patron lists.
- Test the two methods for list deletion available on the page:
- Check one or more checkboxes and then click the "Delete selected
lists" at the top of the page.
- Click the "Actions" button for an individual list and choose "Delete
list."
- Open the checkout page for a patron.
- Under the "Patron lists" tab, add the patron to a list.
- Click the "Actions" button for an that list and choose "Delete
list."
- When you are taken to the patron lists page the list should have
been deleted.
- Perform the same test on the patron details page.
Sponsored-by: Athens County Public Libraries
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This change improves the validation of the report ID passed by the user.
Test plan:
0. Apply the patch
1. koha-plack --restart kohadev
2. Create a SQL report
3. Go to /cgi-bin/koha/tools/scheduler.pl
4. Add in a Time, Date, and Email
5. Choose your report from the list
6. Click "Save"
7. Note that your report is saved
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
acqui/booksellers.tt and admin/currency.tt use | $HtmlTags without first
filtering the string they wrap.
Test plan:
1. Without the patch, load the URL in comment 1, note the alert()
2. Apply patch, load the URL in comment 1, no alert()
Sponsored-by: Chetco Community Public Library
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Followed the test plan, works as advertised.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Magnus Enger <magnus@libriotech.no>
The new test fails without this patch, and passes
when it is applied.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
[EDIT] Added a shebang line.
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This change adds a Template::Toolkit filter which is invoked
via " | scrub_html type => 'note' ".
Test plan:
0. Apply the patch
1. prove t/Koha/Plugins/HtmlScrubber.t
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This change replaces single quotes with double quotes to prevent XSS
for particular operations on the circ returns page.
Test plan:
0. Apply the patch
1. Go to http://localhost:8081/cgi-bin/koha/circ/returns.pl?print_slip=1&reserve_id=1
2. Note that a pring slip is generated
(you may need to allow popups)
3. To test the XSS is patched, try the proof-of-concept from the
bug report
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>