Browse Source

update 共富制度

tags/v1.2.6
DengBiao 2 years ago
parent
commit
cef736008d
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      rule/public_platoon_relate_commission.go

+ 2
- 2
rule/public_platoon_relate_commission.go View File

@@ -260,7 +260,7 @@ func reverseDeductionPosition(calcPosition, levelFirstPosition, severalTimes int
// getLevelForFirstPosition 返回当前等级的起始值 // getLevelForFirstPosition 返回当前等级的起始值
func getLevelForFirstPosition(level, severalTimes int) (position int) { func getLevelForFirstPosition(level, severalTimes int) (position int) {
position = position + 1 position = position + 1
for n := 1; n <= (level - 2); n++ {
for n := 0; n <= (level - 2); n++ {
position += int(math.Pow(float64(severalTimes), float64(n))) position += int(math.Pow(float64(severalTimes), float64(n)))
} }
return return
@@ -268,7 +268,7 @@ func getLevelForFirstPosition(level, severalTimes int) (position int) {


// getLevelForLastPosition 每个等级的结束值 // getLevelForLastPosition 每个等级的结束值
func getLevelForLastPosition(level, severalTimes int) (position int) { func getLevelForLastPosition(level, severalTimes int) (position int) {
for n := 1; n <= (level - 1); n++ {
for n := 0; n <= (level - 1); n++ {
position += int(math.Pow(float64(severalTimes), float64(n))) position += int(math.Pow(float64(severalTimes), float64(n)))
} }
return return


Loading…
Cancel
Save