Commit ddb4108b authored by ZWT's avatar ZWT

feat(零碳): 长庆

1.邮件发送服务代码修改,修改配置文件及发送逻辑,解决邮件名称唯一性;
2.邮件接收功能修改,解决邮件接收协议修改后导致的一系列问题;
3.长期间开优化功能修改,修改定时任务处理逻辑及执行周期;
4.中期间开优化功能修改,修改定时任务处理逻辑及执行周期;
5.超长期间开优化功能开发,开发相关接口及定时任务,创建对应数据表,生成对应接口文档并完成接口冒烟测试;
6.超短期间开优化功能开发,开发相关接口及定时任务,创建对应数据表,生成对应接口文档并完成接口冒烟测试;
7.组织线路树功能修改,重构查询逻辑;

BREAKING CHANGE: 无

Closes 无

[skip ci]
parent eca198b4
...@@ -77,5 +77,13 @@ public interface SysOrganizationViewMapper { ...@@ -77,5 +77,13 @@ public interface SysOrganizationViewMapper {
*/ */
List<SysOrganizationView> selectOrgAndLineList(SysOrganizationView record); List<SysOrganizationView> selectOrgAndLineList(SysOrganizationView record);
/**
* 查询子线路列表
*
* @param record 记录
* @return {@link List}<{@link SysOrganizationView}>
*/
List<SysOrganizationView> selectChildLineList(SysOrganizationView record);
SysOrganizationView selectOrgProvince(SysOrganizationView record); SysOrganizationView selectOrgProvince(SysOrganizationView record);
} }
package pps.core.system.service; package pps.core.system.service;
import cn.hutool.core.collection.CollUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo; import com.github.pagehelper.PageInfo;
...@@ -486,6 +487,10 @@ public class SysOrganizationService { ...@@ -486,6 +487,10 @@ public class SysOrganizationService {
viewList = mapper.selectLineList(view); viewList = mapper.selectLineList(view);
} else { } else {
viewList = mapper.selectOrgAndLineList(view); viewList = mapper.selectOrgAndLineList(view);
if (CollUtil.isEmpty(viewList)) {
//查子线路
viewList = mapper.selectChildLineList(view);
}
} }
List<DynamicQuerySysOrganizationOutput> outputs = XCopyUtils.copyNewList(viewList, DynamicQuerySysOrganizationOutput.class); List<DynamicQuerySysOrganizationOutput> outputs = XCopyUtils.copyNewList(viewList, DynamicQuerySysOrganizationOutput.class);
return XListResult.success(outputs); return XListResult.success(outputs);
......
...@@ -589,7 +589,7 @@ ...@@ -589,7 +589,7 @@
AND o.is_deleted = 1 AND o.is_deleted = 1
ORDER BY r.sort) ORDER BY r.sort)
UNION ALL UNION ALL
(SELECT ou_id AS id, (SELECT id AS id,
line_name AS ou_name, line_name AS ou_name,
id AS line_id, id AS line_id,
'LINE' AS ou_level, 'LINE' AS ou_level,
...@@ -597,8 +597,33 @@ ...@@ -597,8 +597,33 @@
FROM base_power_line FROM base_power_line
WHERE ou_id = #{id} WHERE ou_id = #{id}
AND is_deleted = 1 AND is_deleted = 1
AND grid_type_key = '1'
AND line_type_key = '10' AND line_type_key = '10'
ORDER BY modify_time DESC) ORDER BY modify_time DESC)
UNION ALL
(SELECT ou_id AS id,
line_name AS ou_name,
id AS line_id,
'LINE' AS ou_level,
grid_type_key
FROM base_power_line
WHERE ou_id = #{id}
AND is_deleted = 1
AND grid_type_key = '0'
ORDER BY modify_time DESC)
</select>
<select id="selectChildLineList" parameterType="pps.core.system.entity.SysOrganizationView"
resultMap="ExtendResultMap">
SELECT id AS id,
line_name AS ou_name,
id AS line_id,
'LINE' AS ou_level,
grid_type_key
FROM base_power_line
WHERE upper_line_id = #{id}
AND is_deleted = 1
ORDER BY modify_time DESC
</select> </select>
<select id="selectOrgProvince" parameterType="pps.core.system.entity.SysOrganizationView" resultMap="BaseResultMap"> <select id="selectOrgProvince" parameterType="pps.core.system.entity.SysOrganizationView" resultMap="BaseResultMap">
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment