1.修改查询无人机盒子列表权限bug。
2.修改查询服务器管理列表权限bug。
| | |
| | | package com.ard.work.service.impl; |
| | | |
| | | import com.alibaba.fastjson2.JSONObject; |
| | | import com.ard.common.annotation.DataScope; |
| | | import com.ard.common.constant.CacheConstants; |
| | | import com.ard.common.core.redis.RedisCache; |
| | | import com.ard.common.exception.ServiceException; |
| | |
| | | /** |
| | | * 查询无人机盒子列表 |
| | | * |
| | | * @param ArdDroneInfo 无人机盒子 |
| | | * @param ardDroneInfo 无人机盒子 |
| | | * @return 无人机盒子 |
| | | */ |
| | | @Override |
| | | public List<ArdDroneInfo> selectArdDroneList(ArdDroneInfo ArdDroneInfo) { |
| | | return ArdDroneInfoMapper.selectArdDroneList(ArdDroneInfo); |
| | | @DataScope(deptAlias = "d", userAlias = "u") |
| | | public List<ArdDroneInfo> selectArdDroneList(ArdDroneInfo ardDroneInfo) { |
| | | return ArdDroneInfoMapper.selectArdDroneList(ardDroneInfo); |
| | | } |
| | | |
| | | /** |
| | |
| | | package com.ard.work.service.impl; |
| | | |
| | | import com.ard.common.annotation.DataScope; |
| | | import com.ard.common.utils.uuid.IdUtils; |
| | | import com.ard.work.component.forest.TyClient; |
| | | import com.ard.work.component.netty.TyTcpClientManager; |
| | |
| | | * @return 服务器管理 |
| | | */ |
| | | @Override |
| | | @DataScope(deptAlias = "d", userAlias = "u") |
| | | public List<ArdServerInfo> selectArdServerInfoList(ArdServerInfo ardServerInfo) { |
| | | return ardServerInfoMapper.selectArdServerInfoList(ardServerInfo); |
| | | } |
| | |
| | | </select> |
| | | |
| | | <sql id="selectArdDroneVo"> |
| | | select id, |
| | | box_sn, |
| | | box_name, |
| | | box_version, |
| | | start_time, |
| | | on_line, |
| | | video_server, |
| | | video_port, |
| | | last_task_id, |
| | | server_id, |
| | | user_id, |
| | | dept_id, |
| | | box_alias_name |
| | | from ard_drone_info |
| | | select c.id, |
| | | c.box_sn, |
| | | c.box_name, |
| | | c.box_version, |
| | | c.start_time, |
| | | c.on_line, |
| | | c.video_server, |
| | | c.video_port, |
| | | c.last_task_id, |
| | | c.server_id, |
| | | c.user_id, |
| | | c.dept_id, |
| | | c.box_alias_name |
| | | from ard_drone_info c |
| | | left join sys_dept d on d.dept_id = c.dept_id |
| | | left join sys_user u on u.user_id = c.user_id |
| | | </sql> |
| | | |
| | | <select id="selectArdDroneList" parameterType="ArdDroneInfo" resultMap="ArdDroneInfoResult"> |
| | | <include refid="selectArdDroneVo"/> |
| | | <where> |
| | | <if test="boxSn != null and boxSn != ''"> and box_sn like concat('%', #{boxSn}, '%')</if> |
| | | <if test="boxName != null and boxName != ''"> and box_name like concat('%', #{boxName}, '%')</if> |
| | | <if test="boxVersion != null and boxVersion != ''"> and box_version = #{boxVersion}</if> |
| | | <if test="onLine != null "> and onLine = #{onLine}</if> |
| | | <if test="lastTaskId != null "> and last_task_id = #{lastTaskId}</if> |
| | | <if test="userId != null "> and user_id = #{userId}</if> |
| | | <if test="deptId != null "> and dept_id = #{deptId}</if> |
| | | <if test="boxSn != null and boxSn != ''"> and c.box_sn like concat('%', #{boxSn}, '%')</if> |
| | | <if test="boxName != null and boxName != ''"> and c.box_name like concat('%', #{boxName}, '%')</if> |
| | | <if test="boxVersion != null and boxVersion != ''"> and c.box_version = #{boxVersion}</if> |
| | | <if test="onLine != null "> and c.onLine = #{onLine}</if> |
| | | <if test="lastTaskId != null "> and c.last_task_id = #{lastTaskId}</if> |
| | | <if test="userId != null "> and c.user_id = #{userId}</if> |
| | | <if test="deptId != null and deptId != 0"> |
| | | and (d.dept_id = #{deptId} OR d.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE |
| | | find_in_set(#{deptId}, ancestors) )) |
| | | </if> |
| | | <!-- 数据范围过滤 --> |
| | | ${params.dataScope} |
| | | </where> |
| | | </select> |
| | | |