Closed emylonas closed 3 years ago
EM check language code once more. See #98
Would it be possible to add syc = "Syriac" to these language codes as well? As per issue with qast0001 and iip-text issue #140
Correction: syc/Syriac not necessary
Sorry for the waffling - can we get syc as "Syriac"? Firm commitment to it this time.
I think this is the change that should be added: in file iip_smr_web_app/templatetags/iipCustomFilters.py l. 25ff
vocab_dict = {
"grc":"Greek",
"he":"Hebrew",
"la":"Latin",
"arc":"Aramaic",
"xcl":"Armenian",
"geo":"Georgian",
"syc":"Syriac",
"x-unknown":"Unknown",
}
and in file iip_smr_web_app/forms.py l. 92ff
self.languages_dict = {
"he":"Hebrew",
"la": "Latin",
"grc": "Greek",
"arc": "Aramaic",
"xcl":"Armenian",
"geo":"Georgian",
"syc":"Syriac",
"x-unknown":"Unknown"
}
I did a grep for grc
in the code base, to find where language arrays appear and this is what I came up with. There may be other places that I haven't found. (it also appears in old_forms.py l. 86, but perhaps it's not in use? if should be updated, then please insert the same array.
I believe the language-codes must also be updated in the indexer. Will look into this.
It's in the solr xsl, I can change it right now! no need for you to look at this. best, --elli
On Wed, Feb 17, 2021 at 10:42 AM Birkin James Diana < notifications@github.com> wrote:
I believe the language-codes must also be updated in the indexer. Will look into this.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Brown-University-Library/iip-production/issues/106#issuecomment-780646786, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAOA7ZJ4FD4QC6NLREP5GWTS7PPYDANCNFSM4VWRV42A .
I'm on the fence: I'm reluctant to push the changes you suggested -- and that I made in a branch -- to production, because it appears these may be old unused code, with the newer code simply using the solr "language_display" field. If all looks correct with your change to the solr.xsl -- then perhaps this issue could be revised to "Delete unused language-code code".
@birkin check whether this provisions the search page
Can we add phn as "Phoenician" as well? syc and phn are right-to-left languages, if that matters.
@zeichman I can do that in the css and the solr xsl.
I have added the language codes in the IIP->solr script. There is also a list of langauges in forms.py, which is probably used on the search page. Finally I should add the rtl languages to the CSS so they are displayed in the proper direction.
I'm on the fence: I'm reluctant to push the changes you suggested -- and that I made in a branch -- to production, because it appears these may be old unused code, with the newer code simply using the solr "language_display" field. If all looks correct with your change to the solr.xsl -- then perhaps this issue could be revised to "Delete unused language-code code".
@birkin the solr "language_display" field is not enough. The languages are not displaying properly on the search page. I think we need forms.py.
Updating SearchForm.languages_dict
in forms.py
is enough to make languages show up on the search page. Two issues:
Corrected the file listed as heb (zoor0452).
@atbradley There is some code in the iip_to_solr.xsk script, around l. 191ff which handles second or more languages. It seems to only know about Latin, Hebrew, Greek and Aramaic. Could this be the problem?
@atbradley After today's pull request, there are still problems:
language_display
and not language
Not sure if this is correct, but some places to start looking.
I've deployed my change to the language dictionary in forms.py. It's looking right to me now.
Looks great, go ahead and close!
On Thu, Jun 24, 2021 at 2:10 PM Adam Bradley @.***> wrote:
I've deployed my change to the language dictionary in forms.py. It's looking right to me now.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Brown-University-Library/iip-production/issues/106#issuecomment-867849898, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAOA7ZKJVRAL4DHI4N5RHPDTUNYILANCNFSM4VWRV42A .
A few (about 10) inscriptions are being added to IIP that are in Armenian and Georgian. Armenian: ISO language code -
xcl
Example inscriptions - jer0545, jeru0557Georgian: ISO language code -
geo
example inscriptions - bqut0001, bqut0002In order for the search page to display these languages properly, we need to add the ISO codes and full names of the new languages wherever this is managed. I found an array of ISO codes and language names here: iip_smr_web_app/templatetags/iipCustomFilters.py l. 25 iip_smr_web_app/forms.py l. 92
See also #98