|
@@ -4,17 +4,17 @@ import com.zanxiang.erp.security.annotation.PreAuthorize;
|
|
|
import com.zanxiang.game.data.serve.pojo.dto.*;
|
|
|
import com.zanxiang.game.data.serve.service.IRoleManageService;
|
|
|
import com.zanxiang.game.data.serve.utils.Page;
|
|
|
+import com.zanxiang.game.module.base.ServerInfo;
|
|
|
import com.zanxiang.game.module.base.pojo.vo.SendMsgResultVO;
|
|
|
import com.zanxiang.game.module.base.pojo.vo.SendMsgVO;
|
|
|
+import com.zanxiang.game.module.base.rpc.ICPSendMsgRpc;
|
|
|
import com.zanxiang.module.util.pojo.ResultVO;
|
|
|
import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.apache.dubbo.config.annotation.DubboReference;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
-import org.springframework.web.bind.annotation.PostMapping;
|
|
|
-import org.springframework.web.bind.annotation.RequestBody;
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import javax.validation.Valid;
|
|
|
import java.util.Map;
|
|
@@ -32,6 +32,8 @@ public class RoleManageController {
|
|
|
|
|
|
@Autowired
|
|
|
private IRoleManageService roleManageService;
|
|
|
+ @DubboReference(providedBy = ServerInfo.SERVER_DUBBO_NAME)
|
|
|
+ private ICPSendMsgRpc sendMsgRpc;
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "角色充值排行榜")
|
|
@@ -71,6 +73,20 @@ public class RoleManageController {
|
|
|
return ResultVO.ok(roleManageService.getSendMsgResultList(msgTaskResultDto));
|
|
|
}
|
|
|
|
|
|
+ @ApiOperation(value = "根据任务id重发消息")
|
|
|
+ @PreAuthorize(permissionKey = "roleManage:sendMsgTask:reSendMsgByTaskId")
|
|
|
+ @PostMapping("/reSendMsgByTaskId")
|
|
|
+ public ResultVO<Boolean> reSendMsgByTaskId(@RequestParam("gameId") Long gameId,@RequestParam("taskId") Long taskId) {
|
|
|
+ return sendMsgRpc.reSendMsgByTaskId(gameId, taskId);
|
|
|
+ }
|
|
|
+
|
|
|
+ @ApiOperation(value = "根据发送结果id重发消息")
|
|
|
+ @PreAuthorize(permissionKey = "roleManage:sendMsgTask:reSendMsgByResultId")
|
|
|
+ @PostMapping("/reSendMsgByResultId")
|
|
|
+ public ResultVO<Boolean> reSendMsgByResultId(@RequestParam("resultId") Long resultId) {
|
|
|
+ return sendMsgRpc.reSendMsgByResultId(resultId);
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
|
|
|
|