From 7baed70455850ca367396103dd1682b0bfabe32a Mon Sep 17 00:00:00 2001 From: shijie <648688341@qq.com> Date: Mon, 28 Dec 2020 18:28:05 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A6=96=E9=A1=B5=E7=BB=9F=E8=AE=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/DgEfficiencyController.java | 23 +++++++++++++++ .../mapper/DgAuditProcessMapper.java | 5 ++++ .../response/EfficiencyApprovalResponse.java | 24 +++++++++++++++ .../service/IDgEfficiencyService.java | 1 + .../service/impl/DgEfficiencyServiceImpl.java | 29 +++++++++++++++++++ .../mapper/guarantee/DgAuditProcessMapper.xml | 20 +++++++++++++ .../src/main/resources/jwt.properties | 3 +- 7 files changed, 104 insertions(+), 1 deletion(-) create mode 100644 dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/model/response/EfficiencyApprovalResponse.java diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgEfficiencyController.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgEfficiencyController.java index 7ca8f764..a864e3d4 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgEfficiencyController.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgEfficiencyController.java @@ -1,8 +1,15 @@ package com.daqing.financial.guarantee.controller; +import com.daqing.financial.guarantee.service.IDgEfficiencyService; +import com.daqing.framework.model.response.ResponseResult; +import io.swagger.annotations.ApiOperation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; +import javax.servlet.http.HttpServletResponse; + /** * 流程效率 * @@ -12,4 +19,20 @@ import org.springframework.web.bind.annotation.RestController; @RestController @RequestMapping("/guarantee/efficiency") public class DgEfficiencyController { + + @Autowired + private IDgEfficiencyService dgEfficiencyService; + + /** + * 首页-近十天的审批数目 + */ + @GetMapping("/approvalNum") + public ResponseResult approvalNum(){ + + //查询审批数目的值的数组 + String result = dgEfficiencyService.approvalNum(); + + //return result ? ResponseResult.SUCCESS() : ResponseResult.FAIL(); + return new ResponseResult(); + } } diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgAuditProcessMapper.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgAuditProcessMapper.java index 0b944a9f..5246b898 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgAuditProcessMapper.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgAuditProcessMapper.java @@ -1,6 +1,7 @@ package com.daqing.financial.guarantee.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.daqing.financial.guarantee.model.response.EfficiencyApprovalResponse; import com.daqing.framework.domain.guarantee.DgAuditProcess; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; @@ -21,4 +22,8 @@ public interface DgAuditProcessMapper extends BaseMapper { List selectAuditProcessList(@Param("businessId") String businessId,@Param("processId") String processId); List selectProcessId(String businessId); + + List selectTenDays(Integer userId); + + List selectApprovalNum(int parseInt); } diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/model/response/EfficiencyApprovalResponse.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/model/response/EfficiencyApprovalResponse.java new file mode 100644 index 00000000..f1dc0738 --- /dev/null +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/model/response/EfficiencyApprovalResponse.java @@ -0,0 +1,24 @@ +package com.daqing.financial.guarantee.model.response; + +import com.alibaba.excel.metadata.BaseRowModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.ToString; + +import java.io.Serializable; + +@Data +@ToString +public class EfficiencyApprovalResponse extends BaseRowModel implements Serializable { + + /** + * 审批数量 + */ + @ApiModelProperty(value = "审批数量") + private Integer approvalNum; + /** + * 审批日期 + */ + @ApiModelProperty(value = "审批日期") + private Integer createTime2; +} diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgEfficiencyService.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgEfficiencyService.java index b52c529a..d785943f 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgEfficiencyService.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgEfficiencyService.java @@ -9,4 +9,5 @@ import com.daqing.framework.domain.guarantee.DgApplyAmountInfo; */ public interface IDgEfficiencyService extends IService { + String approvalNum(); } diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgEfficiencyServiceImpl.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgEfficiencyServiceImpl.java index d9594880..736928da 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgEfficiencyServiceImpl.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgEfficiencyServiceImpl.java @@ -1,14 +1,43 @@ package com.daqing.financial.guarantee.service.impl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.daqing.financial.guarantee.controller.DgApplyAmountInfoController; +import com.daqing.financial.guarantee.mapper.DgAuditProcessMapper; import com.daqing.financial.guarantee.mapper.DgEfficiencyMapper; +import com.daqing.financial.guarantee.model.response.EfficiencyApprovalResponse; import com.daqing.financial.guarantee.service.IDgEfficiencyService; import com.daqing.framework.domain.guarantee.DgApplyAmountInfo; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.List; /** * @auther River * @date 2020/11/10 11:34 */ +@Service public class DgEfficiencyServiceImpl extends ServiceImpl implements IDgEfficiencyService { + @Autowired + private DgApplyAmountInfoController dgApplyAmountInfoController; + @Autowired + private DgAuditProcessMapper dgAuditProcessMapper; + /** + * 查询审批数目的值的数组 + * @return + */ + @Override + public String approvalNum() { + //获取当前用户id + String userId = dgApplyAmountInfoController.getUserId(); + //近十天的日期数组 + ListtimeList = dgAuditProcessMapper.selectTenDays(Integer.parseInt(userId)); + System.out.println("timeList============"+timeList); + //近十天审批数目的值的数组 + ListapprovalList = dgAuditProcessMapper.selectApprovalNum(Integer.parseInt(userId)); + System.out.println("approvalList==========="+approvalList); + + return null; + } } \ No newline at end of file diff --git a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgAuditProcessMapper.xml b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgAuditProcessMapper.xml index 91f7603e..1fe74cf4 100644 --- a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgAuditProcessMapper.xml +++ b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgAuditProcessMapper.xml @@ -30,5 +30,25 @@ + + + diff --git a/dq-govern-gateway/src/main/resources/jwt.properties b/dq-govern-gateway/src/main/resources/jwt.properties index 3fc16df0..61efd42f 100644 --- a/dq-govern-gateway/src/main/resources/jwt.properties +++ b/dq-govern-gateway/src/main/resources/jwt.properties @@ -26,7 +26,8 @@ jwt.ignoreUrlList=/apiHrmsAuth/hrms/auth/userlogin/getBackPwd,\ /api-guarantee/dg-loan-notice/loanNoticeListExport,\ /api-guarantee/dg-loan-notice/exportLoanNotice,\ /api-hrms/hrms/user/uploadFile,\ - /apiHrmsAuth/hrms/auth/permission/getUserRoles + /apiHrmsAuth/hrms/auth/permission/getUserRoles,\ + /api-hrms/hrms/permission/getPermission