优化小程序查询案件列表接口
This commit is contained in:
+8
-5
@@ -38,7 +38,7 @@ public class CaseEvidenceController extends BaseController {
|
|||||||
@GetMapping("/{id}")
|
@GetMapping("/{id}")
|
||||||
public AjaxResult getCaseDetailsById(@PathVariable Long id) {
|
public AjaxResult getCaseDetailsById(@PathVariable Long id) {
|
||||||
String username = this.getUsername();
|
String username = this.getUsername();
|
||||||
return caseEvidenceService.getCaseDetailsById(id,username);
|
return caseEvidenceService.getCaseDetailsById(id, username);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -53,16 +53,17 @@ public class CaseEvidenceController extends BaseController {
|
|||||||
public AjaxResult uploadEvidence(@RequestParam("file") MultipartFile file, Integer annexType, Long id) {
|
public AjaxResult uploadEvidence(@RequestParam("file") MultipartFile file, Integer annexType, Long id) {
|
||||||
String username = this.getUsername();
|
String username = this.getUsername();
|
||||||
Long userId = this.getUserId();
|
Long userId = this.getUserId();
|
||||||
return caseEvidenceService.uploadEvidence(file, annexType, id,username,userId);
|
return caseEvidenceService.uploadEvidence(file, annexType, id, username, userId);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询当前用户案件列表
|
* 查询当前用户案件列表
|
||||||
|
*
|
||||||
* @param identityNum
|
* @param identityNum
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("/all")
|
@GetMapping("/all")
|
||||||
public TableDataInfo getCaseListAll(@RequestParam String identityNum) {
|
public TableDataInfo getCaseListAll(@RequestParam(required = false) String identityNum) {
|
||||||
startPage();
|
startPage();
|
||||||
List<CaseEvidenceVO> list = caseEvidenceService.getCaseListAll(identityNum);
|
List<CaseEvidenceVO> list = caseEvidenceService.getCaseListAll(identityNum);
|
||||||
if (list != null) {
|
if (list != null) {
|
||||||
@@ -73,21 +74,23 @@ public class CaseEvidenceController extends BaseController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 证据确认
|
* 证据确认
|
||||||
|
*
|
||||||
* @param caseApplication 案件对象
|
* @param caseApplication 案件对象
|
||||||
* @return 统一返回结果
|
* @return 统一返回结果
|
||||||
*/
|
*/
|
||||||
@PutMapping("/confirm")
|
@PutMapping("/confirm")
|
||||||
public AjaxResult evidenceConfirmation(@Validated @RequestBody CaseApplication caseApplication){
|
public AjaxResult evidenceConfirmation(@Validated @RequestBody CaseApplication caseApplication) {
|
||||||
return caseEvidenceService.evidenceConfirmation(caseApplication);
|
return caseEvidenceService.evidenceConfirmation(caseApplication);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 案件质证
|
* 案件质证
|
||||||
|
*
|
||||||
* @param caseEvidenceDTO
|
* @param caseEvidenceDTO
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping("/crossexami")
|
@PostMapping("/crossexami")
|
||||||
public AjaxResult caseCrossexamination(@Validated @RequestBody CaseEvidenceDTO caseEvidenceDTO){
|
public AjaxResult caseCrossexamination(@Validated @RequestBody CaseEvidenceDTO caseEvidenceDTO) {
|
||||||
return caseEvidenceService.caseCrossexamination(caseEvidenceDTO);
|
return caseEvidenceService.caseCrossexamination(caseEvidenceDTO);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+15
-1
@@ -3,6 +3,9 @@ package com.ruoyi.wisdomarbitrate.service.impl;
|
|||||||
import com.ruoyi.common.config.RuoYiConfig;
|
import com.ruoyi.common.config.RuoYiConfig;
|
||||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||||
|
import com.ruoyi.common.utils.SecurityUtils;
|
||||||
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
|
||||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||||
import com.ruoyi.wisdomarbitrate.domain.*;
|
import com.ruoyi.wisdomarbitrate.domain.*;
|
||||||
@@ -118,10 +121,21 @@ public class CaseEvidenceServiceImpl implements ICaseEvidenceService {
|
|||||||
|
|
||||||
return AjaxResult.error("上传失败");
|
return AjaxResult.error("上传失败");
|
||||||
}
|
}
|
||||||
|
@Autowired
|
||||||
|
IdentityAuthenticationMapper identityAuthenticationMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<CaseEvidenceVO> getCaseListAll(String identityNum) {
|
public List<CaseEvidenceVO> getCaseListAll(String identityNum) {
|
||||||
|
if(StringUtils.isBlank(identityNum)){
|
||||||
|
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||||
|
String username = loginUser.getUsername();
|
||||||
|
IdentityAuthentication authentication=new IdentityAuthentication();
|
||||||
|
authentication.setUserName(username);
|
||||||
|
IdentityAuthentication authentication1 = identityAuthenticationMapper.selectIdentityAuthentication(authentication);
|
||||||
|
if(authentication1!=null){
|
||||||
|
identityNum = authentication1.getIdentityNo();
|
||||||
|
}
|
||||||
|
}
|
||||||
List<Integer> caseStatusList = Arrays.asList(CaseApplicationConstants.CASE_CROSSEXAMI);
|
List<Integer> caseStatusList = Arrays.asList(CaseApplicationConstants.CASE_CROSSEXAMI);
|
||||||
return getCaseEvidenceVOList(identityNum, caseStatusList, null);
|
return getCaseEvidenceVOList(identityNum, caseStatusList, null);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user