活动优化
This commit is contained in:
parent
dc3039dad9
commit
6828f035aa
@ -518,8 +518,8 @@ const ( //Rpc
|
|||||||
|
|
||||||
Rpc_Activity core.Rpc_Key = "Rpc_Activity"
|
Rpc_Activity core.Rpc_Key = "Rpc_Activity"
|
||||||
|
|
||||||
Rpc_ActivityOver core.Rpc_Key = "Rpc_ActivityOver" //活动结束
|
Rpc_ActivityOver core.Rpc_Key = "Rpc_ActivityOver" //活动结束
|
||||||
Rpc_ActivityStar core.Rpc_Key = "Rpc_ActivityStar" //活动开启
|
Rpc_ActivityStart core.Rpc_Key = "Rpc_ActivityStart" //活动开启
|
||||||
|
|
||||||
RPC_XXLOffLine core.Rpc_Key = "RPC_XXLOffLine" //三消离线
|
RPC_XXLOffLine core.Rpc_Key = "RPC_XXLOffLine" //三消离线
|
||||||
|
|
||||||
|
@ -586,10 +586,8 @@ type (
|
|||||||
}
|
}
|
||||||
|
|
||||||
IActivity interface {
|
IActivity interface {
|
||||||
GetHdInfoByHdId(oid string) (result *pb.DBHuodong, err error) // 通过活动id 获取活动信息
|
|
||||||
GetAllHdInfo() (hdList map[pb.HdType]*pb.DBHuodong) // 获取所有活动信息
|
GetAllHdInfo() (hdList map[pb.HdType]*pb.DBHuodong) // 获取所有活动信息
|
||||||
GetHdInfoByItype(itype pb.HdType) (result *pb.DBHuodong, err error) //
|
GetHdInfoByItype(itype pb.HdType) (result *pb.DBHuodong, err error) //
|
||||||
|
|
||||||
// 庆典活动
|
// 庆典活动
|
||||||
HDCelebration(session IUserSession, systemtype int32, bosstype int32) bool
|
HDCelebration(session IUserSession, systemtype int32, bosstype int32) bool
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@ func (this *apiComp) GetHdDataCheck(session comm.IUserSession, req *pb.ActivityG
|
|||||||
// 活动活动
|
// 活动活动
|
||||||
func (this *apiComp) GetHdData(session comm.IUserSession, req *pb.ActivityGetHdDataReq) (errdata *pb.ErrorData) {
|
func (this *apiComp) GetHdData(session comm.IUserSession, req *pb.ActivityGetHdDataReq) (errdata *pb.ErrorData) {
|
||||||
|
|
||||||
result := this.module.GetHdData(session, req.Oid)
|
result := this.module.GetHdData(session, req.Oid) // 不用
|
||||||
session.SendMsg(string(this.module.GetType()), "gethddata", &pb.ActivityGetHdDataResp{
|
session.SendMsg(string(this.module.GetType()), "gethddata", &pb.ActivityGetHdDataResp{
|
||||||
Data: result,
|
Data: result,
|
||||||
})
|
})
|
||||||
|
@ -38,6 +38,7 @@ func (this *apiComp) GetReward(session comm.IUserSession, req *pb.ActivityGetRew
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
// 接口需要修改
|
||||||
if activity, err = this.module.modelhdList.getHdListByHdId(req.Oid); err == nil {
|
if activity, err = this.module.modelhdList.getHdListByHdId(req.Oid); err == nil {
|
||||||
curTime := configure.Now().Unix()
|
curTime := configure.Now().Unix()
|
||||||
if activity.Stime > curTime || curTime > activity.Etime { //不在活动时间范围内
|
if activity.Stime > curTime || curTime > activity.Etime { //不在活动时间范围内
|
||||||
|
@ -122,7 +122,7 @@ func (this *Activity) Start() (err error) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.service.RegisterFunctionName(string(comm.Rpc_ActivityOver), this.Rpc_ActivityOver)
|
this.service.RegisterFunctionName(string(comm.Rpc_ActivityOver), this.Rpc_ActivityOver)
|
||||||
this.service.RegisterFunctionName(string(comm.Rpc_ActivityStar), this.Rpc_ActivityStar)
|
this.service.RegisterFunctionName(string(comm.Rpc_ActivityStart), this.Rpc_ActivityStart)
|
||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -197,12 +197,6 @@ func (this *Activity) GetHdInfoByItype(itype pb.HdType) (result *pb.DBHuodong, e
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// 通过活动ID查找
|
|
||||||
func (this *Activity) GetHdInfoByHdId(oid string) (result *pb.DBHuodong, err error) {
|
|
||||||
result, err = this.modelhdList.getHdListByHdId(oid)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
// 统计庆典活动完成情况
|
// 统计庆典活动完成情况
|
||||||
func (this *Activity) HDCelebration(session comm.IUserSession, systemtype int32, bosstype int32) bool {
|
func (this *Activity) HDCelebration(session comm.IUserSession, systemtype int32, bosstype int32) bool {
|
||||||
bDouble := false // 是否开启双倍奖励
|
bDouble := false // 是否开启双倍奖励
|
||||||
@ -296,6 +290,7 @@ func (this *Activity) HDCelebration(session comm.IUserSession, systemtype int32,
|
|||||||
return bDouble
|
return bDouble
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 接口废弃
|
||||||
func (this *Activity) GetHdData(session comm.IUserSession, oids []string) (result []*pb.DBActivityData) {
|
func (this *Activity) GetHdData(session comm.IUserSession, oids []string) (result []*pb.DBActivityData) {
|
||||||
var (
|
var (
|
||||||
activity *pb.DBHuodong
|
activity *pb.DBHuodong
|
||||||
@ -355,9 +350,9 @@ func (this *Activity) GetHdData(session comm.IUserSession, oids []string) (resul
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *Activity) Rpc_Activity(ctx context.Context, args string, reply *pb.EmptyResp) (err error) {
|
func (this *Activity) Rpc_Activity(ctx context.Context, req *pb.RPCGeneralReqA1, reply *pb.EmptyResp) (err error) {
|
||||||
this.Debug("Rpc_ActivityOver",
|
this.Debug("Rpc_Activity",
|
||||||
log.Field{Key: "args", Value: args},
|
log.Field{Key: "args", Value: req.Param1},
|
||||||
)
|
)
|
||||||
this.modelhdList.LoadActivityData()
|
this.modelhdList.LoadActivityData()
|
||||||
return
|
return
|
||||||
@ -405,8 +400,8 @@ func (this *Activity) Rpc_ActivityOver(ctx context.Context, args *pb.RPCGeneralR
|
|||||||
|
|
||||||
// 活动开启通知
|
// 活动开启通知
|
||||||
|
|
||||||
func (this *Activity) Rpc_ActivityStar(ctx context.Context, args *pb.RPCGeneralReqB1, reply *pb.EmptyResp) (err error) {
|
func (this *Activity) Rpc_ActivityStart(ctx context.Context, args *pb.RPCGeneralReqB1, reply *pb.EmptyResp) (err error) {
|
||||||
this.Debug("Rpc_ActivityStar",
|
this.Debug("Rpc_ActivityStart",
|
||||||
log.Field{Key: "args", Value: args.String()},
|
log.Field{Key: "args", Value: args.String()},
|
||||||
)
|
)
|
||||||
var (
|
var (
|
||||||
@ -416,7 +411,7 @@ func (this *Activity) Rpc_ActivityStar(ctx context.Context, args *pb.RPCGeneralR
|
|||||||
|
|
||||||
for _, v := range szOverActivity {
|
for _, v := range szOverActivity {
|
||||||
hd := &pb.DBHuodong{}
|
hd := &pb.DBHuodong{}
|
||||||
if err := this.modelhdList.DB.FindOne(core.SqlTable(this.modelhdList.TableName), bson.M{"_id": v}).Decode(hd); err != nil {
|
if err := this.modelhdList.DB.FindOne(core.SqlTable(this.modelhdList.TableName), bson.M{"_id": v}).Decode(hd); err == nil {
|
||||||
switch hd.Itype {
|
switch hd.Itype {
|
||||||
case pb.HdType_HdTypeWarorder, pb.HdType_SupplyWarOrder, pb.HdType_MoondreamWarOrder:
|
case pb.HdType_HdTypeWarorder, pb.HdType_SupplyWarOrder, pb.HdType_MoondreamWarOrder:
|
||||||
this.warorder.ActivityOpenNotice(hd)
|
this.warorder.ActivityOpenNotice(hd)
|
||||||
@ -443,3 +438,63 @@ func (this *Activity) Rpc_ActivityStar(ctx context.Context, args *pb.RPCGeneralR
|
|||||||
this.Debug("szOverActivity", log.Field{Key: "args", Value: szOverActivity})
|
this.Debug("szOverActivity", log.Field{Key: "args", Value: szOverActivity})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 通过活动类型获取活动信息
|
||||||
|
func (this *Activity) GetHdDataByHdType(session comm.IUserSession, itype pb.HdType) (result []*pb.DBActivityData) {
|
||||||
|
var (
|
||||||
|
activity *pb.DBHuodong
|
||||||
|
err error
|
||||||
|
list *pb.DBActivityData
|
||||||
|
)
|
||||||
|
curTime := configure.Now().Unix()
|
||||||
|
|
||||||
|
if activity, err = this.GetHdInfoByItype(itype); err != nil {
|
||||||
|
this.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if activity.Stime > curTime || curTime > activity.Etime { // 不在活动范围内数据不给活动记录数据
|
||||||
|
return
|
||||||
|
}
|
||||||
|
id := activity.Id
|
||||||
|
list, _ = this.modelhdData.getHddataByOid(session.GetUserId(), id)
|
||||||
|
// 获取开服庆典活动
|
||||||
|
if activity.Itype == pb.HdType_HdCelebration {
|
||||||
|
if list, err = this.modelhdData.getHddataByOid(session.GetUserId(), id); err == nil {
|
||||||
|
if list.Lasttime < configure.Now().Unix() || list.Val == 0 { // 不是今天重置
|
||||||
|
list.Gotarr = make(map[int32]int32)
|
||||||
|
update := make(map[string]interface{})
|
||||||
|
|
||||||
|
update["gotarr"] = list.Gotarr
|
||||||
|
var maxday int32
|
||||||
|
_days := this.configure.GetHDCelebrationData()
|
||||||
|
for _, v := range _days { // 开启循环
|
||||||
|
maxday += v
|
||||||
|
}
|
||||||
|
var pos int32
|
||||||
|
_sub := int32((configure.Now().Unix() - activity.Stime) / (24 * 3600))
|
||||||
|
|
||||||
|
for index, v := range _days {
|
||||||
|
find := false
|
||||||
|
for i := 0; i < int(v); i++ {
|
||||||
|
pos++
|
||||||
|
if _sub%maxday+1 == pos {
|
||||||
|
list.Val = int32(index) + 1 // 计算val 值
|
||||||
|
update["val"] = list.Val
|
||||||
|
find = true
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if find { // 找到剩余的天数
|
||||||
|
list.Lasttime = activity.Stime + int64(_sub+pos%v+1)*24*3600
|
||||||
|
update["lasttime"] = list.Lasttime
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.modelhdData.ModifyActivityList(session.GetUserId(), list.Id, update)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
result = append(result, list)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
@ -21,12 +21,14 @@ import (
|
|||||||
type Activity struct {
|
type Activity struct {
|
||||||
cbase.ModuleBase
|
cbase.ModuleBase
|
||||||
modules.MCompModel
|
modules.MCompModel
|
||||||
service base.IRPCXService
|
service base.IRPCXService
|
||||||
module *Timer
|
module *Timer
|
||||||
cTimerObj *timewheel.Task
|
cTimerObj *timewheel.Task
|
||||||
closeSignal chan struct{}
|
closeSignal chan struct{}
|
||||||
hlock sync.RWMutex
|
hlock sync.RWMutex
|
||||||
activity map[pb.HdType]*pb.DBHuodong
|
curActivity map[pb.HdType]*pb.DBHuodong // 正在进行的活动
|
||||||
|
delActivity map[pb.HdType]*pb.DBHuodong // 已经过期的活动
|
||||||
|
futureActivity map[pb.HdType]*pb.DBHuodong // 即将要开启的活动过期的活动
|
||||||
}
|
}
|
||||||
|
|
||||||
//组件初始化接口
|
//组件初始化接口
|
||||||
@ -71,105 +73,125 @@ func (this *Activity) Start() (err error) {
|
|||||||
|
|
||||||
func (this *Activity) LoadActivityData(id string) {
|
func (this *Activity) LoadActivityData(id string) {
|
||||||
if id == "" { // 查所有的
|
if id == "" { // 查所有的
|
||||||
if c, err := this.DB.Find(core.SqlTable(this.TableName), bson.M{}); err != nil {
|
if c, err := this.DB.Find(core.SqlTable(this.TableName), bson.M{}); err == nil {
|
||||||
return
|
var (
|
||||||
} else {
|
szEnd []string // 活动结束
|
||||||
|
szStart []string // 有活动开启
|
||||||
|
)
|
||||||
this.hlock.Lock()
|
this.hlock.Lock()
|
||||||
|
this.curActivity = make(map[pb.HdType]*pb.DBHuodong)
|
||||||
|
this.delActivity = make(map[pb.HdType]*pb.DBHuodong)
|
||||||
|
this.futureActivity = make(map[pb.HdType]*pb.DBHuodong)
|
||||||
defer this.hlock.Unlock()
|
defer this.hlock.Unlock()
|
||||||
this.activity = make(map[pb.HdType]*pb.DBHuodong)
|
|
||||||
for c.Next(context.Background()) {
|
for c.Next(context.Background()) {
|
||||||
hd := &pb.DBHuodong{}
|
hd := &pb.DBHuodong{}
|
||||||
if err = c.Decode(hd); err != nil {
|
if err = c.Decode(hd); err != nil {
|
||||||
this.module.Errorf("err:%v", err)
|
this.module.Errorf("err:%v", err)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
this.activity[hd.Itype] = hd
|
if hd.Etime <= configure.Now().Unix() {
|
||||||
|
this.delActivity[hd.Itype] = hd
|
||||||
|
szEnd = append(szEnd, hd.Id)
|
||||||
|
} else if hd.Etime > configure.Now().Unix() && hd.Stime < configure.Now().Unix() {
|
||||||
|
this.curActivity[hd.Itype] = hd
|
||||||
|
szStart = append(szStart, hd.Id)
|
||||||
|
} else {
|
||||||
|
this.futureActivity[hd.Itype] = hd
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if len(szEnd) > 0 {
|
||||||
|
this.NotifyActivityOver(szEnd)
|
||||||
|
}
|
||||||
|
if len(szStart) > 0 {
|
||||||
|
this.NotifyActivityStart(szStart)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
var hd *pb.DBHuodong
|
var hd *pb.DBHuodong
|
||||||
this.DB.FindOne(core.SqlTable(this.TableName), bson.M{"_id": id}).Decode(&hd)
|
if err := this.DB.FindOne(core.SqlTable(this.TableName), bson.M{"_id": id}).Decode(&hd); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if hd.Etime <= configure.Now().Unix() { // 活动结束
|
||||||
|
this.NotifyActivityOver([]string{hd.Id})
|
||||||
|
} else if hd.Etime > configure.Now().Unix() && hd.Stime < configure.Now().Unix() {
|
||||||
|
this.NotifyActivityStart([]string{hd.Id})
|
||||||
|
}
|
||||||
this.hlock.Lock()
|
this.hlock.Lock()
|
||||||
if this.activity == nil {
|
// 删除内存中
|
||||||
this.activity = make(map[pb.HdType]*pb.DBHuodong)
|
if _, ok := this.curActivity[hd.Itype]; ok {
|
||||||
|
delete(this.curActivity, hd.Itype)
|
||||||
}
|
}
|
||||||
this.activity[hd.Itype] = hd
|
if _, ok := this.delActivity[hd.Itype]; ok {
|
||||||
this.hlock.Unlock()
|
delete(this.delActivity, hd.Itype)
|
||||||
// rpc 通知
|
|
||||||
if configure.Now().Unix() <= hd.Etime && configure.Now().Unix() >= hd.Stime {
|
|
||||||
if err := this.service.RpcCall(
|
|
||||||
context.Background(),
|
|
||||||
comm.Service_Worker,
|
|
||||||
string(comm.Rpc_ActivityStar),
|
|
||||||
pb.RPCGeneralReqB1{
|
|
||||||
Param1: "starActivity",
|
|
||||||
Param2: []string{hd.Id},
|
|
||||||
},
|
|
||||||
nil,
|
|
||||||
); err != nil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if configure.Now().Unix() > hd.Etime {
|
if _, ok := this.futureActivity[hd.Itype]; ok {
|
||||||
if err := this.service.RpcCall(
|
delete(this.futureActivity, hd.Itype)
|
||||||
context.Background(),
|
|
||||||
comm.Service_Worker,
|
|
||||||
string(comm.Rpc_ActivityOver),
|
|
||||||
pb.RPCGeneralReqB1{
|
|
||||||
Param1: "endActivity",
|
|
||||||
Param2: []string{hd.Id},
|
|
||||||
},
|
|
||||||
nil,
|
|
||||||
); err != nil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
if hd.Etime <= configure.Now().Unix() { // 活动结束
|
||||||
|
this.delActivity[hd.Itype] = hd
|
||||||
|
} else if hd.Etime > configure.Now().Unix() && hd.Stime < configure.Now().Unix() {
|
||||||
|
this.curActivity[hd.Itype] = hd
|
||||||
|
} else {
|
||||||
|
this.futureActivity[hd.Itype] = hd
|
||||||
|
}
|
||||||
|
defer this.hlock.Unlock()
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (this *Activity) NotifyActivityOver(szEnd []string) {
|
||||||
|
if err := this.service.RpcCall(
|
||||||
|
context.Background(),
|
||||||
|
comm.Service_Worker,
|
||||||
|
string(comm.Rpc_ActivityOver),
|
||||||
|
pb.RPCGeneralReqB1{
|
||||||
|
Param1: "endActivity",
|
||||||
|
Param2: szEnd,
|
||||||
|
},
|
||||||
|
nil,
|
||||||
|
); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (this *Activity) NotifyActivityStart(szStart []string) {
|
||||||
|
if err := this.service.RpcCall(
|
||||||
|
context.Background(),
|
||||||
|
comm.Service_Worker,
|
||||||
|
string(comm.Rpc_ActivityStart),
|
||||||
|
pb.RPCGeneralReqB1{
|
||||||
|
Param1: "startActivity",
|
||||||
|
Param2: szStart,
|
||||||
|
},
|
||||||
|
nil,
|
||||||
|
); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
}
|
||||||
|
}
|
||||||
func (this *Activity) CheckActivityData() {
|
func (this *Activity) CheckActivityData() {
|
||||||
var (
|
var (
|
||||||
szEnd []string // 活动结束
|
szEnd []string // 活动结束
|
||||||
szStar []string // 有活动开启
|
szStart []string // 有活动开启
|
||||||
)
|
)
|
||||||
this.hlock.RLock()
|
this.hlock.Lock()
|
||||||
for _, v := range this.activity {
|
defer this.hlock.Unlock()
|
||||||
|
for _, v := range this.curActivity {
|
||||||
if v.Etime == configure.Now().Unix() { // 有活动结束
|
if v.Etime == configure.Now().Unix() { // 有活动结束
|
||||||
szEnd = append(szEnd, v.Id)
|
szEnd = append(szEnd, v.Id)
|
||||||
}
|
delete(this.curActivity, v.Itype)
|
||||||
if v.Stime == configure.Now().Unix() { // 有活动结束
|
this.delActivity[v.Itype] = v
|
||||||
szStar = append(szStar, v.Id)
|
}
|
||||||
|
}
|
||||||
|
for _, v := range this.futureActivity {
|
||||||
|
if v.Stime >= configure.Now().Unix() { // 有活动结束
|
||||||
|
szStart = append(szStart, v.Id)
|
||||||
|
delete(this.futureActivity, v.Itype)
|
||||||
|
this.curActivity[v.Itype] = v
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.hlock.RUnlock()
|
|
||||||
if len(szEnd) > 0 {
|
if len(szEnd) > 0 {
|
||||||
if err := this.service.RpcCall(
|
this.NotifyActivityOver(szEnd)
|
||||||
context.Background(),
|
|
||||||
comm.Service_Worker,
|
|
||||||
string(comm.Rpc_ActivityOver),
|
|
||||||
pb.RPCGeneralReqB1{
|
|
||||||
Param1: "endActivity",
|
|
||||||
Param2: szEnd,
|
|
||||||
},
|
|
||||||
nil,
|
|
||||||
); err != nil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if len(szStar) > 0 {
|
if len(szStart) > 0 {
|
||||||
if err := this.service.RpcCall(
|
this.NotifyActivityStart(szStart)
|
||||||
context.Background(),
|
|
||||||
comm.Service_Worker,
|
|
||||||
string(comm.Rpc_ActivityStar),
|
|
||||||
pb.RPCGeneralReqB1{
|
|
||||||
Param1: "starActivity",
|
|
||||||
Param2: szStar,
|
|
||||||
},
|
|
||||||
nil,
|
|
||||||
); err != nil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -39,6 +39,7 @@ func (this *UiGame) Init(service core.IService, module core.IModule, options cor
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.service = service.(base.IRPCXService)
|
this.service = service.(base.IRPCXService)
|
||||||
|
this.hdlist = make(map[pb.HdType]*pb.DBHuodong)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -27,18 +27,19 @@ func (this *Api_Comp) ActivityNotify(c *engine.Context) {
|
|||||||
c.JSON(http.StatusOK, &Respond{Code: errdata.Code, Message: errdata.Message, Data: data})
|
c.JSON(http.StatusOK, &Respond{Code: errdata.Code, Message: errdata.Message, Data: data})
|
||||||
}()
|
}()
|
||||||
|
|
||||||
if _, err = this.module.service.RpcGo(
|
_, err = this.module.service.RpcGo(
|
||||||
context.Background(),
|
context.Background(),
|
||||||
comm.Service_Worker,
|
comm.Service_Worker,
|
||||||
string(comm.Rpc_Activity),
|
string(comm.Rpc_Activity),
|
||||||
req.Id, nil); err != nil {
|
pb.RPCGeneralReqA1{
|
||||||
|
Param1: req.Id,
|
||||||
|
},
|
||||||
|
nil)
|
||||||
|
if err != nil {
|
||||||
this.module.Errorln(err)
|
this.module.Errorln(err)
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_RpcFuncExecutionError,
|
|
||||||
Title: pb.ErrorCode_RpcFuncExecutionError.ToString(),
|
|
||||||
}
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
Code: pb.ErrorCode_Success,
|
Code: pb.ErrorCode_Success,
|
||||||
Title: pb.ErrorCode_Success.ToString(),
|
Title: pb.ErrorCode_Success.ToString(),
|
||||||
|
Loading…
Reference in New Issue
Block a user