Bläddra i källkod

更新

master
huangjiajun 1 år sedan
förälder
incheckning
0198ed7513
2 ändrade filer med 8 tillägg och 6 borttagningar
  1. +7
    -6
      md/appreciation.go
  2. +1
    -0
      rule/appreciation.go

+ 7
- 6
md/appreciation.go Visa fil

@@ -3,19 +3,20 @@ package md
import "github.com/shopspring/decimal"

var (
WithdrawalCommissionFee = decimal.NewFromFloat(0.15) //提现比例 扣了手续费的
WithdrawalCommissionFee = decimal.NewFromFloat(0.15) //提现手续费比例
WithdrawalDestroyFee = decimal.NewFromFloat(0.05) //提现销毁增值积分比例
WithdrawalRefluxFee = decimal.NewFromFloat(0.10) //提现回流增值积分比例
)

type DealWithdrawalAndDestroyResp struct {
TransferOut float64 `json:"transfer_out"`
AmountOut float64 `json:"amount_out"`
DestroyValue float64 `json:"destroy_value"`
RefluxValue float64 `json:"reflux_value"`
TransferOut float64 `json:"transfer_out"` //提现的积分
TransferOutValue float64 `json:"transfer_out_value"` //提现的余额
AmountOut float64 `json:"amount_out"` //手续费
DestroyValue float64 `json:"destroy_value"` //销毁的积分
RefluxValue float64 `json:"reflux_value"` //回流的积分
}
type DealWithdrawalFeeResp struct {
WithdrawalCommissionFee float64 `json:"withdrawal_commission_fee"` //提现比例 扣了手续费的
WithdrawalCommissionFee float64 `json:"withdrawal_commission_fee"` //提现手续费比例
WithdrawalDestroyFee float64 `json:"withdrawal_destroy_fee"` //提现销毁增值积分比例
WithdrawalRefluxFee float64 `json:"withdrawal_reflux_fee"` //提现回流增值积分比例
}

+ 1
- 0
rule/appreciation.go Visa fil

@@ -63,6 +63,7 @@ func DealWithdrawalAndDestroy(session *xorm.Session, feeMap md.DealWithdrawalFee
return
}
resp.TransferOut = transferOut
resp.TransferOutValue, _ = decimal.NewFromFloat(transferOut).Mul(decimal.NewFromFloat(nowValue)).Float64()
resp.AmountOut, _ = transferOutValue.Mul(decimal.NewFromFloat(nowValue)).Float64()
resp.DestroyValue, _ = destroyValue.Float64()
resp.RefluxValue, _ = refluxValue.Float64()


Laddar…
Avbryt
Spara