新增了放心签的对接
This commit is contained in:
parent
656b466917
commit
f29c161cc1
@ -5,27 +5,31 @@ import cn.hutool.http.HttpResponse;
|
||||
import cn.hutool.json.JSONObject;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import lombok.Getter;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import net.lab1024.sa.common.common.exception.BusinessException;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
@Slf4j
|
||||
@Component
|
||||
@Getter
|
||||
public class Base {
|
||||
private static final ObjectMapper objectMapper = new ObjectMapper();
|
||||
|
||||
@Value("${fxq.client-id}")
|
||||
private static String clientId;
|
||||
private String clientId;
|
||||
|
||||
@Value("${fxq.client-secret}")
|
||||
private static String clientSecret;
|
||||
private String clientSecret;
|
||||
|
||||
@Value("${fxq.client-url}")
|
||||
private static String clientUrl;
|
||||
private String clientUrl;
|
||||
|
||||
@Resource
|
||||
private RedisTemplate<String, String> redisTemplate;
|
||||
@ -55,22 +59,22 @@ public class Base {
|
||||
headers.forEach(request::header);
|
||||
}
|
||||
|
||||
log.info("获取app数据参数:{}",jsonData);
|
||||
|
||||
try (HttpResponse response = request.execute()) {
|
||||
JSONObject json = JSONUtil.parseObj(response.body());
|
||||
|
||||
log.info("获取app数据返回:{}",json);
|
||||
|
||||
int code = json.getInt("code", -1);
|
||||
if (code == 10000) {
|
||||
return response.body();
|
||||
} else if (code == 10005) {
|
||||
if (code == 10005) {
|
||||
// token 失效,重新获取
|
||||
getAccessToken();
|
||||
|
||||
return postJson(url,jsonData,headers);
|
||||
}else{
|
||||
throw new BusinessException(json.getStr("message", "操作失败"));
|
||||
}
|
||||
|
||||
return response.body();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -1,16 +1,47 @@
|
||||
package net.lab1024.sa.admin.extend.fangxinqian.company;
|
||||
|
||||
import cn.hutool.http.HttpRequest;
|
||||
import cn.hutool.http.HttpResponse;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import net.lab1024.sa.admin.extend.fangxinqian.Base;
|
||||
import net.lab1024.sa.common.common.exception.BusinessException;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 企业账号
|
||||
*/
|
||||
@Slf4j
|
||||
@Component
|
||||
public class Company extends Base {
|
||||
public String register2p1(){
|
||||
return "1";
|
||||
/**
|
||||
* 添加账号(个人账号未创建)
|
||||
*/
|
||||
public RegisterPResponse registerPResponse(){
|
||||
// 处理参数
|
||||
Map<String, Object> requestData = new HashMap<>();
|
||||
requestData.put("uid", "duanshuli"); // 接入方系统中用户的标识
|
||||
requestData.put("mobile", "18601047315");
|
||||
requestData.put("orgName", "北京医药科学技术发展协会");
|
||||
|
||||
String url = getClientUrl() + "company/register2p1";
|
||||
String jsonBody = JSONUtil.toJsonStr(requestData);
|
||||
log.info("获取app数据参数:{}",jsonBody);
|
||||
|
||||
String response = postJson(url,jsonBody,null);
|
||||
RegisterPResponse result = JSONUtil.toBean(response, RegisterPResponse.class);
|
||||
if (result.getCode() != 10000){
|
||||
if (!Objects.equals(result.getMessage(), "")){
|
||||
throw new BusinessException(result.getMessage());
|
||||
}else{
|
||||
throw new BusinessException("失败");
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
@ -0,0 +1,36 @@
|
||||
package net.lab1024.sa.admin.extend.fangxinqian.company;
|
||||
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class RegisterPResponse {
|
||||
private int code;
|
||||
|
||||
private String message;
|
||||
|
||||
private List<GetRegisterPData> data;
|
||||
|
||||
private String requestId;
|
||||
|
||||
/**
|
||||
* 根据统一标签列表 - 详细数据
|
||||
*/
|
||||
@Data
|
||||
public static class GetRegisterPData {
|
||||
|
||||
/**
|
||||
* 接入方用户唯一标识
|
||||
*/
|
||||
private String uid;
|
||||
|
||||
/**
|
||||
* 企业主体在放心签平台与接入方关联的唯一性标识
|
||||
*/
|
||||
@JsonProperty("unionId")
|
||||
private String unionId;
|
||||
}
|
||||
}
|
||||
@ -3,16 +3,25 @@ package net.lab1024.sa.admin.module.app.expert.controller;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import net.lab1024.sa.admin.constant.AdminSwaggerTagConst;
|
||||
import net.lab1024.sa.admin.module.app.expert.admin.*;
|
||||
import net.lab1024.sa.admin.module.app.expert.dao.CasePlatformBankDao;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.entity.CasePlatformBankEntity;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.entity.FxqExpertTaskEntity;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.vo.CasePlatformBankVo;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.vo.GetExpertSignVo;
|
||||
import net.lab1024.sa.admin.module.app.expert.service.ExpertService;
|
||||
import net.lab1024.sa.admin.module.app.expert.service.ExpertWhiteEntityService;
|
||||
import net.lab1024.sa.admin.module.app.medicalrecord.dao.MedicalRecorDao;
|
||||
import net.lab1024.sa.admin.module.app.medicalrecord.domain.MedicalRecordUpdateForm;
|
||||
import net.lab1024.sa.admin.module.business.area.domain.vo.ProvVO;
|
||||
import net.lab1024.sa.admin.module.business.area.service.AreaService;
|
||||
import net.lab1024.sa.admin.module.business.bankcard.domain.form.CaseplatformBankAddForm;
|
||||
import net.lab1024.sa.admin.module.business.bankcard.service.CaseplatformBankService;
|
||||
import net.lab1024.sa.admin.module.business.captcha.service.CaptchaService;
|
||||
import net.lab1024.sa.admin.module.system.login.service.LoginService;
|
||||
import net.lab1024.sa.common.common.annoation.NoNeedLogin;
|
||||
@ -21,6 +30,7 @@ import net.lab1024.sa.common.common.domain.ResponseDTO;
|
||||
import net.lab1024.sa.common.common.util.Sha256Util;
|
||||
import net.lab1024.sa.common.common.util.SmartBeanUtil;
|
||||
import net.lab1024.sa.common.common.util.SmartRequestUtil;
|
||||
import net.lab1024.sa.common.common.wangyi.yidun.sdk.BankCardCheckAPI;
|
||||
import net.lab1024.sa.common.module.support.captcha.domain.CaptchaVO;
|
||||
import net.lab1024.sa.common.module.support.config.ConfigKeyEnum;
|
||||
import net.lab1024.sa.common.module.support.config.ConfigService;
|
||||
@ -115,6 +125,12 @@ public class ExpertController {
|
||||
@Autowired
|
||||
private ExpertWhiteEntityService expertWhiteEntityService;
|
||||
|
||||
@Autowired
|
||||
private CasePlatformBankDao casePlatformBankDao;
|
||||
|
||||
@Autowired
|
||||
private CaseplatformBankService caseplatformBankService;
|
||||
|
||||
@ApiOperation("获取验证码")
|
||||
@GetMapping("/user/getCaptcha")
|
||||
@NoNeedLogin
|
||||
@ -583,4 +599,41 @@ public class ExpertController {
|
||||
ResponseDTO responseDTO = JSON.parseObject(result, ResponseDTO.class);
|
||||
return responseDTO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取专家银行卡数据
|
||||
*/
|
||||
@ApiOperation(value = "获取专家银行卡数据")
|
||||
@GetMapping("/user/getBank")
|
||||
public ResponseDTO<CasePlatformBankVo> getExpertSign() {
|
||||
Long expertId = SmartRequestUtil.getRequestUserId();
|
||||
if (expertId == null) {
|
||||
return ResponseDTO.error(LOGIN_STATE_INVALID);
|
||||
}
|
||||
|
||||
// 获取银行卡数据
|
||||
LambdaQueryWrapper<CasePlatformBankEntity> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(CasePlatformBankEntity::getExpertId, expertId);
|
||||
CasePlatformBankEntity casePlatformBank = casePlatformBankDao.selectOne(queryWrapper);
|
||||
CasePlatformBankVo g = SmartBeanUtil.copy(casePlatformBank, CasePlatformBankVo.class);
|
||||
|
||||
return ResponseDTO.app_ok(g);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加专家银行卡数据
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "添加专家银行卡数据")
|
||||
@PostMapping("/user/addBank")
|
||||
public ResponseDTO<String> bankVerify(@RequestBody @Valid CaseplatformBankAddForm addForm) {
|
||||
boolean check = BankCardCheckAPI.check(addForm.getIdCardName(), addForm.getIdCardNo(), addForm.getBankCardNo());
|
||||
if(check){
|
||||
return caseplatformBankService.add(addForm);
|
||||
}else {
|
||||
return ResponseDTO.error(ExpertBankVerifyFail);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -0,0 +1,112 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.controller;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import net.lab1024.sa.admin.constant.AdminSwaggerTagConst;
|
||||
import net.lab1024.sa.admin.module.app.expert.admin.*;
|
||||
import net.lab1024.sa.admin.module.app.expert.dao.FxqExpertTaskDao;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.entity.FxqExpertTaskEntity;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.vo.GetExpertSignVo;
|
||||
import net.lab1024.sa.admin.module.app.expert.service.ExpertService;
|
||||
import net.lab1024.sa.admin.module.app.expert.service.ExpertWhiteEntityService;
|
||||
import net.lab1024.sa.admin.module.app.medicalrecord.dao.MedicalRecorDao;
|
||||
import net.lab1024.sa.admin.module.business.area.domain.vo.ProvVO;
|
||||
import net.lab1024.sa.admin.module.business.area.service.AreaService;
|
||||
import net.lab1024.sa.admin.module.business.captcha.service.CaptchaService;
|
||||
import net.lab1024.sa.admin.module.system.login.service.LoginService;
|
||||
import net.lab1024.sa.common.common.annoation.NoNeedLogin;
|
||||
import net.lab1024.sa.common.common.constant.RequestHeaderConst;
|
||||
import net.lab1024.sa.common.common.domain.ResponseDTO;
|
||||
import net.lab1024.sa.common.common.util.Sha256Util;
|
||||
import net.lab1024.sa.common.common.util.SmartBeanUtil;
|
||||
import net.lab1024.sa.common.common.util.SmartRequestUtil;
|
||||
import net.lab1024.sa.common.module.support.captcha.domain.CaptchaVO;
|
||||
import net.lab1024.sa.common.module.support.config.ConfigKeyEnum;
|
||||
import net.lab1024.sa.common.module.support.config.ConfigService;
|
||||
import net.lab1024.sa.common.module.support.config.domain.ConfigVO;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.validation.Valid;
|
||||
import java.io.*;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import static net.lab1024.sa.common.common.code.UserErrorCode.*;
|
||||
|
||||
@Slf4j
|
||||
@RestController
|
||||
@Api(tags = {AdminSwaggerTagConst.App.Expert})
|
||||
public class ExpertFxqController {
|
||||
@Resource
|
||||
private FxqExpertTaskDao fxqExpertTaskDao;
|
||||
|
||||
/**
|
||||
* 获取专家协议签署详情
|
||||
*/
|
||||
@ApiOperation(value = "获取专家协议签署详情")
|
||||
@GetMapping("/expert/sign")
|
||||
public ResponseDTO<GetExpertSignVo> getExpertSign() {
|
||||
Long expertId = SmartRequestUtil.getRequestUserId();
|
||||
if (expertId == null) {
|
||||
return ResponseDTO.error(LOGIN_STATE_INVALID);
|
||||
}
|
||||
|
||||
GetExpertSignVo g = new GetExpertSignVo();
|
||||
g.setTaskStatus(2);
|
||||
|
||||
// 获取协议签署情况
|
||||
LambdaQueryWrapper<FxqExpertTaskEntity> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(FxqExpertTaskEntity::getExpertId, expertId);
|
||||
FxqExpertTaskEntity fxqExpertTask = fxqExpertTaskDao.selectOne(queryWrapper);
|
||||
if (fxqExpertTask == null) {
|
||||
return ResponseDTO.app_ok(g);
|
||||
}
|
||||
|
||||
if (fxqExpertTask.getTaskStatus() == 20){
|
||||
g.setTaskStatus(1);
|
||||
g.setTaskFileUrl(fxqExpertTask.getTaskFileUrl());
|
||||
}
|
||||
|
||||
return ResponseDTO.app_ok(g);
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 放心签认证
|
||||
// */
|
||||
// @ApiOperation(value = "获取专家协议签署详情")
|
||||
// @GetMapping("/expert/sign")
|
||||
// public ResponseDTO<GetExpertSignVo> getExpertSign() {
|
||||
// Long expertId = SmartRequestUtil.getRequestUserId();
|
||||
// if (expertId == null) {
|
||||
// return ResponseDTO.error(LOGIN_STATE_INVALID);
|
||||
// }
|
||||
//
|
||||
// GetExpertSignVo g = new GetExpertSignVo();
|
||||
// g.setTaskStatus(2);
|
||||
//
|
||||
// // 获取协议签署情况
|
||||
// LambdaQueryWrapper<FxqExpertTaskEntity> queryWrapper = new LambdaQueryWrapper<>();
|
||||
// queryWrapper.eq(FxqExpertTaskEntity::getExpertId, expertId);
|
||||
// FxqExpertTaskEntity fxqExpertTask = fxqExpertTaskDao.selectOne(queryWrapper);
|
||||
// if (fxqExpertTask == null) {
|
||||
// return ResponseDTO.app_ok(g);
|
||||
// }
|
||||
//
|
||||
// if (fxqExpertTask.getTaskStatus() == 20){
|
||||
// g.setTaskStatus(1);
|
||||
// g.setTaskFileUrl(fxqExpertTask.getTaskFileUrl());
|
||||
// }
|
||||
//
|
||||
// return ResponseDTO.app_ok(g);
|
||||
// }
|
||||
}
|
||||
@ -39,21 +39,4 @@ public class ExpertSignController {
|
||||
ExpertSignVO expertSign = expertSignService.getExpertSign();
|
||||
return ResponseDTO.app_ok(expertSign);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加专家 签名
|
||||
* 认证银行卡
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "添加专家 签名 & 认证银行卡")
|
||||
@PostMapping("/user/addBank")
|
||||
public ResponseDTO<String> bankVerify(@RequestBody @Valid CaseplatformBankAddForm addForm) {
|
||||
boolean check = BankCardCheckAPI.check(addForm.getName(), addForm.getIdCardNo(), addForm.getBankCardNo());
|
||||
if(check){
|
||||
return caseplatformBankService.add(addForm);
|
||||
}else {
|
||||
return ResponseDTO.error(ExpertBankVerifyFail);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -0,0 +1,13 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.dao;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.entity.CasePlatformBankEntity;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.entity.FxqExpertTaskEntity;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Mapper
|
||||
@Component
|
||||
public interface CasePlatformBankDao extends BaseMapper<CasePlatformBankEntity> {
|
||||
|
||||
}
|
||||
@ -0,0 +1,12 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.dao;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import net.lab1024.sa.admin.module.app.expert.domain.entity.FxqExpertTaskEntity;
|
||||
import org.apache.ibatis.annotations.*;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Mapper
|
||||
@Component
|
||||
public interface FxqExpertTaskDao extends BaseMapper<FxqExpertTaskEntity> {
|
||||
|
||||
}
|
||||
@ -0,0 +1,76 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.domain.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 lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 病例平台-专家银行卡信息实体类
|
||||
*/
|
||||
@TableName("`t_caseplatform_bank`") // 对应数据库表名
|
||||
@Data
|
||||
public class CasePlatformBankEntity {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 专家id
|
||||
*/
|
||||
@TableField("expert_id")
|
||||
private Long expertId;
|
||||
|
||||
/**
|
||||
* 身份证姓名
|
||||
*/
|
||||
@TableField("id_card_name")
|
||||
private String idCardName;
|
||||
|
||||
/**
|
||||
* 身份证号码
|
||||
*/
|
||||
@TableField("id_card_no")
|
||||
private String idCardNo;
|
||||
|
||||
/**
|
||||
* 银行卡号
|
||||
*/
|
||||
@TableField("bank_card_no")
|
||||
private String bankCardNo;
|
||||
|
||||
/**
|
||||
* 开户行名称
|
||||
*/
|
||||
@TableField("bank_name")
|
||||
private String bankName;
|
||||
|
||||
/**
|
||||
* 省ID
|
||||
*/
|
||||
@TableField("prov_id")
|
||||
private Integer provinceId;
|
||||
|
||||
/**
|
||||
* 市ID
|
||||
*/
|
||||
@TableField("city_id")
|
||||
private Integer cityId;
|
||||
|
||||
/**
|
||||
* 区ID
|
||||
*/
|
||||
@TableField("county_id")
|
||||
private Integer countyId;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@TableField("create_time")
|
||||
private LocalDateTime createTime;
|
||||
}
|
||||
@ -0,0 +1,77 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.domain.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 lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 病例-放心签-签署任务实体类
|
||||
*/
|
||||
@Data
|
||||
@TableName("`t_caseplatform_fxq_expert_task`") // 指定数据库表名
|
||||
public class FxqExpertTaskEntity {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 专家id
|
||||
*/
|
||||
@TableField("expert_id")
|
||||
private Long expertId;
|
||||
|
||||
/**
|
||||
* 签署编号
|
||||
*/
|
||||
@TableField("task_no")
|
||||
private String taskNo;
|
||||
|
||||
/**
|
||||
* 签署模板id
|
||||
*/
|
||||
@TableField("template_id")
|
||||
private Long templateId;
|
||||
|
||||
/**
|
||||
* 签署任务状态:
|
||||
* -30:已过期
|
||||
* -20:已撤销
|
||||
* -10:已拒签
|
||||
* 0:发起签署
|
||||
* 5:待编辑
|
||||
* 10:待签署
|
||||
* 20:已完成
|
||||
*/
|
||||
@TableField("task_status")
|
||||
private Integer taskStatus;
|
||||
|
||||
/**
|
||||
* 签署完成时间
|
||||
*/
|
||||
@TableField("signTime")
|
||||
private LocalDateTime signTime;
|
||||
|
||||
/**
|
||||
* 签署协议的预览地址(只有签署成功后才存在)
|
||||
*/
|
||||
@TableField("task_file_url")
|
||||
private String taskFileUrl;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@TableField("create_time")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
@TableField("update_time")
|
||||
private LocalDateTime updateTime;
|
||||
}
|
||||
@ -0,0 +1,46 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.domain.vo;
|
||||
|
||||
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.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
@Data
|
||||
public class CasePlatformBankVo {
|
||||
@ApiModelProperty(value = "主键")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "专家id")
|
||||
private Long expertId;
|
||||
|
||||
@ApiModelProperty(value = "身份证姓名")
|
||||
private String idCardName;
|
||||
|
||||
@ApiModelProperty(value = "身份证")
|
||||
private String idCardNo;
|
||||
|
||||
@ApiModelProperty(value = "银行卡")
|
||||
private String bankCardNo;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "开户行")
|
||||
private String bankName;
|
||||
|
||||
@ApiModelProperty(value = "省")
|
||||
private Integer provId;
|
||||
|
||||
@ApiModelProperty(value = "市")
|
||||
private Integer cityId;
|
||||
|
||||
@ApiModelProperty(value = "区")
|
||||
@JsonProperty("county_id")
|
||||
private Integer countyId;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
package net.lab1024.sa.admin.module.app.expert.domain.vo;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
@Data
|
||||
public class GetExpertSignVo {
|
||||
/**
|
||||
* 签署状态(1:已签署 2:未签署)
|
||||
*/
|
||||
@ApiModelProperty(value = "签署状态", required = true)
|
||||
private Integer taskStatus;
|
||||
|
||||
@ApiModelProperty(value = "签署协议的预览地址(只有签署成功后才存在)", required = true)
|
||||
private String taskFileUrl;
|
||||
}
|
||||
@ -23,7 +23,7 @@ public class CaseplatformBankAddForm extends ExpertSignAddForm {
|
||||
|
||||
@ApiModelProperty(value = "姓名", required = true)
|
||||
@NotBlank(message = "姓名 不能为空")
|
||||
private String name;
|
||||
private String idCardName;
|
||||
|
||||
@ApiModelProperty(value = "开户行", required = true)
|
||||
@NotBlank(message = "开户行 不能为空")
|
||||
|
||||
@ -66,15 +66,6 @@ public class CaseplatformBankService {
|
||||
caseplatformBankDao.updateById(caseplatformBankEntity);
|
||||
}
|
||||
|
||||
|
||||
String signImg = addForm.getSignImg();
|
||||
ExpertSignVO expertSign = expertSignDao.getExpertSign(expertId);
|
||||
if(expertSign == null){
|
||||
expertSignDao.addExpertSign(expertId, signImg);
|
||||
return ResponseDTO.app_ok();
|
||||
}else{
|
||||
expertSignDao.updateById(expertSign.getId(), signImg);
|
||||
}
|
||||
return ResponseDTO.app_ok();
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user