A few strings in aqbudgetperiods.tt are untranslatable like Duplicate budget:245, closed:257, and Budgets administration:262. If you review the po file for staff, you will notice that these strings aren't include.
Created attachment 36003 [details] [review] Bug 13350 - Untranslatable strings in aqbudgetperiods.tt This patch fix a few untranslatable strings in aqbudgetperiods.tt. Style not pretty but work. The section modified is BREADCRUMBS. This patch adds html tags to be recognized by misc/translator/translate script. Test plan --------------- 1) Use another language (not English) 2) Go to More > Administration > Budgets. Notice that "> Budgets administration" is untranslatable in the Navigation section. 3) Try to create a New budget. Notice the same happens as previous step. 4) Try delete, edit, duplicate, and close a budget. The result is the same. 5) Apply the patch. 6) Run perl translate update xx-XX (in my case es-ES) 7) Edit es-ES-i-staff-t-prog-v-3006000.po 8) Get notice that a new lines has been adhered to po file. 9) Run perl translate install es-ES 10) Go to Global system preferences and search for "language" in I18N/L10N preferences. Enable Español(es-ES). 11) Follow step 2 and 3 and notice that the strings were translated.
Created attachment 36004 [details] [review] Bug 13350 - Untranslatable strings in aqbudgetperiods.tt This patch fix a few untranslatable strings in aqbudgetperiods.tt. Style not pretty but work. The section modified is BREADCRUMBS. This patch adds html tags to be recognized by misc/translator/translate script. Test plan --------------- 1) Use another language (not English) 2) Go to More > Administration > Budgets. Notice that "> Budgets administration" is untranslatable in the Navigation section. 3) Try to create a New budget. Notice the same happens as previous step. 4) Try delete, edit, duplicate, and close a budget. The result is the same. 5) Apply the patch. 6) Run perl translate update xx-XX (in my case es-ES) 7) Edit es-ES-i-staff-t-prog-v-3006000.po 8) Get notice that a new lines has been adhered to po file. 9) Run perl translate install es-ES 10) Go to Global system preferences and search for "language" in I18N/L10N preferences. Enable Español(es-ES). 11) Follow step 2 and 3 and notice that the strings were translated. Sponsored-by: Universidad de El Salvador Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Created attachment 36407 [details] [review] [Signed-off] Bug 13350 - Untranslatable strings in aqbudgetperiods.tt This patch fix a few untranslatable strings in aqbudgetperiods.tt. Style not pretty but work. The section modified is BREADCRUMBS. This patch adds html tags to be recognized by misc/translator/translate script. Test plan --------------- 1) Use another language (not English) 2) Go to More > Administration > Budgets. Notice that "> Budgets administration" is untranslatable in the Navigation section. 3) Try to create a New budget. Notice the same happens as previous step. 4) Try delete, edit, duplicate, and close a budget. The result is the same. 5) Apply the patch. 6) Run perl translate update xx-XX (in my case es-ES) 7) Edit es-ES-i-staff-t-prog-v-3006000.po 8) Get notice that a new lines has been adhered to po file. 9) Run perl translate install es-ES 10) Go to Global system preferences and search for "language" in I18N/L10N preferences. Enable Español(es-ES). 11) Follow step 2 and 3 and notice that the strings were translated. Sponsored-by: Universidad de El Salvador Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Followed test plan. Works as expected. Signed-off-by: Marc Véron <veron@veron.ch>
Comment on attachment 36407 [details] [review] [Signed-off] Bug 13350 - Untranslatable strings in aqbudgetperiods.tt Review of attachment 36407 [details] [review]: ----------------------------------------------------------------- Hi Héctor, I think something strange is going on here and I would like to avoid changing how the bradcrumbs display the last bit - could you take another look? Also adding Bernardo, maybe he has some ideas. ::: koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgetperiods.tt @@ +238,2 @@ > [% ELSE %] > + Delete budget <i>'[% budget_period_description %]'?</i> I am not sure why the ' would cause the strings to be not translatable, but probably easisest would be to just remove them and maybe also the <i>? Thinking about how this looks like in other places in Koha. @@ +240,5 @@ > [% END %] > [% END %] > <!-- duplicate a budget --> > [% IF ( duplicate_form ) %] > + <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">Budgets</a> › <strong>Duplicate budget</strong> I think we shouldn't use strong here, as the current page is not highlighted like that on the other pages. I think a <span> should do the trick without an optical change, but it would be a little better to see why these pages don't get translated, while other pages work correctly and adjust the code to look the same (hope I make sense). @@ +257,5 @@ > [% END %] > <!-- display budget periods list --> > <!-- ########################################## --> > [% IF ( else ) %] > + <strong>Budgets administration</strong> Same here as above - there are a lot of strange looking comments on this site. Hm.
Hi Katrine I've used strong tag on example basis. If you go to Patrons and then create a New patron (e.g. Staff), this will display "Add patron (Staff)" in bold type. So, this kind of code has been used in memberentrygen.tt I will try to test another solution or if Bernardo can help, he has got more experiences with untranslatables strings. Regards
I'm looking into this right now :)
Can't said that I found the problem, but a solution. Removing comments on breadcrumb code does the job, e.g. - <!-- delete a budget period --> - <!-- ################################ --> With only that the text is now picked up by translation script. But new strings are not good, some phrases are split and then difficult to translate. So I propose a counter patch, putting <span>...</span> on each string. With that, updating and installing es-ES gives a correct result, no need to translate.
Created attachment 36634 [details] [review] Bug 13350: Untranslatable strings in aqbudgetperiods.tt Counter patch, same test plan as original
I think this need a sign, or an opinion :)
Created attachment 36639 [details] [review] [Signed-off] Bug 13350: Untranslatable strings in aqbudgetperiods.tt Counter patch, same test plan as original Followed test plan, works as expected. Signed-off-by: Marc Véron <veron@veron.ch>
Created attachment 36772 [details] [review] Bug 13350: Untranslatable strings in aqbudgetperiods.tt Counter patch, same test plan as original Followed test plan, works as expected. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Patch pushed to master. Thanks Bernardo! We are getting closer!
Pushed to 3.18.x will be in 3.18.5