Commit a8a82d88 by 王力

Merge branch 'dev_dispatch_filter0711' into 'develop'

修改紧急程度筛选项

See merge request !209
2 parents e60139a1 9824d2e1
...@@ -286,10 +286,20 @@ public class DispatchServiceImpl implements DispatchService { ...@@ -286,10 +286,20 @@ public class DispatchServiceImpl implements DispatchService {
lqw.in(ListUtils.isNotEmpty(reqDTO.getBranchIds()), OrderRequest::getOrgBranchId, reqDTO.getBranchIds()); lqw.in(ListUtils.isNotEmpty(reqDTO.getBranchIds()), OrderRequest::getOrgBranchId, reqDTO.getBranchIds());
lqw.in(ListUtils.isNotEmpty(reqDTO.getGroupIds()), OrderRequest::getOrgGroupId, reqDTO.getGroupIds()); lqw.in(ListUtils.isNotEmpty(reqDTO.getGroupIds()), OrderRequest::getOrgGroupId, reqDTO.getGroupIds());
lqw.in(ListUtils.isNotEmpty(reqDTO.getTeamIds()), OrderRequest::getOrgTeamId, reqDTO.getTeamIds()); lqw.in(ListUtils.isNotEmpty(reqDTO.getTeamIds()), OrderRequest::getOrgTeamId, reqDTO.getTeamIds());
lqw.in(ListUtils.isNotEmpty(reqDTO.getPriorities()), OrderRequest::getPriority, reqDTO.getPriorities());
lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentType()), OrderRequest::getAppointmentMethod, reqDTO.getAppointmentType()); lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentType()), OrderRequest::getAppointmentMethod, reqDTO.getAppointmentType());
lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentStatus()), OrderRequest::getAppointmentStatus, reqDTO.getAppointmentStatus()); lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentStatus()), OrderRequest::getAppointmentStatus, reqDTO.getAppointmentStatus());
if(ListUtils.isNotEmpty(reqDTO.getPriorities())) {
List<Integer> p = reqDTO.getPriorities();
if(p.contains(0) && p.contains(1)) {
lqw.ge(OrderRequest::getPriority, 1);
} else if (p.contains(0) && !p.contains(1)) {
lqw.le(OrderRequest::getPriority, 1);
} else if (p.contains(1) && p.contains(0)) {
lqw.ge(OrderRequest::getPriority, 5);
}
}
if (ListUtils.isNotEmpty(reqDTO.getTypeCategory())) { if (ListUtils.isNotEmpty(reqDTO.getTypeCategory())) {
String types = "'" + String.join("','", reqDTO.getTypeCategory()) + "'"; String types = "'" + String.join("','", reqDTO.getTypeCategory()) + "'";
String sql = String.format("select 1 from skill_info sk where sk.brand = order_request.brand and sk.type = order_request.type and sk.skill = order_request.skill and type_category in (%s)", types); String sql = String.format("select 1 from skill_info sk where sk.brand = order_request.brand and sk.type = order_request.type and sk.skill = order_request.skill and type_category in (%s)", types);
......
...@@ -56,10 +56,20 @@ public class OrderServiceListServiceImpl implements OrderServiceListService { ...@@ -56,10 +56,20 @@ public class OrderServiceListServiceImpl implements OrderServiceListService {
lqw.in(ListUtils.isNotEmpty(reqDTO.getBranchIds()), OrderRequest::getOrgBranchId, reqDTO.getBranchIds()); lqw.in(ListUtils.isNotEmpty(reqDTO.getBranchIds()), OrderRequest::getOrgBranchId, reqDTO.getBranchIds());
lqw.in(ListUtils.isNotEmpty(reqDTO.getGroupIds()), OrderRequest::getOrgGroupId, reqDTO.getGroupIds()); lqw.in(ListUtils.isNotEmpty(reqDTO.getGroupIds()), OrderRequest::getOrgGroupId, reqDTO.getGroupIds());
lqw.in(ListUtils.isNotEmpty(reqDTO.getTeamIds()), OrderRequest::getOrgTeamId, reqDTO.getTeamIds()); lqw.in(ListUtils.isNotEmpty(reqDTO.getTeamIds()), OrderRequest::getOrgTeamId, reqDTO.getTeamIds());
lqw.in(ListUtils.isNotEmpty(reqDTO.getPriorities()), OrderRequest::getPriority, reqDTO.getPriorities());
lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentType()), OrderRequest::getAppointmentMethod, reqDTO.getAppointmentType()); lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentType()), OrderRequest::getAppointmentMethod, reqDTO.getAppointmentType());
lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentStatus()), OrderRequest::getAppointmentStatus, reqDTO.getAppointmentStatus()); lqw.in(ListUtils.isNotEmpty(reqDTO.getAppointmentStatus()), OrderRequest::getAppointmentStatus, reqDTO.getAppointmentStatus());
if(ListUtils.isNotEmpty(reqDTO.getPriorities())) {
List<Integer> p = reqDTO.getPriorities();
if(p.contains(0) && p.contains(1)) {
lqw.ge(OrderRequest::getPriority, 1);
} else if (p.contains(0) && !p.contains(1)) {
lqw.le(OrderRequest::getPriority, 1);
} else if (p.contains(1) && p.contains(0)) {
lqw.ge(OrderRequest::getPriority, 5);
}
}
if (ListUtils.isNotEmpty(reqDTO.getTypeCategory())) { if (ListUtils.isNotEmpty(reqDTO.getTypeCategory())) {
String types = "'" + String.join("','", reqDTO.getTypeCategory()) + "'"; String types = "'" + String.join("','", reqDTO.getTypeCategory()) + "'";
String sql = String.format("select 1 from skill_info sk where sk.brand = order_request.brand and sk.type = order_request.type and sk.skill = order_request.skill and type_category in (%s)", types); String sql = String.format("select 1 from skill_info sk where sk.brand = order_request.brand and sk.type = order_request.type and sk.skill = order_request.skill and type_category in (%s)", types);
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!