Browse Source

更新

tags/v4.3.1
huangjiajun 1 year ago
parent
commit
25f9a24f0b
1 changed files with 5 additions and 4 deletions
  1. +5
    -4
      lib/comm_plan/all.go

+ 5
- 4
lib/comm_plan/all.go View File

@@ -824,13 +824,14 @@ func GetSubsidyVirtualCoinAmount(ratio, moneyRate, typ string, fee, sysFee float
// 计算佣金、虚拟币额度
func getCoinAmount(ratio string, coinId int, fee float64, rateList map[int]string) (amount float64) {
moneyRate, ok := rateList[coinId]
if !ok {
amount = 0.00
return
}

if coinId == 0 { // 金额
amount = fee * zhios_order_relate_utils.StrToFloat64(ratio)
} else { // 虚拟币 需要将金额按设置的比例兑换成虚拟币 这里不乘比例了 会影响后面的极差
if !ok {
amount = 0.00
return
}
//amount = fee * zhios_order_relate_utils.AnyToFloat64(moneyRate) * zhios_order_relate_utils.StrToFloat64(ratio)
amount = fee * zhios_order_relate_utils.AnyToFloat64(moneyRate)
}


Loading…
Cancel
Save