功能优化
This commit is contained in:
+6
-6
@@ -9,7 +9,7 @@
|
||||
u.nickName name,
|
||||
u.id_type idType,
|
||||
r.role_name roleName,
|
||||
GROUP_CONCAT( DISTINCT CASE WHEN c.organize_flag = 0 THEN u.nick_name ELSE d.dept_name END ) AS name,
|
||||
GROUP_CONCAT( DISTINCT CASE WHEN a1.organize_flag = 0 THEN u.nick_name ELSE d.dept_name END ) AS name,
|
||||
(select GROUP_CONCAT( DISTINCT u1.nick_name ) FROM
|
||||
|
||||
ms_case_affiliate a1
|
||||
@@ -39,13 +39,13 @@
|
||||
group by a.case_appli_id
|
||||
</select>
|
||||
<select id="selectByCaseId" resultType="com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseAffiliate">
|
||||
select c.id caseAppliId,a.id,a.role_type roleType,a.group_order groupOrder,a.operator_flag operatorFlag,d.code,d.comp_legal_person compLegalPerson,u.id_card idCard,u.phonenumber phone,
|
||||
u.email,
|
||||
select c.id caseAppliId,r.role_id roleId,a.id,a.role_type roleType,a.group_order groupOrder,a.operator_flag operatorFlag,d.code,d.comp_legal_person compLegalPerson,u.id_card idCard,u.phonenumber phone,
|
||||
u.email,u.user_name userName,
|
||||
(case when a.user_id is null then d.dept_name else u.nick_name end) name,
|
||||
(case when a.user_id is null then d.home else u.home end) home,
|
||||
(case when a.user_id is null then d.address else u.address end) address,
|
||||
(case when a.user_id is null then d.nationality else u.nationality end) nationality,
|
||||
u.sex,u.id_type idType,u.birth,a.user_id userId,c.organize_flag organizeFlag,c.case_source caseSource,d.dept_name applicantOrgName
|
||||
u.sex,u.id_type idType,u.birth,a.user_id userId,a.organize_flag organizeFlag,c.case_source caseSource,d.dept_name applicantOrgName
|
||||
FROM
|
||||
ms_case_application c
|
||||
JOIN ms_case_affiliate a ON a.case_appli_id=#{id} and c.id = a.case_appli_id
|
||||
@@ -54,7 +54,7 @@
|
||||
LEFT JOIN ms_sys_role r ON r.role_id = ur.role_id
|
||||
LEFT JOIN ms_sys_dept d ON d.dept_id = a.applicant_dept_id
|
||||
where c.id = #{id}
|
||||
GROUP BY a.id order by a.id asc
|
||||
GROUP BY a.id,r.role_id order by a.id asc
|
||||
</select>
|
||||
<select id="selectUserRoleByCaseIds" resultType="com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseAffiliate">
|
||||
select c.id caseAppliId,a.id,a.role_type roleType,a.group_order groupOrder,a.operator_flag operatorFlag,d.code,d.comp_legal_person compLegalPerson,u.id_card idCard,u.phonenumber phone,
|
||||
@@ -63,7 +63,7 @@
|
||||
(case when a.user_id is null then d.home else u.home end) home,
|
||||
(case when a.user_id is null then d.address else u.address end) address,
|
||||
(case when a.user_id is null then d.nationality else u.nationality end) nationality,
|
||||
u.sex,u.id_type idType,u.birth,r.role_name roleName,d.dept_name applicantOrgName,a.user_id userId,a.applicant_dept_id applicantDeptId,c.organize_flag organizeFlag,c.case_source caseSource
|
||||
u.sex,u.id_type idType,u.birth,r.role_name roleName,d.dept_name applicantOrgName,a.user_id userId,a.applicant_dept_id applicantDeptId,a.organize_flag organizeFlag,c.case_source caseSource
|
||||
FROM
|
||||
ms_case_application c
|
||||
JOIN ms_case_affiliate a ON c.id = a.case_appli_id
|
||||
|
||||
Reference in New Issue
Block a user