Compare commits
1 Commits
master
...
成都运达科技股份有限公司
| Author | SHA1 | Date |
|---|---|---|
|
|
34447af035 |
|
|
@ -271,13 +271,13 @@ public class ChartServiceImpl extends Service implements ChartService {
|
||||||
if (isRealTime) {
|
if (isRealTime) {
|
||||||
// 查询部门本身
|
// 查询部门本身
|
||||||
if (hasVirtualFields) {
|
if (hasVirtualFields) {
|
||||||
sql = "select a.id,a.departmentname as name,b.bmfzr,b.bmlx as isvitual from " + DEPARTMENT_TABLE + " a left join hrmdepartmentdefined b on a.id = b.deptid where a.id = '" + departmentId + "'";
|
sql = "select a.id,a.departmentname as name,b.bmfzr,b.bmlx as isvitual,b.bmjl from " + DEPARTMENT_TABLE + " a left join hrmdepartmentdefined b on a.id = b.deptid where a.id = '" + departmentId + "'";
|
||||||
} else {
|
} else {
|
||||||
sql = "select a.id,a.departmentname as name,b.bmfzr from " + DEPARTMENT_TABLE + " a left join hrmdepartmentdefined b on a.id = b.deptid where a.id = '" + departmentId + "'";
|
sql = "select a.id,a.departmentname as name,b.bmfzr,b.bmjl from " + DEPARTMENT_TABLE + " a left join hrmdepartmentdefined b on a.id = b.deptid where a.id = '" + departmentId + "'";
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (hasVirtualFields) {
|
if (hasVirtualFields) {
|
||||||
sql = "select " + DEPARTMENT_ID + " as id,a.departmentname as name,fleader as bmfzr,isvirtual as isvitual from " + DEPARTMENT_TABLE + " a where a." + DEPARTMENT_ID + " = '" + departmentId + "' and versionid = " + versionId;
|
sql = "select " + DEPARTMENT_ID + " as id,a.departmentname as name,fleader as bmjl,isvirtual as isvitual from " + DEPARTMENT_TABLE + " a where a." + DEPARTMENT_ID + " = '" + departmentId + "' and versionid = " + versionId;
|
||||||
} else {
|
} else {
|
||||||
sql = "select " + DEPARTMENT_ID + " as id,a.departmentname as name from " + DEPARTMENT_TABLE + " a where a." + DEPARTMENT_ID + " = '" + departmentId + "' and versionid = " + versionId;
|
sql = "select " + DEPARTMENT_ID + " as id,a.departmentname as name from " + DEPARTMENT_TABLE + " a where a." + DEPARTMENT_ID + " = '" + departmentId + "' and versionid = " + versionId;
|
||||||
}
|
}
|
||||||
|
|
@ -285,7 +285,7 @@ public class ChartServiceImpl extends Service implements ChartService {
|
||||||
rs.executeQuery(sql);
|
rs.executeQuery(sql);
|
||||||
ChartPO departmentChartPO = new ChartPO();
|
ChartPO departmentChartPO = new ChartPO();
|
||||||
if (rs.next()) {
|
if (rs.next()) {
|
||||||
String fLeader = Util.null2String(rs.getString("bmfzr"));
|
String fLeader = Util.null2String(rs.getString("bmjl"));
|
||||||
departmentChartPO.setFtype("2");
|
departmentChartPO.setFtype("2");
|
||||||
departmentChartPO.setFobjid(departmentId);
|
departmentChartPO.setFobjid(departmentId);
|
||||||
departmentChartPO.setId(rootId);
|
departmentChartPO.setId(rootId);
|
||||||
|
|
@ -1007,7 +1007,7 @@ public class ChartServiceImpl extends Service implements ChartService {
|
||||||
" left join JCL_ORG_ONJOB d on a.id=d.data_id and d.type=1 ";
|
" left join JCL_ORG_ONJOB d on a.id=d.data_id and d.type=1 ";
|
||||||
deptQuerySql = "select a.id as departmentid, a.departmentmark, a.departmentname, a.subcompanyid1 as subcompanyid, " +
|
deptQuerySql = "select a.id as departmentid, a.departmentmark, a.departmentname, a.subcompanyid1 as subcompanyid, " +
|
||||||
"b.SUBCOMPANYNAME as subcompany,a.supdepid as supdepartmentid,c.departmentname as supdepartment," +
|
"b.SUBCOMPANYNAME as subcompany,a.supdepid as supdepartmentid,c.departmentname as supdepartment," +
|
||||||
"a.canceled,a.departmentcode,a.coadjutant,a.tlevel,d.bmlx as isvirtual,a.bmfzr as fleader,e.on_job_num,e.staff_num " +
|
"a.canceled,a.departmentcode,a.coadjutant,a.tlevel,d.bmlx as isvirtual,d.bmjl as fleader,e.on_job_num,e.staff_num " +
|
||||||
"from hrmdepartment a left join hrmsubcompany b on a.subcompanyid1 = b.id " +
|
"from hrmdepartment a left join hrmsubcompany b on a.subcompanyid1 = b.id " +
|
||||||
"left join hrmdepartment c on a.supdepid = c.id " +
|
"left join hrmdepartment c on a.supdepid = c.id " +
|
||||||
"left join hrmdepartmentdefined d on a.id=d.deptid " +
|
"left join hrmdepartmentdefined d on a.id=d.deptid " +
|
||||||
|
|
@ -1040,13 +1040,15 @@ public class ChartServiceImpl extends Service implements ChartService {
|
||||||
" a.departmentcode,\n" +
|
" a.departmentcode,\n" +
|
||||||
" a.coadjutant,\n" +
|
" a.coadjutant,\n" +
|
||||||
" a.tlevel,\n" +
|
" a.tlevel,\n" +
|
||||||
" a.bmfzr as fleader,\n" +
|
" d.bmjl as fleader,\n" +
|
||||||
" d.on_job_num,\n" +
|
" e.on_job_num,\n" +
|
||||||
" d.staff_num" +
|
" e.staff_num" +
|
||||||
" from hrmdepartment a\n" +
|
" from hrmdepartment a\n" +
|
||||||
" left join hrmsubcompany b on a.subcompanyid1 = b.id\n" +
|
" LEFT JOIN hrmsubcompany b ON a.subcompanyid1 = b.id\n" +
|
||||||
" left join hrmdepartment c on a.supdepid = c.id\n" +
|
" LEFT JOIN hrmdepartment c ON a.supdepid = c.id\n" +
|
||||||
" left join JCL_ORG_ONJOB d on a.id=d.data_id and d.type=2 ";
|
" LEFT JOIN hrmdepartmentdefined d ON a.id = d.deptid\n" +
|
||||||
|
" LEFT JOIN JCL_ORG_ONJOB e ON a.id = e.data_id \n" +
|
||||||
|
" AND e.type = 2";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -1671,9 +1673,6 @@ public class ChartServiceImpl extends Service implements ChartService {
|
||||||
* @return 人员名称
|
* @return 人员名称
|
||||||
*/
|
*/
|
||||||
private String getDepartmentLeader(String ids) {
|
private String getDepartmentLeader(String ids) {
|
||||||
if (!isRealTime) {
|
|
||||||
return ids;
|
|
||||||
}
|
|
||||||
if (StringUtils.isBlank(ids)) {
|
if (StringUtils.isBlank(ids)) {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue