Merge branch 'dev'
This commit is contained in:
commit
cb9c3a598f
|
@ -23,4 +23,9 @@ public interface SysNoticeDao extends BaseDao<SysNoticeEntity> {
|
|||
* 获取我的通知列表
|
||||
*/
|
||||
List<SysNoticeEntity> getMyNoticeList(Map<String, Object> params);
|
||||
|
||||
/**
|
||||
* 更新 apply state
|
||||
*/
|
||||
int updateApplyState(Long userId, Integer applyState, String applyId);
|
||||
}
|
|
@ -110,13 +110,7 @@ public class SysNoticeServiceImpl extends CrudServiceImpl<SysNoticeDao, SysNotic
|
|||
|
||||
@Override
|
||||
public void updateApplyStateById(String id, Integer state) {
|
||||
Map params = new HashMap();
|
||||
params.put("apply_id", id);
|
||||
List<SysNoticeDTO> list = this.list(params);
|
||||
list.stream().filter(it -> it.getReceiverTypeIds().contains(SecurityUser.getUserId().toString())).forEach(it -> {
|
||||
it.setApplyState(state);
|
||||
this.update(it);
|
||||
});
|
||||
baseDao.updateApplyState(SecurityUser.getUserId(), state, id);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -23,4 +23,8 @@
|
|||
</if>
|
||||
order by t2.create_date desc
|
||||
</select>
|
||||
|
||||
<update id="updateApplyState">
|
||||
update sys_notice set apply_state = #{applyState} where receiver_type_ids like concat('%', #{userId}, '%') and apply_id=#{applyId}
|
||||
</update>
|
||||
</mapper>
|
|
@ -1763,17 +1763,19 @@
|
|||
END
|
||||
) AS "type"
|
||||
FROM
|
||||
(SELECT IF(d.type='组件服务', A.attr_value, d.type) AS type, d.id, d.del_flag FROM tb_data_resource d LEFT JOIN
|
||||
(SELECT IF(d.type='组件服务', A.attr_value, d.type) AS type, d.id, d.dept_id, d.del_flag 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) tdr,
|
||||
sys_dept sd,
|
||||
sys_user su,
|
||||
t_ability_application taa
|
||||
t_ability_application taa,
|
||||
sys_dept dept
|
||||
WHERE
|
||||
1 = 1
|
||||
AND tdr.del_flag = 0
|
||||
AND taa.user_id = su.id
|
||||
AND su.dept_id = sd.id
|
||||
AND taa.resource_id = tdr.id
|
||||
AND dept.id = tdr.dept_id
|
||||
AND (tdr.type = '应用资源' OR tdr.type = '智能算法' OR tdr.type = '图层服务' OR tdr.type = '开发组件' OR
|
||||
tdr.type = '业务组件')
|
||||
<if test="approveStatus != null and approveStatus != ''">
|
||||
|
|
Loading…
Reference in New Issue