上传错误码修复异常
This commit is contained in:
parent
460a614dfa
commit
24067fdc01
@ -136,12 +136,16 @@ func (this *Buried) ActiveCondition(uid string, condiIds ...int32) (err error) {
|
||||
//激活数据采集点
|
||||
func (this *Buried) CheckCondition(uid string, condiIds ...int32) (condis []*pb.ConIProgress, err error) {
|
||||
var (
|
||||
model *buriedModel
|
||||
bdatas *pb.DBBuried
|
||||
conf *cfg.GameBuriedCondiData
|
||||
bdata *pb.DBBuriedItem
|
||||
ok bool
|
||||
)
|
||||
if bdatas, err = this.modelBuried.getUserBurieds(uid); err != nil {
|
||||
if model, err = this.modelBuried.getburiedModel(uid); err != nil {
|
||||
return
|
||||
}
|
||||
if bdatas, err = model.getUserBurieds(uid); err != nil {
|
||||
return
|
||||
}
|
||||
condis = make([]*pb.ConIProgress, 0)
|
||||
@ -194,6 +198,7 @@ func (this *Buried) CheckCondition(uid string, condiIds ...int32) (condis []*pb.
|
||||
//设置任务完成状态并校验
|
||||
func (this *Buried) FinishConditionAndCheck(uid string, finishcondiIds []int32, condiIds ...int32) (condis []*pb.ConIProgress, err error) {
|
||||
var (
|
||||
model *buriedModel
|
||||
bdatas *pb.DBBuried
|
||||
bitem *pb.DBBuriedConItem
|
||||
conf *cfg.GameBuriedCondiData
|
||||
@ -201,7 +206,11 @@ func (this *Buried) FinishConditionAndCheck(uid string, finishcondiIds []int32,
|
||||
chanage bool
|
||||
bdata *pb.DBBuriedItem
|
||||
)
|
||||
if bdatas, err = this.modelBuried.getUserBurieds(uid); err != nil {
|
||||
|
||||
if model, err = this.modelBuried.getburiedModel(uid); err != nil {
|
||||
return
|
||||
}
|
||||
if bdatas, err = model.getUserBurieds(uid); err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
@ -323,7 +332,7 @@ func (this *Buried) FinishConditionAndCheck(uid string, finishcondiIds []int32,
|
||||
}
|
||||
|
||||
if chanage {
|
||||
if err = this.modelBuried.updateUserBurieds(uid, bdatas); err != nil {
|
||||
if err = model.updateUserBurieds(uid, bdatas); err != nil {
|
||||
this.Error("更新用户埋点数据错误!", log.Field{Key: "err", Value: err.Error()})
|
||||
return
|
||||
}
|
||||
|
@ -491,7 +491,7 @@ func (this *Equipment) GetForgeEquip(session comm.IUserSession, suiteId int32, p
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_ConfigNoFound,
|
||||
Title: pb.ErrorCode_ConfigNoFound.ToString(),
|
||||
Message: err.Error(),
|
||||
Message: fmt.Sprintf("no fond pos:%d intlv:%d", pos, lv),
|
||||
}
|
||||
return
|
||||
} else {
|
||||
|
@ -112,9 +112,8 @@ func (this *apiComp) Buy(session comm.IUserSession, req *pb.ShopBuyReq) (errdata
|
||||
}
|
||||
if conf.Buyminnum-record.Buy[req.GoodsId] < req.BuyNum {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_ShopGoodsIsSoldOut,
|
||||
Title: pb.ErrorCode_ShopGoodsIsSoldOut.ToString(),
|
||||
Message: err.Error(),
|
||||
Code: pb.ErrorCode_ShopGoodsIsSoldOut,
|
||||
Title: pb.ErrorCode_ShopGoodsIsSoldOut.ToString(),
|
||||
}
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user