|
|
|
@ -417,57 +417,7 @@ |
|
|
|
|
and p.project_name like CONCAT('%',#{keyword},'%') |
|
|
|
|
</if> |
|
|
|
|
</select> |
|
|
|
|
<select id="selectProjectAssessmentByCompetition" |
|
|
|
|
resultType="com.huoran.common.entity.ProjectManage"> |
|
|
|
|
SELECT |
|
|
|
|
sort, |
|
|
|
|
m.*, |
|
|
|
|
'系统内置' AS schoolName, |
|
|
|
|
'系统内置' AS createUser, |
|
|
|
|
IFNULL( |
|
|
|
|
( |
|
|
|
|
SELECT |
|
|
|
|
GROUP_CONCAT( role_name ) AS roleName |
|
|
|
|
FROM |
|
|
|
|
nakadai.acl_user_role ur |
|
|
|
|
INNER JOIN nakadai.acl_role r ON r.id = ur.role_id |
|
|
|
|
WHERE |
|
|
|
|
account_id = m.account_id |
|
|
|
|
AND r.platform_id = 1 |
|
|
|
|
AND is_del = 0 |
|
|
|
|
), |
|
|
|
|
'中台超管' |
|
|
|
|
) AS roleName,sc.system_name |
|
|
|
|
FROM |
|
|
|
|
nakadai.curriculum_configure cc |
|
|
|
|
INNER JOIN nakadai.curriculum c ON c.cid = cc.cid |
|
|
|
|
INNER JOIN ol_project_manage m ON m.project_id = cc.project_id |
|
|
|
|
left join nakadai.service_configuration sc on sc.system_id = m.system_id |
|
|
|
|
WHERE |
|
|
|
|
cc.is_show = 0 |
|
|
|
|
AND cc.is_del = 0 |
|
|
|
|
AND m.is_del = 0 |
|
|
|
|
AND m.zt_del = 0 |
|
|
|
|
AND zt_open = 0 |
|
|
|
|
AND FIND_IN_SET( c.cid, #{req.cid} ) |
|
|
|
|
AND m.founder = 0 |
|
|
|
|
<if test="req.systemId !=null"> |
|
|
|
|
AND FIND_IN_SET(m.system_id ,#{req.systemId}) |
|
|
|
|
</if> |
|
|
|
|
|
|
|
|
|
<if test="req.permissions !=null"> |
|
|
|
|
and m.permissions = #{req.permissions} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.state !=null"> |
|
|
|
|
and m.state = #{req.state} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.projectName !=null and req.projectName != ''"> |
|
|
|
|
and m.project_name LIKE CONCAT('%',#{req.projectName},'%') |
|
|
|
|
</if> |
|
|
|
|
ORDER BY |
|
|
|
|
cc.sort ASC,cc.config_id asc |
|
|
|
|
|
|
|
|
|
</select> |
|
|
|
|
<select id="selectSystemName" resultType="java.lang.String"> |
|
|
|
|
select system_name from nakadai.service_configuration where system_id = #{systemId} |
|
|
|
|
</select> |
|
|
|
@ -585,7 +535,7 @@ |
|
|
|
|
sort, |
|
|
|
|
m.*, |
|
|
|
|
'系统内置' AS schoolName, |
|
|
|
|
'系统内置' AS createUser, |
|
|
|
|
'系统内置' AS createUser,u.user_name, |
|
|
|
|
IFNULL( |
|
|
|
|
( |
|
|
|
|
SELECT |
|
|
|
@ -604,6 +554,8 @@ |
|
|
|
|
nakadai.curriculum_configure cc |
|
|
|
|
INNER JOIN nakadai.curriculum c ON c.cid = cc.cid |
|
|
|
|
INNER JOIN ol_project_manage m ON m.project_id = cc.project_id |
|
|
|
|
left JOIN nakadai.hr_user_account ua ON ua.id = m.account_id |
|
|
|
|
left JOIN nakadai.hr_user_info u ON u.user_id = ua.user_id |
|
|
|
|
left join nakadai.service_configuration sc on sc.system_id = m.system_id |
|
|
|
|
WHERE |
|
|
|
|
cc.is_show = 0 |
|
|
|
@ -812,4 +764,165 @@ |
|
|
|
|
|
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectProjectAssessmentByCompetition" |
|
|
|
|
resultType="com.huoran.common.entity.ProjectManage"> |
|
|
|
|
SELECT |
|
|
|
|
sort, |
|
|
|
|
m.*,u.user_name, |
|
|
|
|
'系统内置' AS schoolName, |
|
|
|
|
'系统内置' AS createUser, |
|
|
|
|
IFNULL( |
|
|
|
|
( |
|
|
|
|
SELECT |
|
|
|
|
GROUP_CONCAT( role_name ) AS roleName |
|
|
|
|
FROM |
|
|
|
|
nakadai.acl_user_role ur |
|
|
|
|
INNER JOIN nakadai.acl_role r ON r.id = ur.role_id |
|
|
|
|
WHERE |
|
|
|
|
account_id = m.account_id |
|
|
|
|
AND r.platform_id = 1 |
|
|
|
|
AND is_del = 0 |
|
|
|
|
), |
|
|
|
|
'中台超管' |
|
|
|
|
) AS roleName,sc.system_name |
|
|
|
|
FROM |
|
|
|
|
nakadai.curriculum_configure cc |
|
|
|
|
INNER JOIN nakadai.curriculum c ON c.cid = cc.cid |
|
|
|
|
INNER JOIN ol_project_manage m ON m.project_id = cc.project_id |
|
|
|
|
left JOIN nakadai.hr_user_account ua ON ua.id = m.account_id |
|
|
|
|
left JOIN nakadai.hr_user_info u ON u.user_id = ua.user_id |
|
|
|
|
left join nakadai.service_configuration sc on sc.system_id = m.system_id |
|
|
|
|
WHERE |
|
|
|
|
cc.is_show = 0 |
|
|
|
|
AND cc.is_del = 0 |
|
|
|
|
AND m.is_del = 0 |
|
|
|
|
AND m.zt_del = 0 |
|
|
|
|
AND zt_open = 0 |
|
|
|
|
AND FIND_IN_SET( c.cid, #{req.cid} ) |
|
|
|
|
AND m.founder = 0 |
|
|
|
|
<if test="req.systemId !=null"> |
|
|
|
|
AND FIND_IN_SET(m.system_id ,#{req.systemId}) |
|
|
|
|
</if> |
|
|
|
|
|
|
|
|
|
<if test="req.permissions !=null"> |
|
|
|
|
and m.permissions = #{req.permissions} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.state !=null"> |
|
|
|
|
and m.state = #{req.state} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.projectName !=null and req.projectName != ''"> |
|
|
|
|
and m.project_name LIKE CONCAT('%',#{req.projectName},'%') |
|
|
|
|
</if> |
|
|
|
|
ORDER BY |
|
|
|
|
cc.sort ASC,cc.config_id asc |
|
|
|
|
|
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
<select id="selectAllProjectByCompetition" resultType="com.huoran.common.entity.ProjectManage"> |
|
|
|
|
SELECT |
|
|
|
|
NULL AS sort, |
|
|
|
|
m.project_id, |
|
|
|
|
m.project_name, |
|
|
|
|
m.permissions, |
|
|
|
|
m.system_id, |
|
|
|
|
m.account_id, |
|
|
|
|
m.school_id, |
|
|
|
|
m.founder, |
|
|
|
|
m.state, |
|
|
|
|
m.remark, |
|
|
|
|
m.mall_id, |
|
|
|
|
u.user_name, |
|
|
|
|
s.school_name AS schoolName, |
|
|
|
|
'老师' AS roleName, |
|
|
|
|
sc.system_name,m.create_time |
|
|
|
|
FROM |
|
|
|
|
ol_project_manage m |
|
|
|
|
LEFT JOIN nakadai.service_configuration sc ON sc.system_id = m.system_id |
|
|
|
|
LEFT JOIN nakadai.hr_user_account ua ON ua.id = m.account_id |
|
|
|
|
LEFT JOIN nakadai.hr_user_info u ON u.user_id = ua.user_id |
|
|
|
|
LEFT JOIN nakadai.school s ON s.school_id = m.school_id |
|
|
|
|
WHERE |
|
|
|
|
m.is_del = 0 |
|
|
|
|
AND m.school_id = #{req.schoolId} |
|
|
|
|
AND m.zt_del = 0 |
|
|
|
|
AND m.zt_open = 0 |
|
|
|
|
AND m.is_open = 0 |
|
|
|
|
<if test="req.systemId !=null"> |
|
|
|
|
AND FIND_IN_SET(m.system_id ,#{req.systemId}) |
|
|
|
|
</if> |
|
|
|
|
|
|
|
|
|
<if test="req.permissions !=null"> |
|
|
|
|
and m.permissions = #{req.permissions} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.state !=null"> |
|
|
|
|
and m.state = #{req.state} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.projectName !=null and req.projectName != ''"> |
|
|
|
|
and m.project_name LIKE CONCAT('%',#{req.projectName},'%') |
|
|
|
|
</if> |
|
|
|
|
|
|
|
|
|
UNION ALL |
|
|
|
|
|
|
|
|
|
SELECT |
|
|
|
|
sort, |
|
|
|
|
m.project_id, |
|
|
|
|
m.project_name, |
|
|
|
|
m.permissions, |
|
|
|
|
m.system_id, |
|
|
|
|
m.account_id, |
|
|
|
|
m.school_id, |
|
|
|
|
m.founder, |
|
|
|
|
m.state, |
|
|
|
|
m.remark, |
|
|
|
|
m.mall_id, |
|
|
|
|
'系统' AS userName, |
|
|
|
|
'系统内置' AS schoolName, |
|
|
|
|
IFNULL( |
|
|
|
|
( |
|
|
|
|
SELECT |
|
|
|
|
GROUP_CONCAT(role_name) AS roleName |
|
|
|
|
FROM |
|
|
|
|
nakadai.acl_user_role ur |
|
|
|
|
INNER JOIN nakadai.acl_role r ON r.id = ur.role_id |
|
|
|
|
WHERE |
|
|
|
|
account_id = m.account_id |
|
|
|
|
AND r.platform_id = 1 |
|
|
|
|
AND is_del = 0 |
|
|
|
|
), |
|
|
|
|
'中台超管' |
|
|
|
|
) AS roleName, |
|
|
|
|
sc.system_name,m.create_time |
|
|
|
|
FROM |
|
|
|
|
nakadai.curriculum_configure cc |
|
|
|
|
INNER JOIN nakadai.curriculum c ON c.cid = cc.cid |
|
|
|
|
INNER JOIN ol_project_manage m ON m.project_id = cc.project_id |
|
|
|
|
LEFT JOIN nakadai.hr_user_account ua ON ua.id = m.account_id |
|
|
|
|
LEFT JOIN nakadai.hr_user_info u ON u.user_id = ua.user_id |
|
|
|
|
LEFT JOIN nakadai.service_configuration sc ON sc.system_id = m.system_id |
|
|
|
|
WHERE |
|
|
|
|
cc.is_show = 0 |
|
|
|
|
AND cc.is_del = 0 |
|
|
|
|
AND m.is_del = 0 |
|
|
|
|
AND m.zt_del = 0 |
|
|
|
|
AND zt_open = 0 |
|
|
|
|
AND FIND_IN_SET( c.cid, #{req.cid} ) |
|
|
|
|
<if test="req.systemId !=null"> |
|
|
|
|
AND FIND_IN_SET(m.system_id ,#{req.systemId}) |
|
|
|
|
</if> |
|
|
|
|
|
|
|
|
|
<if test="req.permissions !=null"> |
|
|
|
|
and m.permissions = #{req.permissions} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.state !=null"> |
|
|
|
|
and m.state = #{req.state} |
|
|
|
|
</if> |
|
|
|
|
<if test="req.projectName !=null and req.projectName != ''"> |
|
|
|
|
and m.project_name LIKE CONCAT('%',#{req.projectName},'%') |
|
|
|
|
</if> |
|
|
|
|
AND m.founder = 0 |
|
|
|
|
ORDER BY |
|
|
|
|
sort ASC |
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
</mapper> |
|
|
|
|