Преглед на файлове

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

cs преди 2 години
родител
ревизия
714faf2c10

+ 2 - 1
fhKeeper/formulahousekeeper/timesheet/index.html

@@ -71,11 +71,12 @@
             .projectSelectPopperClass .el-select-dropdown__item span:nth-child(1){
                 font-size: 13px;
                 height: 34px;
+                width: 35%;
             }
             .projectSelectPopperClass .el-select-dropdown__item span:nth-child(2){
                 font-size: 13px;
                 height: 34px;
-                width: 70%;
+                width: 65%;
                 overflow: hidden;
                 white-space: nowrap;
                 text-overflow: ellipsis;

+ 21 - 4
fhKeeper/formulahousekeeper/timesheet/src/i18n/en.json

@@ -51,7 +51,8 @@
     "rejected": "rejected",
     "completed": "completed",
     "tried": "tried",
-    "untrial": "untrial"
+    "untrial": "untrial",
+    "undone": "undone"
   },
   "time": {
     "dueDate": "Due date",
@@ -187,7 +188,7 @@
     "prompts": "prompt",
     "expired": "expired",
     "AskForLeaveOnTheSameDay": "Ask for leave on the same day",
-    "AskForLeave": "Ask for leave", 
+    "AskForLeave": "Ask for leave",
     "dailyWork": "Daily work",
     "people": "people",
     "totalWorkingHours": "Total working hours",
@@ -279,7 +280,8 @@
     "workHourData": "Work hour data",
     "specificcontentandresults": "specific content and results",
     "pleaseYes": "please yes",
-    "tofillin": "to fill in"
+    "tofillin": "to fill in",
+    "Tobereviewedbytheprojectreviewer": "To be reviewed by the project reviewer"
   },
   "export": {
     "dailyExport": "daily export",
@@ -345,5 +347,20 @@
     "leave": "leave",
     "paternityLeave": "paternity leave",
     "other": "other"
-  }
+  },
+  "qing-xuan-ze-bu-men": "Please select a department",
+  "ren-yuan": "personnel",
+  "Auditrecords": "Audit records",
+  "Batchrejected": "Bulk rejection",
+  "Batchthrough": "batch pass",
+  "workAttendance": "Attendance time",
+  "operation": "operate",
+  "reasonforyourdecisiontoreject": "Please enter the reason for your decision to reject",
+  "AuditTime": "Review time",
+  "EmployeeDate": "employee/date",
+  "Reviewtheresults": "Audit results",
+  "details": "Details",
+  "yourdecisiontorevoke": "Please enter the reason for your decision to withdraw",
+  "enterapassrating": "Please enter a pass rating",
+  "Revocationofsuccess": "Undo succeeded"
 }

+ 21 - 4
fhKeeper/formulahousekeeper/timesheet/src/i18n/zh.json

@@ -5,7 +5,7 @@
     "projectManagement": "项目管理",
     "professionalAudit": "专业审核",
     "departmentAudit": "部门审核",
-    "projectReportReview": "项目报告审核", 
+    "projectReportReview": "项目报告审核",
     "ImportDailyReview": "导入日报审核",
     "laborCostStatistics": "工时成本统计",
     "customizeNumericalStatistics": "自定义数值统计",
@@ -51,7 +51,8 @@
     "rejected": "已驳回",
     "completed": "已完成",
     "tried": "已审",
-    "untrial": "未审"
+    "untrial": "未审",
+    "undone": "已撤销"
   },
   "time": {
     "dueDate": "到期日期",
@@ -279,7 +280,8 @@
     "workHourData": "条工时数据",
     "specificcontentandresults": "具体内容与结果",
     "pleaseYes": "请对",
-    "tofillin": "进行填写"
+    "tofillin": "进行填写",
+    "Tobereviewedbytheprojectreviewer": "待项目审核人审核"
   },
   "export": {
     "dailyExport": "日报导出",
@@ -345,5 +347,20 @@
     "leave": "调休假",
     "paternityLeave": "陪产假",
     "other": "其他"
-  }
+  },
+  "qing-xuan-ze-bu-men": "请选择部门",
+  "ren-yuan": "人员",
+  "Batchthrough": "批量通过",
+  "Batchrejected": "批量驳回",
+  "Auditrecords": "审核记录",
+  "workAttendance": "考勤时长",
+  "operation": "操作",
+  "reasonforyourdecisiontoreject": "请输入您决定驳回的原因",
+  "AuditTime": "审核时间",
+  "Reviewtheresults": "审核结果",
+  "EmployeeDate": "员工/日期",
+  "details": "详情",
+  "yourdecisiontorevoke": "请输入您决定撤销的原因",
+  "enterapassrating": "请输入通过评价",
+  "Revocationofsuccess": "撤销成功"
 }

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

@@ -62,7 +62,7 @@
           <el-select v-model="cusProJuctId" placeholder="请选择项目" clearable filterable size="small" @change="selcts()" popper-class="projectSelectPopperClass">
             <el-option v-for="(item) in cusProListOvertime" :key="item.id" :label="item.projectName + (item.projectCode ? item.projectCode : '')" :value="item.id">
               <span style="float: left;color: #8492a6;">{{ item.projectCode }}</span>
-              <span style="float: right;font-size: 13px;margin-left: 20px">{{ item.projectName }}</span>
+              <span style="float: right;font-size: 13px;">{{ item.projectName }}</span>
             </el-option>
           </el-select>
         </template>

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet/src/views/expense/expense.vue

@@ -117,7 +117,7 @@
                 <el-select size="small" v-model="scope.row.projectId" placeholder="项目" style="width: 150px" filterable popper-class="projectSelectPopperClass">
                   <el-option v-for="(item, index) in projectList" :key="index" :label="item.projectName + item.projectCode" :value="item.id" @click="ok(item)">
                     <span style="float: left;color: #8492a6; font-size: 13px">{{ item.projectCode }}</span>
-                    <span style="float: right;margin-left: 20px">{{ item.projectName }}</span>
+                    <span style="float: right;">{{ item.projectName }}</span>
                   </el-option>
                 </el-select>
               </template>

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet/src/views/project/cost.vue

@@ -71,7 +71,7 @@
                     <el-select v-model="exportParam.projectId" placeholder="全部项目"  clearable style="width:350px;" filterable="true" popper-class="projectSelectPopperClass">
                         <el-option v-for="item in projectList"  :key="item.id" :label="item.projectName + item.projectCode" :value="item.id">
                             <span style="float: left;color: #8492a6;">{{ item.projectCode }}</span>
-                            <span style="float: right;font-size: 13px;margin-left: 20px">{{ item.projectName }}</span>
+                            <span style="float: right;font-size: 13px;">{{ item.projectName }}</span>
                         </el-option>
                     </el-select>
                 </el-form-item>

+ 24 - 0
fhKeeper/formulahousekeeper/timesheet/src/views/project/list.vue

@@ -88,6 +88,9 @@
                             <el-dropdown-item v-if="permissions.projectExport">
                                 <el-link type="primary" :underline="false" @click="exportProjectData" download="项目导出.xlsx">导出项目</el-link>
                             </el-dropdown-item>
+                            <el-dropdown-item v-if="user.company.packageProject == 1 && permissions.projectExport">
+                                <el-link type="primary" :underline="false" @click="exportProjectGroup" download="任务分组导出.xlsx">导出任务分组</el-link>
+                            </el-dropdown-item>
                             <el-dropdown-item v-if="user.company.packageProject == 1 && permissions.projectCostOfItems">
                                 <el-link type="primary" :underline="false" @click="showBaseCostItemDialog">基线成本项</el-link>
                             </el-dropdown-item>
@@ -2090,6 +2093,27 @@ a {
                     }
                 );
             },
+            exportProjectGroup() {
+                //导出项目分组
+                this.http.post('/project/exportGroupData',{},
+                res => {
+                    if (res.code == "ok") {
+                        var filePath = res.data;
+                        const a = document.createElement('a'); // 创建a标签
+                        a.setAttribute('download', '项目任务分组导出.xls');// download属性
+                        a.setAttribute('href', filePath);// href链接
+                        a.click(); //自执行点击事件
+                        a.remove();
+                    } 
+                },
+                error => {
+                    this.$message({
+                        message: error,
+                        type: "error"
+                    });
+                    }
+                );
+            },
             userssHu() {
                 this.http.post('/time-type/getCompanyTimeSetting',{ 
                     companyId: this.user.companyId

+ 0 - 2
fhKeeper/formulahousekeeper/timesheet/src/views/project/projectInside.vue

@@ -32,9 +32,7 @@
                     <el-aside :style="'overflow:auto;padding-left:10px;padding-right:5px;height:'+tableHeight+'px;width:'+groupWidth+'px;'">
                         <el-input v-model="groupSearch" size="small" placeholder="搜索分组" @input="startSearchGroup" style="margin-top:10px"/>
                         <p ><span class="heavyTxt">任务分组</span>
-                            <!-- <el-button size="mini">导出</el-button> -->
                             <i class="el-icon-plus pull-right" style="color:#666;margin-right:10px;" @click="createGroup" v-if="projectCreatorId == user.id || projectInchargerId == user.id || permissions.projectManagement"></i>
-                            <i class="iconfont firerock-icondaochu pull-right" style="font-size:14px"></i>
                         </p>
                         <el-menu :default-active="defaultGroupId" ref="defaultMenu"  class="el-menu-vertical-demo" @select="groupChange" style="border-right:none;">
                             <el-menu-item :index="item.id" v-for="item in groupList" :key="item.id"  class="group_style">

+ 22 - 3
fhKeeper/formulahousekeeper/timesheet/src/views/settings/timetype.vue

@@ -18,7 +18,7 @@
             </el-form-item>    
             <el-form-item label="每日正常工作时长" prop="allday">
-                <el-select v-model="timeType.allday" placeholder="请选择工作时长" style="width:120px;" @change="timeChange">
+                <el-select v-model="timeType.allday" placeholder="请选择工作时长" style="width:120px;" @change="timeAlldayChange">
                     <el-option v-for="item in times" :key="item" :label="item.toFixed(1)" :value="item"></el-option>
                 </el-select>
                 小时
@@ -29,7 +29,9 @@
                     <i class="el-icon-question" style="color:#606266"></i>
                 </el-tooltip>
                 <span style="margin-left:25px">填报时长上限</span>
-                <el-input :disabled="timeType.lockWorktime" :min="timeType.allday" v-model="timeType.maxReportTime" type="number" style="width:120px;margin-left:10px"></el-input><span style="margin-left:5px;color:#409eff">小时</span>
+                <el-select :disabled="timeType.lockWorktime" v-model="timeType.maxReportTime" type="number" style="width:120px;margin-left:10px">
+                    <el-option v-for="item in maxReportTimeRange" :key="item" :label="item.toFixed(1)" :value="item"></el-option>
+                </el-select><span style="margin-left:5px;color:#409eff">小时</span>
                 </span>
                 
             </el-form-item><br>
@@ -488,6 +490,7 @@
                     children: 'children',
                     label: 'label'
                 },
+                maxReportTimeRange: []
             };
         },
         watch: {
@@ -496,8 +499,18 @@
             }
         },
         methods: {
+            timeAlldayChange(){
+                if(this.timeType.maxReportTime < this.timeType.allday || this.timeType.lockWorktime){
+                    this.timeType.maxReportTime = this.timeType.allday
+                }
+                this.maxReportTimeRange = []
+                for(let i=this.timeType.allday; i<=24; i+=0.5){
+                    this.maxReportTimeRange.push(i)
+                }
+                this.timeChange()
+            },
             lockChange(){
-                console.log('lockChange',this.timeType.maxReportTime);
+                // console.log('lockChange',this.timeType.maxReportTime);
                 if(this.timeType.lockWorktime){
                     this.timeType.maxReportTime = this.timeType.allday
                 }
@@ -1007,6 +1020,12 @@
                             this.timeType.customDataMaxValue = this.timeType.customDataMaxValue ? this.timeType.customDataMaxValue : 100
                             this.timeType.reportAutoApproveDays = this.timeType.reportAutoApproveDays ? this.timeType.reportAutoApproveDays : 1
                             this.timeChange();
+
+                            this.maxReportTimeRange = [] // 填报时长上限
+                            for(let i=this.timeType.allday; i<=24; i+=0.5){
+                                this.maxReportTimeRange.push(i)
+                            }
+
                             let userlist = res.data.userList
                             this.whiteList = []
                             for(let i in userlist){

+ 8 - 8
fhKeeper/formulahousekeeper/timesheet/src/views/workReport/daily.vue

@@ -340,7 +340,7 @@
                             @change="iptChang()">
                         </el-time-picker>
                         </span>
-                        <div class="overtime" v-if="user.timeType.fillOvertime || isWeekend">
+                        <div class="overtime" v-if="user.timeType.fillOvertime || (isWeekend && user.timeType.lockWorktime != 1)">
                             <el-checkbox :disabled="!domain.canEdit" v-model="domain.isOvertime">{{$t('other.IncludingOvertime')}}</el-checkbox>
                             <el-input :disabled="!domain.canEdit || domain.isOvertime==null || domain.isOvertime==0 || !domain.isOvertime" v-model="domain.overtimeHours" @blur="triggerCalculateOT(index)" @input="domain.overtimeHours=domain.overtimeHours.replace(/[^\d.]/g,'')" style="width: 100px;"></el-input><span style="margin-left:5px">{{$t('time.hour')}}</span>
                         </div>
@@ -354,7 +354,7 @@
                             <!-- <el-option v-for="item in projectList" :disabled="item.status>=2" :key="item.id" :label="item.projectName" :value="item.id"></el-option> -->
                             <el-option v-for="item in fillProjectList" :disabled="item.status!=1 && item.status!=4" :key="item.id" :label="item.projectName + '\u3000' + item.projectCode" :value="item.id">
                                 <span style="float: left; color: #8492a6; font-size: 13px;">{{ item.projectCode }}</span>
-                                <span style="float: right;margin-left: 20px">{{ item.projectName }}</span>
+                                <span style="float: right;">{{ item.projectName }}</span>
                             </el-option>
                         </el-select>
                         <template v-if="user.timeType.mainProjectState != 1">
@@ -463,7 +463,7 @@
                             :disabled="workForm.domains.length==0?true:(workForm.domains[index].state>=2?false:true)" popper-class="projectSelectPopperClass">
                                 <el-option v-for="item in fillProjectList" :disabled="item.status!=1 && item.status!=4" :key="item.id" :label="item.projectName + '\u3000' + item.projectCode" :value="item.id">
                                     <span style="float: left; color: #8492a6; font-size: 13px;">{{ item.projectCode }}</span>
-                                    <span style="float: right;margin-left: 20px">{{ item.projectName }}</span>
+                                    <span style="float: right;">{{ item.projectName }}</span>
                                 </el-option>
                             </el-select>
                             <template v-if="user.timeType.mainProjectState != 1">
@@ -482,7 +482,7 @@
                                 <i class="fa fa-trash" style="color: red;;font-size:18px;"></i>
                             </el-link>
 
-                            <div class="overtime" v-if="user.timeType.fillOvertime || isWeekend"><el-checkbox :disabled="!domain.canEdit" v-model="domain.isOvertime">{{$t('other.IncludingOvertime')}}</el-checkbox>
+                            <div class="overtime" v-if="user.timeType.fillOvertime"><el-checkbox :disabled="!domain.canEdit" v-model="domain.isOvertime">{{$t('other.IncludingOvertime')}}</el-checkbox>
                             <el-input :disabled="!domain.canEdit || domain.isOvertime==null || domain.isOvertime==0 || !domain.isOvertime" v-model="domain.overtimeHours" @blur="triggerCalculateOT(index)" @input="domain.overtimeHours=domain.overtimeHours.replace(/[^\d.]/g,'')" style="width: 100px;"></el-input><span style="margin-left:5px">{{$t('time.hour')}}</span>
                             </div>
                             
@@ -4000,7 +4000,7 @@
                                 userNames:null,
                                 time: this.report.time
                             }
-                            if(this.isWeekend){
+                            if(this.isWeekend && this.user.timeType.lockWorktime != 1){
                                 this.$set(this.workForm.domains[0],'isOvertime',true)
                                 if(this.reportTimeType.type != 2){
                                     this.$set(this.workForm.domains[0],'overtimeHours',this.reportTimeType.allday.toFixed(0))
@@ -4991,7 +4991,7 @@
                         canEdit: true
                         // degreeId: '',
                 };
-                if(this.isWeekend){
+                if(this.isWeekend && this.user.timeType.lockWorktime != 1){
                     this.$set(addItem,'isOvertime',true)
                     if(this.reportTimeType.type == 3){
                         this.$set(addItem,'overtimeHours',(leftProgress*this.reportTimeType.allday/100).toFixed(0))
@@ -5755,9 +5755,9 @@
         .chooseDate {
             position: absolute;
             bottom: -3px;
-            width: 34px;
+            width: 37px;
             height: 2px;
-            left: 12px;
+            left: 14px;
             background: #20a0ff;
         }
     }

+ 79 - 80
fhKeeper/formulahousekeeper/timesheet/src/views/workReport/list.vue

@@ -3,23 +3,23 @@
         <!--工具条-->
         <el-col :span="24" class="toolbar" style="padding-bottom: 0px;">
             <el-form :inline="true">
-                <el-form-item label="部门" style="width: 165px">
-                    <el-cascader v-model="search.departmentIdArray" placeholder="请选择部门" style="width: 125px"
+                <el-form-item :label="$t('lable.department')" style="width: 165px">
+                    <el-cascader v-model="search.departmentIdArray" :placeholder="$t('qing-xuan-ze-bu-men')" style="width: 125px"
                     :options="option" :props="{ checkStrictly: false,expandTrigger: 'hover' }" :show-all-levels="false" clearable
                     @change="getList(1)" size="mini"
                     ></el-cascader>
                     <!-- <el-button @click="test" size="mini">test</el-button> -->
                 </el-form-item>
-                <el-form-item label="人员" style="width: 210px">
-                        <el-select v-model="search.userIdArray" placeholder="请选择" clearable @visible-change="usersSearch" @remove-tag="usersSearch(false)" @clear="usersSearch(false)" filterable="true" size="mini" style="width: 150px" multiple collapse-tags>
+                <el-form-item :label="$t('ren-yuan')" style="width: 210px">
+                        <el-select v-model="search.userIdArray" :placeholder="$t('defaultText.pleaseChoose')" clearable @visible-change="usersSearch" @remove-tag="usersSearch(false)" @clear="usersSearch(false)" filterable="true" size="mini" style="width: 150px" multiple collapse-tags>
                             <el-option v-for="item in searchUsersList" :key="item.id" :label="item.name" :value="item.id"></el-option>
                         </el-select>
                     </el-form-item>
-                <el-form-item label="项目" style="width: 215px">
-                    <el-select v-model="search.projectId" placeholder="请选择" clearable @change="getList()" filterable="true" size="mini" style="width: 175px" popper-class="projectSelectPopperClass">
+                <el-form-item :label="$t('other.project')" style="width: 215px">
+                    <el-select v-model="search.projectId" :placeholder="$t('defaultText.pleaseChoose')" clearable @change="getList()" filterable="true" size="mini" style="width: 175px" popper-class="projectSelectPopperClass">
                         <el-option v-for="item in projectList" :key="item.id" :label="item.projectName + item.projectCode" :value="item.id">
                             <span style="float: left;color: #8492a6;">{{ item.projectCode }}</span>
-                            <span style="float: right;font-size: 13px;margin-left: 20px">{{ item.projectName }}</span>
+                            <span style="float: right;font-size: 13px;">{{ item.projectName }}</span>
                         </el-option>
                     </el-select>
                 </el-form-item>
@@ -29,25 +29,25 @@
                 </el-form-item> -->
                 <!-- <div> -->
                     
-                    <el-form-item label="日期">
+                    <el-form-item :label="$t('weekDay.date')">
                         <!-- <el-date-picker v-model="search.date" :editable="false" format="yyyy-MM-dd" value-format="yyyy-MM-dd" 
                         @change="getList()" :clearable="true" type="date" placeholder="选择工作日期"></el-date-picker> -->
                         <el-date-picker
                             v-model="dataTime"
                             type="daterange"
-                            range-separator="至"
-                            start-placeholder="工作开始日期"
-                            end-placeholder="工作结束日期"
+                            :range-separator="$t('other.to')"
+                            :start-placeholder="$t('time.startDate')"
+                            :end-placeholder="$t('time.endDate')"
                             format="yyyy-MM-dd" value-format="yyyy-MM-dd" @change="dataTimes()" size="mini">
                         </el-date-picker>
                     </el-form-item>
 
                     <el-form-item   style="margin-left:20px;">
-                        <el-button @click="batchApprove(true)" style="margin-left:10px;" :loading="batchApproveLoading" :disabled="multipleSelection.length==0" size="mini">批量通过</el-button>
-                        <el-button @click="batchApprove(false)"   :disabled="multipleSelection.length==0" size="mini">批量驳回</el-button>
+                        <el-button @click="batchApprove(true)" style="margin-left:10px;" :loading="batchApproveLoading" :disabled="multipleSelection.length==0" size="mini">{{ $t('Batchthrough') }}</el-button>
+                        <el-button @click="batchApprove(false)"   :disabled="multipleSelection.length==0" size="mini">{{ $t('Batchrejected') }}</el-button>
                     </el-form-item>
                     <el-form-item style="margin-left:20px;">
-                    <el-link type="primary" @click="recordList(),recordDialogVisible = true,pageIndexList = 1,pageSizeList = 20">审核记录</el-link>
+                    <el-link type="primary" @click="recordList(),recordDialogVisible = true,pageIndexList = 1,pageSizeList = 20">{{ $t('Auditrecords') }}</el-link>
                     </el-form-item>
                 <!-- </div> -->
             </el-form>
@@ -61,18 +61,18 @@
                     <el-timeline>
                         <el-timeline-item v-for="(item,index) in props.row.data" :key="index">
                             <el-card shadow="never">
-                                <p>项目:<b>{{item.project}}<span v-if="item.subProjectName != null"> / {{item.subProjectName}}</span>
+                                <p>{{ $t('other.project') + ':' }}<b>{{item.project}}<span v-if="item.subProjectName != null"> / {{item.subProjectName}}</span>
                                 <span style="margin-left:15px;color:#DAA520;" >[ 
                                                 <span v-if="item.isDeptAudit==0">
                                                     <span v-if="item.projectAuditState==0">
-                                                        待项目审核人<span v-if="item.projectAuditorName != null">({{item.projectAuditorName}})</span>审核
+                                                        {{ $t('other.waitForTheProjectReviewer') }}<span v-if="item.projectAuditorName != null">({{item.projectAuditorName}})</span>{{ $t('other.audit') }}
                                                     </span>
                                                     <span style="color:#32CD32;" v-else-if="item.projectAuditState==1">
-                                                        项目审核人<span v-if="item.projectAuditorName != null">({{item.projectAuditorName}})</span>审核通过
+                                                        {{ $t('other.projectAuditor') }}<span v-if="item.projectAuditorName != null">({{item.projectAuditorName}})</span>{{ $t('state.approved') }}
                                                     </span>
                                                 </span>
                                                 <span v-else-if="item.isDeptAudit==1">
-                                                    {{('待'+item.auditDeptName+('('+item.deptAuditorName+')')+'审核')}}
+                                                    {{($t('other.await') +item.auditDeptName+('('+item.deptAuditorName+')')+ $t('other.audit'))}}
                                                 </span>
                                                  ]
                                 </span>
@@ -81,40 +81,39 @@
                                 <p v-if="user.timeType.customDataActive==1">{{user.timeType.customDataName}}:{{item.customData}}</p>
                                 <p v-if="user.timeType.customTextActive==1">{{user.timeType.customTextName}}:{{item.customText}}</p>
                                 <p v-if="user.company.packageEngineering == 1">
-                                    专业进度:
-                                    <span style="margin-right:10px;" v-for="progressItem in item.professionProgressList" :key="progressItem.id">
+                                    {{ $t('other.professionalProgress') +':'}} <span style="margin-right:10px;" v-for="progressItem in item.professionProgressList" :key="progressItem.id">
                                         {{progressItem.professionName}}({{progressItem.progress}}%)
-                                        <el-tooltip v-if="progressItem.auditState == 0"  content="待审核" effect="light" placement="top">
+                                        <el-tooltip v-if="progressItem.auditState == 0"  :content="$t('state.WaitingAudit')" effect="light" placement="top">
                                         <i class="iconfont firerock-icondaibandengdaishenhe"></i>
                                         </el-tooltip>
-                                        <el-tooltip v-if="progressItem.auditState == 1" content="已通过" effect="light" placement="top">
+                                        <el-tooltip v-if="progressItem.auditState == 1" :content="$t('state.alreadyPassed')" effect="light" placement="top">
                                         <i  class="iconfont firerock-iconshenhetongguo"></i>
                                         </el-tooltip>
-                                        <el-tooltip v-if="progressItem.auditState == 2" content="不通过" effect="light" placement="top">
+                                        <el-tooltip v-if="progressItem.auditState == 2" :content="$t('state.notThrough')" effect="light" placement="top">
                                         <i  class="iconfont firerock-iconshenhebohui"></i>
                                         </el-tooltip>
                                         </span>
                                 </p>
-                                <p v-if="item.taskId != null">任务:{{item.taskName}}</p>
+                                <p v-if="item.taskId != null">{{$t('other.task')}}:{{item.taskName}}</p>
                                 <p v-if="item.groupId">
-                                    <span>任务分组:{{item.groupName}}</span>
+                                    <span>{{$t('other.taskGroup')}}:{{item.groupName}}</span>
                                     <!-- 阶段 -->
-                                    <span v-if="item.stage != null" style="margin-left:10px;"> 投入阶段:{{item.stage}}</span>
+                                    <span v-if="item.stage != null" style="margin-left:10px;"> {{$t('other.inputStage')}}:{{item.stage}}</span>
                                 </p>
-                                <p><span v-if="item.multiWorktime==1">项目</span>时长:{{item.time.toFixed(1)}}h <span class="propsbtn" v-if="item.isOvertime === 1">
-                                    <el-tag type="danger" size="mini" style="margin-left: 65px">加班<span v-if="item.overtimeHours">{{item.overtimeHours.toFixed(1)}}小时</span></el-tag></span>
+                                <p><span v-if="item.multiWorktime==1">{{ $t('other.project') }}</span>{{$t('time.duration')}}:{{item.time.toFixed(1)}}h <span class="propsbtn" v-if="item.isOvertime === 1">
+                                    <el-tag type="danger" size="mini" style="margin-left: 65px">{{ $t('other.WorkOvertime') }}<span v-if="item.overtimeHours">{{item.overtimeHours.toFixed(1)}}{{$t('time.hour')}}</span></el-tag></span>
                                 </p>
                                 <div v-if="item.multiWorktime==0">
-                                <p>事项:<span v-html="item.content"></span></p>
+                                <p>{{ $t('other.matters') }}:<span v-html="item.content"></span></p>
                                 </div>
                                 <div v-if="item.multiWorktime==1" >
                                     <div v-for="(timeItem, tIndex) in item.worktimeList" :key="tIndex"
                                         style="border: 0.5px #ddd solid;margin:5px 0px;padding:5px; ">
-                                        <p style="line-height:20px;margin:5px 0px;">时长
+                                        <p style="line-height:20px;margin:5px 0px;">{{$t('time.duration')}}
                                             <span v-if="item.reportTimeType == 2" style="margin-right:10px;">{{timeItem.startTime+'-'+timeItem.endTime}}</span>
                                         {{timeItem.time.toFixed(1)}}h  
                                         </p>
-                                        <p style="line-height:20px;margin:5px 0px;">事项:<span v-html="timeItem.content"></span></p>
+                                        <p style="line-height:20px;margin:5px 0px;">{{ $t('other.matters') }}:<span v-html="timeItem.content"></span></p>
                                     </div>
                                 </div>
 
@@ -132,52 +131,52 @@
                 </template>
             </el-table-column>
             
-            <el-table-column prop="name" label="姓名" sortable></el-table-column>
-            <el-table-column prop="departmentName" label="部门" sortable></el-table-column>
-            <el-table-column prop="dateStr" label="日期" sortable>
+            <el-table-column prop="name" :label="$t('lable.name')" sortable></el-table-column>
+            <el-table-column prop="departmentName" :label="$t('lable.department')" sortable></el-table-column>
+            <el-table-column prop="dateStr" :label="$t('weekDay.date')" sortable>
             </el-table-column>
-            <el-table-column prop="reportTime" label="工作时长(h)" >
+            <el-table-column prop="reportTime" :label="$t('screening.workTime') + '(h)'" >
                 <template slot-scope="scope">
                     {{scope.row.reportTime | amounts}}
                 </template>
             </el-table-column>
-             <el-table-column prop="cardHours" label="考勤时长(h)" v-if="user.timeType.showCorpwxCardtime==1||user.timeType.showDdCardtime==1">
+             <el-table-column prop="cardHours" :label="$t('workAttendance') + '(h)'" v-if="user.timeType.showCorpwxCardtime==1||user.timeType.showDdCardtime==1">
                 <template slot-scope="scope">
                     {{scope.row.cardHours?scope.row.cardHours.toFixed(1):'-'}}
                 </template>
             </el-table-column>
-            <el-table-column prop="state" label="状态" sortable>
+            <el-table-column prop="state" :label="$t('state.states')" sortable>
                 <template slot-scope="scope">
-                    <span v-if="scope.row.state == 0" style="color:#DAA520;">{{scope.row.isDeptAudit==0?'待项目审核人审核':('待'+scope.row.auditDeptName+('('+scope.row.deptAuditorName+')')+'审核')}}</span>
-                    <span v-else-if="scope.row.state == 1" style="color:#32CD32;">已通过</span>
-                    <span v-else-if="scope.row.state == 2" style="color:#FF0000;">已驳回</span>
+                    <span v-if="scope.row.state == 0" style="color:#DAA520;">{{scope.row.isDeptAudit==0?$t('other.Tobereviewedbytheprojectreviewer'):($t('other.await')+scope.row.auditDeptName+('('+scope.row.deptAuditorName+')')+$t('other.audit'))}}</span>
+                    <span v-else-if="scope.row.state == 1" style="color:#32CD32;">{{ $t('state.alreadyPassed') }}</span>
+                    <span v-else-if="scope.row.state == 2" style="color:#FF0000;">{{ $t('state.rejected') }}</span>
                 </template>
             </el-table-column>
-            <el-table-column label="操作" width="220">
+            <el-table-column :label="$t('operation')" width="220">
                 <template slot-scope="scope">
-                    <el-button type="primary" :loading="logining" size="small" @click="approve(scope.row.id,scope.row.date, scope.row)">通过</el-button>
-                    <el-button type="danger" :loading="logining" size="small" @click="showDenyDialog(scope.row.id,0,scope.row.dateStr, scope.row)">驳回</el-button>
+                    <el-button type="primary" :loading="logining" size="small" @click="approve(scope.row.id,scope.row.date, scope.row)">{{ $t('btn.through') }}</el-button>
+                    <el-button type="danger" :loading="logining" size="small" @click="showDenyDialog(scope.row.id,0,scope.row.dateStr, scope.row)">{{ $t('btn.rejected') }}</el-button>
                 </template>
             </el-table-column>
         </el-table>
         <!--驳回弹出框 -->
-        <el-dialog title="请输入原因"  v-if="denyReasonDialog" :visible.sync="denyReasonDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
+        <el-dialog :title="$t('defaultText.pleaseEnterTheReason')"  v-if="denyReasonDialog" :visible.sync="denyReasonDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
             <div>
-                <el-input type="textarea" v-model="denyForm.reason" rows="2" :placeholder="'请输入您决定'+(denyForm.i==0?'驳回':'撤销')+'的原因'" />
+                <el-input type="textarea" v-model="denyForm.reason" rows="2" :placeholder="$t('defaultText.pleaseEnterYourDecision')+(denyForm.i==0?$t('btn.rejected'):$t('btn.undo'))+$t('other.reason')" />
             </div>
             <div slot="footer" class="dialog-footer">
-                <el-button  @click="denyReasonDialog = false" >取消</el-button>
-                <el-button type="primary" @click="deny()" >确定</el-button>
+                <el-button  @click="denyReasonDialog = false" >{{ $t('btn.cancel') }}</el-button>
+                <el-button type="primary" @click="deny()" >{{ $t('btn.determine') }}</el-button>
             </div>
         </el-dialog>
         <!--批量驳回弹出框 -->
-        <el-dialog title="请输入原因"  v-if="batchDenyDialog" :visible.sync="batchDenyDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
+        <el-dialog :title="$t('defaultText.pleaseEnterTheReason')"  v-if="batchDenyDialog" :visible.sync="batchDenyDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
             <div>
-                <el-input type="textarea" v-model="batchDenyData.reason" rows="2" placeholder="请输入您决定驳回的原因" />
+                <el-input type="textarea" v-model="batchDenyData.reason" rows="2" :placeholder="$t('reasonforyourdecisiontoreject')" />
             </div>
             <div slot="footer" class="dialog-footer">
-                <el-button  @click="batchDenyDialog = false" >取消</el-button>
-                <el-button type="primary" @click="batchDenyClick()" :loading="batchDenyLoading">确定</el-button>
+                <el-button  @click="batchDenyDialog = false" >{{ $t('btn.cancel') }}</el-button>
+                <el-button type="primary" @click="batchDenyClick()" :loading="batchDenyLoading">{{ $t('btn.determine') }}</el-button>
             </div>
         </el-dialog>
         <!--工具条-->
@@ -195,14 +194,14 @@
 
         
         <!-- 审核记录弹窗 -->
-        <el-dialog title="审核记录" :visible.sync="recordDialogVisible" width="1000px" :before-close="handleClose">
+        <el-dialog :title="$t('Auditrecords')" :visible.sync="recordDialogVisible" width="1000px" :before-close="handleClose">
             <div style="height: 430px">
                 <el-table :data="recordLists" style="width: 100%" height="400">
-                    <el-table-column prop="userName" label="操作人" width="120"></el-table-column>
+                    <el-table-column prop="userName" :label="$t('other.operator')" width="120"></el-table-column>
                     
-                    <el-table-column prop="indate" label="审核时间"></el-table-column>
-                    <el-table-column prop="result" label="审核结果" width="120" show-overflow-tooltip></el-table-column>
-                    <el-table-column prop="date" label="员工/日期" width="200">
+                    <el-table-column prop="indate" :label="$t('AuditTime')"></el-table-column>
+                    <el-table-column prop="result" :label="$t('Reviewtheresults')" width="120" show-overflow-tooltip></el-table-column>
+                    <el-table-column prop="date" :label="$t('EmployeeDate')" width="200">
                         <template slot-scope="scope">
                             <div>
                                 <div v-if="scope.row.membdateList.length > 1">
@@ -227,15 +226,15 @@
                             </div>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="projectName" label="项目" width="200" show-overflow-tooltip></el-table-column>
-                    <el-table-column prop="date" label="操作" width="100">
+                    <el-table-column prop="projectName" :label="$t('other.project')" width="200" show-overflow-tooltip></el-table-column>
+                    <el-table-column prop="date" :label="$t('operation')" width="100">
                         <template slot-scope="scope">
                             <div>
                                 <template v-if="scope.row.membdateList.length < 2 && scope.row.flg">
-                                    <el-button type="warning" size="mini" v-if="scope.row.membdateList[0].state == 1" @click="undoCli(scope.row, 0)">撤销</el-button>
-                                    <el-link type="info" v-else :underline="false">{{scope.row.membdateList[0].state == 2 ? '已驳回' : '已撤销'}}</el-link>
+                                    <el-button type="warning" size="mini" v-if="scope.row.membdateList[0].state == 1" @click="undoCli(scope.row, 0)">{{ $t('btn.undo') }}</el-button>
+                                    <el-link type="info" v-else :underline="false">{{scope.row.membdateList[0].state == 2 ? $t('state.rejected') : $t('state.undone')}}</el-link>
                                 </template>
-                                <el-button size="mini" v-if="scope.row.membdateList.length >= 2 && scope.row.flg" @click="detailsClick(scope.row, scope.$index)">详情</el-button>
+                                <el-button size="mini" v-if="scope.row.membdateList.length >= 2 && scope.row.flg" @click="detailsClick(scope.row, scope.$index)">{{ $t('details') }}</el-button>
                             </div>
                         </template>
                     </el-table-column>
@@ -254,51 +253,51 @@
             </div>
         </el-dialog>
         <!-- 审核记录撤销 -->
-        <el-dialog title="请输入原因"  v-if="undoFormDialog" :visible.sync="undoFormDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
+        <el-dialog :title="$t('defaultText.pleaseEnterTheReason')"  v-if="undoFormDialog" :visible.sync="undoFormDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
             <div>
-                <el-input type="textarea" v-model="undoForm.reason" rows="2" placeholder="请输入您决定撤销的原因" />
+                <el-input type="textarea" v-model="undoForm.reason" rows="2" :placeholder="$t('yourdecisiontorevoke')" />
             </div>
             <div slot="footer" class="dialog-footer">
-                <el-button  @click="undoFormDialog = false" >取消</el-button>
-                <el-button type="primary" @click="clickCancel()" :loading="undoFormLoading">确定</el-button>
+                <el-button  @click="undoFormDialog = false" >{{ $t('btn.cancel') }}</el-button>
+                <el-button type="primary" @click="clickCancel()" :loading="undoFormLoading">{{ $t('btn.determine') }}</el-button>
             </div>
         </el-dialog>
         <!-- 审核记录详情列表 -->
-        <el-dialog title="审核记录"  v-if="detailsDialog" :visible.sync="detailsDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
+        <el-dialog :title="$t('Auditrecords')"  v-if="detailsDialog" :visible.sync="detailsDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
             <div>
                 <el-table :data="detailsList" style="width: 100%">
-                    <el-table-column prop="userName" label="员工/日期">
+                    <el-table-column prop="userName" :label="$t('EmployeeDate')">
                         <template slot-scope="scope">
                             <div>
                                 {{scope.row.userName}}/{{scope.row.createDate}}
                             </div>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="date" label="操作" width="80">
+                    <el-table-column prop="date" :label="$t('operation')" width="80">
                         <template slot-scope="scope">
                             <div>
-                                <el-button type="warning" size="mini" @click="undoCli(scope.row, 1)" v-if="scope.row.state == 1">撤销</el-button>
+                                <el-button type="warning" size="mini" @click="undoCli(scope.row, 1)" v-if="scope.row.state == 1">{{ $t('btn.undo') }}</el-button>
                                 <!-- <div >{{scope.row.state == 2 ? '已驳回' : '已撤销'}}</div> -->
-                                <el-link type="info" v-else :underline="false">{{scope.row.state == 2 ? '已驳回' : '已撤销'}}</el-link>
+                                <el-link type="info" v-else :underline="false">{{scope.row.state == 2 ? $t('state.rejected') : $t('state.undone')}}</el-link>
                             </div>
                         </template>
                     </el-table-column>
                 </el-table>
             </div>
             <div slot="footer" class="dialog-footer">
-                <el-button  @click="detailsDialog = false" size="mini">取消</el-button>
+                <el-button  @click="detailsDialog = false" size="mini">{{ $t('btn.cancel') }}</el-button>
             </div>
         </el-dialog>
 
         <!-- 审核通过评价 -->
-        <el-dialog title="请输入通过评价" v-if="approveinDialog" :visible.sync="approveinDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
+        <el-dialog :title="$t('enterapassrating')" v-if="approveinDialog" :visible.sync="approveinDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
             <div>
-                <el-input type="textarea" v-model="approveinData.evaluate" rows="2" placeholder="请输入您决定通过的评价" />
+                <el-input type="textarea" v-model="approveinData.evaluate" rows="2" :placeholder="$t('defaultText.Pleaseenterthereviewyoudecidetopass')" />
             </div>
             <div slot="footer" class="dialog-footer">
-                <el-button  @click="approveinDialog = false" >取消</el-button>
-                <el-button type="primary" @click="batchApproveinfun()" v-if="isbatch">确定</el-button>
-                <el-button type="primary" @click="approveinfun()" v-else>确定</el-button>
+                <el-button  @click="approveinDialog = false" >{{ $t('btn.cancel') }}</el-button>
+                <el-button type="primary" @click="batchApproveinfun()" v-if="isbatch">{{ $t('btn.determine') }}</el-button>
+                <el-button type="primary" @click="approveinfun()" v-else>{{ $t('btn.determine') }}</el-button>
             </div>
         </el-dialog>
     </section>
@@ -386,7 +385,7 @@
                     this.undoFormLoading = false
                     if (res.code == "ok") {
                         this.$message({
-                            message: '撤销成功',
+                            message: this.$t('Revocationofsuccess'),
                             type: "success"
                         });
                         this.undoFormDialog = false
@@ -437,7 +436,7 @@
                 res => {
                     if (res.code == "ok") {
                         for (var i in res.data.records) {
-                            res.data.records[i].result.indexOf('通过') == '-1' ? res.data.records[i].flg = false : res.data.records[i].flg = true
+                            res.data.records[i].result.indexOf(this.$t('btn.through')) == '-1' ? res.data.records[i].flg = false : res.data.records[i].flg = true
                         }
                         this.recordLists = res.data.records
                         this.totals = res.data.total
@@ -682,7 +681,7 @@
                     if (res.code == "ok") {
                         this.approveinDialog = false
                         this.$message({
-                            message: "审核成功",
+                            message: this.$t('message.Reviewsucceeded'),
                             type: "success"
                         });
                         this.getList();
@@ -758,7 +757,7 @@
                     this.logining = false;
                     if (res.code == "ok") {
                         this.$message({
-                            message: this.denyForm.i==0?"驳回成功":"撤销成功",
+                            message: this.denyForm.i==0?this.$t('message.rejectedsuccessfully'):this.$t('Revocationofsuccess'),
                             type: "success"
                         });
                         this.getList();

+ 6 - 5
fhKeeper/formulahousekeeper/timesheet_h5/src/views/edit/index.vue

@@ -239,8 +239,8 @@
                         icon="plus" color="#ffffff" ><span style="color:#999;text-align:center;padding: 0 5px;"> 添加工时  </span></van-tag>
                     </div>
                     
-                    <div class="overtime" v-if="((user.timeType.fillOvertime || isWeekend) || (isCorpWX&&canEdit))">
-                        <div class="overTimeClas" v-if="user.timeType.fillOvertime || isWeekend">
+                    <div class="overtime" v-if="((user.timeType.fillOvertime || (isWeekend && user.timeType.lockWorktime != 1)) || (isCorpWX&&canEdit))">
+                        <div class="overTimeClas" v-if="user.timeType.fillOvertime || (isWeekend && user.timeType.lockWorktime != 1)">
                             <van-checkbox :disabled="!item.canEdit" v-model="item.isOvertime" style="width: 4.3rem;">含加班</van-checkbox>
                             <van-field v-model="item.overtimeHours" type="number" :disabled="!item.canEdit || item.isOvertime==null||item.isOvertime==0 || !item.isOvertime"
                             placeholder="请输入加班时长" style="width: 5rem"></van-field>
@@ -323,6 +323,7 @@
 <script src="//res.wx.qq.com/open/js/jweixin-1.2.0.js"></script>
 <script>
     import wx from 'weixin-js-sdk'
+import timetoolVue from '../timetool/timetool.vue';
     // Vue.prototype.$wx = wx
     export default {
         data() {
@@ -518,7 +519,7 @@
                 domainItem.projectAuditorName = null;
                 domainItem.auditUserList = null;
                 //获取项目审核人
-                console.log(domainItem.projectId,this.project);
+                // console.log(domainItem.projectId,this.project);
                 var curProject = this.project.filter(p=>p.id == domainItem.projectId)[0];
                 if (curProject && this.user.timeType.reportAuditType == 0) {
                     this.getProjectAuditorList(domainItem, index);
@@ -1003,7 +1004,7 @@
                                 worktimeList:[{}],  
                                 canEdit: true
                             }]
-                            if(this.isWeekend){
+                            if(this.isWeekend && this.user.timeType.lockWorktime != 1){
                                 this.$set(this.form.domains[0],'isOvertime',true)
                                 if(t.type != 2 && t.type != 0){
                                     this.$set(this.form.domains[0],'overtimeHours',t.allday.toFixed(0))
@@ -1269,7 +1270,7 @@
                     degreeId: null,
                     canEdit: true
                 }
-                if(this.isWeekend){
+                if(this.isWeekend && this.user.timeType.lockWorktime != 1){
                     this.$set(item,'isOvertime',true)
                     if(this.reportTimeType.type == 3){
                         this.$set(item,'overtimeHours',(leftProgress*this.reportTimeType.allday/100).toFixed(1))

+ 2 - 2
fhKeeper/formulahousekeeper/timesheet_h5/src/views/edit/weekEdit.vue

@@ -432,7 +432,7 @@
                     this.currentForm.domains[0].basecostId = this.reportBasecostList[0].id;
                     this.currentForm.domains[0].basecostName = this.reportBasecostList[0].name;
                 }
-                console.log(this.form);
+                // console.log(this.form);
                 this.getKaoqin()
                 this.getWorkTime()
             },
@@ -1166,7 +1166,7 @@
                 // if (!this.canEdit) return;
                 // this.clickIndex = i;
                 // this.showPickerProject = true;
-                console.log(i, item, this.currentForm)
+                // console.log(i, item, this.currentForm)
                 this.proIdx = i
                 this.showPickerUserddp = true
                 // this.$router.push({