Bladeren bron

Merge branch 'dev' of http://git.xayunmei.com/SH-Arbitrate/Arbitrate-Backend into qtz3

qitz 2 jaren geleden
bovenliggende
commit
c5c7b7ba9f

+ 2
- 1
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/mapper/CaseEvidenceMapper.java Bestand weergeven

11
 public interface CaseEvidenceMapper {
11
 public interface CaseEvidenceMapper {
12
     List<CaseEvidenceVO> getCaseListByRespondent(@Param(value = "identityNum" ) String identityNum
12
     List<CaseEvidenceVO> getCaseListByRespondent(@Param(value = "identityNum" ) String identityNum
13
             , @Param(value = "caseStatusList") List<Integer> caseStatusList
13
             , @Param(value = "caseStatusList") List<Integer> caseStatusList
14
-            , @Param(value = "identityType" ) Integer identityType);
14
+            , @Param(value = "identityType" ) Integer identityType
15
+    );
15
 }
16
 }

+ 29
- 8
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseEvidenceServiceImpl.java Bestand weergeven

4
 import com.ruoyi.common.config.RuoYiConfig;
4
 import com.ruoyi.common.config.RuoYiConfig;
5
 import com.ruoyi.common.constant.CaseApplicationConstants;
5
 import com.ruoyi.common.constant.CaseApplicationConstants;
6
 import com.ruoyi.common.core.domain.AjaxResult;
6
 import com.ruoyi.common.core.domain.AjaxResult;
7
+import com.ruoyi.common.core.domain.entity.SysRole;
8
+import com.ruoyi.common.core.domain.entity.SysUser;
7
 import com.ruoyi.common.core.domain.model.LoginUser;
9
 import com.ruoyi.common.core.domain.model.LoginUser;
8
 import com.ruoyi.common.utils.SecurityUtils;
10
 import com.ruoyi.common.utils.SecurityUtils;
9
 import com.ruoyi.common.utils.StringUtils;
11
 import com.ruoyi.common.utils.StringUtils;
10
 import com.ruoyi.common.utils.spring.SpringUtils;
12
 import com.ruoyi.common.utils.spring.SpringUtils;
13
+import com.ruoyi.system.mapper.SysUserMapper;
11
 import com.ruoyi.wisdomarbitrate.domain.vo.CaseEvidenceDirectoryVO;
14
 import com.ruoyi.wisdomarbitrate.domain.vo.CaseEvidenceDirectoryVO;
12
 import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
15
 import com.ruoyi.wisdomarbitrate.utils.CaseLogUtils;
13
 import com.ruoyi.common.utils.file.FileUploadUtils;
16
 import com.ruoyi.common.utils.file.FileUploadUtils;
41
     @Autowired
44
     @Autowired
42
     private CaseAttachMapper caseAttachMapper;
45
     private CaseAttachMapper caseAttachMapper;
43
     @Autowired
46
     @Autowired
44
-    private CaseLogRecordMapper caseLogRecordMapper;
45
-    @Autowired
46
     private CaseEvidenceDirectoryMapper caseEvidenceDirectoryMapper;
47
     private CaseEvidenceDirectoryMapper caseEvidenceDirectoryMapper;
48
+    @Autowired
49
+    private SysUserMapper sysUserMapper;
47
 
50
 
48
     @Override
51
     @Override
49
     @Transactional
52
     @Transactional
135
 
138
 
136
     @Override
139
     @Override
137
     public List<CaseEvidenceVO> getCaseListAll(String identityNum) {
140
     public List<CaseEvidenceVO> getCaseListAll(String identityNum) {
141
+        // 是否为超级管理员
142
+        int adMinFlag=0;
138
         if (StringUtils.isBlank(identityNum)) {
143
         if (StringUtils.isBlank(identityNum)) {
139
-            LoginUser loginUser = SecurityUtils.getLoginUser();
140
-            String username = loginUser.getUsername();
141
             IdentityAuthentication authentication = new IdentityAuthentication();
144
             IdentityAuthentication authentication = new IdentityAuthentication();
142
-            authentication.setUserName(username);
143
-            IdentityAuthentication authentication1 = identityAuthenticationMapper.selectIdentityAuthentication(authentication);
144
-            if (authentication1 != null) {
145
-                identityNum = authentication1.getIdentityNo();
145
+            LoginUser loginUser = SecurityUtils.getLoginUser();
146
+            // 查询该用户的角色
147
+            // 查询登录人身份证号
148
+            SysUser sysUser = sysUserMapper.selectUserById(loginUser.getUserId());
149
+            String username = sysUser.getUserName();
150
+            List<SysRole> roles = sysUser.getRoles();
151
+            if(CollectionUtil.isNotEmpty(roles)){
152
+                for (SysRole role : roles) {
153
+                    if(role.getRoleName().equals("超级管理员")
154
+                    ){
155
+                        // 超级管理员可查看所有待案件质证的案件
156
+                        adMinFlag=1;
157
+                        break;
158
+                    }
159
+                }
146
             }
160
             }
161
+          if(adMinFlag!=1) {
162
+              authentication.setUserName(username);
163
+              IdentityAuthentication authentication1 = identityAuthenticationMapper.selectIdentityAuthentication(authentication);
164
+              if (authentication1 != null) {
165
+                  identityNum = authentication1.getIdentityNo();
166
+              }
167
+          }
147
         }
168
         }
148
         List<Integer> caseStatusList = Arrays.asList(CaseApplicationConstants.CASE_CROSSEXAMI);
169
         List<Integer> caseStatusList = Arrays.asList(CaseApplicationConstants.CASE_CROSSEXAMI);
149
         return getCaseEvidenceVOList(identityNum, caseStatusList, 2);
170
         return getCaseEvidenceVOList(identityNum, caseStatusList, 2);

+ 2
- 0
ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml Bestand weergeven

67
         when 9 then '待书面审理' when 10 then '待生成仲裁文书' when 11 then '待核验仲裁文书'
67
         when 9 then '待书面审理' when 10 then '待生成仲裁文书' when 11 then '待核验仲裁文书'
68
         when 12 then '待审核仲裁文书' when 13 then '待仲裁文书签名' when 14 then '待仲裁文书用印'
68
         when 12 then '待审核仲裁文书' when 13 then '待仲裁文书签名' when 14 then '待仲裁文书用印'
69
         when 15 then '待仲裁文书送达' when 16 then '待案件归档' when 17 then '已归档'
69
         when 15 then '待仲裁文书送达' when 16 then '待案件归档' when 17 then '已归档'
70
+        when 31 then '待修改开庭时间'
70
         ELSE '无案件状态'
71
         ELSE '无案件状态'
71
         END caseStatusName,
72
         END caseStatusName,
72
         c.hear_date ,c.arbitrat_claims ,
73
         c.hear_date ,c.arbitrat_claims ,
239
         when 9 then '待书面审理' when 10 then '待生成仲裁文书' when 11 then '待核验仲裁文书'
240
         when 9 then '待书面审理' when 10 then '待生成仲裁文书' when 11 then '待核验仲裁文书'
240
         when 12 then '待审核仲裁文书' when 13 then '待仲裁文书签名' when 14 then '待仲裁文书用印'
241
         when 12 then '待审核仲裁文书' when 13 then '待仲裁文书签名' when 14 then '待仲裁文书用印'
241
         when 15 then '待仲裁文书送达' when 16 then '待案件归档' when 17 then '已归档'
242
         when 15 then '待仲裁文书送达' when 16 then '待案件归档' when 17 then '已归档'
243
+        when 31 then '待修改开庭时间'
242
         ELSE '无案件状态'
244
         ELSE '无案件状态'
243
         END caseStatusName,
245
         END caseStatusName,
244
         c.hear_date ,c.arbitrat_claims ,
246
         c.hear_date ,c.arbitrat_claims ,

+ 1
- 1
ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseEvidenceMapper.xml Bestand weergeven

16
             and d.identity_num = #{identityNum}
16
             and d.identity_num = #{identityNum}
17
         </if>
17
         </if>
18
         <if test="identityType != null ">
18
         <if test="identityType != null ">
19
-            and identity_type = #{identityType}
19
+            and d.identity_type = #{identityType}
20
         </if>
20
         </if>
21
         <if test="caseStatusList != null and caseStatusList.size() > 0">
21
         <if test="caseStatusList != null and caseStatusList.size() > 0">
22
             and c.case_status in
22
             and c.case_status in