Compare commits

..

5 Commits

Author SHA1 Message Date
wangliwen 07b5892265 Merge branch 'master' into docker_package 2023-01-10 18:19:35 +08:00
wangliwen ef790fd82c Merge branch 'dev'
# Conflicts:
#	renren-admin/src/main/java/io/renren/modules/processForm/controller/TAbilityApplicationController.java
2023-01-10 18:19:28 +08:00
wangliwen 9503da7c52 ... 2023-01-10 18:18:57 +08:00
wangliwen 451a5629de ... 2023-01-10 18:17:56 +08:00
wangliwen bb44d49adb 格式化代码 2023-01-10 17:10:51 +08:00
10 changed files with 531 additions and 508 deletions

View File

@ -805,6 +805,12 @@ public class TAbilityApplicationController {
temp.put("system", index.getSystem());
temp.put("resourceId", index.getResourceId());
ResourceDTO resourceDTO = resourceService.get(Long.parseLong(index.getResourceId()));
try {
temp.put("resourceDept", sysDeptService.get(resourceDTO.getDeptId()).getName());
} catch (Exception exception) {
temp.put("resourceDept", "-");
}
temp.put("description", resourceDTO.getDescription());
if ("应用资源".equals(resourceDTO.getType())) {
temp.put("resourceTYpe", "应用资源");
} else if ("组件服务".equals(resourceDTO.getType())) {

View File

@ -85,9 +85,9 @@ public class TAbilityApplicationServiceImpl extends CrudServiceImpl<TAbilityAppl
String sql = "SELECT 1 FROM tb_resource_score t1 WHERE t1.user_id = t_ability_application.user_id AND t1.resource_id = t_ability_application.resource_id";
String resource_sql = "SELECT 1 FROM tb_data_resource WHERE tb_data_resource.del_flag = 0 AND t_ability_application.resource_id = tb_data_resource.id";
if (score) {
wrapper.exists(sql).exists(resource_sql).ne("approve_status", "通过");
wrapper.exists(sql).exists(resource_sql).eq("approve_status", "通过");
} else {
wrapper.notExists(sql).exists(resource_sql).ne("approve_status", "通过");
wrapper.notExists(sql).exists(resource_sql).eq("approve_status", "通过");
}
break;
}

View File

@ -38,13 +38,13 @@
ahp.START_USER_ID_,
arp.VERSION_ AS DEF_VERSION_
FROM
( SELECT DISTINCT PROC_DEF_ID_, PROC_INST_ID_, ASSIGNEE_ FROM ACT_HI_TASKINST ) aht
LEFT JOIN ACT_HI_PROCINST ahp ON aht.PROC_INST_ID_ = ahp.PROC_INST_ID_
LEFT JOIN ACT_RE_PROCDEF arp ON aht.PROC_DEF_ID_ = arp.ID_
( SELECT DISTINCT PROC_DEF_ID_, PROC_INST_ID_, ASSIGNEE_ FROM ACT_HI_TASKINST ) aht
LEFT JOIN ACT_HI_PROCINST ahp ON aht.PROC_INST_ID_ = ahp.PROC_INST_ID_
LEFT JOIN ACT_RE_PROCDEF arp ON aht.PROC_DEF_ID_ = arp.ID_
LEFT JOIN sys_user su ON ahp.START_USER_ID_ = su.id
WHERE
aht.ASSIGNEE_ = #{userId}
<if test="userName != null and userName != ''" >
aht.ASSIGNEE_ = #{userId}
<if test="userName != null and userName != ''">
and su.real_name like CONCAT('%', #{userName} ,'%')
</if>
<if test="processInstanceId != null">
@ -71,7 +71,7 @@
<if test="ended != null">
and ahp.END_TIME_ IS NOT NULL
</if>
ORDER BY
ORDER BY
ahp.START_TIME_ DESC
</select>

View File

@ -23,7 +23,7 @@
<result property="approvalUserDeptName" column="approval_user_dept_name"/>
<result property="visits" column="visits"/>
<result property="applyNumber" column="apply_number"/>
<result property="enclosureName" column="enclosure_name" />
<result property="enclosureName" column="enclosure_name"/>
</resultMap>
<update id="updateInstanceId">

View File

@ -33,7 +33,8 @@
trc.user_id = #{userId})>0 , 'true', 'false') as isCollect
FROM
tb_fuse tf
LEFT JOIN ( SELECT id, resource_Id, user_id FROM tb_resource_collection WHERE 1 = 1 AND del_flag = 0 ) trc ON tf.id = trc.resource_id
LEFT JOIN ( SELECT id, resource_Id, user_id FROM tb_resource_collection WHERE 1 = 1 AND del_flag = 0 ) trc ON
tf.id = trc.resource_id
WHERE
1 =1
<if test="name != null and name != ''">

View File

@ -109,13 +109,13 @@
<update id="updateByDelProcinst">
UPDATE tb_data_resource
SET del_flag = 0,
undercarriage_reason = NULL,
undercarriage_user_name = NULL,
apply_number = NULL,
undercarriage_enclosure = NULL,
undercarriage_title = NULL,
undercarriage_phone = NULL,
undercarriage_enclosure_name = NULL
undercarriage_reason = NULL,
undercarriage_user_name = NULL,
apply_number = NULL,
undercarriage_enclosure = NULL,
undercarriage_title = NULL,
undercarriage_phone = NULL,
undercarriage_enclosure_name = NULL
WHERE id = #{resourceId}
</update>
@ -1517,8 +1517,8 @@
<select id="selectUsersApplyAndCount" resultMap="resourceDTO">
SELECT tdr.*, sd.name AS "deptName", count(taa.id) as applyCount
FROM tb_data_resource tdr
LEFT JOIN sys_dept sd ON tdr.dept_id = sd.id
LEFT JOIN t_ability_application taa on tdr.id=taa.resource_id
LEFT JOIN sys_dept sd ON tdr.dept_id = sd.id
LEFT JOIN t_ability_application taa on tdr.id=taa.resource_id
WHERE
1 = 1
AND tdr.del_flag = 0
@ -1922,31 +1922,31 @@
<select id="selectCensusResourceTable" resultType="java.util.Map">
SELECT
sd.name AS deptName,
tdr.name AS resourceName,
tdr.type,
DATE_FORMAT(tdr.create_date,'%Y-%m-%d %T') AS createDate,
CASE WHEN tdr.del_flag = 0 THEN '通过' WHEN tdr.del_flag = 6 THEN '不通过' ELSE '审核中' END AS approveStatus,
trma.instance_id AS applyNumber
sd.name AS deptName,
tdr.name AS resourceName,
tdr.type,
DATE_FORMAT(tdr.create_date,'%Y-%m-%d %T') AS createDate,
CASE WHEN tdr.del_flag = 0 THEN '通过' WHEN tdr.del_flag = 6 THEN '不通过' ELSE '审核中' END AS approveStatus,
trma.instance_id AS applyNumber
FROM
(SELECT
IF(d.type = '组件服务', a.attr_value, d.type) AS type,
d.id,
d.del_flag,
d.dept_id,
d.create_date,
d.name
FROM tb_data_resource d
LEFT JOIN tb_data_attr a ON d.id = a.data_resource_id AND a.attr_type = '组件类型' AND a.del_flag = 0
WHERE
1 = 1
AND d.del_flag NOT IN (1, 5)
AND d.type IN ('应用资源','组件服务')
IF(d.type = '组件服务', a.attr_value, d.type) AS type,
d.id,
d.del_flag,
d.dept_id,
d.create_date,
d.name
FROM tb_data_resource d
LEFT JOIN tb_data_attr a ON d.id = a.data_resource_id AND a.attr_type = '组件类型' AND a.del_flag = 0
WHERE
1 = 1
AND d.del_flag NOT IN (1, 5)
AND d.type IN ('应用资源','组件服务')
) tdr
LEFT JOIN t_resource_mount_apply trma on tdr.id = trma.resource_id,
sys_dept sd
WHERE 1 = 1
AND tdr.dept_id = sd.id
AND tdr.dept_id = sd.id
<choose>
<when test="approveStatus != null and approveStatus == '通过'">
AND tdr.del_flag = 0
@ -2042,7 +2042,7 @@
<if test="type == null or type == '' or type == '会客厅'">
UNION ALL
UNION ALL
SELECT
tmb.dept AS 'deptName',
tm.`name` AS 'resourceName',
@ -2058,9 +2058,9 @@
sys_dept sd,
sys_region sr
WHERE
tmb.room_id = tm.id
AND tmb.dept = sd.name
AND sd.district = sr.id
tmb.room_id = tm.id
AND tmb.dept = sd.name
AND sd.district = sr.id
<choose>
<when test="approveStatus != null and approveStatus == '通过'">
AND tmb.state=2
@ -2116,7 +2116,8 @@
tb_data_attr a
INNER JOIN mysql.help_topic b ON a.attr_type = '应用领域'
AND a.del_flag = 0
AND b.help_topic_id &lt; ( length( a.attr_value ) - length( REPLACE ( a.attr_value, ';', '' )) + 1 )) tda ON tdr.id = tda.data_resource_id
AND b.help_topic_id &lt; ( length( a.attr_value ) - length( REPLACE ( a.attr_value, ';', '' )) + 1 )) tda ON
tdr.id = tda.data_resource_id
LEFT JOIN (
SELECT
sdd.sort,
@ -2394,40 +2395,41 @@
SELECT
DISTINCT '应用资源' AS "resourceType"
FROM
tb_data_resource tdr
tb_data_resource tdr
WHERE
tdr.del_flag = 0
AND tdr.id IN
<foreach collection="resourceIds" item="id" open="(" separator="," close=")">
#{id}
</foreach> UNION ALL
tdr.del_flag = 0
AND tdr.id IN
<foreach collection="resourceIds" item="id" open="(" separator="," close=")">
#{id}
</foreach>
UNION ALL
SELECT DISTINCT
tda.attr_value
tda.attr_value
FROM
tb_data_resource tdr,
tb_data_attr tda
tb_data_resource tdr,
tb_data_attr tda
WHERE
tdr.id = tda.data_resource_id
AND tdr.del_flag = 0
AND tda.del_flag = 0
AND tda.attr_type = '组件类型'
AND tdr.id IN
<foreach collection="resourceIds" item="id" open="(" separator="," close=")">
#{id}
</foreach>
tdr.id = tda.data_resource_id
AND tdr.del_flag = 0
AND tda.del_flag = 0
AND tda.attr_type = '组件类型'
AND tdr.id IN
<foreach collection="resourceIds" item="id" open="(" separator="," close=")">
#{id}
</foreach>
</select>
<select id="selectProvideDeptNameByIds" resultType="java.lang.String">
SELECT
DISTINCT sd.name AS "provideDept"
DISTINCT sd.name AS "provideDept"
FROM
tb_data_resource tdr, sys_dept sd
tb_data_resource tdr, sys_dept sd
WHERE
tdr.del_flag = 0
AND tdr.dept_id = sd.id
AND tdr.id IN
<foreach collection="resourceIds" item="id" open="(" separator="," close=")">
#{id}
</foreach>
tdr.del_flag = 0
AND tdr.dept_id = sd.id
AND tdr.id IN
<foreach collection="resourceIds" item="id" open="(" separator="," close=")">
#{id}
</foreach>
</select>
<select id="selectPolicyCloudServiceCountByName" resultType="java.lang.Integer">
@ -2435,7 +2437,7 @@
FROM policy_cloud_service
WHERE 1 = 1
<if test="keyWorld != null and keyWorld != ''">
and service_item_tier1 LIKE concat('%', #{keyWorld}, '%')
and service_item_tier1 LIKE concat('%', #{keyWorld}, '%')
</if>
</select>

View File

@ -19,10 +19,10 @@
<where>
1 = 1
<if test="type != null">
and t1.type = #{type}
and t1.type = #{type}
</if>
<if test="name != null and name != ''">
and lang.field_value like CONCAT('%', #{name}, '%')
and lang.field_value like CONCAT('%', #{name}, '%')
</if>
and lang.table_name = 'sys_menu'
and lang.field_name = 'name'

View File

@ -261,22 +261,22 @@
LIMIT ${pageNum}, ${pageSize}
</select>
<select id="getUserByRoleListCount" resultType="java.lang.Long">
<!-- SELECT-->
<!-- COUNT(DISTINCT sys_user.id )-->
<!-- FROM-->
<!-- sys_role_user-->
<!-- LEFT JOIN sys_user ON sys_user.id = sys_role_user.user_id-->
<!-- LEFT JOIN sys_dept ON sys_dept.id = sys_user.dept_id-->
<!-- WHERE-->
<!-- 1 = 1-->
<!-- AND sys_role_user.del_flag = 0-->
<!-- AND sys_user.id IS NOT NULL-->
<!-- <if test="null != roleIds">-->
<!-- AND sys_role_user.role_id IN-->
<!-- <foreach item="roleId" collection="roleIds" open="(" separator="," close=")">-->
<!-- #{roleId}-->
<!-- </foreach>-->
<!-- </if>-->
<!-- SELECT-->
<!-- COUNT(DISTINCT sys_user.id )-->
<!-- FROM-->
<!-- sys_role_user-->
<!-- LEFT JOIN sys_user ON sys_user.id = sys_role_user.user_id-->
<!-- LEFT JOIN sys_dept ON sys_dept.id = sys_user.dept_id-->
<!-- WHERE-->
<!-- 1 = 1-->
<!-- AND sys_role_user.del_flag = 0-->
<!-- AND sys_user.id IS NOT NULL-->
<!-- <if test="null != roleIds">-->
<!-- AND sys_role_user.role_id IN-->
<!-- <foreach item="roleId" collection="roleIds" open="(" separator="," close=")">-->
<!-- #{roleId}-->
<!-- </foreach>-->
<!-- </if>-->
SELECT
COUNT(temp.id)

View File

@ -3,7 +3,8 @@
<mapper namespace="io.renren.modules.sysnoticemanagement.dao.SysNoticeManagementDao">
<resultMap type="io.renren.modules.sysnoticemanagement.entity.SysNoticeManagementEntity" id="sysNoticeManagementMap">
<resultMap type="io.renren.modules.sysnoticemanagement.entity.SysNoticeManagementEntity"
id="sysNoticeManagementMap">
<result property="id" column="id"/>
<result property="content" column="content"/>
<result property="publishTime" column="publish_time"/>