实现签名功能 #67
@@ -26,7 +26,8 @@ import com.ruoyi.system.service.ISysMenuService;
|
||||
* @author ruoyi
|
||||
*/
|
||||
@RestController
|
||||
public class SysLoginController {
|
||||
public class SysLoginController
|
||||
{
|
||||
@Autowired
|
||||
private SysLoginService loginService;
|
||||
|
||||
@@ -36,7 +37,7 @@ public class SysLoginController {
|
||||
@Autowired
|
||||
private SysPermissionService permissionService;
|
||||
@Autowired
|
||||
IdentityAuthenticationService identityAuthenticationService;
|
||||
private IdentityAuthenticationService identityAuthenticationService;
|
||||
|
||||
/**
|
||||
* 登录方法
|
||||
@@ -45,17 +46,20 @@ public class SysLoginController {
|
||||
* @return 结果
|
||||
*/
|
||||
@PostMapping("/login")
|
||||
public AjaxResult login(@RequestBody LoginBody loginBody) {
|
||||
public AjaxResult login(@RequestBody LoginBody loginBody)
|
||||
{
|
||||
AjaxResult ajax = AjaxResult.success();
|
||||
// 生成令牌
|
||||
String token = loginService.login(loginBody.getUsername(), loginBody.getPassword(), loginBody.getCode(),
|
||||
loginBody.getUuid());
|
||||
ajax.put(Constants.TOKEN, token);
|
||||
//判断该用户是否已经实名认证(certificationStatus1已认证0未认证)
|
||||
IdentityAuthentication identityAuthentication=new IdentityAuthentication();
|
||||
identityAuthentication.setUserName(loginBody.getUsername());
|
||||
String status = identityAuthenticationService.checkIsAuthentication(identityAuthentication);
|
||||
ajax.put("certificationStatus", status);
|
||||
|
||||
// IdentityAuthentication identityAuthentication = new IdentityAuthentication();
|
||||
// identityAuthentication.setUserName(loginBody.getUsername());
|
||||
// IdentityAuthentication identityAuthenticationselect = identityAuthenticationService.selectIdentityAuthentication(identityAuthentication);
|
||||
// ajax.put("certificationStatusName", identityAuthenticationselect.getCertificationStatusName());
|
||||
// ajax.put("certificationStatus", identityAuthenticationselect.getCertificationStatus());
|
||||
|
||||
return ajax;
|
||||
}
|
||||
|
||||
@@ -65,7 +69,8 @@ public class SysLoginController {
|
||||
* @return 用户信息
|
||||
*/
|
||||
@GetMapping("getInfo")
|
||||
public AjaxResult getInfo() {
|
||||
public AjaxResult getInfo()
|
||||
{
|
||||
SysUser user = SecurityUtils.getLoginUser().getUser();
|
||||
// 角色集合
|
||||
Set<String> roles = permissionService.getRolePermission(user);
|
||||
@@ -84,7 +89,8 @@ public class SysLoginController {
|
||||
* @return 路由信息
|
||||
*/
|
||||
@GetMapping("getRouters")
|
||||
public AjaxResult getRouters() {
|
||||
public AjaxResult getRouters()
|
||||
{
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
List<SysMenu> menus = menuService.selectMenuTreeByUserId(userId);
|
||||
return AjaxResult.success(menuService.buildMenus(menus));
|
||||
|
||||
+9
-34
@@ -4,15 +4,11 @@ import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.BookSendVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.LogisticsInfoVO;
|
||||
import com.ruoyi.wisdomarbitrate.service.IAdjudicationService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/adjudication")
|
||||
public class AdjudicationController extends BaseController {
|
||||
@@ -25,19 +21,23 @@ public class AdjudicationController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/document")
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:createaward')")
|
||||
public AjaxResult createDocument(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return adjudicationService.createDocument(caseApplication);
|
||||
}
|
||||
|
||||
/**
|
||||
* 裁决书送达(电子邮件)
|
||||
* @param bookSendVO
|
||||
* @param id 案件id
|
||||
* @param appEmail 申请人邮箱
|
||||
* @param resEmail 被申请人邮箱
|
||||
* @param apptrackingNum 申请人快递单号
|
||||
* @param restrackingNum 被申请人快递单号
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/delivery")
|
||||
public AjaxResult sendDocumentByEmail(@RequestBody BookSendVO bookSendVO){
|
||||
return adjudicationService.sendDocumentByEmail(bookSendVO.getId(),bookSendVO.getAppEmail(),bookSendVO.getResEmail(),bookSendVO.getApptrackingNum(),bookSendVO.getRestrackingNum());
|
||||
public AjaxResult sendDocumentByEmail(Long id,String appEmail,String resEmail
|
||||
,String apptrackingNum,String restrackingNum){
|
||||
return adjudicationService.sendDocumentByEmail(id,appEmail,resEmail,apptrackingNum,restrackingNum);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -46,10 +46,8 @@ public class AdjudicationController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/logistics")
|
||||
@PreAuthorize("@ss.hasPermi('delivery:detail')")
|
||||
public AjaxResult getLogisticsInfo(CaseApplication caseApplication){
|
||||
List<LogisticsInfoVO> logisticsInfo = adjudicationService.getLogisticsInfo(caseApplication);
|
||||
return AjaxResult.success(logisticsInfo);
|
||||
return adjudicationService.getLogisticsInfo(caseApplication);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -58,7 +56,6 @@ public class AdjudicationController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/signature")
|
||||
@PreAuthorize("@ss.hasPermi('awardManagement:list:sign')")
|
||||
public AjaxResult signature(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return adjudicationService.signature(caseApplication);
|
||||
}
|
||||
@@ -69,7 +66,6 @@ public class AdjudicationController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/caseFile")
|
||||
@PreAuthorize("@ss.hasPermi('awardManagement:list:file')")
|
||||
public AjaxResult caseFile(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return adjudicationService.caseFile(caseApplication);
|
||||
}
|
||||
@@ -80,28 +76,7 @@ public class AdjudicationController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/service")
|
||||
@PreAuthorize("@ss.hasPermi('awardManagement:list:sendaward')")
|
||||
public AjaxResult service(@RequestBody BookSendVO bookSendVO){
|
||||
return adjudicationService.service(bookSendVO.getId(),bookSendVO.getAppEmail(),bookSendVO.getResEmail(),bookSendVO.getApptrackingNum(),bookSendVO.getRestrackingNum());
|
||||
}
|
||||
/**
|
||||
* 用印(暂时只改案件状态)
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/stamp")
|
||||
@PreAuthorize("@ss.hasPermi('awardManagement:list:signprint')")
|
||||
public AjaxResult stamp(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return adjudicationService.stamp(caseApplication);
|
||||
}
|
||||
|
||||
/**
|
||||
* 档案详情查询
|
||||
* @param id 案件id
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/archives")
|
||||
public AjaxResult getArchivesDetail(Long id){
|
||||
return adjudicationService.getArchivesDetail(id);
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ public class ArbitratorController extends BaseController {
|
||||
/**
|
||||
* 查询仲裁员信息
|
||||
*/
|
||||
// @PreAuthorize("@ss.hasPermi('arbitrator:list')")
|
||||
@PreAuthorize("@ss.hasPermi('arbitrator:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(Arbitrator arbitrator)
|
||||
{
|
||||
|
||||
+49
-41
@@ -1,14 +1,15 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import com.ruoyi.common.annotation.Anonymous;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.SendRoomNoMessageVO;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
@@ -17,9 +18,11 @@ import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/caseApplication")
|
||||
public class CaseApplicationController extends BaseController {
|
||||
@@ -30,9 +33,10 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 查询立案数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(CaseApplication caseApplication) {
|
||||
public TableDataInfo list(CaseApplication caseApplication)
|
||||
{
|
||||
startPage();
|
||||
List<CaseApplication> list = caseApplicationService.selectCaseApplicationList(caseApplication);
|
||||
return getDataTable(list);
|
||||
@@ -41,12 +45,15 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 新增立案数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:add')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:add')")
|
||||
@Log(title = "新增立案数据", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/addCaseApplication")
|
||||
public AjaxResult addCaseApplication(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
|
||||
int caseApplicationCount = caseApplicationService.selectCaseApplicationCount(caseApplication);
|
||||
if(caseApplicationCount>0){
|
||||
return error("新增立案申请'" + caseApplication.getCaseNum() + "'案件编号已存在");
|
||||
}
|
||||
caseApplication.setCreateBy(getUsername());
|
||||
return toAjax(caseApplicationService.insertcaseApplication(caseApplication));
|
||||
}
|
||||
@@ -54,10 +61,11 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 修改立案数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:update')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:edit')")
|
||||
@Log(title = "修改立案数据", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/editCaseApplication")
|
||||
public AjaxResult editCaseApplication(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult editCaseApplication(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
|
||||
caseApplication.setUpdateBy(getUsername());
|
||||
return toAjax(caseApplicationService.editCaseApplication(caseApplication));
|
||||
@@ -66,10 +74,11 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 提交立案申请
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:submit')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:submit')")
|
||||
@Log(title = "提交立案申请", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/submitCaseApplication")
|
||||
public AjaxResult submitCaseApplication(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult submitCaseApplication(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
|
||||
return toAjax(caseApplicationService.submitCaseApplication(caseApplication));
|
||||
}
|
||||
@@ -77,10 +86,11 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 删除立案数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:delete')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:remove')")
|
||||
@Log(title = "删除立案数据", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/removeCaseApplication")
|
||||
public AjaxResult removeCaseApplication(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult removeCaseApplication(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
|
||||
return toAjax(caseApplicationService.deletecaseApplicationByIds(caseApplication));
|
||||
}
|
||||
@@ -88,9 +98,9 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 查询立案信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:detail')")
|
||||
@PostMapping("/selectCaseApplication")
|
||||
public AjaxResult selectCaseApplication(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult selectCaseApplication(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
CaseApplication caseApplicationselect = caseApplicationService.selectCaseApplication(caseApplication);
|
||||
return success(caseApplicationselect);
|
||||
}
|
||||
@@ -99,22 +109,20 @@ public class CaseApplicationController extends BaseController {
|
||||
* 立案申请导入模板下载
|
||||
*/
|
||||
@PostMapping("/importTemplate")
|
||||
public void importTemplate(HttpServletResponse response) {
|
||||
public void importTemplate(HttpServletResponse response)
|
||||
{
|
||||
ExcelUtil<CaseApplication> util = new ExcelUtil<CaseApplication>(CaseApplication.class);
|
||||
util.importTemplateExcel(response, "立案申请数据");
|
||||
}
|
||||
|
||||
@Log(title = "立案信息导入", businessType = BusinessType.IMPORT)
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:import')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:import')")
|
||||
@PostMapping("/importData")
|
||||
public AjaxResult importData(MultipartFile file) throws Exception {
|
||||
if(file==null){
|
||||
return warn("请上传文件");
|
||||
}
|
||||
ExcelUtil<CaseApplication> util = new ExcelUtil<CaseApplication>(CaseApplication.class);
|
||||
List<CaseApplication> caseApplicationList = util.importExcel(file.getInputStream());
|
||||
String operName = getUsername();
|
||||
String message = caseApplicationService.importCaseApplication(caseApplicationList, operName);
|
||||
String message = caseApplicationService.importCaseApplication(caseApplicationList,operName);
|
||||
return success(message);
|
||||
}
|
||||
|
||||
@@ -124,27 +132,30 @@ public class CaseApplicationController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:pendTral')")
|
||||
@Log(title = "组庭", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/pendTral")
|
||||
public AjaxResult pendTral(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult pendTral(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
return toAjax(caseApplicationService.pendTral(caseApplication));
|
||||
}
|
||||
|
||||
/**
|
||||
* 组庭审核
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:checkgroup')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:pendTralCheck')")
|
||||
@Log(title = "组庭审核", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/pendTralCheck")
|
||||
public AjaxResult pendTralCheck(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult pendTralCheck(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
return toAjax(caseApplicationService.pendTralCheck(caseApplication));
|
||||
}
|
||||
|
||||
/**
|
||||
* 组庭确认
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:confirmgroup')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:pendTralSure')")
|
||||
@Log(title = "组庭确认", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/pendTralSure")
|
||||
public AjaxResult pendTralSure(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult pendTralSure(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
return toAjax(caseApplicationService.pendTralSure(caseApplication));
|
||||
}
|
||||
|
||||
@@ -154,7 +165,8 @@ public class CaseApplicationController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:verificationArbitrateRecord')")
|
||||
@Log(title = "核验裁决书", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/verificationArbitrateRecord")
|
||||
public AjaxResult verificationArbitrateRecord(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult verificationArbitrateRecord(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
return toAjax(caseApplicationService.verificationArbitrateRecord(caseApplication));
|
||||
}
|
||||
|
||||
@@ -164,28 +176,32 @@ public class CaseApplicationController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:checkArbitrateRecord')")
|
||||
@Log(title = "审核裁决书", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/checkArbitrateRecord")
|
||||
public AjaxResult checkArbitrateRecord(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult checkArbitrateRecord(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
return toAjax(caseApplicationService.checkArbitrateRecord(caseApplication));
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 是否指派仲裁员
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:pendingAppointArbotrar')")
|
||||
@Log(title = "是否指派仲裁员", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/pendingAppointArbotrar")
|
||||
public AjaxResult pendingAppointArbotrar(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult pendingAppointArbotrar(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
return toAjax(caseApplicationService.pendingAppointArbotrar(caseApplication));
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交立案审查
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:check')")
|
||||
@PreAuthorize("@ss.hasPermi('caseApplication:submitCaseApplicationCheck')")
|
||||
@Log(title = "提交立案审查", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/submitCaseApplicationCheck")
|
||||
public AjaxResult submitCaseApplicationCheck(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult submitCaseApplicationCheck(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
|
||||
return toAjax(caseApplicationService.submitCaseApplicationCheck(caseApplication));
|
||||
}
|
||||
@@ -193,22 +209,14 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 确认缴费查询立案信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('paymentManagement:list:detail')")
|
||||
@PostMapping("/selectCaseApplicationConfirm")
|
||||
public AjaxResult selectCaseApplicationConfirm(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult selectCaseApplicationConfirm(@Validated @RequestBody CaseApplication caseApplication)
|
||||
{
|
||||
CaseApplication caseApplicationselect = caseApplicationService.selectCaseApplicationConfirm(caseApplication);
|
||||
return success(caseApplicationselect);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 发送房间号短信
|
||||
*/
|
||||
@Anonymous
|
||||
@PostMapping("/sendRoomNoMessage")
|
||||
public AjaxResult sendRoomNoMessage(@Validated @RequestBody SendRoomNoMessageVO messageVO) {
|
||||
String result = caseApplicationService.sendRoomNoMessage(messageVO);
|
||||
return success(result);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
-3
@@ -6,7 +6,6 @@ import com.ruoyi.wisdomarbitrate.domain.ArbitrateRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseArbitrateService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@@ -23,7 +22,6 @@ public class CaseArbitrateController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@PutMapping("/method")
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:checkarbitrationway')")
|
||||
public AjaxResult examineArbitrateMethod(@Validated @RequestBody CaseApplication caseApplication
|
||||
,Integer opinion){
|
||||
return caseArbitrateService.examineArbitrateMethod(caseApplication,opinion);
|
||||
@@ -35,7 +33,6 @@ public class CaseArbitrateController extends BaseController {
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/writtenHear")
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:hear')")
|
||||
public AjaxResult writtenHear(@Validated @RequestBody ArbitrateRecord arbitrateRecord){
|
||||
return caseArbitrateService.writtenHear(arbitrateRecord);
|
||||
}
|
||||
|
||||
+5
-9
@@ -8,7 +8,6 @@ import com.ruoyi.wisdomarbitrate.domain.dto.CaseEvidenceDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseEvidenceVO;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseEvidenceService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
@@ -38,7 +37,7 @@ public class CaseEvidenceController extends BaseController {
|
||||
@GetMapping("/{id}")
|
||||
public AjaxResult getCaseDetailsById(@PathVariable Long id) {
|
||||
String username = this.getUsername();
|
||||
return caseEvidenceService.getCaseDetailsById(id, username);
|
||||
return caseEvidenceService.getCaseDetailsById(id,username);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -53,17 +52,16 @@ public class CaseEvidenceController extends BaseController {
|
||||
public AjaxResult uploadEvidence(@RequestParam("file") MultipartFile file, Integer annexType, Long id) {
|
||||
String username = this.getUsername();
|
||||
Long userId = this.getUserId();
|
||||
return caseEvidenceService.uploadEvidence(file, annexType, id, username, userId);
|
||||
return caseEvidenceService.uploadEvidence(file, annexType, id,username,userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询当前用户案件列表
|
||||
*
|
||||
* @param identityNum
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/all")
|
||||
public TableDataInfo getCaseListAll(@RequestParam(required = false) String identityNum) {
|
||||
public TableDataInfo getCaseListAll(@RequestParam String identityNum) {
|
||||
startPage();
|
||||
List<CaseEvidenceVO> list = caseEvidenceService.getCaseListAll(identityNum);
|
||||
if (list != null) {
|
||||
@@ -74,23 +72,21 @@ public class CaseEvidenceController extends BaseController {
|
||||
|
||||
/**
|
||||
* 证据确认
|
||||
*
|
||||
* @param caseApplication 案件对象
|
||||
* @return 统一返回结果
|
||||
*/
|
||||
@PutMapping("/confirm")
|
||||
public AjaxResult evidenceConfirmation(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
public AjaxResult evidenceConfirmation(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return caseEvidenceService.evidenceConfirmation(caseApplication);
|
||||
}
|
||||
|
||||
/**
|
||||
* 案件质证
|
||||
*
|
||||
* @param caseEvidenceDTO
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/crossexami")
|
||||
public AjaxResult caseCrossexamination(@Validated @RequestBody CaseEvidenceDTO caseEvidenceDTO) {
|
||||
public AjaxResult caseCrossexamination(@Validated @RequestBody CaseEvidenceDTO caseEvidenceDTO){
|
||||
return caseEvidenceService.caseCrossexamination(caseEvidenceDTO);
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ public class CaseLogRecordController extends BaseController {
|
||||
/**
|
||||
* 查询案件日志列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseLog:list')")
|
||||
@PreAuthorize("@ss.hasPermi('caseLogRecord:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(CaseLogRecord caseLogRecord)
|
||||
{
|
||||
|
||||
-3
@@ -5,7 +5,6 @@ import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICasePaymentService;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CasePayDTO;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@@ -25,7 +24,6 @@ public class CasePaymentController {
|
||||
* @param casePayDTO 缴费传入参数
|
||||
* @return 统一响应结果
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('caseManagement:list:pay')")
|
||||
@PostMapping("/casePay")
|
||||
public AjaxResult casePay(@Validated @RequestBody CasePayDTO casePayDTO) {
|
||||
return paymentService.casePay(casePayDTO);
|
||||
@@ -36,7 +34,6 @@ public class CasePaymentController {
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('paymentManagement:list:payconfirm')")
|
||||
@PutMapping("/confirm")
|
||||
public AjaxResult confirmPayment(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
return paymentService.confirmPayment(caseApplication);
|
||||
|
||||
+22
-9
@@ -1,8 +1,8 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.IdentityAuthentication;
|
||||
import com.ruoyi.wisdomarbitrate.service.IdentityAuthenticationService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -19,22 +19,35 @@ public class IdentityAuthenticationController extends BaseController {
|
||||
private IdentityAuthenticationService identityAuthenticationService;
|
||||
|
||||
/**
|
||||
* 获取EIDtoken
|
||||
* 查询身份认证EIDtoken
|
||||
*/
|
||||
@PostMapping("/selectIdentityAuthenticaEIDtoken")
|
||||
public AjaxResult selectIdentityAuthenticaEIDtoken() {
|
||||
JSONObject tokenResult = identityAuthenticationService.selectIdentityAuthenticaEIDtoken();
|
||||
return success(tokenResult);
|
||||
public AjaxResult selectIdentityAuthenticaEIDtoken()
|
||||
{
|
||||
IdentityAuthentication ientityAuthentication = identityAuthenticationService.selectIdentityAuthenticaEIDtoken();
|
||||
return success(ientityAuthentication);
|
||||
}
|
||||
|
||||
/**
|
||||
* 小程序人脸核身后查询身份认证结果
|
||||
* 查询身份认证结果
|
||||
*/
|
||||
@PostMapping("/selectIdentityAuthenticaRespon")
|
||||
public AjaxResult selectIdentityAuthenticaRespon(@Validated @RequestBody IdentityAuthentication ientityAuthentication) {
|
||||
AjaxResult checkResult = identityAuthenticationService.selectIdentityAuthenticaRespon(ientityAuthentication);
|
||||
return checkResult;
|
||||
public AjaxResult selectIdentityAuthenticaRespon(@Validated @RequestBody IdentityAuthentication ientityAuthentication)
|
||||
{
|
||||
String username = this.getUsername();
|
||||
Long userId = this.getUserId();
|
||||
ientityAuthentication.setUserId(userId);
|
||||
ientityAuthentication.setUserName(username);
|
||||
IdentityAuthentication ientityAuthenticationRes = identityAuthenticationService.selectIdentityAuthenticaRespon( ientityAuthentication);
|
||||
return success(ientityAuthenticationRes);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -166,4 +166,4 @@ identityAuthentication:
|
||||
credentialSecretId: AKID3xfHgroY4MQHvLXUXMwIQL1UjmbBX1Tv
|
||||
credentialSecretKey: INDrIXcT8YmomZBcsy0oNirnU0LTN4X7
|
||||
merchantId: 0NSJ2309281116194321
|
||||
privateKeyHexDecodeinfo: 4c3b311bf7b98969994e85928e069574a1e95777f24d1c510679cc3c2f460faf
|
||||
privateKeyHexDecodeinfo: MHcCAQEEIEw7MRv3uYlpmU6Fko4GlXSh6Vd38k0cUQZ5zDwvRg+voAoGCCqBHM9VAYItoUQDQgAEUdxIAWhGg4LUXf1GoPdb8XMbGudpexPQCuaaRi9BCnNbpaF1kcwRhhsBKvop9ZmW/nOz4wQ1r/iIEOrc9qCXgQ==
|
||||
+17
-8
@@ -136,15 +136,27 @@
|
||||
<dependency>
|
||||
<groupId>com.tencentcloudapi</groupId>
|
||||
<artifactId>tencentcloud-sdk-java</artifactId>
|
||||
<version>3.1.876</version>
|
||||
<version>3.1.270</version>
|
||||
</dependency>
|
||||
|
||||
<!--
|
||||
<dependency>
|
||||
<groupId>com.tencentcloudapi</groupId>
|
||||
<artifactId>tencentcloud-sdk-java-faceid</artifactId>
|
||||
<version>3.1.875</version>
|
||||
<version>3.1.871</version>
|
||||
</dependency>
|
||||
<!--用户信息解密-->
|
||||
-->
|
||||
<dependency>
|
||||
<groupId>com.tencentcloudapi</groupId>
|
||||
<artifactId>tencentcloud-sdk-java-faceid</artifactId>
|
||||
<version>LATEST</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.tencentcloudapi</groupId>
|
||||
<artifactId>tencentcloud-sdk-java-common</artifactId>
|
||||
<version>LATEST</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>cn.hutool</groupId>
|
||||
<artifactId>hutool-all</artifactId>
|
||||
@@ -183,10 +195,7 @@
|
||||
<artifactId>mail</artifactId>
|
||||
<version>1.4.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpclient</artifactId>
|
||||
</dependency>
|
||||
|
||||
|
||||
|
||||
</dependencies>
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
package com.ruoyi.common.config;
|
||||
package com.ruoyi.common.utils;
|
||||
|
||||
public class EsignDemoConfig {
|
||||
public class EsignApplicaConfig {
|
||||
|
||||
// 应用ID
|
||||
public static final String EsignAppId = "7438987614";
|
||||
@@ -0,0 +1,360 @@
|
||||
package com.ruoyi.common.utils;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.JsonArray;
|
||||
import com.google.gson.JsonObject;
|
||||
import com.ruoyi.common.core.domain.entity.EsignHttpResponse;
|
||||
import com.ruoyi.common.enums.EsignRequestType;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.common.utils.bean.SealSignRecord;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public class SignAward {
|
||||
|
||||
private static String eSignHost= EsignApplicaConfig.EsignHost;
|
||||
private static String eSignAppId=EsignApplicaConfig.EsignAppId;
|
||||
private static String eSignAppSecret=EsignApplicaConfig.EsignAppSecret;
|
||||
// public static String fileId = "95d0c307d91e4985bdb8874f6f84daa5";
|
||||
public static String fileId = "a0c2ad21065f48ff8b872412c39d5d3a";
|
||||
|
||||
|
||||
|
||||
public static void main(String[] args) throws EsignDemoException {
|
||||
Gson gson = new Gson();
|
||||
|
||||
SealSignRecord sealSignRecord = new SealSignRecord();
|
||||
|
||||
sealSignRecord.setFileid("a808f1f39a744357a2f018e4ab34c55d");
|
||||
sealSignRecord.setFilename("23893bfd3f2249ffa5c82850c11c482e.pdf");
|
||||
sealSignRecord.setSignFlowid("41e6732b48c54c63a91b2379c352212d");
|
||||
|
||||
|
||||
sealSignRecord.setPensonAccount("18209231185");
|
||||
sealSignRecord.setPensonName("秦桃则");
|
||||
sealSignRecord.setOrgnizeName("西安云美电子科技有限公司");
|
||||
sealSignRecord.setOrgnizeNamePsnAccount("17691338406");
|
||||
sealSignRecord.setOrgnizeNamepsnName("韩超勃");
|
||||
sealSignRecord.setPositionPagepsn("2");
|
||||
|
||||
sealSignRecord.setPositionXpsn(279+20);
|
||||
sealSignRecord.setPositionYpsn(216.336-20);
|
||||
|
||||
sealSignRecord.setPositionPageorg("2");
|
||||
|
||||
sealSignRecord.setPositionXorg(342+30);
|
||||
sealSignRecord.setPositionYorg(185.136);
|
||||
|
||||
|
||||
|
||||
|
||||
/* 发起签署*/
|
||||
// EsignHttpResponse createByFile = createByFile(sealSignRecord);
|
||||
// JsonObject createByFileJsonObject = gson.fromJson(createByFile.getBody(), JsonObject.class);
|
||||
// JsonObject createByFileData = createByFileJsonObject.getAsJsonObject("data");
|
||||
// String signFlowId = createByFileData.get("signFlowId").getAsString();
|
||||
// System.err.println("流程id:"+signFlowId);
|
||||
|
||||
/* 获取文件签名印章位置*/
|
||||
EsignHttpResponse positions = getPositions(sealSignRecord);
|
||||
JsonObject positionsJsonObject = gson.fromJson(positions.getBody(), JsonObject.class);
|
||||
JsonObject positionsData = positionsJsonObject.getAsJsonObject("data");
|
||||
JsonArray keywordPositions = positionsData.get("keywordPositions").getAsJsonArray();
|
||||
System.out.println("获取文件签名印章位置:" +keywordPositions.toString());
|
||||
|
||||
// String signFlowId = "c9955453716344f9971d308abdc13464";
|
||||
//获取合同文件签名链接
|
||||
// EsignHttpResponse signUrl = signUrl(sealSignRecord);
|
||||
// JsonObject signUrlJsonObject = gson.fromJson(signUrl.getBody(), JsonObject.class);
|
||||
// JsonObject signUrlData = signUrlJsonObject.getAsJsonObject("data");
|
||||
// String shortUrl = signUrlData.get("shortUrl").getAsString();
|
||||
// String url = signUrlData.get("url").getAsString();
|
||||
// System.out.println("签署短链接:" +shortUrl);
|
||||
// System.out.println("签署长链接:"+url);
|
||||
|
||||
//获取合同文件用印链接
|
||||
// EsignHttpResponse usesealUrl = usesealUrl(sealSignRecord);
|
||||
// JsonObject usesealUrlJsonObject = gson.fromJson(usesealUrl.getBody(), JsonObject.class);
|
||||
// JsonObject usesealUrlData = usesealUrlJsonObject.getAsJsonObject("data");
|
||||
// String shortusesealUrl = usesealUrlData.get("shortUrl").getAsString();
|
||||
// String sealUrl = usesealUrlData.get("url").getAsString();
|
||||
// System.out.println("签署长链接:" +shortusesealUrl);
|
||||
// System.out.println("签署短链接:"+sealUrl);
|
||||
|
||||
//查询签署流程详情
|
||||
// EsignHttpResponse signFlowDetail = signFlowDetail(sealSignRecord);
|
||||
// JsonObject signFlowDetailJsonObject = gson.fromJson(signFlowDetail.getBody(),JsonObject.class);
|
||||
// System.out.println(signFlowDetailJsonObject);
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询签署流程详情
|
||||
* @return
|
||||
*/
|
||||
public static EsignHttpResponse signFlowDetail(SealSignRecord sealSignRecord) throws EsignDemoException {
|
||||
String signFlowId = sealSignRecord.getSignFlowid();
|
||||
String apiaddr= "/v3/sign-flow/"+ signFlowId + "/detail";
|
||||
String jsonParm = null;
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.GET;
|
||||
//生成签名鉴权方式的的header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId,eSignAppSecret,jsonParm,requestType.name(),apiaddr,true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr,requestType , jsonParm, header,true);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 发起签署
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
*/
|
||||
public static EsignHttpResponse createByFile(SealSignRecord sealSignRecord) throws EsignDemoException {
|
||||
String apiaddr = "/v3/sign-flow/create-by-file";
|
||||
|
||||
String fileId = sealSignRecord.getFileid();
|
||||
String fileName = sealSignRecord.getFilename();
|
||||
|
||||
String psnAccount = sealSignRecord.getPensonAccount();
|
||||
String psnName = sealSignRecord.getPensonName();
|
||||
|
||||
String orgName = sealSignRecord.getOrgnizeName();
|
||||
String orgNamePsnAccount = sealSignRecord.getOrgnizeNamePsnAccount();
|
||||
String orgNamepsnName = sealSignRecord.getOrgnizeNamepsnName();
|
||||
|
||||
String positionPagepsn = sealSignRecord.getPositionPagepsn();
|
||||
double positionXpsn = sealSignRecord.getPositionXpsn();
|
||||
double positionYpsn = sealSignRecord.getPositionYpsn();
|
||||
|
||||
String positionPageorg = sealSignRecord.getPositionPageorg();
|
||||
double positionXorg = sealSignRecord.getPositionXorg();
|
||||
double positionYorg = sealSignRecord.getPositionYorg();
|
||||
|
||||
|
||||
String jsonParm = "{\n" +
|
||||
" \"docs\": [\n" +
|
||||
" {\n" +
|
||||
|
||||
// " \"fileId\": \"5bd34a81e8084acaab3287c019e82fe8\",\n" +
|
||||
" \"fileId\": \"" + fileId + "\",\n" +
|
||||
|
||||
// " \"fileName\": \"477470a7741b4536a200c792b6ddf966.pdf\"\n" +
|
||||
" \"fileName\": \"" + fileName + "\"\n" +
|
||||
|
||||
" }\n" +
|
||||
" ],\n" +
|
||||
" \"signFlowConfig\": {\n" +
|
||||
" \"signFlowTitle\": \"测试合同\",\n" +
|
||||
" \"autoStart\": true,\n" +
|
||||
" \"authConfig\": {\n" +
|
||||
" \"willingnessAuthModes\": [\n" +
|
||||
" \"CODE_SMS\"\n" +
|
||||
" ],\n" +
|
||||
" \"psnAvailableAuthModes\": [\n" +
|
||||
" \"PSN_MOBILE3\"\n" +
|
||||
" ],\n" +
|
||||
" \"orgAvailableAuthModes\": [\n" +
|
||||
" \"ORG_LEGALREP\"\n" +
|
||||
" ]\n" +
|
||||
" },\n" +
|
||||
" \"autoFinish\": true\n" +
|
||||
" },\n" +
|
||||
|
||||
" \"signers\": [\n" +
|
||||
|
||||
" {\n" +
|
||||
|
||||
" \"psnSignerInfo\": {\n" +
|
||||
|
||||
// " \"psnAccount\": \"18209231185\",\n" +
|
||||
" \"psnAccount\": \"" + psnAccount + "\",\n" +
|
||||
|
||||
" \"psnInfo\": {\n" +
|
||||
|
||||
// " \"psnName\": \"秦桃则\"\n" +
|
||||
" \"psnName\": \"" + psnName + "\"\n" +
|
||||
" }\n" +
|
||||
|
||||
|
||||
" },\n" +
|
||||
|
||||
|
||||
" \"signFields\": [\n" +
|
||||
" {\n" +
|
||||
|
||||
// " \"fileId\": \"5bd34a81e8084acaab3287c019e82fe8\",\n" +
|
||||
" \"fileId\": \"" + fileId + "\",\n" +
|
||||
|
||||
" \"normalSignFieldConfig\": {\n" +
|
||||
" \"autoSign\": false,\n" +
|
||||
" \"freeMode\": false,\n" +
|
||||
" \"movableSignField\": false,\n" +
|
||||
" \"signFieldPosition\": {\n" +
|
||||
|
||||
// " \"positionPage\": \"2\",\n" +
|
||||
" \"positionPage\": \"" + positionPagepsn + "\",\n" +
|
||||
|
||||
// " \"positionX\": 310.0,\n" +
|
||||
" \"positionX\": " + positionXpsn + ",\n" +
|
||||
|
||||
// " \"positionY\": 247.536\n" +
|
||||
" \"positionY\": " + positionYpsn + "\n" +
|
||||
|
||||
" },\n" +
|
||||
" \"signFieldStyle\": 1\n" +
|
||||
" },\n" +
|
||||
" \"signFieldType\": 0\n" +
|
||||
" }\n" +
|
||||
" ],\n" +
|
||||
" \"signerType\": 0\n" +
|
||||
" },\n" +
|
||||
|
||||
|
||||
" {\n" +
|
||||
" \"orgSignerInfo\": {\n" +
|
||||
|
||||
// " \"orgName\": \"西安云美电子科技有限公司\",\n" +
|
||||
" \"orgName\": \"" + orgName + "\",\n" +
|
||||
|
||||
" \"transactorInfo\": {\n" +
|
||||
|
||||
|
||||
// " \"psnAccount\": \"17691338406\",\n" +
|
||||
" \"psnAccount\": \"" + orgNamePsnAccount + "\",\n" +
|
||||
|
||||
" \"psnInfo\": {\n" +
|
||||
|
||||
// " \"psnName\": \"韩超勃\"\n" +
|
||||
" \"psnName\": \"" + orgNamepsnName + "\"\n" +
|
||||
" }\n" +
|
||||
|
||||
" }\n" +
|
||||
" },\n" +
|
||||
|
||||
" \"signFields\": [\n" +
|
||||
" {\n" +
|
||||
|
||||
// " \"fileId\": \"5bd34a81e8084acaab3287c019e82fe8\",\n" +
|
||||
" \"fileId\": \"" + fileId + "\",\n" +
|
||||
|
||||
" \"normalSignFieldConfig\": {\n" +
|
||||
" \"autoSign\": false,\n" +
|
||||
" \"freeMode\": false,\n" +
|
||||
|
||||
" \"signFieldPosition\": {\n" +
|
||||
|
||||
// " \"positionPage\": \"2\",\n" +
|
||||
" \"positionPage\": \"" + positionPageorg + "\",\n" +
|
||||
|
||||
// " \"positionX\": 340.0,\n" +
|
||||
" \"positionX\": " + positionXorg + ",\n" +
|
||||
|
||||
// " \"positionY\": 340.736\n" +
|
||||
" \"positionY\": " + positionYorg + "\n" +
|
||||
" },\n" +
|
||||
" \"signFieldStyle\": 1\n" +
|
||||
" },\n" +
|
||||
" \"signFieldType\": 0\n" +
|
||||
" }\n" +
|
||||
" ],\n" +
|
||||
" \"signerType\": 1\n" +
|
||||
" }\n" +
|
||||
|
||||
" ]\n" +
|
||||
"}";
|
||||
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取合同文件签名链接
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
*/
|
||||
public static EsignHttpResponse signUrl(SealSignRecord sealSignRecord) throws EsignDemoException {
|
||||
|
||||
String signFlowId = sealSignRecord.getSignFlowid();
|
||||
String psnAccount = sealSignRecord.getPensonAccount();
|
||||
|
||||
String apiaddr = "/v3/sign-flow/" + signFlowId + "/sign-url";
|
||||
String jsonParm = "{\n" +
|
||||
" \"operator\": {\n" +
|
||||
// " \"psnAccount\":\"18209231185\"\n" +
|
||||
" \"psnAccount\": \"" + psnAccount + "\"\n" +
|
||||
" }\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取合同文件用印链接
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
*/
|
||||
public static EsignHttpResponse usesealUrl(SealSignRecord sealSignRecord) throws EsignDemoException {
|
||||
String signFlowId = sealSignRecord.getSignFlowid();
|
||||
String apiaddr = "/v3/sign-flow/" + signFlowId + "/sign-url";
|
||||
|
||||
String psnAccount = sealSignRecord.getOrgnizeNamePsnAccount();
|
||||
String orgName = sealSignRecord.getOrgnizeName();
|
||||
|
||||
String jsonParm = "{\n" +
|
||||
// " \"needLogin\": true,\n" +
|
||||
" \"operator\": {\n" +
|
||||
|
||||
// " \"psnAccount\":\"17691338406\"\n" +
|
||||
" \"psnAccount\": \"" + psnAccount + "\"\n" +
|
||||
" },\n" +
|
||||
" \"organization\": {\n" +
|
||||
|
||||
// " \"orgName\": \"西安云美电子科技有限公司\"\n" +
|
||||
" \"orgName\": \"" + orgName + "\"\n" +
|
||||
|
||||
" }\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取文件签名印章位置
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
*/
|
||||
public static EsignHttpResponse getPositions(SealSignRecord sealSignRecord) throws EsignDemoException {
|
||||
String fileId = sealSignRecord.getFileid();
|
||||
String apiaddr = "/v3/files/" + fileId + "/keyword-positions";
|
||||
String jsonParm = "{\n" +
|
||||
" \"keywords\": [\n" +
|
||||
" \"仲裁员:\",\n" +
|
||||
" \"(仲裁委员会盖章)\"\n" +
|
||||
" ]\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,161 @@
|
||||
package com.ruoyi.common.utils.bean;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
public class SealSignRecord extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** ID */
|
||||
private Long id;
|
||||
/** 文件id */
|
||||
private String fileid;
|
||||
/** 文件名称 */
|
||||
private String filename;
|
||||
/** 流程id */
|
||||
private String signFlowid;
|
||||
/** 签名人账户 */
|
||||
private String pensonAccount;
|
||||
/** 签名人姓名 */
|
||||
private String pensonName;
|
||||
/** 机构名称 */
|
||||
private String orgnizeName;
|
||||
/** 机构经办人 */
|
||||
private String orgnizeNamePsnAccount;
|
||||
/** 机构经办人名称 */
|
||||
private String orgnizeNamepsnName;
|
||||
|
||||
public String getFileid() {
|
||||
return fileid;
|
||||
}
|
||||
|
||||
public void setFileid(String fileid) {
|
||||
this.fileid = fileid;
|
||||
}
|
||||
|
||||
public String getFilename() {
|
||||
return filename;
|
||||
}
|
||||
|
||||
public void setFilename(String filename) {
|
||||
this.filename = filename;
|
||||
}
|
||||
|
||||
public String getSignFlowid() {
|
||||
return signFlowid;
|
||||
}
|
||||
|
||||
public void setSignFlowid(String signFlowid) {
|
||||
this.signFlowid = signFlowid;
|
||||
}
|
||||
|
||||
public String getPensonAccount() {
|
||||
return pensonAccount;
|
||||
}
|
||||
|
||||
public void setPensonAccount(String pensonAccount) {
|
||||
this.pensonAccount = pensonAccount;
|
||||
}
|
||||
|
||||
public String getPensonName() {
|
||||
return pensonName;
|
||||
}
|
||||
|
||||
public void setPensonName(String pensonName) {
|
||||
this.pensonName = pensonName;
|
||||
}
|
||||
|
||||
public String getOrgnizeName() {
|
||||
return orgnizeName;
|
||||
}
|
||||
|
||||
public void setOrgnizeName(String orgnizeName) {
|
||||
this.orgnizeName = orgnizeName;
|
||||
}
|
||||
|
||||
public String getOrgnizeNamePsnAccount() {
|
||||
return orgnizeNamePsnAccount;
|
||||
}
|
||||
|
||||
public void setOrgnizeNamePsnAccount(String orgnizeNamePsnAccount) {
|
||||
this.orgnizeNamePsnAccount = orgnizeNamePsnAccount;
|
||||
}
|
||||
|
||||
public String getOrgnizeNamepsnName() {
|
||||
return orgnizeNamepsnName;
|
||||
}
|
||||
|
||||
public void setOrgnizeNamepsnName(String orgnizeNamepsnName) {
|
||||
this.orgnizeNamepsnName = orgnizeNamepsnName;
|
||||
}
|
||||
|
||||
public String getPositionPagepsn() {
|
||||
return positionPagepsn;
|
||||
}
|
||||
|
||||
public void setPositionPagepsn(String positionPagepsn) {
|
||||
this.positionPagepsn = positionPagepsn;
|
||||
}
|
||||
|
||||
public double getPositionXpsn() {
|
||||
return positionXpsn;
|
||||
}
|
||||
|
||||
public void setPositionXpsn(double positionXpsn) {
|
||||
this.positionXpsn = positionXpsn;
|
||||
}
|
||||
|
||||
public double getPositionYpsn() {
|
||||
return positionYpsn;
|
||||
}
|
||||
|
||||
public void setPositionYpsn(double positionYpsn) {
|
||||
this.positionYpsn = positionYpsn;
|
||||
}
|
||||
|
||||
public String getPositionPageorg() {
|
||||
return positionPageorg;
|
||||
}
|
||||
|
||||
public void setPositionPageorg(String positionPageorg) {
|
||||
this.positionPageorg = positionPageorg;
|
||||
}
|
||||
|
||||
public double getPositionXorg() {
|
||||
return positionXorg;
|
||||
}
|
||||
|
||||
public void setPositionXorg(double positionXorg) {
|
||||
this.positionXorg = positionXorg;
|
||||
}
|
||||
|
||||
public double getPositionYorg() {
|
||||
return positionYorg;
|
||||
}
|
||||
|
||||
public void setPositionYorg(double positionYorg) {
|
||||
this.positionYorg = positionYorg;
|
||||
}
|
||||
|
||||
/** 签名位置页数 */
|
||||
private String positionPagepsn;
|
||||
/** 签名位置x坐标 */
|
||||
private double positionXpsn;
|
||||
/** 签名位置y坐标 */
|
||||
private double positionYpsn;
|
||||
/** 印章位置页数 */
|
||||
private String positionPageorg;
|
||||
/** 印章位置x坐标 */
|
||||
private double positionXorg;
|
||||
/** 印章位置y坐标 */
|
||||
private double positionYorg;
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -1,83 +0,0 @@
|
||||
package com.ruoyi.common.utils.file;
|
||||
|
||||
import cn.hutool.json.JSONObject;
|
||||
import com.ruoyi.common.config.EsignDemoConfig;
|
||||
import com.ruoyi.common.constant.EsignHeaderConstant;
|
||||
import com.ruoyi.common.core.domain.entity.EsignHttpResponse;
|
||||
import com.ruoyi.common.enums.EsignRequestType;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.common.utils.EsignHttpHelper;
|
||||
import com.ruoyi.common.utils.bean.EsignFileBean;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public class SaaSAPIFileUtils {
|
||||
private static String eSignHost= EsignDemoConfig.EsignHost;
|
||||
private static String eSignAppId= EsignDemoConfig.EsignAppId;
|
||||
private static String eSignAppSecret=EsignDemoConfig.EsignAppSecret;
|
||||
/**
|
||||
* 获取文件上传地址
|
||||
*/
|
||||
public static EsignHttpResponse getUploadUrl(String filePath) throws EsignDemoException {
|
||||
//自定义的文件封装类,传入文件地址可以获取文件的名称大小,文件流等数据
|
||||
EsignFileBean esignFileBean = new EsignFileBean(filePath);
|
||||
String apiaddr = "/v3/files/file-upload-url";
|
||||
//请求参数body体,json格式。get或者delete请求时jsonString传空json:"{}"或者null
|
||||
String jsonParm = "{\n" +
|
||||
" \"contentMd5\": \"" + esignFileBean.getFileContentMD5() + "\",\n" +
|
||||
" \"fileName\":\"" + esignFileBean.getFileName() + "\"," +
|
||||
" \"fileSize\": " + esignFileBean.getFileSize() + ",\n" +
|
||||
" \"convertToPDF\":" +true+ ",\n" +
|
||||
" \"contentType\": \"" + EsignHeaderConstant.CONTENTTYPE_STREAM.VALUE() + "\"\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成签名鉴权方式的的header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
/**
|
||||
* 上传文件流
|
||||
*/
|
||||
public static EsignHttpResponse uploadFile(String uploadUrl,String filePath) throws EsignDemoException {
|
||||
//根据文件地址获取文件contentMd5
|
||||
EsignFileBean esignFileBean = new EsignFileBean(filePath);
|
||||
//请求方法
|
||||
EsignRequestType requestType= EsignRequestType.PUT;
|
||||
return EsignHttpHelper.doUploadHttp(uploadUrl,requestType,esignFileBean.getFileBytes(),esignFileBean.getFileContentMD5(), EsignHeaderConstant.CONTENTTYPE_STREAM.VALUE(),true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取文件上传状态
|
||||
*/
|
||||
public static EsignHttpResponse getFileStatus(String fileId) throws EsignDemoException {
|
||||
String apiaddr="/v3/files/"+fileId;
|
||||
|
||||
//请求参数body体,json格式。get或者delete请求时jsonString传空json:"{}"或者null
|
||||
String jsonParm=null;
|
||||
//请求方法
|
||||
EsignRequestType requestType= EsignRequestType.GET;
|
||||
//生成签名鉴权方式的的header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId,eSignAppSecret,jsonParm,requestType.name(),apiaddr,true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr,requestType , jsonParm, header,true);
|
||||
}
|
||||
|
||||
// public static void main(String[] args) throws EsignDemoException {
|
||||
// String filePath = "D:\\home\\ruoyi\\uploadPath\\upload\\2023\\10\\7\\b442880179844a848f1f8b08c29e3d0c.docx";
|
||||
// EsignHttpResponse uploadUrl = getUploadUrl(filePath);
|
||||
// String body = uploadUrl.getBody();
|
||||
// JSONObject jsonObject = new JSONObject(body);
|
||||
// JSONObject dataObj = jsonObject.getJSONObject("data");
|
||||
// String fileUploadUrl = dataObj.get("fileUploadUrl").toString();
|
||||
// System.out.println("这是fileUploadUrl:"+fileUploadUrl);
|
||||
// String fileId = dataObj.get("fileId").toString();
|
||||
// System.out.println("这是fileId:"+fileId);
|
||||
// EsignHttpResponse esignHttpResponse = uploadFile(fileUploadUrl, filePath);
|
||||
// System.out.println("这是上传文件流的结果:"+esignHttpResponse.getBody());
|
||||
// EsignHttpResponse fileStatus = getFileStatus(fileId);
|
||||
// System.out.println("这是获取文件上传状态的结果:"+fileStatus.getBody());
|
||||
// getFileStatus("a0c2ad21065f48ff8b872412c39d5d3a");
|
||||
// }
|
||||
}
|
||||
@@ -114,16 +114,6 @@ public class CaseApplication extends BaseEntity {
|
||||
private Integer paymentStatus;
|
||||
/** 支付状态描述 */
|
||||
private String paymentStatusName;
|
||||
// 导入校验失败信息
|
||||
private StringBuilder errorMsg;
|
||||
|
||||
public StringBuilder getErrorMsg() {
|
||||
return errorMsg;
|
||||
}
|
||||
|
||||
public void setErrorMsg(StringBuilder errorMsg) {
|
||||
this.errorMsg = errorMsg;
|
||||
}
|
||||
|
||||
public Integer getPaymentStatus() {
|
||||
return paymentStatus;
|
||||
@@ -342,14 +332,10 @@ public class CaseApplication extends BaseEntity {
|
||||
* 申请人主体信息
|
||||
*/
|
||||
/** 姓名 */
|
||||
@Excel(name = "申请人主体信息-申请人(机构)",width = 26)
|
||||
@Excel(name = "申请人主体信息-申请人姓名",width = 26)
|
||||
private String name;
|
||||
/**
|
||||
* 申请人主体信息-申请人(机构)id
|
||||
*/
|
||||
private String nameId;
|
||||
/** 身份证号 */
|
||||
@Excel(name = "申请人主体信息-代码",width = 26)
|
||||
@Excel(name = "申请人主体信息-身份证号",width = 26)
|
||||
private String identityNum;
|
||||
|
||||
/** 联系电话 */
|
||||
@@ -429,14 +415,6 @@ public class CaseApplication extends BaseEntity {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getNameId() {
|
||||
return nameId;
|
||||
}
|
||||
|
||||
public void setNameId(String nameId) {
|
||||
this.nameId = nameId;
|
||||
}
|
||||
|
||||
public String getIdentityNum() {
|
||||
return identityNum;
|
||||
}
|
||||
|
||||
@@ -25,15 +25,6 @@ public class CaseLogRecord extends BaseEntity {
|
||||
|
||||
/** 案件编号 */
|
||||
private String caseNum;
|
||||
/**
|
||||
* 展示的内容
|
||||
*/
|
||||
private String content;
|
||||
/**
|
||||
* 用户昵称
|
||||
*/
|
||||
private String createNickName;
|
||||
|
||||
|
||||
public String getCaseNum() {
|
||||
return caseNum;
|
||||
@@ -59,7 +50,7 @@ public class CaseLogRecord extends BaseEntity {
|
||||
this.caseAppliId = caseAppliId;
|
||||
}
|
||||
|
||||
public Integer getCaseNode() {
|
||||
public int getCaseNode() {
|
||||
return caseNode;
|
||||
}
|
||||
|
||||
@@ -82,24 +73,4 @@ public class CaseLogRecord extends BaseEntity {
|
||||
public void setNotes(String notes) {
|
||||
this.notes = notes;
|
||||
}
|
||||
|
||||
public void setCaseNode(Integer caseNode) {
|
||||
this.caseNode = caseNode;
|
||||
}
|
||||
|
||||
public String getContent() {
|
||||
return content;
|
||||
}
|
||||
|
||||
public void setContent(String content) {
|
||||
this.content = content;
|
||||
}
|
||||
|
||||
public String getCreateNickName() {
|
||||
return createNickName;
|
||||
}
|
||||
|
||||
public void setCreateNickName(String nickName) {
|
||||
this.createNickName = nickName;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,161 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
public class SealSignRecord extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** ID */
|
||||
private Long id;
|
||||
/** 文件id */
|
||||
private String fileid;
|
||||
/** 文件名称 */
|
||||
private String filename;
|
||||
/** 流程id */
|
||||
private String signFlowid;
|
||||
/** 签名人账户 */
|
||||
private String pensonAccount;
|
||||
/** 签名人姓名 */
|
||||
private String pensonName;
|
||||
/** 机构名称 */
|
||||
private String orgnizeName;
|
||||
/** 机构经办人 */
|
||||
private String orgnizeNamePsnAccount;
|
||||
/** 机构经办人名称 */
|
||||
private String orgnizeNamepsnName;
|
||||
|
||||
public String getFileid() {
|
||||
return fileid;
|
||||
}
|
||||
|
||||
public void setFileid(String fileid) {
|
||||
this.fileid = fileid;
|
||||
}
|
||||
|
||||
public String getFilename() {
|
||||
return filename;
|
||||
}
|
||||
|
||||
public void setFilename(String filename) {
|
||||
this.filename = filename;
|
||||
}
|
||||
|
||||
public String getSignFlowid() {
|
||||
return signFlowid;
|
||||
}
|
||||
|
||||
public void setSignFlowid(String signFlowid) {
|
||||
this.signFlowid = signFlowid;
|
||||
}
|
||||
|
||||
public String getPensonAccount() {
|
||||
return pensonAccount;
|
||||
}
|
||||
|
||||
public void setPensonAccount(String pensonAccount) {
|
||||
this.pensonAccount = pensonAccount;
|
||||
}
|
||||
|
||||
public String getPensonName() {
|
||||
return pensonName;
|
||||
}
|
||||
|
||||
public void setPensonName(String pensonName) {
|
||||
this.pensonName = pensonName;
|
||||
}
|
||||
|
||||
public String getOrgnizeName() {
|
||||
return orgnizeName;
|
||||
}
|
||||
|
||||
public void setOrgnizeName(String orgnizeName) {
|
||||
this.orgnizeName = orgnizeName;
|
||||
}
|
||||
|
||||
public String getOrgnizeNamePsnAccount() {
|
||||
return orgnizeNamePsnAccount;
|
||||
}
|
||||
|
||||
public void setOrgnizeNamePsnAccount(String orgnizeNamePsnAccount) {
|
||||
this.orgnizeNamePsnAccount = orgnizeNamePsnAccount;
|
||||
}
|
||||
|
||||
public String getOrgnizeNamepsnName() {
|
||||
return orgnizeNamepsnName;
|
||||
}
|
||||
|
||||
public void setOrgnizeNamepsnName(String orgnizeNamepsnName) {
|
||||
this.orgnizeNamepsnName = orgnizeNamepsnName;
|
||||
}
|
||||
|
||||
public String getPositionPagepsn() {
|
||||
return positionPagepsn;
|
||||
}
|
||||
|
||||
public void setPositionPagepsn(String positionPagepsn) {
|
||||
this.positionPagepsn = positionPagepsn;
|
||||
}
|
||||
|
||||
public double getPositionXpsn() {
|
||||
return positionXpsn;
|
||||
}
|
||||
|
||||
public void setPositionXpsn(double positionXpsn) {
|
||||
this.positionXpsn = positionXpsn;
|
||||
}
|
||||
|
||||
public double getPositionYpsn() {
|
||||
return positionYpsn;
|
||||
}
|
||||
|
||||
public void setPositionYpsn(double positionYpsn) {
|
||||
this.positionYpsn = positionYpsn;
|
||||
}
|
||||
|
||||
public String getPositionPageorg() {
|
||||
return positionPageorg;
|
||||
}
|
||||
|
||||
public void setPositionPageorg(String positionPageorg) {
|
||||
this.positionPageorg = positionPageorg;
|
||||
}
|
||||
|
||||
public double getPositionXorg() {
|
||||
return positionXorg;
|
||||
}
|
||||
|
||||
public void setPositionXorg(double positionXorg) {
|
||||
this.positionXorg = positionXorg;
|
||||
}
|
||||
|
||||
public double getPositionYorg() {
|
||||
return positionYorg;
|
||||
}
|
||||
|
||||
public void setPositionYorg(double positionYorg) {
|
||||
this.positionYorg = positionYorg;
|
||||
}
|
||||
|
||||
/** 签名位置页数 */
|
||||
private String positionPagepsn;
|
||||
/** 签名位置x坐标 */
|
||||
private double positionXpsn;
|
||||
/** 签名位置y坐标 */
|
||||
private double positionYpsn;
|
||||
/** 印章位置页数 */
|
||||
private String positionPageorg;
|
||||
/** 印章位置x坐标 */
|
||||
private double positionXorg;
|
||||
/** 印章位置y坐标 */
|
||||
private double positionYorg;
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseLogRecordMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class ArchivesDetailVO {
|
||||
/**
|
||||
* 案件信息
|
||||
*/
|
||||
private CaseApplication caseApplication;
|
||||
/**
|
||||
* 案件日志信息
|
||||
*/
|
||||
private List<CaseLogRecord> caseLogRecordList;
|
||||
/**
|
||||
* 快递信息
|
||||
*/
|
||||
private List<LogisticsInfoVO> logisticsInfoVOList;
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @description 案件操作日志实体
|
||||
* @Author wangqiong
|
||||
* @Date 2023/10/09 15:18
|
||||
* @Version V1.0
|
||||
**/
|
||||
@Data
|
||||
public class CaseLogVO {
|
||||
/**日志id*/
|
||||
private String logId;
|
||||
/**操作人id*/
|
||||
private String operatorId;
|
||||
/**操作人名称*/
|
||||
private String operatorName;
|
||||
/**操作人ip*/
|
||||
private String ip;
|
||||
/**操作时间*/
|
||||
private Date operateTime;
|
||||
/**操作明细*/
|
||||
private String operateDetail;
|
||||
/**操作类型*/
|
||||
private String operateType;
|
||||
}
|
||||
-24
@@ -1,24 +0,0 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @author wangqiong
|
||||
* @description 发送房间号短信入参类
|
||||
* @date 2023-10-10 15:20
|
||||
*/
|
||||
@Data
|
||||
public class SendRoomNoMessageVO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
@NotNull(message = "案件id不能为空")
|
||||
private Long id;
|
||||
@NotEmpty(message = "房间号不能为空")
|
||||
private String roomNo;
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -1,7 +1,6 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.Arbitrator;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@ package com.ruoyi.wisdomarbitrate.mapper;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -16,7 +15,6 @@ public interface CaseAffiliateMapper {
|
||||
|
||||
|
||||
List<CaseAffiliate> selectCaseAffiliate(CaseAffiliate caseAffiliate);
|
||||
CaseAffiliate selectCaseAffiliateByIdentityType(@Param("caseAppliId") Long caseAppliId, @Param("identityType")int identityType);
|
||||
|
||||
int updataCaseAffiliate(CaseAffiliate caseAffiliate);
|
||||
}
|
||||
|
||||
+1
-7
@@ -2,16 +2,13 @@ package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.LogisticsInfoVO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IAdjudicationService {
|
||||
AjaxResult createDocument(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult sendDocumentByEmail(Long id,String appEmail,String resEmail ,String apptrackingNum,String restrackingNum);
|
||||
|
||||
List<LogisticsInfoVO> getLogisticsInfo(CaseApplication caseApplication);
|
||||
AjaxResult getLogisticsInfo(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult signature(CaseApplication caseApplication);
|
||||
|
||||
@@ -19,7 +16,4 @@ public interface IAdjudicationService {
|
||||
|
||||
AjaxResult service(Long id, String appEmail, String resEmail, String apptrackingNum, String restrackingNum);
|
||||
|
||||
AjaxResult stamp(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult getArchivesDetail(Long id);
|
||||
}
|
||||
|
||||
-3
@@ -1,7 +1,6 @@
|
||||
package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.SendRoomNoMessageVO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -38,6 +37,4 @@ public interface ICaseApplicationService {
|
||||
int submitCaseApplicationCheck(CaseApplication caseApplication);
|
||||
|
||||
CaseApplication selectCaseApplicationConfirm(CaseApplication caseApplication);
|
||||
|
||||
String sendRoomNoMessage(SendRoomNoMessageVO messageVO);
|
||||
}
|
||||
|
||||
+3
-22
@@ -1,34 +1,15 @@
|
||||
package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.domain.IdentityAuthentication;
|
||||
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
|
||||
|
||||
public interface IdentityAuthenticationService {
|
||||
|
||||
|
||||
IdentityAuthentication selectIdentityAuthentication(IdentityAuthentication identityAuthentication);
|
||||
|
||||
/**
|
||||
* 检查是否已经认证的用户
|
||||
*
|
||||
* @param identityAuthentication
|
||||
* @return
|
||||
*/
|
||||
String checkIsAuthentication(IdentityAuthentication identityAuthentication);
|
||||
|
||||
/**
|
||||
* 获取Eidtoken
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
JSONObject selectIdentityAuthenticaEIDtoken();
|
||||
IdentityAuthentication selectIdentityAuthenticaEIDtoken();
|
||||
|
||||
/**
|
||||
* 小程序人脸核身后查询身份认证结果
|
||||
*
|
||||
* @param ientityAuthentication
|
||||
* @return
|
||||
*/
|
||||
AjaxResult selectIdentityAuthenticaRespon(IdentityAuthentication ientityAuthentication);
|
||||
IdentityAuthentication selectIdentityAuthenticaRespon(IdentityAuthentication ientityAuthentication);
|
||||
}
|
||||
|
||||
+8
-56
@@ -2,13 +2,12 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.deepoove.poi.config.Configure;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.EmailOutUtil;
|
||||
import com.ruoyi.common.utils.WordUtil;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ArchivesDetailVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.LogisticsInfoVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.ArbitrateRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseAffiliateMapper;
|
||||
@@ -16,8 +15,8 @@ import com.ruoyi.wisdomarbitrate.mapper.CaseApplicationMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseAttachMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.IAdjudicationService;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseLogRecordService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.poi.xwpf.usermodel.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.mail.MailSendException;
|
||||
import org.springframework.mail.javamail.JavaMailSender;
|
||||
@@ -33,6 +32,7 @@ import java.nio.file.Path;
|
||||
import java.nio.file.StandardCopyOption;
|
||||
import java.time.LocalDate;
|
||||
import java.time.ZoneId;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.*;
|
||||
|
||||
@Service
|
||||
@@ -52,8 +52,6 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
private EmailOutUtil emailOutUtil;
|
||||
@Autowired
|
||||
private ICaseApplicationService caseApplicationService;
|
||||
@Autowired
|
||||
private ICaseLogRecordService caseLogRecordService;
|
||||
|
||||
@Override
|
||||
public AjaxResult createDocument(CaseApplication caseApplication) {
|
||||
@@ -250,7 +248,7 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<LogisticsInfoVO> getLogisticsInfo(CaseApplication caseApplication) {
|
||||
public AjaxResult getLogisticsInfo(CaseApplication caseApplication) {
|
||||
try {
|
||||
//快递单号查询
|
||||
String key = "729437f92468910aee6c12dbfeaee3c1";
|
||||
@@ -295,11 +293,11 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
}
|
||||
} else {
|
||||
// 请求失败
|
||||
return null;
|
||||
return AjaxResult.error("请求失败,错误码:" + responseCode);
|
||||
}
|
||||
}
|
||||
}
|
||||
return logisticsInfoVOList;
|
||||
return AjaxResult.success(logisticsInfoVOList);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
@@ -312,9 +310,6 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
//更改案件状态(暂时)
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.ARBITRATED_SEAL);
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.ARBITRATED_SEAL,"");
|
||||
|
||||
return AjaxResult.success("签名成功,案件状态已改为待仲裁文书用印");
|
||||
}
|
||||
|
||||
@@ -323,9 +318,6 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
//更改案件状态(暂时)
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_ARCHIVED);
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CASE_ARCHIVED,"");
|
||||
|
||||
return AjaxResult.success("归档成功,案件状态已改为已归档");
|
||||
}
|
||||
|
||||
@@ -357,49 +349,10 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
}
|
||||
}
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CASE_FILING,"");
|
||||
|
||||
return AjaxResult.success("仲裁文书送达成功");
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult stamp(CaseApplication caseApplication) {
|
||||
//更改案件状态(暂时)
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.ARBITRATION_DELIVERY);
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.ARBITRATION_DELIVERY,"");
|
||||
|
||||
return AjaxResult.success("用印成功,案件状态已改为待仲裁文书送达");
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult getArchivesDetail(Long id) {
|
||||
ArchivesDetailVO archivesDetailVO = new ArchivesDetailVO();
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(id);
|
||||
//查询案件信息
|
||||
CaseApplication caseApplication1 = caseApplicationService.selectCaseApplication(caseApplication);
|
||||
if (caseApplication1 != null) {
|
||||
archivesDetailVO.setCaseApplication(caseApplication1);
|
||||
}
|
||||
//查询案件日志信息
|
||||
CaseLogRecord caseLogRecord = new CaseLogRecord();
|
||||
caseLogRecord.setCaseAppliId(id);
|
||||
List<CaseLogRecord> caseLogRecords = caseLogRecordService.selectCaseLogRecordList(caseLogRecord);
|
||||
if (caseLogRecords != null && caseLogRecords.size() > 0) {
|
||||
archivesDetailVO.setCaseLogRecordList(caseLogRecords);
|
||||
}
|
||||
//查询快递信息
|
||||
List<LogisticsInfoVO> logisticsInfo = this.getLogisticsInfo(caseApplication);
|
||||
if (logisticsInfo != null && logisticsInfo.size() > 0) {
|
||||
archivesDetailVO.setLogisticsInfoVOList(logisticsInfo);
|
||||
}
|
||||
return AjaxResult.success(archivesDetailVO);
|
||||
}
|
||||
|
||||
/*public static void main(String[] args) {
|
||||
public static void main(String[] args) {
|
||||
try {
|
||||
List<File> fileList = new ArrayList<>();
|
||||
fileList.add(new File("D:\\home\\ruoyi\\uploadPath\\upload\\2023\\10\\7\\b442880179844a848f1f8b08c29e3d0c.docx"));
|
||||
@@ -414,6 +367,5 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
|
||||
} catch (MailSendException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}*/
|
||||
|
||||
}
|
||||
}
|
||||
+20
-444
@@ -1,21 +1,13 @@
|
||||
package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
|
||||
import com.ruoyi.common.annotation.DataScope;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanUtils;
|
||||
import com.ruoyi.system.mapper.SysDeptMapper;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.SendRoomNoMessageVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -24,11 +16,8 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
import java.math.BigDecimal;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
import java.util.regex.Pattern;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||
|
||||
|
||||
@Service
|
||||
public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
@@ -45,10 +34,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
|
||||
@Autowired
|
||||
private CaseAttachMapper caseAttachMapper;
|
||||
@Autowired
|
||||
private SysDeptMapper sysDeptMapper;
|
||||
// 手机号正则
|
||||
private static final Pattern TELEPHONE_REGX = Pattern.compile("^1(3\\d|4[5-9]|5[0-35-9]|6[2567]|7[0-8]|8\\d|9[0-35-9])\\d{8}$");
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -66,7 +52,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
//根据仲裁费用计费规则计算应缴费用
|
||||
//暂时设置计费比率为0.01
|
||||
BigDecimal feeRate = new BigDecimal(0.01);
|
||||
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2,BigDecimal.ROUND_HALF_UP);
|
||||
caseApplication.setFeePayable(feePayable);
|
||||
// 获取自动编码
|
||||
String caseNum = generateCaseNum();
|
||||
@@ -74,52 +60,22 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
|
||||
int rows = caseApplicationMapper.insertCaseApplication(caseApplication);
|
||||
List<CaseAffiliate> caseAffiliates = caseApplication.getCaseAffiliates();
|
||||
Map<String, Long> deptMap =new HashMap<>();
|
||||
if (caseAffiliates != null && caseAffiliates.size() > 0) {
|
||||
// 查询所有的组织机构,组装成map
|
||||
List<SysDept> deptList = sysDeptMapper.selectDeptList(new SysDept());
|
||||
if (CollectionUtil.isEmpty(deptList)) {
|
||||
deptList = new ArrayList<>();
|
||||
}
|
||||
deptMap = deptList.stream().collect(Collectors.toMap(SysDept::getDeptName, SysDept::getDeptId,(oldV,newV)->newV));
|
||||
|
||||
for (CaseAffiliate caseAffiliate : caseAffiliates) {
|
||||
if(caseAffiliates!=null&&caseAffiliates.size()>0){
|
||||
for (CaseAffiliate caseAffiliate : caseAffiliates){
|
||||
caseAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
if(caseAffiliate.getIdentityType()==1&&StrUtil.isNotEmpty(caseAffiliate.getName())) {
|
||||
// 将组织机构id设为申请人名称
|
||||
if (deptMap.containsKey(caseApplication.getName())) {
|
||||
caseAffiliate.setName(String.valueOf(deptMap.get(caseAffiliate.getName())));
|
||||
} else {
|
||||
// 如果不存在则新增
|
||||
SysDept dept = new SysDept();
|
||||
dept.setParentId(0L);
|
||||
dept.setDeptName(caseAffiliate.getName());
|
||||
dept.setAncestors("0");
|
||||
dept.setOrderNum(1);
|
||||
dept.setStatus("0");
|
||||
dept.setDelFlag("0");
|
||||
dept.setCreateBy(getUsername());
|
||||
dept.setUpdateBy(getUsername());
|
||||
sysDeptMapper.insertDept(dept);
|
||||
deptMap.put(dept.getDeptName(), dept.getDeptId());
|
||||
caseAffiliate.setName(String.valueOf(dept.getDeptId()));
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
caseAffiliateMapper.batchCaseAffiliate(caseAffiliates);
|
||||
}
|
||||
|
||||
List<CaseAttach> caseAttachList = caseApplication.getCaseAttachList();
|
||||
if (caseAttachList != null && caseAttachList.size() > 0) {
|
||||
for (CaseAttach caseAttach : caseAttachList) {
|
||||
if(caseAttachList!=null&&caseAttachList.size()>0){
|
||||
for (CaseAttach caseAttach : caseAttachList){
|
||||
caseAttach.setCaseAppliId(caseApplication.getId());
|
||||
caseAttachMapper.updateCaseAttach(caseAttach);
|
||||
}
|
||||
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CASE_APPLICATION,"");
|
||||
|
||||
return rows;
|
||||
}
|
||||
|
||||
@@ -160,38 +116,10 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
int rows = caseApplicationMapper.updataCaseApplication(caseApplication);
|
||||
List<CaseAffiliate> caseAffiliates = caseApplication.getCaseAffiliates();
|
||||
if(caseAffiliates!=null&&caseAffiliates.size()>0){
|
||||
// 查询所有的组织机构,组装成map
|
||||
List<SysDept> deptList = sysDeptMapper.selectDeptList(new SysDept());
|
||||
if (CollectionUtil.isEmpty(deptList)) {
|
||||
deptList = new ArrayList<>();
|
||||
}
|
||||
Map<String, Long> deptMap = deptList.stream().collect(Collectors.toMap(SysDept::getDeptName, SysDept::getDeptId,(oldV,newV)->newV));
|
||||
for (CaseAffiliate caseAffiliate : caseAffiliates){
|
||||
caseAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
if(caseAffiliate.getIdentityType()==1&&StrUtil.isNotEmpty(caseAffiliate.getName())) {
|
||||
// 将组织机构id设为申请人名称
|
||||
if (deptMap.containsKey(caseApplication.getName())) {
|
||||
caseAffiliate.setName(String.valueOf(deptMap.get(caseAffiliate.getName())));
|
||||
} else {
|
||||
// 如果不存在则新增
|
||||
SysDept dept = new SysDept();
|
||||
dept.setParentId(0L);
|
||||
dept.setDeptName(caseAffiliate.getName());
|
||||
dept.setAncestors("0");
|
||||
dept.setOrderNum(1);
|
||||
dept.setStatus("0");
|
||||
dept.setDelFlag("0");
|
||||
dept.setCreateBy(getUsername());
|
||||
dept.setUpdateBy(getUsername());
|
||||
sysDeptMapper.insertDept(dept);
|
||||
deptMap.put(dept.getDeptName(), dept.getDeptId());
|
||||
caseAffiliate.setName(String.valueOf(dept.getDeptId()));
|
||||
|
||||
}
|
||||
}
|
||||
caseAffiliateMapper.updataCaseAffiliate(caseAffiliate);
|
||||
}
|
||||
|
||||
}
|
||||
List<CaseAttach> caseAttachList = caseApplication.getCaseAttachList();
|
||||
if(caseAttachList!=null&&caseAttachList.size()>0){
|
||||
@@ -211,8 +139,6 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
//提交立案申请
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_CHECK);
|
||||
int rows = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CASE_CHECK,"");
|
||||
return rows;
|
||||
}
|
||||
|
||||
@@ -260,23 +186,12 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
|
||||
List<CaseAffiliate> caseAffiliatListeselect = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
if(caseAffiliatListeselect!=null){
|
||||
// 查询组织机构
|
||||
List<SysDept> sysDepts = sysDeptMapper.selectDeptList(new SysDept());
|
||||
Map<String,String> deptMap=new HashMap<>();
|
||||
if(CollectionUtil.isNotEmpty(sysDepts)){
|
||||
for (SysDept sysDept : sysDepts) {
|
||||
deptMap.put(String.valueOf(sysDept.getDeptId()),sysDept.getDeptName());
|
||||
}
|
||||
}
|
||||
StringBuffer applicantName = new StringBuffer();
|
||||
StringBuffer respondentName = new StringBuffer();
|
||||
for (int i = 0; i < caseAffiliatListeselect.size(); i++){
|
||||
CaseAffiliate caseAffiliateselect = caseAffiliatListeselect.get(i);
|
||||
int identityType = caseAffiliateselect.getIdentityType();
|
||||
if(identityType==1){
|
||||
if(StrUtil.isNotEmpty(caseAffiliateselect.getName())&&deptMap.containsKey(caseAffiliateselect.getName())){
|
||||
caseAffiliateselect.setName(deptMap.get(caseAffiliateselect.getName()));
|
||||
}
|
||||
applicantName.append(caseAffiliateselect.getName()).append(",");;
|
||||
}else if(identityType==2){
|
||||
respondentName.append(caseAffiliateselect.getName()).append(",");;
|
||||
@@ -298,30 +213,18 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
int successNum = 0;
|
||||
int failureNum = 0;
|
||||
if(caseApplicationList!=null&&caseApplicationList.size()>0){
|
||||
// 1,查询所有的组织机构,组装成map
|
||||
List<SysDept> deptList = sysDeptMapper.selectDeptList(new SysDept());
|
||||
Map<String, Long> deptMap =new HashMap<>();
|
||||
if(CollectionUtil.isNotEmpty(deptList)) {
|
||||
deptMap = deptList.stream().collect(Collectors.toMap(SysDept::getDeptName, SysDept::getDeptId,(oldV,newV)->newV));
|
||||
}
|
||||
List<CaseApplication> caseApplicationListinsert = new ArrayList<>();
|
||||
for (int i = 0; i < caseApplicationList.size(); i++){
|
||||
CaseApplication caseApplication = caseApplicationList.get(i);
|
||||
|
||||
// 导入校验
|
||||
importValid(caseApplication);
|
||||
// 校验成功的数据
|
||||
if(StrUtil.isEmpty(caseApplication.getErrorMsg())) {
|
||||
//根据仲裁费用计费规则计算应缴费用
|
||||
//暂时设置计费比率为0.01
|
||||
BigDecimal feeRate = new BigDecimal(0.01);
|
||||
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2,BigDecimal.ROUND_HALF_UP);
|
||||
caseApplication.setFeePayable(feePayable);
|
||||
|
||||
//赋值CaseApplication的案件关联人信息
|
||||
List<CaseAffiliate> caseAffiliatesnew = new ArrayList<>();
|
||||
// 组装案件关联人信息
|
||||
assignmentCaseAffiliates(caseApplication, caseAffiliatesnew, deptMap);
|
||||
assignmentCaseAffiliates(caseApplication,caseAffiliatesnew);
|
||||
|
||||
// int caseApplicationCount = selectCaseApplicationCount(caseApplication);
|
||||
// if(caseApplicationCount>0){
|
||||
@@ -331,11 +234,8 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
// caseApplicationListinsert.add(caseApplication);
|
||||
// }
|
||||
caseApplicationListinsert.add(caseApplication);
|
||||
}else {
|
||||
// 拼接错误信息
|
||||
failureMsg.append("<br/>").append("第").append(i+2).append("行:").append(caseApplication.getErrorMsg().toString());
|
||||
}
|
||||
}
|
||||
|
||||
if(caseApplicationListinsert!=null&&caseApplicationListinsert.size()>0){
|
||||
// List<CaseApplication> caseApplicationListinsertDiffer = caseApplicationListinsert.stream().collect(
|
||||
// collectingAndThen(
|
||||
@@ -394,234 +294,14 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
}else {
|
||||
throw new ServiceException("导入立案申请数据不能为空!");
|
||||
}
|
||||
return successMsg.append(failureMsg.toString()).toString();
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 导入校验
|
||||
* @param caseApplication
|
||||
* @param
|
||||
*/
|
||||
private void importValid(CaseApplication caseApplication) {
|
||||
StringBuilder failureMsg=new StringBuilder();
|
||||
caseApplication.setErrorMsg(failureMsg);
|
||||
// 校验基本字段
|
||||
validBaseColumn(caseApplication,failureMsg);
|
||||
// 校验申请人信息
|
||||
validApplicationColumn(caseApplication,failureMsg);
|
||||
// 校验申请人代理信息
|
||||
validApplicationAgentColumn(caseApplication,failureMsg);
|
||||
// 校验被申请人信息
|
||||
validDebtorApplicationColumn(caseApplication,failureMsg);
|
||||
// 校验被申请人代理信息
|
||||
validDebtorApplicationAgentColumn(caseApplication,failureMsg);
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验被申请人代理信息
|
||||
* @param caseApplication
|
||||
* @param failureMsg
|
||||
*/
|
||||
private void validDebtorApplicationAgentColumn(CaseApplication caseApplication, StringBuilder failureMsg) {
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorNameAgent())){
|
||||
failureMsg.append("【被申请人主体信息-代理人姓名】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorNameAgent().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-代理人姓名】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorIdentityNumAgent())){
|
||||
failureMsg.append("【被申请人主体信息-代理人身份证号】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorIdentityNumAgent().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-代理人身份证号】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
String debtorContactTelphoneAgent = caseApplication.getDebtorContactTelphoneAgent();
|
||||
if( StrUtil.isEmpty(debtorContactTelphoneAgent)){
|
||||
failureMsg.append("【被申请人主体信息-代理人联系电话】字段不能为空;");
|
||||
}else if(!TELEPHONE_REGX.matcher(debtorContactTelphoneAgent).matches()){
|
||||
failureMsg.append("【被申请人主体信息-代理人联系电话】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorContactAddressAgent())){
|
||||
failureMsg.append("【被申请人主体信息-代理人联系地址】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorContactAddressAgent().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-代理人联系地址】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验被申请人信息
|
||||
* @param caseApplication
|
||||
* @param failureMsg
|
||||
*/
|
||||
private void validDebtorApplicationColumn(CaseApplication caseApplication, StringBuilder failureMsg) {
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorName())){
|
||||
failureMsg.append("【被申请人主体信息-申请人姓名】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorName().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-申请人姓名】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorIdentityNum())){
|
||||
failureMsg.append("【被申请人主体信息-身份证号】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorIdentityNum().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-身份证号】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
String debtorContactTelphone = caseApplication.getDebtorContactTelphone();
|
||||
if( StrUtil.isEmpty(debtorContactTelphone)){
|
||||
failureMsg.append("【被申请人主体信息-联系电话】字段不能为空;");
|
||||
}else if(!TELEPHONE_REGX.matcher(debtorContactTelphone).matches()){
|
||||
failureMsg.append("【被申请人主体信息-联系电话】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorContactAddress())){
|
||||
failureMsg.append("【被申请人主体信息-联系地址】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorContactAddress().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-联系地址】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
String debtorWorkTelphone = caseApplication.getDebtorWorkTelphone();
|
||||
if( StrUtil.isEmpty(debtorWorkTelphone)){
|
||||
failureMsg.append("【被申请人主体信息-单位电话】字段不能为空;");
|
||||
}else if(!TELEPHONE_REGX.matcher(debtorWorkTelphone).matches()){
|
||||
failureMsg.append("【被申请人主体信息-单位电话】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getDebtorWorkAddress())){
|
||||
failureMsg.append("【被申请人主体信息-单位地址】字段不能为空;");
|
||||
}else if(caseApplication.getDebtorWorkAddress().length()>50){
|
||||
failureMsg.append("【被申请人主体信息-单位地址】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验申请人代理信息
|
||||
* @param caseApplication
|
||||
* @param failureMsg
|
||||
*/
|
||||
private void validApplicationAgentColumn(CaseApplication caseApplication, StringBuilder failureMsg) {
|
||||
if( StrUtil.isEmpty(caseApplication.getNameAgent())){
|
||||
failureMsg.append("【申请人主体信息-代理人姓名】字段不能为空;");
|
||||
}else if(caseApplication.getNameAgent().length()>50){
|
||||
failureMsg.append("【申请人主体信息-代理人姓名】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getIdentityNumAgent())){
|
||||
failureMsg.append("【申请人主体信息-代理人身份证号】字段不能为空;");
|
||||
}else if(caseApplication.getIdentityNumAgent().length()>50){
|
||||
failureMsg.append("【申请人主体信息-代理人身份证号】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
String contactTelphoneAgent = caseApplication.getContactTelphoneAgent();
|
||||
if( StrUtil.isEmpty(contactTelphoneAgent)){
|
||||
failureMsg.append("【申请人主体信息-代理人联系电话】字段不能为空;");
|
||||
}else if(!TELEPHONE_REGX.matcher(contactTelphoneAgent).matches()){
|
||||
failureMsg.append("【申请人主体信息-代理人联系电话】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getContactAddressAgent())){
|
||||
failureMsg.append("【申请人主体信息-代理人联系地址】字段不能为空;");
|
||||
}else if(caseApplication.getContactAddressAgent().length()>50){
|
||||
failureMsg.append("【申请人主体信息-代理人联系地址】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验申请人主题信息
|
||||
* @param caseApplication
|
||||
* @param failureMsg
|
||||
*/
|
||||
private void validApplicationColumn(CaseApplication caseApplication, StringBuilder failureMsg) {
|
||||
if( StrUtil.isEmpty(caseApplication.getName())){
|
||||
failureMsg.append("【申请人主体信息-申请人(机构)】字段不能为空;");
|
||||
}else if(caseApplication.getName().length()>20){
|
||||
failureMsg.append("【申请人主体信息-申请人(机构)】字段超出指定长度,最大长度为20;");
|
||||
}
|
||||
if( StrUtil.isNotEmpty(caseApplication.getIdentityNum())&&caseApplication.getIdentityNum().length()>50){
|
||||
failureMsg.append("【申请人主体信息-代码】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
String contactTelphone = caseApplication.getContactTelphone();
|
||||
if( StrUtil.isEmpty(contactTelphone)){
|
||||
failureMsg.append("【申请人主体信息-联系电话】字段不能为空;");
|
||||
}else if(!TELEPHONE_REGX.matcher(contactTelphone).matches()){
|
||||
failureMsg.append("【申请人主体信息-联系电话】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getContactAddress())){
|
||||
failureMsg.append("【申请人主体信息-联系地址】字段不能为空;");
|
||||
}else if(caseApplication.getName().length()>50){
|
||||
failureMsg.append("【申请人主体信息-联系地址】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
String workTelphone = caseApplication.getWorkTelphone();
|
||||
if( StrUtil.isEmpty(workTelphone)){
|
||||
failureMsg.append("【申请人主体信息-单位电话】字段不能为空;");
|
||||
}else if(!TELEPHONE_REGX.matcher(workTelphone).matches()){
|
||||
failureMsg.append("【申请人主体信息-单位电话】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getWorkAddress())){
|
||||
failureMsg.append("【申请人主体信息-单位地址】字段不能为空;");
|
||||
}else if(caseApplication.getWorkAddress().length()>50){
|
||||
failureMsg.append("【申请人主体信息-单位地址】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验基本字段
|
||||
* @param caseApplication
|
||||
* @param failureMsg
|
||||
*/
|
||||
private void validBaseColumn(CaseApplication caseApplication, StringBuilder failureMsg) {
|
||||
BigDecimal caseSubjectAmount = caseApplication.getCaseSubjectAmount();
|
||||
if(null== caseSubjectAmount){
|
||||
failureMsg.append("【案件标的】字段不合法;");
|
||||
// 编号存在不导入
|
||||
if(StringUtils.isNotEmpty(failureMsg)){
|
||||
return failureMsg.append(successMsg).toString();
|
||||
}else {
|
||||
if(caseSubjectAmount.compareTo(new BigDecimal("0")) < 0 ||caseSubjectAmount.compareTo(new BigDecimal("99999999.99"))>0){
|
||||
failureMsg.append("【案件标的】字段超出范围,范围为[0,100000000);");
|
||||
}
|
||||
if(caseSubjectAmount.scale()>2){
|
||||
failureMsg.append("【案件标的】字段超出指定精度(10^-2);");
|
||||
}
|
||||
}
|
||||
if( caseApplication.getLoanStartDate()== null){
|
||||
failureMsg.append("【借款开始日期】字段不合法;");
|
||||
}
|
||||
if( caseApplication.getLoanEndDate()== null){
|
||||
failureMsg.append("【借款结束日期】字段不合法;");
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getContractNumber())){
|
||||
failureMsg.append("【合同编号】字段不能为空;");
|
||||
}else if(caseApplication.getContractNumber().length()>50){
|
||||
failureMsg.append("【合同编号】字段超出指定长度,最大长度为50;");
|
||||
}
|
||||
BigDecimal claimPrinciOwed = caseApplication.getClaimPrinciOwed();
|
||||
if(null== claimPrinciOwed){
|
||||
failureMsg.append("【申请人主张欠本金】字段不合法;");
|
||||
}else {
|
||||
if(claimPrinciOwed.compareTo(new BigDecimal("0")) < 0 ||claimPrinciOwed.compareTo(new BigDecimal("99999999.99"))>0){
|
||||
failureMsg.append("【申请人主张欠本金】字段超出范围,范围为[0,100000000);");
|
||||
}
|
||||
if(claimPrinciOwed.scale()>2){
|
||||
failureMsg.append("【申请人主张欠本金】字段超出指定精度(10^-2);");
|
||||
}
|
||||
}
|
||||
BigDecimal claimInterestOwed = caseApplication.getClaimInterestOwed();
|
||||
if(null== claimInterestOwed){
|
||||
failureMsg.append("【申请人主张欠利息】字段不合法;");
|
||||
}else {
|
||||
if(claimInterestOwed.compareTo(new BigDecimal("0")) < 0 ||claimInterestOwed.compareTo(new BigDecimal("99999999.99"))>0){
|
||||
failureMsg.append("【申请人主张欠利息】字段超出范围,范围为[0,100000000);");
|
||||
}
|
||||
if(claimInterestOwed.scale()>2){
|
||||
failureMsg.append("【申请人主张欠利息】字段超出指定精度(10^-2);");
|
||||
}
|
||||
}
|
||||
BigDecimal claimLiquidDamag = caseApplication.getClaimLiquidDamag();
|
||||
if(null== claimLiquidDamag){
|
||||
failureMsg.append("【申请人主张违约金】字段不合法;");
|
||||
}else {
|
||||
if(claimLiquidDamag.compareTo(new BigDecimal("0")) < 0 ||claimLiquidDamag.compareTo(new BigDecimal("99999999.99"))>0){
|
||||
failureMsg.append("【申请人主张违约金】字段超出范围,范围为[0,100000000);");
|
||||
}
|
||||
if(claimLiquidDamag.scale()>2){
|
||||
failureMsg.append("【申请人主张违约金】字段超出指定精度(10^-2);");
|
||||
}
|
||||
}
|
||||
if( StrUtil.isEmpty(caseApplication.getArbitratClaims())){
|
||||
failureMsg.append("【申请人仲裁诉求】字段不能为空;");
|
||||
}else if(caseApplication.getArbitratClaims().length()>10000){
|
||||
failureMsg.append("【申请人仲裁诉求】字段超出指定长度,最大长度为10000;");
|
||||
}
|
||||
}
|
||||
|
||||
return successMsg.toString();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
@@ -664,8 +344,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
rows = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
}
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CONFIRMDED_PENDING_TRIAL,"");
|
||||
|
||||
return rows;
|
||||
}
|
||||
|
||||
@@ -676,8 +355,6 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
int rows = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
ArbitrateRecord arbitrateRecord = caseApplication.getArbitrateRecord();
|
||||
arbitrateRecordMapper.updataArbitrateRecord(arbitrateRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CHECK_ARBITRATION,"");
|
||||
return rows;
|
||||
|
||||
}
|
||||
@@ -691,15 +368,9 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
Integer agreeOrNotCheck = caseApplication.getAgreeOrNotCheck();
|
||||
if(agreeOrNotCheck.intValue()==1){//同意审核
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.SIGN_ARBITRATION);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.SIGN_ARBITRATION,"");
|
||||
|
||||
rows = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
}else if(agreeOrNotCheck.intValue()==2){//拒绝审核
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.VERPRIF_ARBITRATION);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.VERPRIF_ARBITRATION,"");
|
||||
|
||||
rows = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
}
|
||||
|
||||
@@ -719,38 +390,21 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_APPLICATION);
|
||||
rows = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_PAYMENT,"");
|
||||
|
||||
return rows;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CaseApplication selectCaseApplicationConfirm(CaseApplication caseApplication) {
|
||||
CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplicationConfirm(caseApplication);
|
||||
if(caseApplicationselect==null){
|
||||
return caseApplicationselect;
|
||||
}
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
List<CaseAffiliate> caseAffiliatListeselect = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
if(caseAffiliatListeselect!=null){
|
||||
// 查询组织机构
|
||||
List<SysDept> sysDepts = sysDeptMapper.selectDeptList(new SysDept());
|
||||
Map<String,String> deptMap=new HashMap<>();
|
||||
if(CollectionUtil.isNotEmpty(sysDepts)){
|
||||
for (SysDept sysDept : sysDepts) {
|
||||
deptMap.put(String.valueOf(sysDept.getDeptId()),sysDept.getDeptName());
|
||||
}
|
||||
}
|
||||
StringBuffer applicantName = new StringBuffer();
|
||||
for (int i = 0; i < caseAffiliatListeselect.size(); i++){
|
||||
CaseAffiliate caseAffiliateselect = caseAffiliatListeselect.get(i);
|
||||
int identityType = caseAffiliateselect.getIdentityType();
|
||||
if(identityType==1){
|
||||
if(StrUtil.isNotEmpty(caseAffiliateselect.getName())&&deptMap.containsKey(caseAffiliateselect.getName())){
|
||||
caseAffiliateselect.setName(deptMap.get(caseAffiliateselect.getName()));
|
||||
}
|
||||
applicantName.append(caseAffiliateselect.getName()).append(",");;
|
||||
}
|
||||
}
|
||||
@@ -761,32 +415,6 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
return caseApplicationselect;
|
||||
}
|
||||
|
||||
/**
|
||||
* 给被申请人发送房间号短信
|
||||
* @param messageVO
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public String sendRoomNoMessage(SendRoomNoMessageVO messageVO) {
|
||||
CaseAffiliate caseAffiliate = caseAffiliateMapper.selectCaseAffiliateByIdentityType(messageVO.getId(), 2);
|
||||
if(null==caseAffiliate){
|
||||
return "被申请人不存在";
|
||||
}
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(messageVO.getId());
|
||||
CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
|
||||
//发送短信通知
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
request.setTemplateId("1948332");
|
||||
// 1948332 普通短信 开庭审理房间号通知 尊敬的{1}用户,您的{2}仲裁案件,开庭审理房间号为{3},请知晓,如非本人操作,请忽略本短信。
|
||||
request.setPhone(caseAffiliate.getContactTelphone());
|
||||
request.setTemplateParamSet(new String[]{caseAffiliate.getName(), caseApplicationselect.getCaseNum(), messageVO.getRoomNo()});
|
||||
SmsUtils.sendSms(request);
|
||||
|
||||
return "短信发送成功";
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public int pendTralSure(CaseApplication caseApplication) {
|
||||
@@ -831,23 +459,9 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
caseAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
List<CaseAffiliate> caseAffiliatListeselect = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
if(caseAffiliatListeselect!=null) {
|
||||
// 查询组织机构
|
||||
List<SysDept> sysDepts = sysDeptMapper.selectDeptList(new SysDept());
|
||||
Map<String,String> deptMap=new HashMap<>();
|
||||
if(CollectionUtil.isNotEmpty(sysDepts)){
|
||||
for (SysDept sysDept : sysDepts) {
|
||||
deptMap.put(String.valueOf(sysDept.getDeptId()),sysDept.getDeptName());
|
||||
}
|
||||
}
|
||||
for (int j = 0; j < caseAffiliatListeselect.size(); j++) {
|
||||
CaseAffiliate caseAffiliateselect = caseAffiliatListeselect.get(j);
|
||||
int identityType = caseAffiliateselect.getIdentityType();
|
||||
if(identityType==1){
|
||||
if(StrUtil.isNotEmpty(caseAffiliateselect.getName())&&deptMap.containsKey(caseAffiliateselect.getName())){
|
||||
caseAffiliateselect.setName(deptMap.get(caseAffiliateselect.getName()));
|
||||
}
|
||||
caseAffiliateselect.setName(caseAffiliateselect.getName());;
|
||||
}
|
||||
//给申请人、被申请人发送短信通知
|
||||
request.setPhone(caseAffiliateselect.getContactTelphone());
|
||||
// 1947342 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。
|
||||
@@ -856,8 +470,6 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
SmsUtils.sendSms(request);
|
||||
}
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CHECK_ARBITRATION_METHOD,"");
|
||||
|
||||
return rows;
|
||||
|
||||
@@ -897,17 +509,12 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
|
||||
|
||||
|
||||
private void assignmentCaseAffiliates(CaseApplication caseApplication, List<CaseAffiliate> caseAffiliatesnew, Map<String, Long> deptMap) {
|
||||
// 申请人信息
|
||||
private void assignmentCaseAffiliates(CaseApplication caseApplication, List<CaseAffiliate> caseAffiliatesnew) {
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
|
||||
// BeanUtils.copyBeanProp(caseApplication,caseAffiliate);
|
||||
BeanUtils.copyBeanProp(caseAffiliate,caseApplication);
|
||||
caseAffiliate.setIdentityType(1);
|
||||
// 申请人(机构),需要判断部门中是否存在,不存在则新增,当身份类型为1的时候,查询时需要根据名称查询组织机构
|
||||
if(StrUtil.isNotEmpty(caseApplication.getName())){
|
||||
setApplicantOrganization(caseAffiliate, caseApplication, deptMap);
|
||||
}
|
||||
caseAffiliatesnew.add(caseAffiliate);
|
||||
|
||||
// 组装被申请人信息
|
||||
@@ -915,38 +522,6 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
caseApplication.setCaseAffiliates(caseAffiliatesnew);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置申请人的组织机构
|
||||
* @param caseAffiliate
|
||||
* @param caseApplication
|
||||
*/
|
||||
@DataScope(deptAlias = "d")
|
||||
private void setApplicantOrganization(CaseAffiliate caseAffiliate, CaseApplication caseApplication, Map<String, Long> deptMap ) {
|
||||
|
||||
|
||||
|
||||
// 将组织机构id设为申请人名称
|
||||
if(deptMap.containsKey(caseApplication.getName())){
|
||||
caseAffiliate.setName(String.valueOf(deptMap.get(caseApplication.getName())));
|
||||
}else {
|
||||
// 如果不存在则新增
|
||||
SysDept dept = new SysDept();
|
||||
dept.setParentId(0L);
|
||||
dept.setDeptName(caseApplication.getName());
|
||||
dept.setAncestors("0");
|
||||
dept.setOrderNum(1);
|
||||
dept.setStatus("0");
|
||||
dept.setDelFlag("0");
|
||||
dept.setCreateBy(getUsername());
|
||||
dept.setUpdateBy(getUsername());
|
||||
sysDeptMapper.insertDept(dept);
|
||||
deptMap.put(dept.getDeptName(),dept.getDeptId());
|
||||
caseAffiliate.setName(String.valueOf(dept.getDeptId()));
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 组装被申请人信息
|
||||
* @param caseApplication
|
||||
@@ -984,4 +559,5 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
|
||||
caseApplicationNew.setFeePayable(caseApplicationinsertDiffer.getFeePayable());
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
-22
@@ -2,7 +2,6 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.ArbitrateRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
@@ -45,30 +44,18 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
caseApplication1.setArbitratMethod(1); // 更改仲裁方式
|
||||
//修改案件状态为待开庭审理
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_OPENCOURT_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_OPENCOURT_HEAR,"");
|
||||
|
||||
}else {
|
||||
caseApplication1.setArbitratMethod(2);
|
||||
//修改案件状态为待书面审理
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_WRIITEN_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_WRIITEN_HEAR,"");
|
||||
|
||||
}
|
||||
}else {
|
||||
if (arbitratMethod == 2){
|
||||
//修改案件状态为待书面审理
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_WRIITEN_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_WRIITEN_HEAR,"");
|
||||
|
||||
}else {
|
||||
//修改案件状态为待开庭审理
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_OPENCOURT_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_OPENCOURT_HEAR,"");
|
||||
|
||||
}
|
||||
}
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
@@ -100,9 +87,6 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
}
|
||||
}
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_OPENCOURT_HEAR,"");
|
||||
|
||||
return AjaxResult.success("审核成功");
|
||||
}
|
||||
return AjaxResult.error();
|
||||
@@ -134,9 +118,6 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
//修改案件状态
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.GENERATED_ARBITRATION);
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.GENERATED_ARBITRATION,"");
|
||||
|
||||
return AjaxResult.success("提交成功");
|
||||
}
|
||||
}else {
|
||||
@@ -155,9 +136,6 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
//修改案件状态
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.GENERATED_ARBITRATION);
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.GENERATED_ARBITRATION,"");
|
||||
|
||||
return AjaxResult.success("提交成功");
|
||||
}
|
||||
}
|
||||
|
||||
+10
-22
@@ -3,10 +3,6 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
import com.ruoyi.common.config.RuoYiConfig;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseEvidenceDTO;
|
||||
@@ -121,21 +117,10 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
|
||||
return AjaxResult.error("上传失败");
|
||||
}
|
||||
@Autowired
|
||||
IdentityAuthenticationMapper identityAuthenticationMapper;
|
||||
|
||||
|
||||
@Override
|
||||
public List<CaseEvidenceVO> getCaseListAll(String identityNum) {
|
||||
if(StringUtils.isBlank(identityNum)){
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
String username = loginUser.getUsername();
|
||||
IdentityAuthentication authentication=new IdentityAuthentication();
|
||||
authentication.setUserName(username);
|
||||
IdentityAuthentication authentication1 = identityAuthenticationMapper.selectIdentityAuthentication(authentication);
|
||||
if(authentication1!=null){
|
||||
identityNum = authentication1.getIdentityNo();
|
||||
}
|
||||
}
|
||||
List<Integer> caseStatusList = Arrays.asList(CaseApplicationConstants.CASE_CROSSEXAMI);
|
||||
return getCaseEvidenceVOList(identityNum, caseStatusList, null);
|
||||
}
|
||||
@@ -145,9 +130,6 @@ IdentityAuthenticationMapper identityAuthenticationMapper;
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.PENDING_TRIAL);
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
if (i > 0) {
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.PENDING_TRIAL,"");
|
||||
|
||||
return AjaxResult.success("证据确认成功");
|
||||
}
|
||||
return AjaxResult.error("暂无需要确认的证据");
|
||||
@@ -183,9 +165,15 @@ IdentityAuthenticationMapper identityAuthenticationMapper;
|
||||
}
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
if (i > 0) {
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CONFIRMDED_PENDING_TRIAL_SUBMMIT,"");
|
||||
|
||||
//案件日志表里添加数据
|
||||
CaseLogRecord caseLogRecord = new CaseLogRecord();
|
||||
caseLogRecord.setCaseAppliId(caseApplication1.getId());
|
||||
caseLogRecord.setCaseNode(caseStatus);
|
||||
String createBy = caseApplication1.getCreateBy();
|
||||
if (createBy != null) {
|
||||
caseLogRecord.setCreateBy(createBy);
|
||||
}
|
||||
caseLogRecordMapper.insertCaseLogRecord(caseLogRecord);
|
||||
return AjaxResult.success("提交成功");
|
||||
}
|
||||
}
|
||||
|
||||
+1
-80
@@ -1,9 +1,5 @@
|
||||
package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.date.DatePattern;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseLogRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseLogRecordService;
|
||||
@@ -20,82 +16,7 @@ public class CaseLogRecordServiceImpl implements ICaseLogRecordService {
|
||||
|
||||
@Override
|
||||
public List<CaseLogRecord> selectCaseLogRecordList(CaseLogRecord caseLogRecord) {
|
||||
List<CaseLogRecord> records = caseLogRecordMapper.selectCaseLogRecordList(caseLogRecord);
|
||||
if(CollectionUtil.isNotEmpty(records)){
|
||||
records.forEach(record->{
|
||||
StringBuilder contentBuilder = new StringBuilder();
|
||||
String caseNodeTime="";
|
||||
if(record.getCaseNodeTime()!=null){
|
||||
caseNodeTime= DateUtil.format(record.getCaseNodeTime(), DatePattern.NORM_DATETIME_FORMATTER);
|
||||
}
|
||||
|
||||
contentBuilder.append(record.getCreateNickName()).append("(").append(record.getCreateBy()).append(")").append("于").append(caseNodeTime);
|
||||
switch(record.getCaseNode()){
|
||||
case 0:
|
||||
contentBuilder.append("创建立案申请");
|
||||
break;
|
||||
case 1:
|
||||
contentBuilder.append("提交立案申请");
|
||||
break;
|
||||
case 2:
|
||||
contentBuilder.append("立案审查");
|
||||
break;
|
||||
case 3:
|
||||
contentBuilder.append("支付成功");
|
||||
break;
|
||||
case 4:
|
||||
contentBuilder.append("缴费确认");
|
||||
break;
|
||||
case 5:
|
||||
contentBuilder.append("案件质证");
|
||||
break;
|
||||
case 6:
|
||||
contentBuilder.append("组庭审核");
|
||||
break;
|
||||
case 7:
|
||||
contentBuilder.append("组庭确认");
|
||||
break;
|
||||
case 8:
|
||||
contentBuilder.append("待开庭审理");
|
||||
break;
|
||||
case 9:
|
||||
contentBuilder.append("待书面审理");
|
||||
break;
|
||||
case 10:
|
||||
contentBuilder.append("书面审理");
|
||||
break;
|
||||
case 11:
|
||||
contentBuilder.append("审核裁决书,拒绝");
|
||||
break;
|
||||
case 12:
|
||||
contentBuilder.append("核验裁决书");
|
||||
break;
|
||||
case 13:
|
||||
contentBuilder.append("审核裁决书,同意");
|
||||
break;
|
||||
case 14:
|
||||
contentBuilder.append("签名成功");
|
||||
break;
|
||||
case 15:
|
||||
contentBuilder.append("用印成功");
|
||||
break;
|
||||
case 16:
|
||||
contentBuilder.append("送达仲裁文书");
|
||||
break;
|
||||
case 17:
|
||||
contentBuilder.append("案件归档");
|
||||
break;
|
||||
case 26:
|
||||
contentBuilder.append("证据确认成功");
|
||||
break;
|
||||
default:break;
|
||||
}
|
||||
|
||||
record.setContent(contentBuilder.toString());
|
||||
|
||||
});
|
||||
}
|
||||
return records;
|
||||
return caseLogRecordMapper.selectCaseLogRecordList(caseLogRecord);
|
||||
}
|
||||
|
||||
|
||||
|
||||
+1
-4
@@ -4,7 +4,6 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
import com.ruoyi.ElegentPay;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.dto.PayRequest;
|
||||
import com.ruoyi.dto.PayResponse;
|
||||
@@ -20,6 +19,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@@ -127,9 +127,6 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
SmsUtils.sendSms(request);
|
||||
}
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants.CASE_CROSSEXAMI,"");
|
||||
|
||||
return AjaxResult.success();
|
||||
}
|
||||
}
|
||||
|
||||
+82
-148
@@ -1,27 +1,27 @@
|
||||
package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
|
||||
import cn.hutool.core.codec.Base64;
|
||||
|
||||
import cn.hutool.crypto.SmUtil;
|
||||
import cn.hutool.crypto.asymmetric.SM2;
|
||||
import cn.hutool.crypto.symmetric.SymmetricCrypto;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.exceptions.TradeException;
|
||||
import com.ruoyi.wisdomarbitrate.domain.IdentityAuthentication;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.IdentityAuthenticationMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import com.ruoyi.wisdomarbitrate.service.IdentityAuthenticationService;
|
||||
|
||||
import com.tencentcloudapi.common.Credential;
|
||||
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
|
||||
import com.tencentcloudapi.common.profile.ClientProfile;
|
||||
import com.tencentcloudapi.common.profile.HttpProfile;
|
||||
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
|
||||
import com.tencentcloudapi.faceid.v20180301.FaceidClient;
|
||||
import com.tencentcloudapi.faceid.v20180301.models.GetEidResultRequest;
|
||||
import com.tencentcloudapi.faceid.v20180301.models.GetEidResultResponse;
|
||||
import com.tencentcloudapi.faceid.v20180301.models.GetEidTokenRequest;
|
||||
import com.tencentcloudapi.faceid.v20180301.models.GetEidTokenResponse;
|
||||
import com.tencentcloudapi.faceid.v20180301.models.*;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -29,7 +29,12 @@ import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.Date;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.util.Base64;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
@Service
|
||||
public class IdentityAuthenticationServiceImpl implements IdentityAuthenticationService {
|
||||
@@ -53,9 +58,9 @@ public class IdentityAuthenticationServiceImpl implements IdentityAuthentication
|
||||
@Override
|
||||
public IdentityAuthentication selectIdentityAuthentication(IdentityAuthentication identityAuthentication) {
|
||||
IdentityAuthentication identityAuthenticationselect = identityAuthenticationMapper.selectIdentityAuthentication(identityAuthentication);
|
||||
if (identityAuthenticationselect != null) {
|
||||
if(identityAuthenticationselect!=null){
|
||||
identityAuthenticationselect.setCertificationStatusName("已身份认证");
|
||||
} else {
|
||||
}else {
|
||||
IdentityAuthentication identityAuthenticationselectnew = new IdentityAuthentication();
|
||||
identityAuthenticationselectnew.setCertificationStatusName("未身份认证");
|
||||
identityAuthenticationselectnew.setCertificationStatus(0);
|
||||
@@ -65,157 +70,86 @@ public class IdentityAuthenticationServiceImpl implements IdentityAuthentication
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查是否已经认证的用户
|
||||
*
|
||||
* @param identityAuthentication
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public String checkIsAuthentication(IdentityAuthentication identityAuthentication) {
|
||||
IdentityAuthentication identityAuthenticationselect = identityAuthenticationMapper.selectIdentityAuthentication(identityAuthentication);
|
||||
if (identityAuthenticationselect != null) {
|
||||
return "1";
|
||||
} else {
|
||||
return "0";
|
||||
}
|
||||
public IdentityAuthentication selectIdentityAuthenticaEIDtoken() {
|
||||
IdentityAuthentication identityAuthentication = new IdentityAuthentication();
|
||||
try{
|
||||
Credential authenti = new Credential(credentialSecretId, credentialSecretKey);
|
||||
HttpProfile httpProfileIdenAuth = new HttpProfile();
|
||||
httpProfileIdenAuth.setEndpoint("faceid.tencentcloudapi.com");
|
||||
ClientProfile clientInv= new ClientProfile();
|
||||
clientInv.setHttpProfile(httpProfileIdenAuth);
|
||||
FaceidClient clientIdenAuth = new FaceidClient(authenti, "", clientInv);
|
||||
// 实例化一个请求对象
|
||||
GetEidTokenRequest reqest = new GetEidTokenRequest();
|
||||
//设置请求参数
|
||||
reqest.setMerchantId(merchantId);
|
||||
GetEidTokenResponse respIdenAuth = clientIdenAuth.GetEidToken(reqest);
|
||||
String respJSON = GetEidTokenResponse.toJsonString(respIdenAuth);
|
||||
JSONObject objJSON = JSON.parseObject(respJSON);
|
||||
String eidToken = objJSON.getString("EidToken");
|
||||
String requestId = objJSON.getString("RequestId");
|
||||
identityAuthentication.setEidToken(eidToken);
|
||||
}catch (TencentCloudSDKException e) {
|
||||
log.error("获取Eidtoke异常:", e);
|
||||
throw new RuntimeException("获取Eidtoke异常");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取EIDtoken
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public JSONObject selectIdentityAuthenticaEIDtoken() {
|
||||
JSONObject objJSON = new JSONObject();
|
||||
objJSON.put("EidToken", "");
|
||||
try {
|
||||
Credential cred = new Credential(credentialSecretId, credentialSecretKey);
|
||||
// 实例化一个http选项,可选的,没有特殊需求可以跳过
|
||||
HttpProfile httpProfile = new HttpProfile();
|
||||
httpProfile.setEndpoint("faceid.tencentcloudapi.com");
|
||||
// 实例化一个client选项,可选的,没有特殊需求可以跳过
|
||||
ClientProfile clientProfile = new ClientProfile();
|
||||
clientProfile.setHttpProfile(httpProfile);
|
||||
// 实例化要请求产品的client对象,clientProfile是可选的
|
||||
FaceidClient client = new FaceidClient(cred, "", clientProfile);
|
||||
// 实例化一个请求对象,每个接口都会对应一个request对象
|
||||
GetEidTokenRequest req = new GetEidTokenRequest();
|
||||
req.setMerchantId(merchantId);
|
||||
// 返回的resp是一个GetEidTokenResponse的实例,与请求对象对应
|
||||
GetEidTokenResponse resp = client.GetEidToken(req);
|
||||
// 输出json格式的字符串回包
|
||||
String respJSON = GetEidTokenResponse.toJsonString(resp);
|
||||
objJSON = JSON.parseObject(respJSON);
|
||||
} catch (TencentCloudSDKException e) {
|
||||
System.out.println(e.toString());
|
||||
System.out.println("获取Eidtoken失败");
|
||||
}
|
||||
return objJSON;
|
||||
return identityAuthentication;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 解密用户信息
|
||||
*/
|
||||
public JSONObject DecodeUserInfo(String deskey, String userInfo) {
|
||||
JSONObject parse = null;
|
||||
try {
|
||||
byte[] desKeyBytes = Base64.decode(deskey);
|
||||
final SM2 sm2 = new SM2(privateKeyHexDecodeinfo, null, null);
|
||||
sm2.usePlainEncoding();
|
||||
byte[] sm4KeyBytes = sm2.decrypt(desKeyBytes);
|
||||
SymmetricCrypto sm4 = SmUtil.sm4(sm4KeyBytes);
|
||||
byte[] plaintext = sm4.decrypt(Base64.decode(userInfo));
|
||||
if (plaintext != null && plaintext.length > 0) {
|
||||
String s = new String(plaintext);
|
||||
parse = JSON.parseObject(s);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
System.out.println(e.toString());
|
||||
}
|
||||
return parse;
|
||||
}
|
||||
|
||||
/**
|
||||
* 小程序人脸核身后查询身份认证结果
|
||||
*
|
||||
* @param ientityAuthentication
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public AjaxResult selectIdentityAuthenticaRespon(IdentityAuthentication ientityAuthentication) {
|
||||
public IdentityAuthentication selectIdentityAuthenticaRespon(IdentityAuthentication ientityAuthentication) {
|
||||
String eidToken = ientityAuthentication.getEidToken();
|
||||
Long userId = ientityAuthentication.getUserId();
|
||||
String userName = ientityAuthentication.getUserName();
|
||||
IdentityAuthentication IdentityAuthenticationRespon = new IdentityAuthentication();
|
||||
IdentityAuthentication IdentityAuthenticationResult = new IdentityAuthentication();
|
||||
if(StringUtils.isNotEmpty(eidToken)){
|
||||
try{
|
||||
Credential authenti = new Credential(credentialSecretId, credentialSecretKey);
|
||||
HttpProfile httpProfileIdenAuth = new HttpProfile();
|
||||
httpProfileIdenAuth.setEndpoint("faceid.tencentcloudapi.com");
|
||||
ClientProfile clientInv= new ClientProfile();
|
||||
clientInv.setHttpProfile(httpProfileIdenAuth);
|
||||
FaceidClient clientIdenAuth = new FaceidClient(authenti, "", clientInv);
|
||||
// 实例化一个请求对象
|
||||
GetEidResultRequest reqest = new GetEidResultRequest();
|
||||
//设置请求参数
|
||||
reqest.setEidToken(eidToken);
|
||||
|
||||
try {
|
||||
Credential cred = new Credential(credentialSecretId, credentialSecretKey);
|
||||
// 实例化一个http选项,可选的,没有特殊需求可以跳过
|
||||
HttpProfile httpProfile = new HttpProfile();
|
||||
httpProfile.setEndpoint("faceid.tencentcloudapi.com");
|
||||
// 实例化一个client选项,可选的,没有特殊需求可以跳过
|
||||
ClientProfile clientProfile = new ClientProfile();
|
||||
clientProfile.setHttpProfile(httpProfile);
|
||||
// 实例化要请求产品的client对象,clientProfile是可选的
|
||||
FaceidClient client = new FaceidClient(cred, "", clientProfile);
|
||||
// 实例化一个请求对象,每个接口都会对应一个request对象
|
||||
GetEidResultRequest req = new GetEidResultRequest();
|
||||
req.setEidToken(eidToken);
|
||||
// 返回的resp是一个GetEidResultResponse的实例,与请求对象对应
|
||||
GetEidResultResponse resp = client.GetEidResult(req);
|
||||
// 输出json格式的字符串回包
|
||||
String s = GetEidResultResponse.toJsonString(resp);
|
||||
JSONObject objJSON = JSON.parseObject(s);
|
||||
//查看是否核验成功
|
||||
JSONObject text = objJSON.getJSONObject("Text");
|
||||
if (text != null) {
|
||||
Integer comparestatus = text.getInteger("Comparestatus");
|
||||
if (comparestatus != null && comparestatus == 0) {
|
||||
JSONObject eidInfo = objJSON.getJSONObject("EidInfo");
|
||||
if (eidInfo != null) {
|
||||
String desKey = eidInfo.getString("DesKey");
|
||||
String userInfo = eidInfo.getString("UserInfo");
|
||||
//1.解密用户的信息
|
||||
JSONObject info = DecodeUserInfo(desKey, userInfo);
|
||||
if (info != null) {
|
||||
String idcardno = info.getString("idnum");
|
||||
String name = info.getString("name");
|
||||
//2.在用户认证表中插入用户认证记录
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
IdentityAuthentication authentication = new IdentityAuthentication();
|
||||
/**
|
||||
* 用户名
|
||||
* 用户名id
|
||||
* 姓名
|
||||
* 身份证号
|
||||
* 认证时间
|
||||
* 认证状态0表示成功
|
||||
* 请求id
|
||||
*/
|
||||
authentication.setUserName(loginUser.getUsername());
|
||||
authentication.setUserId(loginUser.getUserId());
|
||||
authentication.setName(name);
|
||||
authentication.setIdentityNo(idcardno);
|
||||
authentication.setCertificationTime(new Date());
|
||||
authentication.setCertificationStatus(0);
|
||||
authentication.setCreateBy(loginUser.getUsername());
|
||||
try {
|
||||
identityAuthenticationMapper.insertIdentityAuthentication(authentication);
|
||||
} catch (Exception e) {
|
||||
System.out.println("认证记录新增失败");
|
||||
}
|
||||
// reqest.setInfoType("1");
|
||||
// reqest.setInfoType("13");
|
||||
// reqest.setInfoType("2");
|
||||
|
||||
}
|
||||
//获得身份认证结果
|
||||
GetEidResultResponse respIdenAuth = clientIdenAuth.GetEidResult(reqest);
|
||||
String respJSON = GetEidResultResponse.toJsonString(respIdenAuth);
|
||||
JSONObject objJSON = JSON.parseObject(respJSON);
|
||||
IdentityAuthenticationRespon.setCertificationStatus(1);
|
||||
IdentityAuthenticationRespon.setUserName(userName);
|
||||
IdentityAuthenticationRespon.setUserId(userId);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
return AjaxResult.success();
|
||||
JSONObject objEidInfo = JSON.parseObject(objJSON.getString("EidInfo"));
|
||||
// identityAuthenticationMapper.insertIdentityAuthentication(IdentityAuthenticationRespon);
|
||||
IdentityAuthenticationResult.setCertificationStatus(1);
|
||||
IdentityAuthenticationResult.setCertificationStatusName("认证成功");
|
||||
} catch (TencentCloudSDKException e) {
|
||||
System.out.println(e.toString());
|
||||
log.error("认证失败:", e);
|
||||
throw new RuntimeException("认证失败");
|
||||
}
|
||||
return null;
|
||||
|
||||
}
|
||||
return IdentityAuthenticationResult;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,42 +0,0 @@
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import cn.hutool.extra.spring.SpringUtil;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseLogRecordMapper;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* 案件记录日志文件
|
||||
*
|
||||
* @author wangqiong
|
||||
*/
|
||||
public class CaseLogUtils
|
||||
{
|
||||
private static CaseLogRecordMapper caseLogRecordMapper= SpringUtil.getBean(CaseLogRecordMapper.class);
|
||||
|
||||
/**
|
||||
* 新增案件日志
|
||||
* @param caseAppliId 案件id,不能为空
|
||||
* @param caseNode 案件节点,不能为空
|
||||
* @param notes 备注
|
||||
*/
|
||||
public static void insertCaseLog(@NotNull Long caseAppliId, @NotEmpty Integer caseNode, String notes ){
|
||||
// 获取当前的用户
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
String nickName = loginUser.getUser().getNickName();
|
||||
CaseLogRecord operLog = new CaseLogRecord();
|
||||
operLog.setCreateBy(loginUser.getUsername());
|
||||
operLog.setCreateNickName(nickName);
|
||||
operLog.setUpdateBy(loginUser.getUsername());
|
||||
operLog.setCaseAppliId(caseAppliId);
|
||||
operLog.setCaseNode(caseNode);
|
||||
operLog.setNotes(notes);
|
||||
caseLogRecordMapper.insertCaseLogRecord(operLog);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
public class EsignApplicaConfig {
|
||||
|
||||
// 应用ID
|
||||
public static final String EsignAppId = "7438987614";
|
||||
// 应用密钥
|
||||
public static final String EsignAppSecret = "9d7844f13830931037772b9d20cf1529";
|
||||
// e签宝接口调用域名(模拟环境)
|
||||
public static final String EsignHost = "https://smlopenapi.esign.cn";
|
||||
// e签宝接口调用域名(正式环境)
|
||||
// public static final String EsignHost = "https://openapi.esign.cn";
|
||||
}
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package com.ruoyi.common.core.domain.entity;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
/**
|
||||
* esignSDK-core信息类
|
||||
* @author 澄泓
|
||||
+21
-24
@@ -9,8 +9,8 @@
|
||||
* an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations under the License.
|
||||
*/
|
||||
package com.ruoyi.common.constant;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import org.apache.commons.codec.binary.Base64;
|
||||
import org.apache.http.message.BasicNameValuePair;
|
||||
|
||||
@@ -26,9 +26,6 @@ import java.util.*;
|
||||
|
||||
/**
|
||||
* @description 请求数据通用处理类
|
||||
* @author 澄泓
|
||||
* @date 2020年10月22日 下午14:25:31
|
||||
* @since JDK1.7
|
||||
*/
|
||||
public class EsignEncryption {
|
||||
|
||||
@@ -43,7 +40,7 @@ public class EsignEncryption {
|
||||
* @param url
|
||||
* @return
|
||||
*/
|
||||
public static String appendSignDataString(String httpMethod, String contentMd5,String accept,String contentType,String headers,String date, String url) throws EsignDemoException {
|
||||
public static String appendSignDataString(String httpMethod, String contentMd5,String accept,String contentType,String headers,String date, String url) throws EsignInterfacException {
|
||||
StringBuffer sb = new StringBuffer();
|
||||
sb.append(httpMethod).append("\n").append(accept).append("\n").append(contentMd5).append("\n")
|
||||
.append(contentType).append("\n");
|
||||
@@ -65,9 +62,9 @@ public class EsignEncryption {
|
||||
* Content-MD5的计算方法
|
||||
* @param str 待计算的消息
|
||||
* @return MD5计算后摘要值的Base64编码(ContentMD5)
|
||||
* @throws EsignDemoException 加密过程中的异常信息
|
||||
* @throws EsignInterfacException 加密过程中的异常信息
|
||||
*/
|
||||
public static String doContentMD5(String str) throws EsignDemoException {
|
||||
public static String doContentMD5(String str) throws EsignInterfacException {
|
||||
byte[] md5Bytes = null;
|
||||
MessageDigest md5 = null;
|
||||
String contentMD5 = null;
|
||||
@@ -81,7 +78,7 @@ public class EsignEncryption {
|
||||
contentMD5 = Base64.encodeBase64String(md5Bytes);
|
||||
|
||||
} catch (NoSuchAlgorithmException e) {
|
||||
EsignDemoException ex = new EsignDemoException("不支持此算法",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("不支持此算法",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
@@ -95,9 +92,9 @@ public class EsignEncryption {
|
||||
* @param message 待签名字符串
|
||||
* @param secret 密钥APP KEY
|
||||
* @return reqSignature HmacSHA256计算后摘要值的Base64编码
|
||||
* @throws EsignDemoException 加密过程中的异常信息
|
||||
* @throws EsignInterfacException 加密过程中的异常信息
|
||||
*/
|
||||
public static String doSignatureBase64(String message, String secret) throws EsignDemoException {
|
||||
public static String doSignatureBase64(String message, String secret) throws EsignInterfacException {
|
||||
String algorithm = "HmacSHA256";
|
||||
Mac hmacSha256;
|
||||
String digestBase64 = null;
|
||||
@@ -111,11 +108,11 @@ public class EsignEncryption {
|
||||
// 把摘要后的结果digestBytes使用Base64进行编码
|
||||
digestBase64 = Base64.encodeBase64String(digestBytes);
|
||||
} catch (NoSuchAlgorithmException e) {
|
||||
EsignDemoException ex = new EsignDemoException("不支持此算法",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("不支持此算法",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (InvalidKeyException e) {
|
||||
EsignDemoException ex = new EsignDemoException("无效的密钥规范",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("无效的密钥规范",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
@@ -154,7 +151,7 @@ public class EsignEncryption {
|
||||
* hash散列加密算法
|
||||
* @return
|
||||
*/
|
||||
public static String Hmac_SHA256(String message,String key) throws EsignDemoException {
|
||||
public static String Hmac_SHA256(String message,String key) throws EsignInterfacException {
|
||||
byte[] rawHmac=null;
|
||||
try {
|
||||
SecretKeySpec sk = new SecretKeySpec(key.getBytes(), "HmacSHA256");
|
||||
@@ -162,15 +159,15 @@ public class EsignEncryption {
|
||||
mac.init(sk);
|
||||
rawHmac = mac.doFinal(message.getBytes());
|
||||
}catch (InvalidKeyException e){
|
||||
EsignDemoException ex = new EsignDemoException("无效的密钥规范",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("无效的密钥规范",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (NoSuchAlgorithmException e) {
|
||||
EsignDemoException ex = new EsignDemoException("不支持此算法",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("不支持此算法",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}catch (Exception e){
|
||||
EsignDemoException ex = new EsignDemoException("hash散列加密算法报错",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("hash散列加密算法报错",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}finally {
|
||||
@@ -182,14 +179,14 @@ public class EsignEncryption {
|
||||
/**
|
||||
* MD5加密32位
|
||||
*/
|
||||
public static String MD5Digest(String text) throws EsignDemoException {
|
||||
public static String MD5Digest(String text) throws EsignInterfacException {
|
||||
byte[] digest=null;
|
||||
try {
|
||||
MessageDigest md5 = MessageDigest.getInstance("MD5");
|
||||
md5.update(text.getBytes());
|
||||
digest = md5.digest();
|
||||
}catch (NoSuchAlgorithmException e){
|
||||
EsignDemoException ex = new EsignDemoException("不支持此算法",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("不支持此算法",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}finally {
|
||||
@@ -236,7 +233,7 @@ public class EsignEncryption {
|
||||
* @return 排序后的API接口地址
|
||||
* @throws Exception
|
||||
*/
|
||||
public static String sortApiUrl(String apiUrl) throws EsignDemoException {
|
||||
public static String sortApiUrl(String apiUrl) throws EsignInterfacException {
|
||||
|
||||
if (!apiUrl.contains("?")) {
|
||||
return apiUrl;
|
||||
@@ -258,7 +255,7 @@ public class EsignEncryption {
|
||||
String value = str.substring(index + 1);
|
||||
if (queryParamsMap.containsKey(key)) {
|
||||
String msg = MessageFormat.format("请求URL中的Query参数的{0}重复", key);
|
||||
throw new EsignDemoException(msg);
|
||||
throw new EsignInterfacException(msg);
|
||||
}
|
||||
queryParamsMap.put(key, value);
|
||||
}
|
||||
@@ -300,9 +297,9 @@ public class EsignEncryption {
|
||||
*获取query
|
||||
* @param apiUrl
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static ArrayList<BasicNameValuePair> getQuery(String apiUrl) throws EsignDemoException {
|
||||
public static ArrayList<BasicNameValuePair> getQuery(String apiUrl) throws EsignInterfacException {
|
||||
ArrayList<BasicNameValuePair> BasicNameValuePairList = new ArrayList<>();
|
||||
|
||||
if (!apiUrl.contains("?")) {
|
||||
@@ -321,7 +318,7 @@ public class EsignEncryption {
|
||||
String value = str.substring(index + 1);
|
||||
if (queryParamsMap.containsKey(key)) {
|
||||
String msg = MessageFormat.format("请求URL中的Query参数的{0}重复", key);
|
||||
throw new EsignDemoException(msg);
|
||||
throw new EsignInterfacException(msg);
|
||||
}
|
||||
BasicNameValuePairList.add(new BasicNameValuePair(key,value));
|
||||
queryParamsMap.put(key, value);
|
||||
+5
-9
@@ -1,8 +1,4 @@
|
||||
package com.ruoyi.common.utils.bean;
|
||||
|
||||
|
||||
import com.ruoyi.common.constant.FileTransformation;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
@@ -23,12 +19,12 @@ public class EsignFileBean {
|
||||
private String filePath;
|
||||
|
||||
|
||||
public EsignFileBean(String filePath) throws EsignDemoException {
|
||||
public EsignFileBean(String filePath) throws EsignInterfacException {
|
||||
this.filePath=filePath;
|
||||
this.fileContentMD5 = FileTransformation.getFileContentMD5(filePath);
|
||||
File file = new File(filePath);
|
||||
if (!file.exists()) {
|
||||
throw new EsignDemoException("文件不存在");
|
||||
throw new EsignInterfacException("文件不存在");
|
||||
}
|
||||
this.fileName = file.getName();
|
||||
this.fileSize = (int) file.length();
|
||||
@@ -49,9 +45,9 @@ public class EsignFileBean {
|
||||
/**
|
||||
* 传入本地文件地址获取二进制数据
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public byte[] getFileBytes() throws EsignDemoException {
|
||||
public byte[] getFileBytes() throws EsignInterfacException {
|
||||
return FileTransformation.fileToBytes(filePath);
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package com.ruoyi.common.constant;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
/**
|
||||
* @description 头部信息常量
|
||||
* @author 澄泓
|
||||
+17
-24
@@ -9,10 +9,8 @@
|
||||
* an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations under the License.
|
||||
*/
|
||||
package com.ruoyi.common.constant;
|
||||
import com.ruoyi.common.core.domain.entity.EsignHttpResponse;
|
||||
import com.ruoyi.common.enums.EsignRequestType;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import org.apache.http.*;
|
||||
import org.apache.http.auth.AuthScope;
|
||||
import org.apache.http.auth.UsernamePasswordCredentials;
|
||||
@@ -24,7 +22,6 @@ import org.apache.http.client.entity.UrlEncodedFormEntity;
|
||||
import org.apache.http.client.methods.CloseableHttpResponse;
|
||||
import org.apache.http.client.methods.HttpRequestBase;
|
||||
import org.apache.http.client.protocol.HttpClientContext;
|
||||
import org.apache.http.client.utils.URIBuilder;
|
||||
import org.apache.http.config.Registry;
|
||||
import org.apache.http.config.RegistryBuilder;
|
||||
import org.apache.http.conn.ConnectTimeoutException;
|
||||
@@ -40,7 +37,6 @@ import org.apache.http.impl.client.BasicCredentialsProvider;
|
||||
import org.apache.http.impl.client.CloseableHttpClient;
|
||||
import org.apache.http.impl.client.HttpClientBuilder;
|
||||
import org.apache.http.impl.conn.PoolingHttpClientConnectionManager;
|
||||
import org.apache.http.message.BasicNameValuePair;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
import org.apache.http.util.EntityUtils;
|
||||
import org.slf4j.Logger;
|
||||
@@ -53,15 +49,12 @@ import java.net.UnknownHostException;
|
||||
import java.security.cert.CertificateException;
|
||||
import java.security.cert.X509Certificate;
|
||||
import java.text.MessageFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @description Http请求 辅助类
|
||||
* @author 澄泓
|
||||
* @since JDK1.7
|
||||
*/
|
||||
public class EsignHttpCfgHelper {
|
||||
|
||||
@@ -233,16 +226,16 @@ public class EsignHttpCfgHelper {
|
||||
* @param param
|
||||
* {@link Object} 参数
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
* @author 澄泓
|
||||
*/
|
||||
public static EsignHttpResponse sendHttp(EsignRequestType reqType, String httpUrl, Map<String, String> headers, Object param, boolean debug)
|
||||
throws EsignDemoException {
|
||||
throws EsignInterfacException {
|
||||
HttpRequestBase reqBase=null;
|
||||
if(httpUrl.startsWith("http")){
|
||||
reqBase=reqType.getHttpType(httpUrl);
|
||||
}else{
|
||||
throw new EsignDemoException("请求url地址格式错误");
|
||||
throw new EsignInterfacException("请求url地址格式错误");
|
||||
}
|
||||
if(debug){
|
||||
LOGGER.info("请求头:{}",headers+"\n");
|
||||
@@ -295,29 +288,29 @@ public class EsignHttpCfgHelper {
|
||||
LOGGER.info("----------------------------end------------------------");
|
||||
}
|
||||
} catch (NoHttpResponseException e) {
|
||||
throw new EsignDemoException("服务器丢失了",e);
|
||||
throw new EsignInterfacException("服务器丢失了",e);
|
||||
} catch (SSLHandshakeException e){
|
||||
String msg = MessageFormat.format("SSL握手异常", e);
|
||||
EsignDemoException ex = new EsignDemoException(msg, e);
|
||||
EsignInterfacException ex = new EsignInterfacException(msg, e);
|
||||
throw ex;
|
||||
} catch (UnknownHostException e){
|
||||
EsignDemoException ex = new EsignDemoException("服务器找不到", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("服务器找不到", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch(ConnectTimeoutException e){
|
||||
EsignDemoException ex = new EsignDemoException("连接超时", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("连接超时", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch(SSLException e){
|
||||
EsignDemoException ex = new EsignDemoException("SSL异常",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("SSL异常",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (ClientProtocolException e) {
|
||||
EsignDemoException ex = new EsignDemoException("请求头异常",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("请求头异常",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("网络请求失败",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("网络请求失败",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} finally {
|
||||
@@ -325,7 +318,7 @@ public class EsignHttpCfgHelper {
|
||||
try {
|
||||
res.close();
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("--->>关闭请求响应失败",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("--->>关闭请求响应失败",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -365,7 +358,7 @@ public class EsignHttpCfgHelper {
|
||||
* @return
|
||||
* @author 澄泓
|
||||
*/
|
||||
private static void cfgPoolMgr() throws EsignDemoException {
|
||||
private static void cfgPoolMgr() throws EsignInterfacException {
|
||||
ConnectionSocketFactory plainsf = PlainConnectionSocketFactory.getSocketFactory();
|
||||
LayeredConnectionSocketFactory sslsf = SSLConnectionSocketFactory.getSocketFactory();
|
||||
if(!SSL_VERIFY){
|
||||
@@ -438,7 +431,7 @@ public class EsignHttpCfgHelper {
|
||||
/**
|
||||
* 忽略域名校验
|
||||
*/
|
||||
private static SSLConnectionSocketFactory sslConnectionSocketFactory() throws EsignDemoException {
|
||||
private static SSLConnectionSocketFactory sslConnectionSocketFactory() throws EsignInterfacException {
|
||||
try {
|
||||
SSLContext ctx = SSLContext.getInstance("TLS"); // 创建一个上下文(此处指定的协议类型似乎不是重点)
|
||||
X509TrustManager tm = new X509TrustManager() { // 创建一个跳过SSL证书的策略
|
||||
@@ -455,7 +448,7 @@ public class EsignHttpCfgHelper {
|
||||
ctx.init(null, new TrustManager[] { tm }, null); // 使用上面的策略初始化上下文
|
||||
return new SSLConnectionSocketFactory(ctx, new String[] { "SSLv3", "TLSv1", "TLSv1.1", "TLSv1.2" }, null, NoopHostnameVerifier.INSTANCE);
|
||||
}catch (Exception e){
|
||||
EsignDemoException ex = new EsignDemoException("忽略域名校验失败",e);
|
||||
EsignInterfacException ex = new EsignInterfacException("忽略域名校验失败",e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -468,7 +461,7 @@ public class EsignHttpCfgHelper {
|
||||
* @return
|
||||
* @author 澄泓
|
||||
*/
|
||||
private static synchronized CloseableHttpClient getHttpClient() throws EsignDemoException {
|
||||
private static synchronized CloseableHttpClient getHttpClient() throws EsignInterfacException {
|
||||
if(httpClient==null) {
|
||||
CredentialsProvider credsProvider = new BasicCredentialsProvider();
|
||||
credsProvider.setCredentials(new AuthScope(PROXY_IP,PROXY_PORT),new UsernamePasswordCredentials(PROXY_USERNAME, PROXY_PASSWORD));
|
||||
+9
-19
@@ -1,13 +1,5 @@
|
||||
package com.ruoyi.common.utils;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
|
||||
import com.ruoyi.common.constant.EsignEncryption;
|
||||
import com.ruoyi.common.constant.EsignHeaderConstant;
|
||||
import com.ruoyi.common.constant.EsignHttpCfgHelper;
|
||||
import com.ruoyi.common.core.domain.entity.EsignCoreSdkInfo;
|
||||
import com.ruoyi.common.core.domain.entity.EsignHttpResponse;
|
||||
import com.ruoyi.common.enums.EsignRequestType;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
@@ -36,13 +28,11 @@ public class EsignHttpHelper {
|
||||
* @param url 请求路径
|
||||
* @param paramStr 请求参数
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
* @author 澄泓
|
||||
*/
|
||||
public static EsignHttpResponse doCommHttp(String host, String url, EsignRequestType reqType, Object paramStr , Map<String,String> httpHeader, boolean debug) throws EsignDemoException {
|
||||
|
||||
public static EsignHttpResponse doCommHttp(String host, String url,EsignRequestType reqType, Object paramStr ,Map<String,String> httpHeader,boolean debug) throws EsignInterfacException {
|
||||
return EsignHttpCfgHelper.sendHttp(reqType, host+url,httpHeader, paramStr, debug);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -55,11 +45,11 @@ public class EsignHttpHelper {
|
||||
* @param fileContentMd5 文件fileContentMd5
|
||||
* @param contentType 文件MIME类型
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
* @author 澄泓
|
||||
*/
|
||||
public static EsignHttpResponse doUploadHttp( String uploadUrl,EsignRequestType reqType,byte[] param, String fileContentMd5,
|
||||
String contentType, boolean debug) throws EsignDemoException {
|
||||
String contentType, boolean debug) throws EsignInterfacException {
|
||||
Map<String, String> uploadHeader = buildUploadHeader(fileContentMd5, contentType);
|
||||
if(debug){
|
||||
LOGGER.info("----------------------------start------------------------");
|
||||
@@ -96,7 +86,7 @@ public class EsignHttpHelper {
|
||||
* * charset}
|
||||
* @return
|
||||
*/
|
||||
public static Map<String,String> signAndBuildSignAndJsonHeader(String projectId, String secret,String paramStr,String httpMethod,String url,boolean debug) throws EsignDemoException {
|
||||
public static Map<String,String> signAndBuildSignAndJsonHeader(String projectId, String secret,String paramStr,String httpMethod,String url,boolean debug) throws EsignInterfacException {
|
||||
String contentMD5="";
|
||||
//统一转大写处理
|
||||
httpMethod = httpMethod.toUpperCase();
|
||||
@@ -105,9 +95,9 @@ public class EsignHttpHelper {
|
||||
contentMD5="";
|
||||
} else if("PUT".equals(httpMethod)||"POST".equals(httpMethod)){
|
||||
//对body体做md5摘要
|
||||
contentMD5= EsignEncryption.doContentMD5(paramStr);
|
||||
contentMD5=EsignEncryption.doContentMD5(paramStr);
|
||||
}else{
|
||||
throw new EsignDemoException(String.format("不支持的请求方法%s",httpMethod));
|
||||
throw new EsignInterfacException(String.format("不支持的请求方法%s",httpMethod));
|
||||
}
|
||||
//构造一个初步的请求头
|
||||
Map<String, String> esignHeaderMap = buildSignAndJsonHeader(projectId, contentMD5, EsignHeaderConstant.ACCEPT.VALUE(), EsignHeaderConstant.CONTENTTYPE_JSON.VALUE(), EsignHeaderConstant.AUTHMODE.VALUE());
|
||||
@@ -137,7 +127,7 @@ public class EsignHttpHelper {
|
||||
*/
|
||||
public static Map<String, String> buildTokenAndJsonHeader(String appid,String token) {
|
||||
Map<String, String> esignHeader = new HashMap<>();
|
||||
esignHeader.put("X-Tsign-Open-Version-Sdk", EsignCoreSdkInfo.getSdkVersion());
|
||||
esignHeader.put("X-Tsign-Open-Version-Sdk",EsignCoreSdkInfo.getSdkVersion());
|
||||
esignHeader.put("Content-Type", EsignHeaderConstant.CONTENTTYPE_JSON.VALUE());
|
||||
esignHeader.put("X-Tsign-Open-App-Id", appid);
|
||||
esignHeader.put("X-Tsign-Open-Token", token);
|
||||
+4
-1
@@ -1,6 +1,9 @@
|
||||
package com.ruoyi.common.core.domain.entity;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
/**
|
||||
* 网络请求的response类
|
||||
* @author 澄泓
|
||||
* @date 2022/2/21 17:28
|
||||
* @version
|
||||
*/
|
||||
public class EsignHttpResponse {
|
||||
private int status;
|
||||
+5
-7
@@ -1,24 +1,22 @@
|
||||
package com.ruoyi.common.exception;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
/**
|
||||
* description 自定义全局异常
|
||||
* @author 澄泓
|
||||
* datetime 2019年7月1日上午10:43:24
|
||||
*/
|
||||
public class EsignDemoException extends Exception {
|
||||
public class EsignInterfacException extends Exception {
|
||||
|
||||
private static final long serialVersionUID = 4359180081622082792L;
|
||||
private Exception e;
|
||||
|
||||
public EsignDemoException(String msg) {
|
||||
public EsignInterfacException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
|
||||
public EsignDemoException(String msg, Throwable cause) {
|
||||
public EsignInterfacException(String msg, Throwable cause) {
|
||||
super(msg,cause);
|
||||
}
|
||||
|
||||
public EsignDemoException(){
|
||||
public EsignInterfacException(){
|
||||
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package com.ruoyi.common.enums;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import org.apache.http.client.methods.*;
|
||||
|
||||
+27
-31
@@ -9,9 +9,8 @@
|
||||
* an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations under the License.
|
||||
*/
|
||||
package com.ruoyi.common.constant;
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import org.apache.commons.codec.binary.Base64;
|
||||
|
||||
import java.io.*;
|
||||
@@ -23,10 +22,7 @@ import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author 澄泓
|
||||
* @version JDK1.7
|
||||
* @description 文件转换类
|
||||
* @date 2020/10/26 10:47
|
||||
*/
|
||||
public class FileTransformation {
|
||||
|
||||
@@ -35,9 +31,9 @@ public class FileTransformation {
|
||||
*
|
||||
* @param srcFilePath 本地文件路径
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static byte[] fileToBytes(String srcFilePath) throws EsignDemoException {
|
||||
public static byte[] fileToBytes(String srcFilePath) throws EsignInterfacException {
|
||||
return getBytes(srcFilePath);
|
||||
}
|
||||
|
||||
@@ -46,9 +42,9 @@ public class FileTransformation {
|
||||
*
|
||||
* @param filePath 本地文件路径
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static String fileToBase64(String filePath) throws EsignDemoException {
|
||||
public static String fileToBase64(String filePath) throws EsignInterfacException {
|
||||
byte[] bytes;
|
||||
String base64 = null;
|
||||
bytes = fileToBytes(filePath);
|
||||
@@ -57,7 +53,7 @@ public class FileTransformation {
|
||||
return base64;
|
||||
}
|
||||
|
||||
public static void main(String[] args) throws EsignDemoException {
|
||||
public static void main(String[] args) throws EsignInterfacException {
|
||||
System.out.println(getFileContentMD5("D:\\文档\\PLT2022-02124CT.pdf"));
|
||||
}
|
||||
|
||||
@@ -66,7 +62,7 @@ public class FileTransformation {
|
||||
* @param filePath 文件路径
|
||||
* @return
|
||||
*/
|
||||
public static String getFileContentMD5(String filePath) throws EsignDemoException {
|
||||
public static String getFileContentMD5(String filePath) throws EsignInterfacException {
|
||||
// 获取文件MD5的二进制数组(128位)
|
||||
byte[] bytes = getFileMD5Bytes128(filePath);
|
||||
// 对文件MD5的二进制数组进行base64编码
|
||||
@@ -79,7 +75,7 @@ public class FileTransformation {
|
||||
* @param httpUrl 网络文件地址url
|
||||
* @return
|
||||
*/
|
||||
public static boolean downLoadFileByUrl(String httpUrl, String dir) throws EsignDemoException {
|
||||
public static boolean downLoadFileByUrl(String httpUrl, String dir) throws EsignInterfacException {
|
||||
InputStream fis = null;
|
||||
FileOutputStream fileOutputStream = null;
|
||||
try {
|
||||
@@ -96,7 +92,7 @@ public class FileTransformation {
|
||||
fileOutputStream.write(buffer, 0, length);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("获取文件流异常", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("获取文件流异常", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} finally {
|
||||
@@ -108,7 +104,7 @@ public class FileTransformation {
|
||||
fileOutputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("关闭文件流异常", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("关闭文件流异常", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -123,7 +119,7 @@ public class FileTransformation {
|
||||
* @param fileUrl 网络文件地址url
|
||||
* @return
|
||||
*/
|
||||
public static Map fileUrlToBytes(String fileUrl) throws EsignDemoException {
|
||||
public static Map fileUrlToBytes(String fileUrl) throws EsignInterfacException {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
try {
|
||||
URL url = new URL(fileUrl);
|
||||
@@ -148,11 +144,11 @@ public class FileTransformation {
|
||||
fis.close();
|
||||
map.put("md5Bytes", md5Bytes);
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("获取文件流异常", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("获取文件流异常", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (NoSuchAlgorithmException e) {
|
||||
EsignDemoException ex = new EsignDemoException("文件计算异常", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("文件计算异常", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -163,9 +159,9 @@ public class FileTransformation {
|
||||
* 获取文件MD5的二进制数组(128位)
|
||||
* @param filePath
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static byte[] getFileMD5Bytes128(String filePath) throws EsignDemoException {
|
||||
public static byte[] getFileMD5Bytes128(String filePath) throws EsignInterfacException {
|
||||
FileInputStream fis = null;
|
||||
byte[] md5Bytes = null;
|
||||
try {
|
||||
@@ -180,15 +176,15 @@ public class FileTransformation {
|
||||
md5Bytes = md5.digest();
|
||||
fis.close();
|
||||
} catch (FileNotFoundException e) {
|
||||
EsignDemoException ex = new EsignDemoException("文件找不到", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("文件找不到", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (NoSuchAlgorithmException e) {
|
||||
EsignDemoException ex = new EsignDemoException("不支持此算法", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("不支持此算法", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("输入流或输出流异常", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("输入流或输出流异常", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} finally {
|
||||
@@ -196,7 +192,7 @@ public class FileTransformation {
|
||||
try {
|
||||
fis.close();
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("关闭文件输入流失败", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("关闭文件输入流失败", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -208,12 +204,12 @@ public class FileTransformation {
|
||||
/**
|
||||
* @param path
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
* @description 根据文件路径,获取文件base64
|
||||
* @author 宫清
|
||||
* @date 2019年7月21日 下午4:22:08
|
||||
*/
|
||||
public static String getBase64Str(String path) throws EsignDemoException {
|
||||
public static String getBase64Str(String path) throws EsignInterfacException {
|
||||
InputStream is = null;
|
||||
try {
|
||||
is = new FileInputStream(new File(path));
|
||||
@@ -221,7 +217,7 @@ public class FileTransformation {
|
||||
is.read(bytes);
|
||||
return Base64.encodeBase64String(bytes);
|
||||
} catch (Exception e) {
|
||||
EsignDemoException ex = new EsignDemoException("获取文件输入流失败", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("获取文件输入流失败", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} finally {
|
||||
@@ -229,7 +225,7 @@ public class FileTransformation {
|
||||
try {
|
||||
is.close();
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("关闭文件输入流失败", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("关闭文件输入流失败", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -251,12 +247,12 @@ public class FileTransformation {
|
||||
/**
|
||||
* @param filePath {@link String} 文件地址
|
||||
* @return
|
||||
* @throws EsignDemoException
|
||||
* @throws EsignInterfacException
|
||||
* @description 获取文件字节流
|
||||
* @date 2019年7月10日 上午9:17:00
|
||||
* @author 宫清
|
||||
*/
|
||||
public static byte[] getBytes(String filePath) throws EsignDemoException {
|
||||
public static byte[] getBytes(String filePath) throws EsignInterfacException {
|
||||
File file = new File(filePath);
|
||||
FileInputStream fis = null;
|
||||
byte[] buffer = null;
|
||||
@@ -265,7 +261,7 @@ public class FileTransformation {
|
||||
buffer = new byte[(int) file.length()];
|
||||
fis.read(buffer);
|
||||
} catch (Exception e) {
|
||||
EsignDemoException ex = new EsignDemoException("获取文件字节流失败", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("获取文件字节流失败", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
} finally {
|
||||
@@ -273,7 +269,7 @@ public class FileTransformation {
|
||||
try {
|
||||
fis.close();
|
||||
} catch (IOException e) {
|
||||
EsignDemoException ex = new EsignDemoException("关闭文件字节流失败", e);
|
||||
EsignInterfacException ex = new EsignInterfacException("关闭文件字节流失败", e);
|
||||
ex.initCause(e);
|
||||
throw ex;
|
||||
}
|
||||
@@ -0,0 +1,336 @@
|
||||
package com.ruoyi.wisdomarbitrate.utils;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.JsonArray;
|
||||
import com.google.gson.JsonObject;
|
||||
import com.ruoyi.wisdomarbitrate.domain.SealSignRecord;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public class SignAward {
|
||||
|
||||
private static String eSignHost= EsignApplicaConfig.EsignHost;
|
||||
private static String eSignAppId=EsignApplicaConfig.EsignAppId;
|
||||
private static String eSignAppSecret=EsignApplicaConfig.EsignAppSecret;
|
||||
// public static String fileId = "95d0c307d91e4985bdb8874f6f84daa5";
|
||||
public static String fileId = "a0c2ad21065f48ff8b872412c39d5d3a";
|
||||
|
||||
|
||||
|
||||
public static void main(String[] args) throws EsignInterfacException {
|
||||
Gson gson = new Gson();
|
||||
|
||||
SealSignRecord sealSignRecord = new SealSignRecord();
|
||||
|
||||
sealSignRecord.setFileid("a808f1f39a744357a2f018e4ab34c55d");
|
||||
sealSignRecord.setFilename("23893bfd3f2249ffa5c82850c11c482e.pdf");
|
||||
sealSignRecord.setSignFlowid("41e6732b48c54c63a91b2379c352212d");
|
||||
|
||||
|
||||
sealSignRecord.setPensonAccount("18209231185");
|
||||
sealSignRecord.setPensonName("秦桃则");
|
||||
sealSignRecord.setOrgnizeName("西安云美电子科技有限公司");
|
||||
sealSignRecord.setOrgnizeNamePsnAccount("17691338406");
|
||||
sealSignRecord.setOrgnizeNamepsnName("韩超勃");
|
||||
sealSignRecord.setPositionPagepsn("2");
|
||||
|
||||
sealSignRecord.setPositionXpsn(279+20);
|
||||
sealSignRecord.setPositionYpsn(216.336-20);
|
||||
|
||||
sealSignRecord.setPositionPageorg("2");
|
||||
|
||||
sealSignRecord.setPositionXorg(342+30);
|
||||
sealSignRecord.setPositionYorg(185.136);
|
||||
|
||||
|
||||
|
||||
|
||||
/* 发起签署*/
|
||||
// EsignHttpResponse createByFile = createByFile(sealSignRecord);
|
||||
// JsonObject createByFileJsonObject = gson.fromJson(createByFile.getBody(), JsonObject.class);
|
||||
// JsonObject createByFileData = createByFileJsonObject.getAsJsonObject("data");
|
||||
// String signFlowId = createByFileData.get("signFlowId").getAsString();
|
||||
// System.err.println("流程id:"+signFlowId);
|
||||
|
||||
/* 获取文件签名印章位置*/
|
||||
// EsignHttpResponse positions = getPositions(sealSignRecord);
|
||||
// JsonObject positionsJsonObject = gson.fromJson(positions.getBody(), JsonObject.class);
|
||||
// JsonObject positionsData = positionsJsonObject.getAsJsonObject("data");
|
||||
// JsonArray keywordPositions = positionsData.get("keywordPositions").getAsJsonArray();
|
||||
// System.out.println("获取文件签名印章位置:" +keywordPositions.toString());
|
||||
|
||||
// String signFlowId = "c9955453716344f9971d308abdc13464";
|
||||
//获取合同文件签名链接
|
||||
// EsignHttpResponse signUrl = signUrl(sealSignRecord);
|
||||
// JsonObject signUrlJsonObject = gson.fromJson(signUrl.getBody(), JsonObject.class);
|
||||
// JsonObject signUrlData = signUrlJsonObject.getAsJsonObject("data");
|
||||
// String shortUrl = signUrlData.get("shortUrl").getAsString();
|
||||
// String url = signUrlData.get("url").getAsString();
|
||||
// System.out.println("签署短链接:" +shortUrl);
|
||||
// System.out.println("签署长链接:"+url);
|
||||
|
||||
//获取合同文件用印链接
|
||||
EsignHttpResponse usesealUrl = usesealUrl(sealSignRecord);
|
||||
JsonObject usesealUrlJsonObject = gson.fromJson(usesealUrl.getBody(), JsonObject.class);
|
||||
JsonObject usesealUrlData = usesealUrlJsonObject.getAsJsonObject("data");
|
||||
String shortusesealUrl = usesealUrlData.get("shortUrl").getAsString();
|
||||
String sealUrl = usesealUrlData.get("url").getAsString();
|
||||
System.out.println("签署长链接:" +shortusesealUrl);
|
||||
System.out.println("签署短链接:"+sealUrl);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 发起签署
|
||||
* @return
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static EsignHttpResponse createByFile(SealSignRecord sealSignRecord) throws EsignInterfacException {
|
||||
String apiaddr = "/v3/sign-flow/create-by-file";
|
||||
|
||||
String fileId = sealSignRecord.getFileid();
|
||||
String fileName = sealSignRecord.getFilename();
|
||||
|
||||
String psnAccount = sealSignRecord.getPensonAccount();
|
||||
String psnName = sealSignRecord.getPensonName();
|
||||
|
||||
String orgName = sealSignRecord.getOrgnizeName();
|
||||
String orgNamePsnAccount = sealSignRecord.getOrgnizeNamePsnAccount();
|
||||
String orgNamepsnName = sealSignRecord.getOrgnizeNamepsnName();
|
||||
|
||||
String positionPagepsn = sealSignRecord.getPositionPagepsn();
|
||||
double positionXpsn = sealSignRecord.getPositionXpsn();
|
||||
double positionYpsn = sealSignRecord.getPositionYpsn();
|
||||
|
||||
String positionPageorg = sealSignRecord.getPositionPageorg();
|
||||
double positionXorg = sealSignRecord.getPositionXorg();
|
||||
double positionYorg = sealSignRecord.getPositionYorg();
|
||||
|
||||
|
||||
String jsonParm = "{\n" +
|
||||
" \"docs\": [\n" +
|
||||
" {\n" +
|
||||
|
||||
// " \"fileId\": \"5bd34a81e8084acaab3287c019e82fe8\",\n" +
|
||||
" \"fileId\": \"" + fileId + "\",\n" +
|
||||
|
||||
// " \"fileName\": \"477470a7741b4536a200c792b6ddf966.pdf\"\n" +
|
||||
" \"fileName\": \"" + fileName + "\"\n" +
|
||||
|
||||
" }\n" +
|
||||
" ],\n" +
|
||||
" \"signFlowConfig\": {\n" +
|
||||
" \"signFlowTitle\": \"测试合同\",\n" +
|
||||
" \"autoStart\": true,\n" +
|
||||
" \"authConfig\": {\n" +
|
||||
" \"willingnessAuthModes\": [\n" +
|
||||
" \"CODE_SMS\"\n" +
|
||||
" ],\n" +
|
||||
" \"psnAvailableAuthModes\": [\n" +
|
||||
" \"PSN_MOBILE3\"\n" +
|
||||
" ],\n" +
|
||||
" \"orgAvailableAuthModes\": [\n" +
|
||||
" \"ORG_LEGALREP\"\n" +
|
||||
" ]\n" +
|
||||
" },\n" +
|
||||
" \"autoFinish\": true\n" +
|
||||
" },\n" +
|
||||
|
||||
" \"signers\": [\n" +
|
||||
|
||||
" {\n" +
|
||||
|
||||
" \"psnSignerInfo\": {\n" +
|
||||
|
||||
// " \"psnAccount\": \"18209231185\",\n" +
|
||||
" \"psnAccount\": \"" + psnAccount + "\",\n" +
|
||||
|
||||
" \"psnInfo\": {\n" +
|
||||
|
||||
// " \"psnName\": \"秦桃则\"\n" +
|
||||
" \"psnName\": \"" + psnName + "\"\n" +
|
||||
" }\n" +
|
||||
|
||||
|
||||
" },\n" +
|
||||
|
||||
|
||||
" \"signFields\": [\n" +
|
||||
" {\n" +
|
||||
|
||||
// " \"fileId\": \"5bd34a81e8084acaab3287c019e82fe8\",\n" +
|
||||
" \"fileId\": \"" + fileId + "\",\n" +
|
||||
|
||||
" \"normalSignFieldConfig\": {\n" +
|
||||
" \"autoSign\": false,\n" +
|
||||
" \"freeMode\": false,\n" +
|
||||
" \"movableSignField\": false,\n" +
|
||||
" \"signFieldPosition\": {\n" +
|
||||
|
||||
// " \"positionPage\": \"2\",\n" +
|
||||
" \"positionPage\": \"" + positionPagepsn + "\",\n" +
|
||||
|
||||
// " \"positionX\": 310.0,\n" +
|
||||
" \"positionX\": " + positionXpsn + ",\n" +
|
||||
|
||||
// " \"positionY\": 247.536\n" +
|
||||
" \"positionY\": " + positionYpsn + "\n" +
|
||||
|
||||
" },\n" +
|
||||
" \"signFieldStyle\": 1\n" +
|
||||
" },\n" +
|
||||
" \"signFieldType\": 0\n" +
|
||||
" }\n" +
|
||||
" ],\n" +
|
||||
" \"signerType\": 0\n" +
|
||||
" },\n" +
|
||||
|
||||
|
||||
" {\n" +
|
||||
" \"orgSignerInfo\": {\n" +
|
||||
|
||||
// " \"orgName\": \"西安云美电子科技有限公司\",\n" +
|
||||
" \"orgName\": \"" + orgName + "\",\n" +
|
||||
|
||||
" \"transactorInfo\": {\n" +
|
||||
|
||||
|
||||
// " \"psnAccount\": \"17691338406\",\n" +
|
||||
" \"psnAccount\": \"" + orgNamePsnAccount + "\",\n" +
|
||||
|
||||
" \"psnInfo\": {\n" +
|
||||
|
||||
// " \"psnName\": \"韩超勃\"\n" +
|
||||
" \"psnName\": \"" + orgNamepsnName + "\"\n" +
|
||||
" }\n" +
|
||||
|
||||
" }\n" +
|
||||
" },\n" +
|
||||
|
||||
" \"signFields\": [\n" +
|
||||
" {\n" +
|
||||
|
||||
// " \"fileId\": \"5bd34a81e8084acaab3287c019e82fe8\",\n" +
|
||||
" \"fileId\": \"" + fileId + "\",\n" +
|
||||
|
||||
" \"normalSignFieldConfig\": {\n" +
|
||||
" \"autoSign\": false,\n" +
|
||||
" \"freeMode\": false,\n" +
|
||||
|
||||
" \"signFieldPosition\": {\n" +
|
||||
|
||||
// " \"positionPage\": \"2\",\n" +
|
||||
" \"positionPage\": \"" + positionPageorg + "\",\n" +
|
||||
|
||||
// " \"positionX\": 340.0,\n" +
|
||||
" \"positionX\": " + positionXorg + ",\n" +
|
||||
|
||||
// " \"positionY\": 340.736\n" +
|
||||
" \"positionY\": " + positionYorg + "\n" +
|
||||
" },\n" +
|
||||
" \"signFieldStyle\": 1\n" +
|
||||
" },\n" +
|
||||
" \"signFieldType\": 0\n" +
|
||||
" }\n" +
|
||||
" ],\n" +
|
||||
" \"signerType\": 1\n" +
|
||||
" }\n" +
|
||||
|
||||
" ]\n" +
|
||||
"}";
|
||||
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取合同文件签名链接
|
||||
* @return
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static EsignHttpResponse signUrl(SealSignRecord sealSignRecord) throws EsignInterfacException {
|
||||
|
||||
String signFlowId = sealSignRecord.getSignFlowid();
|
||||
String psnAccount = sealSignRecord.getPensonAccount();
|
||||
|
||||
String apiaddr = "/v3/sign-flow/" + signFlowId + "/sign-url";
|
||||
String jsonParm = "{\n" +
|
||||
" \"operator\": {\n" +
|
||||
// " \"psnAccount\":\"18209231185\"\n" +
|
||||
" \"psnAccount\": \"" + psnAccount + "\"\n" +
|
||||
" }\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取合同文件用印链接
|
||||
* @return
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static EsignHttpResponse usesealUrl(SealSignRecord sealSignRecord) throws EsignInterfacException {
|
||||
String signFlowId = sealSignRecord.getSignFlowid();
|
||||
String apiaddr = "/v3/sign-flow/" + signFlowId + "/sign-url";
|
||||
|
||||
String psnAccount = sealSignRecord.getOrgnizeNamePsnAccount();
|
||||
String orgName = sealSignRecord.getOrgnizeName();
|
||||
|
||||
String jsonParm = "{\n" +
|
||||
// " \"needLogin\": true,\n" +
|
||||
" \"operator\": {\n" +
|
||||
|
||||
// " \"psnAccount\":\"17691338406\"\n" +
|
||||
" \"psnAccount\": \"" + psnAccount + "\"\n" +
|
||||
" },\n" +
|
||||
" \"organization\": {\n" +
|
||||
|
||||
// " \"orgName\": \"西安云美电子科技有限公司\"\n" +
|
||||
" \"orgName\": \"" + orgName + "\"\n" +
|
||||
|
||||
" }\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取文件签名印章位置
|
||||
* @return
|
||||
* @throws EsignInterfacException
|
||||
*/
|
||||
public static EsignHttpResponse getPositions(SealSignRecord sealSignRecord) throws EsignInterfacException {
|
||||
String fileId = sealSignRecord.getFileid();
|
||||
String apiaddr = "/v3/files/" + fileId + "/keyword-positions";
|
||||
String jsonParm = "{\n" +
|
||||
" \"keywords\": [\n" +
|
||||
" \"仲裁员:\",\n" +
|
||||
" \"(仲裁委员会盖章)\"\n" +
|
||||
" ]\n" +
|
||||
"}";
|
||||
//请求方法
|
||||
EsignRequestType requestType = EsignRequestType.POST;
|
||||
//生成请求签名鉴权方式的Header
|
||||
Map<String, String> header = EsignHttpHelper.signAndBuildSignAndJsonHeader(eSignAppId, eSignAppSecret, jsonParm, requestType.name(), apiaddr, true);
|
||||
//发起接口请求
|
||||
return EsignHttpHelper.doCommHttp(eSignHost, apiaddr, requestType, jsonParm, header, true);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -87,7 +87,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where dept_name=#{deptName} and parent_id = #{parentId} and del_flag = '0' limit 1
|
||||
</select>
|
||||
|
||||
<insert id="insertDept" parameterType="SysDept" useGeneratedKeys="true" keyColumn="dept_id" keyProperty="deptId">
|
||||
<insert id="insertDept" parameterType="SysDept">
|
||||
insert into sys_dept(
|
||||
<if test="deptId != null and deptId != 0">dept_id,</if>
|
||||
<if test="parentId != null and parentId != 0">parent_id,</if>
|
||||
@@ -112,7 +112,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="status != null">#{status},</if>
|
||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||
sysdate()
|
||||
);
|
||||
)
|
||||
</insert>
|
||||
|
||||
<update id="updateDept" parameterType="SysDept">
|
||||
|
||||
@@ -37,4 +37,21 @@
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</mapper>
|
||||
@@ -33,20 +33,6 @@
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
<select id="selectCaseAffiliateByIdentityType" resultMap="CaseAffiliateResult">
|
||||
select c.id ,c.case_appli_id ,c.identity_type ,c.name ,c.identity_num ,c.contact_telphone ,c.contact_address ,
|
||||
c.work_address ,c.work_telphone ,c.name_agent, c.identity_num_agent ,c.contact_telphone_agent ,c.contact_address_agent,
|
||||
c.track_num
|
||||
from case_affiliate c
|
||||
<where>
|
||||
<if test="caseAppliId != null ">
|
||||
AND c.case_appli_id = #{caseAppliId}
|
||||
</if>
|
||||
<if test="caseAppliId != null ">
|
||||
AND c.identity_type = #{identityType}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
||||
<insert id="batchCaseAffiliate">
|
||||
|
||||
@@ -55,10 +55,8 @@
|
||||
c.hear_date ,c.arbitrat_claims ,
|
||||
c.loan_start_date ,c.loan_end_date ,c.claim_princi_owed ,c.claim_interest_owed ,c.claim_liquid_damag ,c.fee_payable ,
|
||||
c.begin_video_date ,c.online_video_person ,c.contract_number ,c.create_by ,c.create_time ,
|
||||
c.update_by ,c.update_time , c.arbitrator_name,d.dept_name as applicantName
|
||||
c.update_by ,c.update_time , c.arbitrator_name
|
||||
from case_application c
|
||||
LEFT JOIN case_affiliate ca ON ca.case_appli_id = c.id and ca.identity_type=1
|
||||
LEFT JOIN sys_dept d ON ca.NAME = d.dept_id and ca.name=d.dept_id
|
||||
<where>
|
||||
<if test="caseStatus != null">
|
||||
AND c.case_status = #{caseStatus}
|
||||
@@ -66,9 +64,6 @@
|
||||
<if test="caseNum != null and caseNum != ''">
|
||||
AND c.case_num = #{caseNum}
|
||||
</if>
|
||||
<if test="nameId != null and nameId != ''">
|
||||
AND ca.NAME=#{nameId} AND ca.identity_type=1 and ca.name=d.dept_id
|
||||
</if>
|
||||
<if test="caseStatusList != null and caseStatusList.size() > 0">
|
||||
and c.case_status in
|
||||
<foreach item="caseStatus" collection="caseStatusList" open="(" separator="," close=")">
|
||||
@@ -206,10 +201,8 @@
|
||||
c.hear_date ,c.arbitrat_claims ,
|
||||
c.loan_start_date ,c.loan_end_date ,c.claim_princi_owed ,c.claim_interest_owed ,c.claim_liquid_damag ,c.fee_payable ,
|
||||
c.begin_video_date ,c.online_video_person ,c.contract_number ,c.create_by ,c.create_time ,
|
||||
c.update_by ,c.update_time,c.arbitrator_id,c.arbitrator_name,d.dept_name as applicantName
|
||||
c.update_by ,c.update_time,c.arbitrator_id,c.arbitrator_name
|
||||
from case_application c
|
||||
LEFT JOIN case_affiliate ca ON ca.case_appli_id = c.id and ca.identity_type=1
|
||||
LEFT JOIN sys_dept d ON ca.NAME = d.dept_id and ca.name=d.dept_id
|
||||
<where>
|
||||
<if test="id != null ">
|
||||
AND c.id = #{id}
|
||||
|
||||
@@ -10,30 +10,43 @@
|
||||
<result property="caseNodeTime" column="case_node_time" />
|
||||
<result property="notes" column="notes" />
|
||||
<result property="caseNum" column="case_num" />
|
||||
<result property="createBy" column=" create_by" />
|
||||
<result property="createNickName" column="create_nick_name" />
|
||||
|
||||
</resultMap>
|
||||
|
||||
<insert id="insertCaseLogRecord">
|
||||
insert into case_log_record(case_appli_id, case_node,case_node_time,notes,create_by,create_nick_name,create_time,update_by,update_time ) values(
|
||||
#{caseAppliId},#{caseNode},sysdate(),#{notes},#{createBy},#{createNickName},sysdate(),#{updateBy},sysdate()
|
||||
insert into case_log_record(case_appli_id, case_node,case_node_time,notes,create_by,create_time ) values(
|
||||
#{caseAppliId},#{caseNode},sysdate(),#{notes},#{createBy},sysdate()
|
||||
)
|
||||
</insert>
|
||||
<select id="selectCaseLogRecordList" resultType="com.ruoyi.wisdomarbitrate.domain.CaseLogRecord">
|
||||
select cl.case_node caseNode ,cl.case_node_time caseNodeTime ,cl.notes ,cl.id ,cl.case_appli_id caseAppliId,
|
||||
cl.create_by createBy,cl.create_nick_name createNickName,cl.create_time createTime,cl.update_by updateBy,cl.update_time updateTime
|
||||
from case_log_record cl
|
||||
|
||||
<select id="selectCaseLogRecordList" parameterType="CaseLogRecord" resultMap="CaseLogRecordResult">
|
||||
select cl.case_node ,cl.case_node_time ,cl.notes ,c.case_num ,cl.id ,cl.case_appli_id
|
||||
from case_log_record cl left join case_application c on cl.case_appli_id = c.id
|
||||
<where>
|
||||
|
||||
<if test="caseAppliId != null and caseAppliId != ''">
|
||||
AND cl.case_appli_id = #{caseAppliId}
|
||||
<if test="caseNum != null and caseNum != ''">
|
||||
AND c.case_num = #{caseNum}
|
||||
</if>
|
||||
</where>
|
||||
order by create_time asc
|
||||
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</mapper>
|
||||
+1
-1
@@ -20,7 +20,7 @@
|
||||
<if test="name != null and name != ''">name,</if>
|
||||
<if test="identityNo != null and identityNo != ''">identity_no,</if>
|
||||
certification_time,
|
||||
<if test="certificationStatus != null">certification_status,</if>
|
||||
<if test="certificationStatus != null and certificationStatus != ''">certification_status,</if>
|
||||
<if test="userName != null and userName != ''">user_name,</if>
|
||||
<if test="createBy != null and createBy != ''">create_by,</if>
|
||||
create_time
|
||||
|
||||
Reference in New Issue
Block a user