Setting up currencies

From Catglobe Wiki
Jump to: navigation, search



Setting up currencies

The only way to set up currencies in catglobe is directly on the database. Depending on how you wish to manage currencies you can either update them manually when necessary or you can integrate the currency table with an external provider of exchange rates.

The columns that exist on the currency table are

Id: This column will automatically update when other values are inserted.

Name: Here you specify the short name of the currency, e.g. "USD" and is the name mostly used in the GUI of the system to identify the currency an amount is shown in. Here you are adviced to use the alphabetic ISO currency code.

Description: This field is for the long name of the currency, e.g. "US Dollar".

Default: This value states the default currency. Remember that there must be one and no more than one default currency. The default currency should NEVER be changed. Once a site has started using the web shop and a default currency is established then it will have serious consequences if the default currency is changed.

Exchange_Rate: This is the exchange rate of a currency compared to the default currency. The exchange rate of the default currency must always be "1" since it obviously will give 1 to 1 of it's own currency. An example of an exchange rate where USD is the default currency is "119" for Japanese YEN, meaning that 1 usd is worth 119 yen.

Decimal_Places: This shows how many decimals the currency is normally displayed with. USD is normally displayed with 2 decimals, whereas YEN is normally displayed with 0 decimals. This helps the system know how to show calculated amounts that may have many decimals, but where the user will expect only a certain number of decimals.

Currency_Code: This is the numeric code of currencies. Please look at the following link for more information: http://en.wikipedia.org/wiki/ISO_4217