考核任务 发布考核 设置任何时候可以修改结束时间

main
wanglei 2 months ago
parent 6d479accd8
commit 4477aebdac

@ -415,7 +415,7 @@
<div>
<el-input-number :disabled="scope.row.vote.id && !(new Date(scope.row.vote.sTime) > (new Date()))" style="width: 120px;margin-right: 10px;"
v-model="scope.row.vote.percentage" :precision="2" :step="0.01" :max="1" controls-position="right"></el-input-number>
<el-switch
<el-switch :disabled="scope.row.vote.id && !(new Date(scope.row.vote.sTime) > (new Date()))"
v-model="scope.row.vote.samePercent" active-text="不一致" inactive-text="一致" active-value="1" inactive-value="0"
v-hasPermi="['kaohe:vote_emp:list']" @change="samePercentChange(scope.row)">
</el-switch>
@ -424,8 +424,8 @@
<div v-for="item in scope.row.vote.voteEmps" :key="item.bkhdxId"
style="margin-bottom: 5px; display: flex; justify-content: space-between;align-items: center">
<span>{{ item.bkhdxName }}</span>
<el-input-number v-model="item.percentage" :precision="2" :step="0.01" :max="1" :controls="false"
style="width: 120px;"></el-input-number>
<el-input-number v-model="item.percentage" :precision="2" :step="0.01" :max="1" :controls="false" style="width: 120px;"
:disabled="scope.row.vote.id && !(new Date(scope.row.vote.sTime) > (new Date()))"></el-input-number>
</div>
</div>
@ -451,8 +451,7 @@
<el-table-column label="结束时间" align="center" prop="vote" min-width="200" :show-overflow-tooltip="true">
<template slot-scope="scope">
<div v-if="scope.$index=== pcSetUp.xzhIndex">
<el-date-picker :disabled="scope.row.vote.id && !(new Date(scope.row.vote.eTime) > (new Date()))"
clearable style="width: 100%;" v-model="scope.row.vote.eTime"
<el-date-picker clearable style="width: 100%;" v-model="scope.row.vote.eTime"
type="datetime" value-format="yyyy-MM-dd HH:mm:ss" placeholder="请选择结束时间">
</el-date-picker>
</div>
@ -1260,10 +1259,21 @@ export default {
Vote.voteItems = '1,2,3,4'
}
if (Vote.id != null && flag ) {
if(Vote.state==='2'){
Vote.state='1';
}
updateVote(Vote).then(response => {
this.$modal.msgSuccess("修改成功")
this.cancelVote()
})
if(this.pcSetUp.row.state==='2'){
//
this.pcSetUp.row.state='1'
updatePingce(this.pcSetUp.row).then(response => {
this.getList()
})
}
} else if(Vote.id === null && flag){
Vote.state = '0';
addVote(Vote).then(response => {

Loading…
Cancel
Save