[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2017-06-30 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

   See Also||https://bugs.koha-community
   ||.org/bugzilla3/show_bug.cgi
   ||?id=18002

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2016-12-08 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Josef Moravec  changed:

   What|Removed |Added

 CC||josef.mora...@gmail.com

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2016-07-19 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Katrin Fischer  changed:

   What|Removed |Added

   See Also||https://bugs.koha-community
   ||.org/bugzilla3/show_bug.cgi
   ||?id=16940

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2016-03-20 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Owen Leonard  changed:

   What|Removed |Added

   Assignee|ve...@veron.ch  |koha-b...@lists.koha-commun
   ||ity.org

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2016-03-18 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Owen Leonard  changed:

   What|Removed |Added

   Assignee|oleon...@myacpl.org |ve...@veron.ch

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #21 from Jonathan Druart  
---
(In reply to Jonathan Druart from comment #20)
> You do you remove this default value, it does not look mandatory.

s/You/Why

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #20 from Jonathan Druart  
---
Comment on attachment 45888
  --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45888
Bug 4078 - Display active currency symbol on currency output and input

Review of attachment 45888:
 --> 
(http://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html=4078=45888)
-

You will have to write tests.

I don't think it's the good approach. What about the other cases?
For instance : "-£127.54" vs "-127,54 €", you will have to add 3 values.
I think that what you are trying to add with this patch should be done at the
currency level (currency table), not the syspref.
Actually the syspref should be removed.

::: Koha/Number/Price.pm
@@ +79,4 @@
>  
>  sub _format_params {
>  my ( $self, $params ) = @_;
> +my $with_symbol = $params->{with_symbol};

You do you remove this default value, it does not look mandatory.

@@ +96,5 @@
> +$p_cs_precedes = 1 unless ( defined $p_cs_precedes );
> +}
> +
> +if ( $currency_format =~ m/(_TRAIL)/ ) {
> +$p_cs_precedes = 0 unless ( defined $p_cs_precedes );

You are mixing ternary operator in the conditions, it does not make the code
easy to read.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Jonathan Druart  changed:

   What|Removed |Added

 Status|Signed Off  |Failed QA

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

   Assignee|ve...@veron.ch  |oleon...@myacpl.org

--- Comment #22 from Marc Véron  ---
(In reply to Jonathan Druart from comment #20)
> Comment on attachment 45888 [details] [review]

> (...) should be done at the currency level (currency table), not the syspref.
> Actually the syspref should be removed.
> (...)

Hi Jonathan, your approach will be better, for sure. 

I remove assignement from this long outstanding bug and will be happy to
sign-off your solution. I simply hope that we soon have the possibility to
display currency symbols and more currency formatting than the US and French
ones only, e.g. 360'000.00 for Switzerland.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-21 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Aleisha Amohia  changed:

   What|Removed |Added

 Status|Needs Signoff   |Signed Off

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-21 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Aleisha Amohia  changed:

   What|Removed |Added

  Attachment #45878|0   |1
is obsolete||

--- Comment #19 from Aleisha Amohia  ---
Created attachment 45888
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45888=edit
Bug 4078 - Display active currency symbol on currency output and input

Display active currency using international formatting patterns and active
currency symbol withplugin price.

To test:

- Apply patch
- Make sure that you have defined an active currency in
  Home > Administration > Currency & Exchange rates
- Search for Syspref 'Currency Format'
- Select a formatting pattern from the drop down list
- Go to a page that uses Price formatting and verify
  that currency symbol displays wheere price formatting
  is applied (git grep '| $Price')

(Amended patch to remove example opac-user.tt. To test with
OPAC see bug 15374)

Signed-off-by: Aleisha 

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-21 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

  Attachment #43320|0   |1
is obsolete||

--- Comment #17 from Marc Véron  ---
Created attachment 45877
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45877=edit
Bug 4078 - Display active currency symbol on currency output and input

Display active currency using international formatting patterns and active
currency symbol withplugin price.

To test:

Without patch:

- Go to 'Your summary'. The amount appears in the tab 'Credits'rsp. 'Fines'
- Apply patch
- Make sure that you have defined an active currency in
  Home > Administration > Currency & Exchange rates
- Search for Syspref 'Currency Format'
- Select a formatting pattern from the drop down list
- Go to a page that uses Price formatting and verify
  that currency symbol displays wheere price formatting
  is applied (git grep '| $Price')

(Amended patch to remove example opac-user.tt. To test with
OPAC see bug 15374)

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-21 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

  Attachment #45877|0   |1
is obsolete||

--- Comment #18 from Marc Véron  ---
Created attachment 45878
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45878=edit
Bug 4078 - Display active currency symbol on currency output and input

Display active currency using international formatting patterns and active
currency symbol withplugin price.

To test:

- Apply patch
- Make sure that you have defined an active currency in
  Home > Administration > Currency & Exchange rates
- Search for Syspref 'Currency Format'
- Select a formatting pattern from the drop down list
- Go to a page that uses Price formatting and verify
  that currency symbol displays wheere price formatting
  is applied (git grep '| $Price')

(Amended patch to remove example opac-user.tt. To test with
OPAC see bug 15374)

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-20 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

   See Also||http://bugs.koha-community.
   ||org/bugzilla3/show_bug.cgi?
   ||id=15374

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-08 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #16 from Marc Véron  ---
Still applies.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-01 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

 Depends on|12979   |

--- Comment #14 from Marc Véron  ---
Still applies.
Removed 12979 as blocking (12979 is pushed to Master).


Referenced Bugs:

http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12979
[Bug 12979] Price formatting should only be defined at one place
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-12-01 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Jonathan Druart  changed:

   What|Removed |Added

 Depends on||12979

--- Comment #15 from Jonathan Druart  
---
(In reply to Marc Véron from comment #14)
> Still applies.
> Removed 12979 as blocking (12979 is pushed to Master).

I think it's a good thing to keep the dependencies, even when the patches are
pushed.


Referenced Bugs:

http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12979
[Bug 12979] Price formatting should only be defined at one place
-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-10-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #13 from Jonathan Druart  
---
Note: the symbol should not be displayed by default.
(I have not tested it, but it's a personal note for later).

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-10-10 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

   Severity|trivial |enhancement
   Patch complexity|--- |Small patch
   Assignee|oleon...@myacpl.org |ve...@veron.ch

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-10-10 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

 Status|ASSIGNED|Needs Signoff

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-10-10 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #12 from Marc Véron  ---
Created attachment 43320
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43320=edit
Bug 4078 - Display active currency symbol on currency output and input

Display active currency using international formatting patterns and active
currency symbol withplugin price.

The patch inlcudes an example on Opac.

To test:

Without patch:
- Log in to the Opac with an user who has credits or fines.
- Go to 'Your summary'. The amount appears in the tab 'Credits'rsp. 'Fines'
- Apply patch
- Make sure that you have defined an active currency in
  Home > Administration > Currency & Exchange rates
- Search for Syspref 'Currency Format'
- Select a formatting pattern from the drop down list
- Go back to the Opac and verify that the amount is properly formatted,
  including the position of the currency symbol.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-10-10 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron  changed:

   What|Removed |Added

   Attachment #7308|0   |1
is obsolete||

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2015-02-20 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Jonathan Druart jonathan.dru...@biblibre.com changed:

   What|Removed |Added

 Depends on||12979
 CC||jonathan.dru...@biblibre.co
   ||m
 Status|In Discussion   |ASSIGNED
   Assignee|ale...@vujicic.com  |oleon...@myacpl.org

--- Comment #11 from Jonathan Druart jonathan.dru...@biblibre.com ---
Should be done on top of bug 12979, see Koha::Number::Price.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #7 from Paul Poulain paul.poul...@biblibre.com ---
(In reply to comment #4)
 I propose to expand this functionality to the formatting of currency values
 as well.
Marc, when you say that you propose does it mean that you'll submit a patch ?
Or you propose to go this way (and I agree), and hope someone else will write a
patch.

Aleksa = we have no feedback from you !

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Chris Cormack ch...@bigballofwax.co.nz changed:

   What|Removed |Added

 CC||ch...@bigballofwax.co.nz

--- Comment #8 from Chris Cormack ch...@bigballofwax.co.nz ---
Aleksa was a high school student doing some work on the school holidays. He may
time and/or the desire to work on this again. But to expect him to leap in and
make a template::toolkit plugin is a pretty big ask for a high school kid.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #9 from Marc Véron ve...@veron.ch ---
Paul,

If everybody agrees with my proposition I can try to submit a patch within the
next weeks.

However I would like to try first with some smaller issue, just to find out how
to patch.

Marc

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #10 from Paul Poulain paul.poul...@biblibre.com ---
(In reply to comment #9)
 Paul,
 
 If everybody agrees with my proposition I can try to submit a patch within
 the next weeks.
I don't understand why we need a column in currencies table. There is only one
currency displayed, it's the one that has active=1.
When you select a different currency when you enter an amount, it's
transformed, with the rate, to become a currency that has active=1.
So I think the CurrencyFormat should be switched to a formatting display, but
we shouldn't need a column.

 However I would like to try first with some smaller issue, just to find out
 how to patch.
Just in case:

Marc, I see you're from switzerland. Do you know that next week, BibLibre
organize a hackfest in Marseille (France), there will be mbalmer, from
Switzerland too, you're welcomed if you want  can join us (
http://drupal.biblibre.com/en/blog/entry/2012-hackfest-in-europe)

The hackfest would be the perfect place to write your first patches !
just drop me a mail or catch me on IRC for more information if you want

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-06 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #4 from Marc Véron ve...@veron.ch ---
I propose to expand this functionality to the formatting of currency values as
well.

Up to now, formatting is handled via the preference CurrencyFormat. User can
choose between 360,000.00 (US) and 360 000,00 (FR). The preference is evaluated
in a hard coded way in several .pl and .pm files as
acqui-home.pl
aqbudgetperiods.pl
layout2pages.pm
aqplan.pl
aqbudgetperiods.pl
layout3pages.pm
layout2pages.pm
(maybe more)

The code reads:
---Snip---
my $cur_format = C4::Context-preference(CurrencyFormat);
my $num;

if ( $cur_format eq 'US' ) {
$num = new Number::Format(
'int_curr_symbol'   = '',
'mon_thousands_sep' = ',',
'mon_decimal_point' = '.'
);
} elsif ( $cur_format eq 'FR' ) {
$num = new Number::Format(
'decimal_fill'  = '2',
'decimal_point' = ',',
'int_curr_symbol'   = '',
'mon_thousands_sep' = ' ',
'thousands_sep' = ' ',
'mon_decimal_point' = ','
);
}
---Snip---


To make things more configurable I propose to do the following:

1) 
Expand table currency (http://schema.koha-community.org/tables/currency.html)
with an additional column format

This column could be pre-filled by system_preferences.sql, and it should be
editable (/admin/currency.pl). 
Maybe some input validation is necessary to get well formed strings.

2)
Remove preference CurrencyFormat (not longer used)

3)
The sub GetCurrency()(located in Budgets.pm) will return the currency format
string along with the currency symbol. No chnges needed (Select *)

Use GetCurrency()-{format} in sub filter and format the number as appropriate.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-06 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Katrin Fischer katrin.fisc...@bsz-bw.de changed:

   What|Removed |Added

 CC||katrin.fisc...@bsz-bw.de

--- Comment #5 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Hi Marc,
I agree with 1) and 2) - not sure I get 3). I would really like to see a new TT
plugin doing the formatting on template level. Then we could start stepping
through the code and making it show correctly everywhere. 
Do we need to distinguish between active currency and other currency display? I
think later is only needed in acquisitions.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-06 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

--- Comment #6 from Marc Véron ve...@veron.ch ---
Hi Katrin,

I expect that GetCurrency() would be used in a context like proposed by Paul
Poluain in Comment 3, i.e. it would be the template that does the formatting.

GetCurency() returns an aray resulting form a select * statement, you simply
could use $active_currency-{format} along with the existing
$active_currency-{currency}

The same with the result of GetCurrencies()
(but it seems that it is currently only used to get the rates).

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-03-05 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Marc Véron ve...@veron.ch changed:

   What|Removed |Added

 CC||ve...@veron.ch

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-02-21 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Paul Poulain paul.poul...@biblibre.com changed:

   What|Removed |Added

 CC||paul.poul...@biblibre.com

--- Comment #3 from Paul Poulain paul.poul...@biblibre.com 2012-02-21 
13:31:05 UTC ---
Hi Aleksa,

The more I look at your patch, the more I think it's the *perfect* candidate
for Template::Toolkit plugins.
Something similar to what has been made for displaying dates:
see : http://wiki.koha-community.org/wiki/Coding_Guidelines#Displaying_dates

Look at Koha/Template/Plugin/KohaDates/KohaDates.pm, create a KohaCurrencies.pm
that could be (untested)

use Template::Plugin::Filter;
use base qw( Template::Plugin::Filter );

use C4::Dates;

sub filter {
my ($self,$amount) = @_;
my $curr_symbol = GetCurrency()-{symbol};
if ($curr_symbol  $amount) {
if ($amount =~ /^\-/) {
$amount =~ s/^\-/\-$curr_symbol/;
} else {
$amount = $curr_symbol.$amount;
}
}
return $amount;
}

and just update all template to display currencies:
[% USE KohaCurrencies %]

and
[% totspent | $KohaCurrencies %] 
...

thanks for your feedback on this
1;

-- 
Configure bugmail: 
http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-02-07 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Ian Walls koha.sek...@gmail.com changed:

   What|Removed |Added

 Status|Needs Signoff   |In Discussion
 CC||koha.sek...@gmail.com

--- Comment #2 from Ian Walls koha.sek...@gmail.com 2012-02-07 15:52:32 UTC 
---
It seems to me that currency formatting is much the same as date formatting,
and as such should be handled by a T:T plugin.  Koha passes the raw numeric
values to the template, and the template formats the currency as appropriate.

-- 
Configure bugmail: 
http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 4078] Display active currency symbol on currency output and input

2012-01-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4078

Aleksa ale...@catalyst.net.nz changed:

   What|Removed |Added

 Status|ASSIGNED|Needs Signoff
 AssignedTo|oleon...@myacpl.org |ale...@catalyst.net.nz

--- Comment #1 from Aleksa ale...@catalyst.net.nz 2012-01-24 01:24:57 UTC ---
Created attachment 7308
  -- http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=7308
Added a sub that places currency symbol. Added to most prices.

I've called this sub on as many prices as I could find. However there still
might be a few that I've missed.

This can be seen on /cgi-bin/koha/members/boraccount.pl

-- 
Configure bugmail: 
http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/