Bug 13350 - Untranslatable strings in aqbudgetperiods.tt
Summary: Untranslatable strings in aqbudgetperiods.tt
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: I18N/L10N (show other bugs)
Version: master
Hardware: All All
: P5 - low trivial (vote)
Assignee: Bernardo Gonzalez Kriegel
QA Contact: Testopia
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-26 17:37 UTC by Héctor Eduardo Castro Avalos
Modified: 2015-12-03 22:03 UTC (History)
7 users (show)

See Also:
Change sponsored?: ---
Patch complexity: String patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 13350 - Untranslatable strings in aqbudgetperiods.tt (3.36 KB, patch)
2015-02-18 20:38 UTC, Héctor Eduardo Castro Avalos
Details | Diff | Splinter Review
Bug 13350 - Untranslatable strings in aqbudgetperiods.tt (3.46 KB, patch)
2015-02-18 20:54 UTC, Héctor Eduardo Castro Avalos
Details | Diff | Splinter Review
[Signed-off] Bug 13350 - Untranslatable strings in aqbudgetperiods.tt (3.56 KB, patch)
2015-03-03 14:31 UTC, Marc Véron
Details | Diff | Splinter Review
Bug 13350: Untranslatable strings in aqbudgetperiods.tt (3.18 KB, patch)
2015-03-05 18:53 UTC, Bernardo Gonzalez Kriegel
Details | Diff | Splinter Review
[Signed-off] Bug 13350: Untranslatable strings in aqbudgetperiods.tt (3.36 KB, patch)
2015-03-06 08:42 UTC, Marc Véron
Details | Diff | Splinter Review
Bug 13350: Untranslatable strings in aqbudgetperiods.tt (3.41 KB, patch)
2015-03-10 16:08 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Héctor Eduardo Castro Avalos 2014-11-26 17:37:30 UTC
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.
Comment 1 Héctor Eduardo Castro Avalos 2015-02-18 20:38:17 UTC Comment hidden (obsolete)
Comment 2 Héctor Eduardo Castro Avalos 2015-02-18 20:54:06 UTC Comment hidden (obsolete)
Comment 3 Marc Véron 2015-03-03 14:31:54 UTC Comment hidden (obsolete)
Comment 4 Katrin Fischer 2015-03-05 14:02:52 UTC
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> &rsaquo; <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.
Comment 5 Héctor Eduardo Castro Avalos 2015-03-05 15:25:27 UTC
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
Comment 6 Bernardo Gonzalez Kriegel 2015-03-05 15:28:06 UTC
I'm looking into this right now :)
Comment 7 Bernardo Gonzalez Kriegel 2015-03-05 18:50:37 UTC
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.
Comment 8 Bernardo Gonzalez Kriegel 2015-03-05 18:53:33 UTC Comment hidden (obsolete)
Comment 9 Bernardo Gonzalez Kriegel 2015-03-05 18:55:57 UTC
I think this need a sign, or an opinion :)
Comment 10 Marc Véron 2015-03-06 08:42:51 UTC Comment hidden (obsolete)
Comment 11 Jonathan Druart 2015-03-10 16:08:12 UTC
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>
Comment 12 Tomás Cohen Arazi 2015-03-11 17:40:07 UTC
Patch pushed to master.

Thanks Bernardo! We are getting closer!
Comment 13 Chris Cormack 2015-03-13 22:32:08 UTC
Pushed to 3.18.x will be in 3.18.5