Ver a proveniência

升级

master
huangjiajun há 1 semana
ascendente
cometimento
4ec100c869
1 ficheiros alterados com 2 adições e 2 eliminações
  1. +2
    -2
      rule/user_upgrade.go

+ 2
- 2
rule/user_upgrade.go Ver ficheiro

@@ -106,7 +106,7 @@ func UserUpgradeTask(eg *xorm.Engine, uid, lv int) ([]map[string]string, error)
"is_success": utils.IntToStr(isSuccess),
}
taskList = append(taskList, tmp)
if isSuccess == 1 || v.IsMustTask == 0 { //记录选做任务数量
if isSuccess == 1 && v.IsMustTask == 0 { //记录选做任务数量
chooseNum++
}
if isSuccess == 0 && v.IsMustTask == 1 { //必做任务未完成
@@ -116,7 +116,7 @@ func UserUpgradeTask(eg *xorm.Engine, uid, lv int) ([]map[string]string, error)
if mustTaskErr == 1 {
return taskList, errors.New("必做任务未完成")
}
if level.ChoosableNum > chooseNum { //选做任务未完成
if chooseNum < level.ChoosableNum { //选做任务未完成
return taskList, errors.New("选择任务未完成")
}
return taskList, nil


Carregando…
Cancelar
Guardar