Commit b7270b0c authored by cq990612's avatar cq990612

优化代码结构

parent e04b6a84
...@@ -106,7 +106,7 @@ select d.id 'dept_id',d.dept_name,p.id 'project_id',p.project_name ...@@ -106,7 +106,7 @@ select d.id 'dept_id',d.dept_name,p.id 'project_id',p.project_name
from work_dept d LEFT JOIN work_project p on d.id = p.dept_id from work_dept d LEFT JOIN work_project p on d.id = p.dept_id
<where> <where>
<if test="userId !=null"> <if test="userId !=null">
p.manager_id = #{userId} AND p.manager_id = #{userId}
</if> </if>
<if test="deptId !=null"> <if test="deptId !=null">
OR p.dept_id = #{deptId} OR p.dept_id = #{deptId}
......
...@@ -298,6 +298,7 @@ ...@@ -298,6 +298,7 @@
LEFT JOIN work_dept d ON d.id = u.dept_id LEFT JOIN work_dept d ON d.id = u.dept_id
LEFT JOIN work_type t ON p.type = t.id LEFT JOIN work_type t ON p.type = t.id
<where> <where>
p.is_conclusion = 1
<if test="userId !=null"> <if test="userId !=null">
AND p.manager_id = #{userId} AND p.manager_id = #{userId}
</if> </if>
......
...@@ -1337,7 +1337,7 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService { ...@@ -1337,7 +1337,7 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
// 判断新增的工单变更是否为空 // 判断新增的工单变更是否为空
private void OrderChangeVoIsNull(OrderChangeVo vo, Boolean workIdIsNeed) { private void OrderChangeVoIsNull(OrderChangeVo vo, Boolean workIdIsNeed) {
System.out.println(vo); System.out.println(vo);
if (null == vo || null ==vo.getOperatorId() || null == vo.getWorkDay() || null == vo.getWorkTime() || StringUtils.isBlank(vo.getDes()) || StringUtils.isBlank(vo.getChangeReason())) { if (null == vo || null ==vo.getOperatorId() || null == vo.getWorkDay() || null == vo.getWorkTime() || StringUtils.isEmpty(vo.getDes()) || StringUtils.isEmpty(vo.getChangeReason())) {
throw new BaseCustomException(BASE_RESP_CODE_ENUM.INPUT_PARAM_IS_NULL); throw new BaseCustomException(BASE_RESP_CODE_ENUM.INPUT_PARAM_IS_NULL);
} }
if (!UserRoleLevelUtils.isManagerLevel(vo.getOperatorId(), LevelEnum.WORKORDER_CHANGEMANAGEMENT.getLevelName())) { if (!UserRoleLevelUtils.isManagerLevel(vo.getOperatorId(), LevelEnum.WORKORDER_CHANGEMANAGEMENT.getLevelName())) {
......
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