[Bug 20545] New: Add multi-language support to SIP2

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] New: Add multi-language support to SIP2

bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

            Bug ID: 20545
           Summary: Add multi-language support to SIP2
 Change sponsored?: ---
           Product: Koha
           Version: master
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5 - low
         Component: SIP2
          Assignee: [hidden email]
          Reporter: [hidden email]
        QA Contact: [hidden email]
                CC: [hidden email]

At the moment the messages from the SIP2 server are in English by default and
can be changed using a feature Kyle has written on bug 12571.

The problem is, that while this can be used to translate the message, it
doesn't provide true multi-language support. It's very common to provide the
GUI on the self checks in mulitple languages here, so there is a need for
translating the errors etc. sent by Koha as well.

The SIP specification provides means to send a language code that would allow
us to implement this properly. It uses a 3 character language code in its
messages:

http://multimedia.3m.com/mws/media/355361O/sip2-protocol.pdf

Language Code
Unknown (default)  000
English 001          
French 002          
German 003          
Italian 004          
Dutch 005          
Swedish 006          
Finnish 007          
Spanish 008          
Danish 009          
Portuguese 010          
Canadian-French 011          
Norwegian 012          
Hebrew 013          
Japanese 014          
Russian 015          
Arabic 016          
Polish 017          
Greek 018          
Chinese 019          
Korean 020          
North American Spanish 021
Tamil 022          
Malay 023          
United Kingdom 024          
Icelandic 025          
Belgian 026          
Taiwanese 027

--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

Kyle M Hall <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #1 from Kyle M Hall <[hidden email]> ---
If we moved all SIP2 strings into Template Toolkit files it would make
translation easy. I would recommend we use TT directly in the SIP2 code and
*not* use C4::Templates do to it's cgi-centriticy and the fact that it would
add a huge amount of overhead to the SIP server.

--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

--- Comment #2 from Kyle M Hall <[hidden email]> ---
Also, if we are going this far, we should also allow alternative templates to
be specified on a per-login basis in the SIP2 config.

--
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

--- Comment #3 from Kyle M Hall <[hidden email]> ---
Better idea from cait, use YAML and hook into the same translation system as
the sysprefs. Still should allow alternatives in the config ; )

--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

Magnus Enger <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #4 from Magnus Enger <[hidden email]> ---
This hints at a bug in the SIP2 implementation in Koha. In the SIP2 standard
that Katrin references in Comment 1, "language" is listed as a "3-char, fixed
length required field". The contents of this field should be the 3-digit
language codes that Katrin lists.

As fas as I can tell, Koha uses the contents of the borrowers.lang database
field for the language, using 000 if the field is not set:
http://git.koha-community.org/gitweb/?p=koha.git;a=blob;f=C4/SIP/ILS/Patron.pm;h=23c576493fbc6214905efd1297225057a80c537a;hb=HEAD#l252

If a language code like nb-NO is used for the language in SIP2 the language
info will have both the wrong length and the wrong format.

As far as I can tell, we should have a mapping somewhere from the codes we use
in borrowers.lang to the 3-digit codes required by SIP2.

Not sure if it makes sense to fix this as part of the present bug or if it
should be a separate bug.

--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

--- Comment #5 from Katrin Fischer <[hidden email]> ---
Hm, I was wondering if we should just response in the lanugage that was set in
the request, assuming that it's the language selected on the self check GUI.
Maybe a fallback to borrowers.lang?

Yes, we'd need to map the Koha language codes to the SIP2 codes in some way.
Maybe a YAML system preference?

--
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

--- Comment #6 from Colin Campbell <[hidden email]> ---
Actually we always return 000 for the language because the language does not
get set in the ILS::Patron objectand we fall back on default.

Would be interesting to see if self-issue machines take much notice of whats
set, what they are configured for may override anything in the response

--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

--- Comment #7 from Magnus Enger <[hidden email]> ---
(In reply to Colin Campbell from comment #6)
> Actually we always return 000 for the language because the language does not
> get set in the ILS::Patron objectand we fall back on default.

That has not been my experience. The one time I checked, borrowers.lang was
empty and the three-digit language code was missing from the SIP2 response,
giving the "fixed length" part of the response the wrong length.

--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|

[Bug 20545] Add multi-language support to SIP2

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20545

--- Comment #8 from Katrin Fischer <[hidden email]> ---
I think borrowers.lang was added in 17.05 or 17.11, maybe you are looking at
different versions? It's a rather recent addition.

--
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/