注册增加身份证相关字段
parent
d50f9a709d
commit
0b47bfe55b
|
|
@ -66,4 +66,12 @@ public class BizAuditConfigController {
|
||||||
return R.success(bizAuditConfigService.paging(pageParam, bizAuditConfigEntity));
|
return R.success(bizAuditConfigService.paging(pageParam, bizAuditConfigEntity));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 下载文件
|
||||||
|
*/
|
||||||
|
@GetMapping("/copy")
|
||||||
|
public void copy() {
|
||||||
|
bizAuditConfigService.copy();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
package com.njzscloud.supervisory.biz.pojo.entity;
|
package com.njzscloud.supervisory.biz.pojo.entity;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.*;
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
import com.njzscloud.common.mp.support.handler.j.JsonTypeHandler;
|
|
||||||
import com.njzscloud.supervisory.biz.constant.AuditStatus;
|
import com.njzscloud.supervisory.biz.constant.AuditStatus;
|
||||||
import com.njzscloud.supervisory.biz.constant.BizObj;
|
import com.njzscloud.supervisory.biz.constant.BizObj;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
|
|
@ -10,7 +9,6 @@ import lombok.experimental.Accessors;
|
||||||
|
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.time.LocalDateTime;
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 企业信息
|
* 企业信息
|
||||||
|
|
@ -77,10 +75,11 @@ public class BizCompanyEntity {
|
||||||
*/
|
*/
|
||||||
private String legalRepresentative;
|
private String legalRepresentative;
|
||||||
|
|
||||||
@TableField(typeHandler = JsonTypeHandler.class)
|
private String idcard;
|
||||||
private List<String> idcard;
|
|
||||||
private LocalDate idcardStartTime;
|
private LocalDate idcardStartTime;
|
||||||
private LocalDate idcardEndTime;
|
private LocalDate idcardEndTime;
|
||||||
|
private String idcardFront;
|
||||||
|
private String idcardBack;
|
||||||
/**
|
/**
|
||||||
* 省; 代码
|
* 省; 代码
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ import lombok.ToString;
|
||||||
import lombok.experimental.Accessors;
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 企业信息
|
* 企业信息
|
||||||
|
|
@ -57,9 +56,11 @@ public class AddBizCompanyParam {
|
||||||
* 法人名称
|
* 法人名称
|
||||||
*/
|
*/
|
||||||
private String legalRepresentative;
|
private String legalRepresentative;
|
||||||
private List<String> idcard;
|
private String idcard;
|
||||||
private LocalDate idcardStartTime;
|
private LocalDate idcardStartTime;
|
||||||
private LocalDate idcardEndTime;
|
private LocalDate idcardEndTime;
|
||||||
|
private String idcardFront;
|
||||||
|
private String idcardBack;
|
||||||
/**
|
/**
|
||||||
* 省; 代码
|
* 省; 代码
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,11 @@ public class ModifyBizCompanyParam {
|
||||||
* 业务对象; 字典代码:biz_obj
|
* 业务对象; 字典代码:biz_obj
|
||||||
*/
|
*/
|
||||||
private BizObj bizObj;
|
private BizObj bizObj;
|
||||||
|
private String idcard;
|
||||||
|
private LocalDate idcardStartTime;
|
||||||
|
private LocalDate idcardEndTime;
|
||||||
|
private String idcardFront;
|
||||||
|
private String idcardBack;
|
||||||
/**
|
/**
|
||||||
* 企业名称
|
* 企业名称
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,11 @@ package com.njzscloud.supervisory.biz.service;
|
||||||
|
|
||||||
import cn.hutool.core.lang.Assert;
|
import cn.hutool.core.lang.Assert;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import com.aliyun.oss.ClientBuilderConfiguration;
|
||||||
|
import com.aliyun.oss.OSS;
|
||||||
|
import com.aliyun.oss.OSSClientBuilder;
|
||||||
|
import com.aliyun.oss.common.auth.DefaultCredentialProvider;
|
||||||
|
import com.aliyun.oss.common.comm.SignVersion;
|
||||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
@ -48,7 +53,7 @@ public class BizAuditConfigService extends ServiceImpl<BizAuditConfigMapper, Biz
|
||||||
|
|
||||||
String areaRole = bizAuditConfigEntity.getAreaRole();
|
String areaRole = bizAuditConfigEntity.getAreaRole();
|
||||||
if (StrUtil.isNotBlank(areaRole)) {
|
if (StrUtil.isNotBlank(areaRole)) {
|
||||||
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getCityRole()), () -> Exceptions.clierr("市级审核员不能为空"));
|
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getCityRole()), () -> Exceptions.clierr("市级审核员不能为空"));
|
||||||
}
|
}
|
||||||
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getCityRole()), () -> Exceptions.clierr("市级审核员不能为空"));
|
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getCityRole()), () -> Exceptions.clierr("市级审核员不能为空"));
|
||||||
this.save(bizAuditConfigEntity);
|
this.save(bizAuditConfigEntity);
|
||||||
|
|
@ -92,4 +97,82 @@ public class BizAuditConfigService extends ServiceImpl<BizAuditConfigMapper, Biz
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
OSS oss(String accessKey, String secretKey, String endpoint, String region) {
|
||||||
|
ClientBuilderConfiguration clientBuilderConfiguration = new ClientBuilderConfiguration();
|
||||||
|
clientBuilderConfiguration.setSignatureVersion(SignVersion.V4);
|
||||||
|
DefaultCredentialProvider credentialProvider = new DefaultCredentialProvider(accessKey, secretKey);
|
||||||
|
return OSSClientBuilder.create()
|
||||||
|
.endpoint(endpoint)
|
||||||
|
.region(region)
|
||||||
|
.credentialsProvider(credentialProvider)
|
||||||
|
.clientConfiguration(clientBuilderConfiguration)
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* public static String uploadFile(OSS oss,String objectName, String contentType, InputStream inputStream) {
|
||||||
|
try {
|
||||||
|
ObjectMetadata objectMetadata = new ObjectMetadata();
|
||||||
|
if (StrUtil.isNotBlank(contentType)) objectMetadata.setContentType(contentType);
|
||||||
|
oss.putObject("cdn-zsy", objectName, inputStream, objectMetadata);
|
||||||
|
return "/" + "cdn-zsy" + "/" + objectName;
|
||||||
|
} catch (OSSException oe) {
|
||||||
|
log.error("阿里云上传文件失败,错误信息:{}、错误码:{}、请求标识:{}、主机标识:{}、存储桶:{}、对象名称:{}",
|
||||||
|
oe.getErrorMessage(),
|
||||||
|
oe.getErrorCode(),
|
||||||
|
oe.getRequestId(),
|
||||||
|
oe.getHostId(),
|
||||||
|
BUCKET_NAME,
|
||||||
|
objectName);
|
||||||
|
throw Exceptions.error("文件服务器错误");
|
||||||
|
} catch (ClientException ce) {
|
||||||
|
log.error("阿里云上传文件失败,错误信息:{}、存储桶:{}、对象名称:{}",
|
||||||
|
ce.getMessage(),
|
||||||
|
BUCKET_NAME,
|
||||||
|
objectName);
|
||||||
|
throw Exceptions.error("文件服务器错误");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Tuple2<InputStream, String> obtainFile(OSS oss,String bucketName, String objectName) {
|
||||||
|
try {
|
||||||
|
OSSObject response = CLIENT.getObject(new GetObjectRequest(bucketName, objectName));
|
||||||
|
ObjectMetadata objectMetadata = response.getObjectMetadata();
|
||||||
|
String contentType = objectMetadata.getContentType();
|
||||||
|
InputStream objectContent = response.getObjectContent();
|
||||||
|
return Tuple2.create(objectContent, contentType);
|
||||||
|
} catch (OSSException oe) {
|
||||||
|
log.error("阿里云下载文件失败,错误信息:{}、错误码:{}、请求标识:{}、主机标识:{}、存储桶:{}、对象名称:{}",
|
||||||
|
oe.getErrorMessage(),
|
||||||
|
oe.getErrorCode(),
|
||||||
|
oe.getRequestId(),
|
||||||
|
oe.getHostId(),
|
||||||
|
bucketName,
|
||||||
|
objectName);
|
||||||
|
// throw Exceptions.error("文件服务器错误");
|
||||||
|
} catch (ClientException ce) {
|
||||||
|
log.error("阿里云下载文件失败,错误信息:{}、存储桶:{}、对象名称:{}",
|
||||||
|
ce.getMessage(),
|
||||||
|
bucketName,
|
||||||
|
objectName);
|
||||||
|
// throw Exceptions.error("文件服务器错误");
|
||||||
|
}
|
||||||
|
return Tuple2.create(new ByteArrayInputStream(new byte[0]), "");
|
||||||
|
} */
|
||||||
|
|
||||||
|
public void copy() {
|
||||||
|
OSS oss1 = oss(
|
||||||
|
"LTAI5tJJu2WayYchExrT5W1E",
|
||||||
|
"zllX0ZJ1EwsZXT6dE6swCLgTF4ImGg",
|
||||||
|
"oss-cn-shanghai.aliyuncs.com",
|
||||||
|
"cn-shanghai"
|
||||||
|
);
|
||||||
|
OSS oss2 = oss(
|
||||||
|
"LTAI5tJJu2WayYchExrT5W1E",
|
||||||
|
"zllX0ZJ1EwsZXT6dE6swCLgTF4ImGg",
|
||||||
|
"oss-cn-shanghai.aliyuncs.com",
|
||||||
|
"cn-shanghai"
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,9 @@ import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 大屏
|
||||||
|
*/
|
||||||
@Slf4j
|
@Slf4j
|
||||||
@CrossOrigin
|
@CrossOrigin
|
||||||
@RestController
|
@RestController
|
||||||
|
|
@ -31,14 +34,18 @@ public class StatisticsController {
|
||||||
return R.success(statisticsService.obtainOrder(userId));
|
return R.success(statisticsService.obtainOrder(userId));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆监管
|
||||||
|
*/
|
||||||
@GetMapping("/supervision/obtain_data")
|
@GetMapping("/supervision/obtain_data")
|
||||||
public R<?> obtainData1() {
|
public R<?> obtainData1() {
|
||||||
// long l = System.currentTimeMillis();
|
|
||||||
Map<String, Object> data = supervisionStatisticsService.obtainData();
|
Map<String, Object> data = supervisionStatisticsService.obtainData();
|
||||||
return R.success(data);
|
return R.success(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 首页
|
||||||
|
*/
|
||||||
@GetMapping("/first_page")
|
@GetMapping("/first_page")
|
||||||
public R<Map<String, Object>> firstPage(@RequestParam(value = "trendStatisticsType", required = false, defaultValue = "1") Integer trendStatisticsType) {
|
public R<Map<String, Object>> firstPage(@RequestParam(value = "trendStatisticsType", required = false, defaultValue = "1") Integer trendStatisticsType) {
|
||||||
return R.success(supervisionStatisticsService.firstPage(trendStatisticsType));
|
return R.success(supervisionStatisticsService.firstPage(trendStatisticsType));
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ import lombok.ToString;
|
||||||
import lombok.experimental.Accessors;
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
|
|
@ -115,9 +114,14 @@ public class UserRegisterParam {
|
||||||
* 法人名称
|
* 法人名称
|
||||||
*/
|
*/
|
||||||
private String legalRepresentative;
|
private String legalRepresentative;
|
||||||
private List<String> idcard;
|
/**
|
||||||
|
* 身份证号
|
||||||
|
*/
|
||||||
|
private String idcard;
|
||||||
private LocalDate idcardStartTime;
|
private LocalDate idcardStartTime;
|
||||||
private LocalDate idcardEndTime;
|
private LocalDate idcardEndTime;
|
||||||
|
private String idcardFront;
|
||||||
|
private String idcardBack;
|
||||||
/**
|
/**
|
||||||
* 省; 代码
|
* 省; 代码
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue