Commit 61118d89 by qwmqiuwenmin

fix

parent 34b01847
......@@ -408,23 +408,14 @@ public class DepartmentContoller extends WebBaseController{
String chainId = department.getChainId() + Constant.ID_SEPARATOR + departmentId;
String[] chainIdArr = chainId.split(Constant.ID_SEPARATOR);
DepartmentChainVO chainVO = null;
List<DepartmentChainVO> list = new ArrayList<>();
for (String string : chainIdArr) {
if("0".equals(string)){
continue;
}
DepartmentDTO son = departmentApiService.selectById(string);
DepartmentChainVO chain = EntityUtil.changeEntityByJSON(DepartmentChainVO.class, son);
if(chainVO != null){
DepartmentChainVO diguiChian = chainVO;
while(diguiChian.getSonDepartment() != null){
diguiChian = diguiChian.getSonDepartment();
}
diguiChian.setSonDepartment(chain);
}else{
chainVO = new DepartmentChainVO();
chainVO = chain;
}
list.add(chain);
}
return resultResponse(HaoBanErrCode.ERR_1,chainVO);
}
......
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