[update] 企标流程联调

This commit is contained in:
lideqin
2023-11-01 15:43:17 +08:00
parent e25bbfbc5c
commit d8a44a4ae6
12 changed files with 301 additions and 136 deletions
+3 -3
View File
@@ -16,8 +16,6 @@ const enterprisePlanApprovalTurnTo = (params) => postAction('/process/es/initCha
const enterprisePlanApprovalAgree = (params) => postAction('/process/es/initChange/agree', params)
// 驳回
const enterprisePlanApprovalReject = (params) => postAction('/process/es/initChange/reject', params)
// 确定
const enterprisePlanApprovalDetermine = (params) => postAction('', params)
// 节点一的提交————发起流程
const enterprisePlanApproval = (params) => postAction('/process/es/initChange/start', params)
// 保存
@@ -52,6 +50,8 @@ const standardizationInitTurnTo = (params) => postAction('/process/es/annualInit
const standardizationInitAgree = (params) => postAction('/process/es/annualInit/agree', params)
// 拒绝
const standardizationInitReject = (params) => postAction('/process/es/annualInit/reject', params)
// 根据流程id获取流程信息
const standardizationInitGetDataById = (taskId, params) => getAction(`/process/es/annualInit/handle/${taskId}`, params)
// 企标更改流程
// 保存
@@ -139,7 +139,6 @@ export {
enterprisePlanApprovalTurnTo,
enterprisePlanApprovalAgree,
enterprisePlanApprovalReject,
enterprisePlanApprovalDetermine,
enterprisePlanApproval,
enterprisePlanApprovalSave,
getEnStandardNo,
@@ -157,6 +156,7 @@ export {
standardizationInitTurnTo,
standardizationInitAgree,
standardizationInitReject,
standardizationInitGetDataById,
enStandardChangeSave,
enStandardChangeApproval,
@@ -98,7 +98,7 @@
<!-- 人员信息 -->
<div v-show="switchValue === 'user'" class="detail-page-scroll-content p-0">
<process-detail-list :url="url">
<process-detail-list>
<personnel-info slot="personnelInfo" ref="personnelInfo" :data="personnelInfoData" :currentNode="currentNode + ''"></personnel-info>
</process-detail-list>
</div>
@@ -184,35 +184,40 @@ const personData = [
id: 3,
nodeName: '工作组/所联络人填写企标',
nodeRoleName: '工作组/所联络人',
canChoose: false
canChoose: false,
fieldName: 'workGroupUserList'
},
{
id: 4,
nodeName: '收集联络人主管级领导审批',
nodeRoleName: '联络人主管级领导',
canChoose: false,
chooseType: 'checkbox'
chooseType: 'checkbox',
fieldName: 'collectUserLeader'
},
{
id: 5,
nodeName: '各部门联络人汇总',
nodeRoleName: '各部门联络人',
canChoose: false,
chooseType: 'checkbox'
chooseType: 'checkbox',
fieldName: 'contactUserList'
},
{
id: 6,
nodeName: '联络人主管级上一级领导审批',
nodeRoleName: '联络人主管级上一级领导',
canChoose: false,
chooseType: 'checkbox'
chooseType: 'checkbox',
fieldName: 'contactUserLeaderLeader'
},
{
id: 7,
nodeName: '标准化工程师归档',
nodeRoleName: '标准化工程师',
canChoose: false,
chooseType: 'radio'
chooseType: 'radio',
fieldName: 'standardEngineer'
}
]
@@ -245,6 +250,25 @@ export default {
// 没有taskId说明是新建进来的,初始化人员信息
this.personnelInfoData = personData
}
// 初始化节点
const taskName = this.$route.query.taskName
if (taskName) {
if (taskName === '标准化工程师发起') {
this.currentNode = 1
} else if (taskName === '各部所联络人 填写/下发任务') {
this.currentNode = 2
} else if (taskName === '工作组/所联络人填写企标') {
this.currentNode = 3
} else if (taskName === '收集联络人主管级领导审批') {
this.currentNode = 4
} else if (taskName === '各部所联络人汇总') {
this.currentNode = 5
} else if (taskName === '联络人主管级上一级领导审批') {
this.currentNode = 6
} else {
this.currentNode = 7
}
}
// 如果是查看进入的,不可编辑,不可操作
if (this.$route.query.onlyLook) {
this.onlyLook = this.$route.query.onlyLook
@@ -311,37 +335,52 @@ export default {
if (res.success) {
this.model = res.result
this.$nextTick(() => {
// 初始化流程信息
this.processInfoForm.setFieldsValue(pick(this.model.common, 'prcName', 'dueTime', 'prcMes'))
// 初始化流程信息,节点1没有制修订计划说明,其余节点都有制修订计划说明
if (this.currentNode === 1) {
this.processInfoForm.setFieldsValue(pick(this.model.common, 'prcName', 'dueTime', 'prcMes'))
} else {
this.processInfoForm.setFieldsValue(pick(this.model.common, 'prcName', 'dueTime', 'prcMes', 'processDescription'))
}
// 初始化流程审批信息,todo:需要判断是不是草稿进来的,草稿进来的才回显审批信息
// this.approvalInfoForm.setFieldsValue(pick(this.model[0], 'commitText', 'commitFile'))
})
const taskName = this.$route.query.taskName
if (taskName) {
if (taskName === '标准化工程师发起') {
this.currentNode = 1
} else if (taskName === '各部所联络人填写/下发任务') {
this.currentNode = 2
} else if (taskName === '工作组/所联络人填写企标') {
this.currentNode = 3
} else if (taskName === '收集联络人主管级领导审批') {
this.currentNode = 4
} else if (taskName === '各部所联络人汇总') {
this.currentNode = 5
} else if (taskName === '联络人主管级上一级领导审批') {
this.currentNode = 6
} else {
this.currentNode = 7
}
}
// 初始化人员信息
if (this.currentNode === 1) {
this.personnelInfoData = personData
this.personnelInfoData = personData.map(item => {
if (item.fieldName) {
return {
...item,
user: this.model.flowUser[item.fieldName],
user_dictText: this.model.flowUser[item.fieldName + '_dictText']
}
} else {
return item
}
})
} else {
this.personnelInfoData = personData.map(item => {
return { ...item, canChoose: false, fieldName: undefined }
if (item.fieldName) {
return { ...item, user: this.model.flowUser[item.fieldName], userList: this.model.flowUser[item.fieldName + '_dictText'], canChoose: false }
} else {
return item
}
})
}
this.$refs.baseInfoFormRef.initData(this.model.dataList)
// 初始化业务基本信息
if (this.currentNode === 1) {
// 节点1需要回显数据
this.$refs.baseInfoFormRef.initData(this.model)
} else if (this.currentNode === 2) {
// 节点2草稿情况下需要回显数据 todo
} else if (this.currentNode === 3) {
// 节点3草稿回显所有 todo ,待办进来回显表格数据
this.$refs.baseInfoFormRef.initTableData()
} else if ([4, 5, 6, 7].includes(this.currentNode)) {
// 节点4,5,6,7回显数据
this.$refs.baseInfoFormRef.initData(this.model)
}
} else {
this.$message.warning(res.message)
}
})
},
@@ -418,6 +457,7 @@ export default {
activelyReportSave(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -432,7 +472,7 @@ export default {
const personnelInfo = this.$refs.personnelInfo.stepsData
const personnelObj = {}
for (const item of personnelInfo) {
if (item.fieldName) {
if (item.fieldName && item.canChoose) {
personnelObj[item.fieldName] = item.user
}
}
@@ -457,6 +497,7 @@ export default {
activelyReportApproval(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -485,6 +526,7 @@ export default {
activelyReportTurnTo(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -517,6 +559,7 @@ export default {
activelyReportAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -538,6 +581,7 @@ export default {
activelyReportAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -558,6 +602,7 @@ export default {
activelyReportReject(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -566,6 +611,9 @@ export default {
})
}
})
},
goBack () {
this.$router.go(-1)
}
}
}
@@ -133,11 +133,21 @@ export default {
initData (data) {
this.data = data
// 给表单赋值
// this.formInline =
// 给表格赋值
// this.$nextTick(() => {
// this.$refs.tableRef.dataSource =
// })
if (data.dataList[0].distributeFlag + '' === '0') {
// 不下发联络人
this.formInline = { distributeFlag: data.dataList[0].distributeFlag }
// 给表格赋值
this.$nextTick(() => {
this.$refs.tableRef.initData(data)
})
} else {
// 下发联络人,没有表格
this.formInline = {
distributeFlag: data.dataList[0].distributeFlag,
workGroupUserList: data.flowUser.workGroupUserList,
contactUserLeaderLeader: data.flowUser.contactUserLeaderLeader
}
}
},
// 外层要获取数据
getData () {
@@ -11,13 +11,13 @@
{{ $t('workCenter.revisionPlanActivelyReport.contactsSupervisorLevelLeaders') }}
</span>
</div>
<a-form-model-item class="item-model" prop="contactsSupervisorLevelLeaders">
<a-form-model-item class="item-model" prop="collectUserLeader">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.revisionPlanActivelyReport.contactsSupervisorLevelLeaders')"
v-model="formInline.contactsSupervisorLevelLeaders"
v-model="formInline.collectUserLeader"
:disabled="disabled"
filedName="contactsSupervisorLevelLeaders"
filedName="collectUserLeader"
@nameChange="userSelectNameChange"
:nameStr="formInline.contactsSupervisorLevelLeaders_dictText"
:nameStr="formInline.collectUserLeader_dictText"
type="radio" />
</a-form-model-item>
</div>
@@ -55,7 +55,7 @@ export default {
formInline: {},
rules: {
// 收集联络人主管级领导
contactsSupervisorLevelLeaders: [
collectUserLeader: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.contactsSupervisorLevelLeaders') + this.$t('cannotEmpty'),
@@ -76,11 +76,16 @@ export default {
initData (data) {
this.data = data
// 给表单赋值
// this.formInline =
this.formInline = { collectUserLeader: data.flowUser.collectUserLeader }
// 给表格赋值
// this.$nextTick(() => {
// this.$refs.tableRef.dataSource =
// })
this.$nextTick(() => {
this.$refs.tableRef.initData(data)
})
},
initTableData (data) {
this.$nextTick(() => {
this.$refs.tableRef.initData(data)
})
},
// 外层要获取数据
getData () {
@@ -53,7 +53,9 @@ export default {
initData (data) {
this.data = data
// 给表单赋值
// this.formInline =
this.formInline = {
processDescription: data.common.processDescription
}
},
// 外层要获取数据
getData () {
@@ -277,6 +277,13 @@ export default {
}
},
methods: {
initData (data) {
this.data = data
// 给表格赋值
this.$nextTick(() => {
this.dataSource = data.dataList
})
},
// 企标编号,企标名称跳转详情,原企标
handleGoDetailOld (record) {
this.$openPageNewSheet({
@@ -143,10 +143,12 @@ import {
standardizationInitSave,
standardizationInitTurnTo,
standardizationInitAgree,
standardizationInitReject
standardizationInitReject,
standardizationInitGetDataById
} from '@/api/workCenter'
import Vue from 'vue'
import { USER_INFO } from '@/store/mutation-types'
import pick from 'lodash.pick'
const personData = [
{
@@ -161,37 +163,43 @@ const personData = [
id: 2,
nodeName: '部所联络人选取审批人',
nodeRoleName: '部所联络人',
canChoose: false
canChoose: false,
fieldName: 'contactUser'
},
{
id: 3,
nodeName: '主起草单位主管级领导审批下发',
nodeRoleName: '主起草单位主管级领导',
canChoose: false
canChoose: false,
fieldName: 'approvalUser'
},
{
id: 4,
nodeName: '主起草人填写信息',
nodeRoleName: '主起草人',
canChoose: false
canChoose: false,
fieldName: 'mainDraftUser'
},
{
id: 5,
nodeName: '部所联络人汇总',
nodeRoleName: '部所联络人',
canChoose: false
canChoose: false,
fieldName: 'contactUser'
},
{
id: 6,
nodeName: '主起草单位主管级领导批准',
nodeRoleName: '主起草单位主管级领导',
canChoose: false
canChoose: false,
fieldName: 'approvalUser'
},
{
id: 7,
nodeName: '标准化归档',
nodeRoleName: '标准化工程师',
canChoose: false
canChoose: false,
fieldName: 'standardEngineer'
}
]
@@ -217,12 +225,12 @@ export default {
}
},
mounted () {
if (this.currentNode === 1) {
this.personnelInfoData = personData
if (this.$route.query.taskId) {
// 有流程id说明是从流程中心来的,需要初始化数据
this.getProcessData(this.$route.query.taskId)
} else {
this.personnelInfoData = personData.map(item => {
return { ...item, canChoose: false, fieldName: undefined }
})
// 没有taskId说明是新建进来的,初始化人员信息
this.personnelInfoData = personData
}
// 如果是查看进入的,不可编辑,不可操作
if (this.$route.query.onlyLook) {
@@ -284,6 +292,61 @@ export default {
}
},
methods: {
getProcessData (taskId) {
standardizationInitGetDataById(taskId).then(res => {
if (res.success) {
this.model = res.result
this.$nextTick(() => {
// 初始化流程信息
this.processInfoForm.setFieldsValue(pick(this.model.common, 'prcName', 'dueTime', 'prcMes'))
// 初始化流程审批信息,todo:需要判断是不是草稿进来的,草稿进来的才回显审批信息
// this.approvalInfoForm.setFieldsValue(pick(this.model[0], 'commitText', 'commitFile'))
})
const taskName = this.$route.query.taskName
if (taskName) {
if (taskName === '标准化工程师发起') {
this.currentNode = 1
} else if (taskName === '部所联络人选取审批人') {
this.currentNode = 2
} else if (taskName === '主起草单位主管级领导审批下发') {
this.currentNode = 3
} else if (taskName === '主起草人填写信息') {
this.currentNode = 4
} else if (taskName === '部所联络人汇总') {
this.currentNode = 5
} else if (taskName === '主起草单位主管级领导批准') {
this.currentNode = 6
} else {
this.currentNode = 7
}
}
if (this.currentNode === 1) {
this.personnelInfoData = personData.map(item => {
if (item.fieldName) {
return {
...item,
user: this.model.flowUser[item.fieldName],
user_dictText: this.model.flowUser[item.fieldName + '_dictText']
}
} else {
return item
}
})
} else {
this.personnelInfoData = personData.map(item => {
if (item.fieldName) {
return { ...item, user: this.model.flowUser[item.fieldName], userList: this.model.flowUser[item.fieldName + '_dictText'], canChoose: false }
} else {
return item
}
})
}
this.$refs.baseInfoRef.initData(this.model.dataList)
} else {
this.$message.warning(res.message)
}
})
},
switchChange (value) {
this.switchValue = value
},
@@ -333,6 +396,7 @@ export default {
standardizationInitSave(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -347,7 +411,7 @@ export default {
const personnelInfo = this.$refs.personnelInfo.stepsData
const personnelObj = {}
for (const item of personnelInfo) {
if (item.fieldName) {
if (item.fieldName && item.canChoose) {
personnelObj[item.fieldName] = item.user
}
}
@@ -369,6 +433,7 @@ export default {
standardizationInitApproval(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -397,6 +462,7 @@ export default {
standardizationInitTurnTo(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -420,6 +486,7 @@ export default {
standardizationInitAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -442,6 +509,7 @@ export default {
standardizationInitAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -463,6 +531,7 @@ export default {
standardizationInitReject(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -471,6 +540,9 @@ export default {
})
}
})
},
goBack () {
this.$router.go(-1)
}
}
}
@@ -24,7 +24,7 @@
@change="event => event.target.value = event.target.value.trim()"
disabled
:maxLength="50"
v-decorator="['processName', validatorRules.processName]" />
v-decorator="['prcName', validatorRules.prcName]" />
</a-form-item>
</a-col>
<a-col :span="12">
@@ -34,7 +34,7 @@
style="width: 100%"
:disabled="disabled"
value-format="YYYY-MM-DD"
v-decorator="['deadlineDate']" />
v-decorator="['dueTime']" />
</a-form-item>
</a-col>
<a-col :span="24">
@@ -44,7 +44,7 @@
:maxLength="500"
:rows="4"
:disabled="disabled"
v-decorator="['processDescription']" />
v-decorator="['prcMes']" />
</a-form-item>
</a-col>
</a-row>
@@ -68,11 +68,11 @@
<a-textarea :placeholder="$t('pleaseEnter') + $t('remarks')"
:maxLength="500"
:rows="4"
v-decorator="['remarks', validatorRules.remarks]" />
v-decorator="['commitText', validatorRules.commitText]" />
</a-form-item>
<!--附件-->
<a-form-item :labelCol="longLabelCol" :wrapperCol="longWrapperCol" :label="$t('businessSupport.questionAnswer.attach')">
<j-upload v-decorator="['attachment']" return-id />
<j-upload v-decorator="['commitFile']" return-id />
</a-form-item>
</a-form>
</div>
@@ -134,7 +134,8 @@ const personalInfo = [ // 人员信息的数据
nodeName: '主起草人发起',
nodeRoleName: '发起人',
canChoose: false,
userList: Vue.ls.get(USER_INFO).realname + '(' + Vue.ls.get(USER_INFO).username + ')'
userList: Vue.ls.get(USER_INFO).realname + '(' + Vue.ls.get(USER_INFO).username + ')',
fieldName: 'mainDraftUser'
},
{
id: 2,
@@ -142,7 +143,7 @@ const personalInfo = [ // 人员信息的数据
nodeRoleName: '相关人员',
canChoose: true,
chooseType: 'checkbox',
fieldName: ''
fieldName: 'relatedUser'
},
{
id: 3,
@@ -150,7 +151,7 @@ const personalInfo = [ // 人员信息的数据
nodeRoleName: '起草人主管级领导',
canChoose: true,
chooseType: 'radio',
fieldName: ''
fieldName: 'mainDraftUserLeader'
},
{
id: 4,
@@ -158,7 +159,7 @@ const personalInfo = [ // 人员信息的数据
nodeRoleName: '标准化',
canChoose: true,
chooseType: 'radio',
fieldName: ''
fieldName: 'standardizationUser'
},
{
id: 5,
@@ -166,7 +167,7 @@ const personalInfo = [ // 人员信息的数据
nodeRoleName: '起草人主管级上一级领导',
canChoose: true,
chooseType: 'radio',
fieldName: ''
fieldName: 'mainDraftUserLeaderLeader'
}
]
@@ -233,13 +234,13 @@ export default {
},
validatorRules: {
// 流程名称
processName: {
prcName: {
rules: [
{ required: true, message: this.$t('pleaseEnter') + this.$t('processName') }
],
validateTrigger: 'blur'
},
remarks: {
commitText: {
rules: [
{ required: false, message: this.$t('pleaseEnter') + this.$t('remarks') }
],
@@ -262,9 +263,9 @@ export default {
this.model = res.result
this.$nextTick(() => {
// 初始化流程信息
this.processInfoForm.setFieldsValue(pick(this.model[0], 'processName', 'deadlineDate', 'processDescription'))
this.processInfoForm.setFieldsValue(pick(this.model[0], 'prcName', 'dueTime', 'prcMes'))
// 初始化流程审批信息,todo:需要判断是不是草稿进来的,草稿进来的才回显审批信息
// this.approvalInfoForm.setFieldsValue(pick(this.model[0], 'remarks', 'attachment'))
// this.approvalInfoForm.setFieldsValue(pick(this.model[0], 'commitText', 'commitFile'))
})
// 初始化业务基本信息的申请类型和项目类别
this.formInline.applicationCategory = this.model[0].applicationCategory
@@ -289,9 +290,9 @@ export default {
},
// 业务基本信息组件中获取到流程名称改变后的值
processNameChange (value) {
const param = { processName: value }
const param = { prcName: value }
this.$nextTick(() => {
this.processInfoForm.setFieldsValue(pick(param, 'processName'))
this.processInfoForm.setFieldsValue(pick(param, 'prcName'))
})
},
// 保存
@@ -332,6 +333,7 @@ export default {
enStandardChangeSave(arr).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -346,7 +348,7 @@ export default {
const personnelInfo = this.$refs.personnelInfo.stepsData
const personnelObj = {}
for (const item of personnelInfo) {
if (item.fieldName) {
if (item.fieldName && item.canChoose) {
personnelObj[item.fieldName] = item.user
}
}
@@ -365,6 +367,7 @@ export default {
enStandardChangeApproval(arr).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -393,6 +396,7 @@ export default {
enStandardChangeTurnTo(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -413,6 +417,7 @@ export default {
enStandardChangeAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -425,8 +430,8 @@ export default {
// 驳回
handleReject () {
if (this.loading) return
this.validatorRules.remarks.rules[0].required = true
if (!this.approvalInfoForm.getFieldValue('remarks')) {
this.validatorRules.commitText.rules[0].required = true
if (!this.approvalInfoForm.getFieldValue('commitText')) {
this.$message.warning(this.$t('pleaseEnterRemarks'))
}
this.$nextTick(() => {
@@ -438,16 +443,20 @@ export default {
enStandardChangeReject(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
}).finally(() => {
this.loading = false
this.validatorRules.remarks.rules[0].required = false
this.validatorRules.commitText.rules[0].required = false
})
}
})
})
},
goBack () {
this.$router.go(-1)
}
}
}
@@ -7,7 +7,7 @@
:can-drag="true"
:scroll="{x: '100%'}"
ref="table"
rowKey="enterpriseStandardPlanId"
:rowKey="(index) => {return index}"
:columns="columns"
:dataSource="dataSource"
:pagination="false"
@@ -27,12 +27,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enStandardNo">
<a-form-model-item class="item-model" prop="standardNumber">
<standard-selection :source="StandardSource.ENTERPRISE.value"
:disabled="disabled"
:disabledSourceSearch="true"
type="radio"
v-model="formInline.enStandardNo"
v-model="formInline.standardNumber"
@listChange="listChange" />
</a-form-model-item>
</div>
@@ -43,9 +43,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enStandardName">
<a-form-model-item class="item-model" prop="standardName">
<a-input class="box-input"
v-model="formInline.enStandardName"
v-model="formInline.standardName"
:maxLength="50"
@change="event => event.target.value = event.target.value.trim()"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')" />
@@ -59,10 +59,10 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardGradeClassification') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enStandardClassification">
<a-form-model-item class="item-model" prop="gradeClassification">
<j-dict-select-tag class="box-input"
:disabled="disabled"
v-model="formInline.enStandardClassification"
v-model="formInline.gradeClassification"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.standardGradeClassification')"
:type="'select'"
:triggerChange="false"
@@ -77,9 +77,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardSystem') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enStandardSystem">
<a-form-model-item class="item-model" prop="standardSystem">
<a-tree-select
v-model="formInline.enStandardSystem"
v-model="formInline.standardSystem"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
:disabled="disabled"
@@ -96,10 +96,10 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardEnglishName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enStandardEnglishName">
<a-form-model-item class="item-model" prop="englishName">
<a-input class="box-input"
:disabled="disabled"
v-model="formInline.enStandardEnglishName"
v-model="formInline.englishName"
:maxLength="50"
@change="event => event.target.value = event.target.value.trim()"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.standardEnglishName')" />
@@ -130,9 +130,9 @@
{{ $t('workCenter.enStandardChange.materialDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="materialDate">
<a-form-model-item class="item-model" prop="implementationDate">
<a-date-picker
v-model="formInline.materialDate"
v-model="formInline.implementationDate"
:showTime="false"
:disabled="disabled"
value-format="YYYY-MM-DD">
@@ -146,10 +146,10 @@
{{ $t('workCenter.enStandardChange.isTry') }}
</span>
</div>
<a-form-model-item class="item-model" prop="isTry">
<a-form-model-item class="item-model" prop="tryFlag">
<j-dict-select-tag class="box-input"
:disabled="disabled"
v-model="formInline.isTry"
v-model="formInline.tryFlag"
:placeholder="$t('pleaseSelect')+$t('workCenter.enStandardChange.isTry')"
:type="'select'"
:triggerChange="false"
@@ -181,8 +181,8 @@
{{ $t('workCenter.enterpriseInitChangePlan.partName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="componentName">
<a-tree-select v-model="formInline.componentName"
<a-form-model-item class="item-model" prop="partName">
<a-tree-select v-model="formInline.partName"
:disabled="disabled"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
@@ -228,11 +228,11 @@
{{ $t('workCenter.enStandardChange.scopeOfApplication') }}
</span>
</div>
<a-form-model-item class="item-model" prop="scopeOfApplication">
<a-form-model-item class="item-model" prop="standardScope">
<a-textarea :placeholder="$t('pleaseEnter')+$t('workCenter.enStandardChange.scopeOfApplication')"
:maxLength="500"
:disabled="disabled"
v-model="formInline.scopeOfApplication" :rows="4" />
v-model="formInline.standardScope" :rows="4" />
</a-form-model-item>
</div>
<!-- 代替标准号 -->
@@ -349,12 +349,12 @@ export default {
},
watch: {
// 企标编号监视
'formInline.enStandardNo' (value) {
this.$emit('processNameChange', (value || '') + '-' + (this.formInline.enStandardName || '') + '-' + '企标更改')
'formInline.standardNumber' (value) {
this.$emit('processNameChange', (value || '') + '-' + (this.formInline.standardName || '') + '-' + '企标更改')
},
// 企标名称监视
'formInline.enStandardName' (value) {
this.$emit('processNameChange', (this.formInline.enStandardNo || '') + '-' + (value || '') + '-' + '企标更改')
'formInline.standardName' (value) {
this.$emit('processNameChange', (this.formInline.standardNumber || '') + '-' + (value || '') + '-' + '企标更改')
}
},
data () {
@@ -365,7 +365,7 @@ export default {
formInline: {},
rules: {
// 企标编号
enStandardNo: [
standardNumber: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') + this.$t('cannotEmpty'),
@@ -373,7 +373,7 @@ export default {
}
],
// 标准等级分类
enStandardClassification: [
gradeClassification: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.standardGradeClassification') + this.$t('cannotEmpty'),
@@ -381,7 +381,7 @@ export default {
}
],
// 标准体系
enStandardSystem: [
standardSystem: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.standardSystem') + this.$t('cannotEmpty'),
@@ -397,7 +397,7 @@ export default {
}
],
// 实施日期
materialDate: [
implementationDate: [
{
required: true,
message: this.$t('workCenter.enStandardChange.materialDate') + this.$t('cannotEmpty'),
@@ -405,7 +405,7 @@ export default {
}
],
// 零部件名称
componentName: [
partName: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.partName') + this.$t('cannotEmpty'),
@@ -442,9 +442,9 @@ export default {
listChange (value) {
console.log(value)
// 企标名称
this.formInline.enStandardName = value[0].standardName
this.formInline.standardName = value[0].standardName
// 标准等级分类
// this.formInline.enStandardClassification = value[0].
// this.formInline.gradeClassification = value[0].
// 标准体系
// 标准英文名称
// 发布日期
@@ -256,7 +256,6 @@ import {
enterprisePlanApprovalTurnTo,
enterprisePlanApprovalAgree,
enterprisePlanApprovalReject,
enterprisePlanApprovalDetermine,
enterprisePlanApprovalSave,
enterprisePlanApproval,
getProcessDataById
@@ -374,28 +373,32 @@ const changePersonalInfo = [
nodeName: '新起草部门主管级上一级领导下发',
nodeRoleName: '新起草部门主管级上一级领导',
canChoose: false,
chooseType: 'radio'
chooseType: 'radio',
fieldName: 'newMainDraftUserLeaderLeader'
},
{
id: 7,
nodeName: '新起草部门主管级领导确认',
nodeRoleName: '新起草部门主管级领导',
canChoose: false,
chooseType: 'radio'
chooseType: 'radio',
fieldName: 'newMainDraftUserLeader'
},
{
id: 8,
nodeName: '相关人员会签',
nodeRoleName: '相关人员',
canChoose: false,
chooseType: 'checkbox'
chooseType: 'checkbox',
fieldName: 'relatedUser'
},
{
id: 9,
nodeName: '抄送主起草人',
nodeRoleName: '主起草人',
canChoose: false,
chooseType: 'checkbox'
chooseType: 'checkbox',
fieldName: 'createUser'
}
]
@@ -811,6 +814,7 @@ export default {
enterprisePlanApprovalSave(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -825,7 +829,7 @@ export default {
const personnelInfo = this.$refs.personnelInfo.stepsData
const personnelObj = {}
for (const item of personnelInfo) {
if (item.fieldName) {
if (item.fieldName && item.canChoose) {
personnelObj[item.fieldName] = item.user
}
}
@@ -940,6 +944,7 @@ export default {
func(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -964,6 +969,7 @@ export default {
enterprisePlanApprovalAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -991,6 +997,7 @@ export default {
enterprisePlanApprovalTurnTo(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -1026,6 +1033,7 @@ export default {
enterprisePlanApprovalAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -1052,6 +1060,7 @@ export default {
enterprisePlanApprovalReject(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -1069,11 +1078,13 @@ export default {
this.approvalInfoForm.validateFields((err, values) => {
if (!err) {
this.loading = true
const param = Object.assign({}, values)
param.taskId = this.$route.query.taskId
enterprisePlanApprovalDetermine(param).then(res => {
const param = {}
param.common = Object.assign({}, values)
param.common.taskId = this.$route.query.taskId
enterprisePlanApprovalAgree(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.goBack()
} else {
this.$message.warning(res.message)
}
@@ -1082,6 +1093,9 @@ export default {
})
}
})
},
goBack () {
this.$router.go(-1)
}
}
}
@@ -16,7 +16,6 @@
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum')"
v-model="formInline.espId"
:standard-number="formInline.originEnStandardNo"
@standardNumberChange="standardNumberChange"
:searchParam="{ projectType: projectType }"
:disabled="disabled"
@listChange="listChange"/>
@@ -251,25 +250,24 @@ export default {
}
},
methods: {
// 企标计划选择完成的企标编号回调
standardNumberChange (value) {
this.formInline.originEnStandardNo = value
},
// 企标选编号选择完成的回调
listChange (value) {
console.log(value)
if (value && value.length > 0) {
this.formInline.originEnStandardName = value[0].originEnStandardName
this.formInline.mainDraftingUser = value[0].mainDraftingUser
this.formInline.mainDraftingUser_dictText = value[0].mainDraftingUser_dictText
this.formInline.mainDraftingUnit = value[0].mainDraftingUnit
this.formInline.newMainDraftingUser = value[0].mainDraftingUser
this.formInline.newMainDraftingUser_dictText = value[0].mainDraftingUser_dictText
this.formInline.newMainDraftingUnit = value[0].mainDraftingUnit
this.formInline.mainDraftingUnitResponsiblePerson = value[0].mainDraftingUnitResponsiblePerson
this.formInline.mainDraftingUnitResponsiblePerson_dictText = value[0].mainDraftingUnitResponsiblePerson_dictText
this.formInline.newMainDraftingUnitResponsiblePerson = value[0].mainDraftingUnitResponsiblePerson
this.formInline.newMainDraftingUnitResponsiblePerson_dictText = value[0].mainDraftingUnitResponsiblePerson_dictText
const formInline = {}
formInline.originEnStandardNo = value[0].originEnStandardNo
formInline.originEnStandardName = value[0].originEnStandardName
formInline.mainDraftingUser = value[0].mainDraftingUser
formInline.mainDraftingUser_dictText = value[0].mainDraftingUser_dictText
formInline.mainDraftingUnit = value[0].mainDraftingUnit
formInline.newMainDraftingUser = value[0].mainDraftingUser
formInline.newMainDraftingUser_dictText = value[0].mainDraftingUser_dictText
formInline.newMainDraftingUnit = value[0].mainDraftingUnit
formInline.mainDraftingUnitResponsiblePerson = value[0].mainDraftingUnitResponsiblePerson
formInline.mainDraftingUnitResponsiblePerson_dictText = value[0].mainDraftingUnitResponsiblePerson_dictText
formInline.newMainDraftingUnitResponsiblePerson = value[0].mainDraftingUnitResponsiblePerson
formInline.newMainDraftingUnitResponsiblePerson_dictText = value[0].mainDraftingUnitResponsiblePerson_dictText
this.formInline = Object.assign({}, this.formInline, formInline)
}
},
// 选择用户得到用户名