[Koha-bugs] [Bug 13352] Editing amount in Acquisitions budget causes error due to formatting

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Sun Feb 8 16:26:21 CET 2015


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13352

Katrin Fischer <katrin.fischer at bsz-bw.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #35703|0                           |1
        is obsolete|                            |

--- Comment #6 from Katrin Fischer <katrin.fischer at bsz-bw.de> ---
Created attachment 35724
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=35724&action=edit
[PASSED QA] Bug 13352: On editing, prices should not be formatted

Bug 12979 refactored the way to display prices.
The price format configuration was duplicated everywhere it was used.

All calls looks good except the one in admin/aqbudgetperiods.pl
In this one, the prices are formatted for an edition field (input).
This means the input is incorrectly filled even if the user does not
update the field.

At the end, maybe should we manage formatted prices everywhere, even in
inputs, but it's not in the scope of this bug.

Technically, a new subroutine format_for_editing is added to the
Koha::Number::Price module.
It should be called everywhere a price is displayed in an input field.
At the moment, it only does a sprintf("%.2f"), but it is a first step to
let the number of decimals to display configurable.

To test:
1/ Verify the issue described is fixed (editing a budget with a total
amount > 1000 (With CurrencyFormat is US or FR).
2/ Verify you can edit a fund with a total amount > 1000

Signed-off-by: Paola Rossi <paola.rossi at cineca.it>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83 at web.de>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list