Bug 32008 - String "Not for loan " not translated to german "Nicht ausleihbar"
Summary: String "Not for loan " not translated to german "Nicht ausleihbar"
Status: RESOLVED DUPLICATE of bug 30352
Alias: None
Product: Koha
Classification: Unclassified
Component: System Administration (show other bugs)
Version: 22.05
Hardware: All All
: P5 - low normal
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-10-27 06:08 UTC by Hans Ulrich Frink
Modified: 2022-10-29 09:46 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
screenshot of missing transllation (68.09 KB, image/png)
2022-10-27 06:08 UTC, Hans Ulrich Frink
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Hans Ulrich Frink 2022-10-27 06:08:04 UTC
Created attachment 142694 [details]
screenshot of missing transllation

In our German install of Koha 22.05 the string "Not for loan " is not translated to german "Nicht ausleihbar"
When searching for journals on our koha library site www.opac.genealogie-lahndill.de that string remains in English language. Please see attachment.
I found no way to exchange strings.
Comment 1 Katrin Fischer 2022-10-27 09:07:47 UTC
It's not only in German - it doesn't translate in general for a programming problem. I've tried to fix it, but failed so far. See bug 30352.

*** This bug has been marked as a duplicate of bug 30352 ***
Comment 2 Katrin Fischer 2022-10-27 09:09:17 UTC
For a workaround you can try to set the "Nicht-Ausleihbar" status in the items. You might also need to make the item type "for loan" then - but maybe it works already if both are set.
The problem appears when the "Not for loan" is derived from the itemtype being set to 'for reference'.
Comment 3 Katrin Fischer 2022-10-27 09:42:55 UTC
You can also fix it by translating the string with jQuery/Javascript - I can help with that later, if you are interested.
Comment 4 Hans Ulrich Frink 2022-10-28 14:47:05 UTC
(In reply to Katrin Fischer from comment #3)
> You can also fix it by translating the string with jQuery/Javascript - I can
> help with that later, if you are interested.

Hi Karin,
that would be fine.
I know about jquery and use it on my own websites, but it may be different on koha.
we could chat or video is also possible on senfcall or jitsi, as you prefer.
Just make a time/date proposal. As I have retired I got time.
cheers 
Uli
Comment 5 Katrin Fischer 2022-10-28 19:43:55 UTC
You can paste this in your OpacUserJs system preference:

$( document ).ready(function() {

$("html[lang='de-DE'] .notforloandesc:contains('Not for loan')").text('Nicht ausleihbar');

});

You can find more examples for the use of jQuery in Koha in the wiki at https://wiki.koha-community.org/wiki/JQuery_Library 

:)
Comment 6 Hans Ulrich Frink 2022-10-29 06:13:17 UTC
Thanks for your help, Karin.

In the end "_Not" was missing in the selector, so for further interest the following is the full workaround:

$("html[lang='de-DE'] .notforloandesc_Not:contains('Not for loan')").text('Nicht ausleihbar');

Thank you again for your quick help

Uli
Comment 7 Katrin Fischer 2022-10-29 09:46:59 UTC
(In reply to Hans Ulrich Frink from comment #6)
> Thanks for your help, Karin.
> 
> In the end "_Not" was missing in the selector, so for further interest the
> following is the full workaround:
> 
> $("html[lang='de-DE'] .notforloandesc_Not:contains('Not for
> loan')").text('Nicht ausleihbar');
> 
> Thank you again for your quick help
> 
> Uli

Maybe there is a difference in versions - I had tested/written it with the latest development version. Maybe something to keep in mind to test after the next update. Glad you could make it work.