Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
091f8b9be5 | ||
|
|
b2e0e7465d | ||
|
|
a78d2bd6c7 | ||
|
|
b5cdcbad4a | ||
|
|
a54280c347 | ||
|
|
22ccd19725 | ||
|
|
8261c52673 | ||
|
|
44babb09b1 | ||
|
|
084c22a00f | ||
|
|
34524284d4 | ||
|
|
0f8ee6e6fe | ||
|
|
06ef88126b | ||
|
|
e9c7346843 | ||
|
|
7e2c288beb | ||
|
|
b3f445fdd4 | ||
|
|
e1484a5889 | ||
|
|
48752c2712 | ||
|
|
e637b7c511 | ||
|
|
bf43517b5c | ||
|
|
9df0b9e290 | ||
|
|
42c9a82363 | ||
|
|
198b29dcb0 | ||
|
|
44129c7cd0 | ||
|
|
50a9e7242c | ||
|
|
5b24d0f522 | ||
|
|
fbcf91a592 | ||
|
|
8c22728855 | ||
|
|
9840cae11d | ||
|
|
25f4ac62c7 | ||
|
|
f7e4f7df3f | ||
|
|
d705802c6a | ||
|
|
30e0be1493 | ||
|
|
d9a2454fe8 | ||
|
|
f6bf5abc9f | ||
|
|
77f84afdd6 | ||
|
|
0e215afa39 | ||
|
|
189433a164 | ||
|
|
c19c61affd | ||
|
|
4a807869aa | ||
|
|
064b88a86a | ||
|
|
7d8529e7d8 | ||
|
|
374841e417 | ||
|
|
c22b16e7ac | ||
|
|
2f3b5645aa | ||
|
|
d05a943e66 | ||
|
|
b7f1e265f9 | ||
|
|
03bc65284d | ||
|
|
e3fe728c6c | ||
|
|
86e209494f | ||
|
|
6c5e16386c |
+3
-2
@@ -9,7 +9,8 @@
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<packaging>jar</packaging>
|
||||
<artifactId>ruoyi-admin</artifactId>
|
||||
<artifactId>SmartArbitrate</artifactId>
|
||||
<version>1.1.0</version>
|
||||
|
||||
<description>
|
||||
web服务入口
|
||||
@@ -94,7 +95,7 @@
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
<finalName>${project.artifactId}</finalName>
|
||||
<finalName>${project.artifactId}-${project.version}</finalName>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
@@ -1,10 +1,20 @@
|
||||
package com.ruoyi;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import com.ruoyi.common.constant.CacheConstants;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.core.redis.RedisCache;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import com.ruoyi.system.mapper.SysRoleMapper;
|
||||
import com.ruoyi.system.mapper.SysUserMapper;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 启动程序
|
||||
*
|
||||
@@ -18,15 +28,28 @@ public class RuoYiApplication
|
||||
{
|
||||
// System.setProperty("spring.devtools.restart.enabled", "false");
|
||||
SpringApplication.run(RuoYiApplication.class, args);
|
||||
System.out.println("(♥◠‿◠)ノ゙ 若依启动成功 ლ(´ڡ`ლ)゙ \n" +
|
||||
" .-------. ____ __ \n" +
|
||||
" | _ _ \\ \\ \\ / / \n" +
|
||||
" | ( ' ) | \\ _. / ' \n" +
|
||||
" |(_ o _) / _( )_ .' \n" +
|
||||
" | (_,_).' __ ___(_ o _)' \n" +
|
||||
" | |\\ \\ | || |(_,_)' \n" +
|
||||
" | | \\ `' /| `-' / \n" +
|
||||
" | | \\ / \\ / \n" +
|
||||
" ''-' `'-' `-..-' ");
|
||||
System.out.println(" __ _ \n" +
|
||||
" ____ / /_ ____ ____ ____ _ _________ _(_)\n" +
|
||||
"/_ / / __ \\/ __ \\/ __ \\/ __ `/ / ___/ __ `/ / \n" +
|
||||
" / /_/ / / / /_/ / / / / /_/ / / /__/ /_/ / / \n" +
|
||||
"/___/_/ /_/\\____/_/ /_/\\__, / \\___/\\__,_/_/ \n" +
|
||||
" /____/ ");
|
||||
// 启动成功后,查询用户表,将用户信息存到redis
|
||||
RedisCache redisCache = SpringUtils.getBean(RedisCache.class);
|
||||
SysUserMapper userMapper = SpringUtils.getBean(SysUserMapper.class);
|
||||
List<SysUser> sysUsers = userMapper.selectUserListByIds(null);
|
||||
if(CollectionUtil.isNotEmpty(sysUsers)){
|
||||
for (SysUser sysUser : sysUsers) {
|
||||
redisCache.setCacheObject(CacheConstants.USER_KEY+sysUser.getUserId(),sysUser);
|
||||
}
|
||||
}
|
||||
// 初始化角色redis
|
||||
SysRoleMapper roleMapper = SpringUtils.getBean(SysRoleMapper.class);
|
||||
List<SysRole> roles = roleMapper.selectRoleList(new SysRole());
|
||||
if(CollectionUtil.isNotEmpty(roles)){
|
||||
for (SysRole role : roles) {
|
||||
redisCache.setCacheObject(CacheConstants.ROLE_KEY+role.getRoleName(),role.getRoleId());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,14 +4,15 @@ import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseAttachMapper;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import com.ruoyi.common.config.RuoYiConfig;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
@@ -36,6 +37,8 @@ public class CommonController
|
||||
private ServerConfig serverConfig;
|
||||
|
||||
private static final String FILE_DELIMETER = ",";
|
||||
@Autowired
|
||||
CaseAttachMapper caseAttachMapper;
|
||||
|
||||
/**
|
||||
* 通用下载请求
|
||||
@@ -160,4 +163,22 @@ public class CommonController
|
||||
log.error("下载文件失败", e);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 根据案件id获取附件
|
||||
* @param caseAppliId
|
||||
* @param annexTypeList
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/fileList")
|
||||
public AjaxResult fileList(@RequestParam("caseAppliId")Long caseAppliId, @RequestParam(value = "annexTypeList",required = false) List<Integer> annexTypeList){
|
||||
if(caseAppliId==null){
|
||||
return AjaxResult.error("案件id不能为空");
|
||||
}
|
||||
CaseApplication msCaseApplicationVO = new CaseApplication();
|
||||
msCaseApplicationVO.setId(caseAppliId);
|
||||
msCaseApplicationVO.setAnnexTypeList(annexTypeList);
|
||||
List<CaseAttach> caseAttachList = caseAttachMapper.queryCaseAttachList(msCaseApplicationVO);
|
||||
return AjaxResult.success(caseAttachList);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ public class SysDeptController extends BaseController
|
||||
/**
|
||||
* 获取部门列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:list')")
|
||||
// @PreAuthorize("@ss.hasPermi('system:dept:list')")
|
||||
@GetMapping("/list")
|
||||
public AjaxResult list(SysDept dept)
|
||||
{
|
||||
|
||||
@@ -139,4 +139,13 @@ public class SysMenuController extends BaseController
|
||||
}
|
||||
return toAjax(menuService.deleteMenuById(menuId));
|
||||
}
|
||||
/**
|
||||
* 根据用户查询菜单权限字符
|
||||
*/
|
||||
@GetMapping("/getMenuPermsByUser")
|
||||
public AjaxResult getMenuPermsByUser()
|
||||
{
|
||||
|
||||
return menuService.getMenuPermsByUser();
|
||||
}
|
||||
}
|
||||
+48
-49
@@ -2,6 +2,7 @@ package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
@@ -44,14 +45,14 @@ public class AdjudicationController extends BaseController {
|
||||
/**
|
||||
* 根据批号查询批量签名链接
|
||||
*/
|
||||
@PostMapping("/getSignUrlBatch")
|
||||
public AjaxResult getSignUrlBatch(@RequestBody StringIdsReq idsReq) {
|
||||
if(StrUtil.isEmpty(idsReq.getBatchNumber().toString())|| StrUtil.isEmpty(idsReq.getPsnAccount())){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
SealSignRecord sealSignRecordselect = adjudicationService.getSignUrlBatch(idsReq);
|
||||
return success(sealSignRecordselect);
|
||||
}
|
||||
// @PostMapping("/getSignUrlBatch")
|
||||
// public AjaxResult getSignUrlBatch(@RequestBody StringIdsReq idsReq) {
|
||||
// if(StrUtil.isEmpty(idsReq.getBatchNumber().toString())|| StrUtil.isEmpty(idsReq.getPsnAccount())){
|
||||
// return error("参数校验失败");
|
||||
// }
|
||||
// SealSignRecord sealSignRecordselect = adjudicationService.getSignUrlBatch(idsReq);
|
||||
// return success(sealSignRecordselect);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 根据签署流程id查询批量用印链接
|
||||
@@ -101,6 +102,18 @@ public class AdjudicationController extends BaseController {
|
||||
}
|
||||
return adjudicationService.createDocument(caseApplication);
|
||||
}
|
||||
/**
|
||||
* 开庭审理,确定审理结果,生成裁决书
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/caseJudgment")
|
||||
public AjaxResult caseJudgment(@Validated @RequestBody CaseApplication caseApplication){
|
||||
if (caseApplication.getId() == null) {
|
||||
return AjaxResult.error("案件id不能为空");
|
||||
}
|
||||
return adjudicationService.caseJudgment(caseApplication);
|
||||
}
|
||||
/**
|
||||
* 批量生成裁决书
|
||||
* @param caseApplication
|
||||
@@ -114,15 +127,7 @@ public class AdjudicationController extends BaseController {
|
||||
return adjudicationService.batchDocument(caseApplication.getIds());
|
||||
}
|
||||
|
||||
/**
|
||||
* 重新生成裁决书
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/regenerationDocument")
|
||||
public AjaxResult regenerationDocument(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return adjudicationService.regenerationDocument(caseApplication);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 裁决书送达(电子邮件)
|
||||
@@ -139,23 +144,14 @@ public class AdjudicationController extends BaseController {
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/logistics")
|
||||
// @PreAuthorize("@ss.hasPermi('delivery:detail')")
|
||||
public AjaxResult getLogisticsInfo(CaseApplication caseApplication){
|
||||
List<LogisticsInfoVO> logisticsInfo = adjudicationService.getLogisticsInfo(caseApplication);
|
||||
return AjaxResult.success(logisticsInfo);
|
||||
}
|
||||
// @GetMapping("/logistics")
|
||||
//// @PreAuthorize("@ss.hasPermi('delivery:detail')")
|
||||
// public AjaxResult getLogisticsInfo(CaseApplication caseApplication){
|
||||
// List<LogisticsInfoVO> logisticsInfo = adjudicationService.getLogisticsInfo(caseApplication);
|
||||
// return AjaxResult.success(logisticsInfo);
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* 签名(暂时只改案件状态)
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/signature")
|
||||
// @PreAuthorize("@ss.hasPermi('awardManagement:list:sign')")
|
||||
public AjaxResult signature(@Validated @RequestBody CaseApplication caseApplication){
|
||||
return adjudicationService.signature(caseApplication);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
@@ -174,7 +170,7 @@ public class AdjudicationController extends BaseController {
|
||||
|
||||
/**
|
||||
* 批量归档(暂时只改案件状态)
|
||||
* @param batchCaseApplication
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/caseFileBatch")
|
||||
@@ -209,27 +205,18 @@ public class AdjudicationController extends BaseController {
|
||||
return adjudicationService.serviceBatch(caseApplication.getBatchNumber());
|
||||
}
|
||||
|
||||
/**
|
||||
* 用印(暂时只改案件状态)
|
||||
* @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);
|
||||
}
|
||||
// @GetMapping("/archives")
|
||||
// public AjaxResult getArchivesDetail(Long id){
|
||||
//
|
||||
// return adjudicationService.getArchivesDetail(id);
|
||||
// }
|
||||
/**
|
||||
* 根据案件id获取邮箱
|
||||
* @param id 案件id
|
||||
@@ -240,5 +227,17 @@ public class AdjudicationController extends BaseController {
|
||||
|
||||
return adjudicationService.emailByCaseId(id);
|
||||
}
|
||||
/**
|
||||
* 开庭审理提交,只改变案件状态为CaseApplicationConstants.VERPRIF_ARBITRATION
|
||||
* @param caseApplication 案件
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/changeCaseStatus")
|
||||
public AjaxResult changeCaseStatus(@RequestBody CaseApplication caseApplication){
|
||||
if(caseApplication.getId()==null){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
return adjudicationService.changeCaseStatus(caseApplication.getId(), CaseApplicationConstants.VERPRIF_ARBITRATION);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+3
-2
@@ -6,6 +6,7 @@ import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.CheckSignatuerUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseApplicationDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseApplicationVO;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
@@ -32,10 +33,10 @@ public class ArbitrateApplicationController extends BaseController {
|
||||
String paramsbody = JSONUtil.toJsonStr(caseApplicationVO);
|
||||
boolean checkResult= CheckSignatuerUtils.checkSignuter(paramsbody);
|
||||
if(checkResult){
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
CaseApplicationDTO caseApplication = new CaseApplicationDTO();
|
||||
BeanUtils.copyProperties(caseApplicationVO,caseApplication);
|
||||
caseApplication.setCreateBy(getUsername());
|
||||
return toAjax(caseApplicationService.insertcaseApplication1(caseApplication));
|
||||
return caseApplicationService.insertOrUpdate(caseApplication);
|
||||
}else {
|
||||
return AjaxResult.error("签名验证失败");
|
||||
}
|
||||
|
||||
+6
-3
@@ -1,6 +1,7 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.system.mapper.SysUserMapper;
|
||||
@@ -26,11 +27,13 @@ public class ArbitratorController extends BaseController {
|
||||
*/
|
||||
// @PreAuthorize("@ss.hasPermi('arbitrator:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(Arbitrator arbitrator)
|
||||
public AjaxResult list(Arbitrator arbitrator)
|
||||
{
|
||||
startPage();
|
||||
if(arbitrator.getCaseId()==null){
|
||||
return AjaxResult.error("案件id不能为空");
|
||||
}
|
||||
List<SysUser> list = sysUserService.selectUserListByAdRole(arbitrator);
|
||||
return getDataTable(list);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
|
||||
|
||||
+82
-68
@@ -12,6 +12,7 @@ import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.WxAppletNotifyUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseApplicationDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ReservedConferenceVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.SendRoomNoMessageVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ToDoCount;
|
||||
@@ -37,8 +38,17 @@ public class CaseApplicationController extends BaseController {
|
||||
private ICaseApplicationService caseApplicationService;
|
||||
@Autowired
|
||||
private IAdjudicationService adjudicationService;
|
||||
/**
|
||||
* 根据登录人返回用户信息
|
||||
*/
|
||||
@GetMapping("/getUserInfo")
|
||||
public AjaxResult getUserInfo()
|
||||
{
|
||||
|
||||
|
||||
return success(caseApplicationService.getUserInfo());
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询立案数据
|
||||
*/
|
||||
@@ -48,20 +58,20 @@ public class CaseApplicationController extends BaseController {
|
||||
if(StrUtil.isEmpty(caseApplication.getSelectCaseStatus())){
|
||||
caseApplication.setSelectCaseStatus("0");
|
||||
}
|
||||
startPage();
|
||||
List<CaseApplication> list = caseApplicationService.selectCaseApplicationListByRole(caseApplication);
|
||||
// List<CaseApplication> list = caseApplicationService.selectCaseApplicationListByRole(caseApplication);
|
||||
List<CaseApplication> list = caseApplicationService.page(caseApplication);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询批量管理案件列表
|
||||
*/
|
||||
@GetMapping("/listBatch")
|
||||
public TableDataInfo listBatch(CaseApplication caseApplication) {
|
||||
startPage();
|
||||
List<CaseApplication> list = caseApplicationService.selectCaseApplicationListBatchByRole(caseApplication);
|
||||
return getDataTable(list);
|
||||
}
|
||||
// /**
|
||||
// * 查询批量管理案件列表
|
||||
// */
|
||||
// @GetMapping("/listBatch")
|
||||
// public TableDataInfo listBatch(CaseApplication caseApplication) {
|
||||
// startPage();
|
||||
// List<CaseApplication> list = caseApplicationService.selectCaseApplicationListBatchByRole(caseApplication);
|
||||
// return getDataTable(list);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 根据角色查询待办数量
|
||||
@@ -81,24 +91,24 @@ public class CaseApplicationController extends BaseController {
|
||||
// @PreAuthorize("@ss.hasPermi('caseManagement:list:add')")
|
||||
@Log(title = "新增立案数据", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/addCaseApplication")
|
||||
public AjaxResult addCaseApplication(@Validated @RequestBody CaseApplication caseApplication)
|
||||
public AjaxResult addCaseApplication(@Validated @RequestBody CaseApplicationDTO caseApplication)
|
||||
{
|
||||
|
||||
caseApplication.setCreateBy(getUsername());
|
||||
return toAjax(caseApplicationService.insertcaseApplication(caseApplication));
|
||||
return caseApplicationService.insertOrUpdate(caseApplication);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改立案数据
|
||||
*/
|
||||
// @PreAuthorize("@ss.hasPermi('caseManagement:list:update')")
|
||||
@Log(title = "修改立案数据", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/editCaseApplication")
|
||||
public AjaxResult editCaseApplication(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
|
||||
caseApplication.setUpdateBy(getUsername());
|
||||
return caseApplicationService.editCaseApplication(caseApplication);
|
||||
}
|
||||
// @Log(title = "修改立案数据", businessType = BusinessType.UPDATE)
|
||||
// @PostMapping("/editCaseApplication")
|
||||
// public AjaxResult editCaseApplication(@Validated @RequestBody CaseApplicationDTO caseApplication) {
|
||||
//
|
||||
// caseApplication.setUpdateBy(getUsername());
|
||||
// return caseApplicationService.editCaseApplication(caseApplication);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 修改立案数据自定义字段
|
||||
@@ -132,7 +142,7 @@ public class CaseApplicationController extends BaseController {
|
||||
if(StringUtils.isEmpty(batchCaseApplication.getBatchNumber())){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
return toAjax(caseApplicationService.submitCaseApplicationBatch(batchCaseApplication.getBatchNumber()));
|
||||
return caseApplicationService.submitCaseApplicationBatch(batchCaseApplication.getBatchNumber());
|
||||
}
|
||||
|
||||
|
||||
@@ -152,7 +162,7 @@ public class CaseApplicationController extends BaseController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询立案信息
|
||||
* 查询立案详情
|
||||
*/
|
||||
// @PreAuthorize("@ss.hasPermi('caseManagement:list:detail')")
|
||||
@PostMapping("/selectCaseApplication")
|
||||
@@ -161,6 +171,18 @@ public class CaseApplicationController extends BaseController {
|
||||
CaseApplication caseApplicationselect = caseApplicationService.selectCaseApplication(caseApplication);
|
||||
return success(caseApplicationselect);
|
||||
}
|
||||
/**
|
||||
* 视频会议中查询立案详情
|
||||
*/
|
||||
// @PreAuthorize("@ss.hasPermi('caseManagement:list:detail')")
|
||||
@GetMapping("/selectById")
|
||||
public AjaxResult selectById(@RequestParam(required = false) Long id ,@RequestParam(required = false) String caseNum) {
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(id);
|
||||
caseApplication.setCaseNum(caseNum);
|
||||
CaseApplication caseApplicationselect = caseApplicationService.selectCaseApplication(caseApplication);
|
||||
return success(caseApplicationselect);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询已签署裁决书URL
|
||||
@@ -271,7 +293,10 @@ public class CaseApplicationController extends BaseController {
|
||||
@Log(title = "组庭审核", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/pendTralCheck")
|
||||
public AjaxResult pendTralCheck(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
return toAjax(caseApplicationService.pendTralCheck(caseApplication));
|
||||
if(CollectionUtil.isEmpty(caseApplication.getArbitrators())){
|
||||
return error("请选择仲裁员");
|
||||
}
|
||||
return caseApplicationService.pendTralCheck(caseApplication);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -396,15 +421,6 @@ public class CaseApplicationController extends BaseController {
|
||||
return success(caseApplicationService.submitCaseApplicationCheck(batchCaseApplication.getIds(),batchCaseApplication.getAgreeOrNotCheck(),batchCaseApplication.getCaseCheckReject()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 确认缴费查询立案信息
|
||||
*/
|
||||
// @PreAuthorize("@ss.hasPermi('paymentManagement:list:detail')")
|
||||
@PostMapping("/selectCaseApplicationConfirm")
|
||||
public AjaxResult selectCaseApplicationConfirm(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
CaseApplication caseApplicationselect = caseApplicationService.selectCaseApplicationConfirm(caseApplication);
|
||||
return success(caseApplicationselect);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量提交立案审查
|
||||
@@ -415,18 +431,18 @@ public class CaseApplicationController extends BaseController {
|
||||
if(StringUtils.isEmpty(batchCaseApplication.getBatchNumber()) || batchCaseApplication.getAgreeOrNotCheck()==null){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
return success(caseApplicationService.submitCaseApplicationCheckBatch(batchCaseApplication.getBatchNumber(),batchCaseApplication.getAgreeOrNotCheck(),batchCaseApplication.getCaseCheckReject()));
|
||||
return caseApplicationService.submitCaseApplicationCheckBatch(batchCaseApplication.getBatchNumber(),batchCaseApplication.getAgreeOrNotCheck(),batchCaseApplication.getCaseCheckReject());
|
||||
}
|
||||
|
||||
/**
|
||||
* 下载案件压缩包
|
||||
*/
|
||||
@PostMapping("/downloadCaseZipFile")
|
||||
public AjaxResult downloadCaseZipFile(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
|
||||
CaseAttach caseAttach = caseApplicationService.downloadCaseZipFile(caseApplication);
|
||||
return success(caseAttach);
|
||||
}
|
||||
// /**
|
||||
// * 下载案件压缩包
|
||||
// */
|
||||
// @PostMapping("/downloadCaseZipFile")
|
||||
// public AjaxResult downloadCaseZipFile(@Validated @RequestBody CaseApplication caseApplication) {
|
||||
//
|
||||
// CaseAttach caseAttach = caseApplicationService.downloadCaseZipFile(caseApplication);
|
||||
// return success(caseAttach);
|
||||
// }
|
||||
|
||||
|
||||
|
||||
@@ -451,25 +467,18 @@ public class CaseApplicationController extends BaseController {
|
||||
return success(schemeUrl);
|
||||
}
|
||||
|
||||
/**
|
||||
* 生成庭审笔录
|
||||
* @param arbitrateRecord
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/creatTrialRecord")
|
||||
// @PreAuthorize("@ss.hasPermi('caseManagement:list:creatTrialRecord')")
|
||||
public AjaxResult creatTrialRecord(@Validated @RequestBody ArbitrateRecord arbitrateRecord){
|
||||
return caseApplicationService.creatTrialRecord(arbitrateRecord);
|
||||
}
|
||||
|
||||
/**
|
||||
* 记录庭审笔录
|
||||
* 确认会议结果
|
||||
* @param arbitrateRecord
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/creatTrialRecordnew")
|
||||
@PostMapping("/confirmMeetingResult")
|
||||
// @PreAuthorize("@ss.hasPermi('caseManagement:list:creatTrialRecord')")
|
||||
public AjaxResult creatTrialRecordnew(@Validated @RequestBody ArbitrateRecord arbitrateRecord){
|
||||
public AjaxResult creatTrialRecordnew( @RequestBody ArbitrateRecord arbitrateRecord){
|
||||
if(arbitrateRecord.getCaseAppliId()==null || arbitrateRecord.getAppliIsAbsen()==null || arbitrateRecord.getIsAbsence()==null){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
return caseApplicationService.creatTrialRecordnew(arbitrateRecord);
|
||||
}
|
||||
|
||||
@@ -487,17 +496,7 @@ public class CaseApplicationController extends BaseController {
|
||||
return AjaxResult.success(caseApplicationService.updateCaseLockStatus(caseApplication));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询短信发送记录
|
||||
* @param smsSendRecord
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/smsRecord")
|
||||
public TableDataInfo getSmsSendRecord(@RequestBody SmsSendRecord smsSendRecord){
|
||||
startPage();
|
||||
List<SmsSendRecord> list = caseApplicationService.getSmsSendRecord(smsSendRecord);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取userSign
|
||||
* @param userId
|
||||
@@ -557,12 +556,14 @@ public class CaseApplicationController extends BaseController {
|
||||
/**
|
||||
* 案件压缩包导入
|
||||
* @param file
|
||||
* @param applicantType 申请人类型,自然人-1,机构-2
|
||||
* @param resType 被申请人类型,自然人-1,机构-2
|
||||
* @return
|
||||
* @throws IOException
|
||||
*/
|
||||
@PostMapping("/uploadCaseZipFile")
|
||||
public AjaxResult uploadCaseZipFile(@RequestParam("file") MultipartFile file,@RequestParam("templateId") Long templateId) throws IOException {
|
||||
return caseApplicationService.uploadCaseZipFile(file,templateId);
|
||||
public AjaxResult uploadCaseZipFile(@RequestParam("file") MultipartFile file,@RequestParam("templateId") Long templateId,Integer applicantType,Integer resType) throws IOException {
|
||||
return caseApplicationService.uploadCaseZipFile(file,templateId,applicantType,resType);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -577,4 +578,17 @@ public class CaseApplicationController extends BaseController {
|
||||
}
|
||||
return caseApplicationService.updateCaseIdByAnnexId(caseAttach);
|
||||
}
|
||||
/**
|
||||
* 保存onlyOffice在线编辑的文件
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/saveOnlyOfficeFile")
|
||||
public AjaxResult saveOnlyOfficeFile( @RequestBody CaseAttach caseAttach) {
|
||||
if(caseAttach.getCaseAppliId()==null||StrUtil.isEmpty(caseAttach.getOnlyOfficeFileId())||StrUtil.isEmpty(caseAttach.getAnnexPath())){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
|
||||
return caseApplicationService.saveOnlyOfficeFile(caseAttach);
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ public class CaseApplicationLogController {
|
||||
if(vo.getCaseId()==null || vo.getVersion()==null){
|
||||
return AjaxResult.error("参数校验错误");
|
||||
}
|
||||
// todo 需确定
|
||||
|
||||
return caseApplicationLogService.revoke(vo);
|
||||
}
|
||||
|
||||
|
||||
+23
-22
@@ -6,6 +6,7 @@ import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseEvidenceDirectory;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseEvidenceDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseEvidenceVO;
|
||||
@@ -32,23 +33,23 @@ public class CaseEvidenceController extends BaseController {
|
||||
this.caseEvidenceService = caseEvidenceService;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据案件id查询案件详情
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/{id}")
|
||||
public AjaxResult getCaseDetailsById(@PathVariable Long id) {
|
||||
String username = this.getUsername();
|
||||
return caseEvidenceService.getCaseDetailsById(id, username);
|
||||
}
|
||||
// /**
|
||||
// * 根据案件id查询案件详情
|
||||
// *
|
||||
// * @param id
|
||||
// * @return
|
||||
// */
|
||||
// @GetMapping("/{id}")
|
||||
// public AjaxResult getCaseDetailsById(@PathVariable Long id) {
|
||||
// String username = this.getUsername();
|
||||
// return caseEvidenceService.getCaseDetailsById(id, username);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 案件证据上传
|
||||
*
|
||||
* @param file 附件
|
||||
* @param annexType 附件类型,立案申请书(1)、证据材料(2)、仲裁文书(3)、案件视频(4)、身份证件(5)
|
||||
* @param annexType 附件类型,立案申请书(1)、证据材料(2)、裁决书(3)、案件视频(4)、身份证件(5)
|
||||
* @param id 案件申请id
|
||||
* @return
|
||||
*/
|
||||
@@ -101,16 +102,16 @@ public class CaseEvidenceController extends BaseController {
|
||||
|
||||
/**
|
||||
* 删除附件
|
||||
* @param fileIds
|
||||
* @param caseAttach
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/deleteFile")
|
||||
public AjaxResult deleteFile( @RequestParam("fileIds") List<Integer> fileIds){
|
||||
public AjaxResult deleteFile(@RequestBody CaseAttach caseAttach){
|
||||
|
||||
if(CollectionUtil.isEmpty(fileIds)){
|
||||
if(CollectionUtil.isEmpty(caseAttach.getFileIds())){
|
||||
return error("附件id不能为空");
|
||||
}
|
||||
return toAjax(caseEvidenceService.deleteFile( fileIds));
|
||||
return success(caseEvidenceService.deleteFile( caseAttach.getFileIds()));
|
||||
}
|
||||
|
||||
|
||||
@@ -120,12 +121,12 @@ public class CaseEvidenceController extends BaseController {
|
||||
* @param caseStatus
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/all")
|
||||
public AjaxResult getCaseListAll(@RequestParam("caseStatus") Integer caseStatus) {
|
||||
|
||||
return success(caseEvidenceService.getCaseListAll(caseStatus));
|
||||
|
||||
}
|
||||
// @GetMapping("/all")
|
||||
// public AjaxResult getCaseListAll(@RequestParam("caseStatus") Integer caseStatus) {
|
||||
//
|
||||
// return success(caseEvidenceService.getCaseListAll(caseStatus));
|
||||
//
|
||||
// }
|
||||
|
||||
/**
|
||||
* 证据确认
|
||||
|
||||
+2
-2
@@ -75,10 +75,10 @@ public class CasePaymentController {
|
||||
// @PreAuthorize("@ss.hasPermi('paymentManagement:list:payconfirm')")
|
||||
@PutMapping("/confirm")
|
||||
public AjaxResult confirmPayment(@Validated @RequestBody BatchCaseApplication batchCaseApplication) {
|
||||
if(CollectionUtil.isEmpty(batchCaseApplication.getIds())){
|
||||
if(CollectionUtil.isEmpty(batchCaseApplication.getIds()) || batchCaseApplication.getAgreeOrNotCheck()==null){
|
||||
return AjaxResult.error("参数校验失败");
|
||||
}
|
||||
return paymentService.confirmPayment(batchCaseApplication.getIds());
|
||||
return paymentService.confirmPayment(batchCaseApplication);
|
||||
}
|
||||
/**
|
||||
* 缴费列表查询
|
||||
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import com.ruoyi.common.annotation.Anonymous;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.service.MsSignSealService;
|
||||
import com.ruoyi.wisdomarbitrate.utils.SignVerifyUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* @Classname MsSignSealController
|
||||
* @Description TODO
|
||||
* @Version 1.0.0
|
||||
* @Date 2024/5/10 15:07
|
||||
* @Created wangqiong
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/mssignSeal")
|
||||
public class MsSignSealController extends BaseController {
|
||||
@Autowired
|
||||
private MsSignSealService msSignSealService;
|
||||
/**
|
||||
* 签名用印回调
|
||||
*/
|
||||
@Anonymous
|
||||
@PostMapping("/signSeaalCaseApplicaCallback")
|
||||
public AjaxResult signSeaalCaseApplicaCallback() throws Exception {
|
||||
boolean checkResult= SignVerifyUtils.checkSignuter();
|
||||
if(checkResult){
|
||||
String reqbodystr =SignVerifyUtils.getRequestBody();
|
||||
return msSignSealService.signSeaalCaseApplicaCallback(reqbodystr);
|
||||
}else {
|
||||
return AjaxResult.error("error");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 印章审核回调
|
||||
*/
|
||||
@Anonymous
|
||||
@PostMapping("/sealCheckCallback")
|
||||
public AjaxResult sealCheckCallback() throws Exception {
|
||||
boolean checkResult= SignVerifyUtils.checkSignuter();
|
||||
if(checkResult){
|
||||
String reqbodystr =SignVerifyUtils.getRequestBody();
|
||||
return msSignSealService.sealCheckCallback(reqbodystr);
|
||||
}else {
|
||||
return AjaxResult.error("error");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
-48
@@ -1,48 +0,0 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.SendMailRecord;
|
||||
import com.ruoyi.wisdomarbitrate.service.ISendMailRecordService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/sendMailRecord")
|
||||
public class SendMailRecordController extends BaseController {
|
||||
@Autowired
|
||||
private ISendMailRecordService sendMailRecordService;
|
||||
|
||||
/**
|
||||
* 查询发送邮件记录列表
|
||||
*/
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(SendMailRecord sendMailRecord)
|
||||
{
|
||||
startPage();
|
||||
List<SendMailRecord> list = sendMailRecordService.selectSendMailRecordList(sendMailRecord);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
// /**
|
||||
// * 新增立案数据
|
||||
// */
|
||||
// @Log(title = "新增立案数据", businessType = BusinessType.INSERT)
|
||||
// @PostMapping("/addSendMailRecord")
|
||||
// public AjaxResult addSendMailRecord(@Validated @RequestBody SendMailRecord sendMailRecord)
|
||||
// {
|
||||
//
|
||||
// return toAjax(sendMailRecordService.addSendMailRecord(sendMailRecord));
|
||||
// }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
+137
-4
@@ -2,13 +2,23 @@ package com.ruoyi.web.controller.wisdomarbitrate;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.common.annotation.Anonymous;
|
||||
import com.ruoyi.common.config.RuoYiConfig;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||
import com.ruoyi.common.utils.file.FileUtils;
|
||||
import com.ruoyi.framework.config.ServerConfig;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.domain.IdentityAuthentication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ReservedConferenceVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.SendRoomNoMessageVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.WeChatUserVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseAttachMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import com.ruoyi.wisdomarbitrate.service.VideoService;
|
||||
import com.ruoyi.wisdomarbitrate.service.WeChatUserService;
|
||||
import com.tencentcloudapi.common.Credential;
|
||||
@@ -25,6 +35,9 @@ import org.springframework.web.multipart.MultipartFile;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.validation.Valid;
|
||||
import java.io.IOException;
|
||||
import java.util.Objects;
|
||||
|
||||
import static com.google.common.io.Files.getFileExtension;
|
||||
|
||||
/**
|
||||
* @author wangqiong
|
||||
@@ -36,7 +49,12 @@ import java.io.IOException;
|
||||
public class VideoController extends BaseController {
|
||||
@Autowired
|
||||
private VideoService videoService;
|
||||
|
||||
@Autowired
|
||||
private ServerConfig serverConfig;
|
||||
@Autowired
|
||||
private CaseAttachMapper caseAttachMapper;
|
||||
@Autowired
|
||||
private ICaseApplicationService caseApplicationService;
|
||||
/**
|
||||
* 从腾讯云下载文件到本地
|
||||
* @param
|
||||
@@ -114,9 +132,8 @@ public class VideoController extends BaseController {
|
||||
*/
|
||||
@Anonymous
|
||||
@GetMapping("secretaryRoleByUserId")
|
||||
public AjaxResult secretaryRoleByUserId( @RequestParam(value = "userId",required = true) Long userId) {
|
||||
|
||||
return videoService.secretaryRoleByUserId(userId);
|
||||
public AjaxResult secretaryRoleByUserId( @RequestParam(value = "userId",required = true) Long userId,@RequestParam(value = "caseId",required = true) Long caseId) {
|
||||
return videoService.secretaryRoleByUserId(userId,caseId);
|
||||
}
|
||||
/**
|
||||
* 根据html字符串转pdf并和案件关联
|
||||
@@ -144,6 +161,122 @@ public class VideoController extends BaseController {
|
||||
|
||||
return videoService.attachListByCaseId(caseAppliId,annexType);
|
||||
}
|
||||
/**
|
||||
* 根据案件id查询申请人/被申请人会议上传附件按钮权限
|
||||
* @param caseId
|
||||
* @return
|
||||
*/
|
||||
@Anonymous
|
||||
@GetMapping("selectRoleMenuByCaseId")
|
||||
public AjaxResult selectRoleMenuByCaseId( @RequestParam(value = "caseId",required = true) Long caseId) {
|
||||
|
||||
return videoService.selectRoleMenuByCaseId(caseId);
|
||||
}
|
||||
/**
|
||||
* 通用上传请求(单个)
|
||||
* param officeFlag: 是否上传到onlyoffice,0-否,1-是
|
||||
* param isMediaBook: 是否上仲裁书,1-是,其余为否
|
||||
*/
|
||||
@PostMapping("/upload")
|
||||
public AjaxResult uploadFile(@RequestParam("file") MultipartFile file, @RequestParam(value = "isMediaBook",required = false) Integer isMediaBook, @RequestParam("annexType") Integer annexType, @RequestParam(value = "officeFlag", required = false) Integer officeFlag,@RequestParam(value = "caseId",required = false) Long caseId) throws Exception
|
||||
{
|
||||
try
|
||||
{
|
||||
|
||||
// 上传文件路径
|
||||
String filePath = RuoYiConfig.getUploadPath();
|
||||
String name=file.getOriginalFilename();
|
||||
// 上传并返回新文件名称
|
||||
String fileName = FileUploadUtils.upload(filePath, file);
|
||||
String suffix = getFileExtension(fileName);
|
||||
if(StrUtil.isNotEmpty(suffix)&& suffix.contains("doc")){
|
||||
// 上传到onlyoffice
|
||||
officeFlag=1;
|
||||
}
|
||||
String url = serverConfig.getUrl() + fileName;
|
||||
if(officeFlag != null && officeFlag == 1){
|
||||
// officeFlag,fileName为annexPath
|
||||
JSONArray jsonArray = caseApplicationService.uploadOnlyOffice(fileName,caseId);
|
||||
if(jsonArray!=null && jsonArray.size() > 0) {
|
||||
// 先删除之前的裁决书附件
|
||||
if(Objects.equals(annexType,3) && caseId!=null) {
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(caseId, annexType);
|
||||
}
|
||||
CaseAttach caseAttach=null;
|
||||
for (Object obj : jsonArray) {
|
||||
JSONObject jsonObject = (JSONObject) obj;
|
||||
String path = jsonObject.get("filePath")!=null?jsonObject.getString("filePath"):"";
|
||||
path=path.replace("/home/ruoyi/uploadPath/","profile/");
|
||||
caseAttach = CaseAttach.builder()
|
||||
.caseAppliId(caseId)
|
||||
// .annexName(jsonObject.get("fileName")!=null?jsonObject.getString("fileName"):"")
|
||||
.annexName(name)
|
||||
.annexType(annexType)
|
||||
.onlyOfficeFileId(jsonObject.getString("fileId"))
|
||||
.annexPath(path)
|
||||
.build();
|
||||
// if(jsonObject.get("filePath")!=null){
|
||||
// String officePath = jsonObject.getString("filePath");
|
||||
// String replace = officePath.replace("/home/ruoyi/uploadPath/", "/profile/");
|
||||
// caseAttach.setAnnexPath(replace);
|
||||
//
|
||||
// }
|
||||
caseAttachMapper.save(caseAttach);
|
||||
}
|
||||
if(caseAttach==null){
|
||||
return AjaxResult.error("上传失败");
|
||||
}
|
||||
AjaxResult ajax = AjaxResult.success();
|
||||
ajax.put("annexId", caseAttach.getAnnexId());
|
||||
ajax.put("annexType", annexType);
|
||||
// ajax.put("url", url);
|
||||
ajax.put("fileName", name);
|
||||
ajax.put("newFileName", FileUtils.getName(fileName));
|
||||
ajax.put("originalFilename", file.getOriginalFilename());
|
||||
return ajax;
|
||||
}else {
|
||||
return AjaxResult.error("上传失败");
|
||||
}
|
||||
}else {
|
||||
// 如果是调解书并且是pdf,则删除之前的在新增
|
||||
if(annexType!=null && annexType.equals(3) ){
|
||||
// if(StrUtil.isNotEmpty(suffix)&&!suffix.equals("pdf")){
|
||||
// return AjaxResult.error("请上传pdf格式文件");
|
||||
// }
|
||||
// annexType=AnnexTypeEnum.MEDIATE_BOOK_PDF.getCode();
|
||||
// 先删除之前的附件
|
||||
if(caseId!=null) {
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(caseId, annexType);
|
||||
}
|
||||
}
|
||||
Long annexId = saveCaseAttach(annexType, name, file.getOriginalFilename(), caseId);
|
||||
|
||||
AjaxResult ajax = AjaxResult.success();
|
||||
ajax.put("annexId", annexId);
|
||||
ajax.put("annexType", annexType);
|
||||
ajax.put("url", url);
|
||||
ajax.put("fileName", name);
|
||||
ajax.put("newFileName", FileUtils.getName(fileName));
|
||||
ajax.put("originalFilename", file.getOriginalFilename());
|
||||
return ajax;
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return AjaxResult.error(e.getMessage());
|
||||
}
|
||||
}
|
||||
private Long saveCaseAttach(Integer annexType, String path, String originalFilename,Long caseId) {
|
||||
CaseAttach caseAttach = CaseAttach.builder()
|
||||
.annexName(originalFilename)
|
||||
.caseAppliId(caseId)
|
||||
.annexPath(path)
|
||||
.annexType(annexType)
|
||||
.userId(SecurityUtils.getUserId())
|
||||
.userName(SecurityUtils.getUsername())
|
||||
.build();
|
||||
|
||||
caseAttachMapper.save(caseAttach);
|
||||
return caseAttach.getAnnexId();
|
||||
}
|
||||
}
|
||||
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate.sendrecord;
|
||||
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.sendrecord.SendMailRecord;
|
||||
import com.ruoyi.wisdomarbitrate.service.sendrecord.ISendMailRecordService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/sendMailRecord")
|
||||
public class SendMailRecordController extends BaseController {
|
||||
@Autowired
|
||||
private ISendMailRecordService sendMailRecordService;
|
||||
|
||||
/**
|
||||
* 查询发送邮件记录列表
|
||||
*/
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(SendMailRecord sendMailRecord) {
|
||||
startPage();
|
||||
List<SendMailRecord> list = sendMailRecordService.selectSendMailRecordList(sendMailRecord);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑邮件记录
|
||||
*/
|
||||
@PostMapping("/update")
|
||||
public AjaxResult update(@RequestBody SendMailRecord sendMailRecord) {
|
||||
return sendMailRecordService.updateSendMailRecord(sendMailRecord);
|
||||
}
|
||||
|
||||
/**
|
||||
* 重新发送邮件记录
|
||||
*/
|
||||
@PostMapping("/reSendMailRecord")
|
||||
public AjaxResult reSendMailRecord(@RequestBody SendMailRecord sendMailRecord) {
|
||||
Boolean aBoolean = sendMailRecordService.reSendMailRecord(sendMailRecord);
|
||||
if (aBoolean) {
|
||||
return AjaxResult.success("发送成功");
|
||||
} else {
|
||||
return AjaxResult.error("发送失败");
|
||||
}
|
||||
}
|
||||
}
|
||||
+143
@@ -0,0 +1,143 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate.sendrecord;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import com.ruoyi.common.annotation.Anonymous;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.framework.web.service.TokenService;
|
||||
|
||||
import com.ruoyi.system.mapper.SysUserMapper;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.sendrecord.SmsSendRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsSendRecordParam;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsTemplateParam;
|
||||
import com.ruoyi.wisdomarbitrate.domain.shortmessage.MeetingInfo;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.shortmessage.MeetingInfoVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.shortmessage.ReSendMessageVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sendrecord.SmsRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.shortmessage.MeetingInfoMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sms.MsSmsSendHistoryRecordParamMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sms.MsSmsSendRecordParamMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.shortmessage.ShortMessageService;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import tk.mybatis.mapper.entity.Example;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/shortMessage")
|
||||
public class ShortMessageController extends BaseController {
|
||||
@Autowired
|
||||
private SmsRecordMapper smsRecordMapper;
|
||||
@Autowired
|
||||
private ShortMessageService shortMessageService;
|
||||
@Autowired
|
||||
MsSmsSendRecordParamMapper recordParamMapper;
|
||||
@Autowired
|
||||
MsSmsSendHistoryRecordParamMapper historyRecordParamMapper;
|
||||
|
||||
/**
|
||||
* 查询短信发送记录
|
||||
*
|
||||
* @param smsSendRecord
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/recordList")
|
||||
public TableDataInfo smsSendRecordList(SmsSendRecord smsSendRecord) {
|
||||
startPage();
|
||||
List<SmsSendRecord> list = shortMessageService.smsSendRecordList(smsSendRecord);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
@Anonymous
|
||||
@PostMapping("/updateSendContent")
|
||||
public AjaxResult update(@RequestBody SmsSendRecord smsSendRecord) {
|
||||
if (smsSendRecord == null || smsSendRecord.getId() == null || CollectionUtil.isEmpty(smsSendRecord.getTemplateParams())) {
|
||||
return AjaxResult.error("参数校验失败");
|
||||
}
|
||||
// 查询当前版本记录
|
||||
SmsSendRecord oldSendRecord = smsRecordMapper.selectById(smsSendRecord.getId());
|
||||
smsSendRecord.setUpdateTime(new Date());
|
||||
// 更新短信内容,先删除短信记录参数表
|
||||
Example recordParamExam = new Example(MsSmsSendRecordParam.class);
|
||||
recordParamExam.createCriteria().andEqualTo("smsRecordId", smsSendRecord.getId());
|
||||
recordParamMapper.deleteByExample(recordParamExam);
|
||||
// 新增短信记录参数表
|
||||
List<MsSmsSendRecordParam> recordParams = new ArrayList<>();
|
||||
for (MsSmsTemplateParam templateParam : smsSendRecord.getTemplateParams()) {
|
||||
MsSmsSendRecordParam recordParam = new MsSmsSendRecordParam();
|
||||
recordParam.setSmsRecordId(smsSendRecord.getId());
|
||||
recordParam.setParamValue(templateParam.getParamValue());
|
||||
recordParams.add(recordParam);
|
||||
}
|
||||
recordParamMapper.batchInsert(recordParams);
|
||||
shortMessageService.insertShortMessageHistoryRecord(oldSendRecord, recordParams);
|
||||
return AjaxResult.success();
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 重新发送短信
|
||||
*/
|
||||
@Anonymous
|
||||
@PostMapping("/reSendShortMessage")
|
||||
public AjaxResult reSendShortMessage(@RequestBody ReSendMessageVO reSendMessageVO) {
|
||||
if (reSendMessageVO != null) {
|
||||
AjaxResult result = shortMessageService.reSendShortMessage(reSendMessageVO);
|
||||
return result;
|
||||
}
|
||||
return AjaxResult.error("参数缺失");
|
||||
}
|
||||
|
||||
/**
|
||||
* 短信回调
|
||||
* @param body
|
||||
* @return
|
||||
*/
|
||||
@Anonymous
|
||||
@PostMapping("/smsCallBack")
|
||||
public AjaxResult smsCallBack(@RequestBody String body) {
|
||||
if(body != null){
|
||||
return shortMessageService.smsCallBack(body);
|
||||
}
|
||||
return AjaxResult.error("参数缺失");
|
||||
}
|
||||
|
||||
@Autowired
|
||||
MeetingInfoMapper meetingInfoMapper;
|
||||
@Autowired
|
||||
SysUserMapper sysUserMapper;
|
||||
@Autowired
|
||||
private TokenService tokenService;
|
||||
|
||||
/**
|
||||
* 查询UID好的密钥
|
||||
*/
|
||||
// @Anonymous
|
||||
// @GetMapping("/getMeetingInfo")
|
||||
// public Object getEncryptInfoByUid(@RequestParam(name = "authId", required = true) String authId) {
|
||||
// MeetingInfoVO result = new MeetingInfoVO();
|
||||
// if (authId != null) {
|
||||
// MeetingInfo meetingInfo = meetingInfoMapper.selectByPrimaryKey(authId);
|
||||
// if (meetingInfo != null && meetingInfo.getUserId() != null) {
|
||||
// BeanUtils.copyProperties(meetingInfo, result);
|
||||
// SysUser sysUser = sysUserMapper.selectUserById(meetingInfo.getUserId());
|
||||
// LoginUser loginUser = new LoginUser();
|
||||
// loginUser.setUserId(sysUser.getUserId());
|
||||
// loginUser.setUser(sysUser);
|
||||
// String token = tokenService.createVideoToken(loginUser, 120);
|
||||
//// String createToken = createToken(claims);
|
||||
// result.setToken(token);
|
||||
// }
|
||||
// return result;
|
||||
// }
|
||||
// return AjaxResult.error("查询失败");
|
||||
// }
|
||||
}
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
package com.ruoyi.web.controller.wisdomarbitrate.sms;
|
||||
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsTemplate;
|
||||
import com.ruoyi.wisdomarbitrate.service.sms.SMSTemplateService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 短信模板控制器
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/smsTemplate")
|
||||
public class SMSTemplateController extends BaseController {
|
||||
@Autowired
|
||||
private SMSTemplateService templateService;
|
||||
|
||||
/**
|
||||
* 查询
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/page")
|
||||
public TableDataInfo page( ){
|
||||
startPage();
|
||||
List<MsSmsTemplate> list = templateService.page();
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
* 新增或者修改
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/insert")
|
||||
public AjaxResult insert(@RequestBody MsSmsTemplate template){
|
||||
return templateService.insert(template);
|
||||
}
|
||||
/**
|
||||
* 删除
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/delete")
|
||||
public AjaxResult delete(@RequestBody MsSmsTemplate template){
|
||||
if(template.getId()==null){
|
||||
return AjaxResult.warn("id不能为空");
|
||||
}
|
||||
return templateService.delete(template.getId());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -6,7 +6,8 @@ spring:
|
||||
druid:
|
||||
# 主库数据源
|
||||
master:
|
||||
url: jdbc:mysql://121.40.189.20:3306/test_smart_arbitration?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=Asia/Shanghai&useSSL=false
|
||||
url: jdbc:mysql://121.40.189.20:3306/test_smart_arbitration?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&useSSL=true&serverTimezone=Asia/Shanghai&useSSL=false
|
||||
# url: jdbc:mysql://121.40.189.20:3306/smart_arbitration?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&useSSL=true&serverTimezone=Asia/Shanghai&useSSL=false
|
||||
username: root
|
||||
password: YMzc157#
|
||||
# 从库数据源
|
||||
|
||||
@@ -17,7 +17,7 @@ ruoyi:
|
||||
|
||||
# 开发环境配置
|
||||
server:
|
||||
# 服务器的HTTP端口,默认为8080
|
||||
# 服务器的HTTP端口,默认为8001,正式9001
|
||||
port: 8001
|
||||
servlet:
|
||||
# 应用的访问路径
|
||||
@@ -58,9 +58,9 @@ spring:
|
||||
servlet:
|
||||
multipart:
|
||||
# 单个文件大小
|
||||
max-file-size: 50MB
|
||||
max-file-size: 1000MB
|
||||
# 设置总上传的文件大小
|
||||
max-request-size: 500MB
|
||||
max-request-size: 10000MB
|
||||
# 服务模块
|
||||
devtools:
|
||||
restart:
|
||||
@@ -72,8 +72,8 @@ spring:
|
||||
host: 121.40.189.20
|
||||
# 端口,默认为6379
|
||||
port: 6389
|
||||
# 数据库索引
|
||||
database: 0
|
||||
# 数据库索引,2-正式,3-测试
|
||||
database: 3
|
||||
# 密码
|
||||
password:
|
||||
# 连接超时时间
|
||||
@@ -121,7 +121,7 @@ token:
|
||||
# 令牌密钥
|
||||
secret: abcdefghijklmnopqrstuvwxyz
|
||||
# 令牌有效期(默认30分钟)
|
||||
expireTime: 30
|
||||
expireTime: 1200
|
||||
|
||||
# MyBatis配置
|
||||
mybatis:
|
||||
@@ -183,6 +183,14 @@ imConfig:
|
||||
secretId: AKID3xfHgroY4MQHvLXUXMwIQL1UjmbBX1Tv
|
||||
# 腾讯云密钥
|
||||
secretKey: INDrIXcT8YmomZBcsy0oNirnU0LTN4X7
|
||||
# onlyOffice系统url配置
|
||||
onlyOfficeConfig:
|
||||
# url: http://172.16.0.254:9090/files/upload
|
||||
url: http://121.40.189.20:9090/files/upload
|
||||
# 调解机构代码配置
|
||||
organizeConfig:
|
||||
# creditCode
|
||||
creditCode: 910000058386410044
|
||||
#jodconverter:
|
||||
# local:
|
||||
# host: 121.40.189.20
|
||||
|
||||
@@ -42,4 +42,16 @@ public class CacheConstants
|
||||
*/
|
||||
public static final String PWD_ERR_CNT_KEY = "pwd_err_cnt:";
|
||||
public static final String WE_CHAT_SMS_VERIFY_CODE_KEY="we_chat_sms_verify_code:";
|
||||
/**
|
||||
* 所有用户 redis key
|
||||
*/
|
||||
public static final String USER_KEY = "user_key:";
|
||||
/**
|
||||
* 用户邮箱 redis key
|
||||
*/
|
||||
// public static final String USER_EMAIL_KEY = "user_email_key:";
|
||||
/**
|
||||
* 角色 redis key
|
||||
*/
|
||||
public static final String ROLE_KEY = "role_key:";
|
||||
}
|
||||
|
||||
+26
-20
@@ -4,50 +4,56 @@ package com.ruoyi.common.constant;
|
||||
*
|
||||
*/
|
||||
public class CaseApplicationConstants {
|
||||
/** 立案申请 */
|
||||
/** 申请人/代理人,立案申请 */
|
||||
public static final int CASE_APPLICATION = 0;
|
||||
/** 待立案审查 */
|
||||
/**
|
||||
* 案件新增
|
||||
*/
|
||||
public static final int CASE_INSERT = -2;
|
||||
/** 申请人/代理人,案件修改 */
|
||||
public static final int CASE_EDIT = -1;
|
||||
/** 顾问,待立案审查 */
|
||||
public static final int CASE_CHECK = 1;
|
||||
/** 待缴费 */
|
||||
/** 申请人、代理人,待缴费 */
|
||||
public static final int PENDING_PAYMENT = 2;
|
||||
/** 待缴费确认 */
|
||||
/** 财务,待缴费确认 */
|
||||
public static final int PENDING_PAYMENT_CONFIRM = 3;
|
||||
/** 待案件质证 */
|
||||
/** 被申,待案件质证 */
|
||||
public static final int CASE_CROSSEXAMI = 4;
|
||||
|
||||
/** 待组庭 */
|
||||
/** 待定,待组庭 */
|
||||
public static final int PENDING_TRIAL = 26;
|
||||
/** 待组庭审核 */
|
||||
/** 顾问,待组庭审核 */
|
||||
public static final int CONFIRMDED_PENDING_TRIAL_SUBMMIT = 5;
|
||||
/** 待组庭确定 */
|
||||
/** 部门长,待组庭确定 */
|
||||
public static final int CONFIRMDED_PENDING_TRIAL = 6;
|
||||
|
||||
/** 待审核仲裁方式 */
|
||||
/** 仲裁员,待审核仲裁方式 */
|
||||
public static final int CHECK_ARBITRATION_METHOD = 7;
|
||||
/** 待开庭审理 */
|
||||
/** 申请人,被申,顾问,仲裁员,待开庭审理 */
|
||||
public static final int PENDING_OPENCOURT_HEAR = 8;
|
||||
/** 待书面审理 */
|
||||
/** 申请人,被申,顾问,仲裁员,待书面审理 */
|
||||
public static final int PENDING_WRIITEN_HEAR = 9;
|
||||
/** 待生成仲裁文书 */
|
||||
/** 待生成裁决书 */
|
||||
public static final int GENERATED_ARBITRATION = 10;
|
||||
/**待秘书核验仲裁文书*/
|
||||
/**顾问,待秘书核验裁决书*/
|
||||
public static final int VERPRIF_ARBITRATION = 11;
|
||||
/**待部门长审核仲裁文书*/
|
||||
/**部门长,待部门长审核裁决书*/
|
||||
public static final int CHECK_ARBITRATION = 12;
|
||||
/**待仲裁文书签名*/
|
||||
/**仲裁员,待裁决书签名*/
|
||||
public static final int SIGN_ARBITRATION = 13;
|
||||
/** 待仲裁文书用印 */
|
||||
/** 顾问,待裁决书用印 */
|
||||
public static final int ARBITRATED_SEAL = 14;
|
||||
/** 待仲裁文书送达 */
|
||||
/** 顾问,待裁决书送达 */
|
||||
public static final int ARBITRATION_DELIVERY = 15;
|
||||
/** 待案件归档*/
|
||||
/** 顾问,待案件归档*/
|
||||
public static final int CASE_FILING = 16;
|
||||
/** 已归档*/
|
||||
public static final int CASE_ARCHIVED = 17;
|
||||
|
||||
/** 待修改开庭时间*/
|
||||
/** 顾问,待修改开庭时间*/
|
||||
public static final int MODIFY_HEARDATE = 31;
|
||||
/**待仲裁员审核仲裁文书*/
|
||||
/**仲裁员,待仲裁员审核裁决书*/
|
||||
public static final int HEAD_CHECK_ARBITRATION = 18;
|
||||
|
||||
|
||||
|
||||
@@ -154,4 +154,11 @@ public class Constants
|
||||
*/
|
||||
public static final String[] JOB_ERROR_STR = { "java.net.URL", "javax.naming.InitialContext", "org.yaml.snakeyaml",
|
||||
"org.springframework", "org.apache", "com.ruoyi.common.utils.file", "com.ruoyi.common.config" };
|
||||
// 中文逗号分隔符
|
||||
public static final String CN_SPLIT_COMMA = ",";
|
||||
/**
|
||||
* 会议主键Id
|
||||
*/
|
||||
public static final String MEETING_KEY = "meeting_key";
|
||||
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package com.ruoyi.common.core.controller;
|
||||
|
||||
import java.beans.PropertyEditorSupport;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import org.slf4j.Logger;
|
||||
@@ -82,6 +83,9 @@ public class BaseController
|
||||
@SuppressWarnings({ "rawtypes", "unchecked" })
|
||||
protected TableDataInfo getDataTable(List<?> list)
|
||||
{
|
||||
if(list == null){
|
||||
list=new ArrayList<>();
|
||||
}
|
||||
TableDataInfo rspData = new TableDataInfo();
|
||||
rspData.setCode(HttpStatus.SUCCESS);
|
||||
rspData.setMsg("查询成功");
|
||||
|
||||
@@ -54,6 +54,68 @@ public class SysDept extends BaseEntity
|
||||
|
||||
/** 父部门名称 */
|
||||
private String parentName;
|
||||
/**
|
||||
* 代码(统一社会信用代码或者身份证号)
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 法定代表人
|
||||
*/
|
||||
private String compLegalPerson;
|
||||
/**
|
||||
* 住所
|
||||
*/
|
||||
private String home;
|
||||
/**
|
||||
* 联系地址
|
||||
*/
|
||||
private String address;
|
||||
/**
|
||||
*
|
||||
* 国籍,0-国内,1-国外
|
||||
*/
|
||||
private Integer nationality;
|
||||
|
||||
public String getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(String code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getCompLegalPerson() {
|
||||
return compLegalPerson;
|
||||
}
|
||||
|
||||
public void setCompLegalPerson(String compLegalPerson) {
|
||||
this.compLegalPerson = compLegalPerson;
|
||||
}
|
||||
|
||||
public String getHome() {
|
||||
return home;
|
||||
}
|
||||
|
||||
public void setHome(String home) {
|
||||
this.home = home;
|
||||
}
|
||||
|
||||
public String getAddress() {
|
||||
return address;
|
||||
}
|
||||
|
||||
public void setAddress(String address) {
|
||||
this.address = address;
|
||||
}
|
||||
|
||||
public Integer getNationality() {
|
||||
return nationality;
|
||||
}
|
||||
|
||||
public void setNationality(Integer nationality) {
|
||||
this.nationality = nationality;
|
||||
}
|
||||
|
||||
public Integer getDeptType() {
|
||||
return deptType;
|
||||
|
||||
@@ -49,6 +49,23 @@ public class SysUser extends BaseEntity
|
||||
public void setNickNameAndNum(String nickNameAndNum) {
|
||||
this.nickNameAndNum = nickNameAndNum;
|
||||
}
|
||||
/** 身份类别,0-身份证,1-护照,默认0 */
|
||||
private Integer idType;
|
||||
/** 国籍,0-国内,1-国外,默认0 */
|
||||
|
||||
private Integer nationality;
|
||||
/**
|
||||
* 生日
|
||||
*/
|
||||
private Date birth;
|
||||
/**
|
||||
* 住所
|
||||
*/
|
||||
private String home;
|
||||
/**
|
||||
* 联系地址
|
||||
*/
|
||||
private String address;
|
||||
|
||||
/** 用户身份证号 */
|
||||
@Excel(name = "身份证号")
|
||||
@@ -105,12 +122,64 @@ public class SysUser extends BaseEntity
|
||||
|
||||
/** 角色ID */
|
||||
private Long roleId;
|
||||
/**
|
||||
* 职位
|
||||
*/
|
||||
private String position;
|
||||
|
||||
public String getPosition() {
|
||||
return position;
|
||||
}
|
||||
|
||||
public void setPosition(String position) {
|
||||
this.position = position;
|
||||
}
|
||||
|
||||
public SysUser()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public Integer getIdType() {
|
||||
return idType;
|
||||
}
|
||||
|
||||
public void setIdType(Integer idType) {
|
||||
this.idType = idType;
|
||||
}
|
||||
|
||||
public Integer getNationality() {
|
||||
return nationality;
|
||||
}
|
||||
|
||||
public void setNationality(Integer nationality) {
|
||||
this.nationality = nationality;
|
||||
}
|
||||
|
||||
public Date getBirth() {
|
||||
return birth;
|
||||
}
|
||||
|
||||
public void setBirth(Date birth) {
|
||||
this.birth = birth;
|
||||
}
|
||||
|
||||
public String getHome() {
|
||||
return home;
|
||||
}
|
||||
|
||||
public void setHome(String home) {
|
||||
this.home = home;
|
||||
}
|
||||
|
||||
public String getAddress() {
|
||||
return address;
|
||||
}
|
||||
|
||||
public void setAddress(String address) {
|
||||
this.address = address;
|
||||
}
|
||||
|
||||
public SysUser(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
package com.ruoyi.common.enums;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @author wangqiong
|
||||
* @description 短信状态枚举
|
||||
* @date 2023-11-17 14:05
|
||||
*/
|
||||
public enum SMSStatusEnum
|
||||
{
|
||||
SUCCESS(1, "成功"),
|
||||
SENDING(2, "发送中"),
|
||||
FAIL(3, "失败"),
|
||||
|
||||
;
|
||||
|
||||
private final Integer code;
|
||||
private final String text;
|
||||
|
||||
SMSStatusEnum(Integer code, String text)
|
||||
{
|
||||
this.code = code;
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
public Integer getCode()
|
||||
{
|
||||
return code;
|
||||
}
|
||||
|
||||
public String getText()
|
||||
{
|
||||
return text;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据code获取text
|
||||
* @param codeNo
|
||||
* @return
|
||||
*/
|
||||
public static String getTextByCode(Integer codeNo){
|
||||
for (SMSStatusEnum value : SMSStatusEnum.values()) {
|
||||
if (value.getCode().equals(codeNo)){
|
||||
return value.getText();
|
||||
}
|
||||
}
|
||||
return codeNo.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据text获取code
|
||||
* @param textStr
|
||||
* @return
|
||||
*/
|
||||
public static String getCodeByText(String textStr){
|
||||
for (SMSStatusEnum value : SMSStatusEnum.values()) {
|
||||
if (value.getText().equals(textStr)){
|
||||
return value.getText();
|
||||
}
|
||||
}
|
||||
return textStr;
|
||||
}
|
||||
}
|
||||
@@ -2,10 +2,12 @@ package com.ruoyi.common.utils;
|
||||
|
||||
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.common.utils.uuid.UUID;
|
||||
import lombok.Data;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.mail.MailException;
|
||||
import org.springframework.mail.SimpleMailMessage;
|
||||
|
||||
import org.springframework.mail.javamail.JavaMailSender;
|
||||
@@ -49,12 +51,12 @@ public class EmailOutUtil {
|
||||
// private static String fromOut;
|
||||
@Value("${spring.mail.host}")
|
||||
private String hostOut;
|
||||
// @Value("${spring.mail.username}")
|
||||
// private String usernameOut;
|
||||
private String usernameOut="wq18792927508@163.com";
|
||||
// @Value("${spring.mail.password}")
|
||||
// private String passwordOut;
|
||||
private String passwordOut= "WDFHKSEMCKVRELEA";
|
||||
@Value("${spring.mail.username}")
|
||||
private String usernameOut;
|
||||
|
||||
@Value("${spring.mail.password}")
|
||||
private String passwordOut;
|
||||
|
||||
@Value("${spring.mail.port}")
|
||||
private Integer portOut;
|
||||
|
||||
@@ -76,18 +78,29 @@ public class EmailOutUtil {
|
||||
* @param subject 邮件主题
|
||||
* @param content 邮件内容(发送内容)
|
||||
*/
|
||||
public void sendMessage(String to, String subject, String content, String from, JavaMailSender mailSender) {
|
||||
// 创建一个邮件对象
|
||||
SimpleMailMessage msg = new SimpleMailMessage();
|
||||
msg.setFrom(from);
|
||||
msg.setTo(to);
|
||||
// 设置邮件主题
|
||||
msg.setSubject(subject);
|
||||
// 设置邮件内容
|
||||
msg.setText(content);
|
||||
// 发送邮件
|
||||
mailSender.send(msg);
|
||||
////System.out.println("发送成功:" + from + ":to:" + to);
|
||||
public Boolean sendMessage(String to, String subject, String content, String from, JavaMailSender mailSender) {
|
||||
try {
|
||||
if(mailSender==null){
|
||||
mailSender= rebuildMailSender();
|
||||
}
|
||||
// 创建一个邮件对象
|
||||
SimpleMailMessage msg = new SimpleMailMessage();
|
||||
if(StrUtil.isEmpty(from)){
|
||||
msg.setFrom(usernameOut);
|
||||
}else {
|
||||
msg.setFrom(from);
|
||||
}
|
||||
msg.setTo(to);
|
||||
// 设置邮件主题
|
||||
msg.setSubject(subject);
|
||||
// 设置邮件内容
|
||||
msg.setText(content);
|
||||
// 发送邮件
|
||||
mailSender.send(msg);
|
||||
} catch (MailException e) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -95,14 +108,14 @@ public class EmailOutUtil {
|
||||
* @param message 邮件内容
|
||||
* @param subject 邮件主题
|
||||
* @param fileList 邮件附件
|
||||
* @param fileNameMap 附件名称map,附件路径-附件名称
|
||||
*/
|
||||
public Boolean sendEmil(String to, String message, String subject, List<File> fileList, File file) {
|
||||
public Boolean sendEmil(String to, String message, String subject, List<File> fileList, File file,Map<String,String> fileNameMap) {
|
||||
try {
|
||||
String messageContent = "<html><body><p style=\"font-family: Arial, sans-serif; font-size: 18px;\">"+message+"。</p></body></html>";
|
||||
MimeBodyPart messageBodyPart = new MimeBodyPart();
|
||||
messageBodyPart.setContent(messageContent, "text/html;charset=utf-8");
|
||||
messageBodyPart.setContentID(UUID.randomUUID().toString());
|
||||
Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
|
||||
final String SSL_FACTORY = "javax.net.ssl.SSLSocketFactory";
|
||||
//设置邮件会话参数
|
||||
Properties props = new Properties();
|
||||
@@ -154,7 +167,10 @@ public class EmailOutUtil {
|
||||
for (File tempfile : fileList) {
|
||||
MimeBodyPart attachmentPart = new MimeBodyPart();
|
||||
attachmentPart.attachFile(tempfile);
|
||||
attachmentPart.setFileName(MimeUtility.encodeText(tempfile.getName()));
|
||||
// 设置附件名称
|
||||
if(fileNameMap!=null && fileNameMap.containsKey(tempfile.getPath())) {
|
||||
attachmentPart.setFileName(MimeUtility.encodeText(fileNameMap.get(tempfile.getPath())));
|
||||
}
|
||||
multipart.addBodyPart(attachmentPart);
|
||||
}
|
||||
msg.setContent(multipart);
|
||||
@@ -273,40 +289,40 @@ public class EmailOutUtil {
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
public void buildReceiveConnect() throws Exception {
|
||||
public void buildReceiveConnect() throws Exception {
|
||||
|
||||
//POP3主机名
|
||||
String host = "pop3.163.com";
|
||||
//设置传输协议
|
||||
String protocol = "pop3";
|
||||
//用户账号
|
||||
String username = "wq18792927508@163.com";
|
||||
//密码或者授权码
|
||||
String password = "WDFHKSEMCKVRELEA";
|
||||
/*
|
||||
* 获取Session
|
||||
*/
|
||||
Properties props = new Properties();
|
||||
//协议
|
||||
props.setProperty("mail.store.protocol", protocol);
|
||||
//POP3主机名
|
||||
props.setProperty("mail.pop3.host", host);
|
||||
props.setProperty("mail.smtp.auth", "true");
|
||||
props.setProperty("mail.pop3.default-encoding", "UTF-8");
|
||||
Session session = Session.getDefaultInstance(props, new Authenticator() {
|
||||
@Override
|
||||
protected PasswordAuthentication getPasswordAuthentication() {
|
||||
return new PasswordAuthentication(usernameOut, passwordOut);
|
||||
}
|
||||
});
|
||||
URLName urlName = new URLName(protocol, host, 110, null, username, password);
|
||||
Store store = session.getStore(urlName);
|
||||
store.connect(username, password);
|
||||
//POP3主机名
|
||||
String host = "pop3.163.com";
|
||||
//设置传输协议
|
||||
String protocol = "pop3";
|
||||
//用户账号
|
||||
String username = "wq18792927508@163.com";
|
||||
//密码或者授权码
|
||||
String password = "WDFHKSEMCKVRELEA";
|
||||
/*
|
||||
* 获取Session
|
||||
*/
|
||||
Properties props = new Properties();
|
||||
//协议
|
||||
props.setProperty("mail.store.protocol", protocol);
|
||||
//POP3主机名
|
||||
props.setProperty("mail.pop3.host", host);
|
||||
props.setProperty("mail.smtp.auth", "true");
|
||||
props.setProperty("mail.pop3.default-encoding", "UTF-8");
|
||||
Session session = Session.getDefaultInstance(props, new Authenticator() {
|
||||
@Override
|
||||
protected PasswordAuthentication getPasswordAuthentication() {
|
||||
return new PasswordAuthentication(usernameOut, passwordOut);
|
||||
}
|
||||
});
|
||||
URLName urlName = new URLName(protocol, host, 110, null, username, password);
|
||||
Store store = session.getStore(urlName);
|
||||
store.connect(username, password);
|
||||
|
||||
|
||||
Folder folder = store.getFolder("INBOX");
|
||||
Folder folder = store.getFolder("INBOX");
|
||||
|
||||
folder.open(Folder.READ_ONLY);
|
||||
folder.open(Folder.READ_ONLY);
|
||||
|
||||
}
|
||||
/**
|
||||
@@ -350,14 +366,14 @@ public void buildReceiveConnect() throws Exception {
|
||||
Folder folder = store.getFolder("INBOX");
|
||||
folder.open(Folder.READ_ONLY);
|
||||
SearchTerm orTerm = new SubjectTerm("退信");
|
||||
// Message[] messages = folder.search(orTerm);
|
||||
// Message[] messages = folder.search(orTerm);
|
||||
Date endTime= new Date();
|
||||
long oneDayMillis=24*60*60*1000L;
|
||||
Date startTime=new Date(endTime.getTime()-oneDayMillis);
|
||||
// SearchTerm comparisonTermGe = new SentDateTerm(ComparisonTerm.GE, startTime);
|
||||
// SearchTerm comparisonTermLe = new SentDateTerm(ComparisonTerm.LE, endTime);
|
||||
// SearchTerm comparisonAndTerm = new AndTerm(comparisonTermGe, comparisonTermLe);
|
||||
// SearchTerm searchTerm = new AndTerm(comparisonAndTerm, orTerm);
|
||||
// SearchTerm comparisonTermGe = new SentDateTerm(ComparisonTerm.GE, startTime);
|
||||
// SearchTerm comparisonTermLe = new SentDateTerm(ComparisonTerm.LE, endTime);
|
||||
// SearchTerm comparisonAndTerm = new AndTerm(comparisonTermGe, comparisonTermLe);
|
||||
// SearchTerm searchTerm = new AndTerm(comparisonAndTerm, orTerm);
|
||||
Message[] messages = folder.search(orTerm);
|
||||
if (messages != null) {
|
||||
|
||||
@@ -376,7 +392,7 @@ public void buildReceiveConnect() throws Exception {
|
||||
folder.close(false);
|
||||
store.close();
|
||||
} catch (Exception e) {
|
||||
return messageIds;
|
||||
return messageIds;
|
||||
}
|
||||
return messageIds;
|
||||
}
|
||||
@@ -397,32 +413,32 @@ public void buildReceiveConnect() throws Exception {
|
||||
}
|
||||
}
|
||||
public static String getMessageId(Part part) throws Exception {
|
||||
if (!part.isMimeType("multipart/*")) {
|
||||
return "";
|
||||
}
|
||||
if (!part.isMimeType("multipart/*")) {
|
||||
return "";
|
||||
}
|
||||
|
||||
Multipart multipart = (Multipart) part.getContent();
|
||||
for (int i = 0; i < multipart.getCount(); i++) {
|
||||
BodyPart bodyPart = multipart.getBodyPart(i);
|
||||
Multipart multipart = (Multipart) part.getContent();
|
||||
for (int i = 0; i < multipart.getCount(); i++) {
|
||||
BodyPart bodyPart = multipart.getBodyPart(i);
|
||||
|
||||
if (part.isMimeType("message/rfc822")) {
|
||||
return getMessageId((Part) part.getContent());
|
||||
}
|
||||
InputStream inputStream = bodyPart.getInputStream();
|
||||
|
||||
try (BufferedReader br = new BufferedReader(new InputStreamReader(inputStream))) {
|
||||
String strLine;
|
||||
while ((strLine = br.readLine()) != null) {
|
||||
if (strLine.startsWith("Message_Id:")) {
|
||||
String[] split = strLine.split("Message_Id:");
|
||||
return split.length > 1 ? split[1].trim() : null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return "";
|
||||
if (part.isMimeType("message/rfc822")) {
|
||||
return getMessageId((Part) part.getContent());
|
||||
}
|
||||
InputStream inputStream = bodyPart.getInputStream();
|
||||
|
||||
try (BufferedReader br = new BufferedReader(new InputStreamReader(inputStream))) {
|
||||
String strLine;
|
||||
while ((strLine = br.readLine()) != null) {
|
||||
if (strLine.startsWith("Message_Id:")) {
|
||||
String[] split = strLine.split("Message_Id:");
|
||||
return split.length > 1 ? split[1].trim() : null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
|
||||
//检查退信邮件
|
||||
|
||||
@@ -44,7 +44,7 @@ public class PdfUtils {
|
||||
document.setMarginMirroring(false);
|
||||
document.open();
|
||||
// 解决PDF中文不显示
|
||||
String fontPath = "/D:/simsun.ttf"; //字体文件路径
|
||||
String fontPath = "/home/ruoyi/uploadPath/songfont/simsun.ttf"; //字体文件路径
|
||||
XMLWorkerFontProvider provider = new XMLWorkerFontProvider(XMLWorkerFontProvider.DONTLOOKFORFONTS);
|
||||
provider.register(fontPath);//注册字体
|
||||
log.error("注册字体");
|
||||
|
||||
@@ -1,78 +0,0 @@
|
||||
package com.ruoyi.common.utils;
|
||||
|
||||
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.cvm.v20170312.CvmClient;
|
||||
import com.tencentcloudapi.cvm.v20170312.models.DescribeRegionsRequest;
|
||||
import com.tencentcloudapi.cvm.v20170312.models.DescribeRegionsResponse;
|
||||
import com.tencentcloudapi.sms.v20210111.SmsClient;
|
||||
import com.tencentcloudapi.sms.v20210111.models.SendSmsResponse;
|
||||
import com.tencentcloudapi.sms.v20210111.models.SendStatus;
|
||||
import lombok.Data;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import lombok.var;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
@Slf4j
|
||||
public class SmsUtils {
|
||||
//应用id
|
||||
private static final String SDK_APP_ID = "1400854852";
|
||||
//API的SecretId
|
||||
private static final String SECRET_ID = "AKIDeEf2A8uX1HSainvvnXAc3X9ZlhtyvkMp";
|
||||
//API的SecretKey
|
||||
private static final String SECRET_KEY = "QjphKo8zkHZigT8j9PVtFPJyfIvO3d6V";
|
||||
//签名内容
|
||||
private static final String SIGN_NAME = "乙巢智慧仲裁网";
|
||||
|
||||
public static Boolean sendSms(SendSmsRequest request) {
|
||||
Credential cred = new Credential(SECRET_ID, SECRET_KEY );
|
||||
|
||||
SmsClient client = new SmsClient(cred, "ap-guangzhou");
|
||||
|
||||
final var req = new com.tencentcloudapi.sms.v20210111.models.SendSmsRequest();
|
||||
req.setPhoneNumberSet(new String[]{"+86" + request.getPhone()});
|
||||
req.setSmsSdkAppId(SDK_APP_ID );
|
||||
req.setSignName(SIGN_NAME);
|
||||
req.setTemplateId(request.getTemplateId());
|
||||
req.setTemplateParamSet(request.getTemplateParamSet());
|
||||
SendSmsResponse res = null;
|
||||
try {
|
||||
res = client.SendSms(req);
|
||||
} catch (TencentCloudSDKException e) {
|
||||
log.error("发送短信出错:", e);
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
SendStatus sendStatus = res.getSendStatusSet()[0];
|
||||
log.info("发送短信结果:Code={}, Message={}", sendStatus.getCode(), sendStatus.getMessage());
|
||||
|
||||
if (Objects.nonNull(res.getSendStatusSet()) && res.getSendStatusSet().length > 0 && "Ok".equals(res.getSendStatusSet()[0].getCode())){
|
||||
return Boolean.TRUE;
|
||||
}
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
/**
|
||||
* 参数对象
|
||||
*/
|
||||
@Data
|
||||
public static class SendSmsRequest {
|
||||
/**
|
||||
* 电话
|
||||
*/
|
||||
private String phone;
|
||||
|
||||
/**
|
||||
* 模板 ID: 必须填写已审核通过的模板 ID
|
||||
*/
|
||||
private String templateId;
|
||||
|
||||
/**
|
||||
* 模板参数: 模板参数的个数需要与 TemplateId 对应模板的变量个数保持一致,若无模板参数,则设置为空
|
||||
*/
|
||||
private String[] templateParamSet;
|
||||
private Long caseId;
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.ruoyi.common.utils;
|
||||
|
||||
import com.google.common.util.concurrent.ThreadFactoryBuilder;
|
||||
|
||||
import java.util.concurrent.*;
|
||||
|
||||
/**
|
||||
* @Author: ymbgy
|
||||
* @Date: 2022-09-23 10:06
|
||||
*/
|
||||
public class ThreadUtil {
|
||||
public static ExecutorService createThreadPool() {
|
||||
//获取系统处理器个数,作为线程池数量
|
||||
int nThreads = Runtime.getRuntime().availableProcessors();
|
||||
ThreadFactory namedThreadFactory = new ThreadFactoryBuilder()
|
||||
.setNameFormat("demo-pool-%d").build();
|
||||
//Thread Pool
|
||||
ExecutorService executor = new ThreadPoolExecutor(nThreads, 200,
|
||||
0L, TimeUnit.MILLISECONDS,
|
||||
new LinkedBlockingQueue<Runnable>(1024), namedThreadFactory, new ThreadPoolExecutor.AbortPolicy());
|
||||
return executor;
|
||||
}
|
||||
}
|
||||
@@ -1,11 +1,12 @@
|
||||
package com.ruoyi.framework.config;
|
||||
|
||||
import java.util.TimeZone;
|
||||
import org.mybatis.spring.annotation.MapperScan;
|
||||
//import org.mybatis.spring.annotation.MapperScan;
|
||||
import org.springframework.boot.autoconfigure.jackson.Jackson2ObjectMapperBuilderCustomizer;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.context.annotation.EnableAspectJAutoProxy;
|
||||
import tk.mybatis.spring.annotation.MapperScan;
|
||||
|
||||
/**
|
||||
* 程序注解配置
|
||||
|
||||
+18
-3
@@ -12,11 +12,16 @@
|
||||
<artifactId>ruoyi-system</artifactId>
|
||||
|
||||
<description>
|
||||
system系统模块
|
||||
<!-- system系统模块-->
|
||||
</description>
|
||||
|
||||
<dependencies>
|
||||
|
||||
<!--通用mapper-->
|
||||
<dependency>
|
||||
<groupId>tk.mybatis</groupId>
|
||||
<artifactId>mapper-spring-boot-starter</artifactId>
|
||||
<version>2.1.5</version>
|
||||
</dependency>
|
||||
<!-- 通用工具-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
@@ -33,7 +38,17 @@
|
||||
<artifactId>tls-sig-api-v2</artifactId>
|
||||
<version>1.2</version>
|
||||
</dependency>
|
||||
|
||||
<!--通用mapper-->
|
||||
<dependency>
|
||||
<groupId>tk.mybatis</groupId>
|
||||
<artifactId>mapper-spring-boot-starter</artifactId>
|
||||
<version>2.1.5</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>1.18.22</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
@@ -124,4 +124,11 @@ public interface SysDeptMapper
|
||||
* @return
|
||||
*/
|
||||
int batchSave(@Param("list")List<SysDept> sysDepts);
|
||||
|
||||
/**
|
||||
* 根据部门名称查询部门信息
|
||||
* @param deptName
|
||||
* @return
|
||||
*/
|
||||
public SysDept selectDeptByName(@Param("deptName") String deptName);
|
||||
}
|
||||
|
||||
@@ -171,4 +171,17 @@ public interface SysUserMapper
|
||||
* @return
|
||||
*/
|
||||
int batchSave(@Param("list")List<SysUser> addUsers);
|
||||
/**
|
||||
* 根据邮箱查询用户信息
|
||||
* @param email
|
||||
* @return
|
||||
*/
|
||||
SysUser selectUserByEmail(String email);
|
||||
|
||||
/**
|
||||
* 根据角色查询用户
|
||||
* @param 法律顾问
|
||||
* @return
|
||||
*/
|
||||
SysUser selectUserByRole(String 法律顾问);
|
||||
}
|
||||
|
||||
@@ -59,4 +59,13 @@ public interface SysUserRoleMapper
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserRoleInfos(@Param("roleId") Long roleId, @Param("userIds") Long[] userIds);
|
||||
|
||||
/**
|
||||
* 根据用户id查询关联的角色id
|
||||
* @param userId
|
||||
* @return
|
||||
*/
|
||||
List<Long> selectRoleIdsByUserId(Long userId);
|
||||
|
||||
void insertUserRole(@Param("userId") Long userId,@Param("roleId") Long roleId);
|
||||
}
|
||||
|
||||
@@ -2,6 +2,8 @@ package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.TreeSelect;
|
||||
import com.ruoyi.common.core.domain.entity.SysMenu;
|
||||
import com.ruoyi.system.domain.vo.RouterVo;
|
||||
@@ -141,4 +143,9 @@ public interface ISysMenuService
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean checkMenuNameUnique(SysMenu menu);
|
||||
/**
|
||||
* 根据用户查询菜单权限字符
|
||||
* @return
|
||||
*/
|
||||
AjaxResult getMenuPermsByUser();
|
||||
}
|
||||
|
||||
@@ -20,6 +20,12 @@ public interface ISysUserService
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectUserList(SysUser user);
|
||||
|
||||
/**
|
||||
* 查询仲裁员
|
||||
* @param arbitrator
|
||||
* @return
|
||||
*/
|
||||
public List<SysUser> selectUserListByAdRole(Arbitrator arbitrator);
|
||||
|
||||
/**
|
||||
|
||||
@@ -8,6 +8,8 @@ import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
@@ -528,4 +530,11 @@ public class SysMenuServiceImpl implements ISysMenuService
|
||||
return StringUtils.replaceEach(path, new String[] { Constants.HTTP, Constants.HTTPS, Constants.WWW, "." },
|
||||
new String[] { "", "", "", "/" });
|
||||
}
|
||||
@Override
|
||||
public AjaxResult getMenuPermsByUser() {
|
||||
AjaxResult result = AjaxResult.success();
|
||||
List<String> perms = menuMapper.selectMenuPermsByUserId(SecurityUtils.getUserId());
|
||||
result.put("perms",perms);
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,11 +6,17 @@ import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import javax.validation.Validator;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
import com.ruoyi.system.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.Arbitrator;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseAffiliateMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseApplicationMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -64,9 +70,13 @@ public class SysUserServiceImpl implements ISysUserService {
|
||||
|
||||
@Autowired
|
||||
private CaseApplicationMapper caseApplicationMapper;
|
||||
@Autowired
|
||||
private CaseAffiliateMapper caseAffiliateMapper;
|
||||
|
||||
@Autowired
|
||||
protected Validator validator;
|
||||
@Autowired
|
||||
protected ICaseApplicationService caseApplicationService;
|
||||
|
||||
/**
|
||||
* 根据条件分页查询用户列表
|
||||
@@ -80,21 +90,41 @@ public class SysUserServiceImpl implements ISysUserService {
|
||||
return userMapper.selectUserList(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询仲裁员
|
||||
* @param arbitrator
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<SysUser> selectUserListByAdRole(Arbitrator arbitrator) {
|
||||
// 根据案件id查询案件
|
||||
List<CaseAffiliateEntity> caseAffiliates = caseApplicationService.selectAfflicatesByCaseId(arbitrator.getCaseId());
|
||||
List<Long> userIds=new ArrayList<>();
|
||||
if(CollectionUtil.isNotEmpty(caseAffiliates)){
|
||||
for (CaseAffiliateEntity affiliate : caseAffiliates) {
|
||||
if(null!=affiliate.getUserId()) {
|
||||
userIds.add(affiliate.getUserId());
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
List<SysUser> sysUsers = userMapper.selectUserListByAdRole(arbitrator);
|
||||
if(sysUsers!=null&&sysUsers.size()>0){
|
||||
List<SysUser> arbitrators = new ArrayList<>();
|
||||
if(CollectionUtil.isNotEmpty(sysUsers)){
|
||||
for(SysUser sysUser: sysUsers){
|
||||
Long userId = sysUser.getUserId();
|
||||
int casenum = caseApplicationMapper.selectCasenum(userId.toString());
|
||||
String nickName = sysUser.getNickName();
|
||||
String nickNamenew = nickName + "(待办案件数量" + casenum + "个)";
|
||||
sysUser.setNickNameAndNum(nickNamenew);
|
||||
if(!userIds.contains(sysUser.getUserId())) {
|
||||
Long userId = sysUser.getUserId();
|
||||
int todoCount = caseApplicationMapper.selectCasenum(userId.toString());
|
||||
String nickName = sysUser.getNickName();
|
||||
String nickNamenew = nickName + "(待办案件数量" + todoCount + "个)";
|
||||
sysUser.setNickNameAndNum(nickNamenew);
|
||||
arbitrators.add(sysUser);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return sysUsers;
|
||||
return arbitrators;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -259,6 +289,13 @@ public class SysUserServiceImpl implements ISysUserService {
|
||||
@Override
|
||||
@Transactional
|
||||
public AjaxResult insertUser(SysUser user) {
|
||||
// 校验手机号是否重复
|
||||
if(StrUtil.isNotEmpty(user.getPhonenumber())){
|
||||
if(userMapper.checkPhoneUnique(user.getPhonenumber())!=null){
|
||||
return AjaxResult.error("新增用户'" + user.getUserName() + "'失败,手机号码已存在");
|
||||
}
|
||||
}
|
||||
|
||||
Long deptId = user.getDeptId();
|
||||
Long[] postIds = user.getPostIds();
|
||||
if (deptId != null) {
|
||||
@@ -296,6 +333,11 @@ public class SysUserServiceImpl implements ISysUserService {
|
||||
*/
|
||||
@Override
|
||||
public boolean registerUser(SysUser user) {
|
||||
if(StrUtil.isNotEmpty(user.getPhonenumber())){
|
||||
if(userMapper.checkPhoneUnique(user.getPhonenumber())!=null){
|
||||
throw new ServiceException("注册用户'" + user.getUserName() + "'失败,手机号码已存在");
|
||||
}
|
||||
}
|
||||
return userMapper.insertUser(user) > 0;
|
||||
}
|
||||
|
||||
@@ -315,13 +357,15 @@ public class SysUserServiceImpl implements ISysUserService {
|
||||
Integer deptType = dept.getDeptType();
|
||||
if (deptType != null && deptType.intValue() == 1) {
|
||||
SysPost sysPost = postMapper.selectPostByPostCode("jbr");
|
||||
Long postId = sysPost.getPostId();
|
||||
if (postIds.length > 0) {
|
||||
boolean isContain = Arrays.asList(postIds).contains(postId);
|
||||
if (isContain) {
|
||||
List<SysUser> sysUsers = userMapper.selectUserByDeptId(deptId);
|
||||
if (sysUsers != null && sysUsers.size() > 0) {
|
||||
return AjaxResult.error("部门类型为仲裁机构的部门的岗位为经办人的用户只能有一个!");
|
||||
if(sysPost!=null) {
|
||||
Long postId = sysPost.getPostId();
|
||||
if (postIds.length > 0) {
|
||||
boolean isContain = Arrays.asList(postIds).contains(postId);
|
||||
if (isContain) {
|
||||
List<SysUser> sysUsers = userMapper.selectUserByDeptId(deptId);
|
||||
if (sysUsers != null && sysUsers.size() > 0) {
|
||||
return AjaxResult.error("部门类型为仲裁机构的部门的岗位为经办人的用户只能有一个!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -522,6 +566,11 @@ public class SysUserServiceImpl implements ISysUserService {
|
||||
BeanValidators.validateWithException(validator, user);
|
||||
user.setPassword(SecurityUtils.encryptPassword(password));
|
||||
user.setCreateBy(operName);
|
||||
if(StrUtil.isNotEmpty(user.getPhonenumber())){
|
||||
if(userMapper.checkPhoneUnique(user.getPhonenumber())!=null){
|
||||
throw new ServiceException("导入用户'" + user.getUserName() + "'失败,手机号码已存在");
|
||||
}
|
||||
}
|
||||
userMapper.insertUser(user);
|
||||
successNum++;
|
||||
successMsg.append("<br/>" + successNum + "、账号 " + user.getUserName() + " 导入成功");
|
||||
|
||||
@@ -28,7 +28,7 @@ public class ArbitrateRecord extends BaseEntity {
|
||||
/** 仲裁员审核裁决书意见 */
|
||||
private String arbitraCheckOpinion;
|
||||
/** 裁决书附件id */
|
||||
private Integer annexId;
|
||||
private Long annexId;
|
||||
|
||||
/** 被申请人是否缺席 */
|
||||
private Integer isAbsence;
|
||||
@@ -62,14 +62,17 @@ public class ArbitrateRecord extends BaseEntity {
|
||||
*/
|
||||
private String caseCheckReject;
|
||||
/**
|
||||
* 仲裁员确认裁决书驳回
|
||||
* 裁决书驳回原因
|
||||
*/
|
||||
private String arbitrateReject;
|
||||
/**
|
||||
* 部门长确认裁决书驳回
|
||||
*/
|
||||
private String deptorReject;
|
||||
|
||||
/**
|
||||
* 缴费确认驳回原因
|
||||
*/
|
||||
private String payRejectReason;
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -9,6 +9,10 @@ public class Arbitrator extends BaseEntity {
|
||||
|
||||
/** ID */
|
||||
private Long id;
|
||||
/**
|
||||
* 案件id
|
||||
*/
|
||||
private Long caseId;
|
||||
/** 仲裁员姓名 */
|
||||
private String arbitratorName;
|
||||
/** 职称 */
|
||||
@@ -47,6 +51,14 @@ public class Arbitrator extends BaseEntity {
|
||||
/** 已结案数量 */
|
||||
private int closedCaseNum;
|
||||
|
||||
public Long getCaseId() {
|
||||
return caseId;
|
||||
}
|
||||
|
||||
public void setCaseId(Long caseId) {
|
||||
this.caseId = caseId;
|
||||
}
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.ruoyi.wisdomarbitrate.domain;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseAffiliateVO;
|
||||
import lombok.Data;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ColumnValue;
|
||||
@@ -17,6 +18,19 @@ public class CaseApplication extends BaseEntity {
|
||||
* 查询案件时区分是否待办案件,0待办案件,1已办案件
|
||||
*/
|
||||
private String selectCaseStatus;
|
||||
/**
|
||||
* 房间号
|
||||
*/
|
||||
private String roomId;
|
||||
/**
|
||||
* 仲裁员,0-否,1-是
|
||||
*/
|
||||
private Integer arbitratorFlag;
|
||||
/**
|
||||
* 第三方代理人,0-否,1-是
|
||||
*/
|
||||
private Integer agentFlag;
|
||||
|
||||
|
||||
/** ID */
|
||||
private Long id;
|
||||
@@ -26,6 +40,10 @@ public class CaseApplication extends BaseEntity {
|
||||
/** 案件编号 */
|
||||
// @Excel(name = "案件编号")
|
||||
private String caseNum;
|
||||
/**
|
||||
* 是否同意,0-否
|
||||
*/
|
||||
private Integer opinion;
|
||||
/** 案件标的 */
|
||||
@Excel(name = "案件标的")
|
||||
private BigDecimal caseSubjectAmount;
|
||||
@@ -39,7 +57,7 @@ public class CaseApplication extends BaseEntity {
|
||||
/** 立案日期 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date registerDate;
|
||||
/** 仲裁方式 */
|
||||
/** 仲裁方式 ,1-开庭,2-书面*/
|
||||
private Integer arbitratMethod;
|
||||
/**
|
||||
* 是否导入,0手动录入,1导入,默认0
|
||||
@@ -188,11 +206,15 @@ public class CaseApplication extends BaseEntity {
|
||||
/**
|
||||
* 用户id
|
||||
*/
|
||||
private String userId;
|
||||
private Long userId;
|
||||
/**
|
||||
* 登录用户用户名
|
||||
*/
|
||||
private String loginUserName;
|
||||
/**
|
||||
* 登录人电话
|
||||
*/
|
||||
private String loginUserPhone;
|
||||
private List<Long> deptIds;
|
||||
/**
|
||||
* 部门长状态
|
||||
@@ -207,7 +229,7 @@ public class CaseApplication extends BaseEntity {
|
||||
*/
|
||||
private Integer financeStatus;
|
||||
/**
|
||||
* 是否是被申请人,仲裁员,部门长,财务,代理人,0-否,1-是
|
||||
* 是否查询全部节点
|
||||
*/
|
||||
private Integer isOtherRole;
|
||||
/**
|
||||
@@ -219,7 +241,7 @@ public class CaseApplication extends BaseEntity {
|
||||
/** 是否指派仲裁员 */
|
||||
private int pendingAppointArbotrar;
|
||||
/** 案件关联人信息 */
|
||||
private List<CaseAffiliate> caseAffiliates;
|
||||
private CaseAffiliateVO affiliate;
|
||||
|
||||
/** 案件仲裁员 */
|
||||
private List<Arbitrator> arbitrators;
|
||||
@@ -227,7 +249,10 @@ public class CaseApplication extends BaseEntity {
|
||||
private List<Integer> caseStatusList;
|
||||
|
||||
private List<Integer> annexTypeList;
|
||||
|
||||
/**
|
||||
* 立案申请书(1)、申请人证据材料(2)、裁决书(3)、案件视频(4)、身份证件(5)
|
||||
* 被申请人证据材料 (6)、庭审笔录(7)、缴费凭证(8)、视频录制(9)、公章图片(10)、语音转录文件(11)
|
||||
*/
|
||||
private Integer annexType;
|
||||
/**
|
||||
* 案件附件列表
|
||||
@@ -419,4 +444,18 @@ public class CaseApplication extends BaseEntity {
|
||||
private Integer pendingStatus;
|
||||
/** e签宝流程id */
|
||||
private String signFlowId;
|
||||
/**
|
||||
* 登录用户名
|
||||
*/
|
||||
private String userName;
|
||||
// 缴费确认驳回原因
|
||||
private String payRejectReason;
|
||||
/**
|
||||
* 仲裁员确认裁决书驳回原因
|
||||
*/
|
||||
private String arbitrateReject;
|
||||
/**
|
||||
* deptorReject:部门长驳回原因
|
||||
*/
|
||||
private String deptorReject;
|
||||
}
|
||||
|
||||
@@ -1,19 +1,22 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain;
|
||||
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
@Data
|
||||
import java.util.List;
|
||||
|
||||
@Builder
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class CaseAttach {
|
||||
public class CaseAttach {
|
||||
/**
|
||||
* 附件id
|
||||
* 附件id
|
||||
*/
|
||||
private Integer annexId;
|
||||
private Long annexId;
|
||||
/**
|
||||
* 案件申请id
|
||||
*/
|
||||
@@ -22,6 +25,10 @@ public class CaseAttach {
|
||||
* 案件记录id
|
||||
*/
|
||||
private Long caseAppliLogId;
|
||||
/**
|
||||
* onlyOffice附件id
|
||||
*/
|
||||
private String onlyOfficeFileId;
|
||||
/**
|
||||
* 附件名称
|
||||
*/
|
||||
@@ -31,7 +38,7 @@ public class CaseAttach {
|
||||
*/
|
||||
private String annexPath;
|
||||
/**
|
||||
* 附件类型,立案申请书(1)、申请人证据材料(2)、仲裁文书(3)、案件视频(4)、身份证件(5)、被申请人证据材料 (6)、庭审笔录(7)、缴费凭证(8)'
|
||||
* 附件类型,立案申请书(1)、申请人证据材料(2)、裁决书(3)、案件视频(4)、身份证件(5)、被申请人证据材料 (6)、庭审笔录(7)、缴费凭证(8)'
|
||||
*/
|
||||
private Integer annexType;
|
||||
/**
|
||||
@@ -54,5 +61,9 @@ public class CaseAttach {
|
||||
* 是否是证据上传,0-否,1-是
|
||||
*/
|
||||
private Integer isBatchUpload;
|
||||
/**
|
||||
* 附件ids
|
||||
*/
|
||||
private List<Long> fileIds;
|
||||
|
||||
}
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ public class CaseEvidenceDirectory extends BaseEntity {
|
||||
/**
|
||||
* 附件id
|
||||
*/
|
||||
private Integer annexId;
|
||||
private Long annexId;
|
||||
|
||||
/**
|
||||
* 级数
|
||||
|
||||
@@ -42,6 +42,18 @@ public class CaseLogRecord extends BaseEntity {
|
||||
* 下一个节点角色名称
|
||||
*/
|
||||
private String nextRoleName;
|
||||
/**
|
||||
* 当前节点角色名称
|
||||
*/
|
||||
private String currentRoleName;
|
||||
|
||||
public String getCurrentRoleName() {
|
||||
return currentRoleName;
|
||||
}
|
||||
|
||||
public void setCurrentRoleName(String currentRoleName) {
|
||||
this.currentRoleName = currentRoleName;
|
||||
}
|
||||
|
||||
public String getNextRoleName() {
|
||||
return nextRoleName;
|
||||
|
||||
@@ -29,7 +29,7 @@ public class SealManage extends BaseEntity {
|
||||
/**
|
||||
* 附件id
|
||||
*/
|
||||
private Integer annexId;
|
||||
private Long annexId;
|
||||
|
||||
/**
|
||||
* 印章审核状态(0未通过,1通过)
|
||||
|
||||
@@ -58,6 +58,14 @@ public class SealSignRecord extends BaseEntity {
|
||||
private double positionXorg;
|
||||
/** 印章位置y坐标 */
|
||||
private double positionYorg;
|
||||
/**
|
||||
* 仲裁员签名状态,1-签名
|
||||
*/
|
||||
private Integer signStatusArbitor;
|
||||
/**
|
||||
* 用印状态,1用印
|
||||
*/
|
||||
private Integer sealStatus;
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,45 +0,0 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class SmsSendRecord extends BaseEntity {
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
* 案件申请id
|
||||
*/
|
||||
private Long caseId;
|
||||
/**
|
||||
* 案件编号
|
||||
*/
|
||||
private String caseNum;
|
||||
/**
|
||||
* 手机号
|
||||
*/
|
||||
private String phone;
|
||||
/**
|
||||
* 发送时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date sendTime;
|
||||
/**
|
||||
* 发送内容
|
||||
*/
|
||||
private String sendContent;
|
||||
|
||||
/**
|
||||
* 发送状态
|
||||
*/
|
||||
private Integer sendStatus;
|
||||
}
|
||||
+309
@@ -0,0 +1,309 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.dto;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseAffiliateVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ColumnValue;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Classname CaseApplicationDTO
|
||||
* @Description 案件申请表
|
||||
* @Version 1.0.0
|
||||
* @Date 2024/5/22 9:19
|
||||
* @Created wangqiong
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class CaseApplicationDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 案件编号
|
||||
*/
|
||||
private String caseNum;
|
||||
|
||||
/**
|
||||
* 案件标的
|
||||
*/
|
||||
private BigDecimal caseSubjectAmount;
|
||||
|
||||
/**
|
||||
* 立案日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "Asia/Shanghai")
|
||||
private Date registerDate;
|
||||
|
||||
/**
|
||||
* 仲裁方式,视频仲裁(1)、书面仲裁(2)
|
||||
*/
|
||||
private Long arbitratMethod;
|
||||
|
||||
/**
|
||||
* 案件状态,立案申请(0)、待立案审查(1)、 待缴费(2)、待缴费确认(3)、 待案件质证(4)、
|
||||
*/
|
||||
private Integer caseStatus;
|
||||
|
||||
/**
|
||||
* 开庭日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "Asia/Shanghai")
|
||||
private Date hearDate;
|
||||
|
||||
/**
|
||||
* 申请人仲裁请求及事实和理由
|
||||
*/
|
||||
private String arbitratClaims;
|
||||
|
||||
/**
|
||||
* 借款开始日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "Asia/Shanghai")
|
||||
private Date loanStartDate;
|
||||
|
||||
/**
|
||||
* 借款结束日期
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "Asia/Shanghai")
|
||||
private Date loanEndDate;
|
||||
|
||||
/**
|
||||
* 申请人主张欠本金
|
||||
*/
|
||||
private BigDecimal claimPrinciOwed;
|
||||
|
||||
/**
|
||||
* 申请人主张欠利息
|
||||
*/
|
||||
private BigDecimal claimInterestOwed;
|
||||
|
||||
/**
|
||||
* 申请人主张违约金
|
||||
*/
|
||||
private BigDecimal claimLiquidDamag;
|
||||
|
||||
/**
|
||||
* 仲裁应缴费用
|
||||
*/
|
||||
private BigDecimal feePayable;
|
||||
|
||||
|
||||
/**
|
||||
* 合同编号
|
||||
*/
|
||||
private String contractNumber;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "Asia/Shanghai")
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
private String updateBy;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "Asia/Shanghai")
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
private String createBy;
|
||||
|
||||
/**
|
||||
* 仲裁员id
|
||||
*/
|
||||
private String arbitratorId;
|
||||
|
||||
/**
|
||||
* 案件名称
|
||||
*/
|
||||
private String caseName;
|
||||
|
||||
/**
|
||||
* 仲裁结果
|
||||
*/
|
||||
private String caseResult;
|
||||
|
||||
/**
|
||||
* 是否同意组庭,0否,1是
|
||||
*/
|
||||
private Integer isAgreePendTral;
|
||||
|
||||
/**
|
||||
* 是否有异议需要举证,1是,0否
|
||||
*/
|
||||
private Integer objectionAddEviden;
|
||||
|
||||
|
||||
/**
|
||||
* 案件实缴费用
|
||||
*/
|
||||
private BigDecimal paidExpenses;
|
||||
|
||||
/**
|
||||
* 裁决书URL
|
||||
*/
|
||||
private String filearbitraUrl;
|
||||
|
||||
/**
|
||||
* 支付方式(0线上支付,1线下支付)
|
||||
*/
|
||||
private String payType;
|
||||
|
||||
/**
|
||||
* 申请人请求仲裁庭裁决
|
||||
*/
|
||||
private String requestRule;
|
||||
|
||||
/**
|
||||
* 是否仲裁反请求,1是,0否
|
||||
*/
|
||||
private Integer adjudicaCounter;
|
||||
|
||||
/**
|
||||
* 仲裁反请求原因
|
||||
*/
|
||||
private String adjudicaCounterReason;
|
||||
|
||||
/**
|
||||
* 是否财产保全申请,1是,0否
|
||||
*/
|
||||
private Integer properPreser;
|
||||
|
||||
/**
|
||||
* 是否管辖异议申请,1是,0否
|
||||
*/
|
||||
private Integer objectiJuris;
|
||||
|
||||
/**
|
||||
* 被申请人是否缺席,1是,0否
|
||||
*/
|
||||
private Integer isAbsence;
|
||||
|
||||
/**
|
||||
* 被申请人质证意见
|
||||
*/
|
||||
private String responCrossOpin;
|
||||
|
||||
/**
|
||||
* 申请人质证意见
|
||||
*/
|
||||
private String applicaCrossOpin;
|
||||
|
||||
/**
|
||||
* 被申请人的答辩意见
|
||||
*/
|
||||
private String responDefenOpini;
|
||||
|
||||
/**
|
||||
* 申请人是否缺席,1是,0否
|
||||
*/
|
||||
private Integer appliIsAbsen;
|
||||
|
||||
/**
|
||||
* 是否锁定,0-否,1-是
|
||||
*/
|
||||
private Integer lockStatus;
|
||||
|
||||
/**
|
||||
* 视频会议房间号id
|
||||
*/
|
||||
private String roomId;
|
||||
|
||||
/**
|
||||
* 是否导入,0手动录入,1导入,默认0
|
||||
*/
|
||||
private Integer importFlag=0;
|
||||
|
||||
/**
|
||||
* 版本号
|
||||
*/
|
||||
private Integer version;
|
||||
|
||||
/**
|
||||
* 事实和理由
|
||||
*/
|
||||
private String facts;
|
||||
|
||||
/**
|
||||
* 批次
|
||||
*/
|
||||
private Integer batchNumber;
|
||||
|
||||
/**
|
||||
* 模板id
|
||||
*/
|
||||
private Long templateId;
|
||||
|
||||
/**
|
||||
* 调解内容
|
||||
*/
|
||||
private String mediationAgreement;
|
||||
|
||||
/**
|
||||
* 申请人是否书面审理 ,0否,1是
|
||||
*/
|
||||
private Integer appliIswritHear;
|
||||
|
||||
/**
|
||||
* 被申请人是否书面审理
|
||||
*/
|
||||
private Integer responIsWritHear;
|
||||
|
||||
/**
|
||||
* 案件附件相关表
|
||||
*/
|
||||
private List<CaseAttach> caseAttachList;
|
||||
/**
|
||||
* 附件类型
|
||||
*/
|
||||
private List<Integer> annexTypeList;
|
||||
/**
|
||||
* 附件类型
|
||||
*/
|
||||
private Integer annexType;
|
||||
/**
|
||||
* 自定义字段
|
||||
*/
|
||||
private List<ColumnValue> columnValueList;
|
||||
/**
|
||||
* 案件相关人员
|
||||
*/
|
||||
private CaseAffiliateVO affiliate;
|
||||
/**
|
||||
* 待办状态,0-待办,1-已办
|
||||
*/
|
||||
private Integer pendingStatus;
|
||||
/**
|
||||
* 仲裁方式名称,1-线上调解,2-线下调解
|
||||
*/
|
||||
private String arbitratMethodName;
|
||||
/**
|
||||
* 申请机构名称
|
||||
*/
|
||||
private String applicationName;
|
||||
/**
|
||||
* 被申请人姓名
|
||||
*/
|
||||
private String respondentName;
|
||||
|
||||
}
|
||||
+15
-2
@@ -1,11 +1,14 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain;
|
||||
package com.ruoyi.wisdomarbitrate.domain.dto.sendrecord;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class SendMailRecord extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -40,6 +43,16 @@ public class SendMailRecord extends BaseEntity {
|
||||
private Integer sendStatus;
|
||||
|
||||
|
||||
/** 附件id */
|
||||
private String fileIds;
|
||||
|
||||
/** 邮件主题 */
|
||||
private String mailSubject;
|
||||
|
||||
/** 邮件发件人地址 */
|
||||
private String mailFromAddress;
|
||||
private List<CaseAttach> caseAttachList;
|
||||
|
||||
|
||||
public Integer getSendStatus() {
|
||||
return sendStatus;
|
||||
+78
@@ -0,0 +1,78 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.dto.sendrecord;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsTemplateParam;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class SmsSendRecord extends BaseEntity {
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
* 短信模板主键id
|
||||
*/
|
||||
private Long msSmsTemplateId;
|
||||
/**
|
||||
* 案件申请id
|
||||
*/
|
||||
private Long caseId;
|
||||
/**
|
||||
* 案件编号
|
||||
*/
|
||||
private String caseNum;
|
||||
/**
|
||||
* 手机号
|
||||
*/
|
||||
private String phone;
|
||||
/**
|
||||
* 发送时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date sendTime;
|
||||
|
||||
/**
|
||||
* 发送状态
|
||||
*/
|
||||
private Integer sendStatus;
|
||||
/**
|
||||
* 短信sid,发送的唯一标识
|
||||
*/
|
||||
private String sid;
|
||||
/**
|
||||
* 失败原因
|
||||
*/
|
||||
private String reason;
|
||||
/**
|
||||
* 短信内容
|
||||
*/
|
||||
private String sendContent;
|
||||
/**
|
||||
* 腾讯云模板id
|
||||
*/
|
||||
private String templateId;
|
||||
/**
|
||||
* 模板内容
|
||||
*/
|
||||
private String templateContent;
|
||||
private List<MsSmsTemplateParam> templateParams;
|
||||
|
||||
public SmsSendRecord(Long caseId, String caseNum, String phone, Date sendTime, String sendContent,String sid) {
|
||||
this.caseId = caseId;
|
||||
this.caseNum = caseNum;
|
||||
this.phone = phone;
|
||||
this.sendTime = sendTime;
|
||||
this.sendContent = sendContent;
|
||||
this.sid = sid;
|
||||
}
|
||||
}
|
||||
+129
@@ -0,0 +1,129 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Data
|
||||
public class CaseAffiliateEntity {
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
* 案件主表id,案件申请表主键
|
||||
*/
|
||||
private Long caseAppliId;
|
||||
/**
|
||||
* 案件日志表id
|
||||
*/
|
||||
private Long caseAppliLogId;
|
||||
/**
|
||||
* 用户id,用户表user_id关联
|
||||
*/
|
||||
private Long userId;
|
||||
/**
|
||||
* 申请机构id,和部门表id关联
|
||||
*/
|
||||
private Long applicantDeptId;
|
||||
|
||||
/**
|
||||
* 代码(统一社会信用代码或者身份证号)
|
||||
*/
|
||||
private String code;
|
||||
/**
|
||||
* 用户名
|
||||
*/
|
||||
private String userName;
|
||||
|
||||
/**
|
||||
* 法定代表人
|
||||
*/
|
||||
private String compLegalPerson;
|
||||
/**
|
||||
* 角色类别,1-申请操作人/申请人,2-申请人代理人,3-被申请人操作人/被申请人,4-被申请人代理人
|
||||
*/
|
||||
private Integer roleType=1;
|
||||
/**
|
||||
* 组别
|
||||
*/
|
||||
private Integer groupOrder;
|
||||
/**
|
||||
* 是否操作人,0-否,1-是
|
||||
*/
|
||||
private Integer operatorFlag=1;
|
||||
/**
|
||||
* 是否机构申请,0-自然人,1-申请机构,默认0
|
||||
*/
|
||||
private Integer organizeFlag=0;
|
||||
/**
|
||||
* 电话
|
||||
*/
|
||||
private String phone;
|
||||
/**
|
||||
* 邮箱
|
||||
*/
|
||||
private String email;
|
||||
/**
|
||||
* 姓名
|
||||
*/
|
||||
private String name;
|
||||
/**
|
||||
* 住所
|
||||
*/
|
||||
private String home;
|
||||
/**
|
||||
* 联系地址
|
||||
*/
|
||||
private String address;
|
||||
/**
|
||||
* 身份证号
|
||||
*/
|
||||
private String idCard;
|
||||
|
||||
/**
|
||||
* '身份类别,0-身份证,1-护照,默认0'
|
||||
*/
|
||||
private Integer idType;
|
||||
/**
|
||||
* 国籍,0-境内,1-境外,默认0
|
||||
*/
|
||||
private Integer nationality;
|
||||
/**
|
||||
* 生日
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "Asia/Shanghai")
|
||||
private Date birth;
|
||||
/**
|
||||
* 性别,0-男,1-女
|
||||
*/
|
||||
private String sex;
|
||||
/**
|
||||
* 被申请人姓名
|
||||
*/
|
||||
private String resName;
|
||||
/**
|
||||
* 角色名称
|
||||
*/
|
||||
private String roleName;
|
||||
/**
|
||||
* 申请机构名称
|
||||
*/
|
||||
private String applicantOrgName;
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
private Long roleId;
|
||||
/**
|
||||
* 职位
|
||||
*/
|
||||
private String position;
|
||||
|
||||
}
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.entity.sms;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Table(name = "sms_send_history_record_param")
|
||||
public class MsSmsSendHistoryRecordParam {
|
||||
@Id
|
||||
@GeneratedValue(generator = "JDBC")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 短信历史记录表id
|
||||
*/
|
||||
@Column(name = "sms_record_history_id")
|
||||
private Long smsRecordHistoryId;
|
||||
|
||||
/**
|
||||
* 参数值
|
||||
*/
|
||||
@Column(name = "param_value")
|
||||
private String paramValue;
|
||||
}
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.entity.sms;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Table(name = "sms_send_record_param")
|
||||
public class MsSmsSendRecordParam {
|
||||
@Id
|
||||
@GeneratedValue(generator = "JDBC")
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 短信记录表id
|
||||
*/
|
||||
@Column(name = "sms_record_id")
|
||||
private Long smsRecordId;
|
||||
|
||||
|
||||
/**
|
||||
* 参数值
|
||||
*/
|
||||
@Column(name = "param_value")
|
||||
private String paramValue;
|
||||
}
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.entity.sms;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.util.List;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Table(name = "sms_template")
|
||||
public class MsSmsTemplate {
|
||||
@Id
|
||||
@GeneratedValue(generator = "JDBC")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 腾讯云模板id
|
||||
*/
|
||||
@Column(name = "template_id")
|
||||
private String templateId;
|
||||
|
||||
/**
|
||||
* 模板名称
|
||||
*/
|
||||
private String name;
|
||||
/**
|
||||
* 模板内容
|
||||
*/
|
||||
private String content;
|
||||
/**
|
||||
* 模板参数
|
||||
*/
|
||||
@Transient
|
||||
private List<MsSmsTemplateParam> templateParams;
|
||||
}
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.entity.sms;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Table(name = "sms_template_param")
|
||||
public class MsSmsTemplateParam {
|
||||
@Id
|
||||
@GeneratedValue(generator = "JDBC")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* ms_sms_template表id
|
||||
*/
|
||||
@Column(name = "sms_template_id")
|
||||
private Long smsTemplateId;
|
||||
|
||||
/**
|
||||
* 参数
|
||||
*/
|
||||
private String param;
|
||||
/**
|
||||
* 参数名
|
||||
*/
|
||||
@Column(name = "param_name")
|
||||
private String paramName;
|
||||
/**
|
||||
* 参数值
|
||||
*/
|
||||
@Transient
|
||||
private String paramValue;
|
||||
}
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.shortmessage;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table(name = "meeting_info")
|
||||
public class MeetingInfo {
|
||||
/**
|
||||
* 主键Id
|
||||
*/
|
||||
@Id
|
||||
private String uid;
|
||||
|
||||
/**
|
||||
* 案件Id
|
||||
*/
|
||||
@Column(name = "case_id")
|
||||
private Long caseId;
|
||||
|
||||
/**
|
||||
* 用户Id
|
||||
*/
|
||||
@Column(name = "user_id")
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 用户名称
|
||||
*/
|
||||
@Column(name = "user_name")
|
||||
private String userName;
|
||||
|
||||
/**
|
||||
* 房间Id
|
||||
*/
|
||||
@Column(name = "room_id")
|
||||
private String roomId;
|
||||
|
||||
/**
|
||||
* 系统类型
|
||||
*/
|
||||
@Column(name = "system_type")
|
||||
private String systemType;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@Column(name = "create_time")
|
||||
private Date createTime;
|
||||
}
|
||||
+111
@@ -0,0 +1,111 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.shortmessage;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
import java.util.Date;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Table(name = "send_mail_history_record")
|
||||
public class MsSendMailHistoryRecord {
|
||||
@Id
|
||||
@GeneratedValue(generator = "JDBC")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 邮件名称
|
||||
*/
|
||||
@Column(name = "mail_name")
|
||||
private String mailName;
|
||||
|
||||
/**
|
||||
* 邮件接收地址
|
||||
*/
|
||||
@Column(name = "mail_address")
|
||||
private String mailAddress;
|
||||
|
||||
/**
|
||||
* 发送时间
|
||||
*/
|
||||
@Column(name = "send_time")
|
||||
private Date sendTime;
|
||||
|
||||
/**
|
||||
* 案件编号
|
||||
*/
|
||||
@Column(name = "case_num")
|
||||
private String caseNum;
|
||||
|
||||
/**
|
||||
* 发送状态
|
||||
*/
|
||||
@Column(name = "send_status")
|
||||
private Long sendStatus;
|
||||
|
||||
/**
|
||||
* 立案申请id
|
||||
*/
|
||||
@Column(name = "case_id")
|
||||
private Long caseId;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@Column(name = "create_time")
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
@Column(name = "create_by")
|
||||
private String createBy;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
@Column(name = "update_by")
|
||||
private String updateBy;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@Column(name = "update_time")
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 附件id用英文逗号隔开
|
||||
*/
|
||||
@Column(name = "file_ids")
|
||||
private String fileIds;
|
||||
|
||||
/**
|
||||
* 邮件主题
|
||||
*/
|
||||
@Column(name = "mail_subject")
|
||||
private String mailSubject;
|
||||
|
||||
/**
|
||||
* 邮件发送地址
|
||||
*/
|
||||
@Column(name = "mail_from_address")
|
||||
private String mailFromAddress;
|
||||
|
||||
/**
|
||||
* 邮件父类id
|
||||
*/
|
||||
@Column(name = "parent_id")
|
||||
private Long parentId;
|
||||
|
||||
/**
|
||||
* 邮件内容
|
||||
*/
|
||||
@Column(name = "mail_content")
|
||||
private String mailContent;
|
||||
}
|
||||
+98
@@ -0,0 +1,98 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.shortmessage;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Builder
|
||||
@Table(name = "sms_send_history_record")
|
||||
public class MsSmsSendHistoryRecord {
|
||||
@Id
|
||||
@GeneratedValue(generator = "JDBC")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 案件id
|
||||
*/
|
||||
@Column(name = "case_appli_id")
|
||||
private Long caseAppliId;
|
||||
/**
|
||||
* 短信模板表主键id
|
||||
*/
|
||||
@Column(name = "ms_sms_template_id")
|
||||
private Long msSmsTemplateId;
|
||||
|
||||
/**
|
||||
* 案件编号
|
||||
*/
|
||||
@Column(name = "case_num")
|
||||
private String caseNum;
|
||||
|
||||
/**
|
||||
* 手机号
|
||||
*/
|
||||
private String phone;
|
||||
|
||||
/**
|
||||
* 发送时间
|
||||
*/
|
||||
@Column(name = "send_time")
|
||||
private Date sendTime;
|
||||
|
||||
/**
|
||||
* 发送状态,0-失败,1-成功
|
||||
*/
|
||||
@Column(name = "send_status")
|
||||
private Long sendStatus;
|
||||
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@Column(name = "create_time")
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@Column(name = "update_time")
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
@Column(name = "create_by")
|
||||
private String createBy;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
@Column(name = "update_by")
|
||||
private String updateBy;
|
||||
|
||||
/**
|
||||
* 发送短信唯一标识
|
||||
*/
|
||||
private String sid;
|
||||
|
||||
/**
|
||||
* 父类短信id
|
||||
*/
|
||||
@Column(name = "parent_id")
|
||||
private Long parentId;
|
||||
|
||||
/**
|
||||
* 失败原因
|
||||
*/
|
||||
private String reason;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @Classname MsCaseAffiliateList
|
||||
* @Description 案件人员表
|
||||
* @Version 1.0.0
|
||||
* @Date 2024/3/27 16:08
|
||||
* @Created wangqiong
|
||||
*/
|
||||
@Data
|
||||
public class CaseAffiliateBase {
|
||||
/**
|
||||
* 申请人/操作人
|
||||
*/
|
||||
private CaseAffiliateEntity applicant;
|
||||
/**
|
||||
* 申请人代理人
|
||||
*/
|
||||
private CaseAffiliateEntity applicantAgent;
|
||||
/**
|
||||
* 被申请人/操作人
|
||||
*/
|
||||
private CaseAffiliateEntity res;
|
||||
/**
|
||||
* 被申请人代理人
|
||||
*/
|
||||
private CaseAffiliateEntity resAgent;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Classname MsCaseAffiliateVO
|
||||
* @Description 案件人员表
|
||||
* @Version 1.0.0
|
||||
* @Date 2024/3/22 11:46
|
||||
* @Created wangqiong
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@ToString
|
||||
@Data
|
||||
public class CaseAffiliateVO {
|
||||
/**
|
||||
* 申请人/操作人
|
||||
*/
|
||||
private List<CaseAffiliateBase> applicant;
|
||||
|
||||
/**
|
||||
* 被申请人/操作人
|
||||
*/
|
||||
private List<CaseAffiliateBase> res;
|
||||
|
||||
}
|
||||
+3
-3
@@ -30,7 +30,7 @@ public class CaseEvidenceDirectoryVO implements Serializable {
|
||||
/**
|
||||
* 附件id
|
||||
*/
|
||||
private Integer annexId;
|
||||
private Long annexId;
|
||||
|
||||
/**
|
||||
* 级数
|
||||
@@ -105,11 +105,11 @@ public class CaseEvidenceDirectoryVO implements Serializable {
|
||||
this.evidenceName = evidenceName;
|
||||
}
|
||||
|
||||
public Integer getAnnexId() {
|
||||
public Long getAnnexId() {
|
||||
return annexId;
|
||||
}
|
||||
|
||||
public void setAnnexId(Integer annexId) {
|
||||
public void setAnnexId(Long annexId) {
|
||||
this.annexId = annexId;
|
||||
}
|
||||
|
||||
|
||||
@@ -37,4 +37,8 @@ public class CaseEvidenceVO {
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date scheduleStartTime;
|
||||
/**
|
||||
* 案件编号
|
||||
*/
|
||||
private String caseStatusName;
|
||||
}
|
||||
|
||||
@@ -21,14 +21,14 @@ public class ToDoCount {
|
||||
private int caseApplyArbitrateWay=0; // 待审核仲裁方式
|
||||
private int caseApplyGroupOnline=0; // 待开庭审理
|
||||
private int caseApplyGroupOffline=0; // 待书面审理
|
||||
private int caseApplyAward=0; // 待生成仲裁文书
|
||||
private int caseApplyAwardCheck=0; // 待核验仲裁文书
|
||||
private int caseApplyAwardConfirm=0; // 待审核仲裁文书
|
||||
private int caseApplyAwardSign=0; // 待仲裁文书签名
|
||||
private int caseApplyAwardSeal=0; // 待仲裁文书用印
|
||||
private int caseApplyAwardSend=0; // 待仲裁文书送达
|
||||
private int caseApplyAward=0; // 待生成裁决书
|
||||
private int caseApplyAwardCheck=0; // 待核验裁决书
|
||||
private int caseApplyAwardConfirm=0; // 待审核裁决书
|
||||
private int caseApplyAwardSign=0; // 待裁决书签名
|
||||
private int caseApplyAwardSeal=0; // 待裁决书用印
|
||||
private int caseApplyAwardSend=0; // 待裁决书送达
|
||||
private int caseApplyStored=0; // 待案件归档
|
||||
private int caseApplyArchived=0; // 已归档
|
||||
private int updateOnlineHearDate=0; // 待修改开庭时间
|
||||
private int arbitratorApplyAwardConfirm=0; // 待仲裁员审核仲裁文书
|
||||
private int arbitratorApplyAwardConfirm=0; // 待仲裁员审核裁决书
|
||||
}
|
||||
|
||||
+41
@@ -0,0 +1,41 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo.shortmessage;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class MeetingInfoVO {
|
||||
/**
|
||||
* 案件Id
|
||||
*/
|
||||
private Long caseId;
|
||||
|
||||
/**
|
||||
* 用户Id
|
||||
*/
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 用户名称
|
||||
*/
|
||||
private String userName;
|
||||
|
||||
/**
|
||||
* 房间Id
|
||||
*/
|
||||
private String roomId;
|
||||
|
||||
/**
|
||||
* 系统类型
|
||||
*/
|
||||
private String systemType;
|
||||
/**
|
||||
* 登录认证令牌
|
||||
*/
|
||||
private String token;
|
||||
}
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo.shortmessage;
|
||||
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsTemplateParam;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class ReSendMessageVO {
|
||||
/**
|
||||
* 短信模版Id
|
||||
*/
|
||||
private String templateId;
|
||||
/**
|
||||
* 手机号
|
||||
*/
|
||||
private String phone;
|
||||
/**
|
||||
* 短信id
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
* 短信模版参数值
|
||||
*/
|
||||
private List<MsSmsTemplateParam> templateParams;
|
||||
|
||||
}
|
||||
+2
-1
@@ -2,6 +2,7 @@ package com.ruoyi.wisdomarbitrate.mapper;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
@@ -10,7 +11,7 @@ import java.util.List;
|
||||
public interface CaseAffiliateLogMapper {
|
||||
|
||||
|
||||
int batchCaseAffiliate(List<CaseAffiliate> caseAffiliates);
|
||||
int batchCaseAffiliate(List<CaseAffiliateEntity> caseAffiliates);
|
||||
|
||||
|
||||
void deletecaseAffiliate(CaseApplication caseApplication);
|
||||
|
||||
+18
-18
@@ -3,6 +3,8 @@ package com.ruoyi.wisdomarbitrate.mapper;
|
||||
import com.ruoyi.wisdomarbitrate.domain.BatchCaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseApplicationDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.BookSendVO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
@@ -18,28 +20,26 @@ public interface CaseAffiliateMapper {
|
||||
void batchDeletecaseAffiliate(@Param("ids") List<Long> ids);
|
||||
|
||||
|
||||
List<CaseAffiliate> selectCaseAffiliate(CaseAffiliate caseAffiliate);
|
||||
List<CaseAffiliate> selectCaseAffiliateByCaseIds(@Param("ids") List<Long> ids);
|
||||
CaseAffiliate selectCaseAffiliateByIdentityType(@Param("caseAppliId") Long caseAppliId, @Param("identityType")int identityType);
|
||||
|
||||
int updataCaseAffiliate(CaseAffiliate caseAffiliate);
|
||||
|
||||
/**
|
||||
* 根据案件查询邮箱
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
List<CaseAffiliate> emailByCaseId(@Param("caseAppliId")Long id);
|
||||
|
||||
/**
|
||||
* 批量修改
|
||||
* @param affiliateLogList
|
||||
*/
|
||||
void updateCaseAffiliateByCaseId(@Param("caseAppliId")Long caseAppliId,@Param("list") List<CaseAffiliate> affiliateLogList);
|
||||
List<CaseAffiliateEntity> selectCaseAffiliate(CaseAffiliateEntity entity);
|
||||
List<CaseAffiliateEntity> selectCaseAffiliateByCaseIds(@Param("caseIds") List<Long> ids);
|
||||
|
||||
/**
|
||||
* 根据案件id删除
|
||||
* @param caseId
|
||||
*/
|
||||
void deleteByCaseId(@Param("caseAppliId") Long caseId);
|
||||
|
||||
/**
|
||||
* 新增人员
|
||||
* @param affiliate
|
||||
*/
|
||||
|
||||
void insert(CaseAffiliateEntity affiliate);
|
||||
|
||||
/**
|
||||
* 根据案件id查询邮箱
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
List<CaseAffiliateEntity> emailByCaseId(Long id);
|
||||
}
|
||||
|
||||
+32
-20
@@ -4,6 +4,7 @@ import com.ruoyi.wisdomarbitrate.domain.Arbitrator;
|
||||
import com.ruoyi.wisdomarbitrate.domain.BatchCaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseApplicationDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseConfirmPayDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ToDoCount;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
@@ -11,18 +12,9 @@ import org.apache.ibatis.annotations.Param;
|
||||
import java.util.List;
|
||||
|
||||
public interface CaseApplicationMapper {
|
||||
List<CaseApplication> selectCaseApplicationList(CaseApplication caseApplication);
|
||||
List<CaseApplication> selectCaseApplicationList1(CaseApplication caseApplication);
|
||||
|
||||
int selectCaseApplicationCount(CaseApplication caseApplication);
|
||||
|
||||
/**
|
||||
* 查询超级管理员案件
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
List<CaseApplication> selectAdminCaseApplicationList(CaseApplication caseApplication);
|
||||
|
||||
int insertCaseApplication(CaseApplication caseApplication);
|
||||
|
||||
|
||||
@@ -41,7 +33,7 @@ public interface CaseApplicationMapper {
|
||||
*/
|
||||
List<CaseApplication> listCaseApplicationByIds(@Param("ids")List<Long> ids);
|
||||
|
||||
CaseApplication selectCaseApplicationConfirm(CaseApplication caseApplication);
|
||||
|
||||
|
||||
/**
|
||||
* 查询最大编号
|
||||
@@ -65,10 +57,11 @@ public interface CaseApplicationMapper {
|
||||
void updatePayType(CaseConfirmPayDTO payDTO);
|
||||
|
||||
|
||||
ToDoCount selectAdminCaseToDoCount();
|
||||
|
||||
|
||||
ToDoCount selectTodoCountByRole(CaseApplication caseApplication);
|
||||
ToDoCount selectTodoCountByRole(@Param("caseApplication") CaseApplication caseApplication,
|
||||
@Param("caseStatusList") List<Integer> caseStatusList,
|
||||
@Param("roleIds") List<Long> roleIds);
|
||||
|
||||
/**
|
||||
* 修改案件锁定状态
|
||||
@@ -99,12 +92,6 @@ public interface CaseApplicationMapper {
|
||||
*/
|
||||
Long selectCaseIdByRoomId(@Param("roomId")String roomId);
|
||||
|
||||
/**
|
||||
* 查询已办案件
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
List<CaseApplication> selectHandledCase(CaseApplication caseApplication);
|
||||
/**
|
||||
* 查询最大房间号
|
||||
* @return
|
||||
@@ -123,7 +110,7 @@ public interface CaseApplicationMapper {
|
||||
* 查询最大批号
|
||||
* @return
|
||||
*/
|
||||
Integer selectBatchNumberLike();
|
||||
Integer selectMaxBatchNumber();
|
||||
|
||||
/**
|
||||
* 批量新增案件
|
||||
@@ -138,5 +125,30 @@ public interface CaseApplicationMapper {
|
||||
|
||||
List<CaseApplication> listCaseApplicationByBatchNumber(CaseApplication caseApplication);
|
||||
|
||||
List<CaseApplication> selectAdminCaseApplicationListBatch1(CaseApplication caseApplication);
|
||||
|
||||
|
||||
/**
|
||||
* 案件列表查询
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
List<CaseApplication> list(@Param("caseApplication") CaseApplication caseApplication,
|
||||
@Param("caseStatusList") List<Integer> caseStatusList,
|
||||
@Param("roleIds") List<Long> roleIds);
|
||||
|
||||
/**
|
||||
* 查询当前案件节点
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
Integer selectCaseApplicationCaseStatus(@Param("id") Long id);
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
int insert(CaseApplicationDTO caseApplication);
|
||||
int update(CaseApplicationDTO caseApplication);
|
||||
|
||||
}
|
||||
|
||||
@@ -21,11 +21,11 @@ public interface CaseAttachMapper {
|
||||
|
||||
int updateCaseAttachBycaseid(CaseAttach caseAttach);
|
||||
|
||||
int deleteByFileIds(@Param("ids") List<Integer> fileIds);
|
||||
int deleteByFileIds(@Param("ids") List<Long> fileIds);
|
||||
|
||||
List<CaseAttach> getCaseAttachByCaseIdAndType(CaseAttach caseAttach);
|
||||
|
||||
CaseAttach queryAnnexById(Integer annexId);
|
||||
CaseAttach queryAnnexById(@Param("annexId")Long annexId);
|
||||
|
||||
/**
|
||||
* 根据案件id和附件类型删除和上传类型
|
||||
@@ -35,4 +35,18 @@ public interface CaseAttachMapper {
|
||||
void deleteByCasedIdAndType(@Param("caseAppliId")Long caseAppliId,@Param("annexType") int annexType,@Param("isBatchUpload") int isBatchUpload);
|
||||
|
||||
void deleteCaseAttachByCasedIdAndType(@Param("caseAppliId")Long caseAppliId,@Param("annexType") int annexType);
|
||||
|
||||
/**
|
||||
* 删除存在的附件不包括该附件
|
||||
* @param caseId 附件
|
||||
* @param type 附件类型
|
||||
* @param annexId 附件id
|
||||
*/
|
||||
void deleteCaseAttach(@Param("caseId")Long caseId, @Param("type")int type,@Param("annexId") Long annexId);
|
||||
/**
|
||||
* 根据ids查询
|
||||
* @param fileIds
|
||||
* @return
|
||||
*/
|
||||
List<CaseAttach> selectByIds(@Param("ids") List<String> fileIds);
|
||||
}
|
||||
|
||||
@@ -9,8 +9,5 @@ import java.util.List;
|
||||
|
||||
@Mapper
|
||||
public interface CaseEvidenceMapper {
|
||||
List<CaseEvidenceVO> getCaseListByRespondent(@Param(value = "identityNum" ) String identityNum
|
||||
, @Param(value = "caseStatusList") List<Integer> caseStatusList
|
||||
, @Param(value = "identityType" ) Integer identityType
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
@@ -31,4 +31,11 @@ public interface SealSignRecordMapper {
|
||||
void insertSealSignRecord(SealSignRecord sealSignRecord);
|
||||
|
||||
List<CaseApplication> selectsignFlow(@Param("batchNumber") Integer batchNumber,@Param("caseStatus") Integer caseStatus);
|
||||
|
||||
/**
|
||||
* 根据签署流程id查询签署记录
|
||||
* @param signFlowId
|
||||
* @return
|
||||
*/
|
||||
SealSignRecord selectSealByFlowId(@Param("signFlowId") String signFlowId);
|
||||
}
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.SendMailRecord;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface SendMailRecordMapper {
|
||||
int saveSendMailRecord(SendMailRecord sendMailRecord);
|
||||
|
||||
List<SendMailRecord> selectSendMailRecord(SendMailRecord sendMailRecord);
|
||||
|
||||
|
||||
|
||||
}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.sendrecord;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.sendrecord.SendMailRecord;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface SendMailRecordMapper {
|
||||
/**
|
||||
* 新增发送邮件记录
|
||||
*
|
||||
* @param sendMailRecord 发送邮件记录
|
||||
* @return 结果
|
||||
*/
|
||||
|
||||
int saveSendMailRecord(SendMailRecord sendMailRecord);
|
||||
/**
|
||||
* 查询发送邮件记录
|
||||
*
|
||||
* @param sendMailRecord 发送邮件记录
|
||||
* @return 结果
|
||||
*/
|
||||
List<SendMailRecord> selectSendMailRecord(SendMailRecord sendMailRecord);
|
||||
/**
|
||||
* 修改发送邮件记录
|
||||
*
|
||||
* @param sendMailRecord 发送邮件记录
|
||||
* @return 结果
|
||||
*/
|
||||
int updateSendMailRecord(SendMailRecord sendMailRecord);
|
||||
|
||||
/**
|
||||
* 根据id查询发送邮件记录
|
||||
* @param id
|
||||
*/
|
||||
SendMailRecord querySendMailRecordById(Long id);
|
||||
}
|
||||
+11
-2
@@ -1,6 +1,6 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper;
|
||||
package com.ruoyi.wisdomarbitrate.mapper.sendrecord;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.SmsSendRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.sendrecord.SmsSendRecord;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
@@ -19,4 +19,13 @@ public interface SmsRecordMapper {
|
||||
* @return
|
||||
*/
|
||||
int batchSaveSmsSendRecord(@Param("list") List<SmsSendRecord> smsSendRecordList);
|
||||
SmsSendRecord selectBySId(@Param("sid") String sid);
|
||||
void updateStatus (SmsSendRecord smsSendRecord);
|
||||
|
||||
/**
|
||||
* 通过id查询短信发送记录
|
||||
*/
|
||||
SmsSendRecord selectById(@Param("id") Long id);
|
||||
|
||||
void update(SmsSendRecord smsSendRecord);
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.shortmessage;
|
||||
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.shortmessage.MeetingInfo;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
public interface MeetingInfoMapper extends Mapper<MeetingInfo> {
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.shortmessage;
|
||||
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.shortmessage.MsSendMailHistoryRecord;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
public interface MsSendMailHistoryRecordMapper extends Mapper<MsSendMailHistoryRecord> {
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.shortmessage;
|
||||
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.shortmessage.MsSmsSendHistoryRecord;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
public interface MsSmsSendHistoryRecordMapper extends Mapper<MsSmsSendHistoryRecord> {
|
||||
}
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.sms;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsSendHistoryRecordParam;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface MsSmsSendHistoryRecordParamMapper extends Mapper<MsSmsSendHistoryRecordParam> {
|
||||
/**
|
||||
* 批量新增
|
||||
* @param historyRecordParams
|
||||
*/
|
||||
@Select("<script> INSERT INTO sms_send_history_record_param (sms_record_history_id, param_value)\n" +
|
||||
" VALUES\n" +
|
||||
" <foreach item=\"item\" index=\"index\" collection=\"list\" separator=\",\">\n" +
|
||||
" (#{item.smsRecordHistoryId}, #{item.paramValue})\n" +
|
||||
" </foreach> " +
|
||||
"</script>")
|
||||
void batchInsert(@Param("list") List<MsSmsSendHistoryRecordParam> historyRecordParams);
|
||||
}
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.sms;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsSendRecordParam;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface MsSmsSendRecordParamMapper extends Mapper<MsSmsSendRecordParam> {
|
||||
/**
|
||||
* 批量插入
|
||||
* @param list
|
||||
*/
|
||||
@Select("<script> INSERT INTO sms_send_record_param (sms_record_id, param_value)\n" +
|
||||
" VALUES\n" +
|
||||
" <foreach item=\"item\" index=\"index\" collection=\"list\" separator=\",\">\n" +
|
||||
" (#{item.smsRecordId}, #{item.paramValue})\n" +
|
||||
" </foreach> " +
|
||||
"</script>")
|
||||
void batchInsert(@Param("list") List<MsSmsSendRecordParam> list);
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.sms;
|
||||
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsTemplate;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
public interface MsSmsTemplateMapper extends Mapper<MsSmsTemplate> {
|
||||
}
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package com.ruoyi.wisdomarbitrate.mapper.sms;
|
||||
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.sms.MsSmsTemplateParam;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface MsSmsTemplateParamMapper extends Mapper<MsSmsTemplateParam> {
|
||||
@Select("<script> INSERT INTO sms_template_param (sms_template_id, param,param_name)\n" +
|
||||
" VALUES\n" +
|
||||
" <foreach item=\"item\" index=\"index\" collection=\"list\" separator=\",\">\n" +
|
||||
" (#{item.smsTemplateId}, #{item.param}, #{item.paramName})\n" +
|
||||
" </foreach> " +
|
||||
"</script>")
|
||||
void batchInsert(@Param("list") List<MsSmsTemplateParam> templateParams);
|
||||
}
|
||||
+18
-5
@@ -16,19 +16,16 @@ public interface IAdjudicationService {
|
||||
|
||||
AjaxResult sendDocumentByEmail(Long id,String appEmail,String resEmail ,String apptrackingNum,String restrackingNum);
|
||||
|
||||
List<LogisticsInfoVO> getLogisticsInfo(CaseApplication caseApplication);
|
||||
// List<LogisticsInfoVO> getLogisticsInfo(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult signature(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult caseFile( List<Long> ids);
|
||||
|
||||
AjaxResult service(Long id, String appEmail, String resEmail, String apptrackingNum, String restrackingNum);
|
||||
|
||||
AjaxResult stamp(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult getArchivesDetail(Long id);
|
||||
|
||||
AjaxResult regenerationDocument(CaseApplication caseApplication);
|
||||
|
||||
|
||||
/**
|
||||
* 根据案件id查询邮箱
|
||||
@@ -67,4 +64,20 @@ public interface IAdjudicationService {
|
||||
AjaxResult caseFileBatch(Integer batchNumber);
|
||||
|
||||
AjaxResult serviceBatch(Integer batchNumber) throws EsignDemoException, IOException;
|
||||
|
||||
/**
|
||||
* 开庭审理,确定审理结果,生成裁决书
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
AjaxResult caseJudgment(CaseApplication caseApplication);
|
||||
|
||||
/**
|
||||
* 案件状态改变
|
||||
* @param id 案件id
|
||||
* @param caseStatus 案件状态
|
||||
* @return
|
||||
*/
|
||||
|
||||
AjaxResult changeCaseStatus(Long id, Integer caseStatus);
|
||||
}
|
||||
|
||||
+80
-23
@@ -1,12 +1,13 @@
|
||||
package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ColumnValue;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ReservedConferenceVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.SendRoomNoMessageVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ToDoCount;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseApplicationDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.*;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
@@ -15,17 +16,15 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public interface ICaseApplicationService {
|
||||
List<CaseApplication> selectCaseApplicationList(CaseApplication caseApplication);
|
||||
List<CaseApplication> selectCaseApplicationListByRole(CaseApplication caseApplication);
|
||||
|
||||
|
||||
int insertcaseApplication(CaseApplication caseApplication);
|
||||
// int insertcaseApplication(CaseApplication caseApplication);
|
||||
|
||||
int insertcaseApplication1(CaseApplication caseApplication);
|
||||
// int insertcaseApplication1(CaseApplication caseApplication);
|
||||
|
||||
int selectCaseApplicationCount(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult editCaseApplication(CaseApplication caseApplication);
|
||||
// AjaxResult editCaseApplication(CaseApplication caseApplication);
|
||||
|
||||
int submitCaseApplication( List<Long> ids);
|
||||
|
||||
@@ -39,7 +38,7 @@ public interface ICaseApplicationService {
|
||||
|
||||
int pendingAppointArbotrar(CaseApplication caseApplication);
|
||||
|
||||
int pendTralCheck(CaseApplication caseApplication);
|
||||
AjaxResult pendTralCheck(CaseApplication caseApplication);
|
||||
|
||||
int pendTralSure(CaseApplication caseApplication);
|
||||
|
||||
@@ -49,15 +48,13 @@ public interface ICaseApplicationService {
|
||||
|
||||
int submitCaseApplicationCheck(List<Long> ids, Integer agreeOrNotCheck,String caseCheckReject);
|
||||
|
||||
CaseApplication selectCaseApplicationConfirm(CaseApplication caseApplication);
|
||||
|
||||
String sendRoomNoMessage(SendRoomNoMessageVO messageVO);
|
||||
|
||||
SealSignRecord selectSignUrl(CaseApplication caseApplication) throws EsignDemoException;
|
||||
|
||||
SealSignRecord selectSealUrl(CaseApplication caseApplication) throws EsignDemoException;
|
||||
|
||||
AjaxResult creatTrialRecord(ArbitrateRecord arbitrateRecord);
|
||||
|
||||
|
||||
CaseApplication selectSignSealUrl(CaseApplication caseApplication) throws EsignDemoException;
|
||||
|
||||
@@ -79,12 +76,7 @@ public interface ICaseApplicationService {
|
||||
int updateCaseLockStatus(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult uploadZipFile(MultipartFile file, Long id, String username, Long userId);
|
||||
/**
|
||||
* 查询短信发送记录
|
||||
* @param smsSendRecord
|
||||
* @return
|
||||
*/
|
||||
List<SmsSendRecord> getSmsSendRecord(SmsSendRecord smsSendRecord);
|
||||
|
||||
|
||||
/**
|
||||
* 获取userSign
|
||||
@@ -116,7 +108,7 @@ public interface ICaseApplicationService {
|
||||
|
||||
AjaxResult deleteRoom( String roomId);
|
||||
|
||||
AjaxResult uploadCaseZipFile(MultipartFile file,Long templateId);
|
||||
AjaxResult uploadCaseZipFile(MultipartFile file,Long templateId,Integer applicantType,Integer resType);
|
||||
|
||||
/**
|
||||
* 根据附件id修改案件id
|
||||
@@ -138,11 +130,13 @@ public interface ICaseApplicationService {
|
||||
|
||||
CaseAttach downloadCaseZipFile(CaseApplication caseApplication);
|
||||
|
||||
List<CaseApplication> selectCaseApplicationListBatchByRole(CaseApplication caseApplication);
|
||||
// List<CaseApplication> selectCaseApplicationListBatchByRole(CaseApplication caseApplication);
|
||||
public List<CaseApplication> page(CaseApplication caseApplication) ;
|
||||
|
||||
int submitCaseApplicationBatch(String batchNumber);
|
||||
|
||||
int submitCaseApplicationCheckBatch(String batchNumber, Integer agreeOrNotCheck, String caseCheckReject);
|
||||
AjaxResult submitCaseApplicationBatch(String batchNumber);
|
||||
|
||||
AjaxResult submitCaseApplicationCheckBatch(String batchNumber, Integer agreeOrNotCheck, String caseCheckReject);
|
||||
|
||||
int pendTralCheckBatch(CaseApplication caseApplication);
|
||||
|
||||
@@ -153,4 +147,67 @@ public interface ICaseApplicationService {
|
||||
AjaxResult arbitratorCheckArbitrateRecordBatch(CaseApplication caseApplication);
|
||||
|
||||
AjaxResult checkArbitrateRecordBatch(CaseApplication caseApplication);
|
||||
/**
|
||||
* 附件上传到onlyoffice服务器
|
||||
* @param annexPath
|
||||
*/
|
||||
JSONArray uploadOnlyOffice(String annexPath, Long id);
|
||||
/**
|
||||
* 保存onlyOffice在线编辑的文件
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
|
||||
AjaxResult saveOnlyOfficeFile(CaseAttach caseAttach);
|
||||
|
||||
/**
|
||||
* 新增或编辑
|
||||
* @param caseApplication
|
||||
* @return
|
||||
*/
|
||||
|
||||
AjaxResult insertOrUpdate(CaseApplicationDTO caseApplication);
|
||||
|
||||
/**
|
||||
* 设置案件相关信息
|
||||
* @param caseApplication
|
||||
* @param affiliate
|
||||
* @param groupOrder 组别
|
||||
* @param operatorCount 操作人数量
|
||||
* @param updateFlag 是否修改案件
|
||||
*/
|
||||
public int setCaseAfflicate(List<CaseAffiliateEntity> affliates,CaseApplicationDTO caseApplication, CaseAffiliateEntity affiliate, int groupOrder, int operatorCount, boolean updateFlag);
|
||||
|
||||
/**
|
||||
* 新增案件
|
||||
* @param caseApplication
|
||||
*/
|
||||
void insert(CaseApplicationDTO caseApplication);
|
||||
|
||||
/**
|
||||
* 修改案件
|
||||
* @param caseApplication
|
||||
*/
|
||||
|
||||
void update(CaseApplicationDTO caseApplication);
|
||||
/**
|
||||
* 新增案件相关人员信息
|
||||
* @param affiliate 相关人员信息
|
||||
* @param roleIdList 角色id
|
||||
* @param updateFlag 是否修改案件
|
||||
|
||||
*/
|
||||
public void insertAfficateUser(CaseAffiliateEntity affiliate, List<Long> roleIdList,boolean updateFlag,List<CaseAffiliateEntity> affiliateEntities);
|
||||
|
||||
void insertCaseAfflicate(CaseAffiliateVO caseAffiliateVO, List<CaseAffiliateEntity> affliates,CaseApplicationDTO caseApplicationm,boolean updateFlag);
|
||||
|
||||
/**
|
||||
* 根据案件id查询相关人员
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
|
||||
List<CaseAffiliateEntity> selectAfflicatesByCaseId(Long id);
|
||||
|
||||
SysUser getUserInfo();
|
||||
}
|
||||
|
||||
+3
-3
@@ -13,11 +13,11 @@ import java.util.List;
|
||||
|
||||
public interface ICaseEvidenceService {
|
||||
|
||||
AjaxResult getCaseDetailsById(Long id,String userName);
|
||||
// AjaxResult getCaseDetailsById(Long id,String userName);
|
||||
|
||||
AjaxResult uploadEvidence(MultipartFile file, Integer annexType, Long id,String userName,Long userId);
|
||||
|
||||
List<CaseEvidenceVO> getCaseListAll(Integer caseStatus);
|
||||
// List<CaseEvidenceVO> getCaseListAll(Integer caseStatus);
|
||||
|
||||
AjaxResult evidenceConfirmation(CaseApplication caseApplication);
|
||||
|
||||
@@ -36,7 +36,7 @@ public interface ICaseEvidenceService {
|
||||
|
||||
AjaxResult fileList(Long caseAppliId, List<Integer> annexTypeList);
|
||||
|
||||
int deleteFile( List<Integer> fileIds);
|
||||
int deleteFile( List<Long> fileIds);
|
||||
|
||||
List<CaseEvidenceDirectoryVO> selectEvidenceTreeList(CaseEvidenceDirectory caseEvidenceDirectory);
|
||||
|
||||
|
||||
+2
-1
@@ -2,6 +2,7 @@ package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.dto.PayRequest;
|
||||
import com.ruoyi.wisdomarbitrate.domain.BatchCaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseConfirmPayDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CasePayDTO;
|
||||
@@ -14,7 +15,7 @@ public interface ICasePaymentService {
|
||||
*/
|
||||
AjaxResult casePay(CasePayDTO casePayDTO);
|
||||
|
||||
AjaxResult confirmPayment( List<Long> ids);
|
||||
AjaxResult confirmPayment(BatchCaseApplication batchCaseApplication);
|
||||
|
||||
/**
|
||||
* 确认缴费
|
||||
|
||||
-15
@@ -1,15 +0,0 @@
|
||||
package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.ruoyi.wisdomarbitrate.domain.SendMailRecord;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface ISendMailRecordService {
|
||||
|
||||
|
||||
List<SendMailRecord> selectSendMailRecordList(SendMailRecord sendMailRecord);
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
package com.ruoyi.wisdomarbitrate.service;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
public interface MsSignSealService {
|
||||
AjaxResult signSeaalCaseApplicaCallback(String reqbodystr) throws EsignDemoException, IOException;
|
||||
|
||||
AjaxResult sealCheckCallback(String reqbodystr) throws EsignDemoException, IOException;
|
||||
}
|
||||
@@ -39,7 +39,7 @@ public interface VideoService {
|
||||
* @param userId
|
||||
* @return
|
||||
*/
|
||||
AjaxResult secretaryRoleByUserId(Long userId);
|
||||
AjaxResult secretaryRoleByUserId(Long userId,Long caseId);
|
||||
|
||||
/**
|
||||
* 根据html字符串转pdf并和案件关联
|
||||
@@ -55,4 +55,5 @@ public interface VideoService {
|
||||
* @return
|
||||
*/
|
||||
AjaxResult attachListByCaseId(Long caseAppliId, Integer annexType);
|
||||
AjaxResult selectRoleMenuByCaseId(Long caseId);
|
||||
}
|
||||
|
||||
+533
-835
File diff suppressed because it is too large
Load Diff
+74
-101
@@ -3,15 +3,14 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
import com.ruoyi.common.enums.UpdateSubmitStatus;
|
||||
import com.ruoyi.common.enums.YesOrNoEnum;
|
||||
import com.ruoyi.common.utils.ObjectFieldUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sendrecord.SmsRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.domain.SmsSendRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ColumnValue;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CompareCaseVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.UpdateSubmitVO;
|
||||
@@ -210,30 +209,11 @@ public class CaseApplicationLogServiceImpl implements CaseApplicationLogService
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
request.setTemplateId("1996949");
|
||||
request.setPhone(caseAffiliate.getContactTelphone());
|
||||
request.setTemplateParamSet(new String[]{caseAffiliate.getName(), logCase.getCaseNum(),vo.getReason()});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseAffiliate.getCaseAppliId());
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(caseAffiliate.getCaseAppliId());
|
||||
caseApplication = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
smsSendRecord.setCaseNum(caseApplication.getCaseNum());
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
// 1996949 审核案件结果通知 尊敬的{1}用户,您的{2}仲裁案件,审核未通过,理由为{3},请知晓,如非本人操作,请忽略本短信
|
||||
String content = "尊敬的" + caseAffiliate.getName() + ",您的"+logCase.getCaseNum()+"仲裁案件,审核未通过,理由为"+vo.getReason()+",请知晓,如非本人操作,请忽略本短信。";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean) {
|
||||
smsSendRecord.setSendStatus(1);
|
||||
} else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
|
||||
SmsUtils.sendSms(caseApplication, "1996949", caseAffiliate.getContactTelphone(), new String[]{caseAffiliate.getName(),caseApplication.getCaseNum(),vo.getReason()});
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
@@ -247,7 +227,7 @@ public class CaseApplicationLogServiceImpl implements CaseApplicationLogService
|
||||
CaseApplication beforeCase = caseApplicationService.selectCaseApplication(caseApplication);
|
||||
|
||||
// 查询案件关联人员
|
||||
afterCase.setCaseAffiliates(caseAffiliateLogMapper.selectCaseAffiliate(afterCase.getCaseLogId()));
|
||||
// afterCase.setAffiliate(caseAffiliateLogMapper.selectCaseAffiliate(afterCase.getCaseLogId()));
|
||||
// 查询自定义字段表
|
||||
afterCase.setColumnValues(columnValueLogMapper.listBycaseAppliLogId(afterCase.getCaseLogId()));
|
||||
// 查询附件
|
||||
@@ -259,17 +239,10 @@ public class CaseApplicationLogServiceImpl implements CaseApplicationLogService
|
||||
List<CaseAttach> afterAttachList = caseAttachLogMapper.getCaseAttachByCaseIdAndType(caseAttach);
|
||||
if (CollectionUtil.isNotEmpty(afterAttachList)) {
|
||||
for (CaseAttach attach : afterAttachList) {
|
||||
String annexName = attach.getAnnexName();
|
||||
String prefix = "/profile";
|
||||
int startIndex = annexName.indexOf(prefix);
|
||||
startIndex += prefix.length();
|
||||
String annexPath = "/uploadPath" + annexName.substring(startIndex);
|
||||
attach.setAnnexPath(annexPath);
|
||||
int startIndexnew = annexName.lastIndexOf("/");
|
||||
if (startIndexnew != -1) {
|
||||
String annexNamenew = annexName.substring(startIndexnew + 1);
|
||||
attach.setAnnexName(annexNamenew);
|
||||
}
|
||||
String path = attach.getAnnexPath()==null?"":attach.getAnnexPath();
|
||||
attach.setAnnexPath(path);
|
||||
attach.setAnnexName(attach.getAnnexName());
|
||||
|
||||
}
|
||||
afterCase.setCaseAttachList(afterAttachList);
|
||||
}
|
||||
@@ -299,7 +272,7 @@ public class CaseApplicationLogServiceImpl implements CaseApplicationLogService
|
||||
|
||||
}
|
||||
// 对比案件人员字段
|
||||
compareAffilate(beforeCase, afterCase);
|
||||
// compareAffilate(beforeCase, afterCase);
|
||||
// 对比申请人证据资料
|
||||
compareCaseVO.setChangeColumn(compareApplicantFile(beforeCase, afterCase, changeColumn).toString());
|
||||
// 对比自定义字段
|
||||
@@ -385,70 +358,70 @@ public class CaseApplicationLogServiceImpl implements CaseApplicationLogService
|
||||
* @param beforeCase
|
||||
* @param afterCase
|
||||
*/
|
||||
private void compareAffilate(CaseApplication beforeCase, CaseApplication afterCase) {
|
||||
// 对比人员字段
|
||||
List<CaseAffiliate> beforeCaseCaseAffiliates = beforeCase.getCaseAffiliates();
|
||||
List<CaseAffiliate> afterCaseCaseAffiliates = afterCase.getCaseAffiliates();
|
||||
Map<Integer, CaseAffiliate> beforeCaseCaseAffiliateMap = null;
|
||||
if (CollectionUtil.isNotEmpty(beforeCaseCaseAffiliates)) {
|
||||
// 转为map
|
||||
beforeCaseCaseAffiliateMap = beforeCaseCaseAffiliates.stream().collect(Collectors.toMap(CaseAffiliate::getIdentityType, v -> v, (n1, n2) -> n2));
|
||||
}
|
||||
StringBuilder affiliateChangeColumn;
|
||||
// 如果上一个版本和现版本有一个为空,那么所有字段都修改
|
||||
if (beforeCaseCaseAffiliates != null && afterCaseCaseAffiliates == null) {
|
||||
affiliateChangeColumn = new StringBuilder();
|
||||
for (String column : affiliateColumns) {
|
||||
|
||||
affiliateChangeColumn.append(column).append(",");
|
||||
}
|
||||
|
||||
} else if (beforeCaseCaseAffiliates == null && afterCaseCaseAffiliates != null) {
|
||||
affiliateChangeColumn = new StringBuilder();
|
||||
for (String column : affiliateColumns) {
|
||||
|
||||
affiliateChangeColumn.append(column).append(",");
|
||||
}
|
||||
} else if (beforeCaseCaseAffiliates != null && afterCaseCaseAffiliates != null) {
|
||||
for (CaseAffiliate afterCaseCaseAffiliate : afterCaseCaseAffiliates) {
|
||||
// 找到相同身份类型的数据,进行对比
|
||||
affiliateChangeColumn = new StringBuilder();
|
||||
int identityType = afterCaseCaseAffiliate.getIdentityType();
|
||||
if (beforeCaseCaseAffiliateMap != null && beforeCaseCaseAffiliateMap.containsKey(identityType)) {
|
||||
CaseAffiliate beforeCaseCaseAffiliate = beforeCaseCaseAffiliateMap.get(identityType);
|
||||
for (String column : affiliateColumns) {
|
||||
String beforeValue = ObjectFieldUtils.getValue(beforeCaseCaseAffiliate, column);
|
||||
String afterValue = ObjectFieldUtils.getValue(afterCaseCaseAffiliate, column);
|
||||
if (StrUtil.isEmpty(beforeValue) && StrUtil.isNotEmpty(afterValue)) {
|
||||
affiliateChangeColumn.append(column).append(",");
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isNotEmpty(beforeValue) && StrUtil.isEmpty(afterValue)) {
|
||||
affiliateChangeColumn.append(column).append(",");
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isNotEmpty(beforeValue) && StrUtil.isNotEmpty(afterValue) && !Objects.equals(beforeValue, afterValue)) {
|
||||
affiliateChangeColumn.append(column).append(",");
|
||||
continue;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
for (String column : affiliateColumns) {
|
||||
|
||||
affiliateChangeColumn.append(column).append(",");
|
||||
}
|
||||
}
|
||||
afterCaseCaseAffiliate.setChangeColumn(affiliateChangeColumn.toString());
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
// private void compareAffilate(CaseApplication beforeCase, CaseApplication afterCase) {
|
||||
// // 对比人员字段
|
||||
// List<CaseAffiliate> beforeCaseCaseAffiliates = beforeCase.getCaseAffiliates();
|
||||
// List<CaseAffiliate> afterCaseCaseAffiliates = afterCase.getCaseAffiliates();
|
||||
// Map<Integer, CaseAffiliate> beforeCaseCaseAffiliateMap = null;
|
||||
// if (CollectionUtil.isNotEmpty(beforeCaseCaseAffiliates)) {
|
||||
// // 转为map
|
||||
// beforeCaseCaseAffiliateMap = beforeCaseCaseAffiliates.stream().collect(Collectors.toMap(CaseAffiliate::getIdentityType, v -> v, (n1, n2) -> n2));
|
||||
// }
|
||||
// StringBuilder affiliateChangeColumn;
|
||||
// // 如果上一个版本和现版本有一个为空,那么所有字段都修改
|
||||
// if (beforeCaseCaseAffiliates != null && afterCaseCaseAffiliates == null) {
|
||||
// affiliateChangeColumn = new StringBuilder();
|
||||
// for (String column : affiliateColumns) {
|
||||
//
|
||||
// affiliateChangeColumn.append(column).append(",");
|
||||
// }
|
||||
//
|
||||
// } else if (beforeCaseCaseAffiliates == null && afterCaseCaseAffiliates != null) {
|
||||
// affiliateChangeColumn = new StringBuilder();
|
||||
// for (String column : affiliateColumns) {
|
||||
//
|
||||
// affiliateChangeColumn.append(column).append(",");
|
||||
// }
|
||||
// } else if (beforeCaseCaseAffiliates != null && afterCaseCaseAffiliates != null) {
|
||||
// for (CaseAffiliate afterCaseCaseAffiliate : afterCaseCaseAffiliates) {
|
||||
// // 找到相同身份类型的数据,进行对比
|
||||
// affiliateChangeColumn = new StringBuilder();
|
||||
// int identityType = afterCaseCaseAffiliate.getIdentityType();
|
||||
// if (beforeCaseCaseAffiliateMap != null && beforeCaseCaseAffiliateMap.containsKey(identityType)) {
|
||||
// CaseAffiliate beforeCaseCaseAffiliate = beforeCaseCaseAffiliateMap.get(identityType);
|
||||
// for (String column : affiliateColumns) {
|
||||
// String beforeValue = ObjectFieldUtils.getValue(beforeCaseCaseAffiliate, column);
|
||||
// String afterValue = ObjectFieldUtils.getValue(afterCaseCaseAffiliate, column);
|
||||
// if (StrUtil.isEmpty(beforeValue) && StrUtil.isNotEmpty(afterValue)) {
|
||||
// affiliateChangeColumn.append(column).append(",");
|
||||
// continue;
|
||||
// }
|
||||
// if (StrUtil.isNotEmpty(beforeValue) && StrUtil.isEmpty(afterValue)) {
|
||||
// affiliateChangeColumn.append(column).append(",");
|
||||
// continue;
|
||||
// }
|
||||
// if (StrUtil.isNotEmpty(beforeValue) && StrUtil.isNotEmpty(afterValue) && !Objects.equals(beforeValue, afterValue)) {
|
||||
// affiliateChangeColumn.append(column).append(",");
|
||||
// continue;
|
||||
//
|
||||
// }
|
||||
//
|
||||
// }
|
||||
//
|
||||
//
|
||||
// } else {
|
||||
// for (String column : affiliateColumns) {
|
||||
//
|
||||
// affiliateChangeColumn.append(column).append(",");
|
||||
// }
|
||||
// }
|
||||
// afterCaseCaseAffiliate.setChangeColumn(affiliateChangeColumn.toString());
|
||||
//
|
||||
// }
|
||||
//
|
||||
//
|
||||
// }
|
||||
// }
|
||||
|
||||
/**
|
||||
* 同意撤销
|
||||
|
||||
+1986
-2116
File diff suppressed because it is too large
Load Diff
+47
-440
@@ -1,37 +1,24 @@
|
||||
package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import com.deepoove.poi.data.PictureRenderData;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.redis.RedisCache;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.WordUtil;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sendrecord.SmsRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.IAdjudicationService;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseArbitrateService;
|
||||
import org.apache.poi.xwpf.usermodel.XWPFDocument;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.StandardCopyOption;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.time.LocalDate;
|
||||
import java.time.ZoneId;
|
||||
import java.util.*;
|
||||
import java.util.function.Function;
|
||||
import java.util.regex.Pattern;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||
@@ -56,6 +43,8 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
private RedisCache redisCache;
|
||||
@Autowired
|
||||
private ICaseApplicationService caseApplicationService;
|
||||
@Autowired
|
||||
private ICaseArbitrateService caseArbitrateService;
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
@@ -65,7 +54,11 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
if (caseApplication1 == null) {
|
||||
return AjaxResult.success();
|
||||
}
|
||||
// Integer currentStatus = caseApplication1.getCaseStatus();
|
||||
Integer arbitratMethodOriral = caseApplication.getArbitratMethod();
|
||||
if (arbitratMethodOriral == null) {
|
||||
return AjaxResult.error("请选择仲裁方式");
|
||||
}
|
||||
|
||||
String caseNum = caseApplication1.getCaseNum();
|
||||
if (opinion == 0) { //拒绝
|
||||
@@ -76,50 +69,41 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
//修改案件状态为待修改开庭时间
|
||||
// caseApplication1.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.MODIFY_HEARDATE, "");
|
||||
|
||||
|
||||
} else {
|
||||
caseApplication1.setArbitratMethod(2);
|
||||
//修改案件状态为待书面审理
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_WRIITEN_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_WRIITEN_HEAR, "");
|
||||
|
||||
|
||||
}
|
||||
} else if (opinion == 1 ) {
|
||||
} else if (opinion == 1) {
|
||||
if (arbitratMethodOriral == 2) {
|
||||
//修改案件状态为待书面审理
|
||||
caseApplication1.setArbitratMethod(2);
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_WRIITEN_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_WRIITEN_HEAR, "");
|
||||
|
||||
|
||||
} else {
|
||||
//修改案件状态为待修改开庭时间
|
||||
caseApplication1.setArbitratMethod(1);
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
|
||||
//修改案件状态为待修改开庭时间
|
||||
// caseApplication1.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.MODIFY_HEARDATE, "");
|
||||
|
||||
|
||||
}
|
||||
}else if (opinion == 2) {
|
||||
} else if (opinion == 2) {
|
||||
if (arbitratMethodNow == 2) {
|
||||
//修改案件状态为待书面审理
|
||||
caseApplication1.setArbitratMethod(2);
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_WRIITEN_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_WRIITEN_HEAR, "");
|
||||
|
||||
|
||||
} else {
|
||||
//修改案件状态为待修改开庭时间
|
||||
caseApplication1.setArbitratMethod(1);
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
|
||||
//修改案件状态为待修改开庭时间
|
||||
// caseApplication1.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.MODIFY_HEARDATE, "");
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@@ -127,41 +111,26 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
if (i > 0) {
|
||||
String arbitratMethodStr = caseApplication1.getArbitratMethod() == 1 ? "开庭审理" : "书面审理";
|
||||
//发送短信通知
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(caseApplication1.getId());
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate); //获取案件关联人信息
|
||||
//获取案件关联人信息
|
||||
List<CaseAffiliateEntity> caseAffiliates = caseApplicationService.selectAfflicatesByCaseId(caseApplication1.getId());
|
||||
if (caseAffiliates != null && caseAffiliates.size() > 0) {
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
request.setTemplateId("1931000");
|
||||
request.setPhone(affiliate.getContactTelphone());
|
||||
// 这个值,要看你的模板中是否预留了占位符,如果没有则不需要设置
|
||||
// 1931000 尊敬的{1}用户,您的{2}仲裁案件,仲裁方式已确定为{3},请知晓,如非本人操作,请忽略本短信。
|
||||
String name = affiliate.getName();
|
||||
request.setTemplateParamSet(new String[]{name, caseNum, arbitratMethodStr});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplication.getId());
|
||||
smsSendRecord.setCaseNum(caseApplication1.getCaseNum());
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + name + "用户,您的" + caseNum + "仲裁案件,仲裁方式已确定为" + arbitratMethodStr + ",请知晓,如非本人操作,请忽略本短信。";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean){
|
||||
smsSendRecord.setSendStatus(1);
|
||||
}else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
ArrayList<CaseAffiliateEntity> operatorList = new ArrayList<>();
|
||||
// 申请操作人
|
||||
Optional<CaseAffiliateEntity> applicantAffiliateOpt = caseAffiliates.stream().filter(affiliate -> affiliate.getOperatorFlag() == 1 && StrUtil.isNotEmpty(affiliate.getPhone()) && (affiliate.getRoleType().equals(1) || affiliate.getRoleType().equals(2))).findFirst();
|
||||
// 被申请操作人
|
||||
Optional<CaseAffiliateEntity> resAffiliateOpt = caseAffiliates.stream().filter(affiliate -> affiliate.getOperatorFlag() == 1 && StrUtil.isNotEmpty(affiliate.getPhone()) && (affiliate.getRoleType().equals(3) || affiliate.getRoleType().equals(4))).findFirst();
|
||||
if (!applicantAffiliateOpt.isPresent() || !resAffiliateOpt.isPresent()) {
|
||||
throw new ServiceException("未找到案件操作人员");
|
||||
}
|
||||
operatorList.add(applicantAffiliateOpt.get());
|
||||
operatorList.add(resAffiliateOpt.get());
|
||||
for (CaseAffiliateEntity affiliate : operatorList) {
|
||||
SmsUtils.sendSms(caseApplication1, "1931000", affiliate.getPhone(), new String[]{affiliate.getName(),caseApplication1.getCaseNum(),arbitratMethodStr});
|
||||
}
|
||||
}
|
||||
|
||||
return AjaxResult.success("审核成功");
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.CHECK_ARBITRATION_METHOD, "");
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
@@ -173,67 +142,13 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
caseApplicationsel.setCaseStatus(CaseApplicationConstants.CHECK_ARBITRATION_METHOD);
|
||||
List<CaseApplication> caseApplications1 = caseApplicationMapper.listCaseApplicationByBatchNumber(caseApplicationsel);
|
||||
if (caseApplications1 != null && caseApplications1.size() > 0) {
|
||||
for(CaseApplication caseApplicationse:caseApplications1){
|
||||
String caseNum = caseApplicationse.getCaseNum();
|
||||
Integer arbitratMethod = caseApplication.getArbitratMethod();
|
||||
if (arbitratMethod == 1) {
|
||||
caseApplicationse.setArbitratMethod(1);
|
||||
caseApplicationse.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.MODIFY_HEARDATE, "");
|
||||
|
||||
}else if (arbitratMethod == 2) {
|
||||
//修改案件状态为待书面审理
|
||||
caseApplicationse.setArbitratMethod(2);
|
||||
caseApplicationse.setCaseStatus(CaseApplicationConstants.PENDING_WRIITEN_HEAR);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_WRIITEN_HEAR, "");
|
||||
|
||||
}
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplicationse);
|
||||
|
||||
if (i > 0) {
|
||||
String arbitratMethodStr = caseApplicationse.getArbitratMethod() == 1 ? "开庭审理" : "书面审理";
|
||||
//发送短信通知
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(caseApplicationse.getId());
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate); //获取案件关联人信息
|
||||
if (caseAffiliates != null && caseAffiliates.size() > 0) {
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
request.setTemplateId("1931000");
|
||||
request.setPhone(affiliate.getContactTelphone());
|
||||
// 这个值,要看你的模板中是否预留了占位符,如果没有则不需要设置
|
||||
// 1931000 尊敬的{1}用户,您的{2}仲裁案件,仲裁方式已确定为{3},请知晓,如非本人操作,请忽略本短信。
|
||||
String name = affiliate.getName();
|
||||
request.setTemplateParamSet(new String[]{name, caseNum, arbitratMethodStr});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplicationse.getId());
|
||||
smsSendRecord.setCaseNum(caseApplicationse.getCaseNum());
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + name + "用户,您的" + caseNum + "仲裁案件,仲裁方式已确定为" + arbitratMethodStr + ",请知晓,如非本人操作,请忽略本短信。";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean){
|
||||
smsSendRecord.setSendStatus(1);
|
||||
}else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
for (CaseApplication caseApplicationse : caseApplications1) {
|
||||
caseArbitrateService.examineArbitrateMethod(caseApplicationse, caseApplication.getOpinion(), caseApplication.getArbitratMethod());
|
||||
}
|
||||
|
||||
}else{
|
||||
} else {
|
||||
throw new ServiceException("这个批号没有批量审核仲裁方式的案件");
|
||||
}
|
||||
|
||||
@@ -255,13 +170,8 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
caseApplication.setId(caseId);
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
//案件日志表里添加数据
|
||||
CaseLogRecord caseLogRecord = new CaseLogRecord();
|
||||
caseLogRecord.setCaseAppliId(caseApplication1.getId());
|
||||
caseLogRecord.setCaseNode(caseApplication1.getCaseStatus());
|
||||
caseLogRecord.setCreateBy(getUsername());
|
||||
caseLogRecordMapper.insertCaseLogRecord(caseLogRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.VERPRIF_ARBITRATION, "");
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_WRIITEN_HEAR, "");
|
||||
|
||||
// 生成裁决书
|
||||
CaseApplication application = new CaseApplication();
|
||||
@@ -273,7 +183,7 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
|
||||
}
|
||||
|
||||
}else{
|
||||
} else {
|
||||
throw new ServiceException("这个批号没有批量书面审理的案件");
|
||||
}
|
||||
return AjaxResult.success();
|
||||
@@ -283,7 +193,7 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
@Override
|
||||
@Transactional
|
||||
public AjaxResult writtenHear(CaseIds caseIds) {
|
||||
if (caseIds!=null){
|
||||
if (caseIds != null) {
|
||||
List<Long> ids = caseIds.getIds();
|
||||
for (Long caseId : ids) {
|
||||
//查询案件详情
|
||||
@@ -296,331 +206,28 @@ public class CaseArbitrateServiceImpl implements ICaseArbitrateService {
|
||||
ArbitrateRecord arbitrateRecord1 = arbitrateRecordMapper.selectArbitrateRecord(arbitrateRecord);
|
||||
if (arbitrateRecord1 != null) {
|
||||
int i = arbitrateRecordMapper.updataArbitrateRecord(arbitrateRecord);
|
||||
if (i > 0) {
|
||||
//案件日志表里添加数据
|
||||
CaseLogRecord caseLogRecord = new CaseLogRecord();
|
||||
caseLogRecord.setCaseAppliId(caseApplication1.getId());
|
||||
caseLogRecord.setCaseNode(caseApplication1.getCaseStatus());
|
||||
caseLogRecord.setCreateBy(getUsername());
|
||||
caseLogRecordMapper.insertCaseLogRecord(caseLogRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.GENERATED_ARBITRATION, "");
|
||||
|
||||
}
|
||||
} else {
|
||||
//提交仲裁结果
|
||||
int i = arbitrateRecordMapper.insertArbitrateRecord(arbitrateRecord);
|
||||
if (i > 0) {
|
||||
//案件日志表里添加数据
|
||||
CaseLogRecord caseLogRecord = new CaseLogRecord();
|
||||
caseLogRecord.setCaseAppliId(caseApplication1.getId());
|
||||
caseLogRecord.setCaseNode(caseApplication1.getCaseStatus());
|
||||
caseLogRecord.setCreateBy(getUsername());
|
||||
caseLogRecordMapper.insertCaseLogRecord(caseLogRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.GENERATED_ARBITRATION, "");
|
||||
}
|
||||
}
|
||||
// 生成裁决书
|
||||
CaseApplication application = new CaseApplication();
|
||||
application.setId(caseId);
|
||||
adjudicationService.createDocument(application);
|
||||
//修改案件状态
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.VERPRIF_ARBITRATION);
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
|
||||
//修改案件状态
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.VERPRIF_ARBITRATION);
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_WRIITEN_HEAR, "");
|
||||
}
|
||||
|
||||
|
||||
return AjaxResult.success("审理成功");
|
||||
}
|
||||
return AjaxResult.error("请检查参数");
|
||||
}
|
||||
|
||||
//生成仲裁文书
|
||||
private Boolean generateAward(Long id) {
|
||||
try {
|
||||
Map<String, Object> datas = new HashMap<>();
|
||||
if (id == null) {
|
||||
return null;
|
||||
}
|
||||
//获取案件详细信息
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(id);
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
//生成编码
|
||||
String equipmentNo = getNewEquipmentNo();
|
||||
datas.put("num", equipmentNo);
|
||||
//获取仲裁记录表里的相关信息
|
||||
ArbitrateRecord arbitrateRecord = new ArbitrateRecord();
|
||||
arbitrateRecord.setCaseAppliId(id);
|
||||
ArbitrateRecord arbitrateRecord1 = arbitrateRecordMapper.selectArbitrateRecord(arbitrateRecord);
|
||||
//获取案件关联人信息
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(id);
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
List<String> nameAgentList = new ArrayList<>();
|
||||
if (caseAffiliates != null && caseAffiliates.size() > 0) {
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
//获取身份类型
|
||||
int identityType = affiliate.getIdentityType();
|
||||
if (identityType == 1) { //申请人
|
||||
datas.put("appName", affiliate.getName());
|
||||
datas.put("appAddress", affiliate.getResidenAffili());
|
||||
datas.put("appContactAddress", affiliate.getContactAddress());
|
||||
datas.put("appLegalPerson", affiliate.getCompLegalPerson());
|
||||
datas.put("appLegalPersonTitle", affiliate.getCompLegalperPost());
|
||||
datas.put("appAgentName", affiliate.getNameAgent());
|
||||
datas.put("appAgentTitle", affiliate.getAppliAgentTitle());
|
||||
nameAgentList.add(affiliate.getNameAgent());
|
||||
} else if (identityType == 2) { //被申请人
|
||||
datas.put("resName", affiliate.getName());
|
||||
datas.put("resAddress", affiliate.getResidenAffili());
|
||||
String responSex = affiliate.getResponSex();
|
||||
if (responSex.equals("0")) {
|
||||
datas.put("resSex", "男");
|
||||
} else if (responSex.equals("1")){
|
||||
datas.put("resSex", "女");
|
||||
}else {
|
||||
datas.put("resSex", "未知");
|
||||
}
|
||||
Date responBirth = affiliate.getResponBirth();
|
||||
if (responBirth != null) {
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
String responBirthStr = sdf.format(responBirth);
|
||||
datas.put("resDateOfBirth", responBirthStr);
|
||||
|
||||
}
|
||||
|
||||
datas.put("resContactAddress", affiliate.getContactAddress());
|
||||
nameAgentList.add(affiliate.getNameAgent());
|
||||
}
|
||||
}
|
||||
}
|
||||
Date createTime = caseApplication1.getCreateTime();
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||
// 将日期格式化为字符串
|
||||
String createTimeStr = sdf.format(createTime);
|
||||
datas.put("submissionDate", createTimeStr);
|
||||
Date registerDate = caseApplication1.getRegisterDate();
|
||||
String registerDateStr = sdf.format(registerDate);
|
||||
datas.put("acceptDate", registerDateStr);
|
||||
//反请求
|
||||
Integer adjudicaCounter = caseApplication1.getAdjudicaCounter();
|
||||
String counterclaim = "在《2022年版仲裁规则》第十八条第(一)项规定的期限内,被申请人向秘书处提交了" +
|
||||
"《仲裁反请求申请书》及证据材料。仲裁委依据《2022年版仲裁规则》第十八条的规定受理了该仲裁反请求案申请。" +
|
||||
"仲裁反请求案件受理后,秘书处向被申请人发送了仲裁反请求通知书及附件,向申请人发送了仲裁反请求通知书及附件、仲裁反请求申请书及附件。";
|
||||
if (adjudicaCounter == null) {
|
||||
datas.put("counterclaim", null);
|
||||
} else if (adjudicaCounter == 1) {
|
||||
datas.put("counterclaim", counterclaim);
|
||||
} else {
|
||||
datas.put("counterclaim", null);
|
||||
}
|
||||
//财产保全
|
||||
Integer properPreser = caseApplication1.getProperPreser();
|
||||
String preservation = "本案受理后,申请人向仲裁委提交了财产保全申请,仲裁委根据《中华人民共和国仲裁法》" +
|
||||
"第二十八条之规定,将该申请提交至法院。";
|
||||
if (properPreser == null) {
|
||||
datas.put("preservation", null);
|
||||
} else if (properPreser == 1) {
|
||||
datas.put("preservation", preservation);
|
||||
} else {
|
||||
datas.put("preservation", null);
|
||||
}
|
||||
//管辖权异议
|
||||
Integer objectiJuris = caseApplication1.getObjectiJuris();
|
||||
String jurisdictionalObjection = "本案受理后,被申请人向仲裁委提交了《XX管辖异议申请书》,认为XXXXXX" +
|
||||
",仲裁委经审理,当庭驳回了被申请人的管辖异议申请,并告知被申请人具体的事实和理由将在裁决书中一并列明。";
|
||||
if (objectiJuris == null) {
|
||||
datas.put("jurisdictionalObjection", null);
|
||||
} else if (objectiJuris == 1) {
|
||||
datas.put("jurisdictionalObjection", jurisdictionalObjection);
|
||||
} else {
|
||||
datas.put("jurisdictionalObjection", null);
|
||||
}
|
||||
String arbitratorName = caseApplication1.getArbitratorName();
|
||||
datas.put("arbitratorName", arbitratorName);
|
||||
Integer arbitratMethod = caseApplication1.getArbitratMethod();
|
||||
Date hearDate = caseApplication1.getHearDate();
|
||||
if (hearDate != null) {
|
||||
String hearDateStr = sdf.format(hearDate);
|
||||
//线上开庭时
|
||||
if (arbitratMethod == 1) {
|
||||
String onLine1 = "仲裁庭审阅了申请人提交的仲裁申请书、证据材料后,于";
|
||||
String onLine2 = "通过仲裁委智慧仲裁平台开庭审理了本案。";
|
||||
datas.put("onLine1", onLine1);
|
||||
datas.put("hearDate", hearDateStr);
|
||||
datas.put("onLine2", onLine2);
|
||||
} else {
|
||||
//书面仲裁时
|
||||
String written1 = "仲裁庭审阅了申请人提交的仲裁申请书、证据材料后,于";
|
||||
String written2 = "在仲裁委所在地开庭审理了本案。";
|
||||
datas.put("written1", written1);
|
||||
datas.put("hearDate1", hearDateStr);
|
||||
datas.put("written2", written2);
|
||||
}
|
||||
}
|
||||
Integer isAbsence = caseApplication1.getIsAbsence();
|
||||
if (isAbsence == null) {
|
||||
datas.put("absent1", null);
|
||||
datas.put("absent2", null);
|
||||
datas.put("absent3", null);
|
||||
datas.put("absent4", null);
|
||||
datas.put("absent5", null);
|
||||
datas.put("attend1", null);
|
||||
datas.put("attend2", null);
|
||||
datas.put("attend3", null);
|
||||
datas.put("attend4", null);
|
||||
datas.put("attend5", null);
|
||||
datas.put("attend6", null);
|
||||
datas.put("attend7", null);
|
||||
datas.put("appAgentName1", null);
|
||||
datas.put("appAgentName2", null);
|
||||
datas.put("resAgentName", null);
|
||||
} else if (isAbsence == 1) {
|
||||
//缺席审理
|
||||
String absent1 = "申请人的特别授权委托代理人";
|
||||
String absent2 = "出席了庭审。被申请人经依法送达开庭通知,无正当理由未出席庭审,故仲裁庭依据" +
|
||||
"《2022年版仲裁规则》第四十条第(二)项的规定,对本案进行了缺席审理。";
|
||||
String absent3 = "庭审中,申请人陈述了仲裁请求事项及事实与理由,出示了证据材料并进行了说明," +
|
||||
"发表了意见,回答了仲裁庭的提问,并作了最后陈述。因被申请人缺席庭审,故仲裁庭无法组织调解。";
|
||||
String absent4 = "(二/三)当事人提供的证据材料\n" +
|
||||
"申请人为证明其主张的事实和理由,向仲裁庭提交了如下证据材料:";
|
||||
String absent5 = "综上,仲裁庭依据《上海仲裁委员会仲裁规则》(2022年7月1日起施行的版本)" +
|
||||
"第四十条第(二)项、第五十一条的规定,缺席裁决如下:";
|
||||
datas.put("absent1", absent1);
|
||||
datas.put("absent2", absent2);
|
||||
datas.put("absent3", absent3);
|
||||
datas.put("absent4", absent4);
|
||||
datas.put("absent5", absent5);
|
||||
datas.put("appAgentName1", nameAgentList.get(0));
|
||||
} else {
|
||||
//出席审理
|
||||
String attend1 = "申请人的特别授权委托代理人";
|
||||
String attend2 = "和被申请人本人/的特别授权委托代理人";
|
||||
String attend3 = "出席了庭审。";
|
||||
String attend4 = "庭审中,申请人陈述了仲裁请求事项及所依据的事实与理由,被申请人进行了答辩;" +
|
||||
"双方当事人均出示了证据材料并对对方的证据材料进行了质证;申请人出示了证据材料," +
|
||||
"被申请人对对方的证据材料进行了质证;双方当事人均回答了仲裁庭的提问,进行了辩论," +
|
||||
"并分别作了最后陈述。双方当事人在仲裁庭的主持下进行了调解,但未能达成调解协议。";
|
||||
String attend5 = "(二)被申请人的答辩意见";
|
||||
String attend6 = "(二/三)当事人提供的证据材料及对方的质证意见\n" +
|
||||
"申请人为证明其主张的事实和理由,向仲裁庭提交了如下证据材料:";
|
||||
String attend7 = "被申请人对上述材料的质证意见为:";
|
||||
datas.put("attend1", attend1);
|
||||
datas.put("attend2", attend2);
|
||||
datas.put("attend3", attend3);
|
||||
datas.put("attend4", attend4);
|
||||
datas.put("attend5", attend5);
|
||||
datas.put("attend6", attend6);
|
||||
datas.put("attend7", attend7);
|
||||
datas.put("responCrossOpin", caseApplication1.getResponCrossOpin());
|
||||
datas.put("appAgentName2", nameAgentList.get(0));
|
||||
datas.put("resAgentName", nameAgentList.get(1));
|
||||
if (arbitratMethod == 1) {
|
||||
//被申出席+开庭
|
||||
String attend8 = "综上,仲裁庭依据《上海仲裁委员会仲裁规则》(2022年7月1日起施行的版本)" +
|
||||
"第五十一条的规定,裁决如下:";
|
||||
datas.put("attend8", attend8);
|
||||
} else {
|
||||
//被申出席+书面
|
||||
String attend9 = "综上,仲裁庭依据《上海仲裁委员会仲裁规则》(2022年7月1日起施行的版本)" +
|
||||
"第五十一条、第五十八条的规定,裁决如下:";
|
||||
datas.put("attend9", attend9);
|
||||
}
|
||||
}
|
||||
datas.put("claims", caseApplication1.getArbitratClaims());
|
||||
datas.put("request", caseApplication1.getRequestRule());
|
||||
CaseApplication caseApplication2 = caseApplicationService.selectCaseApplication(caseApplication);
|
||||
List<CaseAttach> caseAttachList1 = caseApplication2.getCaseAttachList();
|
||||
if (caseAttachList1 != null && caseAttachList1.size() > 0) {
|
||||
for (CaseAttach caseAttach : caseAttachList1) {
|
||||
if (caseAttach.getAnnexType() == 6) { //被申请人证据材料
|
||||
String annexName = caseAttach.getAnnexName();
|
||||
boolean isImageFile = Pattern.matches(".*\\.(jpg|png|gif|bmp)$", annexName);
|
||||
if (isImageFile) {
|
||||
String annexPath = "/home/ruoyi" + caseAttach.getAnnexPath();
|
||||
System.out.println("路径是===========" + annexPath);
|
||||
PictureRenderData pictureRenderData = WordUtil
|
||||
.rebuildImageContent(100, 100, null, annexPath);
|
||||
datas.put("resEvidenceMaterial", pictureRenderData);
|
||||
}
|
||||
} else if (caseAttach.getAnnexType() == 2) { //申请人证据材料
|
||||
String annexName = caseAttach.getAnnexName();
|
||||
boolean isImageFile = Pattern.matches(".*\\.(jpg|png|gif|bmp)$", annexName);
|
||||
if (isImageFile) {
|
||||
String annexPath = "/home/ruoyi" + caseAttach.getAnnexPath();
|
||||
System.out.println("路径是===========" + annexPath);
|
||||
PictureRenderData pictureRenderData = WordUtil
|
||||
.rebuildImageContent(100, 100, null, annexPath);
|
||||
//申请人证据材料
|
||||
datas.put("appEvidenceMaterial", pictureRenderData);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
datas.put("applicaCrossOpin", "被申请人证据不足,无法说明事实");
|
||||
datas.put("factDetermi", "被申请人欠款属实");
|
||||
datas.put("arbitrateThink", " 被申请人应按约定还款");
|
||||
datas.put("rulingFollows", "被申请人依法偿还申请人欠款");
|
||||
LocalDate now = LocalDate.now();
|
||||
String year = Integer.toString(now.getYear());
|
||||
datas.put("year", year);
|
||||
String month = String.format("%02d", now.getMonthValue());
|
||||
String day = String.format("%02d", now.getDayOfMonth());
|
||||
String modalFilePath = "/data/arbitrate-document/template/新裁决书模板.docx";
|
||||
//String modalFilePath = "D:/develop/新裁决书模板.docx";
|
||||
String saveFolderPath = "/home/ruoyi/uploadPath/upload/" + year + "/" + month + "/" + day;
|
||||
//String saveFolderPath = "D:/data/" + year + "/" + month + "/" + day;
|
||||
String fileName = UUID.randomUUID().toString().replace("-", "") + ".docx";
|
||||
String saveName = "/profile/upload/" + year + "/" + month + "/" + day + "/" + fileName;
|
||||
String resultFilePath = saveFolderPath + "/" + fileName;
|
||||
// 创建日期目录
|
||||
File saveFolder = new File(saveFolderPath);
|
||||
if (!saveFolder.exists()) {
|
||||
saveFolder.mkdirs();
|
||||
}
|
||||
Path sourcePath = new File(modalFilePath).toPath();
|
||||
Path destinationPath = new File(resultFilePath).toPath();
|
||||
Files.copy(sourcePath, destinationPath, StandardCopyOption.REPLACE_EXISTING);
|
||||
String docFilePath = WordUtil.getDocFilePath(datas, modalFilePath, resultFilePath);
|
||||
File file = new File(docFilePath);
|
||||
if (file.exists()) {
|
||||
InputStream in = new FileInputStream(file);
|
||||
XWPFDocument xwpfDocument = new XWPFDocument(in);
|
||||
WordUtil.changeText(xwpfDocument);
|
||||
}
|
||||
String savePath = docFilePath.substring(0, docFilePath.indexOf("/upload/") + 8);
|
||||
CaseAttach caseAttach = CaseAttach.builder()
|
||||
.caseAppliId(id)
|
||||
.annexName(saveName)
|
||||
.annexPath(savePath)
|
||||
.annexType(3)
|
||||
.build();
|
||||
//保存到附件表里,先判断之前有没有,有的话更新,没有的话新增
|
||||
CaseAttach caseAttach1 = new CaseAttach();
|
||||
caseAttach1.setAnnexType(3);
|
||||
caseAttach1.setCaseAppliId(id);
|
||||
List<CaseAttach> caseAttachList = caseAttachMapper.getCaseAttachByCaseIdAndType(caseAttach1);
|
||||
if (caseAttachList != null && caseAttachList.size() > 0) {
|
||||
//之前已经生成过了,更新
|
||||
caseAttachMapper.updateCaseAttachBycaseid(caseAttach);
|
||||
} else {
|
||||
//之前没生成过,新增
|
||||
int i = caseAttachMapper.save(caseAttach);
|
||||
if (i > 0) {
|
||||
if (arbitrateRecord1 != null) {
|
||||
Integer annexId = caseAttach.getAnnexId();
|
||||
//将附件id保存到仲裁记录表里面
|
||||
arbitrateRecord1.setAnnexId(annexId);
|
||||
arbitrateRecordMapper.updataArbitrateRecord(arbitrateRecord1);
|
||||
}
|
||||
}
|
||||
}
|
||||
return Boolean.TRUE;
|
||||
} catch (IOException e) {
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
public String getNewEquipmentNo() {
|
||||
Object awardNum = redisCache.getCacheObject("awardNum");
|
||||
|
||||
+263
-226
@@ -2,27 +2,25 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
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.entity.SysRole;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sendrecord.SmsRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.utils.SmsUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import com.ruoyi.system.mapper.SysUserMapper;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseEvidenceDirectoryVO;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
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;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseDetailVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseEvidenceVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseEvidenceService;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -32,6 +30,7 @@ import java.io.IOException;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.google.common.io.Files.getFileExtension;
|
||||
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||
|
||||
@Service
|
||||
@@ -48,80 +47,82 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
private CaseEvidenceDirectoryMapper caseEvidenceDirectoryMapper;
|
||||
@Autowired
|
||||
private SysUserMapper sysUserMapper;
|
||||
// @Autowired
|
||||
// private SmsRecordMapper smsRecordMapper;
|
||||
@Autowired
|
||||
private SmsRecordMapper smsRecordMapper;
|
||||
private ICaseApplicationService caseApplicationService;
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public AjaxResult getCaseDetailsById(Long id, String userName) {
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(id);
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
if (caseApplication1 != null) {
|
||||
CaseDetailVO caseDetailVO = new CaseDetailVO();
|
||||
BeanUtils.copyProperties(caseApplication1, caseDetailVO);
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(id);
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
if (affiliate.getName() != null) {
|
||||
String name = affiliate.getName();
|
||||
//判断当前登录人和案件关联人姓名是否一致
|
||||
if (name.equals(userName)) { //一致,将案件关联人的身份类型赋给当前登录人
|
||||
caseDetailVO.setIdentityType(affiliate.getIdentityType());
|
||||
}
|
||||
}
|
||||
if (affiliate.getIdentityType() == 1) { //申请人
|
||||
caseDetailVO.setApplicantName(affiliate.getName());
|
||||
} else {
|
||||
caseDetailVO.setRespondentName(affiliate.getName());
|
||||
}
|
||||
//根据案件id查询案件证据材料
|
||||
List<CaseAttach> evidenceMaterialList = caseAttachMapper.queryAnnexPathByCaseId(id);
|
||||
if (evidenceMaterialList != null && evidenceMaterialList.size() > 0) {
|
||||
// for (CaseAttach caseAttach : evidenceMaterialList) {
|
||||
// //根据附件类型决定返回的路径
|
||||
// Integer annexType = caseAttach.getAnnexType();
|
||||
// if (annexType != 1){
|
||||
// String path = caseAttach.getAnnexName();
|
||||
// String prefix = "/profile";
|
||||
// int startIndex = path.indexOf(prefix);
|
||||
// startIndex += prefix.length();
|
||||
// String extractedPath = "/uploadPath" + path.substring(startIndex);
|
||||
// caseAttach.setAnnexPath(extractedPath);
|
||||
// }else {
|
||||
// String annexPath = caseAttach.getAnnexPath();
|
||||
// String result = annexPath.replace("/home/ruoyi", "");
|
||||
// caseAttach.setAnnexPath(result);
|
||||
// }
|
||||
// @Override
|
||||
// @Transactional
|
||||
// public AjaxResult getCaseDetailsById(Long id, String userName) {
|
||||
// CaseApplication caseApplication = new CaseApplication();
|
||||
// caseApplication.setId(id);
|
||||
// CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
// if (caseApplication1 != null) {
|
||||
// CaseDetailVO caseDetailVO = new CaseDetailVO();
|
||||
// BeanUtils.copyProperties(caseApplication1, caseDetailVO);
|
||||
// CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
// caseAffiliate.setCaseAppliId(id);
|
||||
// List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
// for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
// if (affiliate.getName() != null) {
|
||||
// String name = affiliate.getName();
|
||||
// //判断当前登录人和案件关联人姓名是否一致
|
||||
// if (name.equals(userName)) { //一致,将案件关联人的身份类型赋给当前登录人
|
||||
// caseDetailVO.setIdentityType(affiliate.getIdentityType());
|
||||
// }
|
||||
|
||||
for (CaseAttach caseAttach : evidenceMaterialList) {
|
||||
String annexName = caseAttach.getAnnexName();
|
||||
String prefix = "/profile";
|
||||
int startIndex = annexName.indexOf(prefix);
|
||||
if(startIndex!=-1) {
|
||||
startIndex += prefix.length();
|
||||
|
||||
String annexPath = "/uploadPath" + annexName.substring(startIndex);
|
||||
caseAttach.setAnnexPath(annexPath);
|
||||
}
|
||||
int startIndexnew = annexName.lastIndexOf("/");
|
||||
if (startIndexnew != -1) {
|
||||
String annexNamenew = annexName.substring(startIndexnew + 1);
|
||||
caseAttach.setAnnexName(annexNamenew);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
caseDetailVO.setEvidenceMaterialList(evidenceMaterialList);
|
||||
}
|
||||
return AjaxResult.success(caseDetailVO);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
// }
|
||||
// if (affiliate.getIdentityType() == 1) { //申请人
|
||||
// caseDetailVO.setApplicantName(affiliate.getName());
|
||||
// } else {
|
||||
// caseDetailVO.setRespondentName(affiliate.getName());
|
||||
// }
|
||||
// //根据案件id查询案件证据材料
|
||||
// List<CaseAttach> evidenceMaterialList = caseAttachMapper.queryAnnexPathByCaseId(id);
|
||||
// if (evidenceMaterialList != null && evidenceMaterialList.size() > 0) {
|
||||
//// for (CaseAttach caseAttach : evidenceMaterialList) {
|
||||
//// //根据附件类型决定返回的路径
|
||||
//// Integer annexType = caseAttach.getAnnexType();
|
||||
//// if (annexType != 1){
|
||||
//// String path = caseAttach.getAnnexName();
|
||||
//// String prefix = "/profile";
|
||||
//// int startIndex = path.indexOf(prefix);
|
||||
//// startIndex += prefix.length();
|
||||
//// String extractedPath = "/uploadPath" + path.substring(startIndex);
|
||||
//// caseAttach.setAnnexPath(extractedPath);
|
||||
//// }else {
|
||||
//// String annexPath = caseAttach.getAnnexPath();
|
||||
//// String result = annexPath.replace("/home/ruoyi", "");
|
||||
//// caseAttach.setAnnexPath(result);
|
||||
//// }
|
||||
//// }
|
||||
//
|
||||
// for (CaseAttach caseAttach : evidenceMaterialList) {
|
||||
// String annexName = caseAttach.getAnnexName();
|
||||
// String prefix = "/profile";
|
||||
// int startIndex = annexName.indexOf(prefix);
|
||||
// if(startIndex!=-1) {
|
||||
// startIndex += prefix.length();
|
||||
//
|
||||
// String annexPath = "/uploadPath" + annexName.substring(startIndex);
|
||||
// caseAttach.setAnnexPath(annexPath);
|
||||
// }
|
||||
// int startIndexnew = annexName.lastIndexOf("/");
|
||||
// if (startIndexnew != -1) {
|
||||
// String annexNamenew = annexName.substring(startIndexnew + 1);
|
||||
// caseAttach.setAnnexName(annexNamenew);
|
||||
// }
|
||||
//
|
||||
//
|
||||
// }
|
||||
//
|
||||
// }
|
||||
// caseDetailVO.setEvidenceMaterialList(evidenceMaterialList);
|
||||
// }
|
||||
// return AjaxResult.success(caseDetailVO);
|
||||
// }
|
||||
// return null;
|
||||
// }
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
@@ -130,19 +131,62 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
if (file.isEmpty()) {
|
||||
return AjaxResult.error("请选择要上传的文件");
|
||||
}
|
||||
AjaxResult success = AjaxResult.success();
|
||||
try {
|
||||
String filePath = RuoYiConfig.getUploadPath();
|
||||
// 上传
|
||||
String fileName = FileUploadUtils.upload(filePath, file);
|
||||
CaseAttach caseAttach = CaseAttach.builder().caseAppliId(id)
|
||||
.annexName(fileName)
|
||||
.annexPath(filePath)
|
||||
.annexType(annexType)
|
||||
.userId(userId)
|
||||
.userName(userName)
|
||||
.build();
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
if (count > 0 && annexType != null && annexType != 8) {
|
||||
String name = file.getOriginalFilename();
|
||||
String suffix = getFileExtension(fileName);
|
||||
if(StrUtil.isNotEmpty(suffix)&& suffix.contains("doc")){
|
||||
// 上传到onlyoffice
|
||||
JSONArray jsonArray = caseApplicationService.uploadOnlyOffice(fileName,id);
|
||||
if(jsonArray!=null && jsonArray.size() > 0) {
|
||||
for (Object obj : jsonArray) {
|
||||
JSONObject jsonObject = (JSONObject) obj;
|
||||
String path = jsonObject.get("filePath")!=null?jsonObject.getString("filePath"):"";
|
||||
path=path.replace("/home/ruoyi/uploadPath/","/profile/");
|
||||
name = jsonObject.get("fileName")!=null?jsonObject.getString("fileName"):"";
|
||||
CaseAttach caseAttach = CaseAttach.builder()
|
||||
.caseAppliId(id)
|
||||
.annexType(annexType)
|
||||
.annexName(name)
|
||||
.onlyOfficeFileId(jsonObject.getString("fileId"))
|
||||
.annexPath(path)
|
||||
.build();
|
||||
// if(jsonObject.get("filePath")!=null){
|
||||
// String officePath = jsonObject.getString("filePath");
|
||||
// String replace = officePath.replace("/home/ruoyi/uploadPath/", "/profile/");
|
||||
// caseAttach.setAnnexPath(replace);
|
||||
//
|
||||
// }
|
||||
if(annexType!=null && annexType.equals(8)){
|
||||
// 缴费单,先删除
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(id,annexType);
|
||||
}
|
||||
caseAttachMapper.save(caseAttach);
|
||||
success.put("annexId", caseAttach.getAnnexId());
|
||||
success.put("annexType", caseAttach.getAnnexType());
|
||||
}
|
||||
}
|
||||
}else {
|
||||
filePath=fileName.replace("/home/ruoyi/uploadPath/","/profile/");
|
||||
if(annexType!=null && annexType.equals(8)){
|
||||
// 缴费单,先删除
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(id,annexType);
|
||||
}
|
||||
CaseAttach caseAttach = CaseAttach.builder().caseAppliId(id)
|
||||
.annexName(name)
|
||||
.annexPath(filePath)
|
||||
.annexType(annexType)
|
||||
.userId(userId)
|
||||
.userName(userName)
|
||||
.build();
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
success.put("annexId", caseAttach.getAnnexId());
|
||||
success.put("annexType", caseAttach.getAnnexType());
|
||||
}
|
||||
if ( annexType != null && annexType != 8) {
|
||||
if (id != null) {
|
||||
//修改案件状态
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
@@ -151,18 +195,7 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
}
|
||||
}
|
||||
CaseAttach caseAttachselect = new CaseAttach();
|
||||
caseAttachselect.setAnnexId(caseAttach.getAnnexId());
|
||||
String annexName = caseAttach.getAnnexName();
|
||||
if(StrUtil.isNotEmpty(annexName)) {
|
||||
int startIndexnew = annexName.lastIndexOf("/");
|
||||
if (startIndexnew != -1) {
|
||||
String annexNamenew = annexName.substring(startIndexnew + 1);
|
||||
caseAttach.setAnnexName(annexNamenew);
|
||||
}
|
||||
}
|
||||
caseAttachselect.setAnnexType(caseAttach.getAnnexType());
|
||||
return AjaxResult.success("上传成功", caseAttachselect);
|
||||
return success;
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
@@ -174,47 +207,49 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
@Autowired
|
||||
IdentityAuthenticationMapper identityAuthenticationMapper;
|
||||
|
||||
@Override
|
||||
public List<CaseEvidenceVO> getCaseListAll(Integer caseStatus) {
|
||||
// 是否为超级管理员
|
||||
int adMinFlag=0;
|
||||
String identityNum = "";
|
||||
IdentityAuthentication authentication = new IdentityAuthentication();
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// 查询该用户的角色
|
||||
// 查询登录人身份证号
|
||||
SysUser sysUser = sysUserMapper.selectUserById(loginUser.getUserId());
|
||||
String username = sysUser.getUserName();
|
||||
List<SysRole> roles = sysUser.getRoles();
|
||||
if(CollectionUtil.isNotEmpty(roles)){
|
||||
for (SysRole role : roles) {
|
||||
if(role.getRoleName().equals("超级管理员")
|
||||
){
|
||||
// 超级管理员可查看所有待案件质证的案件
|
||||
adMinFlag=1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if(adMinFlag!=1) {
|
||||
authentication.setUserName(username);
|
||||
IdentityAuthentication authentication1 = identityAuthenticationMapper.selectIdentityAuthentication(authentication);
|
||||
if (authentication1 != null) {
|
||||
identityNum = authentication1.getIdentityNo();
|
||||
}
|
||||
}
|
||||
|
||||
List<Integer> caseStatusList = Arrays.asList(caseStatus);
|
||||
return getCaseEvidenceVOList(identityNum, caseStatusList, 2);
|
||||
}
|
||||
// @Override
|
||||
// public List<CaseEvidenceVO> getCaseListAll(Integer caseStatus) {
|
||||
// // 是否为超级管理员
|
||||
// int adMinFlag=0;
|
||||
// String identityNum = "";
|
||||
// IdentityAuthentication authentication = new IdentityAuthentication();
|
||||
// LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// // 查询该用户的角色
|
||||
// // 查询登录人手机号
|
||||
// SysUser sysUser = sysUserMapper.selectUserById(loginUser.getUserId());
|
||||
// String username = sysUser.getUserName();
|
||||
// List<SysRole> roles = sysUser.getRoles();
|
||||
// if(CollectionUtil.isNotEmpty(roles)){
|
||||
// for (SysRole role : roles) {
|
||||
// if(role.getRoleName().equals("超级管理员")
|
||||
// ){
|
||||
// // 超级管理员可查看所有待案件质证的案件
|
||||
// adMinFlag=1;
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//// if(adMinFlag!=1) {
|
||||
//// authentication.setUserName(username);
|
||||
//// IdentityAuthentication authentication1 = identityAuthenticationMapper.selectIdentityAuthentication(authentication);
|
||||
//// if (authentication1 != null) {
|
||||
//// identityNum = authentication1.getIdentityNo();
|
||||
//// }
|
||||
//// }
|
||||
// String phone=sysUser.getPhonenumber();
|
||||
// List<Integer> caseStatusList = Arrays.asList(caseStatus);
|
||||
//// return getCaseEvidenceVOList(identityNum, caseStatusList, 2);
|
||||
// return getCaseEvidenceVOListByPhone(phone, caseStatusList, 2);
|
||||
// }
|
||||
|
||||
@Override
|
||||
public AjaxResult evidenceConfirmation(CaseApplication caseApplication) {
|
||||
// Integer currentStatus = caseApplicationMapper.selectCaseApplicationCaseStatus(caseApplication.getId());
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.PENDING_TRIAL);
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
if (i > 0) {
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_TRIAL, "");
|
||||
// CaseLogUtils.insertCaseLog(caseApplication.getId(),CaseApplicationConstants., "");
|
||||
|
||||
return AjaxResult.success("证据确认成功");
|
||||
}
|
||||
@@ -252,7 +287,7 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
if (i > 0) {
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.CONFIRMDED_PENDING_TRIAL_SUBMMIT, "");
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.CASE_CROSSEXAMI, "");
|
||||
|
||||
return AjaxResult.success("提交成功");
|
||||
}
|
||||
@@ -263,27 +298,44 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
@Transactional
|
||||
@Override
|
||||
public AjaxResult batchUpload(MultipartFile[] files, Integer annexType, Long id, String userName, Long userId) {
|
||||
List<CaseAttach> successList = new ArrayList<>();
|
||||
try {
|
||||
String filePath = RuoYiConfig.getUploadPath();
|
||||
for (MultipartFile file : files) {
|
||||
// 上传
|
||||
String fileName = FileUploadUtils.upload(filePath, file);
|
||||
CaseAttach caseAttach = CaseAttach.builder().caseAppliId(id)
|
||||
.annexName(fileName)
|
||||
.annexPath(filePath)
|
||||
.annexType(annexType)
|
||||
.userId(userId)
|
||||
.userName(userName)
|
||||
.isBatchUpload(1)
|
||||
.build();
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
if (count > 0 && annexType != null && annexType != 8) {
|
||||
CaseAttach caseAttachselect = new CaseAttach();
|
||||
caseAttachselect.setAnnexId(caseAttach.getAnnexId());
|
||||
caseAttachselect.setAnnexName(caseAttach.getAnnexName());
|
||||
caseAttachselect.setAnnexType(caseAttach.getAnnexType());
|
||||
successList.add(caseAttachselect);
|
||||
String name=file.getOriginalFilename();
|
||||
String suffix = getFileExtension(fileName);
|
||||
if (StrUtil.isNotEmpty(suffix) && suffix.contains("doc")) {
|
||||
// 上传onlyoffice
|
||||
JSONArray jsonArray = caseApplicationService.uploadOnlyOffice(fileName,id);
|
||||
if(jsonArray!=null && jsonArray.size() > 0) {
|
||||
for (Object obj : jsonArray) {
|
||||
JSONObject jsonObject = (JSONObject) obj;
|
||||
String path = jsonObject.get("filePath")!=null?jsonObject.getString("filePath"):"";
|
||||
// name = jsonObject.get("fileName")!=null?jsonObject.getString("fileName"):"";
|
||||
path=path.replace("/home/ruoyi/uploadPath/","/profile/");
|
||||
|
||||
CaseAttach caseAttach = CaseAttach.builder()
|
||||
.caseAppliId(id)
|
||||
.annexType(annexType)
|
||||
.annexName(name)
|
||||
.annexPath(path)
|
||||
.onlyOfficeFileId(jsonObject.getString("fileId"))
|
||||
.build();
|
||||
caseAttachMapper.save(caseAttach);
|
||||
}
|
||||
}
|
||||
}else {
|
||||
filePath=fileName.replace("/home/ruoyi/uploadPath/","/profile/");
|
||||
CaseAttach caseAttach = CaseAttach.builder().caseAppliId(id)
|
||||
.annexName(name)
|
||||
.annexPath(filePath)
|
||||
.annexType(annexType)
|
||||
.userId(userId)
|
||||
.userName(userName)
|
||||
.isBatchUpload(1)
|
||||
.build();
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -294,44 +346,23 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
}
|
||||
// 给秘书发送短信
|
||||
// 根据caseid查询该案件的法律顾问,根据案件id查申请表,查到申请机构id,然后拿申请机构id查询在哪个人下并且角色要是法律顾问
|
||||
CaseAffiliate caseAffiliate = caseAffiliateMapper.selectCaseAffiliateByIdentityType(id, 1);
|
||||
if(caseAffiliate!= null && StrUtil.isNotEmpty(caseAffiliate.getApplicationOrganId())){
|
||||
List<SysUser> userList= sysUserMapper.selectByDeptIdAndRole(caseAffiliate.getApplicationOrganId(),"法律顾问");
|
||||
if(CollectionUtil.isNotEmpty(userList)){
|
||||
// CaseAffiliate caseAffiliate = caseAffiliateMapper.selectCaseAffiliateByIdentityType(id, 1);
|
||||
// if(caseAffiliate!= null && StrUtil.isNotEmpty(caseAffiliate.getApplicationOrganId())){
|
||||
// List<SysUser> userList= sysUserMapper.selectByDeptIdAndRole(caseAffiliate.getApplicationOrganId(),"法律顾问");
|
||||
SysUser user= sysUserMapper.selectUserByRole("法律顾问");
|
||||
if(user!=null){
|
||||
// 新增短信记录
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
// 1992106 普通短信 修改证据资料通知 尊敬的{1}用户,您的{2}仲裁案件,有新的证据上传,请知晓,如非本人操作,请忽略本短信。
|
||||
request.setTemplateId("1992106");
|
||||
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(id);
|
||||
caseApplication = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
for (SysUser user : userList) {
|
||||
request.setPhone(user.getPhonenumber());
|
||||
request.setTemplateParamSet(new String[]{user.getNickName(),caseApplication.getCaseNum()});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseAffiliate.getCaseAppliId());
|
||||
|
||||
smsSendRecord.setCaseNum(caseApplication.getCaseNum());
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + user.getNickName() + ",您的"+caseApplication.getCaseNum()+"仲裁案件,有新的证据上传,请知晓,如非本人操作,请忽略本短信。";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean) {
|
||||
smsSendRecord.setSendStatus(1);
|
||||
} else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
}
|
||||
SmsUtils.sendSms(caseApplication, "1992106", user.getPhonenumber(), new String[]{user.getNickName(),caseApplication.getCaseNum()});
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return AjaxResult.success("上传成功", successList);
|
||||
|
||||
return AjaxResult.success("上传成功");
|
||||
|
||||
}
|
||||
|
||||
@@ -343,17 +374,13 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
List<CaseAttach> caseAttachList = caseAttachMapper.queryCaseAttachList(caseApplication);
|
||||
if (CollectionUtil.isNotEmpty(caseAttachList)) {
|
||||
for (CaseAttach caseAttach : caseAttachList) {
|
||||
String annexName = caseAttach.getAnnexName();
|
||||
String prefix = "/profile";
|
||||
int startIndex = annexName.indexOf(prefix);
|
||||
startIndex += prefix.length();
|
||||
String annexPath = "/uploadPath" + annexName.substring(startIndex);
|
||||
caseAttach.setAnnexPath(annexPath);
|
||||
int startIndexnew = annexName.lastIndexOf("/");
|
||||
if (startIndexnew != -1) {
|
||||
String annexNamenew = annexName.substring(startIndexnew + 1);
|
||||
caseAttach.setAnnexName(annexNamenew);
|
||||
String annexPath = caseAttach.getAnnexPath();
|
||||
if(StrUtil.isEmpty(annexPath)){
|
||||
continue;
|
||||
}
|
||||
caseAttach.setAnnexPath(annexPath);
|
||||
caseAttach.setAnnexName(caseAttach.getAnnexName());
|
||||
|
||||
}
|
||||
return AjaxResult.success(caseAttachList);
|
||||
}
|
||||
@@ -361,7 +388,7 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public int deleteFile(List<Integer> fileIds) {
|
||||
public int deleteFile(List<Long> fileIds) {
|
||||
return caseAttachMapper.deleteByFileIds(fileIds);
|
||||
}
|
||||
|
||||
@@ -423,25 +450,16 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
String filePath = RuoYiConfig.getUploadPath();
|
||||
// 上传
|
||||
String fileName = FileUploadUtils.upload(filePath, file);
|
||||
fileName=fileName.replace("/home/ruoyi/uploadPath/","/profile/");
|
||||
CaseAttach caseAttach = CaseAttach.builder().caseAppliId(id)
|
||||
.annexName(fileName)
|
||||
.annexPath(filePath)
|
||||
.annexName(file.getOriginalFilename())
|
||||
.annexPath(fileName)
|
||||
.annexType(annexType)
|
||||
.userId(userId)
|
||||
.userName(username)
|
||||
.build();
|
||||
|
||||
CaseApplication caseApplicationsel = new CaseApplication();
|
||||
caseApplicationsel.setId(id);
|
||||
caseApplicationsel.setAnnexType(7);
|
||||
List<CaseAttach> caseAttachs = caseAttachMapper.queryCaseAttachList(caseApplicationsel);
|
||||
if(caseAttachs!=null&&caseAttachs.size()>0){
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(id,7);
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
}else {
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
}
|
||||
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(id,annexType);
|
||||
int count = caseAttachMapper.save(caseAttach);
|
||||
return AjaxResult.success("上传成功");
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
@@ -487,25 +505,44 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
||||
return getChildList(list, t).size() > 0;
|
||||
}
|
||||
|
||||
private List<CaseEvidenceVO> getCaseEvidenceVOList(String identityNum, List<Integer> caseStatusList, Integer identityType) {
|
||||
List<CaseEvidenceVO> caseListByRespondent = caseEvidenceMapper.getCaseListByRespondent(identityNum, caseStatusList, identityType);
|
||||
// todo 返回房间号和开庭时间
|
||||
if (caseListByRespondent != null && caseListByRespondent.size() > 0) {
|
||||
for (CaseEvidenceVO caseEvidenceVO : caseListByRespondent) {
|
||||
//根据案件id查询姓名
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(caseEvidenceVO.getId());
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
if (affiliate.getIdentityType() == 1) { //申请人
|
||||
caseEvidenceVO.setApplicantName(affiliate.getName());
|
||||
} else {
|
||||
caseEvidenceVO.setRespondentName(affiliate.getName());
|
||||
}
|
||||
}
|
||||
}
|
||||
return caseListByRespondent;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
// private List<CaseEvidenceVO> getCaseEvidenceVOList(String identityNum, List<Integer> caseStatusList, Integer identityType) {
|
||||
// List<CaseEvidenceVO> caseListByRespondent = caseEvidenceMapper.getCaseListByRespondent(identityNum, caseStatusList, identityType,null,SecurityUtils.getUsername());
|
||||
// if (caseListByRespondent != null && caseListByRespondent.size() > 0) {
|
||||
// for (CaseEvidenceVO caseEvidenceVO : caseListByRespondent) {
|
||||
// //根据案件id查询姓名
|
||||
// CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
// caseAffiliate.setCaseAppliId(caseEvidenceVO.getId());
|
||||
// List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
// for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
// if (affiliate.getIdentityType() == 1) { //申请人
|
||||
// caseEvidenceVO.setApplicantName(affiliate.getName());
|
||||
// } else {
|
||||
// caseEvidenceVO.setRespondentName(affiliate.getName());
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// return caseListByRespondent;
|
||||
// }
|
||||
// return null;
|
||||
// }
|
||||
// private List<CaseEvidenceVO> getCaseEvidenceVOListByPhone(String phone, List<Integer> caseStatusList, Integer identityType) {
|
||||
// List<CaseEvidenceVO> caseListByRespondent = caseEvidenceMapper.getCaseListByRespondent(null, caseStatusList, identityType,phone,SecurityUtils.getUsername());
|
||||
// if (caseListByRespondent != null && caseListByRespondent.size() > 0) {
|
||||
// for (CaseEvidenceVO caseEvidenceVO : caseListByRespondent) {
|
||||
// //根据案件id查询姓名
|
||||
// CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
// caseAffiliate.setCaseAppliId(caseEvidenceVO.getId());
|
||||
// List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate);
|
||||
// for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
// if (affiliate.getIdentityType() == 1) { //申请人
|
||||
// caseEvidenceVO.setApplicantName(affiliate.getName());
|
||||
// } else {
|
||||
// caseEvidenceVO.setRespondentName(affiliate.getName());
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// return caseListByRespondent;
|
||||
// }
|
||||
// return null;
|
||||
// }
|
||||
}
|
||||
|
||||
+12
-2
@@ -4,12 +4,15 @@ 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.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseApplicationMapper;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseLogRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseLogRecordService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
@@ -17,10 +20,13 @@ import java.util.Optional;
|
||||
public class CaseLogRecordServiceImpl implements ICaseLogRecordService {
|
||||
@Autowired
|
||||
private CaseLogRecordMapper caseLogRecordMapper;
|
||||
|
||||
@Autowired
|
||||
private CaseApplicationMapper applicationMapper;
|
||||
|
||||
@Override
|
||||
public List<CaseLogRecord> selectCaseLogRecordList(CaseLogRecord caseLogRecord) {
|
||||
CaseApplication caseApplicationReq = new CaseApplication();
|
||||
caseApplicationReq.setId(caseLogRecord.getCaseAppliId());
|
||||
List<CaseLogRecord> records = caseLogRecordMapper.selectCaseLogRecordList(caseLogRecord);
|
||||
if(CollectionUtil.isNotEmpty(records)){
|
||||
records.forEach(record->{
|
||||
@@ -30,7 +36,11 @@ public class CaseLogRecordServiceImpl implements ICaseLogRecordService {
|
||||
caseNodeTime= DateUtil.format(record.getCaseNodeTime(), DatePattern.NORM_DATETIME_FORMATTER);
|
||||
}
|
||||
|
||||
contentBuilder.append(Optional.ofNullable(record.getCreateNickName()).orElse("")).append("(").append(record.getCreateBy()).append(")").append("于").append(caseNodeTime);
|
||||
contentBuilder.append(Optional.ofNullable(record.getCreateNickName()).orElse(""));
|
||||
if(StrUtil.isNotEmpty(record.getCreateBy())) {
|
||||
contentBuilder.append("(").append(record.getCreateBy()).append(")");
|
||||
}
|
||||
contentBuilder.append("于").append(caseNodeTime);
|
||||
if(StrUtil.isNotEmpty(record.getContent())){
|
||||
contentBuilder.append(record.getContent());
|
||||
}
|
||||
|
||||
+119
-187
@@ -2,26 +2,25 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.ruoyi.ElegentPay;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.constant.HttpStatus;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseConfirmPayDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CasePayListVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sendrecord.SmsRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICaseApplicationService;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.wisdomarbitrate.utils.SmsUtils;
|
||||
import com.ruoyi.dto.PayRequest;
|
||||
import com.ruoyi.dto.PayResponse;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CasePayDTO;
|
||||
import com.ruoyi.wisdomarbitrate.service.ICasePaymentService;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -30,6 +29,7 @@ import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||
@@ -44,6 +44,9 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
private CaseAttachMapper caseAttachMapper;
|
||||
@Autowired
|
||||
private SmsRecordMapper smsRecordMapper;
|
||||
@Autowired
|
||||
private ArbitrateRecordMapper arbitrateRecordMapper;
|
||||
private ICasePaymentService casePaymentService;
|
||||
|
||||
@Autowired
|
||||
public CasePaymentServiceImpl(ElegentPay elegentPay
|
||||
@@ -111,76 +114,75 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public AjaxResult confirmPayment( List<Long> ids) {
|
||||
for (Long id : ids) {
|
||||
public AjaxResult confirmPayment( BatchCaseApplication batchCaseApplication) {
|
||||
for (Long id : batchCaseApplication.getIds()) {
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(id);
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_CROSSEXAMI);
|
||||
//查询案件详细信息
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
if (caseApplication1 == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// 查询当前案件节点
|
||||
// Integer currentStatus= caseApplicationMapper.selectCaseApplicationCaseStatus(id);
|
||||
if(batchCaseApplication.getAgreeOrNotCheck().equals(1)){
|
||||
// 同意,更新案件状态为案件质证
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_CROSSEXAMI);
|
||||
}else {
|
||||
if(StrUtil.isEmpty(batchCaseApplication.getCaseCheckReject())){
|
||||
return AjaxResult.error("请填写拒绝理由");
|
||||
}
|
||||
// 拒绝,更新案件状态为待缴费
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.PENDING_PAYMENT);
|
||||
ArbitrateRecord arbitrateRecordsel = new ArbitrateRecord();
|
||||
arbitrateRecordsel.setCaseAppliId(id);
|
||||
ArbitrateRecord arbitrateRecordnew = arbitrateRecordMapper.selectArbitrateRecord(arbitrateRecordsel);
|
||||
if(arbitrateRecordnew!=null){
|
||||
arbitrateRecordnew.setPayRejectReason(batchCaseApplication.getCaseCheckReject());
|
||||
arbitrateRecordMapper.updataArbitrateRecord(arbitrateRecordnew);
|
||||
}else {
|
||||
|
||||
arbitrateRecordsel.setPayRejectReason(batchCaseApplication.getCaseCheckReject());
|
||||
arbitrateRecordMapper.insertArbitrateRecord(arbitrateRecordsel);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
//发送短信通知
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate); //获取案件关联人信息
|
||||
List<CaseAffiliateEntity> caseAffiliates = caseApplicationService.selectAfflicatesByCaseId(caseApplication.getId());
|
||||
if (caseAffiliates != null && caseAffiliates.size() > 0) {
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
//获取身份类型
|
||||
int identityType = affiliate.getIdentityType();
|
||||
//查询案件详细信息
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
if (caseApplication1 == null) {
|
||||
continue;
|
||||
}
|
||||
// 申请操作人
|
||||
Optional<CaseAffiliateEntity> applicantAffiliateOpt = caseAffiliates.stream().filter(affiliate -> affiliate.getOperatorFlag() == 1 && StrUtil.isNotEmpty(affiliate.getPhone()) && (affiliate.getRoleType().equals(1) || affiliate.getRoleType().equals(2))).findFirst();
|
||||
// 被申请操作人
|
||||
Optional<CaseAffiliateEntity> resAffiliateOpt = caseAffiliates.stream().filter(affiliate -> affiliate.getOperatorFlag() == 1 && StrUtil.isNotEmpty(affiliate.getPhone()) && (affiliate.getRoleType().equals(3) || affiliate.getRoleType().equals(4))).findFirst();
|
||||
if (!applicantAffiliateOpt.isPresent() || !resAffiliateOpt.isPresent()) {
|
||||
throw new ServiceException("未找到案件操作人员");
|
||||
}
|
||||
|
||||
String caseName = "仲裁"; //这里案件名称表里未定义,暂时写死
|
||||
String caseNum = caseApplication1.getCaseNum();
|
||||
if (identityType == 1) { //申请人
|
||||
request.setPhone(affiliate.getContactTelphone());
|
||||
request.setTemplateId("1928003"); //传入申请人模板id
|
||||
// 这个值,要看你的模板中是否预留了占位符,如果没有则不需要设置
|
||||
// 模板id:1928003 普通短信 案件受理通知
|
||||
String name = affiliate.getName();
|
||||
request.setTemplateParamSet(new String[]{name, caseName, caseNum});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplication.getId());
|
||||
smsSendRecord.setCaseNum(caseNum);
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + name + "用户,您的" + caseName + "案件" + caseNum + "已成功受理。";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean) {
|
||||
smsSendRecord.setSendStatus(1);
|
||||
} else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
} else { //被申请人
|
||||
CaseAffiliateEntity app = applicantAffiliateOpt.get();
|
||||
CaseAffiliateEntity res = resAffiliateOpt.get();
|
||||
//申请人
|
||||
if(batchCaseApplication.getAgreeOrNotCheck().equals(1)){
|
||||
SmsUtils.sendSms(caseApplication1, "1928003", app.getPhone(), new String[]{app.getName(),caseName,caseApplication1.getCaseNum()});
|
||||
}else {
|
||||
SmsUtils.sendSms(caseApplication1, "2074402", app.getPhone(), new String[]{app.getName(),caseApplication1.getCaseNum(),batchCaseApplication.getCaseCheckReject()});
|
||||
|
||||
request.setPhone(affiliate.getContactTelphone());
|
||||
request.setTemplateId("1952840");
|
||||
// 1952840 尊敬的{1}用户,您的{2}案件{3}已成功受理,请点击链接:https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 选择是否应诉。如非本人操作,请忽略本短信
|
||||
String name = affiliate.getName();
|
||||
request.setTemplateParamSet(new String[]{name, caseName, caseNum});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplication.getId());
|
||||
smsSendRecord.setCaseNum(caseNum);
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + name + "用户,您的" + caseName + "案件" + caseNum + "已成功受理,请点击链接:https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 选择是否应诉。如非本人操作,请忽略本短信";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean) {
|
||||
smsSendRecord.setSendStatus(1);
|
||||
} else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//被申请人
|
||||
if(batchCaseApplication.getAgreeOrNotCheck().equals(1)) {
|
||||
|
||||
SmsUtils.sendSms(caseApplication1, "1952840", res.getPhone(), new String[]{res.getName(),caseName,caseApplication1.getCaseNum()});
|
||||
|
||||
}
|
||||
|
||||
|
||||
//更改记录表里的支付状态和支付时间
|
||||
CasePaymentRecord casePaymentRecord = new CasePaymentRecord();
|
||||
casePaymentRecord.setPaymentStatus(1);
|
||||
@@ -188,7 +190,11 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
casePaymentRecord.setUpdateTime(new Date());
|
||||
casePaymentRecordMapper.update(casePaymentRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.CASE_CROSSEXAMI, "");
|
||||
if(batchCaseApplication.getAgreeOrNotCheck().equals(1)) {
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_PAYMENT_CONFIRM, "");
|
||||
}else {
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_PAYMENT_CONFIRM, "拒绝原因:"+batchCaseApplication.getCaseCheckReject());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -210,6 +216,8 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
if (CollectionUtil.isNotEmpty(payDTO.getPayOrderList())) {
|
||||
for (CaseAttach caseAttach : payDTO.getPayOrderList()) {
|
||||
caseAttach.setCaseAppliId(caseId);
|
||||
// 先删除该案件缴费凭证,类型为8,在新增
|
||||
caseAttachMapper.deleteCaseAttach(caseId,8,caseAttach.getAnnexId());
|
||||
caseAttachMapper.updateCaseAttach(caseAttach);
|
||||
}
|
||||
}
|
||||
@@ -218,6 +226,7 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(caseId);
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
Integer currentStatus=caseApplication1.getCaseStatus();
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_PAYMENT_CONFIRM);
|
||||
//修改案件状态
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
@@ -229,7 +238,7 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
paymentRecord.setPaymentStatus(1);
|
||||
casePaymentRecordMapper.saveRecord(paymentRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_PAYMENT_CONFIRM, "");
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_PAYMENT ,"");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -282,43 +291,45 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
caseApplicationsel.setBatchNumber(Integer.parseInt(batchNumber));
|
||||
caseApplicationsel.setCaseStatus(CaseApplicationConstants.PENDING_PAYMENT);
|
||||
List<CaseApplication> caseApplications = caseApplicationMapper.listCaseApplicationByBatchNumber(caseApplicationsel);
|
||||
List<Long> caseIds = caseApplications.stream().map(CaseApplication::getId).collect(Collectors.toList());
|
||||
if(caseApplications!=null&&caseApplications.size()>0){
|
||||
if (payDTO.getPayType() != null) {
|
||||
payDTO.setCaseIds(caseIds);
|
||||
// 修改支付方式
|
||||
CaseConfirmPayDTO caseConfirmPayDTO = new CaseConfirmPayDTO();
|
||||
BeanUtils.copyProperties(payDTO, caseConfirmPayDTO);
|
||||
caseApplicationMapper.updatePayType(caseConfirmPayDTO);
|
||||
}
|
||||
for (Long caseId : caseIds) {
|
||||
if (CollectionUtil.isNotEmpty(payDTO.getPayOrderList())) {
|
||||
for (CaseAttach caseAttach : payDTO.getPayOrderList()) {
|
||||
caseAttach.setCaseAppliId(caseId);
|
||||
caseAttachMapper.updateCaseAttach(caseAttach);
|
||||
}
|
||||
}
|
||||
|
||||
// 修改节点状态
|
||||
//根据案件id查询案件信息
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(caseId);
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_PAYMENT_CONFIRM);
|
||||
//修改案件状态
|
||||
int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
if (i > 0) {
|
||||
// 修改支付状态
|
||||
CasePaymentRecord paymentRecord = new CasePaymentRecord();
|
||||
paymentRecord.setPayType(payDTO.getPayType());
|
||||
paymentRecord.setCaseId(caseId);
|
||||
paymentRecord.setPaymentStatus(1);
|
||||
casePaymentRecordMapper.saveRecord(paymentRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_PAYMENT_CONFIRM, "");
|
||||
}
|
||||
if(CollectionUtil.isNotEmpty(caseApplications)){
|
||||
List<Long> caseIds = caseApplications.stream().map(CaseApplication::getId).collect(Collectors.toList());
|
||||
|
||||
}
|
||||
// if (payDTO.getPayType() != null) {
|
||||
// payDTO.setCaseIds(caseIds);
|
||||
// // 修改支付方式
|
||||
// CaseConfirmPayDTO caseConfirmPayDTO = new CaseConfirmPayDTO();
|
||||
// BeanUtils.copyProperties(payDTO, caseConfirmPayDTO);
|
||||
// caseApplicationMapper.updatePayType(caseConfirmPayDTO);
|
||||
// }
|
||||
// for (Long caseId : caseIds) {
|
||||
// if (CollectionUtil.isNotEmpty(payDTO.getPayOrderList())) {
|
||||
// for (CaseAttach caseAttach : payDTO.getPayOrderList()) {
|
||||
// caseAttach.setCaseAppliId(caseId);
|
||||
// caseAttachMapper.updateCaseAttach(caseAttach);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// // 修改节点状态
|
||||
// //根据案件id查询案件信息
|
||||
// CaseApplication caseApplication = new CaseApplication();
|
||||
// caseApplication.setId(caseId);
|
||||
// CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
// caseApplication1.setCaseStatus(CaseApplicationConstants.PENDING_PAYMENT_CONFIRM);
|
||||
// //修改案件状态
|
||||
// int i = caseApplicationMapper.submitCaseApplication(caseApplication1);
|
||||
// if (i > 0) {
|
||||
// // 修改支付状态
|
||||
// CasePaymentRecord paymentRecord = new CasePaymentRecord();
|
||||
// paymentRecord.setPayType(payDTO.getPayType());
|
||||
// paymentRecord.setCaseId(caseId);
|
||||
// paymentRecord.setPaymentStatus(1);
|
||||
// casePaymentRecordMapper.saveRecord(paymentRecord);
|
||||
// // 新增日志
|
||||
// CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.PENDING_PAYMENT_CONFIRM, "");
|
||||
// }
|
||||
//
|
||||
// }
|
||||
|
||||
}else{
|
||||
throw new ServiceException("这个批号没有批量缴费的案件");
|
||||
@@ -359,89 +370,10 @@ public class CasePaymentServiceImpl implements ICasePaymentService {
|
||||
|
||||
if (caseApplications != null && caseApplications.size() > 0) {
|
||||
List<Long> caseIds = caseApplications.stream().map(CaseApplication::getId).collect(Collectors.toList());
|
||||
for (Long caseId : caseIds) {
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(caseId);
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_CROSSEXAMI);
|
||||
caseApplicationMapper.submitCaseApplication(caseApplication);
|
||||
//发送短信通知
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
CaseAffiliate caseAffiliate = new CaseAffiliate();
|
||||
caseAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
List<CaseAffiliate> caseAffiliates = caseAffiliateMapper.selectCaseAffiliate(caseAffiliate); //获取案件关联人信息
|
||||
if (caseAffiliates != null && caseAffiliates.size() > 0) {
|
||||
for (CaseAffiliate affiliate : caseAffiliates) {
|
||||
//获取身份类型
|
||||
int identityType = affiliate.getIdentityType();
|
||||
//查询案件详细信息
|
||||
CaseApplication caseApplication1 = caseApplicationMapper.selectCaseApplication(caseApplication);
|
||||
if (caseApplication1 == null) {
|
||||
continue;
|
||||
}
|
||||
String caseName = "仲裁"; //这里案件名称表里未定义,暂时写死
|
||||
String caseNum = caseApplication1.getCaseNum();
|
||||
if (identityType == 1) { //申请人
|
||||
request.setPhone(affiliate.getContactTelphone());
|
||||
request.setTemplateId("1928003"); //传入申请人模板id
|
||||
// 这个值,要看你的模板中是否预留了占位符,如果没有则不需要设置
|
||||
// 模板id:1928003 普通短信 案件受理通知
|
||||
String name = affiliate.getName();
|
||||
request.setTemplateParamSet(new String[]{name, caseName, caseNum});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplication.getId());
|
||||
smsSendRecord.setCaseNum(caseNum);
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + name + "用户,您的" + caseName + "案件" + caseNum + "已成功受理。";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean) {
|
||||
smsSendRecord.setSendStatus(1);
|
||||
} else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
} else { //被申请人
|
||||
|
||||
request.setPhone(affiliate.getContactTelphone());
|
||||
request.setTemplateId("1952840");
|
||||
// 1952840 尊敬的{1}用户,您的{2}案件{3}已成功受理,请点击链接:https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 选择是否应诉。如非本人操作,请忽略本短信
|
||||
String name = affiliate.getName();
|
||||
request.setTemplateParamSet(new String[]{name, caseName, caseNum});
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
//保存短信发送记录
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplication.getId());
|
||||
smsSendRecord.setCaseNum(caseNum);
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + name + "用户,您的" + caseName + "案件" + caseNum + "已成功受理,请点击链接:https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 选择是否应诉。如非本人操作,请忽略本短信";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
if (aBoolean) {
|
||||
smsSendRecord.setSendStatus(1);
|
||||
} else {
|
||||
smsSendRecord.setSendStatus(0);
|
||||
}
|
||||
smsRecordMapper.saveSmsSendRecord(smsSendRecord);
|
||||
}
|
||||
}
|
||||
//更改记录表里的支付状态和支付时间
|
||||
CasePaymentRecord casePaymentRecord = new CasePaymentRecord();
|
||||
casePaymentRecord.setPaymentStatus(1);
|
||||
casePaymentRecord.setCaseId(caseId);
|
||||
casePaymentRecord.setPaymentTime(new Date());
|
||||
casePaymentRecord.setUpdateTime(new Date());
|
||||
casePaymentRecordMapper.update(casePaymentRecord);
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.CASE_CROSSEXAMI, "");
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
BatchCaseApplication batchCaseApplication = new BatchCaseApplication();
|
||||
batchCaseApplication.setIds(caseIds);
|
||||
casePaymentService.confirmPayment(batchCaseApplication);
|
||||
|
||||
}else{
|
||||
throw new ServiceException("这个批号没有批量缴费确认的案件");
|
||||
}
|
||||
|
||||
+218
-352
@@ -4,6 +4,8 @@ import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
@@ -23,8 +25,13 @@ import com.ruoyi.common.utils.thread.ThreadPoolUtil;
|
||||
import com.ruoyi.system.domain.SysUserRole;
|
||||
import com.ruoyi.system.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.CaseApplicationDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.CaseAffiliateEntity;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseAffiliateBase;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.CaseAffiliateVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.ColumnValue;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.*;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.sendrecord.SmsRecordMapper;
|
||||
import com.ruoyi.wisdomarbitrate.task.CaseZipImportTask;
|
||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||
import com.ruoyi.wisdomarbitrate.utils.OCRUtils;
|
||||
@@ -41,11 +48,14 @@ import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.ExecutionException;
|
||||
import java.util.concurrent.Future;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
import java.util.function.Function;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.google.common.io.Files.getFileExtension;
|
||||
import static com.ruoyi.common.constant.FileTransformation.getFileName;
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.error;
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.success;
|
||||
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||
@@ -92,22 +102,29 @@ public class CaseZipImportImpl {
|
||||
// 申请人角色id
|
||||
private long roleId;
|
||||
private Integer maxCaseNum;
|
||||
@Autowired
|
||||
private CaseZipImportImpl caseZipImportImpl;
|
||||
|
||||
|
||||
@Transactional
|
||||
public AjaxResult zipImport(MultipartFile file, Long templateId) {
|
||||
/**
|
||||
* * @param applicantType 申请人类型,自然人-1,机构-2
|
||||
* * @param resType 被申请人类型,自然人-1,机构-2
|
||||
* @param file
|
||||
* @param templateId
|
||||
* @param applicantType
|
||||
* @param resType
|
||||
* @return
|
||||
*/
|
||||
@Transactional
|
||||
public AjaxResult zipImport(MultipartFile file, Long templateId,Integer applicantType,Integer resType) {
|
||||
UUID uuid = UUID.randomUUID();
|
||||
// todo
|
||||
|
||||
String targetPath = "/home/ruoyi/uploadPath/upload/unzipFile/" + uuid + "/";
|
||||
// String targetPath = "D:/home/ruoyi/uploadPath/upload/unzipFile/"+uuid+ "/";
|
||||
File zipFile = null;
|
||||
InputStream ins = null;
|
||||
try {
|
||||
ins = file.getInputStream();
|
||||
//上传的压缩包保存的路径
|
||||
// todo
|
||||
String savePath = "/home/ruoyi/uploadPath/upload/zipFile/";
|
||||
// String savePath = "D:/home/ruoyi/uploadPath/upload/zipFile/";
|
||||
String saveName = uuid + "_" + file.getOriginalFilename();
|
||||
zipFile = new File(savePath + saveName);
|
||||
inputChangeToFile(ins, zipFile);
|
||||
@@ -121,7 +138,6 @@ public class CaseZipImportImpl {
|
||||
throw new ServiceException("解压失败");
|
||||
}
|
||||
// 查询抓取规则
|
||||
// todo 批次需要再上传压缩包时用户填写
|
||||
List<FatchRule> fatchRuleList = fatchRuleMapper.listByTemplateId(templateId);
|
||||
if (CollectionUtil.isEmpty(fatchRuleList)) {
|
||||
throw new ServiceException("未设置抓取规则");
|
||||
@@ -130,34 +146,18 @@ public class CaseZipImportImpl {
|
||||
SysDictData sysDictData = new SysDictData();
|
||||
sysDictData.setDictType("case_built_type");
|
||||
List<SysDictData> dictDataList = dictDataMapper.selectDictDataList(sysDictData);
|
||||
// 查询所有的组织机构,组装成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));
|
||||
|
||||
}
|
||||
// 查询申请人角色id
|
||||
roleId = roleMapper.selectRoleIdByName("申请人");
|
||||
/**
|
||||
* 用户表已存在的用户
|
||||
*/
|
||||
List<SysUser> existUsers = userMapper.selectUserList(new SysUser());
|
||||
Map<String, SysUser> userMap = new HashMap<>();
|
||||
if (CollectionUtil.isNotEmpty(existUsers)) {
|
||||
userMap = existUsers.stream().collect(Collectors.toMap(SysUser::getPhonenumber, Function.identity(), (n1, n2) -> n2));
|
||||
}
|
||||
//查询出当天的案件编号的最大值
|
||||
String currentDay = DateUtils.dateTime();
|
||||
String caseNum = "zc" + currentDay;
|
||||
maxCaseNum = caseApplicationMapper.selectCaseNumLike(caseNum, caseNum.length());
|
||||
// 抓取内容
|
||||
Map<String, String> fatchMap = new HashMap<>();
|
||||
|
||||
// 从抓取规则表取字段和字典表取基本字段,字典表的字段名塞到基本表,is_default=1自定义字段塞到columnValue
|
||||
// 抓取规则,0-内置字段,1-自定义字段
|
||||
Map<String, List<FatchRule>> fatchRuleMap = fatchRuleList.stream().collect(Collectors.groupingBy(FatchRule::getFileName));
|
||||
|
||||
File directory = new File(targetPath);
|
||||
if (!directory.exists()) {
|
||||
throw new ServiceException("文件不存在");
|
||||
@@ -166,58 +166,74 @@ public class CaseZipImportImpl {
|
||||
if (!directory.isDirectory() || directory.listFiles() == null) {
|
||||
throw new ServiceException("未找到文件夹");
|
||||
}
|
||||
Integer maxBatchNumber = caseApplicationMapper.selectBatchNumberLike();
|
||||
if (maxBatchNumber == null) {
|
||||
maxBatchNumber = 1;
|
||||
|
||||
} else {
|
||||
maxBatchNumber = maxBatchNumber + 1;
|
||||
File[] files = directory.listFiles();
|
||||
// todo
|
||||
List<CaseApplicationDTO> caseApplications = new ArrayList<>();
|
||||
for (File file1 : files) {
|
||||
if (file1.isDirectory() && file1.listFiles() != null) {
|
||||
|
||||
}
|
||||
File[] files = directory.listFiles();
|
||||
CaseZipImportTask caseZipImportTask = null;
|
||||
try {
|
||||
caseZipImportTask = new CaseZipImportTask(this, templateId, fatchRuleList, fatchMap, fatchRuleMap, userMap, dictDataList, files , deptMap, SecurityUtils.getLoginUser(),maxBatchNumber);
|
||||
} catch (Exception e) {
|
||||
return error("导入失败");
|
||||
}
|
||||
Future<List<CaseApplication>> future = ThreadPoolUtil.submit(caseZipImportTask);
|
||||
try {
|
||||
if(future.get()!=null){
|
||||
return success("导入成功");
|
||||
for (File file2 : file1.listFiles()) {
|
||||
|
||||
CaseApplicationDTO caseApplication = caseZipImportImpl.buildCaseInfo(file2, templateId, fatchRuleList, fatchRuleMap, dictDataList, applicantType,resType);
|
||||
if (caseApplication != null) {
|
||||
caseApplications.add(caseApplication);
|
||||
}
|
||||
}
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
return success("导入失败");
|
||||
} catch (ExecutionException e) {
|
||||
|
||||
e.printStackTrace();
|
||||
return success("导入失败");
|
||||
}
|
||||
}
|
||||
if (CollectionUtil.isEmpty(caseApplications)) {
|
||||
return error("导入失败");
|
||||
}
|
||||
// CaseZipImportTask caseZipImportTask = null;
|
||||
// try {
|
||||
// caseZipImportTask = new CaseZipImportTask(this, templateId, fatchRuleList, fatchRuleMap, userMap, dictDataList, files , deptMap, SecurityUtils.getLoginUser());
|
||||
// } catch (Exception e) {
|
||||
// return error("导入失败");
|
||||
// }
|
||||
// Future<List<CaseApplication>> future = ThreadPoolUtil.submit(caseZipImportTask);
|
||||
// try {
|
||||
// if(future.get()!=null){
|
||||
// return success("导入成功");
|
||||
// }
|
||||
// } catch (InterruptedException | ExecutionException e) {
|
||||
// e.printStackTrace();
|
||||
// return error(e.getMessage());
|
||||
// }
|
||||
return success("导入成功");
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 组装案件内置字段
|
||||
* @param file
|
||||
* @param templateId
|
||||
* @param fatchRuleList
|
||||
* @param fatchRuleMap
|
||||
* @param dictDataList
|
||||
* @param applicantType 申请人类型,自然人-1,机构-2
|
||||
* @param resType 被申请人类型,自然人-1,机构-2
|
||||
* @return
|
||||
*/
|
||||
@Transactional
|
||||
public CaseApplication buildCaseInfo(File file, Long templateId, List<FatchRule> fatchRuleList, Map<String, List<FatchRule>> fatchRuleMap, Map<String, String> fatchMap, Map<String, SysUser> userMap, List<SysDictData> dictDataList, Map<String, Long> deptMap,LoginUser loginUser, Integer maxBatchNumber) {
|
||||
public CaseApplicationDTO buildCaseInfo(File file, Long templateId, List<FatchRule> fatchRuleList, Map<String, List<FatchRule>> fatchRuleMap,
|
||||
List<SysDictData> dictDataList,
|
||||
Integer applicantType,Integer resType) {
|
||||
// fileMap<caseId, List<File>>
|
||||
Map<String, String> fatchMap = new HashMap<>();
|
||||
Map<String, String> fileMap = findFile(file, fatchRuleList);
|
||||
if (fileMap != null && fileMap.size()> 0) {
|
||||
// 根据抓取规则循环抓取
|
||||
for (Map.Entry<String, List<FatchRule>> entry : fatchRuleMap.entrySet()) {
|
||||
System.out.println("根据抓取规则循环抓取======"+entry.getKey());
|
||||
getFatchContent(fileMap, entry.getKey(), fatchMap, entry.getValue());
|
||||
}
|
||||
|
||||
if (fatchMap.size() > 0) {
|
||||
|
||||
// 尊敬的{1},您的代理的案件已接入仲裁系统,复制访问https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 进入小程序进行认证注册。如非本人操作,请忽略本短信
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
request.setTemplateId("1956159");
|
||||
|
||||
// 新增的案件
|
||||
// 组装案件内置字段主表内容
|
||||
CaseApplication caseApplication = new CaseApplication();
|
||||
caseApplication.setId(IdWorkerUtil.getId());
|
||||
CaseApplicationDTO caseApplication = new CaseApplicationDTO();
|
||||
caseApplication.setTemplateId(templateId);
|
||||
Map<Integer, List<FatchRule>> defaultRuleMap = fatchRuleList.stream().collect(Collectors.groupingBy(FatchRule::getIsDefault));
|
||||
// 自定义字段,组装columnValue表
|
||||
@@ -233,172 +249,84 @@ public class CaseZipImportImpl {
|
||||
columnValue.setCaseId(caseApplication.getId());
|
||||
columnValueList.add(columnValue);
|
||||
});
|
||||
caseApplication.setColumnValues(columnValueList);
|
||||
caseApplication.setColumnValueList(columnValueList);
|
||||
}
|
||||
|
||||
// 角色用户
|
||||
List<SysUserRole> userRoleList = new ArrayList<>();
|
||||
|
||||
// 组装机构
|
||||
List<SysDept> sysDepts = new ArrayList<>();
|
||||
// 案件附件
|
||||
List<CaseAttach> caseAttachs = new ArrayList<>();
|
||||
//发送短信列表
|
||||
List<SmsSendRecord> smsSendRecordList = new ArrayList<>();
|
||||
// 短信记录
|
||||
List<SmsUtils.SendSmsRequest> smsRequestList = new ArrayList<>();
|
||||
|
||||
// 需要新增的用户
|
||||
List<SysUser> addUsers = new ArrayList<>();
|
||||
caseApplication.setCaseStatus(CaseApplicationConstants.CASE_APPLICATION);
|
||||
caseApplication.setCaseLogId(IdWorkerUtil.getId());
|
||||
caseApplication.setUpdateSubmitStatus(UpdateSubmitStatus.UNCOMMITTED.getCode());
|
||||
caseApplication.setCaseAppliId(caseApplication.getId());
|
||||
|
||||
// 设置批号
|
||||
caseApplication.setBatchNumber(maxBatchNumber);
|
||||
// 设置编号
|
||||
String maxCaseNumStr = generateCaseNum();
|
||||
caseApplication.setCaseNum(maxCaseNumStr);
|
||||
caseApplication.setCreateBy(loginUser!=null?loginUser.getUsername():"admin");
|
||||
caseApplication.setVersion(1);
|
||||
// 组装案件内置字段主表内容
|
||||
|
||||
// 组装内置字段
|
||||
buildDefaultColumn(caseApplication, dictDataList, fatchMap, deptMap, sysDepts, userMap, addUsers, userRoleList, smsSendRecordList, smsRequestList);
|
||||
buildDefaultColumn(caseApplication, dictDataList, fatchMap, applicantType,resType);
|
||||
// 组装附件
|
||||
for (Map.Entry<String, String> entry : fileMap.entrySet()) {
|
||||
String fileUrl = entry.getValue();
|
||||
if (StrUtil.isEmpty(fileUrl)) {
|
||||
continue;
|
||||
}
|
||||
// 上传
|
||||
String filePath = RuoYiConfig.getUploadPath();
|
||||
// 根据路径获取文件名
|
||||
String name = getFileName(fileUrl);
|
||||
String suffix = getFileExtension(fileUrl);
|
||||
if (StrUtil.isNotEmpty(suffix) && suffix.contains("doc")) {
|
||||
// 上传onlyoffice
|
||||
JSONArray jsonArray = caseApplicationService.uploadOnlyOffice(fileUrl,caseApplication.getId());
|
||||
if(jsonArray!=null && jsonArray.size() > 0) {
|
||||
for (Object obj : jsonArray) {
|
||||
JSONObject jsonObject = (JSONObject) obj;
|
||||
String path = jsonObject.get("filePath")!=null?jsonObject.getString("filePath"):"";
|
||||
path=path.replace("/home/ruoyi/uploadPath/","/profile/");
|
||||
// String name = jsonObject.get("fileName")!=null?jsonObject.getString("fileName"):"";
|
||||
CaseAttach caseAttach = CaseAttach.builder()
|
||||
.caseAppliId(caseApplication.getId())
|
||||
.annexName(name)
|
||||
.annexPath(path)
|
||||
.onlyOfficeFileId(jsonObject.getString("fileId"))
|
||||
.build();
|
||||
// if(jsonObject.get("filePath")!=null){
|
||||
// String officePath = jsonObject.getString("filePath");
|
||||
// String replace = officePath.replace("/home/ruoyi/uploadPath/", "/profile/");
|
||||
// caseAttach.setAnnexPath(replace);
|
||||
//
|
||||
// }
|
||||
if(fileUrl.contains("申请书")){
|
||||
CaseAttach applyFile = new CaseAttach();
|
||||
BeanUtil.copyProperties(caseAttach, applyFile);
|
||||
applyFile.setAnnexType(1);
|
||||
caseAttachs.add(applyFile);
|
||||
}
|
||||
caseAttach.setAnnexType(2);
|
||||
caseAttachs.add(caseAttach);
|
||||
|
||||
CaseAttach caseAttach = new CaseAttach();
|
||||
caseAttach.setCaseAppliId(caseApplication.getId());
|
||||
caseAttach.setAnnexPath(filePath);
|
||||
if (StrUtil.isNotEmpty(fileUrl)) {
|
||||
String fileName = fileUrl.replace(filePath, "/profile/upload");
|
||||
caseAttach.setAnnexName(fileName);
|
||||
}
|
||||
// 申请人提供的证据材料
|
||||
caseAttach.setAnnexType(2);
|
||||
caseAttachs.add(caseAttach);
|
||||
if (fileUrl.contains("仲裁申请书")) {
|
||||
CaseAttach applyFile = new CaseAttach();
|
||||
BeanUtil.copyProperties(caseAttach, applyFile);
|
||||
applyFile.setAnnexType(1);
|
||||
caseAttachs.add(applyFile);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// 上传
|
||||
String filePath = RuoYiConfig.getUploadPath();
|
||||
|
||||
CaseAttach caseAttach = new CaseAttach();
|
||||
caseAttach.setCaseAppliId(caseApplication.getId());
|
||||
filePath=fileUrl.replace("home/ruoyi/uploadPath/","profile/");
|
||||
caseAttach.setAnnexPath(filePath);
|
||||
|
||||
caseAttach.setAnnexName(name);
|
||||
|
||||
// 申请人提供的证据材料
|
||||
caseAttach.setAnnexType(2);
|
||||
caseAttachs.add(caseAttach);
|
||||
if (fileUrl.contains("申请书")) {
|
||||
CaseAttach applyFile = new CaseAttach();
|
||||
BeanUtil.copyProperties(caseAttach, applyFile);
|
||||
applyFile.setAnnexType(1);
|
||||
caseAttachs.add(applyFile);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
caseApplication.setCaseAttachList(caseAttachs);
|
||||
|
||||
// 案件压缩包导入
|
||||
caseApplication.setImportFlag(2);
|
||||
// 多线程执行
|
||||
// List<MultipleThreadListParam> execList = new ArrayList<>();
|
||||
// if (CollectionUtil.isNotEmpty(addUsers)) {
|
||||
// Function<List<SysUser>, Integer> function = userMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(function, addUsers));
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(userRoleList)) {
|
||||
// Function<List<SysUserRole>, Integer> function = userRoleMapper::batchUserRole;
|
||||
// execList.add(new MultipleThreadListParam(function, userRoleList));
|
||||
//
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(sysDepts)) {
|
||||
// Function<List<SysDept>, Integer> function = sysDeptMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(function, sysDepts));
|
||||
//
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(caseApplications)) {
|
||||
// Function<List<CaseApplication>, Integer> function = caseApplicationMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(function, caseApplications));
|
||||
// Function<List<CaseApplication>, Integer> functionLog = caseApplicationLogMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(functionLog, caseApplications));
|
||||
//
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(caseAffiliates)) {
|
||||
// Function<List<CaseAffiliate>, Integer> function = caseAffiliateMapper::batchCaseAffiliate;
|
||||
// execList.add(new MultipleThreadListParam(function, caseAffiliates));
|
||||
// Function<List<CaseAffiliate>, Integer> functionLog = caseAffiliateLogMapper::batchCaseAffiliate;
|
||||
// execList.add(new MultipleThreadListParam(functionLog, caseAffiliates));
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(caseAttachs)) {
|
||||
// Function<List<CaseAttach>, Integer> function = caseAttachMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(function, caseAttachs));
|
||||
// Function<List<CaseAttach>, Integer> functionLog = caseAttachLogMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(functionLog, caseAttachs));
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(columnValueList)) {
|
||||
// Function<List<ColumnValue>, Integer> function = columnValueMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(function, columnValueList));
|
||||
// Function<List<ColumnValue>, Integer> functionLog = columnValueLogMapper::batchSave;
|
||||
// execList.add(new MultipleThreadListParam(functionLog, columnValueList));
|
||||
// }
|
||||
// if (CollectionUtil.isNotEmpty(execList)) {
|
||||
// MultipleThreadWorkUtil.execListFun(execList.toArray(new MultipleThreadListParam[execList.size()]));
|
||||
// }
|
||||
// 多线程执行
|
||||
ThreadPoolUtil.execute(() -> {
|
||||
try {
|
||||
caseApplicationMapper.insertCaseApplication(caseApplication);
|
||||
caseApplicationLogMapper.insert(caseApplication);
|
||||
// 多线程执行
|
||||
if (CollectionUtil.isNotEmpty(addUsers)) {
|
||||
userMapper.batchSave(addUsers);
|
||||
|
||||
}
|
||||
if (CollectionUtil.isNotEmpty(userRoleList)) {
|
||||
userRoleMapper.batchUserRole(userRoleList);
|
||||
|
||||
}
|
||||
if (CollectionUtil.isNotEmpty(sysDepts)) {
|
||||
sysDeptMapper.batchSave(sysDepts);
|
||||
|
||||
}
|
||||
if (CollectionUtil.isNotEmpty(caseApplication.getCaseAffiliates())) {
|
||||
caseAffiliateMapper.batchCaseAffiliate(caseApplication.getCaseAffiliates());
|
||||
caseAffiliateLogMapper.batchCaseAffiliate(caseApplication.getCaseAffiliates());
|
||||
}
|
||||
if (CollectionUtil.isNotEmpty(caseAttachs)) {
|
||||
caseAttachMapper.batchSave(caseAttachs);
|
||||
caseAttachLogMapper.batchSave(caseAttachs);
|
||||
|
||||
}
|
||||
if (CollectionUtil.isNotEmpty(columnValueList)) {
|
||||
columnValueMapper.batchSave(columnValueList);
|
||||
columnValueLogMapper.batchSave(columnValueList);
|
||||
}
|
||||
// 新增日志
|
||||
CaseLogUtils.insertCaseLog(caseApplication.getId(), CaseApplicationConstants.CASE_APPLICATION, "",loginUser);
|
||||
// 发送短信
|
||||
if (CollectionUtil.isNotEmpty(smsRequestList)) {
|
||||
Map<Long, SmsSendRecord> sendRecordMap = null;
|
||||
if (CollectionUtil.isNotEmpty(smsSendRecordList)) {
|
||||
sendRecordMap = smsSendRecordList.stream().collect(Collectors.toMap(SmsSendRecord::getCaseId, Function.identity()));
|
||||
for (SmsUtils.SendSmsRequest sendSmsRequest : smsRequestList) {
|
||||
Boolean aBoolean = SmsUtils.sendSms(request);
|
||||
if (sendRecordMap != null && sendRecordMap.containsKey(sendSmsRequest.getCaseId())) {
|
||||
if (aBoolean) {
|
||||
sendRecordMap.get(sendSmsRequest.getCaseId()).setSendStatus(1);
|
||||
} else {
|
||||
sendRecordMap.get(sendSmsRequest.getCaseId()).setSendStatus(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
smsRecordMapper.batchSaveSmsSendRecord(smsSendRecordList);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new RuntimeException("导入失败,请检查抓取规则是否正确");
|
||||
}
|
||||
|
||||
});
|
||||
// 新增
|
||||
caseApplicationService.insertOrUpdate(caseApplication);
|
||||
return caseApplication;
|
||||
}
|
||||
}
|
||||
@@ -418,6 +346,7 @@ public class CaseZipImportImpl {
|
||||
for (Map.Entry<String, String> entry : andConvertPDF.entrySet()) {
|
||||
if(entry.getKey().contains(mapKey)){
|
||||
fileURL=entry.getValue();
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (StrUtil.isEmpty(fileURL)) {
|
||||
@@ -707,33 +636,68 @@ public class CaseZipImportImpl {
|
||||
* @param caseApplication 案件信息
|
||||
* @param dictDataList 内置字段
|
||||
* @param fatchMap 抓取字段内容
|
||||
* @param applicantType 申请人类型,自然人-1,机构-2
|
||||
* @param resType 被申请人类型,自然人-1,机构-2
|
||||
*/
|
||||
private void buildDefaultColumn(CaseApplication caseApplication, List<SysDictData> dictDataList, Map<String, String> fatchMap,
|
||||
Map<String, Long> deptMap, List<SysDept> sysDepts,
|
||||
Map<String, SysUser> userMap, List<SysUser> addUsers, List<SysUserRole> userRoleList,
|
||||
List<SmsSendRecord> smsSendRecords, List<SmsUtils.SendSmsRequest> smsRequestList) {
|
||||
private void buildDefaultColumn(CaseApplicationDTO caseApplication, List<SysDictData> dictDataList, Map<String, String> fatchMap,
|
||||
Integer applicantType,Integer resType) {
|
||||
// 组装内置字段
|
||||
if (CollectionUtil.isEmpty(dictDataList)) {
|
||||
return;
|
||||
}
|
||||
List<CaseAffiliate> caseAffiliates = new ArrayList<>();
|
||||
// 被申请人
|
||||
CaseAffiliate debtorAffiliate = new CaseAffiliate();
|
||||
debtorAffiliate.setCaseAppliId(caseApplication.getId());
|
||||
debtorAffiliate.setCaseAppliLogId(caseApplication.getCaseLogId());
|
||||
// 申请人
|
||||
CaseAffiliate affiliate = new CaseAffiliate();
|
||||
affiliate.setCaseAppliLogId(caseApplication.getCaseLogId());
|
||||
affiliate.setCaseAppliId(caseApplication.getId());
|
||||
CaseAffiliateVO affiliateVO = new CaseAffiliateVO();
|
||||
List<CaseAffiliateBase> applicantList = new ArrayList<>();
|
||||
List<CaseAffiliateBase> resList = new ArrayList<>();
|
||||
affiliateVO.setApplicant(applicantList);
|
||||
affiliateVO.setRes(resList);
|
||||
CaseAffiliateBase affiliateBase = new CaseAffiliateBase();
|
||||
|
||||
CaseAffiliateBase resBase = new CaseAffiliateBase();
|
||||
CaseAffiliateEntity applicant = new CaseAffiliateEntity();
|
||||
applicant.setRoleType(1);
|
||||
if(applicantType.equals(1)){
|
||||
// 自然人
|
||||
applicant.setOrganizeFlag(0);
|
||||
applicant.setOperatorFlag(1);
|
||||
}else {
|
||||
// 机构
|
||||
applicant.setOrganizeFlag(1);
|
||||
}
|
||||
CaseAffiliateEntity applicantAgent = new CaseAffiliateEntity();
|
||||
applicantAgent.setRoleType(2);
|
||||
applicantAgent.setOrganizeFlag(0);
|
||||
applicantAgent.setOperatorFlag(1);
|
||||
CaseAffiliateEntity res = new CaseAffiliateEntity();
|
||||
res.setRoleType(3);
|
||||
if(resType.equals(1)){
|
||||
// 自然人
|
||||
res.setOrganizeFlag(0);
|
||||
res.setOperatorFlag(1);
|
||||
}else {
|
||||
// 机构
|
||||
res.setOrganizeFlag(1);
|
||||
}
|
||||
CaseAffiliateEntity resAgent = new CaseAffiliateEntity();
|
||||
resAgent.setRoleType(4);
|
||||
resAgent.setOrganizeFlag(0);
|
||||
resAgent.setOperatorFlag(1);
|
||||
affiliateBase.setApplicant(applicant);
|
||||
affiliateBase.setApplicantAgent(applicantAgent);
|
||||
resBase.setRes(res);
|
||||
resBase.setResAgent(resAgent);
|
||||
applicantList.add(affiliateBase);
|
||||
resList.add(resBase);
|
||||
affiliateVO.setApplicant(applicantList);
|
||||
affiliateVO.setRes(resList);
|
||||
for (SysDictData dictData : dictDataList) {
|
||||
if (StrUtil.isNotEmpty(dictData.getDictLabel())) {
|
||||
if (dictData.getDictLabel().contains("被申请人")) {
|
||||
// 组装被申请人内置自段
|
||||
buildDebtorColumn(dictData, fatchMap, debtorAffiliate, caseApplication.getId());
|
||||
buildDebtorColumn(dictData, fatchMap, res,resAgent);
|
||||
} else if (dictData.getDictLabel().contains("申请人") || dictData.getDictLabel().contains("统一社会信用代码")
|
||||
|| dictData.getDictLabel().contains("法定代表人") || dictData.getDictLabel().contains("委托代理人")) {
|
||||
// 组装申请人内置自段
|
||||
buildAffilcateColumn(dictData, fatchMap, affiliate, deptMap, sysDepts, userMap, addUsers, userRoleList, caseApplication, smsSendRecords, smsRequestList);
|
||||
buildAffilcateColumn(dictData, fatchMap, caseApplication,applicant,applicantAgent);
|
||||
} else if (dictData.getDictLabel().contains("合同编号")) {
|
||||
// 合同编号
|
||||
String contractNumber = fatchMap.get("合同编号" );
|
||||
@@ -749,14 +713,10 @@ public class CaseZipImportImpl {
|
||||
try {
|
||||
BigDecimal bigDecimal = new BigDecimal(caseSubjectAmount);
|
||||
caseApplication.setCaseSubjectAmount(bigDecimal);
|
||||
// todo 案件标的名字要改,字典配置中也要改
|
||||
//todo 暂时设置计费比率为0.01
|
||||
BigDecimal feeRate = new BigDecimal(0.01);
|
||||
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
caseApplication.setFeePayable(feePayable);
|
||||
|
||||
} catch (Exception e) {
|
||||
}
|
||||
}else {
|
||||
caseApplication.setCaseSubjectAmount(BigDecimal.ZERO);
|
||||
}
|
||||
|
||||
} else {
|
||||
@@ -769,13 +729,7 @@ public class CaseZipImportImpl {
|
||||
}
|
||||
|
||||
}
|
||||
if (ObjectUtil.isNotEmpty(affiliate)) {
|
||||
caseAffiliates.add(affiliate);
|
||||
}
|
||||
if (ObjectUtil.isNotEmpty(debtorAffiliate)) {
|
||||
caseAffiliates.add(debtorAffiliate);
|
||||
}
|
||||
caseApplication.setCaseAffiliates(caseAffiliates);
|
||||
caseApplication.setAffiliate(affiliateVO);
|
||||
|
||||
}
|
||||
|
||||
@@ -784,134 +738,43 @@ public class CaseZipImportImpl {
|
||||
*
|
||||
* @param dictData 内置字段
|
||||
* @param fatchMap 抓取内容
|
||||
* @param affiliate 案件人员
|
||||
* @param applicant 申请人
|
||||
* @param applicantAgent 申请代理人
|
||||
*/
|
||||
private void buildAffilcateColumn(SysDictData dictData, Map<String, String> fatchMap, CaseAffiliate affiliate,
|
||||
Map<String, Long> deptMap, List<SysDept> sysDepts,
|
||||
Map<String, SysUser> userMap, List<SysUser> addUsers, List<SysUserRole> userRoleList, CaseApplication caseApplication,
|
||||
List<SmsSendRecord> smsSendRecords, List<SmsUtils.SendSmsRequest> smsRequestList) {
|
||||
|
||||
affiliate.setIdentityType(1);
|
||||
|
||||
private void buildAffilcateColumn(SysDictData dictData, Map<String, String> fatchMap,
|
||||
CaseApplicationDTO caseApplication,CaseAffiliateEntity applicant,
|
||||
CaseAffiliateEntity applicantAgent) {
|
||||
// 申请人
|
||||
switch (dictData.getDictLabel()) {
|
||||
case "申请人姓名":
|
||||
affiliate.setName((fatchMap.get(dictData.getDictLabel())));
|
||||
if (StrUtil.isNotEmpty(affiliate.getName())) {
|
||||
// 组装申请机构
|
||||
// 将组织机构id设为申请人名称
|
||||
if (deptMap.containsKey(affiliate.getName())) {
|
||||
affiliate.setApplicationOrganId(String.valueOf(deptMap.get(affiliate.getName())));
|
||||
affiliate.setApplicationOrganName(affiliate.getName());
|
||||
} else {
|
||||
// 如果不存在则新增
|
||||
SysDept dept = new SysDept();
|
||||
dept.setParentId(0L);
|
||||
dept.setDeptName(affiliate.getName());
|
||||
dept.setAncestors("0");
|
||||
dept.setOrderNum(1);
|
||||
dept.setStatus("0");
|
||||
dept.setDelFlag("0");
|
||||
dept.setCreateBy(getUsername());
|
||||
dept.setUpdateBy(getUsername());
|
||||
dept.setDeptId(Long.valueOf(IdWorkerUtil.getId()));
|
||||
sysDepts.add(dept);
|
||||
deptMap.put(dept.getDeptName(), dept.getDeptId());
|
||||
affiliate.setApplicationOrganId(String.valueOf(dept.getDeptId()));
|
||||
affiliate.setApplicationOrganName(affiliate.getName());
|
||||
|
||||
}
|
||||
}
|
||||
applicant.setName((fatchMap.get(dictData.getDictLabel())));
|
||||
break;
|
||||
case "统一社会信用代码":
|
||||
affiliate.setIdentityNum((fatchMap.get(dictData.getDictLabel())));
|
||||
applicant.setCode((fatchMap.get(dictData.getDictLabel())));
|
||||
break;
|
||||
case "身份证号":
|
||||
applicant.setIdCard((fatchMap.get(dictData.getDictLabel())));
|
||||
break;
|
||||
case "法定代表人":
|
||||
affiliate.setCompLegalPerson(fatchMap.get(dictData.getDictLabel()));
|
||||
applicant.setCompLegalPerson(fatchMap.get(dictData.getDictLabel()));
|
||||
break;
|
||||
case "法定代表人职位":
|
||||
affiliate.setCompLegalperPost((fatchMap.get(dictData.getDictLabel())));
|
||||
applicant.setPosition((fatchMap.get(dictData.getDictLabel())));
|
||||
break;
|
||||
case "申请人住所":
|
||||
affiliate.setResidenAffili((fatchMap.get(dictData.getDictLabel())));
|
||||
applicant.setHome((fatchMap.get(dictData.getDictLabel())));
|
||||
break;
|
||||
case "申请人联系地址":
|
||||
affiliate.setContactAddress(fatchMap.get(dictData.getDictLabel()));
|
||||
applicant.setAddress(fatchMap.get(dictData.getDictLabel()));
|
||||
break;
|
||||
case "委托代理人姓名":
|
||||
affiliate.setNameAgent(fatchMap.get(dictData.getDictLabel()));
|
||||
applicantAgent.setName(fatchMap.get(dictData.getDictLabel()));
|
||||
break;
|
||||
case "委托代理人联系电话":
|
||||
affiliate.setContactTelphoneAgent(fatchMap.get(dictData.getDictLabel()));
|
||||
if (StrUtil.isNotEmpty(affiliate.getContactTelphoneAgent())) {
|
||||
SysUser agentUser = null;
|
||||
// 用户已存在
|
||||
if (userMap.containsKey(affiliate.getContactTelphoneAgent())) {
|
||||
agentUser = userMap.get(affiliate.getContactTelphoneAgent());
|
||||
if (null != agentUser.getDeptId() && String.valueOf(agentUser.getDeptId()).equals(affiliate.getApplicationOrganId())) {
|
||||
// 同步用户表和案件关联人表的手机号和名称
|
||||
affiliate.setContactTelphoneAgent(agentUser.getPhonenumber());
|
||||
affiliate.setNameAgent(agentUser.getNickName());
|
||||
affiliate.setApplicantAgentUserId(String.valueOf(agentUser.getUserId()));
|
||||
if (StrUtil.isNotEmpty(agentUser.getIdCard())) {
|
||||
affiliate.setIdentityNumAgent(agentUser.getIdCard());
|
||||
} else {
|
||||
affiliate.setIdentityNumAgent(affiliate.getIdentityNumAgent());
|
||||
}
|
||||
List<Long> longList = new ArrayList<>();
|
||||
// 新增角色为申请人
|
||||
if (CollectionUtil.isNotEmpty(agentUser.getRoles())) {
|
||||
longList = agentUser.getRoles().stream().map(SysRole::getRoleId).collect(Collectors.toList());
|
||||
if (!longList.contains(roleId)) {
|
||||
insertAgentUserRole(agentUser, roleId, userRoleList);
|
||||
}
|
||||
} else {
|
||||
|
||||
insertAgentUserRole(agentUser, roleId, userRoleList);
|
||||
}
|
||||
|
||||
}
|
||||
} else {
|
||||
// 用户不存在,新增
|
||||
agentUser = new SysUser();
|
||||
agentUser.setUserId(Long.valueOf(IdWorkerUtil.getId()));
|
||||
agentUser.setIdCard(affiliate.getIdentityNumAgent());
|
||||
agentUser.setNickName(affiliate.getNameAgent());
|
||||
agentUser.setUserName(affiliate.getContactTelphoneAgent());
|
||||
agentUser.setPhonenumber(affiliate.getContactTelphoneAgent());
|
||||
agentUser.setPassword(SecurityUtils.encryptPassword("abc123456"));
|
||||
agentUser.setDeptId(Long.valueOf(affiliate.getApplicationOrganId()));
|
||||
addUsers.add(agentUser);
|
||||
userMap.put(agentUser.getPhonenumber(), agentUser);
|
||||
insertAgentUserRole(agentUser, roleId, userRoleList);
|
||||
|
||||
}
|
||||
if (addUsers != null) {
|
||||
SysUser finalAgentUser = agentUser;
|
||||
if (CollectionUtil.isNotEmpty(smsRequestList) && smsRequestList.stream().noneMatch(smsSendRecord -> smsSendRecord.getPhone().equals(finalAgentUser.getPhonenumber()))) {
|
||||
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
|
||||
request.setTemplateId("1956159");
|
||||
request.setPhone(agentUser.getPhonenumber());
|
||||
request.setTemplateParamSet(new String[]{agentUser.getNickName()});
|
||||
smsRequestList.add(request);
|
||||
SmsSendRecord smsSendRecord = new SmsSendRecord();
|
||||
smsSendRecord.setCaseId(caseApplication.getId());
|
||||
smsSendRecord.setCaseNum(caseApplication.getCaseNum());
|
||||
smsSendRecord.setPhone(request.getPhone());
|
||||
smsSendRecord.setSendTime(new Date());
|
||||
String content = "尊敬的" + agentUser.getNickName() + ",您的代理的案件已接入仲裁系统,复制访问https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 进入小程序进行认证注册。如非本人操作,请忽略本短信";
|
||||
smsSendRecord.setSendContent(content);
|
||||
smsSendRecord.setCreateBy(getUsername());
|
||||
smsSendRecords.add(smsSendRecord);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
applicantAgent.setPhone(fatchMap.get(dictData.getDictLabel()));
|
||||
break;
|
||||
case "委托代理人电子邮件":
|
||||
affiliate.setAgentEmail(StrUtil.isNotEmpty(fatchMap.get(dictData.getDictLabel())) ? fatchMap.get(dictData.getDictLabel()).replace("\n", "").replaceAll("\\s", "") : null);
|
||||
applicantAgent.setEmail(StrUtil.isNotEmpty(fatchMap.get(dictData.getDictLabel())) ? fatchMap.get(dictData.getDictLabel()).replace("\n", "").replaceAll("\\s", "") : null);
|
||||
break;
|
||||
default:
|
||||
ObjectFieldUtils.setValue(caseApplication, dictData.getDictValue(), fatchMap.get(dictData.getDictLabel() ));
|
||||
@@ -939,19 +802,22 @@ public class CaseZipImportImpl {
|
||||
*
|
||||
* @param dictData 内置字段
|
||||
* @param fatchMap 抓取内容
|
||||
* @param debtorAffiliate 被申请人
|
||||
* @param res 被申请人
|
||||
* @param resAgent 被申请人代理
|
||||
*/
|
||||
private void buildDebtorColumn(SysDictData dictData, Map<String, String> fatchMap, CaseAffiliate debtorAffiliate, Long caseId) {
|
||||
private void buildDebtorColumn(SysDictData dictData, Map<String, String> fatchMap,CaseAffiliateEntity res,CaseAffiliateEntity resAgent) {
|
||||
|
||||
debtorAffiliate.setIdentityType(2);
|
||||
// 被申请人
|
||||
// 被申请人在。
|
||||
switch (dictData.getDictLabel()) {
|
||||
case "被申请人姓名":
|
||||
debtorAffiliate.setName(fatchMap.get(dictData.getDictLabel() ));
|
||||
res.setName(fatchMap.get(dictData.getDictLabel() ));
|
||||
break;
|
||||
case "被申请人":
|
||||
res.setName(fatchMap.get(dictData.getDictLabel() ));
|
||||
break;
|
||||
case "被申请人身份证号":
|
||||
String identityNum = fatchMap.get(dictData.getDictLabel() );
|
||||
debtorAffiliate.setIdentityNum(fatchMap.get(dictData.getDictLabel() ));
|
||||
res.setIdCard(fatchMap.get(dictData.getDictLabel() ));
|
||||
// 出生年月日,从身份证抓取
|
||||
if (StrUtil.isNotEmpty(identityNum)) {
|
||||
identityNum = identityNum.replace("\n", "");
|
||||
@@ -965,21 +831,21 @@ public class CaseZipImportImpl {
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
debtorAffiliate.setResponBirth(birthdayDate);
|
||||
res.setBirth(birthdayDate);
|
||||
}
|
||||
//从身份证抓取性别
|
||||
debtorAffiliate.setResponSex(identityNumMap.get("sexCode"));
|
||||
res.setSex(identityNumMap.get("sexCode"));
|
||||
}
|
||||
|
||||
break;
|
||||
case "被申请人住所":
|
||||
debtorAffiliate.setResidenAffili(fatchMap.get(dictData.getDictLabel() ));
|
||||
res.setHome(fatchMap.get(dictData.getDictLabel() ));
|
||||
break;
|
||||
case "被申请人联系电话":
|
||||
debtorAffiliate.setContactTelphone(fatchMap.get(dictData.getDictLabel() ));
|
||||
res.setPhone(fatchMap.get(dictData.getDictLabel() ));
|
||||
break;
|
||||
case "被申请人电子邮件":
|
||||
debtorAffiliate.setEmail(StrUtil.isNotEmpty(fatchMap.get(dictData.getDictLabel() )) ? fatchMap.get(dictData.getDictLabel() ).replace("\n", "").replaceAll("\\s", "") : null);
|
||||
res.setEmail(StrUtil.isNotEmpty(fatchMap.get(dictData.getDictLabel() )) ? fatchMap.get(dictData.getDictLabel() ).replace("\n", "").replaceAll("\\s", "") : null);
|
||||
|
||||
break;
|
||||
default:
|
||||
|
||||
+4
-4
@@ -248,12 +248,12 @@ public class DeptIdentifyServiceImpl implements IDeptIdentifyService {
|
||||
if (downLoadFile) {
|
||||
CaseAttach caseAttach = new CaseAttach();
|
||||
caseAttach.setAnnexType(10); //10代表印章图片
|
||||
caseAttach.setAnnexPath(savePath);
|
||||
caseAttach.setAnnexName(saveName);
|
||||
caseAttach.setAnnexPath(saveName);
|
||||
caseAttach.setAnnexName(fileName);
|
||||
int i1 = caseAttachMapper.save(caseAttach);
|
||||
if (i1 > 0) {
|
||||
//将附件id保存到公章管理表里
|
||||
Integer annexId1 = caseAttach.getAnnexId();
|
||||
Long annexId1 = caseAttach.getAnnexId();
|
||||
SealManage sealManage = new SealManage();
|
||||
sealManage.setSealId(sealId);
|
||||
List<SealManage> selectSealList = sealManageMapper.selectSealList(sealManage);
|
||||
@@ -287,7 +287,7 @@ public class DeptIdentifyServiceImpl implements IDeptIdentifyService {
|
||||
List<SealManage> selectSealList = sealManageMapper.selectSealList(sealManage);
|
||||
if (selectSealList != null && selectSealList.size() > 0) {
|
||||
for (SealManage sealManage1 : selectSealList) {
|
||||
Integer annexId = sealManage1.getAnnexId();
|
||||
Long annexId = sealManage1.getAnnexId();
|
||||
if (annexId != null) {
|
||||
//根据附件id查询路径
|
||||
CaseAttach caseAttach = caseAttachMapper.queryAnnexById(annexId);
|
||||
|
||||
+76
@@ -0,0 +1,76 @@
|
||||
package com.ruoyi.wisdomarbitrate.service.impl;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.JsonArray;
|
||||
import com.google.gson.JsonObject;
|
||||
import com.ruoyi.common.constant.FileTransformation;
|
||||
import com.ruoyi.common.core.domain.entity.EsignHttpResponse;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.common.utils.file.SaaSAPIFileUtils;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.CaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.CaseAttachMapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.time.LocalDate;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* 下载文件
|
||||
*/
|
||||
@Service
|
||||
public class DownFileService {
|
||||
@Autowired
|
||||
CaseAttachMapper caseAttachMapper;
|
||||
|
||||
/**
|
||||
* 从E签宝下载签署完成后的PDF文件
|
||||
*/
|
||||
public void downPdfFileFormEsign(String signFlowId, Long caseAppliId) throws EsignDemoException, IOException {
|
||||
Gson gson = new Gson();
|
||||
EsignHttpResponse fileDownload = SaaSAPIFileUtils.fileDownloadUrl(signFlowId);
|
||||
JsonObject fileDownloadJsonObject = gson.fromJson(fileDownload.getBody(), JsonObject.class);
|
||||
JsonObject fileDownloadData = fileDownloadJsonObject.getAsJsonObject("data");
|
||||
JsonArray filesArray = fileDownloadData.get("files").getAsJsonArray();
|
||||
if (filesArray != null && filesArray.size() > 0) {
|
||||
JsonObject fileObject = (JsonObject) filesArray.get(0);
|
||||
String fileDownloadUrl = fileObject.get("downloadUrl").toString();
|
||||
LocalDate now = LocalDate.now();
|
||||
String year = Integer.toString(now.getYear());
|
||||
String month = String.format("%02d", now.getMonthValue());
|
||||
String day = String.format("%02d", now.getDayOfMonth());
|
||||
String saveFolderPath = "/home/ruoyi/uploadPath/upload/" + year + "/" + month + "/" + day;
|
||||
String fileName = UUID.randomUUID().toString().replace("-", "") + ".pdf";
|
||||
String saveName = "/profile/upload/" + year + "/" + month + "/" + day + "/" + fileName;
|
||||
String savePath = "/home/ruoyi/uploadPath/upload/";
|
||||
// 创建日期目录
|
||||
File saveFolder = new File(saveFolderPath);
|
||||
if (!saveFolder.exists()) {
|
||||
saveFolder.mkdirs();
|
||||
}
|
||||
String resultFilePath = saveFolderPath + "/" + fileName;
|
||||
File resultFilePathFile = new File(resultFilePath);
|
||||
if (!resultFilePathFile.exists()) {
|
||||
resultFilePathFile.createNewFile();
|
||||
}
|
||||
String fileDownloadUrlnew = fileDownloadUrl.substring(1, fileDownloadUrl.length() - 1);
|
||||
boolean downLoadFile = FileTransformation.downLoadFileByUrl(fileDownloadUrlnew, resultFilePath);
|
||||
if (downLoadFile) {
|
||||
//立案申请书(1)、申请人证据材料(2)、裁决书(3)、案件视频(4)、身份证件(5)、
|
||||
// 被申请人证据材料 (6)、庭审笔录(7)、缴费凭证(8)、视频录制(9)、公章图片(10)、语音转录文件(11)
|
||||
caseAttachMapper.deleteCaseAttachByCasedIdAndType(caseAppliId, 3);
|
||||
CaseAttach caseAttach = new CaseAttach();
|
||||
caseAttach.setCaseAppliId(caseAppliId);
|
||||
caseAttach.setAnnexType(3);
|
||||
caseAttach.setAnnexPath(saveName);
|
||||
caseAttach.setAnnexName("裁决书.pdf");
|
||||
caseAttachMapper.save(caseAttach);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user