|
|
|
@ -523,15 +523,16 @@ public class ChartServiceImpl extends Service implements ChartService {
|
|
|
|
|
* @param expandedKeys 完整的上级ID集合
|
|
|
|
|
* @param expandedKeyStr 需要展开的树ID
|
|
|
|
|
*/
|
|
|
|
|
private void addParentTreeId(List<String> expandedKeys,String expandedKeyStr){
|
|
|
|
|
if(StringUtils.isNotBlank(expandedKeyStr)) {
|
|
|
|
|
String[] split = expandedKeyStr.split(",");
|
|
|
|
|
for (String s : split) {
|
|
|
|
|
try {
|
|
|
|
|
// 上级分部ID
|
|
|
|
|
String subcompanyid1 = new DepartmentComInfo().getSubcompanyid1(s);
|
|
|
|
|
private void addParentTreeId(List<String> expandedKeys,String expandedKeyStr) {
|
|
|
|
|
if (StringUtils.isNotBlank(expandedKeyStr)) {
|
|
|
|
|
expandedKeyStr = expandedKeyStr.replace("d", "");
|
|
|
|
|
try {
|
|
|
|
|
String[] array;
|
|
|
|
|
// 上级分部ID
|
|
|
|
|
String subcompanyid1 = new DepartmentComInfo().getSubcompanyid1(expandedKeyStr);
|
|
|
|
|
if (StringUtils.isNotBlank(subcompanyid1)) {
|
|
|
|
|
String allSupCompany = new SubCompanyComInfo().getAllSupCompany(subcompanyid1);
|
|
|
|
|
String[] array = allSupCompany.split(",");
|
|
|
|
|
array = allSupCompany.split(",");
|
|
|
|
|
for (String supCompany : array) {
|
|
|
|
|
if (StringUtils.isBlank(supCompany)) {
|
|
|
|
|
continue;
|
|
|
|
@ -539,22 +540,23 @@ public class ChartServiceImpl extends Service implements ChartService {
|
|
|
|
|
expandedKeys.add("s" + supCompany);
|
|
|
|
|
}
|
|
|
|
|
expandedKeys.add("s" + subcompanyid1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 上级部门ID
|
|
|
|
|
String allSupDepartment = new DepartmentComInfo().getAllSupDepartment(s);
|
|
|
|
|
array = allSupDepartment.split(",");
|
|
|
|
|
for (String supDepartment : array) {
|
|
|
|
|
if (StringUtils.isBlank(supDepartment)) {
|
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
expandedKeys.add("d" + supDepartment);
|
|
|
|
|
// 上级部门ID
|
|
|
|
|
String allSupDepartment = new DepartmentComInfo().getAllSupDepartment(expandedKeyStr);
|
|
|
|
|
array = allSupDepartment.split(",");
|
|
|
|
|
for (String supDepartment : array) {
|
|
|
|
|
if (StringUtils.isBlank(supDepartment)) {
|
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
expandedKeys.add("d" + s);
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
throw new RuntimeException(e);
|
|
|
|
|
expandedKeys.add("d" + supDepartment);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
expandedKeys.add("d" + expandedKeyStr);
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
throw new RuntimeException(e);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|