Merge pull request #1609 from CrypticaScriptura/xcd-release816

fix: display XCD, remove non-currencies and filter
This commit is contained in:
Rafael Taranto 2023-10-19 19:54:38 +01:00 committed by GitHub
commit 53dc825210
5 changed files with 14 additions and 156 deletions

View file

@ -2419,158 +2419,5 @@
"Minor unit": 2, "Minor unit": 2,
"Fund": "", "Fund": "",
"": "" "": ""
},
{
"ENTITY": "ZZ01_Bond Markets Unit European_EURCO",
"Currency": "Bond Markets Unit European Composite Unit (EURCO)",
"Alphabetic Code": "XBA",
"Numeric Code": 955,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ02_Bond Markets Unit European_EMU-6",
"Currency": "Bond Markets Unit European Monetary Unit (E.M.U.-6)",
"Alphabetic Code": "XBB",
"Numeric Code": 956,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ03_Bond Markets Unit European_EUA-9",
"Currency": "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)",
"Alphabetic Code": "XBC",
"Numeric Code": 957,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ04_Bond Markets Unit European_EUA-17",
"Currency": "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)",
"Alphabetic Code": "XBD",
"Numeric Code": 958,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ06_Testing_Code",
"Currency": "Codes specifically reserved for testing purposes",
"Alphabetic Code": "XTS",
"Numeric Code": 963,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ07_No_Currency",
"Currency": "The codes assigned for transactions where no currency is involved",
"Alphabetic Code": "XXX",
"Numeric Code": 999,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ08_Gold",
"Currency": "Gold",
"Alphabetic Code": "XAU",
"Numeric Code": 959,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ09_Palladium",
"Currency": "Palladium",
"Alphabetic Code": "XPD",
"Numeric Code": 964,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ10_Platinum",
"Currency": "Platinum",
"Alphabetic Code": "XPT",
"Numeric Code": 962,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "ZZ11_Silver",
"Currency": "Silver",
"Alphabetic Code": "XAG",
"Numeric Code": 961,
"Minor unit": "N.A.",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
},
{
"ENTITY": "",
"Currency": "",
"Alphabetic Code": "",
"Numeric Code": "",
"Minor unit": "",
"Fund": "",
"": ""
} }
] ]

View file

@ -17,7 +17,7 @@ function massageCurrencies (currencies) {
const codeToRec = code => _.find(_.matchesProperty('code', code), mapped) const codeToRec = code => _.find(_.matchesProperty('code', code), mapped)
const top5 = _.map(codeToRec, top5Codes) const top5 = _.map(codeToRec, top5Codes)
const raw = _.uniqBy(_.get('code'), _.concat(top5, mapped)) const raw = _.uniqBy(_.get('code'), _.concat(top5, mapped))
return raw.filter(r => r.code !== '' && r.code[0] !== 'X' && r.display.indexOf('(') === -1) return raw.filter(r => r.code !== '' && r.display.indexOf('(') === -1)
} }
const mapLanguage = lang => { const mapLanguage = lang => {

View file

@ -408,6 +408,17 @@ export default {
}, },
polymer: false polymer: false
}, },
XCD: {
thickness: 0x0c,
lengths: {
5: [0x9b, 0x87],
10: [0x9b, 0x87],
20: [0x9b, 0x87],
50: [0x9b, 0x87],
100: [0x9b, 0x87]
},
polymer: true
},
ZAR: { ZAR: {
thickness: 0x0c, thickness: 0x0c,
lengths: { lengths: {

2
package-lock.json generated
View file

@ -1,6 +1,6 @@
{ {
"name": "lamassu-server", "name": "lamassu-server",
"version": "8.1.5-1", "version": "8.1.6",
"lockfileVersion": 1, "lockfileVersion": 1,
"requires": true, "requires": true,
"dependencies": { "dependencies": {

View file

@ -2,7 +2,7 @@
"name": "lamassu-server", "name": "lamassu-server",
"description": "bitcoin atm client server protocol module", "description": "bitcoin atm client server protocol module",
"keywords": [], "keywords": [],
"version": "8.1.5-1", "version": "8.1.6",
"license": "Unlicense", "license": "Unlicense",
"author": "Lamassu (https://lamassu.is)", "author": "Lamassu (https://lamassu.is)",
"dependencies": { "dependencies": {