Commit 8fbef379 authored by cq990612's avatar cq990612

优化代码结构

parent a9617f98
...@@ -340,6 +340,7 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService { ...@@ -340,6 +340,7 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
throw new BaseCustomException(BASE_RESP_CODE_ENUM.INPUT_PARAM_IS_NULL); throw new BaseCustomException(BASE_RESP_CODE_ENUM.INPUT_PARAM_IS_NULL);
} }
List<Integer> typeIds = workTypeService.getIdByReviewer(1); List<Integer> typeIds = workTypeService.getIdByReviewer(1);
System.out.println(typeIds);
int size = list.size(); int size = list.size();
for (int i = 0; i < size; i++) { for (int i = 0; i < size; i++) {
for (int j = i + 1; j < size; j++) { for (int j = i + 1; j < size; j++) {
...@@ -352,7 +353,7 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService { ...@@ -352,7 +353,7 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
throw new BaseCustomException(BASE_RESP_CODE_ENUM.WORK_ORDER_ALREADY_COMMIT); throw new BaseCustomException(BASE_RESP_CODE_ENUM.WORK_ORDER_ALREADY_COMMIT);
} }
} }
} else if (list.get(i).getType().equals(list.get(j).getProjectId())) { } else if (list.get(i).getType().equals(list.get(j).getType())) {
throw new BaseCustomException(BASE_RESP_CODE_ENUM.WORK_ORDER_ALREADY_COMMIT); throw new BaseCustomException(BASE_RESP_CODE_ENUM.WORK_ORDER_ALREADY_COMMIT);
} }
} }
......
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