• Welcome to KonaKart Community Forum. Please login or sign up.
 

Admin Currency

Started by Mike, April 30, 2008, 10:15:58 am

Previous topic - Next topic

Mike

I'm new to Konakart so I've probably missed something obvious.

I want to switch the default currency to GBP so:

1. I created a new currency

2. I set that currency to be the default

3. I restarted Tomcat (Konakart server)

4. I restarted my browser

As soon as I try to view any of my existing products in the Admin Web App I get a stack trace in Tomcat:

30-Apr 10:05:54 INFO  (?:<init>:?) Engine used by application is com.konakart.
p.KKEng
java.lang.StringIndexOutOfBoundsException: String index out of range: 0
        at java.lang.String.charAt(Unknown Source)
        at com.konakart.al.KKAppEng.getFormatter(Unknown Source)
        at com.konakart.al.KKAppEng.setupCurrency(Unknown Source)
        at com.konakart.al.KKAppEng.<init>(Unknown Source)
        at com.konakart.al.ConfigCacheUpdater.getClientEng(Unknown Source)
        at com.konakart.al.ConfigCacheUpdater.updateConfigs(Unknown Source)
        at com.konakart.al.ConfigCacheUpdater.run(Unknown Source)

Looks to me as if something is trying to get a format string for the language and failing.

Any help would be great (this is one of those times when the source code would be valuable!).

Regards

Mike

PS: As long as I can get over these minor glitches, I will be much happier supplying Konakart to my customers than oscommerce. Great job.

Mike

I've fixed it!

I did not want to use a comma as the thousands separator (nasty American idea) so set the separator to a space. This was presumably getting trimmed to an empty string by your DB code. Then in getFormatter, something was presumably searching the thousands separator string which was zero length.

Cheers.

ming

Hi Mike,

I suspect that you haven't defined a decimal point or a 1000s separator for your new GBP currency.

Please check that in the Admin App and try again!

The problem is in the client engine which mistakenly assumes that the above two will be set... They would normally be set for every currency I can think of at the moment, but still, we'll make the code more robust in this area in the next release.

Regards,
Ming