企标制修订计划管控

This commit is contained in:
宋伟佳
2021-12-15 16:22:34 +08:00
parent efc1f349b5
commit 2a238bfd91
7 changed files with 144 additions and 160 deletions
@@ -97,7 +97,7 @@
</el-date-picker>
</el-form-item>
<el-form-item label="起草责任单位" prop="unit" class="add-form-item form-item-disabled">
<div v-if="qbfsForm.unit.length > 0">
<div v-if="qbfsForm.unit">
<el-tooltip class="item" effect="dark" :content="qbfsForm.unit" placement="top-start">
<el-input
readonly
@@ -306,6 +306,12 @@ export default {
}
}
},
mounted(){
console.log(this.qbfsForm);
if(!this.qbfsForm.passFlag){
this.qbfsForm = {}
}
},
methods: {
validateForm () {
let flag = null
@@ -105,7 +105,7 @@
</el-date-picker>
</el-form-item>
<el-form-item label="起草责任单位" prop="unit" class="add-form-item form-item-disabled">
<div v-if="qbfsForm.unit.length > 0">
<div v-if="qbfsForm.unit">
<el-tooltip class="item" effect="dark" :content="qbfsForm.unit" placement="top-start">
<el-input
readonly
@@ -328,6 +328,11 @@ export default {
}
}
},
mounted(){
if(!this.qbfsForm.passFlag){
this.qbfsForm = {}
}
},
methods: {
validateForm () {
let flag = null
@@ -64,32 +64,11 @@
placeholder="请选择计划标准发布时间">
</el-date-picker>
</el-form-item>
<!-- <el-form-item label="起草责任单位" style="width: 100%; margin-right:10px" class="add-form-item" prop="unit" >-->
<!-- <div style="display: flex;justify-content: space-between;align-items: center;">-->
<!-- <el-input-->
<!-- clearable-->
<!-- v-model="qbfsForm.unit"-->
<!-- placeholder="选择或输入起草单位">-->
<!-- </el-input>-->
<!-- <div>-->
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="primary"-->
<!-- @click="QCDWClick"-->
<!-- class="common-button-primary">手动查找</el-button>-->
<!-- </div>-->
<!-- </div>-->
<!-- </el-form-item>-->
<el-form-item label="起草责任单位" style="width: 100%; margin-right:10px" prop="unit" class="add-form-item form-item-disabled">
<el-select v-model="qbfsForm.unit" filterable multiple clearable>
<el-option
v-for="item in qcdwOptions"
placeholder="请选择起草责任单位"
:key="item.value"
:value="item.label"
:label="item.label"
></el-option>
</el-select>
<el-input v-model="qbfsForm.unitId" style="display: none;"></el-input>
<el-input v-model="qbfsForm.unit" placeholder="请选择起草责任单位"
@click.native="choiceZRBM('unit', '选择起草责任单位', qbfsForm.unitId)">
</el-input>
</el-form-item>
<el-form-item label="新增原因" style="width: 100%; margin-right:10px" prop="newReason" class="add-form-item form-item-disabled">
<el-input
@@ -119,45 +98,30 @@
@checkedRole="checkedRole"
:nodeList="nodeList"
></Role-tree>
<el-dialog
:visible.sync="QCDWmodal"
width="500px"
title="选择起草部门"
destroy-on-close
:close-on-click-modal="false"
@closed="QCDWmodal = false">
<el-select v-model="QCDWValue" multiple filterable placeholder="请选择" style="width: 100%;">
<el-option
v-for="item in qcdwOptions"
:key="item.value"
:label="item.label"
:value="item.label">
</el-option>
</el-select>
<div slot="footer" class="demo-drawer-footer">
<el-button size="mini" type="primary" class="common-button-default" icon="el-icon-check"
@click="QCDWOK">确认
</el-button>
</div>
</el-dialog>
<Mechanism-tree
is-title="选择起草责任单位"
:is-visible.sync="modalshowflagZRBM"
:nodeList="nodeListZRBM"
@checkedRole="drawerCheckZRBM"
/>
</div>
</template>
<script>
import ProcessTitle from "process/components/ProcessTitle";
import MechanismTree from '@/components/mechanismTree'
export default {
name: "establish",
components: {
ProcessTitle
ProcessTitle,
MechanismTree
},
props: ['message'],
data(){
return {
QCDWmodal: false,
QCDWValue: [],
QCDWList: [],
modalshowflagZRBM: false,
nodeListZRBM: [],
drawerTitle2: '',
drawerTitle: '',
roleType: '',
@@ -169,6 +133,7 @@ export default {
qbfsForm: {
type: '5',
unit: '', // 单位
unitId: '',
esName: '', // 企标名称
planStatus: '', // 计划状态
reviseStatus: '', // 制修订状态
@@ -224,10 +189,13 @@ export default {
deep: true,
handler(val) {
this.qbfsForm = val
}
}
},
},
},
mounted(){
if(!this.qbfsForm.passFlag){
this.qbfsForm = {}
}
//查询下拉框数据
this.$http.get('sys/dictype/getDicTypeListCode', '',{
_this: this
@@ -237,19 +205,28 @@ export default {
})
},
methods: {
QCDWOK () {
let arr1 = []
if (this.qbfsForm.unit.length > 0) {
let str = this.qbfsForm.unit.replace(//g, ',')
arr1 = str.split(',')
}
let arr2 = arr1.concat(this.QCDWValue)
this.qbfsForm.unit = Array.from(new Set(arr2)).join(',')
this.QCDWmodal = false
choiceZRBM(type, title, id) {
this.nodeListZRBM = []
this.nodeListZRBM.push(id)
this.drawerTitle = title
this.modalshowflagZRBM = true
},
QCDWClick () {
this.QCDWValue = []
this.QCDWmodal = true
drawerCheckZRBM(data) {
let idList = ''
let nameList = ''
data.forEach(item => {
if (nameList.length) {
nameList += ','
idList += ','
}
idList += item.id
nameList += item.name
})
this.$set(this.qbfsForm, 'unitId', idList)
this.$set(this.qbfsForm, 'unit', nameList)
if(this.qbfsForm.unit){
this.$refs.qbfsForm.validateField('unit')
}
},
choiceZRR() {
this.nodeList = [];
@@ -82,32 +82,20 @@
</el-date-picker>
</el-form-item>
<el-form-item label="起草责任单位" style="width: 100%; margin-right:10px" prop="unit" class="add-form-item form-item-disabled">
<el-select v-model="qbfsForm.unit" filterable multiple clearable>
<el-option
v-for="item in qcdwOptions"
placeholder="请选择起草责任单位"
:key="item.value"
:value="item.label"
:label="item.label"
></el-option>
</el-select>
<el-input v-model="qbfsForm.unitId" style="display: none;"></el-input>
<el-input v-model="qbfsForm.unit" placeholder="请选择起草责任单位"
@click.native="choiceZRBM('unit', '选择起草责任单位', qbfsForm.unitId)">
</el-input>
<!-- <el-select v-model="qbfsForm.unit" filterable multiple clearable>-->
<!-- <el-option-->
<!-- v-for="item in qcdwOptions"-->
<!-- placeholder="请选择起草责任单位"-->
<!-- :key="item.value"-->
<!-- :value="item.label"-->
<!-- :label="item.label"-->
<!-- ></el-option>-->
<!-- </el-select>-->
</el-form-item>
<!-- <el-form-item label="起草责任单位" style="width: 100%; margin-right:10px" class="add-form-item" prop="unit" >-->
<!-- <div style="display: flex;justify-content: space-between;align-items: center;">-->
<!-- <el-input-->
<!-- clearable-->
<!-- v-model="qbfsForm.unit"-->
<!-- placeholder="选择或输入起草单位">-->
<!-- </el-input>-->
<!-- <div>-->
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="primary"-->
<!-- @click="QCDWClick"-->
<!-- class="common-button-primary">手动查找</el-button>-->
<!-- </div>-->
<!-- </div>-->
<!-- </el-form-item>-->
</el-col>
<el-col :span="12">
<el-form-item prop="planStatus" label="计划状态" style="width: 100%; margin-right:10px" class="add-form-item form-item-disabled">
@@ -287,6 +275,12 @@
@checkedRole="checkedRole2"
:nodeList="nodeList2"
></Role-tree>
<Mechanism-tree
is-title="选择起草责任单位"
:is-visible.sync="modalshowflagZRBM"
:nodeList="nodeListZRBM"
@checkedRole="drawerCheckZRBM"
/>
<Role-tree
check-box
:is-title="drawerTitle"
@@ -294,44 +288,24 @@
@checkedRole="checkedRole"
:nodeList="nodeList"
></Role-tree>
<el-dialog
:visible.sync="QCDWmodal"
width="500px"
title="选择起草部门"
destroy-on-close
:close-on-click-modal="false"
@closed="QCDWmodal = false">
<el-select v-model="QCDWValue" multiple filterable placeholder="请选择" style="width: 100%;">
<el-option
v-for="item in qcdwOptions"
:key="item.value"
:label="item.label"
:value="item.label">
</el-option>
</el-select>
<div slot="footer" class="demo-drawer-footer">
<el-button size="mini" type="primary" class="common-button-default" icon="el-icon-check"
@click="QCDWOK">确认
</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import ProcessTitle from "process/components/ProcessTitle";
import MechanismTree from '@/components/mechanismTree'
export default {
name: "merge",
components: {
ProcessTitle
ProcessTitle,
MechanismTree
},
props: ['message'],
data(){
return {
QCDWmodal: false,
QCDWValue: [],
QCDWList: [],
modalshowflagZRBM: false,
nodeListZRBM: [],
drawerTitle2: '',
drawerTitle: '',
type: '',
@@ -430,6 +404,9 @@ export default {
}
},
mounted() {
if(!this.qbfsForm.passFlag){
this.qbfsForm = {}
}
//查询下拉框数据
this.$http.get('sys/dictype/getDicTypeListCode', '',{
_this: this
@@ -450,19 +427,28 @@ export default {
}
},
methods: {
QCDWOK () {
let arr1 = []
if (this.qbfsForm.unit !== undefined) {
let str = this.qbfsForm.unit.replace(//g, ',')
arr1 = str.split(',')
}
let arr2 = arr1.concat(this.QCDWValue)
this.qbfsForm.unit = Array.from(new Set(arr2)).join(',')
this.QCDWmodal = false
choiceZRBM(type, title, id) {
this.nodeListZRBM = []
this.nodeListZRBM.push(id)
this.drawerTitle = title
this.modalshowflagZRBM = true
},
QCDWClick () {
this.QCDWValue = []
this.QCDWmodal = true
drawerCheckZRBM(data) {
let idList = ''
let nameList = ''
data.forEach(item => {
if (nameList.length) {
nameList += ','
idList += ','
}
idList += item.id
nameList += item.name
})
this.$set(this.qbfsForm, 'unitId', idList)
this.$set(this.qbfsForm, 'unit', nameList)
if(this.qbfsForm.unit){
this.$refs.qbfsForm.validateField('unit')
}
},
choiceZRR() {
this.nodeList = [];
@@ -96,7 +96,7 @@
</el-date-picker>
</el-form-item>
<el-form-item label="起草责任单位" prop="unit" class="add-form-item form-item-disabled">
<div v-if="qbfsForm.unit.length > 0">
<div v-if="qbfsForm.unit">
<el-tooltip class="item" effect="dark" :content="qbfsForm.unit" placement="top-start">
<el-input
readonly
@@ -316,6 +316,11 @@ export default {
}
}
},
mounted(){
if(!this.qbfsForm.passFlag){
this.qbfsForm = {}
}
},
methods: {
validateForm () {
let flag = null
@@ -270,7 +270,8 @@ export default {
},
data() {
return {
comFlag: 0,
toggleType: '1',
comFlag: 1,
active: "1",
commentText: "",
comName: "merge",
@@ -405,15 +406,15 @@ export default {
toggleComName(name) {
this.comName = name;
if(this.comName === 'merge'){
this.$refs["childForm"].qbfsForm.type = '1'
this.toggleType = '1'
}else if(this.comName === 'delay'){
this.$refs["childForm"].qbfsForm.type = '2'
this.toggleType = '2'
}else if(this.comName === 'cancel'){
this.$refs["childForm"].qbfsForm.type = '3'
this.toggleType = '3'
}else if(this.comName === 'rename'){
this.$refs["childForm"].qbfsForm.type = '4'
this.toggleType = '4'
}else if(this.comName === 'establish'){
this.$refs["childForm"].qbfsForm.type = '5'
this.toggleType = '5'
}
},
//流程保存
@@ -438,29 +439,32 @@ export default {
this.saveLoading = false
})
},
repeatName(){
let qbzxdFrom = this.$refs["childForm"].qbfsForm;
this.$http.get('esRevisePlan/es-revise-plan/getDataByName', {esName: qbzxdFrom.esName, id : qbzxdFrom.esId}, {
_this: this
}, res => {
let dataList = res.data
dataList.forEach(item => {
if(item.esName === qbzxdFrom.esName1 || item.esName === qbzxdFrom.esName2){
this.comFlag++
}else{
this.comFlag = 0
}
})
})
},
// repeatName(){
// let qbzxdFrom = this.$refs["childForm"].qbfsForm;
// this.$http.get('esRevisePlan/es-revise-plan/getDataByName', {esName: qbzxdFrom.esName, id : qbzxdFrom.esId}, {
// _this: this
// }, res => {
// if(qbzxdFrom.type === '1'){
// let dataList = res.data
// dataList.forEach(item => {
// if(item.esName === qbzxdFrom.esName1 || item.esName === qbzxdFrom.esName2){
// this.comFlag = 1
// }
// })
// }else if(qbzxdFrom.type === '5'){
// if(!res.data.length){
// this.comFlag = 1
// }
// }
// })
// },
//流程提交
handleSubmit() {
if(this.$refs["childForm"].qbfsForm.type === undefined){
this.$refs["childForm"].qbfsForm.type = '1'
if(!this.$refs["childForm"].qbfsForm.type){
this.$refs["childForm"].qbfsForm.type = this.toggleType
}
this.repeatName()
if(this.comFlag === '0'){
this.$message.warning('请更改企标名称')
if(this.comFlag === 0){
this.$message.warning('企标名称已存在,请更改!')
}else {
if (this.$route.query.prcNum === undefined) {
let flag = this.$refs["childForm"].validateForm();
@@ -468,9 +472,10 @@ export default {
if (flag) {
this.$refs["roleForm"].validate((valid) => {
if (valid) {
this.isSubmit = true;
// this.isSubmit = true;
var json = Object.assign(qbzxdFrom, this.roleForm);
console.log(json);
return
this.$http.get("lawss/activiti/startProcess", { type: "25" }, {
_this: this
}, res => {
@@ -650,9 +650,9 @@ export default {
justify-content: space-between;
.card-top-left {
img {
margin: 10px;
width: 80px;
height: 80px;
margin: 30px;
width: 40px;
height: 40px;
}
}
.card-top-right {