添加世界任务group参数
This commit is contained in:
parent
99c043fff7
commit
1f17b9ffe0
@ -49,6 +49,8 @@ func (this *WorldtaskMineView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
|
||||
// 接取任务
|
||||
this.juqingBtn = widget.NewButton("接取任务", func() {
|
||||
groupId := widget.NewEntry()
|
||||
groupId.PlaceHolder = "分组ID"
|
||||
taskIdEntry := widget.NewEntry()
|
||||
taskIdEntry.PlaceHolder = "任务ID"
|
||||
form := widget.NewForm(
|
||||
@ -62,6 +64,7 @@ func (this *WorldtaskMineView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
t.MainType,
|
||||
worldtask.WorldtaskSubtypeFinish,
|
||||
&pb.WorldtaskFinishReq{
|
||||
GroupId: cast.ToInt32(groupId.Text),
|
||||
TaskId: cast.ToInt32(taskIdEntry.Text),
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
|
@ -274,6 +274,7 @@ func (this *ModuleRtask) SendToRtask(session comm.IUserSession, rtaskType comm.T
|
||||
}, uid); err != nil {
|
||||
log.Errorf("任务条件达成推送失败 err:%v", err)
|
||||
}
|
||||
log.Errorf("任务条件达成 uid:%v condId:%v", uid, v.cfg.Id)
|
||||
module, err := this.service.GetModule(comm.ModuleWorldtask)
|
||||
if err == nil {
|
||||
if worldtask, ok := module.(comm.IWorldtask); ok {
|
||||
|
@ -10,7 +10,7 @@ import (
|
||||
// 任务完成
|
||||
|
||||
func (this *apiComp) FinishCheck(session comm.IUserSession, req *pb.WorldtaskFinishReq) (code pb.ErrorCode) {
|
||||
if req.TaskId == 0 {
|
||||
if req.GroupId == 0 || req.TaskId == 0 {
|
||||
code = pb.ErrorCode_ReqParameterError
|
||||
}
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user