Commit 14318d30 authored by fangxinjiang's avatar fangxinjiang

银行卡校验

parent d9542189
......@@ -127,6 +127,12 @@ public class TEmpBadRecord extends BaseEntity {
@ExcelProperty("其他损失")
private BigDecimal loseFeeOther;
/**
* 项目ID
*/
@Schema(description ="项目ID")
private String settleDomain;
/**
* @Author fxj
* @Description 附件ID
......
......@@ -103,6 +103,12 @@ public class TEmpDisabilityInfo extends BaseEntity {
@Schema(description ="职业病名称")
private String occupationalDisease;
/**
* 项目ID
*/
@Schema(description ="项目ID")
private String settleDomain;
/**
* 0删除作废1正常
*/
......
......@@ -138,6 +138,12 @@ public class TEmpEducation extends BaseEntity {
*/
@Schema(description = "派单标识 1 代表派单生成, 派单审核通过后清空标识 专门用于派单作废")
private String dispatchFlag;
/**
* 项目ID
*/
@Schema(description ="项目ID")
private String settleDomain;
/**
* 证书名称
*/
......
......@@ -110,4 +110,10 @@ public class TEmpFamily extends BaseEntity {
@Schema(description ="备注")
private String remark;
/**
* 项目ID
*/
@Schema(description ="项目ID")
private String settleDomain;
}
......@@ -107,6 +107,12 @@ public class TEmpProfessionalQualification extends BaseEntity {
@Schema(description ="是否最高资格0是/1否")
private String heightIdentification;
/**
* 项目ID
*/
@Schema(description ="项目ID")
private String settleDomain;
/**
* 0删除作废1正常
*/
......
......@@ -110,6 +110,12 @@ public class TEmpWorkRecording extends BaseEntity {
@Schema(description ="人员类型")
private String workingType;
/**
* 项目ID
*/
@Schema(description ="项目ID")
private String settleDomain;
/**
* 0删除作废1正常
*/
......
......@@ -29,6 +29,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.yifu.cloud.plus.v1.check.entity.TCheckBankNo;
import com.yifu.cloud.plus.v1.check.vo.CheckBankNoVo;
import com.yifu.cloud.plus.v1.yifu.archives.constants.EmployeeConstants;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TCustomerInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
......@@ -176,13 +177,16 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
check.setBankNo(tEmployeeProject.getBankNo());
check.setIdNum(tEmployeeProject.getEmpIdcard());
check.setName(tEmployeeProject.getEmpName());
R<TCheckBankNo> checkListR = HttpDaprUtil.invokeMethodPost(daprCheckProperties.getAppUrl(), daprCheckProperties.getAppId()
, "/tcheckbankno/inner/checkBankNo", check, TCheckBankNo.class, SecurityConstants.FROM_IN);
R<CheckBankNoVo> checkListR = HttpDaprUtil.invokeMethodPost(daprCheckProperties.getAppUrl(), daprCheckProperties.getAppId()
, "/tcheckbankno/inner/checkBankNo", check, CheckBankNoVo.class, SecurityConstants.FROM_IN);
if (checkListR != null && checkListR.getData() != null) {
check = checkListR.getData();
if (check == null || Common.isEmpty(check.getResult())) {
CheckBankNoVo vo= checkListR.getData();
check = (null==vo.getRes())?null:vo.getRes().getData();
if (Common.isEmpty(vo)) {
return R.failed(EmployeeConstants.CHECK_NO_RESPONSE);
} else if (check.getResult().equals(CommonConstants.ZERO_STRING)) {
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
return R.failed(vo.getRes().getMsg());
} else if (Common.isEmpty(check) && !check.getResult().equals(CommonConstants.ZERO_STRING)){
return R.failed(check.getMessage());
}
} else {
......
......@@ -34,6 +34,7 @@
<result property="remark" column="REMARK"/>
<result property="loseFee" column="LOSE_FEE"/>
<result property="loseFeeOther" column="LOSE_FEE_OTHER"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
<result property="createName" column="CREATE_NAME"/>
......
......@@ -35,6 +35,7 @@
<result property="startTime" column="START_TIME"/>
<result property="endTime" column="END_TIME"/>
<result property="occupationalDisease" column="OCCUPATIONAL_DISEASE"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
......
......@@ -39,6 +39,7 @@
<result property="collageSystem" column="COLLAGE_SYSTEM"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="dispatchFlag" column="DISPATCH_FLAG"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
<result property="createName" column="CREATE_NAME"/>
......
......@@ -34,7 +34,8 @@
<result property="birthday" column="BIRTHDAY"/>
<result property="workUnit" column="WORK_UNIT"/>
<result property="contractTel" column="CONTRACT_TEL"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
<result property="createName" column="CREATE_NAME"/>
......
......@@ -36,6 +36,7 @@
<result property="assessmentUnit" column="ASSESSMENT_UNIT"/>
<result property="declareYear" column="DECLARE_YEAR"/>
<result property="heightIdentification" column="HEIGHT_IDENTIFICATION"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
......
......@@ -36,6 +36,7 @@
<result property="endDate" column="END_DATE"/>
<result property="workingStatus" column="WORKING_STATUS"/>
<result property="workingType" column="WORKING_TYPE"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
......
......@@ -17,6 +17,7 @@
package com.yifu.cloud.plus.v1.check.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
......@@ -110,5 +111,12 @@ public class TCheckBankNo extends BaseEntity {
@Schema(description ="身份证")
private String idNum;
/**
* 手机号码
*/
@TableField(exist = false)
@Schema(description ="手机号码")
private String mobile;
}
package com.yifu.cloud.plus.v1.check.vo;
import com.yifu.cloud.plus.v1.check.entity.TCheckBankNo;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import lombok.Data;
import java.io.Serializable;
/**
* @Author fxj
* @Date 2022/7/12
* @Description
* @Version 1.0
*/
@Data
public class CheckBankNoVo implements Serializable {
private R<TCheckBankNo> res;
}
......@@ -21,6 +21,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yifu.cloud.plus.v1.check.entity.TCheckBankNo;
import com.yifu.cloud.plus.v1.check.service.TCheckBankNoService;
import com.yifu.cloud.plus.v1.check.vo.CheckBankNoVo;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog;
import com.yifu.cloud.plus.v1.yifu.common.security.annotation.Inner;
......@@ -113,36 +114,13 @@ public class TCheckBankNoController {
/**
* 银行卡号校验
* @param name 姓名 是 [string]
* @param idNum 身份证号码,限单个 是 [string]
* @param cardNo 银行卡号,限单个 是 [string]
* @param mobile 银行预留手机号,仅支持国内11位号码
*/
@Operation(description = "银行卡号校验")
@SysLog("银行卡号校验" )
@GetMapping("/checkBankNo" )
public R<TCheckBankNo> checkBankNo(@RequestParam(value = "name",required = true)String name,
@RequestParam(value = "idNum",required = true)String idNum,
@RequestParam(value = "cardNo",required = true)String cardNo,
@RequestParam(value = "mobile",required = false) String mobile) {
return tCheckBankNoService.checkBankNo(name,idNum,cardNo,mobile);
}
/**
* 银行卡号校验
* @param name 姓名 是 [string]
* @param idNum 身份证号码,限单个 是 [string]
* @param cardNo 银行卡号,限单个 是 [string]
* @param mobile 银行预留手机号,仅支持国内11位号码
* @param checkBankNo 姓名 是 [string] 身份证号码,限单个 是 [string] 银行卡号,限单个 是 [string]银行预留手机号,仅支持国内11位号码
*/
@Operation(description = "银行卡号校验")
@SysLog("银行卡号校验" )
@Inner
@PostMapping("/inner/checkBankNo" )
public R<TCheckBankNo> checkBankNoInner(@RequestParam(value = "name",required = true)String name,
@RequestParam(value = "idNum",required = true)String idNum,
@RequestParam(value = "cardNo",required = true)String cardNo,
@RequestParam(value = "mobile",required = false) String mobile) {
return tCheckBankNoService.checkBankNo(name,idNum,cardNo,mobile);
public CheckBankNoVo checkBankNoInner(@RequestBody TCheckBankNo checkBankNo) {
return tCheckBankNoService.checkBankNo(checkBankNo.getName(),checkBankNo.getIdNum(),checkBankNo.getBankNo(),checkBankNo.getMobile());
}
}
......@@ -19,6 +19,7 @@ package com.yifu.cloud.plus.v1.check.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yifu.cloud.plus.v1.check.entity.TCheckBankNo;
import com.yifu.cloud.plus.v1.check.vo.CheckBankNoVo;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
/**
......@@ -29,5 +30,5 @@ import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
*/
public interface TCheckBankNoService extends IService<TCheckBankNo> {
R<TCheckBankNo> checkBankNo(String name, String idNum, String cardNo, String mobile);
CheckBankNoVo checkBankNo(String name, String idNum, String cardNo, String mobile);
}
......@@ -23,6 +23,7 @@ import com.yifu.cloud.plus.v1.check.mapper.TCheckBankNoMapper;
import com.yifu.cloud.plus.v1.check.service.TCanCheckService;
import com.yifu.cloud.plus.v1.check.service.TCheckBankNoService;
import com.yifu.cloud.plus.v1.check.utils.ChecksUtil;
import com.yifu.cloud.plus.v1.check.vo.CheckBankNoVo;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.exception.ErrorCodes;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
......@@ -44,9 +45,12 @@ public class TCheckBankNoServiceImpl extends ServiceImpl<TCheckBankNoMapper, TCh
private final TCanCheckService canCheckService;
@Override
public R<TCheckBankNo> checkBankNo(String name, String idNum, String cardNo, String mobile) {
public CheckBankNoVo checkBankNo(String name, String idNum, String cardNo, String mobile) {
R<TCheckBankNo> res;
CheckBankNoVo vo = new CheckBankNoVo();
if (Common.isEmpty(name) || Common.isEmpty(idNum) || Common.isEmpty(cardNo)){
return R.failed(MsgUtils.getMessage(ErrorCodes.CHECKS_BANK_NO_REQUEST_PARAM_ERROR));
vo.setRes(R.failed(MsgUtils.getMessage(ErrorCodes.CHECKS_BANK_NO_REQUEST_PARAM_ERROR)));
return vo;
}
synchronized (this){
TCheckBankNo checkBankNo = baseMapper.selectOne(Wrappers.<TCheckBankNo>query().lambda()
......@@ -55,13 +59,15 @@ public class TCheckBankNoServiceImpl extends ServiceImpl<TCheckBankNoMapper, TCh
.eq(TCheckBankNo::getIdNum,idNum)
.last(CommonConstants.LAST_ONE_SQL));
if (Common.isNotNull(checkBankNo)){
return R.ok(checkBankNo);
vo.setRes(R.ok(checkBankNo));
return vo;
}
R<TCheckBankNo> res = ChecksUtil.checkBankNo(name,idNum,cardNo,mobile,canCheckService.getCanCheck());
if (Common.isNotNull(res) && Common.isNotNull(res.getData())){
baseMapper.insert(res.getData());
R<TCheckBankNo> resR = ChecksUtil.checkBankNo(name,idNum,cardNo,mobile,canCheckService.getCanCheck());
if (Common.isNotNull(resR) && Common.isNotNull(resR.getData())){
baseMapper.insert(resR.getData());
}
return res;
vo.setRes(resR);
return vo;
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment