This simply copies the fetch of budgets from the acqui/histsearch.pl script.
We should in the future make this a template or other method to avoid code duplication,
but we should fix the functionality first.
To test:
1 - Go to Acqusitions
2 - See the dropdown "Fund: All funds" in the order search section
3 - Click it
4 - Feel disappointed
5 - Apply patch and restart all
6 - Reload and click the dropdown
7 - Options! Feel warm and fuzzy
Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch just reverses the order so we display the list, then update it.
To test:
1 - Enable showLastPatron system preference and set showLastPatronCount to 1
2 - Go to a patron, say Ronnie Ballard
3 - Note you have a link to 'Last patron' - hover or click split dropdown and see it is the patron you are viewing
4 - Search for another patron, Edna Acosta
5 - Note the 'Last patron' links point to Edna, and not Ronnie
6 - Apply patch
7 - Reload Edna, note last patron lists Edna
8 - Search for Ronnie
9 - Confirm previous patron is linked to Edna
10 - Click the link to go to Edna
11 - Confirm last patron now links to Ronnie
12 - Instead of following link, click on another tab for patron
13 - Now the link is updated to current patron, this was behaviour before 21246 as well
14 - Sign off.
Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
It's autogenerated and checksum protected so should be touch only by
dbic.
JD amended patch: just the revert to Koha/Schema.pm here
Koha/Schema.pm will be skipped on bug 39115 (otherwise I will have to
rebase)
original title: Bug 39132: Fix dbic: Revert changes to Schema.pm and add it to denylist
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch makes choosing `polling` for the `JobsNotificationMethod`
system preference not be considered problematic or different than
`STOMP`.
To test:
1. In `KTD` make sure you have `STOMP` selected
2. Make sure rabbitmq is running:
$ ktd --shell
k$ sudo -s
$ service rabbitmq-server start
3. Go to the about page, 'Server information'
=> SUCCESS: 'Using RabbitMQ' displayed
4. Stop rabbit
$ service rabbitmq-server stop
5. Repeat 3
=> SUCCESS: Using Rabbit but fallback to polling
6. Go to the 'System information' tab
=> SUCCESS: Error message about the broker not functional
7. Choose 'polling'
8. Repeat 3
=> FAIL: It says 'Using SQL polling' but in bold face <.<
9. Repeat 6
=> FAIL: There's an error about the broker, which we explicitly asked
not to use <.<
10. Apply this patch
11. Repeat 3
=> SUCCESS: Nothing weird, 'Using SQL polling' displayed.
12. Repeat 6
=> SUCCESS: No weird error about the broker.
13. Switch to 'STOMP'
=> SUCCESS: Behavior is the same with/without rabbit running
14. Sign off :-D
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
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>
We don't need an empty blank line.
Might not have been caused by the tidy
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This patch updates the template which generates item search JSON (for
use by the DataTable) to add a 'collapse' FILTER around it. This
eliminates whitespace which causes the JSON to be invalid.
To test, apply the patch and perform an item search in the staff
interface. It should return results without error.
Sponsored-by: Athens County Public Libraries
Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
If yarn is not installed:
Tidying file 1/1 (koha-tmpl/intranet-tmpl/prog/fr-FR/modules/intranet-main.tt)
Warning: something's wrong at misc/devel/tidy.pl line 79.
There is the error hidden in $error_message
open3: exec of yarn --silent run prettier --write koha-tmpl/intranet-tmpl/prog/fr-FR/modules/intranet-main.tt failed: No such file or directory
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
It looks like this was a type/copy paste error, template fixed
To test:
1 - Find a patron, ensure preferred_name is populated
2 - Duplicate
3 - Note preferred_name is carried over
4 - Apply patch
5 - Cancel and duplicate again
6 - Preferred name is blank!
Signed-off-by: Andrew Fuerste Henry <andrew@bywatersolutions.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This fixes an internal server error when renewing an expired
child patron without a guarantor, when the ChildNeedsGuarantor
is set to "must have".
Test plan:
1. Create or edit a child patron:
- Don't add a guarantor.
- Set the "Expiry date" to a date in the past.
2. Set the ChildNeedsGuarantor system preference to "must have".
3. Refresh or view the patron's check out or details page, and
select the "Renew" link under the attention heading -
this generates an internal server error message.
4. Apply patch.
5. Repeat step 3, you will now get a standard error message
"This patron could not be renewed: they need a guarantor."
6. Add a guarantor for the patron.
7. Repeat step 3, and click "Renew" - the patron is now renewed.
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>
Note: there is a minor bug I had to correct, I don't split into two
patches since it is very minor and necessary to test that one.
Patch 1 - (this one) When a user is on serial collection information, the subscription is
not passed to the template, and therefore not passed to serials-toolbar.inc.
This makes sense if collection information is called with a biblionumber
but not if collection information is called with a subscription id.
Consequently, subscription.closed is always false and it is not possible
to reopen a basket.
Patch 2 - User with incorrect permission can close serials, they just
need to access to the page. This is due to serials-toolbar.inc expecting
a variable named "cannotedit", which is provided by
"subscription-details.pl" and not by "serials-collection.pl"
TEST PLAN:
Before applying patches :
1 - log in as a user with only receive_serial permission
2 - Open two pages one on
/serials-collection.pl?subscriptionid=ID_A, another on
/serials-collection.pl?subscriptionid=ID_B
3 - On serial A's collection page, check you can close the serial (wrong
behaviour), note you can close it again but not reopen it
4 - Apply first patch
5 - Check you can reopen the serial (wrong behaviour) keep the page open
6 - On serial B's collection page, close the serial, keep the page open
7 - Apply second patch
8 - On page left open on 3 -, click on close, you are redirected to a
login page.
8 - Go back to serial A's collection page -> there is no close button
anymore
9 - On page left open on 4 -, click on reopen, you are redirected to a
login page
10 - Go back to serial B's collection page -> there is no close button
anymore
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>
Patch 1 - (this one) When a user is on serial collection information, the subscription is
not passed to the template, and therefore not passed to serials-toolbar.inc.
This makes sense if collection information is called with a biblionumber
but not if collection information is called with a subscription id.
Consequently, subscription.closed is always false and it is not possible
to reopen a basket.
Patch 2 - User with incorrect permission can close serials, they just
need to access to the page. This is due to serials-toolbar.inc expecting
a variable named "cannotedit", which is provided by
"subscription-details.pl" and not by "serials-collection.pl"
TEST PLAN:
Before applying patches :
1 - log in as a user with only receive_serial permission
2 - Open two pages one on
/serials-collection.pl?subscriptionid=ID_A, another on
/serials-collection.pl?subscriptionid=ID_B
3 - On serial A's collection page, check you can close the serial (wrong
behaviour), note you can close it again but not reopen it
4 - Apply first patch
5 - Check you can reopen the serial (wrong behaviour) keep the page open
6 - On serial B's collection page, close the serial, keep the page open
7 - Apply second patch
8 - On page left open on 3 -, click on close, you are redirected to a
login page.
8 - Go back to serial A's collection page -> there is no close button
anymore
9 - On page left open on 4 -, click on reopen, you are redirected to a
login page
10 - Go back to serial B's collection page -> there is no close button
anymore
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>
In ktd 369 will show the "Encoding error" block:
http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=369
The background color has changed this the bootstrap update and now looks
ugly.
This patch reuse the same color (#f2dede) we had before the upgrade
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>
When we attempt to add child as guarantor the error message shown is 'A guarantor cannot be a guarantee.' it doesn't make sense
To recreate:
1. Go to Patrons
2. Click 'New patron' > 'Kid'
3. Fill out surname and cardnumber
4. Under Patron guarantor, click Add guarantor
5. Search for category = Kid and choose one of the patrons
6. Choose the relationship
7. Click 'Save'
--> Error A guarantor cannot be a guarantee.
8. Apply the patch
9. repeat previous steps
10. After clicking Save
--> the error message shown is «Child patron cannot be a guarantor.»
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>
This patch reverts the changes from bug 38718 made to errorpage.tt
It fixes Auth/csrf.ts cypress test, but most important restores the
correct UI on the error page when there is a CSRF error.
This was caused by the STOP from blocking_errors, that is introduced by
messages.inc included by main-container.inc
This patch fixes the following error:
sort (...) interpreted as function at /kohadevbox/koha/installer/data/mysql/updatedatabase.pl line 25950.
sort @words and sort { $a cmp $b } @words are functionally identical because
Perl's default sort behavior is string-wise ascending order (which is exactly
what { $a cmp $b } specifies).
There was a missing END in basket/basket.tt (it should have been raised
by the tidy that something wrong happened, to investigate later)
The branch-selector change is a trick to make the test pass, or it fails
with:
# undef error - WHILE loop terminated (> 1000 iterations)
We don't want to comment the whole block or it won't be parsed by the
translator tool.
This has been done initially to make the prettier plugin happy but it
didn't handle TT comments correctly. Now with version 2.0.2 it should be
better.
This patch fixes t/db_dependent/misc/translator/xgettext-tt2.t
I had the tidy.pl script with correct +x permission during my testing
session. Now we retrieve it from main, write its content into a
temporary file. It does not have the +x bit.
This commit is generated using:
% perl misc/devel/tidy.pl
*within* ktd, to get the same version of perltidy than what will be used
by our CI (currently v20230309).
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
* Test the translation process
* Confirm that the changes make sense
```
- <option value="r" selected="selected">Remote-sensing image</option>
+ <option value="r" selected="selected">
+ Remote-sensing image
+ </option>
```
=> Generate
```
+#: koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_007.tt:89
+#, fuzzy, c-format
+msgid "Remote-sensing image "
+msgstr "Image de télédétection"
```
Added a "trim" commit, and it actually fixes some problem with the current script:
```
+#. For the first occurrence,
#. SCRIPT
-#: koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_007.tt:114
+#: koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_007.tt:139
msgid "b- Large print"
msgstr "b- Gros caractères"
-#. SCRIPT
-#: koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_007.tt:114
-msgid "b- Large print "
-msgstr "b- Gros caractères "
```
Is that enough?
OR we modify prettier's default behaviour: https://prettier.io/docs/en/options.html#html-whitespace-sensitivity
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
We want to test the files from the git index only
On my laptop:
real 3m54.692s
user 3m51.466s
sys 0m0.994s
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>