#Help creating new currency

6 messages · Page 1 of 1 (latest)

coarse birch
#

My country's currency (Maldivian Rufiyaa) was not in the default list so I created it by running a database migration.

It's successfully created but when I try setting the price for that currency on a product variant, I get a client side type error:
Cannot read properties of undefined (reading 'decimal_digits')

I understand that's because it's trying to find that info from the client. I don't know where to put it. I tried to follow the docs here:
https://docs.medusajs.com/modules/regions-and-currencies/currencies#how-currencies-are-created

However, utils/currencies.js mentioned there do not exist in my project. I created that file and added the currency info, but it's not helping.

Can someone tell me what I'm missing here?

misty stag
coarse birch
coarse birch
#

Update: It looks like the admin ui uses it's own currencies.ts file from the node_modules.

quaint charm
# coarse birch Update: It looks like the admin ui uses it's own currencies.ts file from the nod...

hello @coarse birch , there is an open issue here to add currencies to the UI more easily. Feel free to weight in so it gets prioritized ! https://github.com/medusajs/medusa/issues/4907

GitHub

Bug report Describe the bug We are using medusa for an internal company store, where users are assigned points to shop for, rather than using real money. Instead of using one of the built in curren...

coarse birch