任务清单增加催办功能

This commit is contained in:
zyx.net
2022-11-02 10:08:41 +08:00
parent 68170c14bc
commit c145f18ad1
4 changed files with 208 additions and 4 deletions
+1
View File
@@ -1359,4 +1359,5 @@ module.exports = {
Topping:'Topping',
cancelTopping:'Cancel Topping',
relatedProjectVersion:'Related project version',
CuiBan:'CuiBan',
}
+1
View File
@@ -1460,4 +1460,5 @@ module.exports = {
Topping:'置顶',
cancelTopping:'取消置顶',
relatedProjectVersion:'相关项目版本',
CuiBan:'催办',
}
@@ -76,10 +76,10 @@
</a-form>
</div>
<div class="table-operator">
<!-- <div class="operator-text" @click="batSettingClick">-->
<!-- <a-icon type="setting"/>-->
<!-- {{ $t('batSetting') }}-->
<!-- </div>-->
<div class="operator-text" @click="cuibanClick">
<a-icon type="sound"/>
{{ $t('CuiBan') }}
</div>
<div @click="BatchMaintenanceProgress" class="operator-text">
<a-icon type="setting"/>
{{$t('BatchMaintenanceProgress')}}
@@ -190,6 +190,7 @@
<taskBatSetting @taskBatSettingForm="taskBatSettingForm" ref="taskBatSettingRef"></taskBatSetting>
<batchChangeModel @batchChangeModel="batchChangeModel" ref="batchChangeModelRef"/>
<batchModel @batchModel="batchModel" ref="batchModelRef"/>
<cuibanModel @cibanModel="cibanModel" ref="cModelRef"/>
<!-- 错误数据提示-->
<a-modal
:title="$t('operationFailed')"
@@ -222,6 +223,7 @@
import batchModel from './batchModel'
import TaskListModel from './TaskListModel'
import taskBatSetting from './taskBatSetting'
import cuibanModel from './cuibanModel'
import { getAction, postAction, deleteAction, downloadFile } from '@/api/manage'
import { mapGetters } from 'vuex'
import store from '@/store/'
@@ -233,6 +235,7 @@
TaskListModel,
batchChangeModel,
batchModel,
cuibanModel,
taskBatSetting
},
props: ['isDisplayNum', 'areaOfResponsibility'],
@@ -536,6 +539,17 @@
let item = JSON.parse(JSON.stringify(val))
this.$refs.TaskListModelRef.getData(item, this.$t('CurrentStatus'))
},
// 催办
cuibanClick(){
if(this.selectionRowsArray.length <1){
this.$message.warning(this.$t('selectLeastOne'))
}else{
this.$refs.cModelRef.getData(this.selectionRowsArray)
}
},
cibanModel(){
this.getList()
},
//批量维护进度
BatchMaintenanceProgress() {
@@ -0,0 +1,188 @@
<!--催办-->
<template>
<a-modal
:title="title"
:width="700"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="visible = false"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CertificationProgress')">{{$t('CertificationProgress')}}</span>
</div>
<!-- mode="multiple"-->
<a-form-model-item class="itemModel" prop="type">
<a-select v-model="formInline.type"
class='box-input'
:getPopupContainer="triggerNode=> triggerNode.parentNode"
allowClear>
<a-select-option v-for="(item, key) in cuibanList" :key="key" :value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.label ">
{{ item.label }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { postAction, putAction, getAction } from '@/api/manage'
export default {
name: 'TaskListModel',
data() {
return {
formInline: {},
selectionRowsArray:[],
rules: {
type: [
{
required: true,
message: this.$t('PleaseSelect') + this.$t('CertificationProgress'),
trigger: 'change'
}
]
},
title:'',
visible: false,
confirmLoading: false,
studioList: [],
cuibanList:[
{ label: this.$t('confirmationOfDesignConformity'), value: '2' },
{ label: this.$t('PrehomoConfirmation'), value: '3' },
{ label: this.$t('verificationAndConformityconfirmation'), value: '4' },
],
ids:'',
disabled: false,
url: {
edit: '/project/projectTaskInventoryEO/edit',
addOrUpdate: '/project/projectTaskInventoryConditionAssessmentEO/addOrUpdate',
list: '/project/projectTaskInventoryConditionAssessmentEO/list'
}
}
},
mounted() {
},
methods: {
getData(val) {
this.visible = true
this.title = this.$t('CuiBan')
this.selectionRowsArray = val
this.$nextTick(() => {
this.formInline = {}
this.$refs.ruleForm.clearValidate()
})
},
getList(val) {
getAction(this.url.list, { projectLawsInventoryId: val.projectLawsInventoryId }).then((res) => {
if (res.success) {
this.studioList = res.result || []
} else {
this.studioList = []
}
})
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
handleOk() {
if (this.disabled) {
this.visible = false
return
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let ProjectTaskUrgVo = {}
let projectLawsInventoryId = []
this.selectionRowsArray.forEach((item) => {
if(item.projectLawsInventoryId){
projectLawsInventoryId.push(item.projectLawsInventoryId)
}
})
ProjectTaskUrgVo = {
projectLawsInventoryIds: projectLawsInventoryId.join(','),
type: this.formInline.type
}
this.confirmLoading = true
postAction('/project/projectLawsInventoryEO/taskUrg', ProjectTaskUrgVo).then((res) => {
if (res.success) {
this.visible = false
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('cibanModel')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text {
width: 134px;
text-align: right;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: 42px;
line-height: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.headerText {
margin-left: 30px;
color: #040B29;
font-weight: 400;
}
</style>