yurk 2 роки тому
батько
коміт
a0c0a3327b

+ 3 - 0
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/service/impl/ReportServiceImpl.java

@@ -4419,12 +4419,15 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
                                         String deptAuditorName ="$userName="+ item.getCorpwxRealUserid() +"$";
                                         departmentName = "$departmentName=" + departmentName + "$";
                                         if(timeType.getReportAuditType()==4){
+                                            departmentName = map.get("buDepartmentName") + "";
+                                            departmentName = "$departmentName=" + departmentName + "$";
                                             row.createCell(index).setCellValue("待项目所属BU[" + departmentName + "](" + deptAuditorName + ")审核");
                                         }else {
                                             row.createCell(index).setCellValue("待" + departmentName + "(" + deptAuditorName + ")审核");
                                         }
                                     }else {
                                         if(timeType.getReportAuditType()==4){
+                                            departmentName = map.get("buDepartmentName") + "";
                                             row.createCell(index).setCellValue("待项目所属BU[" + departmentName + "](" + item.getName() + ")审核");
                                         }else {
                                             row.createCell(index).setCellValue("待" + departmentName + "(" + item.getName() + ")审核");

+ 6 - 3
fhKeeper/formulahousekeeper/management-platform/src/main/resources/mapper/ReportMapper.xml

@@ -63,7 +63,7 @@
         a.department_audit_state as departmentAuditState, a.stage, a.pic_str as picStr, multi_worktime as multiWorktime,a.is_dept_audit as isDeptAudit,a.group_audit_state as groupAuditState,task_group.incharger_id as inchargerId,a.project_audit_state as projectAuditState,a.audit_dept_managerid as deptAuditorName
         ,c.plate1 as plate1,c.plate2 as plate2,c.plate3 as plate3,c.plate4 as plate4,c.plate5 as plate5
         , reject_reason as rejectReason, reject_username as rejectUsername, reject_userid as rejectUserid, degree_id as degree_id,report_extra_degree.name as degreeName,task_group.name as groupName,a.group_id as groupId,a.custom_data as customData
-        ,u.name as projectAuditorName, a.project_auditor_id as projectAuditorId, department.department_name as departmentName,department.department_id as departmentId, a.overtime_hours as overtimeHours, a.custom_text as customText,a.project_audit_time  as projectAuditTime,project_main.name as projectMainName
+        ,u.name as projectAuditorName, a.project_auditor_id as projectAuditorId, department.department_name as departmentName,dp2.department_name as buDepartmentName,department.department_id as departmentId, a.overtime_hours as overtimeHours, a.custom_text as customText,a.project_audit_time  as projectAuditTime,project_main.name as projectMainName
         FROM report AS a
         JOIN project AS b ON a.project_id=b.id
         LEFT JOIN user AS c ON a.creator_id=c.id
@@ -73,6 +73,7 @@
         left join task_group on task_group.id = a.group_id
         left join user u on u.id = a.project_auditor_id
         left join department on department.department_id = c.department_id
+        left join department dp2 on dp2.department_id = b.bu_id
         left join project_main on b.project_main_id=project_main.id
         WHERE (<if test="stateKey == null or stateKey == 0">
         a.state = 1
@@ -166,7 +167,7 @@
         a.custom_data as customData
         ,c.plate1 as plate1,c.plate2 as plate2,c.plate3 as plate3,c.plate4 as plate4,c.plate5 as plate5
         ,u.name as projectAuditorName, a.project_auditor_id as projectAuditorId, department.department_name as
-        departmentName,department.department_id as departmentId, a.overtime_hours as overtimeHours, a.custom_text as customText, a.project_audit_time as
+        departmentName,dp2.department_name as buDepartmentName,department.department_id as departmentId, a.overtime_hours as overtimeHours, a.custom_text as customText, a.project_audit_time as
         projectAuditTime,project_main.name as projectMainName
         FROM report AS a
         JOIN project AS b ON a.project_id=b.id
@@ -177,6 +178,7 @@
         left join task_group on task_group.id = a.group_id
         left join user u on u.id = a.project_auditor_id
         left join department on department.department_id = c.department_id
+        left join department dp2 on dp2.department_id = b.bu_id
         left join project_main on project_main.id=b.project_main_id
         WHERE
         (<if test="stateKey == null or stateKey == 0">
@@ -218,7 +220,7 @@
         a.department_audit_state as departmentAuditState,a.stage, a.pic_str as picStr, multi_worktime as multiWorktime,a.is_dept_audit as isDeptAudit,a.group_audit_state as groupAuditState,task_group.incharger_id as inchargerId,a.project_audit_state as projectAuditState,a.audit_dept_managerid as deptAuditorName
         ,c.plate1 as plate1,c.plate2 as plate2,c.plate3 as plate3,c.plate4 as plate4,c.plate5 as plate5
         , reject_reason as rejectReason, reject_username as rejectUsername, reject_userid as rejectUserid, degree_id as degree_id,report_extra_degree.name as degreeName,task_group.name as groupName,a.group_id as groupId, a.custom_data as customData
-        ,u.name as projectAuditorName, a.project_auditor_id as projectAuditorId, department.department_name as departmentName,department.department_id as departmentId, a.overtime_hours as overtimeHours, a.custom_text as customText, a.project_audit_time as projectAuditTime,project_main.name as projectMainName
+        ,u.name as projectAuditorName, a.project_auditor_id as projectAuditorId, department.department_name as departmentName,dp2.department_name as buDepartmentName,department.department_id as departmentId, a.overtime_hours as overtimeHours, a.custom_text as customText, a.project_audit_time as projectAuditTime,project_main.name as projectMainName
         FROM report AS a
         JOIN project AS b ON a.project_id=b.id
         LEFT JOIN user AS c ON a.creator_id=c.id
@@ -228,6 +230,7 @@
         left join task_group on task_group.id = a.group_id
         left join user u on u.id = a.project_auditor_id
         left join department on department.department_id = c.department_id
+        left join department dp2 on dp2.department_id = b.bu_id
         left join project_main on project_main.id=b.project_main_id
         WHERE (
         <if test="stateKey == null or stateKey == 0">