[Bug 9141] New: Untranslatable strings on "pay an amount..." page
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Bug ID: 9141 Summary: Untranslatable strings on "pay an amount..." page Classification: Unclassified Change sponsored?: --- Product: Koha Version: master Hardware: All URL: /cgi-bin/koha/members/paycollect.pl OS: All Status: NEW Severity: normal Priority: P5 - low Component: I18N/L10N Assignee: koha-bugs@lists.koha-community.org Reporter: katrin.fischer@bsz-bw.de CC: frederic@tamil.fr paycollect.pl 100 error => sprintf( 'You must pay a value less than or equal to %f.2', $total_due ) Message is shown when you pay a fine and enter a value that is bigger than the totel due: You must pay a value less than or equal to 5.000000.2 Message is not translatable. Also the fine amount is formatted incorrectly. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Assignee|koha-bugs@lists.koha-commun |oleonard@myacpl.org |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 --- Comment #1 from Owen Leonard <oleonard@myacpl.org> --- Created attachment 13665 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13665&action=edit [PATCH] Bug 9141 - Untranslatable strings on "pay an amount..." page Moving text of an error message from the script into the template. To test, submit an amount which is greater than the amount due. You should see an error message displayed correctly with a properly-formatted currency amount. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13665|0 |1 is obsolete| | --- Comment #2 from Marc Véron <veron@veron.ch> --- Created attachment 13857 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13857&action=edit [SIGNED-OFF] Bug 9141 - Untranslatable strings on "pay an amount..." page Moving text of an error message from the script into the template. To test, submit an amount which is greater than the amount due. You should see an error message displayed correctly with a properly-formatted currency amount. Signed-off-by: Marc Veron <veron@veron.ch> Patch behaves as expected. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off CC| |veron@veron.ch Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |paul.poulain@biblibre.com QA Contact| |paul.poulain@biblibre.com --- Comment #3 from Paul Poulain <paul.poulain@biblibre.com> --- QA comment: tiny patch, but I think it could be even simpler. Instead of using a error_over => 1, why not use total_due = -[% IF ( error ) %] +[% IF (total_due > 0 ) %] should achieve the same result, isn't it ? In this case the patch would just be: -[% IF ( error ) %] +[% IF (total_due > 0 ) %] - [% error %] + You must pay a value less than or equal to [% total_due | format('%.2f') %]. - error => sprintf( 'You must pay a value less than or equal to %f.2', - $total_due ) + total_due => $total_due Your opinion ? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 --- Comment #4 from Paul Poulain <paul.poulain@biblibre.com> --- (In reply to comment #3)
Your opinion ?
ping... -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 --- Comment #5 from Owen Leonard <oleonard@myacpl.org> --- (In reply to comment #3)
Your opinion ?
Your version is simpler, but I think what we lose is the readability of the template. Seeing that an error message is displayed if total_due > 0 doesn't mean anything unless you examine the script and see under what condition the variable is being set. The more verbose version makes it clear that the script sets an error variable. I don't think it's a big deal, but I prefer my version. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 --- Comment #6 from Marc Véron <veron@veron.ch> --- I agree with Owen. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA CC| |jonathan.druart@biblibre.co | |m --- Comment #7 from Jonathan Druart <jonathan.druart@biblibre.com> --- QA Comments: With the agreement of Paul, I pass qa on this patch. Works as expected. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13857|0 |1 is obsolete| | --- Comment #8 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 14418 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14418&action=edit Bug 9141 - Untranslatable strings on "pay an amount..." page Moving text of an error message from the script into the template. To test, submit an amount which is greater than the amount due. You should see an error message displayed correctly with a properly-formatted currency amount. Signed-off-by: Marc Veron <veron@veron.ch> Patch behaves as expected. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Jared Camins-Esakov <jcamins@cpbibliography.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #9 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- This patch has been pushed to master. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9141 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |Pushed to Stable CC| |chris@bigballofwax.co.nz --- Comment #10 from Chris Cormack <chris@bigballofwax.co.nz> --- Pushed to 3.10.x and 3.8.x -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org