]> git.koha-community.org Git - koha.git/log
koha.git
6 months agoBug 35979: Check pref before inserting holds_queue background jobs
Marcel de Rooy [Tue, 23 Apr 2024 11:42:50 +0000 (13:42 +0200)]
Bug 35979: Check pref before inserting holds_queue background jobs

Test plan:
Confirm that modrequest does no longer insert when pref is off :)

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36592: Fix default display lenght and default sort
Lucas Gass [Fri, 12 Apr 2024 12:02:46 +0000 (12:02 +0000)]
Bug 36592: Fix default display lenght and default sort

To test:
1. Go to Admin > Table settings
2. Find a table that includes Default display length or Default sort
   order.
3. Try to save a new value.
4. When the page reloads the new values have not been saved.
5. APPLY PATCH
6. Try 1 -3 again, this time the value should save correctly.
7. Go to Admin > Table settings and make sure the accordians still work
   and the in page links in each section still work.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36649: Correctly embed biblio when retrieving items when adding to a train
Jonathan Druart [Mon, 22 Apr 2024 12:33:33 +0000 (14:33 +0200)]
Bug 36649: Correctly embed biblio when retrieving items when adding to a train

I didn't find when this regression has been introduced but the third
parameter here is the headers, not parameters, we should not repeat
"headers".

Test plan:
1. Add a new processing that contains columns from the database, for example biblio.title and biblio.author.
2. Create a new train.
3. Add items to the waiting list.
4. Click on "Add last x items to the train" button.
5. Choose the train you created on number 2.
6. Choose the processing you added on number 1.
7. Try to click the Submit button.
=> Without the patch nothing happens and there is a JS error in the
console: Uncaught TypeError: item.biblio is undefined
=> With this patch applied the item is correctly added to the train and
the attribute is properly populated.

Signed-off-by: Anneli Österman <anneli.osterman@koha-suomi.fi>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32695: Fix search strings for 775, 780, 785 and 787
Nick Clemens [Fri, 26 May 2023 19:00:13 +0000 (19:00 +0000)]
Bug 32695: Fix search strings for 775, 780, 785 and 787

In the past due to some misunderstanding of the MARC standard
we built the search links for these fields using $a and $t with
the title index. But we actually need to search $t as title
and $a as author.
This patch fixes the templates for the MARC 7xx fields:
* 775
* 780
* 785
* 787

To test:
* Ensure systme preference 'UseControlNumber' is set to don't
* Create a record with the linking fields above
* Look at the OPAC and staff interface detail views
* Verify the content of your fields shows and the links combine a+t as a title search
* Apply patch
* Verify you have nicely formatted links now

Example:
775 _ _ ‡asomeone‡ttitle775
780 0 2 ‡asomeone‡ttitle780
785 0 2 ‡asomeone‡ttitle785
787 _ _ ‡ilabel:‡ttitle787‡asomeone

Signed-off-by: Sabrina Kiehl <kiehl@mpis.mpg.de>
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>
6 months agoBug 36652: Pass copy_form template variable
Lucas Gass [Fri, 19 Apr 2024 17:22:15 +0000 (17:22 +0000)]
Bug 36652: Pass copy_form template variable

To test:

1. Go to Tools > Notices and slips
2. Pick any notice and try to copy it to another library using the 'Copy notice' column.
3. You are redirected to a blank screen and if you go back to the Notices and slips page the notice has not been copied.
4. APPLY PATCH
5. Try steps 1 - 3 again, but this time you should be correctly directed.

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36639: Fix delete on authorities detail
Marcel de Rooy [Thu, 18 Apr 2024 09:43:19 +0000 (09:43 +0000)]
Bug 36639: Fix delete on authorities detail

Test plan:
Verify that you can delete an authority from detail page again.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 30318: Don't reset messaging preferences when form is empty
Nick Clemens [Fri, 19 Apr 2024 12:29:31 +0000 (12:29 +0000)]
Bug 30318: Don't reset messaging preferences when form is empty

In testing, the messaging preferences are set in the form when EnhancedMessagingPreferences is enabled.
Switching categories silently updates the preferences unless you have made changes, in which case the
user is warned and can confirm if they want to reset or not. The code only applies to patron creatoin, and
does not seem to be taken into account during OPAC self-registration.

It seems the silent defaulting when saving can be removed in favor of the current updates/warns in the actual
form.

To test:
 1 - Set some messaging preferences for at least two categories
 2 - Enter a new patron
 3 - Confirm switching categories correctly defaults the messaging preferences
 4 - Edit the preferences and switch to another category with defaults
 5 - Confirm the warning appears, and preferences are set if confirmed and ignored if not
 6 - Set to a category with defaults, uncheck all, and save
 7 - Ooof, patron is defaulted
 8 - Apply patch
 9 - Repeat 1-5 and confirm nothing has changed
10 - Set to a category with defaults, uncheck all, save
11 - Confirm patron is saved with no preferences

Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36111: fixed extra space
Matthias Le Gac [Mon, 22 Apr 2024 17:10:50 +0000 (13:10 -0400)]
Bug 36111: fixed extra space

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>
6 months agoBug 36111: 856$h should not appear as a link in detailed record
Matthias Le Gac [Fri, 5 Apr 2024 13:17:16 +0000 (09:17 -0400)]
Bug 36111: 856$h should not appear as a link in detailed record

Test plan:
1. Add 856$h to MARC editor
   1.1. Go to Administration > MARC bibliographic frameworks
   1.2. Next to Default framework, click Actions > MARC structure
   1.3. Search for field 856
   1.4. Click Actions > Edit subfields
   1.5. Click h
   1.6. Check the Editor box
   1.7. Click Save changes
2. Catalog a new record with a random URL in 856$h
   2.1. Go to Cataloging
   2.2. Click New record
   2.3. Fill out the mandatory fields (000, 003, 005, 008, 040$c,
        245$a, 942$c)
   2.4. Go to tab 8 and enter a value in 856$h
   2.5. Click Save (No need to add an item)
3. Search for the title in the staff interface (a large enough
   search to have more than one result)
   --> Notice it says "Online resources: Click here to access online"
   3.1. Try to click the link
        --> Blank page
4. Access the detailed record in the staff interface
   --> Notice it says "Online resources: Click here to access online"
   4.1. Try to click the link
        --> Blank page
5. Search for the title in the opac (a large enough search to have
   more than one result)
   --> Notice it says "Online resources: Click here to access online"
   5.1. Try to click the link
        --> Blank page
6. Access the detailed record in the opac
   --> Notice it says "Online resources: Click here to access online"
   6.1. Try to click the link
        --> Blank page
7. Edit the item and add a text in field 856$y
8. Access the detailed record in the staff interface
   --> Notice it says what you put in 856$y field
9. Apply the patch
10. Replay steps 3 through 6, but this time, the "Online resources"
   field should not be present.
11. Replay steps 7 through 8, but this time, what you put in 856$y
   field should not be present.
12. Edit the item and add a url in field 856$u
13. Replay steps 3 through 6, but this time, clicking on the link
    should take you to the URL specified in the 856$u field.
14. Replay steps 7 through 8, but this time, what you put in 856$y
   field should be present and
   clicking on the link should take you to the URL specified in the 856$u field.

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
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>
6 months agoBug 36282: Chomp whitespace around opac i18n strings
Pedro Amorim [Fri, 8 Mar 2024 11:49:26 +0000 (11:49 +0000)]
Bug 36282: Chomp whitespace around opac i18n strings

Same logic as bug 26816 but to OPAC

Test plan:
1) Apply test plan patch only
2) Visit opac home:
<opac_url>/cgi-bin/koha/opac-main.pl
3) Notice there's a space between 'Translated string' and ':', even though the markup does not contain a whitespace
4) Apply 2nd patch
5) Notice the white space is gone

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36416: Fix cud-check_out
Pedro Amorim [Mon, 25 Mar 2024 13:23:36 +0000 (13:23 +0000)]
Bug 36416: Fix cud-check_out

1) Install FreeForm and enable ILLModule, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
2) Checkout to branch b_36243
cd /kohadevbox/koha/Koha/Illbackends/FreeForm
git checkout b_36243
3) Enable CirculateILL sys pref
4) Create a new ILL request, visit:
<staff_url>/cgi-bin/koha/ill/ill-requests.pl?method=create&backend=FreeForm
5) Set "type" = Book and enter '42' on the cardnumber input, click "Create"
6) On the top toolbar, click "Confirm" and confirm the following screen.
7) You now have a new option "Check out" on the toolbar. Click on it. Notice it explodes.
8) Apply patch. Repeat.

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>
6 months agoBug 36313: Fix Undefined subroutine &C4::Circulation::CheckReserves error
Emmi Takkinen [Thu, 11 Apr 2024 10:12:58 +0000 (13:12 +0300)]
Bug 36313: Fix Undefined subroutine &C4::Circulation::CheckReserves error

On (at least) git installations of Koha checkouts and checkins fail on
error 500. Logs have following error:

Undefined subroutine &C4::Circulation::CheckReserves called...

Error happens also when one tries to open patrons checkouts from detail page.
Koha doesn't die but table just keeps loading. Solution is to add C4::Reserves
before CheckReserves when it's called from Circulation.pm.

To test:
1. Apply this patch.
2. Try to check out and check in item.
=> Confirm both operations are succesfull.
3. Attempt to open patrons checkouts from patron detail and checkout page.
=> Table should load

Also prove t/db_dependent/Circulation.t.

Sponsored-by: Koha-Suomi Oy
Signed-off-by: BabaJaga <babajagawgoglach@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 30645: Add tests
Jonathan Druart [Thu, 28 Apr 2022 13:13:17 +0000 (15:13 +0200)]
Bug 30645: Add tests

to highlight the problem

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>
6 months agoBug 30645: Add REST/Plugin/Query tests
Pedro Amorim [Thu, 21 Dec 2023 16:06:41 +0000 (16:06 +0000)]
Bug 30645: Add REST/Plugin/Query tests

prove t/Koha/REST/Plugin/Query.t

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>
6 months agoBug 30645: Consider multiple instances of extended_attributes in query params
Pedro Amorim [Thu, 30 Nov 2023 16:43:02 +0000 (15:43 -0100)]
Bug 30645: Consider multiple instances of extended_attributes in query params

This will rewrite a query like:

{
    "-and":[
        [
            {
                "extended_attributes.value":{
                    "like":"abc%"
                },
                "extended_attributes.code":[
                    [
                        "arbitrary_attr_code",
                        "another_attr_code"
                    ]
                ]
            }
        ],
        [
            {
                "extended_attributes.value":{
                    "like":"123%"
                },
                "extended_attributes.code":[
                    [
                        "arbitrary_attr_code",
                        "another_attr_code"
                    ]
                ]
            }
        ]
    ]
}

To:

{
    "-and":[
        [
            {
                "extended_attributes.value":{
                    "like":"abc%"
                },
                "extended_attributes.code":[
                    [
                        "arbitrary_attr_code",
                        "another_attr_code"
                    ]
                ]
            }
        ],
        [
            {
                "extended_attributes_2.value":{
                    "like":"123%"
                },
                "extended_attributes_2.code":[
                    [
                        "arbitrary_attr_code",
                        "another_attr_code"
                    ]
                ]
            }
        ]
    ]
}

And it'll also add the number of required 'join' attributes to the query
attributes to match it.

Test plan (with Joubu's test patch applied), run:
prove t/db_dependent/selenium/patrons_search.t

Or

Test plan, k-t-d:
1) Create 2 patron attributes, visit:
/cgi-bin/koha/admin/patron-attr-types.pl
2) Name the first attribute 'test1' and the second attribute 'test2'
3) On both, tick the 'Searchable' and 'Search by default' checkboxes
4) Edit a koha borrower, example visit:
/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=51
5) Put '123' on the test1 attribute, and 'abc' on the test2 attribute
6) Visit the main patrons page:
/cgi-bin/koha/members/members-home.pl
7) On the first left side filter input called 'Search', type '123' and search. Notice you get the patron result
8) Repeat step 7, but type 'abc' instead of '123'. Notice you get the patron result
9) Now do the same search but type '123 abc'. Notice you do not get the patron result.
10) Apply patch. Repeat test plan. Notice you get the patron result in step 9).

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>
6 months agoBug 35568: (RM follow-up) Use warnings_exist over warning_like
Martin Renvoize [Wed, 24 Apr 2024 09:20:38 +0000 (10:20 +0100)]
Bug 35568: (RM follow-up) Use warnings_exist over warning_like

We introduced additional warnings triggered by prepared letter and those
caused the test of the recall hook to fail.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 36400: (RM follow-up) Add .prettierrc to Makefile
Martin Renvoize [Wed, 24 Apr 2024 09:13:13 +0000 (10:13 +0100)]
Bug 36400: (RM follow-up) Add .prettierrc to Makefile

Add the new .prettierrc file to Makefile.PL and set it to be ignored for
make.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 32132: (RM follow-up) Use testbuilder in Acquisitions.t
Martin Renvoize [Wed, 24 Apr 2024 09:08:28 +0000 (10:08 +0100)]
Bug 32132: (RM follow-up) Use testbuilder in Acquisitions.t

This patch adds a use of testbuilder to create a test fund as apposed to
using AddBudget which expects foreign keys to already exist.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 33960: (RM follow-up) Add class decorations to schema
Martin Renvoize [Wed, 24 Apr 2024 09:00:28 +0000 (10:00 +0100)]
Bug 33960: (RM follow-up) Add class decorations to schema

This patch adds the missing koha_objects_class and koha_object_class
definitions to Koha::Schema::Result::DeletedbiblioMetadata.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 35581: (RM follow-up) Add class decorations to schema
Martin Renvoize [Wed, 24 Apr 2024 08:56:06 +0000 (09:56 +0100)]
Bug 35581: (RM follow-up) Add class decorations to schema

This patch adds the missing koha_objects_class and koha_object_class
definitions to Koha::Schema::Result::Illcomment.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 32132: (RM follow-up) Merge supplimentary db update
Martin Renvoize [Tue, 23 Apr 2024 15:43:12 +0000 (16:43 +0100)]
Bug 32132: (RM follow-up) Merge supplimentary db update

This patch merges the logic from the supplimentary database update that
was requested into the original DB update revision making the update
more reliable.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 32132: Handle funds without budget_period_id gracefully
Emmi Takkinen [Tue, 23 Apr 2024 10:51:05 +0000 (13:51 +0300)]
Bug 32132: Handle funds without budget_period_id gracefully

Sponsored-by: Koha-Suomi Oy
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 32132: Fix failing tests
Emmi Takkinen [Mon, 22 Apr 2024 11:02:20 +0000 (14:02 +0300)]
Bug 32132: Fix failing tests

Some tests failed due changes made to aqbudgets.budget_period_id.
Tests failed with error:

DBIx::Class::Storage::DBI::_dbh_execute(): DBI Exception:
DBD::mysql::st execute failed: Field 'budget_period_id' doesn't
have a default value at...

This patch fixes those tests.

To test run following lines:
prove t/db_dependent/Acquisition/CancelReceipt.t
prove t/db_dependent/Acquisition/GetBasketAsCSV.t
prove t/db_dependent/Acquisition/GetBasketGroupAsCSV.t
prove t/db_dependent/Acquisition/GetBasketsInfosByBookseller.t
prove t/db_dependent/Acquisition/GetOrdersByBiblionumber.t
prove t/db_dependent/Acquisition/Invoices.t
prove t/db_dependent/Acquisition/NewOrder.t
prove t/db_dependent/Acquisition/OrderUsers.t
prove t/db_dependent/Acquisition/TransferOrder.t
prove t/db_dependent/Acquisition/close_reopen_basket.t
prove t/db_dependent/Koha/Acquisition/Funds.t
prove t/db_dependent/Letters.t

Sponsored-by: Koha-Suomi Oy
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
6 months agoBug 35345: Add --where option to rebuild_elasticsearch.pl
Thomas Klausner [Fri, 29 Mar 2024 09:20:37 +0000 (09:20 +0000)]
Bug 35345: Add --where option to rebuild_elasticsearch.pl

Sometimes we need to only re-index a subset of our bibliographic data or authorities. Currently this is only possible by enumerating all id (-bn or -ai), which does not work well when indexing eg 100.000 items of a 2.000.000 DB. Re-indexing everything is also overkill.

This patch adds an `--where` flag to misc/search_tools/rebuild_elasticsearch.pl which can take arbitrary SQL (that of course has to match the respective tables) and adds it as an additional param to the resultset to index

To test, start koha-testing-docker with ElasticSearch enabled, for example via `ktd --es7 up

Before applying the patch, rebuild_elasticsearch will index all data:

Biblios:
$ misc/search_tools/rebuild_elasticsearch.pl -b -v
[12387] Checking state of biblios index
[12387] Indexing biblios
[12387] Committing final records...
[12387] Total 435 records indexed
(there might be a waring regarding a broken biblio, which can be ignored)

Auth:
$ misc/search_tools/rebuild_elasticsearch.pl -a -v
[12546] Checking state of authorities index
[12546] Indexing authorities
[12546] 1000 records processed
[12546] Committing final records...
[12546] Total 1706 records indexed

Now apply the patch

Biblio, limit by range of biblioid:
$ misc/search_tools/rebuild_elasticsearch.pl -b -v --where "biblionumber between 100 and 150"
[12765] Checking state of biblios index
[12765] Indexing biblios
[12765] Committing final records...
[12765] Total 50 records indexed

Note that only 50 records where indexed (instead of the whole set of 435 records)

Auth, limit by authtypecode:
$ misc/search_tools/rebuild_elasticsearch.pl -a -v --where "authtypecode = 'GEOGR_NAME'"
[12848] Checking state of authorities index
[12848] Indexing authorities
[12848] Committing final records...
[12848] Total 142 records indexed

Again, only 142 have been indexed.

Sponsored-by: Steiermärkische Landesbibliothek
Sponsored-by: HKS3 / koha-support.eu
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 29825: (follow-up) Fix translatability and capitalization
Katrin Fischer [Mon, 22 Apr 2024 10:14:01 +0000 (10:14 +0000)]
Bug 29825: (follow-up) Fix translatability and capitalization

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 29825: (follow-up) Some style fixes and modal correction
Owen Leonard [Fri, 30 Jun 2023 19:48:04 +0000 (19:48 +0000)]
Bug 29825: (follow-up) Some style fixes and modal correction

This patch makes a few coding style changes to the new JavaScript and
updates the Bootstrap modal markup to be in line with current standards.

The previous patches lacked a trigger for the preview modal, so I added
that. Since the content of the modal uses spaces for formatting I added
monospace formatting to the modal body.

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 29825: Preview of authority record on edit mode as MARC formatted view
George Veranis [Fri, 2 Sep 2022 20:30:45 +0000 (22:30 +0200)]
Bug 29825: Preview of authority record on edit mode as MARC formatted view

This bug adds a new functionality on Edit mode of a new or existing authority.
Add a new button 'MARC Preview' in order librarian have the ability to preview
the record on MARC plain structure mode and have all fields and subfields
that entered before save/update the record.

To test:
1. Open or add an authority
2. The preview button isn't on toolbar
3. Apply the patch
4. Do step 1
5. The preview button exists
6. Do some changes or not to the authority record
7. Click to Preview MARC button and a modal window will appear with all fields
   indicators and subfields that filled in the form of cataloguing.

Mentored by: Andreas Roussos

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: About script: Process only the tab being queried
Pedro Amorim [Thu, 15 Feb 2024 14:36:04 +0000 (13:36 -0100)]
Bug 32693: About script: Process only the tab being queried

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: Preparation: About script: versions
Pedro Amorim [Thu, 15 Feb 2024 14:33:37 +0000 (13:33 -0100)]
Bug 32693: Preparation: About script: versions

versions is being used in both 'team' and 'about' tabs, needs to be
moved

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: Preparation: About script: Move template params
Pedro Amorim [Thu, 15 Feb 2024 14:32:33 +0000 (13:32 -0100)]
Bug 32693: Preparation: About script: Move template params

These template params are only used in the default first 'about' tab but were being added further down in the script

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: Preparation: About script: docdir
Pedro Amorim [Thu, 15 Feb 2024 14:27:50 +0000 (13:27 -0100)]
Bug 32693: Preparation: About script: docdir

docdir is used in both team + history tabs
was previously being loaded in team and additionally used in history
but because now we're only loading one tab at a time, we need to move this

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: Update tab_panels
Pedro Amorim [Thu, 15 Feb 2024 14:15:09 +0000 (13:15 -0100)]
Bug 32693: Update tab_panels

Each tab panel's content has now been moved to its own BLOCK.
Each tab panel's content is now only loaded if said tab is the one being viewed

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: Update tab_items
Pedro Amorim [Thu, 15 Feb 2024 14:13:12 +0000 (13:13 -0100)]
Bug 32693: Update tab_items

tab_items are now linktabs
tab_items are now styled active depending if the URL param 'tab' matches the tab name or not

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 32693: Update tab_item html helper
Pedro Amorim [Thu, 15 Feb 2024 13:42:04 +0000 (12:42 -0100)]
Bug 32693: Update tab_item html helper

tab_item html helper now allows for a boolean tablink option to set if the the tab item is a link or not

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36328: (QA follow-up) Expand tests and reorder elements to clarify differences
Nick Clemens [Mon, 1 Apr 2024 16:03:37 +0000 (16:03 +0000)]
Bug 36328: (QA follow-up) Expand tests and reorder elements to clarify differences

Also tidy

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36328: Add a separate 'note' profile
Jonathan Druart [Wed, 20 Mar 2024 07:34:09 +0000 (08:34 +0100)]
Bug 36328: Add a separate 'note' profile

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36328: Add test
Jonathan Druart [Fri, 15 Mar 2024 10:40:57 +0000 (11:40 +0100)]
Bug 36328: Add test

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36328: Add p span div to Scrubber
Jonathan Druart [Fri, 15 Mar 2024 10:39:33 +0000 (11:39 +0100)]
Bug 36328: Add p span div to Scrubber

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 22567: Add transfer details to stockrotation page
Martin Renvoize [Thu, 4 Jan 2024 16:42:01 +0000 (16:42 +0000)]
Bug 22567: Add transfer details to stockrotation page

This patch adds any pending/current transfer details into the
stockrotation item management page.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33960: Unit tests
Nick Clemens [Tue, 19 Dec 2023 13:29:36 +0000 (13:29 +0000)]
Bug 33960: Unit tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33960: Add routes and controller
Nick Clemens [Fri, 15 Dec 2023 16:56:11 +0000 (16:56 +0000)]
Bug 33960: Add routes and controller

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33960: Add api mapping and biblioitems to Old::Biblios to match Biblio
Nick Clemens [Thu, 7 Sep 2023 16:27:07 +0000 (16:27 +0000)]
Bug 33960: Add api mapping and biblioitems to Old::Biblios to match Biblio

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33960: Add objects and update schema
Nick Clemens [Thu, 8 Jun 2023 13:57:35 +0000 (13:57 +0000)]
Bug 33960: Add objects and update schema

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35364: Update serials pop-up windows with consistent footer markup
Owen Leonard [Fri, 17 Nov 2023 18:44:46 +0000 (18:44 +0000)]
Bug 35364: Update serials pop-up windows with consistent footer markup

This patch updates several serials module templates in order to style
submission and close buttons in a fixed footer at the bottom of pop-up
windows, with markup consistent with other pop-up windows.

Unrelated change: A couple of templates have had a "page-section" div
added where it was missing.

To test, apply the patch and go to Serials. For each affected template,
test that the window looks correct and the buttons in the footer work
correctly:

- New subscription ->
  - Search for a vendor:
    - Vendor search form
      - Vendor search results
  - Search for record
    - Record search form
    - Record search results
- Complete the process of creating a subscription if there are no other
  subscriptions already in your database.
  - From the subscription detail page, click the "Renew" button in the
    toolbar and test that window.
  - From the subscription detail page, click the "Create routing list"
    link in the left-hand sidebar menu.
    - Add one or more recipients and click "Save"
    - Click "Save and preview routing slip" and test the resulting
     pop-up.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36265: Bigger font-size for headers in staff interface
Fridolin Somers [Thu, 7 Mar 2024 09:31:28 +0000 (10:31 +0100)]
Bug 36265: Bigger font-size for headers in staff interface

In staff interface, text in nav bar and search header are at normal
size. Since these are used a lot, I propose to increase font-size at
110%.

Test by applying patch and rebuild CSS to see bigger text in staff
interface

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Fix failing t/db_dependent/Koha/ILL/Request.t
Katrin Fischer [Mon, 22 Apr 2024 06:56:23 +0000 (06:56 +0000)]
Bug 35581: Fix failing t/db_dependent/Koha/ILL/Request.t

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: POD fixes
Tomas Cohen Arazi [Mon, 25 Mar 2024 13:21:27 +0000 (10:21 -0300)]
Bug 35581: POD fixes

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: (follow-up) Remove internal use of ->illrequestattributes
Tomas Cohen Arazi [Mon, 25 Mar 2024 13:08:18 +0000 (10:08 -0300)]
Bug 35581: (follow-up) Remove internal use of ->illrequestattributes

By now, we shouldn't be using the deprecated method internally.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Cleanup Comments.t
Tomas Cohen Arazi [Mon, 25 Mar 2024 12:59:44 +0000 (09:59 -0300)]
Bug 35581: Cleanup Comments.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::REST::V1::Illrequests -> Koha::REST::V1::ILL::Requests
Pedro Amorim [Mon, 8 Jan 2024 12:03:42 +0000 (12:03 +0000)]
Bug 35581: Koha::REST::V1::Illrequests -> Koha::REST::V1::ILL::Requests

Test plan:
1. Apply patch
2. Make sure tests pass, run:
    prove t/db_dependent/api/v1/ill_*

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illrequest -> Koha::ILL::Request
Pedro Amorim [Fri, 15 Dec 2023 10:07:11 +0000 (10:07 +0000)]
Bug 35581: Koha::Illrequest -> Koha::ILL::Request

Koha/Illrequests.pm -> Koha/ILL/Requests.pm

Merged:
t/db_dependent/Koha/Illrequests.t
t/db_dependent/Illrequests.t

Into:
t/db_dependent/Koha/ILL/Requests.t

ILL classes file structure is, for the most part, around 7 years old and doesn't follow a strict logic. It's so confusing that some test files exist redundantly.

This housekeeping should help future work in regards to ISO18626 to add Koha as a supplying agency instead of just requesting agency, as is now.
It should also help future housekeeping of moving backend related logic out of the Illrequest.pm into Illbackend.pm (now ILL/Request.pm and ILL/Backend.pm as of this patchset).
It should also help in structuring the addition of a master generic form (see bug 35570)

This patchset will require existing backends to be updated to match the new class names and structure, if they invoke them.

Test plan, k-t-d, run tests:
prove t/db_dependent/api/v1/ill_*
prove t/db_dependent/Koha/ILL/*

Test plan, k-t-d, manual:
1) Install FreeForm, enable ILL module, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
2) You'll have to switch the FreeForm repo to the one compatible with this work, like:
cd /kohadevbox/koha/Koha/Illbackends/FreeForm
git checkout reorganize_ILL
3) Do some generic ILL testing:
3.1) Create a request
3.2) Add a comment to a request
3.3) Edit a request
3.4) Edit a request's item metadata
3.5) Confirm a request
3.6) List requests
3.7) Filter requests list using left side filters
4) Install a metadata enrichment plugin:
https://github.com/PTFS-Europe/koha-plugin-api-pubmed
4.1) Create an ILL batch and insert a pubmedid like 123
4.2) Add the request and finish batch
5) Verify all of the above works as expected

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illrequest::SupplierUpdate* -> Koha::ILL::Request::SupplierUpdate*
Pedro Amorim [Thu, 14 Dec 2023 17:24:50 +0000 (17:24 +0000)]
Bug 35581: Koha::Illrequest::SupplierUpdate* -> Koha::ILL::Request::SupplierUpdate*

Koha/Illrequest/SupplierUpdate.pm -> Koha/ILL/Request/SupplierUpdate.pm
Koha/Illrequest/SupplierUpdateProcessor.pm -> Koha/ILL/Request/SupplierUpdateProcessor.pm

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illrequest::Logger -> Koha::ILL::Request::Logger
Pedro Amorim [Thu, 14 Dec 2023 17:07:23 +0000 (17:07 +0000)]
Bug 35581: Koha::Illrequest::Logger -> Koha::ILL::Request::Logger

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illrequest::Config -> Koha::ILL::Request::Config
Pedro Amorim [Thu, 14 Dec 2023 16:32:56 +0000 (15:32 -0100)]
Bug 35581: Koha::Illrequest::Config -> Koha::ILL::Request::Config

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illrequest::Workflow* -> Koha::ILL::Request::Workflow*
Pedro Amorim [Thu, 14 Dec 2023 16:20:48 +0000 (15:20 -0100)]
Bug 35581: Koha::Illrequest::Workflow* -> Koha::ILL::Request::Workflow*

Koha/Illrequest/Workflow.pm -> Koha/ILL/Request/Workflow.pm
Koha/Illrequest/Workflow/Availability.pm -> Koha/ILL/Request/Workflow/Availability.pm
Koha/Illrequest/Workflow/TypeDisclaimer.pm -> Koha/ILL/Request/Workflow/TypeDisclaimer.pm

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illrequestattribute* -> Koha::ILL::Request::Attribute*
Pedro Amorim [Thu, 14 Dec 2023 16:02:05 +0000 (15:02 -0100)]
Bug 35581: Koha::Illrequestattribute* -> Koha::ILL::Request::Attribute*

Koha/Illrequestattribute.pm -> Koha/ILL/Request/Attribute.pm
Koha/Illrequestattributes.pm -> Koha/ILL/Request/Attributes.pm

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illcomment* -> Koha::ILL::Comment*
Pedro Amorim [Thu, 14 Dec 2023 15:41:07 +0000 (14:41 -0100)]
Bug 35581: Koha::Illcomment* -> Koha::ILL::Comment*

Koha/Illcomment.pm -> Koha/ILL/Comment.pm
Koha/Illcomments.pm -> Koha/ILL/Comments.pm

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Illbatchstatus* -> ILL::Batch::Status*
Pedro Amorim [Thu, 14 Dec 2023 15:08:20 +0000 (15:08 +0000)]
Bug 35581: Illbatchstatus* -> ILL::Batch::Status*

Koha/IllbatchStatus.pm -> Koha/ILL/Batch/Status.pm
Koha/IllbatchStatuses.pm -> Koha/ILL/Batch/Statuses.pm
Koha/REST/V1/IllbatchStatuses.pm -> Koha/REST/V1/ILL/Batch/Statuses.pm

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::*Illbatch* -> Koha::*ILL::*Batch*
Pedro Amorim [Thu, 14 Dec 2023 14:46:11 +0000 (14:46 +0000)]
Bug 35581: Koha::*Illbatch* -> Koha::*ILL::*Batch*

Koha/Illbatch.pm -> Koha/ILL/Batch.pm
Koha/Illbatches.pm -> Koha/ILL/Batches.pm
Koha/REST/V1/Illbatches.pm -> Koha/REST/V1/ILL/Batches.pm
t/db_dependent/Koha/Illbatch.t -> t/db_dependent/Koha/ILL/Batch.t
t/db_dependent/Illbatches.t -> t/db_dependent/Koha/ILL/Batches.t

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35581: Koha::Illbackend -> Koha::ILL::Backend
Pedro Amorim [Thu, 14 Dec 2023 14:16:01 +0000 (14:16 +0000)]
Bug 35581: Koha::Illbackend -> Koha::ILL::Backend

Koha/Illbackend.pm -> Koha/ILL/Backend.pm
Koha/REST/V1/Illbackends.pm -> Koha/REST/V1/ILL/Backends.pm

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36400: (follow-up) remove option editorconfig from .prettierrc.js
Paul Derscheid [Mon, 25 Mar 2024 13:55:13 +0000 (14:55 +0100)]
Bug 36400: (follow-up) remove option editorconfig from .prettierrc.js

- The option doesn't seem do what it's intended for:
- The debug logs still show options from the .editorconfig (which is actually what we want in this case).
- The option causes unwanted warnings when using the cli.
- In summary: we have to keep in mind that the rules are now hierarchical:
1. .editorconfig
2. .prettierrc.js

Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36400: Centralize {js,ts,vue} formatting config in .prettierrc.js
Paul Derscheid [Fri, 22 Mar 2024 11:29:50 +0000 (12:29 +0100)]
Bug 36400: Centralize {js,ts,vue} formatting config in .prettierrc.js

    Let's centralize all formatting for js, ts and vue files in a .prettierrc.js.
    The goal here is to preserve eslint's linting but ignore all of its formatting options.

    Seems to work for vue files in vscode, vscodium and neovim w/ vscode-eslint-language-server.

    To test:
    1) Pick any vue file for example.
    2) Run format via your editor and either npx prettier -c .prettierrc.js <PATH_TO_VUE_FILE> [you can also use the -w flag to directly write].
    3) Look for unexpected changes: vue files should be already formatted w/ these inline flags (see: https://wiki.koha-community.org/wiki/Coding_Guidelines#JS14:_Prettier_JavaScript): [--trailing-comma es5, --arrow-parens avoid].
    4) Sign off if you're happy and comment or show what went wrong in a comment.

Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35363: Update transfer order pop-up window with consistent footer markup
Owen Leonard [Fri, 17 Nov 2023 17:42:33 +0000 (17:42 +0000)]
Bug 35363: Update transfer order pop-up window with consistent footer markup

This patch updates the "Transfer order" pop-up window so that it has a
fixed footer consistent with other similar pop-up windows.

In order to make navigation between pages within the pop-up window
easier I've added a button in the footer which can take the user back to
the previous step, including any necessary parameters.

To test, apply the patch and go to Acquisitions.

- Locate a vendor with a basket, and a basket with one or more orders.
- On the basket detail page, click the "Transfer" link in the "Modify"
  column.
- In the pop-up window, test each step:
  - Vendor search
  - Vendor selection
  - Basket selection
- Confirm that at any step you can use the new button to go back to the
  previous step.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35568: Add a transform_prepared_letter plugin hook to allow modification of notic...
Kyle M Hall [Thu, 14 Dec 2023 11:58:40 +0000 (11:58 +0000)]
Bug 35568: Add a transform_prepared_letter plugin hook to allow modification of notices created via GetPreparedLetter

A plugin hook for GetPreparedLetter would be very useful. It could be used to add universal headers and/or footers to messages, attach news, and modify notices in other ways in whole or in part. It could even be used for call webhooks when certain types of notices are sent.

For example, the MessageBee ( https://uniquelibrary.com/messagebee/ ) plugin for Koha generates YAML based notice content, which is then further processed by the before_send_messages hook. This process is unreliable due to the possible changes in data between the creation of the yaml and the reading of that yaml and transforming it into JSON with much more data. For example, the yaml may contain an issue_id, but that checkout may have been returned in the meantime. A hook like this would allow the MessageBee plugin to skip the yaml step and create the json data directly which is then sent to MessageBee for transmission to the patron.

Test Plan:
1) Apply this patch
2) prove t/db_dependent/Koha/Plugins/Transform_prepared_letter_hook.t
3) Download and install the Kitchen Sink plugin v2.4.0
   https://github.com/bywatersolutions/dev-koha-plugin-kitchen-sink/releases/tag/v2.4.0
4) Generate any notice or slip, such as a checkin or checkout notice
5) Note that all notices now end with "Thanks for using your local library!"

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>
6 months agoBug 35616: DBIC schema update
Katrin Fischer [Mon, 22 Apr 2024 06:55:34 +0000 (06:55 +0000)]
Bug 35616: DBIC schema update

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35616: DBRev 23.12.00.026
Katrin Fischer [Mon, 22 Apr 2024 06:55:24 +0000 (06:55 +0000)]
Bug 35616: DBRev 23.12.00.026

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35616: (QA follow-up): tidy up code and fix exec permission
Victor Grousset/tuxayo [Tue, 19 Mar 2024 01:21:06 +0000 (02:21 +0100)]
Bug 35616: (QA follow-up): tidy up code and fix exec permission

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35616: Update catalog concerns to set/filter on source
Martin Renvoize [Wed, 20 Dec 2023 14:52:10 +0000 (14:52 +0000)]
Bug 35616: Update catalog concerns to set/filter on source

This patch updates the catalog concerns feature to respect the new
'source' field in the API.  We both set the source for new ticket
submissions and use it for filtering in the corresponding display
tables.

To test:
1) Nothing should noticably change here.. follow the test plan for bug
   31028 and confirm all continues to work as described there.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35616: API specification update
Martin Renvoize [Wed, 20 Dec 2023 14:47:08 +0000 (14:47 +0000)]
Bug 35616: API specification update

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35616: Add source field to tickets table
Martin Renvoize [Wed, 20 Dec 2023 14:42:20 +0000 (14:42 +0000)]
Bug 35616: Add source field to tickets table

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36309: Make create_superlibrarian.pl output more useful
Tomas Cohen Arazi [Wed, 13 Mar 2024 17:56:27 +0000 (14:56 -0300)]
Bug 36309: Make create_superlibrarian.pl output more useful

In situations in which you are not familiar with all the Koha settings,
and table structure, the fact this script just fails telling there's a
broken FK is just not practical.

We should capture those exceptions and display a useful message instead.

This script does that. It adds some validations and some exception
handling too. It prints a nice message about the bad value the user
passed, and the valid values too!

To test:
1. Run this on a fresh KTD:
   $ ktd --shell
  k$ perl  misc/devel/create_superlibrarian.pl \
      --userid tcohen \
      --password tomasito \
      --cardnumber 123456789 \
      --categorycode POT \
      --branchcode ATO
=> FAIL: It explodes with a MySQL exception message!
2. Apply this patch
3. Repeat 1
=> SUCCESS: It tells you which value is wrong and what values you can
pick to make the command work
4. Pick a valid value, and repeat
=> SUCCESS: Now the other value is wrong, a nice message is displayed!
5. Fix with a valid value and repeat
=> SUCCESS: Patron created!
6. Sign off :-D

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36204: (follow-up) Add parenthesis to match display in other places
Katrin Fischer [Mon, 22 Apr 2024 06:54:59 +0000 (06:54 +0000)]
Bug 36204: (follow-up) Add parenthesis to match display in other places

Updated display to:
Acevedo, Henry (othername)

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36204: Add othernames field to PatronAutoComplete display
Lucas Gass [Fri, 19 Apr 2024 17:33:05 +0000 (17:33 +0000)]
Bug 36204: Add othernames field to PatronAutoComplete display

To test:
1. APPLY PATCH
2. Make sure PatronAutoComplete is on.
3. Find or add othernames to a patron record.
4. Search for that patron and make sure othernames properly displays in the dropdown.
5. Add a middle name to that patron and search again, make sure the display looks good.
6. Remove the othernames field and search again, make sure the display looks good.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35151: (follow-up) Remove ILLModuleCopyrightClearance from .pref file
Katrin Fischer [Mon, 22 Apr 2024 06:51:42 +0000 (06:51 +0000)]
Bug 35151: (follow-up) Remove ILLModuleCopyrightClearance from .pref file

Previous patches removed the preference from the database and sysprefs.sql,
but the yaml file was missed.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33393: DBRev 23.12.00.025
Katrin Fischer [Fri, 19 Apr 2024 17:48:28 +0000 (17:48 +0000)]
Bug 33393: DBRev 23.12.00.025

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33393: Specify layout this works with a bit more clearly in system preference...
Katrin Fischer [Fri, 19 Apr 2024 17:46:51 +0000 (17:46 +0000)]
Bug 33393: Specify layout this works with a bit more clearly in system preference description

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33393: tidy layout1page.pm
Kyle M Hall [Fri, 15 Mar 2024 11:49:34 +0000 (11:49 +0000)]
Bug 33393: tidy layout1page.pm

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33393: Add note to system preference explaining text length
Alex Buckley [Tue, 2 May 2023 05:56:52 +0000 (05:56 +0000)]
Bug 33393: Add note to system preference explaining text length

Sponsored-by: Pymble Ladies' College
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33393: Enable libraries to configure their own text in the 1-Page order PDF
Alex Buckley [Thu, 30 Mar 2023 22:01:54 +0000 (22:01 +0000)]
Bug 33393: Enable libraries to configure their own text in the 1-Page order PDF

Test plan:
1) Apply patches and restart services
2) Upgrade Koha schema:
sudo koha-upgrade-schema <instance>
3) Go to Koha Administration -> Libraries. Ensure Library A has an
address, phone and fax.
4) Go to Koha Administration -> System preferences. Search for
OrderPdfFormat. Set this to English 1-page layout option.
5) Go to Acquisitions. Use an existing vendor or create a new one.
Ensure the vendor has a postal address, phone, fax and accout number.
6) Create a basket for this vendor. Add many orders to this basket, for
example 25 items (this is to make the Order PDF cover multiple pages).
7) Close the basket and add it to a basket group of the same name.
8) Edit the basket group. Add an address in the delivery place, and a
delivery comment. Check the box to close the basket group and Save.
9) Click the button to Export as PDF.
10) View the exported PDF. Confirm the PDF is multiple pages long. If it
is not then re-open the basketgroup and add more orders to the basket
and repeat steps 7, 8, and 9
11) If the PDF is multiple pages long then confirm:
- The text "Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s)." appears above the order table.
- The page numbers at the bottom of the first page are not obscured by
the order table.
- That the order table starts near the top of the second page, and not
half way down.
12) Change content in the '1PageOrderPDFText' syspref (use the Enter key
    to split text over multiple lines) and save
13) Back in the Acquisitions module click the button to Export as PDF
14) View the exported PDF. Confirm the following:
- The text above the order table is what you saved in the
1PageOrderPDFText system preference
- The page numbers at the bottom of the first page are not obscrued by
the order table.
- That the order table starts near the top of the second page and not
halfway down.
15) Empty the 1PageOrderPDFText system preference and save
16) Back in the Acquisitions module click te button to Export as PDF
17) View the exported PDF and confirm the line of text between the
Tel/Fax line and the order table has been removed.

Sponsored-by: Pymble Ladies' College
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33393: Add system preference
Alex Buckley [Thu, 30 Mar 2023 21:56:15 +0000 (21:56 +0000)]
Bug 33393: Add system preference

Sponsored-by: Pymble Ladies' College
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35967: Add more test cases
Tomas Cohen Arazi [Mon, 11 Mar 2024 13:45:08 +0000 (10:45 -0300)]
Bug 35967: Add more test cases

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35967: (QA follow-up) `status` is not nullable
Tomas Cohen Arazi [Mon, 11 Mar 2024 13:38:33 +0000 (10:38 -0300)]
Bug 35967: (QA follow-up) `status` is not nullable

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35967: Add REST API endpoint to list patron recalls
Aleisha Amohia [Thu, 1 Feb 2024 00:43:26 +0000 (00:43 +0000)]
Bug 35967: Add REST API endpoint to list patron recalls

This enhancement adds a REST API endpoint to list a patron's recalls:

/api/v1/patrons/{patron_id}/recalls

This depends on the logged in patron having the manage_recalls subpermission.

To test:

1. Log in to the staff interface as your superlibrarian self (Patron A)
2. Go to Koha Administration -> Global system preferences. Enable the UseRecalls system preference
3. Set the relevant recalls circulation and fines rules
4. Search for an item (Item A)
5. Check out Item A to yourself (Patron A)
6. Log in to the OPAC as Patron B, a patron who does not have the manage_recalls permission
7. Search for Item A and request a recall
8. While still logged in to the OPAC as Patron B, hit this URL: https://your-opac-url/api/v1/patrons/patron-b-borrowernumber/recalls (swap out your URL and Patron B's borrowernumber)
9. Confirm you are given an error: "Authorization failure. Missing required permission(s)."
10. Log out of the OPAC and log back in, this time as Patron A
11. Hit the URL again https://your-opac-url/api/v1/patrons/patron-b-borrowernumber/recalls
12. Confirm you are able to view a list of Patron B's recalls
13. Confirm tests pass: t/db_dependent/api/v1/patrons_recalls.t

Sponsored-by: Auckland University of Technology
PA amended: QA follow-up: tidy

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: (QA follow-up): available_backends fix reduce
Pedro Amorim [Fri, 19 Apr 2024 13:28:02 +0000 (13:28 +0000)]
Bug 19605: (QA follow-up): available_backends fix reduce

available_backends was only considering dir backends for reduce, it should consider all backends, including plugin backends.

This relates to the ILLOpacbackends syspref, where if you add a backend name that happens to be a plugin, it was not disabling it for the OPAC.
This change considers all backends for Illopacbackends, regardless of if its a plugin or a directory backend.

This was made evident while writing tests for bug 36197.
Regression tests for this particular use case, and others, are part of bug 36197.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Another fix after bug 35536
Pedro Amorim [Thu, 28 Mar 2024 16:56:34 +0000 (16:56 +0000)]
Bug 19605: Another fix after bug 35536

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Fix after bug 35536
Tomas Cohen Arazi [Mon, 25 Mar 2024 17:18:09 +0000 (14:18 -0300)]
Bug 19605: Fix after bug 35536

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Clarify method name
Tomas Cohen Arazi [Sat, 9 Mar 2024 13:00:17 +0000 (10:00 -0300)]
Bug 19605: Clarify method name

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Rename method and use the instantiated plugin in the call
Tomas Cohen Arazi [Sat, 9 Mar 2024 12:47:45 +0000 (09:47 -0300)]
Bug 19605: Rename method and use the instantiated plugin in the call

This patch makes the backend instantiation happen through a plugin
object method instead of a static one. This way, the (already)
instantiated plugin can be reused (if needed) in the plugin workflow
like this:

sub new_il_backend {
    my ($self, $params) = @_;
    return Custom::Backend->new(
        {
            config => $params->{config},
            logger => $params->{logger},
            plugin => $self,
        }
    );
}

The passed plugin object would then be used to retrieve whatever
plugin-defined configurations, template paths or even helper methods. On
INN-Reach, it gives the backend access to API user agents, task queue
injection, etc.

This patch also renames the method so it is more straight-forward this is
related to ILL.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Tidy
Tomas Cohen Arazi [Sat, 9 Mar 2024 12:10:03 +0000 (09:10 -0300)]
Bug 19605: Tidy

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Add support for ILL backends as plugins
Pedro Amorim [Mon, 30 Oct 2023 12:14:04 +0000 (11:14 -0100)]
Bug 19605: Add support for ILL backends as plugins

This is designed to maintain existing functionality of loading ILL
backends through the backend_dir config (default Koha/Illbackends/).

A check for a plugin of a given backend name takes precedence over a
backend of the same name loaded the old way through backend_dir, this
means that if this happens, the backend plugin is used and NOT the
backend present in backend_dir.

Old backend_dir backends AND new backend plugins coexist.

Test plan, k-t-d:
1) Enable ILLModule and install FreeForm, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
2) Install the plugin ILL backend example .kpz located at:
https://github.com/ammopt/koha-ill-backend-plugin/releases/tag/1.0.0
3) koha-plack --restart kohadev
4) Visit ILL requests:
/cgi-bin/koha/ill/ill-requests.pl
5) Click "+ New ILL request". Notice it lists 'FreeForm' and
   'PluginBackend'
6) Click 'PluginBackend'. Enter a '123' in pubmedid, '42' in cardnumber
   and pick a library. Click 'Marke request'
7) Notice the request is created successfully.
8) Visit plugins:
/cgi-bin/koha/plugins/plugins-home.pl
9) Click "View plugin by class". Pick "ill backend plugins". Notice the
   correct plugin is listed.
10) Click "configure" on the ILL backend plugin. Notice it's a normal
    plugin configuration page

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Update expandTemplate to expand_template method name
Pedro Amorim [Mon, 30 Oct 2023 12:22:52 +0000 (12:22 +0000)]
Bug 19605: Update expandTemplate to expand_template method name

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 19605: Add 'ill_backend' plugin category
Pedro Amorim [Mon, 30 Oct 2023 12:09:39 +0000 (11:09 -0100)]
Bug 19605: Add 'ill_backend' plugin category

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 33174: Add warning about how many holds are being cancelled
Lucas Gass [Wed, 8 Mar 2023 21:12:39 +0000 (21:12 +0000)]
Bug 33174: Add warning about how many holds are being cancelled

To test:
1. Apply patch
2. Find or make a record with many holds on it.
3. Go to the Holds tab ( request.pl ).
4. Select some hodls to cancel and press "Cancel selected"
5. A modal popup will appear. Notice the warning telling you exactly how many holds you are about to cancel. Confirm the count is accurate.
6. Try using the select all button and make sure the warning is accurate.
7. Make sure you can cancel the holds.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35862: Display modal search results to the right of form above 1200px
Lucas Gass [Wed, 6 Mar 2024 23:44:08 +0000 (23:44 +0000)]
Bug 35862: Display modal search results to the right of form above 1200px

To test:
1. Apply patch
2. Rebuild CSS ( yarn build )
3. Look at some of the places where there is a modal patron search.
    -suggestion/suggestion.pl: Set to patron
    -members/memberentry.pl: Add guarantor

4. Make sure the modal looks good before and after you have searched for a patron.
5. Play with many different screen sizes, ensuring everything looks good and makes sense.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 34575: Add a CSS class to patron email
Pedro Amorim [Fri, 22 Dec 2023 10:36:42 +0000 (10:36 +0000)]
Bug 34575: Add a CSS class to patron email

Adds a CSS class to the patron email section in the 'name-address' column of search results in members-home.pl
No functional behaviour change.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 34574: Add CSS class to datatable select filter
Pedro Amorim [Thu, 21 Dec 2023 14:11:35 +0000 (14:11 +0000)]
Bug 34574: Add CSS class to datatable select filter

Test plan:

1) Create a new patron category, visit:
/cgi-bin/koha/admin/categories.pl?op=add_form
2) Add a category code, en enrollment period, a category type and a really long description like:
"This is a real long description of the patron category code for demo purposes"
3) Now do the same but for a library, visit:
/cgi-bin/koha/admin/branches.pl?op=add_form
4) Add a library code and a really long name like:
"This is a real long library name for demo purposes"
5) Visit patrons home:
/cgi-bin/koha/members/members-home.pl
6) Hit "Search". Notice the "library" and "category" columns grow in width to match the largest option (added in previous steps)
7) Apply patch, add the following CSS to IntranetUserCSS:
.dt-select-filter{
max-width:200px;
}
8) repeat 5) and 6). Notice the columns no longer grow in width.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35151: DBRev 23.12.00.024
Katrin Fischer [Fri, 19 Apr 2024 17:11:56 +0000 (17:11 +0000)]
Bug 35151: DBRev 23.12.00.024

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35151: (follow-up) Remove ILLModuleCopyrightClearance from sysprefs.sql
Katrin Fischer [Fri, 19 Apr 2024 17:10:42 +0000 (17:10 +0000)]
Bug 35151: (follow-up) Remove ILLModuleCopyrightClearance from sysprefs.sql

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 35151: Convert ILLModuleCopyrightClearance system preference to additional contents
Owen Leonard [Thu, 26 Oct 2023 14:38:14 +0000 (14:38 +0000)]
Bug 35151: Convert ILLModuleCopyrightClearance system preference to additional contents

This patch moves the ILLModuleCopyrightClearance system preference into
HTML customizations, making it possible to have language- and
library-specific content.

To test you should have some content in the ILLModuleCopyrightClearance
system preference before applying the patch. Apply the patch, run the
database update process, and rebuild the OPAC CSS.

- In the staff client, go to Tools -> HTML customizations and verify
  that the content from ILLModuleCopyrightClearance is now stored there.
- The HTML customization entry form should offer
  ILLModuleCopyrightClearance as a choice under "Display location."
- Update and reinstall active translations (for instance fr-FR):
  - perl misc/translator/translate update fr-FR
  - perl misc/translator/translate install fr-FR
- Enable the translation if necessary under Administration -> System
  preferences -> language.
- Enable the "opaclanguagesdisplay" preference if necessary.
- Edit the ILLModuleCopyrightClearance HTML customization and add unique
  content to the "fr-FR" tab.

- Enable the "ILLModule" and "ILLModuleUnmediated" system preferences if
  necessary. You must have at least one ILL backend installed.
- Log into the OPAC and click the "Interlibrary loan requests" in the
  sidebar menu on the user summary page.
- Click "Create new request."
- You should be taken to a page with your ILLModuleCopyrightClearance
  content shown along with "Yes" and "No" buttons.
  - Clicking "Yes" should take you to the form for creating a new
    request.
- Switch to your updated translation and confirm that the content
  appears correctly.
- Remove all "ILLModuleCopyrightClearance" html customizations. Test the
  "Create new request" process in the OPAC again.
  - There should be no confirmation step before arriving at the form for
    creating a new ILL request.
- Go to Administration -> System preferences and search for
  "ILLModuleCopyrightClearance." It should return no results.

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoBug 36105: Add 'No status alias' option
Pedro Amorim [Thu, 15 Feb 2024 15:18:38 +0000 (15:18 +0000)]
Bug 36105: Add 'No status alias' option

1) Install FreeForm and enable ILLModule, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
2) Visit /cgi-bin/koha/admin/authorised_values.pl add search for 'alias', click on ILL_STATUS_ALIAS
3) Click on the 'New authorized value for ILL_STATUS_ALIAS' button and add 'alias_code' in authorized value and 'Alias Description' in Description
4) Visit /cgi-bin/koha/ill/ill-requests.pl and create a new FreeForm request
5) After created, click 'Manage request', and then click the 'Edit request' button
6) Edit the Status and select 'Alias Description', click 'Submit'
7) Create a second request but do not set a status alias this time
7) Visit /cgi-bin/koha/ill/ill-requests.pl and select 'Alias description' on the 'Status aliases:' left-side filter
8) Notice the correct record is returned.
9) Now repeat 7) and select 'No status alias'. Notice the request with an empty status_alias is returned
10) Repeat 7 but select 'All status aliases'. Notice both requests are returned

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Nell O’Hora <nohora@aub.ac.uk>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>