|
@@ -2,7 +2,6 @@ package com.zanxiang.game.module.manage.controller;
|
|
|
|
|
|
import com.zanxiang.erp.security.annotation.PreAuthorize;
|
|
import com.zanxiang.erp.security.annotation.PreAuthorize;
|
|
import com.zanxiang.game.module.manage.pojo.params.KfApiParam;
|
|
import com.zanxiang.game.module.manage.pojo.params.KfApiParam;
|
|
-import com.zanxiang.game.module.manage.pojo.vo.CpVO;
|
|
|
|
import com.zanxiang.game.module.manage.pojo.vo.KfGameVO;
|
|
import com.zanxiang.game.module.manage.pojo.vo.KfGameVO;
|
|
import com.zanxiang.game.module.manage.service.IKfMsgContentService;
|
|
import com.zanxiang.game.module.manage.service.IKfMsgContentService;
|
|
import com.zanxiang.module.util.pojo.ResultVO;
|
|
import com.zanxiang.module.util.pojo.ResultVO;
|
|
@@ -14,6 +13,7 @@ import lombok.extern.slf4j.Slf4j;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.validation.annotation.Validated;
|
|
import org.springframework.validation.annotation.Validated;
|
|
import org.springframework.web.bind.annotation.*;
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
+import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
import java.util.List;
|
|
import java.util.List;
|
|
|
|
|
|
@@ -31,10 +31,18 @@ public class KfMsgController {
|
|
@Autowired
|
|
@Autowired
|
|
private IKfMsgContentService kfMsgContentService;
|
|
private IKfMsgContentService kfMsgContentService;
|
|
|
|
|
|
|
|
+ @ApiOperation(value = "图片上传")
|
|
|
|
+ @PostMapping(value = "/upload/msg")
|
|
|
|
+ @PreAuthorize(permissionKey = "manage:kf:uploadMsg")
|
|
|
|
+ @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = String.class)})
|
|
|
|
+ public ResultVO<String> uploadMsg(MultipartFile files) {
|
|
|
|
+ return ResultVO.ok(kfMsgContentService.uploadMsg(files));
|
|
|
|
+ }
|
|
|
|
+
|
|
@ApiOperation(value = "小游戏列表查询")
|
|
@ApiOperation(value = "小游戏列表查询")
|
|
@GetMapping(value = "/game/list")
|
|
@GetMapping(value = "/game/list")
|
|
@PreAuthorize(permissionKey = "manage:kf:gameList")
|
|
@PreAuthorize(permissionKey = "manage:kf:gameList")
|
|
- @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = CpVO.class)})
|
|
+ @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = KfGameVO.class)})
|
|
public ResultVO<List<KfGameVO>> list() {
|
|
public ResultVO<List<KfGameVO>> list() {
|
|
return ResultVO.ok(kfMsgContentService.getKfGameList());
|
|
return ResultVO.ok(kfMsgContentService.getKfGameList());
|
|
}
|
|
}
|
|
@@ -42,7 +50,7 @@ public class KfMsgController {
|
|
@ApiOperation(value = "客服接口通用api")
|
|
@ApiOperation(value = "客服接口通用api")
|
|
@PostMapping(value = "/comm/api")
|
|
@PostMapping(value = "/comm/api")
|
|
@PreAuthorize(permissionKey = "manage:kf:commApi")
|
|
@PreAuthorize(permissionKey = "manage:kf:commApi")
|
|
- @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = CpVO.class)})
|
|
+ @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = String.class)})
|
|
public ResultVO<String> list(@Validated @RequestBody KfApiParam param) {
|
|
public ResultVO<String> list(@Validated @RequestBody KfApiParam param) {
|
|
return ResultVO.ok(kfMsgContentService.kfApi(param));
|
|
return ResultVO.ok(kfMsgContentService.kfApi(param));
|
|
}
|
|
}
|