Min 1 年之前
父節點
當前提交
a12147832f

+ 5 - 0
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/controller/ReportController.java

@@ -1541,6 +1541,11 @@ public class ReportController {
         return reportService.getPersonWorkHoursWagesDetail(date,userId,startDate,endDate);
     }
 
+    @RequestMapping("getPersonWorkHoursWagesDetailForTemp")
+    public HttpRespMsg getPersonWorkHoursWagesDetailForTemp(String date,String userId,String startDate,String endDate){
+        return reportService.getPersonWorkHoursWagesDetailForTemp(date,userId,startDate,endDate);
+    }
+
     @RequestMapping("getPersonWorkHoursWagesDetailForMob")
     public HttpRespMsg getPersonWorkHoursWagesDetailForMob(String date,String userId,String startDate,String endDate,Integer checkStatus,Integer detailStatus){
         return reportService.getPersonWorkHoursWagesDetailForMob(date,userId,startDate,endDate,checkStatus,detailStatus);

+ 9 - 5
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/controller/WxCorpInfoController.java

@@ -103,6 +103,7 @@ public class WxCorpInfoController {
 
 
     @RequestMapping("/testGetApprovalList")
+    @Transactional
     public HttpRespMsg testGetApprovalList(String startDate,String endDate) throws Exception {
         HttpRespMsg msg=new HttpRespMsg();
         JSONArray jsonArrayFilter = new JSONArray();
@@ -308,10 +309,11 @@ public class WxCorpInfoController {
                     }
                     if(title.getJSONObject(0).getString("text").equals("开始时间")){
                         if(control.equals("Date")){
-                            long s_timestamp = value.getLongValue("s_timestamp");
+                            JSONObject date = value.getJSONObject("date");
+                            long s_timestamp = date.getLongValue("s_timestamp");
                             LocalDate localDateFromUnix = DateTimeUtil.getLocalDateFromUnix(s_timestamp);
                             plan.setStartDate(localDateFromUnix);
-                            if(sptime!=0){
+                            if(sptime>0){
                                 createDate= DateTimeUtil.getLocalDateFromUnix(sptime);
                             }else {
                                 createDate=localDateFromUnix;
@@ -321,10 +323,11 @@ public class WxCorpInfoController {
                     }
                     if(title.getJSONObject(0).getString("text").equals("结束时间")){
                         if(control.equals("Date")){
-                            long s_timestamp = value.getLongValue("s_timestamp");
+                            JSONObject date = value.getJSONObject("date");
+                            long s_timestamp = date.getLongValue("s_timestamp");
                             LocalDate localDateFromUnix = DateTimeUtil.getLocalDateFromUnix(s_timestamp);
                             plan.setEndDate(localDateFromUnix);
-                            if(sptime!=0){
+                            if(sptime>0){
                                 createDate= DateTimeUtil.getLocalDateFromUnix(sptime);
                             }else {
                                 createDate=localDateFromUnix;
@@ -374,6 +377,7 @@ public class WxCorpInfoController {
                         }
                     }
                 }
+                planService.save(plan);
                 List<Report> reportList=new ArrayList<>();
                 //处理人员日报数据
                 for (String userTeam : userTeams) {
@@ -388,6 +392,7 @@ public class WxCorpInfoController {
                         report.setCost(bigDecimal);
                         report.setWorkingTime(workTime);
                         report.setStatus(2);
+                        report.setPlanId(plan.getId());
                         report.setCompanyId(7);
                         report.setDeptId(deptId);
                         reportList.add(report);
@@ -396,7 +401,6 @@ public class WxCorpInfoController {
                 if(reportList.size()>0){
                     reportService.saveBatch(reportList);
                 }
-                planService.save(plan);
             }
         }
         msg.setData(approvalInfo);

+ 3 - 0
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/entity/User.java

@@ -319,6 +319,9 @@ public class User extends Model<User> {
     @TableField(exist = false)
     private String  totalSurplusResult;
 
+    @TableField(exist = false)
+    private String  totalTempResult;
+
     @Override
     protected Serializable pkVal() {
         return this.id;

+ 2 - 0
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/mapper/ReportMapper.java

@@ -221,4 +221,6 @@ public interface ReportMapper extends BaseMapper<Report> {
             "LEFT JOIN prod_procedure ON prod_procedure.id = report.`prod_procedure_id`\n" +
             "WHERE plan.`create_time` > '2024-01-01' AND report.`finish_num` > 0 AND ABS(report.`finish_num`/plan.`num`- report.`cost`/plan_procedure_total.`total_wages`) > 0.001")
     List<Map<String, Object>> findFinishNumErrorData();
+
+    List<Map<String, Object>> getPersonWorkHoursWagesDetailForTemp(String date, String userId, Integer companyId, String startDate, String endDate);
 }

+ 2 - 0
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/service/ReportService.java

@@ -162,4 +162,6 @@ public interface ReportService extends IService<Report> {
     HttpRespMsg fixFinishNumData();
 
     HttpRespMsg getPersonWorkHoursWagesDetailForMob(String date, String userId, String startDate, String endDate,Integer checkStatus,Integer detailStatus);
+
+    HttpRespMsg getPersonWorkHoursWagesDetailForTemp(String date, String userId, String startDate, String endDate);
 }

+ 23 - 5
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/service/impl/ReportServiceImpl.java

@@ -4106,10 +4106,14 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
             List<Map<String, Object>> targetList = personWorkHoursWagesList.stream().filter(p -> String.valueOf(p.get("crateDate")).equals(date)).collect(Collectors.toList());
             BigDecimal cost = targetList.stream().map(m -> new BigDecimal(String.valueOf(m.get("cost")))).reduce(BigDecimal.ZERO, BigDecimal::add);
             BigDecimal workTime = targetList.stream().map(m -> new BigDecimal(String.valueOf(m.get("workTime")))).reduce(BigDecimal.ZERO, BigDecimal::add);
+            BigDecimal tempCost = targetList.stream().map(m -> new BigDecimal(String.valueOf(m.get("tempCost")))).reduce(BigDecimal.ZERO, BigDecimal::add);
+            BigDecimal tempWorkTime = targetList.stream().map(m -> new BigDecimal(String.valueOf(m.get("tempWorkTime")))).reduce(BigDecimal.ZERO, BigDecimal::add);
             map.put("userId","0");
             map.put("crateDate",date);
             map.put("cost",cost.doubleValue());
             map.put("workTime",workTime.doubleValue());
+            map.put("tempCost",tempCost.doubleValue());
+            map.put("tempWorkTime",tempWorkTime.doubleValue());
             totalList.add(map);
         }
 //        totalUser.setPersonWorkHoursWages(totalList);
@@ -4184,6 +4188,8 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
                     map.put("crateDate", date);
                     map.put("cost", 0);
                     map.put("workTime", 0);
+                    map.put("tempCost", 0);
+                    map.put("tempWorkTime", 0);
                     map.put("departmentName", u.getDepartmentName());
                     if (targetTeams.size() > 0) {
                         double workTime = targetTeams.stream().mapToDouble(ProdProcedureTeam::getWorkTime).sum();
@@ -4241,9 +4247,13 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
             double surplusWorkTime = mapList.stream().filter(mt -> mt.get("surplusTime") != null).mapToDouble(mt -> Double.valueOf(String.valueOf(mt.get("surplusTime")))).sum();
             BigDecimal surplusBigDecimal = new BigDecimal(surplusWorkTime);
             double surplusCost = mapList.stream().filter(mt -> mt.get("surplusCost") != null).mapToDouble(mt -> Double.valueOf(String.valueOf(mt.get("surplusCost")))).sum();
+            double tempWorkTime = mapList.stream().filter(mt -> mt.get("tempWorkTime") != null).mapToDouble(mt -> Double.valueOf(String.valueOf(mt.get("tempWorkTime")))).sum();
+            BigDecimal tempBigDecimal = new BigDecimal(tempWorkTime);
+            double tempCost = mapList.stream().filter(mt -> mt.get("tempCost") != null).mapToDouble(mt -> Double.valueOf(String.valueOf(mt.get("tempCost")))).sum();
             u.setTotalResult(String.valueOf(bigDecimal.doubleValue()) + "分钟 " + String.format("%.2f", cost) + "元");
             u.setTotalPlanResult(String.valueOf(planBigDecimal.doubleValue()) + "分钟 " + String.format("%.2f", planCost) + "元");
             u.setTotalSurplusResult(String.valueOf(surplusBigDecimal.doubleValue()) + "分钟 " + String.format("%.2f", surplusCost) + "元");
+            u.setTotalTempResult(String.valueOf(tempBigDecimal.doubleValue()) + "分钟 " + String.format("%.2f", tempCost) + "元");
         }
         resultMap.put("total",userIPage.getTotal());
         resultMap.put("records",userList);
@@ -4288,11 +4298,6 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
     @Override
     public HttpRespMsg getPersonWorkHoursWagesDetail(String date, String userId,String startDate,String endDate) {
         User user = userMapper.selectById(request.getHeader("token"));
-//        if(checkStatus!=null&&checkStatus==0&&StringUtils.isEmpty(userId)){
-//            userId=user.getId();
-//        }
-        boolean canViewAll = sysFunctionService.hasPriviledge(user.getRoleId(), "查看全部人员工时工价");
-        List<Department> allDeptList = departmentMapper.selectList(new LambdaQueryWrapper<Department>().eq(Department::getCompanyId, user.getCompanyId()));
         List<Department> departmentList = departmentMapper.selectList(new QueryWrapper<Department>().eq("company_id", user.getCompanyId()).eq("manager_id", user.getId()));
         List<DepartmentOtherManager> departmentOtherManagers = departmentOtherManagerMapper.selectList(new QueryWrapper<DepartmentOtherManager>().eq("company_id", user.getCompanyId()).eq("other_manager_id", user.getId()));
         List<Integer> deptIds = departmentList.stream().map(Department::getDepartmentId).distinct().collect(Collectors.toList());
@@ -4407,6 +4412,19 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
         return httpRespMsg;
     }
 
+    @Override
+    public HttpRespMsg getPersonWorkHoursWagesDetailForTemp(String date, String userId, String startDate, String endDate) {
+        User user = userMapper.selectById(request.getHeader("token"));
+        List<Map<String,Object>> mapList=reportMapper.getPersonWorkHoursWagesDetailForTemp(date,userId,user.getCompanyId(),startDate,endDate);
+        HttpRespMsg httpRespMsg=new HttpRespMsg();
+        HashMap map=new HashMap();
+        map.put("record",mapList);
+        map.put("totalWorkingTime",mapList.stream().filter(i->i.get("working_time")!=null).mapToDouble(mt->Double.valueOf(String.valueOf(mt.get("working_time")))).sum());
+        map.put("totalCost",mapList.stream().filter(i->i.get("cost")!=null).mapToDouble(mt->Double.valueOf(String.valueOf(mt.get("cost")))).sum());
+        httpRespMsg.setData(map);
+        return httpRespMsg;
+    }
+
     private List<Integer> getBranchDepartment(Integer departmentId, List<Department> departmentList) {
         List<Integer> list = new ArrayList<>();
         list.add(departmentId);

+ 0 - 150
fhKeeper/formulahousekeeper/management-workshop/src/main/java/com/management/platform/util/ZipUtil.java

@@ -1,150 +0,0 @@
-package com.management.platform.util;
-
-import com.alibaba.excel.util.StringUtils;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import java.io.*;
-import java.util.Enumeration;
-import java.util.zip.*;
-
-/**
- * @Description 压缩与解压工具
- * @Author      yanghanwei
- * @Date        18:42 2019-11-20
- * @Version     v1
- **/
-public class ZipUtils {
-
-    private static final Logger logger = LoggerFactory.getLogger(ZipUtils.class);
-
-    /**
-     * 压缩 zip
-     * @param filePath  文件夹 全路径
-     * @param fileName  文件夹名称
-     * @param outPath   压缩文件保存路径
-     */
-    public static void zipFile(String filePath, String fileName, String outPath) {
-        logger.info("filePath:{}, fileName:{}, outPath:{}", filePath, fileName, outPath);
-        try {
-            //创建Test.zip文件
-            OutputStream is = new FileOutputStream(outPath);
-            //检查输出流,采用CRC32算法,保证文件的一致性
-            CheckedOutputStream cos = new CheckedOutputStream(is, new CRC32());
-            //创建zip文件的输出流
-            ZipOutputStream zos = new ZipOutputStream(cos);
-            //需要压缩的文件或文件夹对象
-            File file = new File(filePath);
-            //压缩文件的具体实现函数
-            zipFilePost(zos,file,filePath,fileName,outPath);
-            zos.close();
-            cos.close();
-            is.close();
-            System.out.println("压缩完成");
-        } catch (Exception e) {
-            logger.error("压缩失败zipFile,Exception:" + e);
-        }
-    }
-
-    /**
-     * 压缩文件
-     * @param zos       zip文件的输出流
-     * @param file      需要压缩的文件或文件夹对象
-     * @param filePath  压缩的文件路径
-     * @param fileName  需要压缩的文件夹名
-     * @param outPath   缩完成后保存为Test.zip文件
-     */
-    private static void zipFilePost(ZipOutputStream zos, File file, String filePath, String fileName, String outPath){
-
-        try{
-            String path = file.getPath();
-            String zosName = "";
-            if(!StringUtils.isEmpty(path)){
-                zosName = path.substring(path.indexOf(fileName));
-            }
-            File[] files = file.listFiles();
-            if(file.isDirectory() && files != null && files.length > 0) {
-                // 创建压缩文件的目录结构
-                zos.putNextEntry(new ZipEntry(zosName + File.separator));
-                for(File f : files) {
-                    zipFilePost(zos, f, filePath, fileName, outPath);
-                }
-            } else {
-                logger.info("正在压缩文件:{}",file.getName());
-                // 创建压缩文件
-                zos.putNextEntry(new ZipEntry(zosName));
-                // 用字节方式读取源文件
-                InputStream is = new FileInputStream(file.getPath());
-                // 创建一个缓存区
-                BufferedInputStream bis = new BufferedInputStream(is);
-                // 字节数组,每次读取1024个字节
-                byte [] b = new byte[1024];
-                // 循环读取,边读边写
-                while(bis.read(b)!=-1) {
-                    // 写入压缩文件
-                    zos.write(b);
-                }
-                //关闭流
-                bis.close();
-                is.close();
-            }
-        } catch (Exception e) {
-            logger.error("压缩文件失败zipFilePost,Exception:" + e);
-        }
-    }
-
-    public static void unzip(String sourcePath, String targetPath) {
-        //targetPath输出文件路径
-        File targetFile = new File(targetPath);
-        // 如果目录不存在,则创建
-        if (!targetFile.exists()) {
-            targetFile.mkdirs();
-        }
-        //sourcePath压缩包文件路径
-        try (ZipFile zipFile = new ZipFile(new File(sourcePath))) {
-            System.out.println("file nums:" + zipFile.size());
-            Enumeration enumeration = zipFile.entries();
-            while (enumeration.hasMoreElements()) {
-                //依次获取压缩包内的文件实体对象
-                ZipEntry entry = (ZipEntry) enumeration.nextElement();
-                String name = entry.getName();
-                if (entry.isDirectory()) {
-                    continue;
-                }
-                try (BufferedInputStream inputStream = new BufferedInputStream(zipFile.getInputStream(entry))) {
-                    // 需要判断文件所在的目录是否存在,处理压缩包里面有文件夹的情况
-                    String outName = targetPath + "/" + name;
-                    File outFile = new File(outName);
-                    File tempFile = new File(outName.substring(0, outName.lastIndexOf("/")));
-                    if (!tempFile.exists()) {
-                        tempFile.mkdirs();
-                    }
-                    try (BufferedOutputStream outputStream = new BufferedOutputStream(new FileOutputStream(outFile))) {
-                        int len;
-                        byte[] buffer = new byte[1024];
-                        while ((len = inputStream.read(buffer)) > 0) {
-                            outputStream.write(buffer, 0, len);
-                        }
-                    }
-
-                }
-
-            }
-
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-    }
-    public static void main(String[] args) throws Exception{
-//        String filePath = "/var/folders/88/jh37h0fj59l1f302jdryz4780000gn/T/201908月小微平台消耗-1574300435525/";
-//        // 需要压缩的文件夹名
-//        String fileName = "201908月小微平台消耗-1574300435525";
-//        // 压缩完成后保存为Test.zip文件,名字随意
-//        String outPath = "/var/folders/88/jh37h0fj59l1f302jdryz4780000gn/T/Test3.zip";
-//        zipFile(filePath, fileName, outPath);
-
-        String sourcePath = "C:\\gitproject\\manHourHousekeeper\\fhKeeper\\formulahousekeeper\\timesheet-workshop\\distPC.zip";
-        String targetPath = "C:\\文档资料\\distPC";
-        unzip(sourcePath, targetPath);
-    }
-}

+ 27 - 1
fhKeeper/formulahousekeeper/management-workshop/src/main/resources/mapper/ReportMapper.xml

@@ -135,7 +135,11 @@
     </select>
 
     <select id="getPersonWorkHoursWagesList" resultType="java.util.Map">
-        select b.id AS userId,c.department_name AS departmentName,b.name AS userName,DATE_FORMAT(a.create_date,'%Y%m%d') AS crateDate,IFNULL(SUM(a.cost),0) AS cost,IFNULL(SUM(a.working_time),0) AS workTime
+        select b.id AS userId,c.department_name AS departmentName,b.name AS userName,DATE_FORMAT(a.create_date,'%Y%m%d') AS crateDate,
+        IFNULL(SUM(IF(a.`user_procedure_team_id`IS NOT NULL,a.cost,NULL)),0) AS cost,
+        IFNULL(SUM(IF(a.`user_procedure_team_id` IS NOT NULL,a.working_time,NULL)),0) AS workTime,
+        IFNULL(SUM(IF(a.`user_procedure_team_id`IS NULL,a.cost,NULL)),0) AS tempCost,
+        IFNULL(SUM(IF(a.`user_procedure_team_id` IS NULL,a.working_time,NULL)),0) AS tempWorkTime
         from report a
         left join user b on a.creator_id=b.id
         left join department c on c.department_id=b.department_id
@@ -181,10 +185,32 @@
                 </otherwise>
             </choose>
         </if>
+        <if test="startDate!=null and endDate!=null">
+            and ppt2.distribute_date between #{startDate} and #{endDate}
+        </if>
+    </select>
+
+    <select id="getPersonWorkHoursWagesDetailForTemp" resultType="java.util.Map">
+        select r.cost,r.working_time,r.finish_num, r.creator_id,DATE_FORMAT(r.create_date,'%Y%m%d') as createDate,
+        p.name as productName,DATE_FORMAT(plan.start_date,'%Y%m%d') as planStartDate,DATE_FORMAT(plan.end_date,'%Y%m%d') as planEndDate ,
+        plan.task_change_notice_num as taskChangeNoticeNum,plan.plan_type as planType,u.name as checkerName,u2.name as creatorName,plan.task_name as taskName
+        from report r
+        left join product p on p.id=r.product_id
+        left join plan on plan.id=r.plan_id
+        left join user u on r.checker_id=u.id
+        left join user u2 on r.creator_id=u2.id
+        where r.company_id=#{companyId}  and r.user_procedure_team_id is null
+        <if test="date!=null and date!=''">
+            and r.create_date=#{date}
+        </if>
+        <if test="userId!=null and userId!=''">
+            and r.creator_id=#{userId}
+        </if>
         <if test="startDate!=null and endDate!=null">
             and r.create_date between #{startDate} and #{endDate}
         </if>
     </select>
+
     <!--修改前 人员工时工价表详情数据-->
     <select id="getPersonWorkHoursWagesDetail" resultType="java.util.Map">
         select r.cost,r.working_time,r.finish_num as finish_num, r.creator_id,ppt.total_progress as progress,DATE_FORMAT(r.create_date,'%Y%m%d') as createDate,pp.name as procedureName,(case  when pp.check_type=0 then '自检' when pp.check_type=1 then '互检' else '专检' end) as checkType,

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet-workshop/src/views/plan/planComponent.vue

@@ -158,7 +158,7 @@
             <el-select :disabled="todayPlanForm.id==null?false:true" v-model="todayPlanForm.productId" placeholder="请选择" class="w100" @change="setProductCode" filterable>
               <el-option v-for="item in productList" :key="item.id" :label="item.name" :value="item.id">
               </el-option>
-            </el-select>
+            </el-select>  
           </el-form-item>
           <el-form-item label="项目代码" style="width: 100%" prop="projectCode">
             <el-input :disabled="todayPlanForm.id==null?false:true" v-model="todayPlanForm.projectCode" maxlength="50" readonly></el-input>

+ 55 - 5
fhKeeper/formulahousekeeper/timesheet-workshop/src/views/statistic/index.vue

@@ -88,11 +88,14 @@
                 <el-table-column align="center" prop="name" label="人员" min-width="100" fixed="left"></el-table-column>
                 <el-table-column v-for="(item, index) in personWorkHoursWagesHead" :key="index" :label="item" align="center" min-width="150">
                     <template slot-scope="scope">
-                        <div v-for="(items, indexs) in scope.row.personWorkHoursWages" :key="indexs" @click="showReportDetail(scope.row,item,0)" :class="`${scope.row.departmentCascade== '小计' ? '' : 'colorText'}`">
+                        <div v-for="(items, indexs) in scope.row.personWorkHoursWages" :key="indexs" :class="`${scope.row.departmentCascade== '小计' ? '' : 'colorText'}`">
                             <div v-if="items.crateDate == item">
                               <div  style="color: black;" v-if="items.planWorkTime">平均 {{items.planWorkTime}}分钟  {{items.planCost}}元</div>
                               <div v-if="items.leave">{{items.leave}}</div>
-                              <div v-else>已填 {{items.workTime}}分钟  {{items.cost}}元</div> 
+                              <template v-else>
+                                  <div @click.stop="showReportDetail(scope.row,item,0)">已填 {{items.workTime}}分钟  {{items.cost}}元</div>
+                                <div style="color: green;" @click.stop="showTempReportDetail(scope.row,item,0)">临时报工 {{items.tempWorkTime}}分钟  {{items.tempCost}}元</div>
+                              </template>  
                               <div style="color: red;" v-if="items.surplusTime">剩余 {{items.surplusTime}}分钟  {{items.surplusCost}}元</div>
                             </div>
                         </div>
@@ -100,11 +103,10 @@
                 </el-table-column>
                 <el-table-column align="center" prop="totalResult" label="合计" min-width="180">
                    <template slot-scope="scope" >
-                    <div @click="showReportDetail(scope.row,item,1)">
-                      <div  style="color: black;">平均 {{scope.row.totalPlanResult}}</div>
+                    <div style="color: black;">平均 {{scope.row.totalPlanResult}}</div>
                       <div style="color: #02a7f0;"  @click="showReportDetail(scope.row,item,1)">已填 {{scope.row.totalResult}}</div> 
+                      <div style="color: green;"  @click="showTempReportDetail(scope.row,item,1)">临时报工 {{scope.row.totalTempResult}}</div> 
                       <div style="color: red;">剩余 {{scope.row.totalSurplusResult}}</div>
-                    </div>
                   </template>
                 </el-table-column>
             </el-table>
@@ -762,6 +764,15 @@ export default {
       this.detailUserId=row.id
       this.getPersonWorkHoursWagesDetail(item,viewAll)
     },
+    showTempReportDetail(row,item,viewAll){
+      if(row.departmentCascade=='小计'){
+          return
+      }
+      console.log(item)
+      this.reportDetailDialog=true
+      this.detailUserId=row.id
+      this.getPersonWorkHoursWagesDetailForTemp(item,viewAll)
+    },
     authorityToJudge() {
     //   if(this.permissions.reportProject || this.permissions.reportAllProject) {this.ssl(0);this.defaultActive = '1-1';return} else
     //   if(this.permissions.reportTask || this.permissions.reportAllTask) {this.ssl(1);this.defaultActive = '1-2';return} else
@@ -970,6 +981,45 @@ export default {
         });
       });
     },
+    getPersonWorkHoursWagesDetailForTemp(item,viewAll){
+      this.listLoading=true
+      let param={
+        userId:this.detailUserId
+      }
+      if(viewAll==1){
+        this.simpleDateChoose=''
+        param={
+          ...param,
+          startDate:this.rangeDatas[0],
+          endDate:this.rangeDatas[1]
+        }
+      }else{
+        this.simpleDateChoose=item
+        param={
+          ...param,
+          date: this.simpleDateChoose.substring(0,4)+"-"+this.simpleDateChoose.substring(4,6)+"-"+this.simpleDateChoose.substring(6,this.simpleDateChoose.length),
+        }
+      }
+      this.http.post( "/report/getPersonWorkHoursWagesDetailForTemp", param,
+      res => {
+        if (res.code == "ok") {
+          this.personWorkHoursWagesDetail=res.data.record
+          this.totalCost=res.data.totalCost
+          this.totalWorkingTime=res.data.totalWorkingTime
+        } else {
+          this.$message({
+            message: res.msg,
+            type: "error"
+          });
+        }
+        this.listLoading=false
+      },error => {
+        this.$message({
+          message: error,
+          type: "error"
+        });
+      });
+    },
     //工序实际工时表
     getProcedureRealTimeProgressList(){
       this.listLoading=true