任务完成状态

master
lion 1 year ago
parent 9b6ff52f2d
commit 856eb365d8

@ -223,7 +223,7 @@
<template v-slot:btns>
<el-table-column align='center'label="操作" width="120" header-align="center">
<template slot-scope="scope">
<div v-if="scope.row.carry_status===1 && showform.main_admin_id===stateObj.login_id">
<div v-if="scope.row.carry_status==1 && showform.main_admin_id==stateObj.login_id">
<Button v-if="scope.row.keep_status===1" @click="startLoad(scope.row,'check')" type="primary" size="small"
>审核进展</Button>
</div>
@ -282,21 +282,21 @@
<el-table-column align='center'label="操作" width="120" header-align="center">
<template slot-scope="scope">
<div v-if="scope.row.carry_status===0">
<Button @click="startLoad(scope.row,'add')" type="primary" size="small"
<Button style="margin-bottom: 5px;" @click="startLoad(scope.row,'add')" type="primary" size="small"
>开始任务</Button>
</div>
<div v-else-if="scope.row.carry_status===1">
<Button v-if="scope.row.carry_type===0" @click="openMyMission" type="primary" size="small"
<Button style="margin-bottom: 5px;" v-if="scope.row.carry_type===0" @click="openMyMission" type="primary" size="small"
>任务执行</Button>
<Button v-if="scope.row.carry_type===1 && scope.row.admin_type==1" @click="editorUnit('pid')" type="primary" size="small"
<Button style="margin-bottom: 5px;" v-if="scope.row.carry_type===1 && scope.row.admin_type==1" @click="editorUnit('pid')" type="primary" size="small"
>任务分解</Button>
<Button v-if="scope.row.carry_type===2 && scope.row.admin_type==1" @click="editorUnit('send')" type="primary" size="small"
<Button style="margin-bottom: 5px;" v-if="scope.row.carry_type===2 && scope.row.admin_type==1" @click="editorUnit('send')" type="primary" size="small"
>任务转办</Button>
<Button v-if="scope.row.keep_status===-1" @click="startLoad(scope.row,'editor')" type="primary" size="small"
<Button style="margin-bottom: 5px;" v-if="scope.row.keep_status===-1" @click="startLoad(scope.row,'editor')" type="primary" size="small"
>提交进展</Button>
<Button v-if="scope.row.keep_status===0 || scope.row.keep_status===3 " @click="startLoad(scope.row,'editor')" type="primary" size="small"
<Button style="margin-bottom: 5px;" v-if="scope.row.keep_status===0 || scope.row.keep_status===3 " @click="startLoad(scope.row,'editor')" type="primary" size="small"
>编辑进展</Button>
</div>
<div v-else></div>
@ -451,7 +451,7 @@
</template>
</xy-dialog>
<openLoad ref="openLoad" @refresh="carryTypeWhat" @reload="getDetail"></openLoad>
<openLoad ref="openLoad" @refresh="carryTypeWhat" @reload="getDetail" @reloadList="reloadList"></openLoad>
<addUnit ref="addUnit" @refresh="carryFinish"></addUnit>
<!-- <checkUnit ref="checkUnit"></checkUnit> -->
<showLogs ref="showLogs"></showLogs>
@ -1173,9 +1173,12 @@
this.$refs.openLoad.pid = this.showform.pid
this.$refs.openLoad.type = type
this.$refs.openLoad.setForm(row,this.showform.start_date,this.showform.end_date)
this.$refs.openLoad.id = this.id
this.$refs.openLoad.isShow = true
},
reloadList(){
this.$emit("refresh")
},
//
carryTypeWhat(e){
console.log("carryTypeWhat",e)
@ -1219,9 +1222,9 @@
//
openMyMission(remark, e) {
switch (this.is_what_unitType) {
case '检查':
this.addPatrol(e)
break;
// case '':
// this.addPatrol(e)
// break;
case '学习':
this.type = 'study'
break;
@ -1234,6 +1237,7 @@
case '资料收集':
case '方案':
case '会议':
case '检查':
this.type = 'uploads'
break;
}

@ -58,6 +58,20 @@
</div>
</div>
</template>
<template v-slot:finish_status v-if="type=='editor'">
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;">*</span>完成情况
</div>
<div class="xy-table-item-content">
<el-select v-model="formObj.finish_status" style="width: 400px;"
placeholder="请选择">
<el-option v-for="item in finish_status_list" :key="item.id" :label="item.value" :value="item.id">
</el-option>
</el-select>
</div>
</div>
</template>
<template v-slot:file_ids v-if="type=='editor'">
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
@ -127,6 +141,9 @@
import {
deepCopy
} from "@/utils/index.js"
import {
updatemission
} from "@/api/task/unit.js";
export default {
components: {
@ -174,10 +191,18 @@
start_date: '',
end_date: '',
ing_introduce: '',
finish_status:'',
file_ids: [],
end_introduce: '',
check_status: ''
},
finish_status_list:[{
id:1,
value:'已完成'
},{
id:2,
value:'已列计划'
}],
rules: {
// carry_type: [{
// required: true,
@ -252,6 +277,10 @@
this.formObj.keep_status = 0
}
if (this.type == 'editor') {
if(!this.formObj.finish_status){
this.$Message.warning('请选择完成情况')
return
}
this.formObj.keep_status = keep_status ? keep_status : 0
}
if (this.type == 'check') {
@ -288,6 +317,13 @@
this.$emit('refresh', 'carry_type2')
}
}
if (this.type == 'check') {
updatemission({
id: this.id
}).then(r => {
this.$emit('reloadList')
})
}
this.$emit('reload')
this.isShow = false

@ -626,7 +626,7 @@
if(this.path_type == 5){
const newArr = res.data.filter((_, index) => !spliceIndex.includes(index));
newArr.map(item=>{
if(item.audit_status==5){
if(item.audit_status==5 || item.audit_status==3){
console.log("item.mission_finished",item.id,item.mission_finished)
my_arr.push(item)
}else{

Loading…
Cancel
Save