Merge remote-tracking branch 'origin/master'

master
shijie 4 years ago
commit f558456c0f
  1. 1
      dq-financial-crms/src/main/java/com/daqing/financial/crms/service/impl/CustomerAppletServiceImpl.java
  2. 12
      dq-financial-crms/src/main/resources/mapper/crms/CustomerAppletDao.xml
  3. 10
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/AlCollectionController.java
  4. 40
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgCopyForServiceImpl.java
  5. 3
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgEfficiencyServiceImpl.java
  6. 15
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/util/OrdinaryUtil.java
  7. 2
      dq-financial-guarantee/src/main/resources/mapper/guarantee/AlCollectionMapper.xml
  8. 4
      dq-govern-gateway/src/main/resources/jwt.properties

@ -370,7 +370,6 @@ public class CustomerAppletServiceImpl extends ServiceImpl<CustomerAppletDao, Cu
public Map getApplyMount() {
// 这个是否填小数没有影响,主要要是看赋予或计算的值是否包含小数
BigDecimal company = new BigDecimal(0.00);
// Double company = 0.00;
Map<String, BigDecimal> map = new HashMap<>();
map.put("company", company);
// 个人类型暂时没有

@ -8,11 +8,19 @@
</insert>
<select id="getCustomerStatus" resultType="integer">
SELECT COUNT(id) FROM crms_customer_user WHERE user_id = #{userId} AND type = #{type}
SELECT COUNT(cu.id) FROM crms_customer_user AS cu
INNER JOIN crms_customer AS c
ON cu.customer_id = c.id
WHERE c.del_or_not = 0
AND cu.user_id = #{userId} AND cu.type = #{type}
</select>
<select id="getCustomerId" resultType="integer">
SELECT customer_id FROM crms_customer_user WHERE user_id = #{userId} AND type = #{type}
SELECT cu.customer_id FROM crms_customer_user AS cu
INNER JOIN crms_customer AS c
ON cu.customer_id = c.id
WHERE c.del_or_not = 0
AND cu.user_id = #{userId} AND cu.type = #{type}
</select>
<!-- 更新客户基本信息 -->

@ -6,6 +6,7 @@ import com.daqing.financial.guarantee.model.request.AlCollectionRequest;
import com.daqing.financial.guarantee.model.response.AlCollectionListResponse;
import com.daqing.financial.guarantee.model.response.AlCollectionResponse;
import com.daqing.financial.guarantee.model.response.MoreOverdueDetailResponse;
import com.daqing.financial.guarantee.model.response.OverdueDetailResponse;
import com.daqing.financial.guarantee.service.IAlCollectionService;
import com.daqing.framework.domain.guarantee.AlCollection;
import com.daqing.framework.model.response.ResponseResult;
@ -15,9 +16,10 @@ import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.validation.Valid;
import java.io.IOException;
import java.io.*;
import java.util.List;
/**
@ -62,7 +64,7 @@ public class AlCollectionController {
* 催收时展示的详情
*/
@GetMapping("/overdue/detail")
@ApiOperation(value = "催收时展示的详情", notes = "催收时展示的详情")
@ApiOperation(value = "催收时展示的详情", notes = "催收时展示的详情", response = OverdueDetailResponse.class)
public ResponseResult overdueDetail(@RequestParam("insuranceId") Integer insuranceId) {
return ResponseResult.SUCCESS(alCollectionService.overdueDetail(insuranceId));
@ -103,8 +105,8 @@ public class AlCollectionController {
* 催收列表导出
*/
@ApiOperation(value = "催收列表导出", notes = "催收列表导出")
@PostMapping("/collection/list/export/excel")
public ResponseResult collectionListExportExcel(@RequestBody List<Integer> ids, HttpServletResponse response) throws IOException {
@GetMapping("/collection/list/export/excel")
public ResponseResult collectionListExportExcel(@RequestParam("ids") List<Integer> ids, HttpServletResponse response) throws IOException {
alCollectionService.collectionListExportExcel(ids, response);
return ResponseResult.SUCCESS();

@ -16,6 +16,7 @@ import com.daqing.framework.domain.guarantee.DgCopyFor;
import com.daqing.framework.domain.guarantee.DgCopyUser;
import com.daqing.framework.domain.guarantee.DgProcessUser;
import com.daqing.framework.model.response.PromptSuccess;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@ -42,24 +43,29 @@ public class DgCopyForServiceImpl extends ServiceImpl<DgCopyForMapper, DgCopyFor
@Override
public boolean copySendUser(Integer businessId, Integer processId, String imgData) throws IOException {
//获取随机值
String snowflakeId = IdUtil.getSnowflake(6, 4).nextIdStr();
//文件扩展名
String ext = ".png";
//新文件名:雪花算法.文件扩展名
String newName = snowflakeId + ext;
//指定存放目录
String directory = PromptSuccess.UPLOAD_FILE_PATH;
// String directory = "D:/img/";
//图片完整路径
String imgPath = directory + newName;
String accessPath = "";
ImgUtil.generateImage(imgData, imgPath);
//拼接图片地址
//访问路径前缀
String serverPrefix = PromptSuccess.IMAGE_URL_PATH;
//访问路径
String accessPath = serverPrefix + newName;
//图片信息不为空,不生成图片地址
if(StringUtils.isNotEmpty(imgData)){
//获取随机值
String snowflakeId = IdUtil.getSnowflake(6, 4).nextIdStr();
//文件扩展名
String ext = ".png";
//新文件名:雪花算法.文件扩展名
String newName = snowflakeId + ext;
//指定存放目录
String directory = PromptSuccess.UPLOAD_FILE_PATH;
// String directory = "D:/img/";
//图片完整路径
String imgPath = directory + newName;
ImgUtil.generateImage(imgData, imgPath);
//拼接图片地址
//访问路径前缀
String serverPrefix = PromptSuccess.IMAGE_URL_PATH;
//访问路径
accessPath = serverPrefix + newName;
}
//取出抄送详情id
Integer copyForId = 0;
//添加之前判断是否抄送详情存在,如果存在则更新这条数据

@ -185,6 +185,9 @@ public class DgEfficiencyServiceImpl extends ServiceImpl<DgEfficiencyMapper, DgA
map.put(processId, time + ",1");
String[] departmentIds = departmentIdList.split(",");
for (String departmentId : departmentIds) {
if (departmentId.equals("0")) {
continue;
}
// 没有当前部门的数据,直接新建一个
if (hashMap.get(Integer.parseInt(departmentId)) == null) {
hashMap.put(Integer.parseInt(departmentId), map);

@ -32,7 +32,20 @@ public class OrdinaryUtil {
*/
public static String getDepartmentId(Integer userId) {
String departmentIds = ordinaryUtil.hrmsFeignService.getDepartmentIds(userId);
if (departmentIds == null || departmentIds.length() == 0) {
departmentIds = "0";
} else {
boolean flag = true;
// 判断departmentIds是不是"1,2,3,4"这种格式,不是就设置为"0"
for (int i = 0; i < departmentIds.length(); i++) {
if ("0123456789,".indexOf(departmentIds.charAt(i)) == -1) {
flag = false;
}
}
if (!flag) {
departmentIds = "0";
}
}
return departmentIds;
}
}

@ -40,7 +40,7 @@
</insert>
<select id="getOverdueDetailByInsuranceId" parameterType="integer" resultType="com.daqing.financial.guarantee.model.response.OverdueDetailResponse">
SELECT i.business_code AS code,i.customer_name AS name,i.business_type AS type,COUNT(c.id) AS numberOfCollection
SELECT i.customer_name AS name,i.business_type AS type,i.business_code AS code,COUNT(c.id) AS number_of_collection
FROM al_insurance_list AS i
INNER JOIN al_collection AS c
ON i.id = c.insurance_id

@ -32,7 +32,9 @@ jwt.ignoreUrlList=/apiHrmsAuth/hrms/auth/userlogin/getBackPwd,\
/api-guarantee/dg-copy-user/exportCopyForMe,\
/apiHrmsAuth/hrms/auth/userlogin/wxAuthLogin,\
/api-guarantee/al-insurance-list/excelExport,\
/api-guarantee/al-repayment-entry/excelExport
/api-guarantee/al-repayment-entry/excelExport,\
/api-guarantee/al-collection/list/export/excel,\
/api-guarantee/al-collection/collection/list/export/excel

Loading…
Cancel
Save