Add EUR to the cash app and demobench tool. Authored by Frederic Dalibard.

This commit is contained in:
FredericDalibard 2017-05-27 14:40:01 +02:00 committed by Mike Hearn
parent 9e5b469bde
commit d76c23824e
3 changed files with 5 additions and 7 deletions

View File

@ -4,4 +4,5 @@ corda.interest_rates
corda.issuer.USD
corda.issuer.GBP
corda.issuer.CHF
corda.issuer.EUR
corda.cash

View File

@ -10,7 +10,7 @@ import net.corda.core.contracts.currency
import net.corda.core.node.NodeInfo
import tornadofx.*
val ISSUER_SERVICE_TYPE = Regex("corda.issuer.(USD|GBP|CHF)")
val ISSUER_SERVICE_TYPE = Regex("corda.issuer.(USD|GBP|CHF|EUR)")
class IssuerModel {
private val networkIdentities by observableList(NetworkIdentityModel::networkIdentities)
@ -37,4 +37,4 @@ class IssuerModel {
currency(issuer.info.type.id.substringAfterLast("."))
} else
null
}
}

View File

@ -5,10 +5,7 @@ import net.corda.client.jfx.model.ExchangeRate
import net.corda.client.jfx.model.ExchangeRateModel
import net.corda.client.jfx.model.observableValue
import net.corda.client.jfx.utils.AmountBindings
import net.corda.core.contracts.Amount
import net.corda.core.contracts.CHF
import net.corda.core.contracts.GBP
import net.corda.core.contracts.USD
import net.corda.core.contracts.*
import org.fxmisc.easybind.EasyBind
import tornadofx.*
import java.util.*
@ -16,7 +13,7 @@ import java.util.*
class ReportingCurrencyModel {
private val exchangeRate: ObservableValue<ExchangeRate> by observableValue(ExchangeRateModel::exchangeRate)
val reportingCurrency by observableValue(SettingsModel::reportingCurrencyProperty)
val supportedCurrencies = setOf(USD, GBP, CHF).toList().observable()
val supportedCurrencies = setOf(USD, GBP, CHF, EUR).toList().observable()
/**
* This stream provides a stream of exchange() functions that updates when either the reporting currency or the