DepartmentService介面中queryIndexPatternByDepartmentId的原始碼

一曲微茫發表於2024-11-15

@Override
public QueryIndexPatternResponse queryIndexPatternByDepartmentId(QueryIndexPatternRequest request) {
QueryDepartmentIndexPatternResponse response = new QueryDepartmentIndexPatternResponse();

if (StringUtils.isEmpty(departmentId)) {
    throw new TitanException("所傳引數為空");
}

Department department = getDepartmentById(request.getdepartmentId());
if (department == null) {
    RespUtils.setError(ErrCodeEnum.DEPARTMENT_NOT_EXIST, response);
    return response;
}

List<UserDepartmentIndexPatternItem> list=indexPatternServive.getDepartmentIndexPatternByDepartmrntId(request.getDepartmentId());
response.setIndexPatternitemList(list);
RespUtils.setSuccess(response);
return response;

}

相關文章