From 5104054c6c7a28c3d97a66c1e614897a6db28ba0 Mon Sep 17 00:00:00 2001 From: value <z1292839451@163.com> Date: 星期六, 08 六月 2024 17:39:36 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- src/components/do/b3-work-time-management/work-time-management.vue | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++---- 1 files changed, 51 insertions(+), 4 deletions(-) diff --git a/src/components/do/b3-work-time-management/work-time-management.vue b/src/components/do/b3-work-time-management/work-time-management.vue index 86d3e07..1ebdf62 100644 --- a/src/components/do/b3-work-time-management/work-time-management.vue +++ b/src/components/do/b3-work-time-management/work-time-management.vue @@ -63,10 +63,12 @@ </el-radio-group> <div style="display: flex;align-items: center;"> <p style="font-size: 14px;margin-right: 30px;"> - 鎬诲伐鏃舵眹鎬伙細<span style="font-size: 16px;color: #3A7BFA;">{{ (totalInfo['浜ч噺宸ユ椂姹囨��']+totalInfo['杈呭姪宸ユ椂姹囨��'])? (totalInfo['浜ч噺宸ユ椂姹囨��']+totalInfo['杈呭姪宸ユ椂姹囨��']):0 }}</span> 浜ч噺宸ユ椂姹囨�伙細<span style="font-size: 16px;color: #3A7BFA;">{{totalInfo['浜ч噺宸ユ椂姹囨��']?totalInfo['浜ч噺宸ユ椂姹囨��']:0}}</span> 杈呭姪宸ユ椂姹囨�伙細<span style="font-size: 16px;color: #3A7BFA;">{{totalInfo['杈呭姪宸ユ椂姹囨��']?totalInfo['杈呭姪宸ユ椂姹囨��']:0}}</span> + 鎬诲伐鏃舵眹鎬伙細<span style="font-size: 16px;color: #3A7BFA;" v-if="totalInfo">{{ (totalInfo['浜ч噺宸ユ椂姹囨��']+totalInfo['杈呭姪宸ユ椂姹囨��'])? (totalInfo['浜ч噺宸ユ椂姹囨��']+totalInfo['杈呭姪宸ユ椂姹囨��']):0 }}</span> 浜ч噺宸ユ椂姹囨�伙細<span style="font-size: 16px;color: #3A7BFA;" v-if="totalInfo">{{totalInfo['浜ч噺宸ユ椂姹囨��']?totalInfo['浜ч噺宸ユ椂姹囨��']:0}}</span> 杈呭姪宸ユ椂姹囨�伙細<span style="font-size: 16px;color: #3A7BFA;" v-if="totalInfo">{{totalInfo['杈呭姪宸ユ椂姹囨��']?totalInfo['杈呭姪宸ユ椂姹囨��']:0}}</span> </p> - <el-button size="small" type="primary" style="margin-right: 16px;" @click="openAdd" v-show="currentTable == 'ValueTable0'">褰曞叆鏁版嵁</el-button> - <el-button size="small" type="primary" @click="handleOut" :loading="outLoading">瀵� 鍑�</el-button> + <el-button size="small" type="primary" style="margin-right: 16px;" @click="openAdd" v-show="currentTable == 'ValueTable0'&&add">褰曞叆鏁版嵁</el-button> + <el-button size="small" type="primary" + v-if="down" + @click="handleOut" :loading="outLoading">瀵� 鍑�</el-button> </div> </div> <div class="table"> @@ -216,6 +218,8 @@ data () { return{ entity:{}, + down:false, + add:false, componentData: { entity: { week: null, @@ -394,7 +398,7 @@ label:'宸叉壒鍑�' }, ], - totalInfo:{}, + totalInfo:null, auxiliaryWorking:null, outLoading:false } @@ -461,6 +465,49 @@ this.componentData.selectField.weekDay.select = this.weekList }, methods:{ + getPower(){ + let power = JSON.parse(sessionStorage.getItem('power')) + let del = false + let down = false + let add = false + let up = false + let check = false + let ratify = false + for (var i = 0; i < power.length; i++) { + if (power[i].menuMethod == 'exportWorkingHours') { + down = true + } + if (power[i].menuMethod == 'deleteAuxiliaryWorkingHoursDay') { + del = true + } + if (power[i].menuMethod == 'insertAuxiliaryWorkingHoursDay') { + add = true + } + if (power[i].menuMethod == 'updateAuxiliaryWorkingHoursDay') { + up = true + } + if (power[i].menuMethod == 'check') { + check = true + } + if (power[i].menuMethod == 'approve') { + ratify = true + } + } + if (!approve) { + this.componentData.do.splice(3, 1) + } + if (!check) { + this.componentData.do.splice(2, 1) + } + if (!up) { + this.componentData.do.splice(1, 1) + } + if (!del) { + this.componentData.do.splice(0, 1) + } + this.down = down + this.add = add + }, getYearAndMonthAndDays(date){ return getYearAndMonthAndDays(date) }, -- Gitblit v1.9.3