Ver Fonte

修复明夷超级管理员无法审核日报的问题
提交任务的执行人数量修改

seyason há 1 ano atrás
pai
commit
e2d53cf80a

+ 5 - 0
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/entity/ExpenseItem.java

@@ -106,6 +106,11 @@ public class ExpenseItem extends Model<ExpenseItem> {
     @TableField(exist = false)
     private Integer isIncharger;
 
+    @TableField(exist = false)
+    private String projectManagerId;
+    @TableField(exist = false)
+    private String projectManagerName;
+
     @Override
     protected Serializable pkVal() {
         return this.id;

+ 11 - 0
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/service/impl/ExpenseSheetServiceImpl.java

@@ -448,6 +448,7 @@ public class ExpenseSheetServiceImpl extends ServiceImpl<ExpenseSheetMapper, Exp
         ExpenseSheet expenseSheet = expenseSheetMapper.selectById(id);
         List<ExpenseItem> list = expenseItemMapper.selectList(new QueryWrapper<ExpenseItem>().eq("expense_id", id));
         List<Project> Project = projectMapper.selectList(new QueryWrapper<Project>().eq("company_id", expenseSheet.getCompanyId()));
+        ExpenseAuditSetting expenseAuditSetting = expenseAuditSettingMapper.selectById(expenseSheet.getCompanyId());
         for (ExpenseItem expenseItem : list) {
             for (Project project : Project) {
                 if ((project.getId().equals(expenseItem.getProjectId()))){
@@ -457,6 +458,16 @@ public class ExpenseSheetServiceImpl extends ServiceImpl<ExpenseSheetMapper, Exp
                         expenseItem.setIsIncharger(0);
                     }
                     expenseItem.setProjectName(project.getProjectName());
+                    //获取审核人姓名
+                    if (!(expenseAuditSetting == null || expenseAuditSetting.getAuditType() == 0)) {
+                        expenseItem.setProjectManagerId(project.getInchargerId());
+                        if (project.getInchargerId() != null) {
+                            User user = userMapper.selectById(project.getInchargerId());
+                            if (user != null) {
+                                expenseItem.setProjectManagerName(user.getName());
+                            }
+                        }
+                    }
                     break;
                 }
             }

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

@@ -1811,7 +1811,7 @@ public class ReportServiceImpl extends ServiceImpl<ReportMapper, Report> impleme
                         } else {
                             //第二步,日报审核人审核
                             if (r.getProjectAuditState() == null || r.getProjectAuditState() == 0) {
-                                if (user.getId().equals(r.getProjectAuditorId())) {
+                                if (hasAuditAllPri || user.getId().equals(r.getProjectAuditorId())) {
                                     newReport.setState(1);
                                     newReport.setProjectAuditState(1);
                                     newReport.setProjectAuditTime(LocalDateTime.now());

+ 1 - 1
fhKeeper/formulahousekeeper/management-platform/src/main/resources/application.yml

@@ -15,7 +15,7 @@ spring:
       location: C:/upload/
   datasource:
     driver-class-name: com.mysql.cj.jdbc.Driver
-    url: jdbc:mysql://47.101.180.183:3306/man_hour_manager?useUnicode=true&characterEncoding=utf8&serverTimezone=GMT%2B8&rewriteBatchedStatements=true&useSSL=false
+    url: jdbc:mysql://47.101.180.183:3306/man_mld?useUnicode=true&characterEncoding=utf8&serverTimezone=GMT%2B8&rewriteBatchedStatements=true&useSSL=false
     username: root
     password: HuoshiDB@2022
 #    url: jdbc:mysql://127.0.0.1:3306/man_hour_manager?useUnicode=true&characterEncoding=utf8&serverTimezone=GMT%2B8&rewriteBatchedStatements=true&useSSL=false

+ 2 - 2
fhKeeper/formulahousekeeper/timesheet/src/components/taskComponent.vue

@@ -68,14 +68,14 @@
                 
                 <span style="margin-left:30px;margin-right:10px;">{{ $t('plantime') }}</span>
                 <el-input-number size="small" :disabled="(addForm.id != null && user.id != addForm.createrId && currentProject.inchargerId != user.id) && !permissions.projectManagement && !(groupResponsibleId == user.id)" v-model="gstimday[index]" style="width:16%;" :min="1" :max="100"  :placeholder="$t('danweitian')" @change="chggstim(0,index)"></el-input-number ><span style="margin-left:5px;">{{ $t('time.day') }}</span>
-                <el-input-number size="small" :disabled="(addForm.id != null && user.id != addForm.createrId && currentProject.inchargerId != user.id) && !permissions.projectManagement && !(groupResponsibleId == user.id)" v-model="gstimhour[index]" style="width:16%;" :min="1" :max="100"  :placeholder="$t('pleaseentertheplannedworking')" @change="chggstim(1,index)"></el-input-number ><span style="margin-left:5px;">{{ $t('time.hour') }}</span>
+                <el-input-number size="small" :disabled="(addForm.id != null && user.id != addForm.createrId && currentProject.inchargerId != user.id) && !permissions.projectManagement && !(groupResponsibleId == user.id)" v-model="gstimhour[index]" style="width:16%;" :min="1" :max="999"  :placeholder="$t('pleaseentertheplannedworking')" @change="chggstim(1,index)"></el-input-number ><span style="margin-left:5px;">{{ $t('time.hour') }}</span>
 
                 <!-- <el-input-number v-model="numnnumnum" @change="handleChange" :min="1" :max="10" label="描述文字"></el-input-number> -->
 
                 <!-- 移除执行人 -->
                 <i class="el-icon-delete" v-if="index>0 && (addForm.id == null|| user.id == addForm.createrId || currentProject.inchargerId == user.id|| permissions.projectManagement || groupResponsibleId == user.id)" style="margin-left:5px" @click="removeExecutorLine(index)"></i>
             </el-form-item>
-            <el-link type="primary" v-if="(((addForm.executorListFront == null || addForm.executorListFront.length<10) && 
+            <el-link type="primary" v-if="(((addForm.executorListFront == null || addForm.executorListFront.length<100) && 
             (addForm.id == null|| user.id == addForm.createrId || currentProject.inchargerId == user.id || permissions.projectManagement)) || 
             groupResponsibleId == user.id)" 
             style="margin-left:35px;" @click="addExecutorLine">{{ $t('addinganexecutor') }}</el-link>

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

@@ -370,9 +370,6 @@
                 :label="item.name"
                 :value="item.id"
                 ></el-option>
-                <!-- <el-option :label="$t('yi-ban')" :value="0"></el-option>
-                <el-option :label="$t('cha-lv')" :value="1"></el-option>
-                <el-option :label="$t('wai-bao')" :value="2"></el-option> -->
               </el-select>
             </el-form-item>
             <el-form-item :label="$t('bei-zhu')" style="width: 280px">
@@ -381,11 +378,6 @@
             <el-form-item :label="$t('totalcostos')">
               ¥{{ParticularsList.totalAmount | numberToCurrency}}&nbsp;&nbsp;{{$t('yuan')}}
             </el-form-item>
-
-            <!-- <template slot-scope="scope">
-                <el-input v-model="scope.row.totalAmount" v-if="!flg"></el-input> 元
-                <span v-else>{{scope.row.totalAmount}} 元</span>
-              </template> -->
           </el-form>
           <div style="height:0;position:relative;" v-if="!flg">
             <span class="newInvoice" @click="addNewInvoice"> <i class="el-icon-circle-plus-outline"></i> {{ $t('newinvoice') }}</span>
@@ -398,6 +390,14 @@
                   <span v-if="scope.row.status == 0 || scope.row.status == 3" >{{statusTxt[scope.row.status]}}</span>
                 </template>
             </el-table-column>
+            <el-table-column v-if="auditTypeItem.auditType == 1" width="172" label="审核人">
+              <template slot-scope="scope">
+                <span v-if="user.userNameNeedTranslate == 1">
+                    <ww-open-data type='userName' :openid='scope.row.projectManagerName'></ww-open-data>
+                </span>
+                <span v-else>{{ scope.row.projectManagerName}}</span>
+              </template>
+            </el-table-column>
             <el-table-column prop="projectId" :label="$t('other.project')" width="155">
                 <template slot-scope="scope">
                   <el-select size="small" v-if="!flg" v-model="scope.row.projectId" :placeholder="$t('other.project')" style="width: 130px">

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

@@ -326,10 +326,10 @@
         <!-- 设置研究中心 -->
         <div class="yanjiu">
             <p style="margin-left:10px;color:#666;">{{ $t('dailyfilling') }}</p>
-            <el-switch style="margin-left: 40px" v-model="timeType.customDegreeActive" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 40px" v-model="timeType.customDegreeActive" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('afteritisenabled') }}</span>
             <template v-if="timeType.customDegreeActive">
-            <el-switch style="margin-left: 40px" v-model="timeType.customDegreeStatus" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 40px" v-model="timeType.customDegreeStatus" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('parametermandatory') }}</span>
             </template>
         </div>
@@ -350,10 +350,10 @@
         <!-- 设置数值填报 -->
         <div class="yanjiu" v-if="user.company.packageProject==1">
             <p style="margin-left:10px;color:#666;"><span>{{ $t('dailyfillingvalue') }}</span></p>
-            <el-switch style="margin-left: 40px" v-model="timeType.customDataActive" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 40px" v-model="timeType.customDataActive" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('afterthisunctionisenabled') }}</span>
             <template v-if="timeType.customDataActive">
-            <el-switch style="margin-left: 40px" v-model="timeType.customDataStatus" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 40px" v-model="timeType.customDataStatus" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('parametermandatory') }}</span>
             </template>
         </div>
@@ -365,7 +365,7 @@
                             <el-input :placeholder="$t('peaseenterthe')" maxlength="5" size="small" v-model="timeType.customDataName" clearable> </el-input>
                         </el-form-item>
                         <el-form-item :label="$t('maximumvaluelimit') " style="margin-left:10px;">
-                            <el-switch v-model="timeType.customDataMaxStatus" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+                            <el-switch v-model="timeType.customDataMaxStatus" active-color="#20a0ff" > </el-switch>
                         </el-form-item>
                         <el-form-item :label="$t('maximum') " style="margin-left:10px;" v-if="timeType.customDataMaxStatus">
                             <el-input-number v-model="timeType.customDataMaxValue"></el-input-number>
@@ -378,10 +378,10 @@
         <!-- 设置数值填报 -->
         <div class="yanjiu" >
             <p style="margin-left:10px;color:#666;"><span>{{ $t('fillingtext') }}</span></p>
-            <el-switch style="margin-left: 40px" v-model="timeType.customTextActive" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 40px" v-model="timeType.customTextActive" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('additionalinformation') }}</span>
             <template v-if="timeType.customTextActive">
-            <el-switch style="margin-left: 40px" v-model="timeType.customTextStatus" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 40px" v-model="timeType.customTextStatus" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('parametermandatory') }}</span>
             </template>
         </div>
@@ -398,13 +398,13 @@
         </el-row>
         <div class="yanjiu">
             <span style="margin-left:10px;color:#666;">{{user.companyId==781?$t('other.specificcontentandresults'):$t('other.workMatters')}}</span>
-            <el-switch :style="user.companyId==781?'margin-left:66px;':'margin-left:108px;'" v-model="timeType.workContentState" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch :style="user.companyId==781?'margin-left:66px;':'margin-left:108px;'" v-model="timeType.workContentState" active-color="#20a0ff" > </el-switch>
             <span style="margin-left:10px;color:#999;">{{ $t('parametermandatory') }}</span>
         </div>
         <!-- 是否开启导入审核 -->
         <div class="yanjiu">
             <p style="margin-left:10px;color:#666;">{{ $t('importauditing') }}</p>
-            <el-switch style="margin-left: 55px" v-model="timeType.needDeptAudit" active-color="#13ce66" inactive-color="#ff4949"> </el-switch>
+            <el-switch style="margin-left: 55px" v-model="timeType.needDeptAudit" active-color="#20a0ff" > </el-switch>
             <span v-if="timeType.needDeptAudit == 1" style="margin-left:10px;color:#999;">{{ $t('eachdepartment') }}</span>
         </div>
 

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

@@ -70,7 +70,7 @@
                                         </span>
                                         <span v-if="data.isUser == 1 && data.state == null && (data.leaveDays || data.leaveTimes)" :style="(data.leaveDays < 1 || data.leaveTimes < user.timeType.allday) ? 'color:red;font-size:13px' : 'color:#32cd32;font-size:13px'">
                                         <!-- {{data.leaveDays ? (data.leaveDays >= 1 ? '当日请假' : '未填报(请假' + data.leaveDays + '天)') : (data.leaveTimes >= user.timeType.allday ? '当日请假' : '未填报(请假' + data.leaveTimes + 'h)')}} -->
-                                        {{data.leaveDays ? (data.leaveDays >= 1 ? $t('other.AskForLeaveOnTheSameDay') : $t('state.DidNotFillIn') + '('+$t('other.AskForLeave') + data.leaveDays + $t('time.day')+')') : (data.leaveTimes >= user.timeType.allday ? $t('other.AskForLeaveOnTheSameDay') : $t('state.DidNotFillIn') + '('+$t('other.AskForLeave') + data.leaveTimes + 'h)')}}
+                                        {{data.leaveDays ? (data.leaveDays >= 1 ? $t('other.AskForLeaveOnTheSameDay') : $t('state.DidNotFillIn') + '('+$t('other.AskForLeave') + data.leaveDays.toFixed(1) + $t('time.day')+')') : (data.leaveTimes >= user.timeType.allday ? $t('other.AskForLeaveOnTheSameDay') : $t('state.DidNotFillIn') + '('+$t('other.AskForLeave') + data.leaveTimes + 'h)')}}
                                         </span>
                                         <span v-if="data.isUser == 1 && data.state == 0" style="color:orange;font-size:13px">
                                         <!-- 待审核 -->
@@ -559,8 +559,8 @@
                         </el-form-item>
                         <el-form-item v-if="reportTimeType.type == 3" :label="$t('lable.percentageOfTime')" :prop="'domains.' + index + '.'+timeFields[reportTimeType.type]"
                             :rules="{ required: true, message: $t('defaultText.pleaseSetTheTimeRatio'), trigger: 'blur' }">
-                            <div style="width:300px;">
-                                <el-col span="14"><el-slider :disabled="!domain.canEdit" v-model="domain.progress" :min="5" :show-tooltip="false" :step="5" style="width:180px;" @input="domain.workingTime = (reportTimeType.allday*domain.progress/100).toFixed(1)" @change="seleChn(0)"></el-slider></el-col>
+                            <div style="width:400px;">
+                                <el-col span="14"><el-slider :disabled="!domain.canEdit" v-model="domain.progress" :min="5" :show-tooltip="false" :step="5" style="width:280px;" @input="domain.workingTime = (reportTimeType.allday*domain.progress/100).toFixed(1)" @change="seleChn(0)" show-input="true" input-size="small"></el-slider></el-col>
                                 <el-col :span="isBatch?6:10"><span style="margin-left:10px;float:right;"><span style="margin-right:10px;">{{domain.progress}}%</span><span v-if="isBatch == 0">{{domain.workingTime}}{{$t('time.hour')}}</span></span></el-col>
                             </div>
                             <div class="overtime" v-if="user.timeType.fillOvertime || isWeekend"><el-checkbox :disabled="!domain.canEdit" v-model="domain.isOvertime">{{$t('other.WorkOvertime')}}</el-checkbox>
@@ -1020,8 +1020,8 @@
                 </div>
                 <div class="zhoFel" v-if="reportTimeType.type == 3">
                     <p>{{$t('lable.percentageOfTime')}}</p>
-                    <div style="width:355px;display: flex;align-items: center;">
-                        <el-col span="23"><el-slider style="margin-left: 5px;width:249px;" v-model="zhoBao.progress" :min="0" :show-tooltip="false" :step="10" @input="zhoBao.workingTime = (reportTimeType.allday*zhoBao.progress/100).toFixed(1)"></el-slider></el-col>
+                    <div style="width:400px;display: flex;align-items: center;">
+                        <el-col span="23"><el-slider style="margin-left: 5px;width:299px;" v-model="zhoBao.progress" :min="0" :show-tooltip="false" :step="10" @input="zhoBao.workingTime = (reportTimeType.allday*zhoBao.progress/100).toFixed(1)" show-input="true" input-size="small"></el-slider></el-col>
                         <el-col span="10"><span style="float:right;"><span style="margin-right:10px;">{{zhoBao.progress || 0}}%</span>{{zhoBao.workingTime | amounts}}{{$t('time.hour')}}</span></el-col>
                     </div>
                 </div>
@@ -1107,7 +1107,7 @@
                                 <span v-if="scope.row.leaveDays || scope.row.leaveTimes">
                                     <span v-if="user.userNameNeedTranslate != '1'">{{scope.row.label}}</span>
                                     <span v-if="user.userNameNeedTranslate == '1'"><ww-open-data type='userName' :openid='scope.row.label'></ww-open-data></span>
-                                    <span>{{scope.row.leaveDays ? '(' + $t('other.AskForLeave') +scope.row.leaveDays + $t('time.day') +')' : '(' + $t('other.AskForLeave') + scope.row.leaveTimes + 'h)'}}</span>
+                                    <span>{{scope.row.leaveDays ? '(' + $t('other.AskForLeave') +scope.row.leaveDays.toFixed(1) + $t('time.day') +')' : '(' + $t('other.AskForLeave') + scope.row.leaveTimes + 'h)'}}</span>
                                 </span>
                                 <span v-else>
                                     <span v-if="user.userNameNeedTranslate != '1'">{{scope.row.label}}</span>
@@ -1135,7 +1135,7 @@
                             <span v-if="scope.row.leaveDays || scope.row.leaveTimes">
                                 <span v-if="user.userNameNeedTranslate != '1'">{{scope.row.label}}</span>
                                 <span v-if="user.userNameNeedTranslate == '1'"><ww-open-data type='userName' :openid='scope.row.label'></ww-open-data></span>
-                                <span>{{scope.row.leaveDays ? '(' + leaveTypeName[scope.row.leaveType] + ')' : '(' + leaveTypeName[scope.row.leaveType] + ')'}}</span>
+                                <span>{{scope.row.leaveDays.toFixed(1) ? '(' + leaveTypeName[scope.row.leaveType] + ')' : '(' + leaveTypeName[scope.row.leaveType] + ')'}}</span>
                             </span>
                             <span v-else>
                                 <span v-if="user.userNameNeedTranslate != '1'">{{scope.row.label}}</span>

+ 7 - 1
fhKeeper/formulahousekeeper/timesheet_h5/src/views/expense/details.vue

@@ -178,7 +178,13 @@
                                     statusList[item.status] }}</span>
                         </template>
                     </van-field>
-
+                    <van-field
+                        label="审核人" v-if="item.projectManagerName">
+                        <template #input>
+                            <span v-if="user.userNameNeedTranslate == 1"><ww-open-data type='userName' :openid='item.projectManagerName'></ww-open-data></span>
+                            <span v-else>{{item.projectManagerName}}</span>
+                        </template>
+                    </van-field>
                     <van-field
                         label="操作" v-if="isAudit && item.isIncharger && item.status == 1"
                     >