Explorar o código

Merge branch 'master' of http://47.100.37.243:10191/wutt/manHourHousekeeper

QuYueTing hai 1 mes
pai
achega
0478f7b4e3

+ 1 - 1
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/service/ProjectService.java

@@ -250,7 +250,7 @@ public interface ProjectService extends IService<Project> {
 
     HttpRespMsg getFTEData(Integer pageIndex, Integer pageSize,String monthStart,String monthEnd, String area,String userId,String sortProp, Integer sortOrder,Integer departmentId,HttpServletRequest request);
 
-    HttpRespMsg exportFTEData(String monthStart,String monthEnd, String area, HttpServletRequest request);
+    HttpRespMsg exportFTEData(String monthStart,String monthEnd, String area,Integer departmentId, HttpServletRequest request);
 
     HttpRespMsg getProjectListByToken(String json);
 

+ 2 - 2
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/service/impl/ProjectServiceImpl.java

@@ -13416,7 +13416,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
 
     //导出FTE报表数据
     @Override
-    public HttpRespMsg exportFTEData(String monthStart,String monthEnd, String area,HttpServletRequest request) {
+    public HttpRespMsg exportFTEData(String monthStart,String monthEnd, String area,Integer departmentId,HttpServletRequest request) {
         HttpRespMsg httpRespMsg = new HttpRespMsg();
         User user = userMapper.selectById(request.getHeader("token"));
         WxCorpInfo wxCorpInfo = wxCorpInfoMapper.selectOne(new QueryWrapper<WxCorpInfo>().eq("company_id", user.getCompanyId()));
@@ -13426,7 +13426,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
         if (userCustoms.size() != 0){
             customName = userCustoms.get(0).getName();
         }
-        HttpRespMsg fteData = getFTEData(null, null, monthStart,monthEnd, area,null,null,null,null,request);
+        HttpRespMsg fteData = getFTEData(null, null, monthStart,monthEnd, area,null,null,null,departmentId,request);
         LocalDate timeStart = LocalDate.parse(monthStart, DateTimeFormatter.ofPattern("yyyy-MM-dd"));
         LocalDate timeEnd = LocalDate.parse(monthEnd, DateTimeFormatter.ofPattern("yyyy-MM-dd"));
         timeStart=timeStart.with(TemporalAdjusters.firstDayOfMonth());

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

@@ -5619,6 +5619,20 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
                                 if (withCheckIn != null) {
                                     if (row.getCell(workContentIndex) != null) {
                                         workContent = row.getCell(workContentIndex).getStringCellValue().trim();
+                                        //支持多个项目内容,用 | 隔开,每个项目内容以项目名称:开头,支持中英文冒号,取当前项目名称匹配的内容
+                                        if (!StringUtils.isEmpty(workContent)) {
+                                            String[] split = workContent.split("\\|");
+                                            for (String s : split) {
+                                                //按:或者:分割
+                                                String[] split1 = s.split(":|:");
+                                                if (split1.length >= 2) {
+                                                    if (split1[0].equals(pName)) {
+                                                        workContent = s.replaceAll(split1[0] + ":", "").replaceAll(split1[0] + ":", "");
+                                                        break;
+                                                    }
+                                                }
+                                            }
+                                        }
                                         report.setContent(workContent);
                                     }
                                 }

+ 1 - 0
fhKeeper/formulahousekeeper/timesheet/src/views/corpreport/list.vue

@@ -2846,6 +2846,7 @@ export default {
           sl.monthStart= this.monthRange[0]+"-01"
           sl.monthEnd= this.monthRange[1]+"-01"
           sl.area = this.areaName || null
+          sl.departmentId = this.departmentIdArray.length > 0 ? this.departmentIdArray[this.departmentIdArray.length - 1] : ''
         }else if(this.ins == 20) {
           fName = this.$t('youXiaoGongShiShuaiBiao') + '.xlsx'
           url = "/project/exportEffectiveLaborHourRate"