Provide your user with a dashboard that fits his local settings and input data by dynamically overriding which currency symbol is displayed on the dashboard!
You only need to create a template dashboard! Specify which columns of your dataset are currencies, and assign a default currency to it, as explained here. You can then override the currency displayed when requesting an embed authorization token for a specific user.
It is very easy, simply specify the currency that should be displayed as an ISO 4217 currency code when requesting an embed authorization token. An example can be found in the following API call, which returns an embed authorization token that can be used in your frontend to embed template dashboards with an overridden currency:
const Luzmo = require('@luzmo/nodejs-sdk');
var client = new Luzmo({
api_key: '< Your API key >',
api_token: '< Your API token >'
});
let promise = client.create('authorization', {
type: 'embed',
access: {
collections: [
{
id: '<collection ID>',
inheritRights: 'use'
}
]
},
username: '12345678',
suborganization: 'Burrito Co.',
name: 'Embed user',
email : 'embed_user@luzmo.com',
currency_id: 'EUR'
}).then((result) => {
/* The temporary embed authorization key and token can be found in result.id and result.token, respectively. */
console.log(result);
});
As you can see, it is as easy as specifying the currency_id property and providing the currency that should be displayed!
Please note that this is just overriding the currency symbol displayed, and does not apply any currency conversion to the underlying data. For example, if a chart which displays $100.00 by default is overridden to display pounds, it will display £100.00.