增加国库模式eth的价格返回
This commit is contained in:
parent
804d1883a9
commit
025132ac5c
@ -112,11 +112,15 @@ class AlchemyOutController extends BaseController {
|
|||||||
let gas = await new GasSvr().estimateGas({ crypto, network: 'ARBITRUM' })
|
let gas = await new GasSvr().estimateGas({ crypto, network: 'ARBITRUM' })
|
||||||
gas = gas * 0.0000000001
|
gas = gas * 0.0000000001
|
||||||
let price = await new PriceSvr().fetchPrice({ crypto: 'ETH', network: 'ARBITRUM', fiat: 'USD' })
|
let price = await new PriceSvr().fetchPrice({ crypto: 'ETH', network: 'ARBITRUM', fiat: 'USD' })
|
||||||
|
let priceToSend = '0.1'
|
||||||
|
if (crypto.toLowerCase() === 'eth') {
|
||||||
|
priceToSend = price + ''
|
||||||
|
}
|
||||||
let networkFee = gas * parseFloat(price)
|
let networkFee = gas * parseFloat(price)
|
||||||
let result = {
|
let result = {
|
||||||
direct: 1,
|
direct: 1,
|
||||||
data: {
|
data: {
|
||||||
price: '0.1',
|
price: priceToSend,
|
||||||
networkList: [
|
networkList: [
|
||||||
{
|
{
|
||||||
network: 'ARBITRUM',
|
network: 'ARBITRUM',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user