|
@@ -1,6 +1,7 @@
|
|
|
package org.springblade.manager.controller;
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
+import com.alibaba.fastjson.JSONObject;
|
|
|
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
|
|
|
import com.mixsmart.utils.StringUtils;
|
|
|
import io.swagger.annotations.Api;
|
|
@@ -26,10 +27,7 @@ import org.springblade.system.feign.IDictBizClient;
|
|
|
import org.springblade.system.feign.ISysClient;
|
|
|
import org.springblade.system.user.entity.User;
|
|
|
import org.springblade.system.user.feign.IUserClient;
|
|
|
-import org.springframework.web.bind.annotation.PostMapping;
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
-import org.springframework.web.bind.annotation.RequestParam;
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import java.util.HashMap;
|
|
|
import java.util.Iterator;
|
|
@@ -57,6 +55,16 @@ public class ManagerHomePageController extends BladeController {
|
|
|
|
|
|
private final ISysClient sysClient;
|
|
|
|
|
|
+ /**
|
|
|
+ * 获取当前用户和全部的工单数量
|
|
|
+ */
|
|
|
+ @GetMapping("/getOpinionNumber")
|
|
|
+ @ApiOperationSupport(order = 7)
|
|
|
+ @ApiOperation(value = "获取当前用户和全部的工单数量")
|
|
|
+ public R<JSONObject> getOpinionNumber(){
|
|
|
+ return R.data(this.opinionUserClient.getOpinionNumber());
|
|
|
+ }
|
|
|
+
|
|
|
/**
|
|
|
* 证书统计
|
|
|
*/
|
|
@@ -257,10 +265,20 @@ public class ManagerHomePageController extends BladeController {
|
|
|
//拼接数据
|
|
|
result.forEach(vo -> {
|
|
|
if(!new Integer("1").equals(vo.getIsIgnore())){
|
|
|
- String title = "待办工单任务:" + DateUtil.format(vo.getCreateTime(), "yyyy-MM-dd HH:mm:ss") + "来自" + "【" + vo.getProjectName() + "-" + vo.getContractName() + "】" +
|
|
|
- "的【" + vo.getSubmitUserRole() + vo.getSubmitUserName() + "】" + "向您反馈" + "\"" + vo.getProblemType() + "\"";
|
|
|
|
|
|
- resultVO.setUserOpinionFlowList(vo.getUserOpinionId().toString(), title, vo.getCurrentLink(), vo.getNewNumber(), vo.getCurrentLinkId().toString(), vo.getOperation());
|
|
|
+ resultVO.setUserOpinionFlowList(
|
|
|
+ vo.getUserOpinionId().toString(),
|
|
|
+ "\"" + vo.getProblemType() + "\"",
|
|
|
+ vo.getCurrentLink(),
|
|
|
+ vo.getNewNumber(),
|
|
|
+ vo.getCurrentLinkId().toString(),
|
|
|
+ "【" + vo.getProjectName() + "-" + vo.getContractName() + "】",
|
|
|
+ "【" + vo.getSubmitUserRole() + vo.getSubmitUserName() + "】",
|
|
|
+ "您",
|
|
|
+ DateUtil.format(vo.getCreateTime(), "yyyy-MM-dd HH:mm:ss"),
|
|
|
+ vo.getOperation()
|
|
|
+ );
|
|
|
+
|
|
|
count.getAndIncrement();
|
|
|
}
|
|
|
});
|
|
@@ -292,18 +310,34 @@ public class ManagerHomePageController extends BladeController {
|
|
|
result.removeIf(BusinessUserOpinionVO::getIsCurrent);
|
|
|
//拼接数据
|
|
|
result.forEach(vo -> {
|
|
|
- String title;
|
|
|
if(vo.getOperation()){
|
|
|
//有操作权限且没有被忽略的
|
|
|
if(!new Integer("1").equals(vo.getIsIgnore())){
|
|
|
- title = "待办工单任务:" + DateUtil.format(vo.getCreateTime(), "yyyy-MM-dd HH:mm:ss") + "来自" + "【" + vo.getProjectName() + "-" + vo.getContractName() + "】" +
|
|
|
- "的【" + vo.getSubmitUserRole() + vo.getSubmitUserName() + "】" + "向您反馈" + "\"" + vo.getProblemType() + "\"";
|
|
|
- resultVO.setUserOpinionFlowList(vo.getUserOpinionId().toString(), title, vo.getCurrentLink(), vo.getNewNumber(), vo.getCurrentLinkId().toString(), vo.getOperation());
|
|
|
+
|
|
|
+ resultVO.setUserOpinionFlowList(
|
|
|
+ vo.getUserOpinionId().toString(),
|
|
|
+ "\"" + vo.getProblemType() + "\"", vo.getCurrentLink(),
|
|
|
+ vo.getNewNumber(),
|
|
|
+ vo.getCurrentLinkId().toString(),
|
|
|
+ "【" + vo.getProjectName() + "-" + vo.getContractName() + "】",
|
|
|
+ "【" + vo.getSubmitUserRole() + vo.getSubmitUserName() + "】",
|
|
|
+ "您",
|
|
|
+ DateUtil.format(vo.getCreateTime(), "yyyy-MM-dd HH:mm:ss"),
|
|
|
+ vo.getOperation()
|
|
|
+ );
|
|
|
}
|
|
|
} else {
|
|
|
- title = "待办工单任务:" + DateUtil.format(vo.getCreateTime(), "yyyy-MM-dd HH:mm:ss") + "来自" + "【" + vo.getProjectName() + "-" + vo.getContractName() + "】" +
|
|
|
- "的【" + vo.getSubmitUserRole() + vo.getSubmitUserName() + "】" + "向【" + vo.getManagerUserName() + "】反馈" + "\"" + vo.getProblemType() + "\"";
|
|
|
- resultVO.setUserOpinionFlowList(vo.getUserOpinionId().toString(), title, vo.getCurrentLink(), vo.getNewNumber(), vo.getCurrentLinkId().toString(), vo.getOperation());
|
|
|
+ resultVO.setUserOpinionFlowList(
|
|
|
+ vo.getUserOpinionId().toString(),
|
|
|
+ "\"" + vo.getProblemType() + "\"",
|
|
|
+ vo.getCurrentLink(),
|
|
|
+ vo.getNewNumber(),
|
|
|
+ vo.getCurrentLinkId().toString(),
|
|
|
+ "【" + vo.getProjectName() + "-" + vo.getContractName() + "】",
|
|
|
+ "【" + vo.getSubmitUserRole() + vo.getSubmitUserName() + "】",
|
|
|
+ "【" + vo.getManagerUserName() + "】",
|
|
|
+ DateUtil.format(vo.getCreateTime(), "yyyy-MM-dd HH:mm:ss"),
|
|
|
+ vo.getOperation());
|
|
|
}
|
|
|
});
|
|
|
|