Lucas Gass [Fri, 12 May 2023 17:54:26 +0000 (17:54 +0000)]
Bug 33725: Add collection to search results
To test:
1. Apply patch and restart services
2. Do a catalog search that will return available, onloan, and notforloan items. (withdrawn,lost,damaged)
3. Notice that the location column should now also include the collection description underneath the shelving location.
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Marcel de Rooy [Fri, 26 May 2023 12:58:22 +0000 (12:58 +0000)]
Bug 33844: Fix is_denied_renewal
Going via result_set->has_column does cost actually nothing if
the object is already there.
Test plan:
Run again t/db_dependent/Koha/Item.t
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> 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>
Marcel de Rooy [Fri, 26 May 2023 12:54:22 +0000 (12:54 +0000)]
Bug 33844: Modify test to show problem
Add delete key.
Without the follow-up, this triggers a delete. Test fails.
DBIx::Class::Row::delete(): Not in database at /usr/share/koha/Koha/Object.pm line 234
Test plan:
Run t/db_dependent/Koha/Item.t
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> 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>
Marcel de Rooy [Fri, 26 May 2023 09:28:28 +0000 (09:28 +0000)]
Bug 32478: (QA follow-up) Keep current hashref behavior
Prevent a crash on wrong contents for ItemsDeniedRenewal pref
as we did before.
Note: Could be a provisional measure (no band aid to repeat anywhere)
until we resolve this in preferences.pl.
Test plan:
Without this patch:
Change ItemsDeniedRenewal to 'nonsense'
Run perl -MKoha::Items -e'Koha::Items->find(X)->is_denied_renewal; print "OK\n"'
=> Replace X by a valid itemnumber
Crashes with: Can't use string ("nonsense") as a HASH ref ... No OK print.
Apply this patch
Run perl -MKoha::Items -e'Koha::Items->find(X)->is_denied_renewal; print "OK\n"'
=> Replace X by a valid itemnumber
Warns only with: Hashref expected for ItemsDeniedRenewal. You got OK.
Clear ItemsDeniedRenewal
Try again. No warning anymore.
Run t/Context.t
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Nick Clemens [Thu, 4 May 2023 18:39:50 +0000 (18:39 +0000)]
Bug 32478: (follow-up) Tidy code
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>
Nick Clemens [Thu, 4 May 2023 18:37:53 +0000 (18:37 +0000)]
Bug 32478: (follow-up) UpdateItemLocationOnCheckin no longer needs flattening
This patch removes a line flattening the arrays generated by get_yaml_pref_hash
as it is no longer necessary
Conditionals are adjusted to avoid warnings in tests
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>
Bug 32478: Fix handling of undef values in ItemsDeniedRenewal
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>
David Gustafsson [Thu, 29 Sep 2022 15:18:40 +0000 (17:18 +0200)]
Bug 32478: Remove Koha::Config::SysPref->find since bypasses cache
get_yaml_pref_hash also allows invalid YAML and only parses a limited
subset so remove this method to avoid future issues.
To test):
Since tests already exists for C4::Context->yaml_preference and this
is a trivial change, do we really need a test plan for this?
Sponsored-by: Gothenburg University Library 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>
Jonathan Druart [Wed, 7 Jun 2023 07:30:15 +0000 (09:30 +0200)]
Bug 33934: Add more detail to 'No encryption_key in koha-conf.xml'
If encryption_key is not set in $KOHA_CONF we are raising an exception.
This key was only needed for a couple of feature, but now we are using Koha::Encryption from the update DB process, and so the upgrade fails with no more info than 'No encryption_key in koha-conf.xml'.
We need to provide more detail in this error.
Additionally we reject "__ENCRYPTION_KEY__", in case people will simple
copy/paste that
Test plan:
Apply the patch
Edit $KOHA_CONf, remove the encryption_key entry (or blank)
restart_all
Go to the about page and enable 2FA
=> warning on the about page, and 500 server-side are displaying more
info about how to generate the missing entry
Edit $KOHA_CONF and set the value to __ENCRYPTION_KEY__
restart_all
=> Same messages
Edit $KOHA_CONF and set a correct value
restart_all
=> No error, everything is working 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>
Owen Leonard [Fri, 26 May 2023 13:45:56 +0000 (13:45 +0000)]
Bug 33524: Use template wrapper for tabs: Authority editor
This patch updates the authority editor template to replace tab markup
with the use of WRAPPERs. Some CSS and JS has been modified in order to
make the custom style and behavior of the tabs on this page work
correctly with standard Bootstrap tab markup.
To test, apply the patch and go to Authorities -> New authority.
- Confirm that the tabs look correct, with the same style they had
before the template change.
- The first tab ("0") should be selected by default.
- Confirm that tab-switching works correctly: The tab color should
change and the list of numbered tags in the menu just below should
change to match the section.
- Confirm that these tag number links still work correctly to jump you
down the page to the corresponding tag.
- Without filling in any mandatory fields, click the "Save" button.
- You should get an error message about missing mandatory fields.
- Clicking the "Go to field" link should take you to the correct tab
and the correct tag.
- Append a hash to the URL to pre-select a tab other than the first one,
e.g. "/cgi-bin/koha/authorities/authorities.pl?authtypecode=PERSO_NAME#tab5XX_panel"
The correct tab should be selected upon page load.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Martin Renvoize [Mon, 22 May 2023 14:54:14 +0000 (15:54 +0100)]
Bug 33343: Catch more cases and correctly use new-password hint
I believe where we're allowing a user to set a new password instead of
using autocomplete="off" we should be hinting to the brownser that it's
a new password box with autocompelte="new-password".
I also correct a couple of missing instances.. Honestly, I'm not sure
how much this helps these days as most browsers offer to save passwords
regardless.
See: https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Bug 33343: Make use of the 'autocomplete=off' attribute on password fields
This patch adds 'autocomplete=off' to all password type fields in the OPAC
To test:
1. Apply the patch
2. Visit http://master/cgi-bin/koha/opac-main.pl
3. Inspect the page
--> Confirm html shows autocomplete off on the password field
4. Click on Log in (without filling any field)
5. Repeat step 3
--> Confirm html shows autocomplete off on the password field
6. Set 'PatronSelfRegistration' system preference to 'Allow' and PatronSelfRegistrationDefaultCategory to 'Board'
7. Visit http://master/cgi-bin/koha/opac-memberentry.pl
9. Repeat step 3
--> Confirm html shows autocomplete off on the password field
10. Connect to the OPAC
11. Click on Change password
11. Repeat step 3
--> Confirm html shows autocomplete off on the password field
12. Set 'EnableExpiredPasswordReset' system preference to 'Enable'
13. Visit http://master/cgi-bin/koha/opac-reset-password.pl
14. Repeat step 3
--> Confirm html shows autocomplete off on the password field
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>
Jonathan Druart [Tue, 16 May 2023 14:36:26 +0000 (16:36 +0200)]
Bug 32060: Use selectrow_array
Trivial ergonomic patch, use selectrow_array, no need to prepare the
query
+ perltidy the sub
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: Tomas Cohen Arazi <tomascohen@theke.io>
To test:
1) Ensure the following tests pass
t/db_dependent/Koha/Item.t
t/db_dependent/Koha/Bibio.t
2) Go to a biblio (preferably as serial) with many items and
click "New" -> "New item" and note down the response time.
3) Apply the patch
4) Ensure tests in 1) still pass
5) Repeat step 2), the response time should be substantially
improved
Sponsored-by: Gothenburg University Library 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: Tomas Cohen Arazi <tomascohen@theke.io>
Matt Blenkinsop [Tue, 21 Mar 2023 19:14:45 +0000 (16:14 -0300)]
Bug 32932: Update router to use object references - agreements
This patch updates the Vue files for ERM to use router object links rather than urls - this will make it much simpler to maintain the router if urls need to be updated. This first patch only updates the files in the agreements section of ERM as a first step to introduce the topic for discussion.
Test plan:
1) Apply patch
2) Navigate to the Agreements section of ERM and click on different navigation links/buttons
3) The links/buttons should all work as normal
4) Review the code to see that the component files now refer back to the router using objects rather than url strings
Signed-off-by: Agustin Moyano <agustinmoyano@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Since Bug 28445 the method Koha::Item->as_marc_field has the option mss not anymore.
This patch removes this in Koha::Filter::MARC::EmbedItems.
Test with :
prove t/db_dependent/Koha/Filter/EmbedItems.t
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Owen Leonard [Mon, 5 Jun 2023 13:06:39 +0000 (13:06 +0000)]
Bug 33892: Use template wrapper for tabs: OPAC authority detail
This patch updates the OPAC authority detail page so that it uses
the new WRAPPER syntax to generate tabs markup.
To test, apply the patch and locate an authority record in the OPAC
which has notes fields.
When viewing the details for that record the notes should appear in a
single "Notes" tab.
Signed-off-by: Sam Lau <samalau@gmail.com> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Bug 21983: Make DelBiblio update linked ILL requests
This patch makes DelBiblio update the biblio linked ILL requests so the
value in biblio_id is moved to the deleted_biblio_id.
The change is covered by tests.
To test:
1. Apply this patchset
2. Run:
$ ktd --shell
k$ updatedatabase
k$ qa --run-tests
=> SUCCESS: Tests pass! All green/good
3. Sign off :-D
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch adds a new method, used for retrieving the linked ill
requests for a biblio.
To test:
1. Apply this patch and run:
$ ktd --shell
k$ prove t/db_dependent/Koha/Biblio.t
=> SUCCESS: Tests pass!
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch:
- Adds a illrequests.deleted_biblio_id column
- Adjusts existing db_rev so people upgrading have the biblio_id value
moved to the also created column, before attempting to add the FK
constraint on the biblios table.
- Adds a new db_rev for those who unfortunately already updated, it
should be idempotent.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marcel de Rooy [Thu, 16 Mar 2023 10:01:07 +0000 (11:01 +0100)]
Bug 33242: Add unit test
Test plan:
Run t/db_dependent/Letters/TemplateToolkit.t
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Marcel de Rooy [Thu, 16 Mar 2023 08:53:20 +0000 (09:53 +0100)]
Bug 33242: Allow passing add_{duration} options to KohaDates
For example, if I want to add a few days to the issuedate in a
TT template, I could do this:
[% checkout.issuedate | $KohaDates add_days => 3 %]
This development allows you to pass add/subtract years, months, weeks,
days, hours, minutes and seconds.
Test plan:
Pick a notice like CHECKOUT.
Add a line like:
[% checkout.date_due | $KohaDates with_hours => 1, add_minutes => 15 %]
Do a checkout. Verify that the notice generated contains a time that
shifted 15 minutes.
Undo your change.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Matt Blenkinsop [Tue, 23 May 2023 16:24:30 +0000 (16:24 +0000)]
Bug 33813: Masthead lists button requires an aria-label
This patch adds an aria-label to the Lists button in the masthead. It is currently not descriptive enough and doesn't identify what is displayed when clicking the button.
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>
Pedro Amorim [Tue, 30 May 2023 09:20:20 +0000 (09:20 +0000)]
Bug 33786: ILL requests table id
Make sure requests table is unique when visiting patron ILL
history so the table state is not shared unintentionally
Reproduce:
1) Have a borrower with >20 ILL requests in their history
2) Visit cgi-bin/koha/members/ill-requests.pl?borrowernumber=<borrowernumber>
3) On the table, click page 2
4) Visit a different borrower with <20 ILL requests
5) Verify that no requests are shown, this is because the table is using page 2 from step 3)
6) Go back to original borrower, click table page 1
7) Now go back to 2nd borrower, verify is now showing page 1 correctly
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Lucas Gass [Thu, 1 Jun 2023 20:03:53 +0000 (20:03 +0000)]
Bug 33882: Add spans in dateofbirth column on member.tt
To test:
1 Apply patch
2 Do a patron search that will return multiple patrons.
3 Look at the date of birth column and notice the text is now wrapped in a class called 'dateofbirth'
4. Notice that the age hint is wrapped in a class called 'agehint'.
5. Add '.agehint { display: none }' to intranetusercss.
6. Now notice the date of birth still displays but no age information.
Signed-off-by: Sam Lau <samalau@gmail.com> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Owen Leonard [Fri, 2 Jun 2023 14:00:34 +0000 (14:00 +0000)]
Bug 33883: "Make sure to copy your API secret" message overlaps text
This patch updates the markup on the patron API keys page so that it
uses standard classes for dialogs and page sections.
To test you must have RESTOAuth2ClientCredentials enabled.
- Apply the patch and locate a patron record.
- From their checkout or detail page, choose More -> Manage API keys
- Click "Generate a new client id/secret pair"
- Enter a description and click Save.
- You should see a message in a standard message-style dialog, "Make
sure to copy your API secret now. You won’t be able to see it again!"
- The API key information should be displayed in a .page-section div.
- The table of existing keys should be displayed in a .page-section div.
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Owen Leonard [Wed, 31 May 2023 17:51:46 +0000 (17:51 +0000)]
Bug 33891: Use template wrapper for tabs: OPAC advanced search
This patch adds the tab WRAPPER markup to the OPAC, adapted for the
Bootstrap version used by the OPAC (4.5.0). The advanced search page is
updated to use the wrapper construction.
Unrelated markup fix: an empty size attribute is removed from an
<input>.
To test, apply the patch and view the the advanced search page in the
OPAC. The tabs for item type, shelving location, and collection should
all look correct and work correctly.
In the staff interface, go to Administration -> System preferences ->
OpacAdvancedSearchTypes and try various configurations, confirming each
time that the OPAC page adjustes correctly.
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 23 May 2023 08:58:55 +0000 (10:58 +0200)]
Bug 33803: Remove comment about tab width
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Owen Leonard [Tue, 23 May 2023 16:45:10 +0000 (16:45 +0000)]
Bug 33525: Use template wrapper for tabs: Basic MARC editor
This patch updates the basic MARC editor template to replace tab markup
with the use of WRAPPERs. Some CSS and JS has been modified in order to
make the custom style and behavior of the tabs on this page work
correctly with standard Bootstrap tab markup.
To test, apply the patch and go to Cataloging -> New record.
- Confirm that the tabs look correct, with the same style they had
before the template change.
- The first tab ("0") should be selected by default.
- Confirm that tab-switching works correctly: The tab color should
change and the list of numbered tags in the menu just below should
change to match the section.
- Confirm that these tag number links still work correctly to jump you
down the page to the corresponding tag.
- Without filling in any mandatory fields, click the "Save" button.
- You should get an error message about missing mandatory fields.
- Clicking the "Go to field" link should take you to the correct tab
and the correct tag.
- Append a hash to the URL to pre-select a tab other than the first one,
e.g. "/cgi-bin/koha/cataloguing/addbiblio.pl#tab5XX_panel" The correct
tab should be selected upon page load.
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>
David Cook [Fri, 2 Jun 2023 02:13:01 +0000 (02:13 +0000)]
Bug 33884: Remove unused Koha::RDF code
This patch removes the unused Koha::RDF module
and its associated unit test.
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: Tomas Cohen Arazi <tomascohen@theke.io>
Test plan:
use git grep extensively and confirm that this patch removes all
occurrences of this feature.
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>
Lucas Gass [Fri, 19 May 2023 22:09:16 +0000 (22:09 +0000)]
Bug 33789: Return issue info. when adding a credit
To test:
1. Make sure MarkLostItemsAsReturned is set so a lost item will stay on a patrons account after being marked as lost.
2. Check an item out to a patron, make sure it has a replacementprice
3. Mark the item as lost.
4. Now check the item in.
5. Go to the patrons account -> transaction tab. You should see 2 accountlines related to the item.
6. For the account type 'Lost item' you will see issue infomation ( check out date, due date, checkouted out from, etc )
7. For the account type 'Lost item fee refund' there is no issue information.
8. Apply patch
9. Try 2 - 6 again. This time the 'Lost item fee refund' should include issue information.
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Nick Clemens [Fri, 10 Mar 2023 16:14:50 +0000 (16:14 +0000)]
Bug 33493: Add a filter relationship for branchtransfers
Prefetching is useful, but we don't want to fetch all the inactive
transfers for an item. This patch adds a filtered relationship and
updates get_transfer(s) to use this
To test:
prove -v t/db_dependent/Koha/Item.t
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>
Owen Leonard [Thu, 25 May 2023 13:48:34 +0000 (13:48 +0000)]
Bug 33779: Terminology: biblio record
This patch corrects a string in the staff interface's ILL requests
template. "This item cannot be issued as it has no biblio record
associated with it" is updated to read "This item cannot be checked out
as it has no bibliographic record associated with it."
I don't know how to trigger the error message in the interface, but the
change is simple enough that it could be verified by examining the
patch.
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>
Nick Clemens [Fri, 7 Apr 2023 18:50:25 +0000 (18:50 +0000)]
Bug 33411: Don't count related guarantees fees against NoIssuesChargeGuarantees
To test:
1 - Find an adult patron in Koha
2 - Add two guarantees
3 - Add $1 fine to parent, $5 fine to each guarantee
4 - Set no issues charge guarantees to 9
5 - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -m patron_information --patron BARCODE
6 - Note the 64 message starts with Y's that mean patron is blocked
7 - Repeat with each child barcode
8 - They are blocked?
9 - Apply patch, restart all (restart_all will restart SIP)
10 - Try again
11 - Parent blocked, children should not be
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>
Nick Clemens [Fri, 7 Apr 2023 18:49:41 +0000 (18:49 +0000)]
Bug 33411: Unit test update
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>
Jonathan Druart [Thu, 11 May 2023 11:48:50 +0000 (13:48 +0200)]
Bug 33247: Flag the authority pending deletion in the result list
When an authority is removed from the result list it is not removed from
the search engine yet.
This patch suggests to add a note in the summary column to tell the user
that the deletion is pending.
Test plan:
1 - Go to authorities home and perform a search;
2 - Delete any authority;
3 - After the confirmation, the page is refreshed but still contains the
deleted authority, with a red note explaining that the deletion is
pending.
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>
Lucas Gass [Thu, 25 May 2023 22:04:08 +0000 (22:04 +0000)]
Bug 33748: Fix UI issue when importing records from a staged MARC file
This patch attempts to fix a UI issue on addorderiso2709.tt. It removes the <td> which contains the actoin buttons MARC, Card, and Add Order and adds them to the title line. This is so there is more space for the fieldsets.
1. Apply patch
2. Set MarcItemFieldsToOrder like this:
3. Stage a MARC file where the bibs have items attached
4. From acquisitions create a new basket and add 'From a staged file'.
5. Add the staged files to a basket.
6. Make sure the display looks correct.
7. Expand the data by clicking on the checkbox on the left hand side, or by clicking 'Select all'.
8. Make sure the display looks correct.
9. Tab over to 'Item informtion' and make sure that display looks correct.
10. Shrink the screen size down to less that 992px, ensuring the display remains correct.
Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Owen Leonard [Tue, 30 May 2023 10:51:16 +0000 (10:51 +0000)]
Bug 33859: Use the phrase 'Identity providers' instead of 'Authentication providers'
This patch updates instances in the code and templates where the term
"Authentication providers" is used, replacing it with the preferred
"Identity provider."
Most of the instances of this change are in module or API documentation,
but you can see a couple of the changes in the interface:
- Administration -> Identity providers:
- The sidebar menu should show "Identity providers" instead of
"Authentication providers."
- Patrons -> Patron details -> More -> Set permissions
- Under " Manage Koha system settings (Administration panel)" you
should see "Manage identity providers (manage_identity_providers)"
Signed-off-by: Sam Lau <samalau@gmail.com> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Fridolin Somers [Wed, 31 May 2023 20:58:45 +0000 (10:58 -1000)]
Bug 33875: Fix missing closing tag a in API key management page
In API key management page, anchor closing tag is missing in message "No keys defined for the current patron".
This patch fixes that.
Also changes display with link on a new line.
Translatable text is on purpose surrounded by span or div.
Test plan :
1) Enable system preference RESTOAuth2ClientCredentials
2) Go to a patron page
3) Click More > Manage API Keys
4) Look at page source HTML code
=> Check code is OK
Signed-off-by: Sam Lau <samalau@gmail.com> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 1 Jun 2023 06:29:53 +0000 (08:29 +0200)]
Bug 33865: (bug 27421 follow-up) Remove leftover
Bug 27421 replaced the progress bar with job_progress.inc.
The code related to the old progress bar has not been removed however.
Moreover there was a JS error in the console:
"Uncaught ReferenceError: submitBackgroundJob is not defined"
Test plan:
Stage a MARC record for import
Import it
Revert the import
All should work correctly, without JS error in the console and with the
progress bar displayed nicely during the staging step.
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>
Marcel de Rooy [Thu, 1 Jun 2023 08:27:35 +0000 (08:27 +0000)]
Bug 33877: Fix some entries in teams.yaml
Trivial edit.
Remove versions from the name of the packaging manager.
As also commented on BZ:
The script only expects to find a name here, not a version too.
See also maintainer role and how versions are handled there.
In this case I dont think it is really needed to still add that
distinction when we had two packaging managers in the past.
Test plan:
Look again at about.pl, Koha team, Koha development team.
Look at Mason James.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Mason James [Thu, 1 Jun 2023 12:49:27 +0000 (00:49 +1200)]
Bug 33371: Add [Install] section to koha-common.service
to test:
1/ install pkg, reboot, note service is not 'active'
2/ add patch, build package
3/ install pkg, reboot, note service is 'active' :)
root@deb11:/etc# systemctl status koha-common
* koha-common.service - Start required services for each Koha instance
Loaded: loaded (/etc/init.d/koha-common; enabled; vendor preset: enabled) <<<<
Active: active (exited) since Thu 2023-06-01 12:45:08 UTC; 13min ago
Tasks: 0 (limit: 2244)
Memory: 0B
CPU: 0
CGroup: /system.slice/koha-common.service
Jun 01 12:45:08 deb11 systemd[1]: Starting Start required services for each Koha instance...
Signed-off-by: Andrew Nugged <nugged@gmail.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Bug 33864: Trigger the 'change' event when setting quantity
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Andrew Nugged <nugged@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Andrew Nugged <nugged@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch corrects the behavior of the 'Confirm' button on the three
possible scenarios regarding item creation.
Ordering:
- 'Confirm' disabled, only gets enabled if quantity > 0
Receiving:
- Quantity gets locked (only changeable when creating items)
- 'Confirm' disabled, only gets enabled if quantity > 0
Cataloguing:
- It now defaults to 1
- 'Confirm' enabled by default (because of 1) if quantity is set to 0,
it gets disabled.
To test:
1. Verify the described behavior with the sample orders for the previous
patch.
=> SUCCESS: It does the job!
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Andrew Nugged <nugged@gmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Bug 33864: Set default date in all acqcreateitem scenarios
On b0aab2aeef9a025d3907d0b723b5ea71eaf94542 the flatpickr default to
'today' was restored, but only for acqcreateitem='ordering'. This patch
moves the initialization to a different stop for broader reach.
To test:
1. Have 3 baskets on with each setting:
- create_item = 'cateloguing'
- create_item = 'ordering'
- create_item = 'receiving'
2. Close those baskets
3. Go to 'Receive shipments'
4. Choose things from the 3 baskets and then 'Receive selected'
5. Navigate through the different orders
=> FAIL: Only the one that has items created on ordering has the date
filled by default
6. Apply this patch
7. Reload the page
8. Repeat 5
=> SUCCESS: Dates are pre-filled!
9. Sign off :-D
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Andrew Nugged <nugged@gmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Bug 33783: Make sure the value is populated on load time
The original patch makes the form set the right values in the order row
(before storing it) but misses to load the right value on page load,
which is still a regression. This patch solves that.
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Nick Clemens [Fri, 26 May 2023 12:50:41 +0000 (12:50 +0000)]
Bug 33783: (bug 8179 follow-up) Populate actual cost with ecost during receiving if not set
This restores behavior prior to 8179 to use the estimated cost when receiving if the
actual cost is not set.
We set the unitprice in the table row so that it will be used when editing and will be saved even if not adjusted
To test:
1 - Add some orders to a basket, do not set actual cost field
2 - Close basket, receive orders
3 - Note actual cost field is blank
4 - Cancel receipt
5 - Apply patch
6 - Receive again
7 - Note actual cost is populated
8 - Complete receipt and confirm actual cost correctly saved
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Kyle M Hall [Thu, 25 May 2023 16:57:24 +0000 (12:57 -0400)]
Bug 33838: Don't reset the renewal count
I cannot find any justification for this line existing.
MarkIssueReturned does not do this.
Resetting item's renewal count was introduced in bug 5877 with no explanation.
Test Plan:
1) Check out item 3999900000001 to a patron
2) Upload the KOC file attached to this bug report
3) Navigate the Pending Offline Circ actions, see your return is listed
4) Click the checkbox to select your return
5) Click Process once. Nothing appears to happen
6) In a new tab, pull up the bib for item 3999900000001, see that it has been checked in
7) Back on your Offline Circ tab, click Process a second time
8) Koha tells you the item is not checked out
9) Apply this patch, restart all the things!
10) Repeat steps 1-4, everything should now work!
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Edit: this line was introduced by bug 30275, by mistake. The
renewals_count attribute belongs to the `issues` table, and I agree it
shouldn't be set to 0 at all as it will (with no reason) make us loose
the value!
Tests pass with and without this change, so this isn't even tested. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Nick Clemens [Fri, 26 May 2023 14:44:05 +0000 (14:44 +0000)]
Bug 33788: Limit the number of old issues rows returned
This patch updates the parameter from 'limit' to 'rows'
To test:
1 - Checkout an item to 5 different people
2 - View item details on items tab of record
3 - Note you see last borrower, and three previous borrowers
4 - Apply patch, restart all
5 - Refresh page
6 - You shoulw now only see last borrower and 2 previous borrowers
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Lucas Gass [Wed, 24 May 2023 15:13:12 +0000 (15:13 +0000)]
Bug 33821: Allow direct input of dates on the OPAC
To test:
1. Apply patch
2. Go to OPAC self registration and try to manually enter the date for date of birth.
3. You can do so sucessfully
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>
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: Tomas Cohen Arazi <tomascohen@theke.io>
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: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 25 May 2023 13:07:25 +0000 (15:07 +0200)]
Bug 33829: Fix add patron to patron list if PatronAutoComplete is off
When adding patrons to a patron list we get a JS error about undefined
variables. We can easily fix this problem by defining them even if the
pref is not set.
We are enabling the auto complete even if PatronAutoComplete if off.
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Wed, 24 May 2023 07:29:30 +0000 (09:29 +0200)]
Bug 33815: Do not explode if logged in user modify their own userid
If the logged in librarian modifies their own userid they will get the
following error when submitting the form:
Can't call method "password_expired" on an undefined value at /kohadevbox/koha/C4/Auth.pm line 1780
We could handle this situation and flag the session as expired. Better
would be to deal with this specific user case and update the cookie (?)
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Bug 33834: Fix random failure on api/v1/ill_requests.t
This patch makes the GET request results more deterministic so we avoid
random failures. It does so by adding a fixed value to each ILL request
and then sorting by it.
To test:
1. Run:
$ DB_IMAGE=mysqli:8.0 ktd up -d
# wait until it finished:
$ ktd --logs
2. Run:
$ ktd --shell
k$ prove t/db_dependent/api/v1/ill_requests.t
(repeat a few times)
=> FAIL: It sometimes fails
3. Apply this patch
4. Repeat 2
=> SUCCESS: It doesn't fail
5. Sign off :-D
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Kyle M Hall [Thu, 11 May 2023 14:43:39 +0000 (14:43 +0000)]
Bug 33362: Allow return claims to be resolved even if the issue has since been delete from the database
Test Plan:
1) Check out an item
2) Claim return on it, moving it to the old_issues table
3) Delete the old_issue via koha-mysql or Use cleanup_database.pl
4) Attempt to resolve the claim
5) Note the error
6) Apply this patch set
7) Restart all the things!
8) Attempt to resolve the claim
9) No errors!
Signed-off-by: Sam Lau <samalau@gmail.com> Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Aleisha Amohia [Tue, 23 May 2023 03:32:59 +0000 (03:32 +0000)]
Bug 26611: Make authority record matching use required match checks
This patch fixes record matching for authorities to correctly apply required match checks.
To test:
1) Create a record matching rule:
Threshold: 100
Record type: Authority record
Match point 1
Search index: subject-topical
Score: 100
Tag: 150
Subfields: a
Match check 1
Both source and target record check fields:
Tag: 040
Subfields: a
This rule says we want to match on the topical term heading, then confirm the match with 040$a.
2) Create two topical term authority records
Authority 1:
150$a: Test
040$a: A
Authority 2:
150$a: Test
040$a: B
3) Export authority 2 and save
4) Go to Cataloging -> Stage records for import
5) Upload your downloaded authority 2 file. Change the record type to Authority. Choose your new record matching rule.
6) Stage for import.
7) Confirm that with the record matching rule applied, both authorities 1 and 2 show as possible matches, even though only authority 2 has a matching 040$a.
8) Apply the patch and restart services
9) Change the matching rule to "Do not look for matching records" and apply. This is to essentially refresh the page.
10) Change the matching rule to your new matching rule and apply. Confirm only the matching authority 2 shows and is selected.
Sponsored-by: Waikato Institute of Technology 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>
This patch makes dismissing the modal equivalent to cancelling the
receipt and thus returning to parcel.pl.
The 'Save' button is renamed to 'Confirm' and is disabled when no items
are selected for receiving.
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>
Jonathan Druart [Tue, 23 May 2023 08:02:39 +0000 (10:02 +0200)]
Bug 33784: Don't display the multi receive form for single receive
With bug 8179, a new step was added when receiving a single item.
This extra step is not useful and adds clicks for the staff member who is receiving orders.
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>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> 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>