|
|
@ -898,7 +898,7 @@ public class AftersalesWorkOrderServiceImpl extends BaseServiceImpl<AftersalesWo |
|
|
|
if (user == null) { |
|
|
|
if (user == null) { |
|
|
|
throw new ServiceException("用户信息获取失败"); |
|
|
|
throw new ServiceException("用户信息获取失败"); |
|
|
|
} |
|
|
|
} |
|
|
|
String roleName = user.getRoleName(); |
|
|
|
List<String> roleList = Arrays.asList(user.getRoleName().split(",")); |
|
|
|
String tenantId = user.getTenantId(); |
|
|
|
String tenantId = user.getTenantId(); |
|
|
|
|
|
|
|
|
|
|
|
// 查询 状态条件
|
|
|
|
// 查询 状态条件
|
|
|
@ -911,11 +911,10 @@ public class AftersalesWorkOrderServiceImpl extends BaseServiceImpl<AftersalesWo |
|
|
|
if (Func.isEmpty(myCurrentWarehouse)) { |
|
|
|
if (Func.isEmpty(myCurrentWarehouse)) { |
|
|
|
log.warn(">>>>myCurrentWarehouse {}", myCurrentWarehouse); |
|
|
|
log.warn(">>>>myCurrentWarehouse {}", myCurrentWarehouse); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (!roleList.isEmpty()) { |
|
|
|
Optional<DictBiz> matchingDictBiz = warehouseType.stream() |
|
|
|
Optional<DictBiz> matchingDictBiz = warehouseType.stream() |
|
|
|
.filter(i -> i.getDictValue().equals(roleName)) |
|
|
|
.filter(i -> roleList.contains(i.getDictValue())) |
|
|
|
.findFirst(); |
|
|
|
.findFirst(); |
|
|
|
|
|
|
|
|
|
|
|
Object workOrderStatus = aftersalesWorkOrder.get("workOrderStatus"); |
|
|
|
Object workOrderStatus = aftersalesWorkOrder.get("workOrderStatus"); |
|
|
|
if (matchingDictBiz.isPresent()) { |
|
|
|
if (matchingDictBiz.isPresent()) { |
|
|
|
String dictValue = matchingDictBiz.get().getDictKey(); |
|
|
|
String dictValue = matchingDictBiz.get().getDictKey(); |
|
|
@ -933,7 +932,9 @@ public class AftersalesWorkOrderServiceImpl extends BaseServiceImpl<AftersalesWo |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
updateWorkOrderForOthers(aftersalesWorkOrder, workOrderStatus); |
|
|
|
updateWorkOrderForOthers(aftersalesWorkOrder, workOrderStatus); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
}else { |
|
|
|
|
|
|
|
throw new CustomerException("当前登录人无工单操作权限!!!"); |
|
|
|
|
|
|
|
} |
|
|
|
AftersalesWorkOrderEntity workOrderEntity = JSONObject.parseObject(JSONObject.toJSONString(aftersalesWorkOrder), AftersalesWorkOrderEntity.class); |
|
|
|
AftersalesWorkOrderEntity workOrderEntity = JSONObject.parseObject(JSONObject.toJSONString(aftersalesWorkOrder), AftersalesWorkOrderEntity.class); |
|
|
|
IPage<AftersalesWorkOrderEntity> iPage = baseMapper.pageListOwn(page, workOrderEntity); |
|
|
|
IPage<AftersalesWorkOrderEntity> iPage = baseMapper.pageListOwn(page, workOrderEntity); |
|
|
|
if (iPage.getRecords().isEmpty()) { |
|
|
|
if (iPage.getRecords().isEmpty()) { |
|
|
|