[add] 企标复审流程
This commit is contained in:
@@ -70,6 +70,18 @@ const enterprisePlanApprovalTurnTo = (params) => postAction('/process/es/initCha
|
||||
// 保存
|
||||
const enterprisePlanApprovalSave = (params) => postAction('/process/es/initChange/save', params)
|
||||
|
||||
// 企标复审流程
|
||||
// 保存
|
||||
const enStandardRecheckSave = (params) => postAction('/process/es/recheck/save', params)
|
||||
// 转办
|
||||
const enStandardRecheckTurnTo = (params) => postAction('/process/es/recheck/transfer', params)
|
||||
// 同意
|
||||
const enStandardRecheckAgree = (params) => postAction('/process/es/recheck/agree', params)
|
||||
// 驳回
|
||||
const enStandardRecheckReject = (params) => postAction('/process/es/recheck/reject', params)
|
||||
// 根据id查询流程数据
|
||||
const enStandardRecheckGetDataById = (taskId, params) => getAction(`/process/es/recheck/handle/${taskId}`, params)
|
||||
|
||||
// 企标废止流程
|
||||
// 根据id查询流程数据--办理
|
||||
const enStandardAnnulGetDataById = (taskId, params) => getAction(`/process/es/abolish/handle/${taskId}`, params)
|
||||
@@ -189,6 +201,12 @@ export {
|
||||
enterprisePlanApprovalTurnTo,
|
||||
enterprisePlanApprovalSave,
|
||||
|
||||
enStandardRecheckSave,
|
||||
enStandardRecheckTurnTo,
|
||||
enStandardRecheckAgree,
|
||||
enStandardRecheckReject,
|
||||
enStandardRecheckGetDataById,
|
||||
|
||||
enStandardAnnulGetDataById,
|
||||
enStandardAnnulTurnTo,
|
||||
enStandardAnnulAgree,
|
||||
|
||||
@@ -103,6 +103,15 @@ module.exports = {
|
||||
superintendent: '所长',
|
||||
relatedPersonnel: '相关人员'
|
||||
},
|
||||
// 企标复审流程
|
||||
esRecheck: {
|
||||
recheckDate: '复审日期',
|
||||
recheck: '复审',
|
||||
standGood: '继续有效',
|
||||
revise: '修订',
|
||||
annul: '废止',
|
||||
sealSave: '封存'
|
||||
},
|
||||
// 企标废止流程
|
||||
esAnnul: {
|
||||
standardType: '标准类型',
|
||||
|
||||
@@ -103,6 +103,15 @@ module.exports = {
|
||||
superintendent: '所长',
|
||||
relatedPersonnel: '相关人员'
|
||||
},
|
||||
// 企标复审流程
|
||||
esRecheck: {
|
||||
recheckDate: '复审日期',
|
||||
recheck: '复审',
|
||||
standGood: '继续有效',
|
||||
revise: '修订',
|
||||
annul: '废止',
|
||||
sealSave: '封存'
|
||||
},
|
||||
// 企标废止流程
|
||||
esAnnul: {
|
||||
standardType: '标准类型',
|
||||
|
||||
@@ -105,6 +105,23 @@ export const EsInitChangeNodes = new EsEnums({
|
||||
mainDrafterCopy: { text: '主起草人抄送', value: 'sid-08D0381A-5C20-4708-9D73-C7EB5C51DB02' }
|
||||
})
|
||||
|
||||
// 企标复审-复审
|
||||
export const Recheck = {
|
||||
STAND_GOOD: { text: '继续有效', value: '1' },
|
||||
REVISE: { text: '修订', value: '2' },
|
||||
ANNUL: { text: '废止', value: '3' },
|
||||
SEAL_SAVE: { text: '封存', value: '4' }
|
||||
}
|
||||
|
||||
// 企标复审流程
|
||||
export const EsRecheckNodes = new EsEnums({
|
||||
standardizationSelectContact: { text: '标准化工程师选择联络人', value: 'sid-9E19F873-6E54-427A-938F-0DBADD1DD7E5' },
|
||||
initiatorStart: { text: '发起人发起', value: 'sid-2E53F267-8541-40FB-974D-D8DDD03191CB' },
|
||||
drafterEnterOption: { text: '起草人填写意见', value: 'sid-72303DAD-0B49-471B-828E-66602468BE44' },
|
||||
drafterMinisterApproval: { text: '起草人部长审批', value: 'sid-18EE1480-C281-4569-93F6-F94F204B71ED' },
|
||||
standardizationApproval: { text: '标准化审批', value: 'sid-6BF8F285-0A2A-449C-A108-24024A922723' }
|
||||
})
|
||||
|
||||
// 下发人员类型
|
||||
export const SenderType = {
|
||||
moduleOwner: { text: '模块负责人', value: '1' },
|
||||
|
||||
@@ -9,6 +9,16 @@ export default [
|
||||
hasBack: true // 这个属性控制页面上面的导航栏 是否有返回按钮
|
||||
}
|
||||
},
|
||||
{
|
||||
path: '/workCenter/enterpriseStandardRecheck',
|
||||
name: 'EnterpriseStandardRecheck',
|
||||
component: (resolve) => require(['@/views/workCenter/enterpriseStandardRecheck/EnterpriseStandardRecheck.vue'], resolve),
|
||||
meta: {
|
||||
title: '企标复审流程',
|
||||
hasNavBar: true, // 这个属性控制页面是否显示上面的导航栏
|
||||
hasBack: true // 这个属性控制页面上面的导航栏 是否有返回按钮
|
||||
}
|
||||
},
|
||||
{
|
||||
path: '/workCenter/enterpriseStandardAnnul',
|
||||
name: 'EnterpriseStandardAnnul',
|
||||
|
||||
+18
-7
@@ -6,6 +6,7 @@
|
||||
<van-button type="info" @click="toMyTodo" style="margin-left: 0.1rem">我的待办</van-button>
|
||||
<br>
|
||||
<van-button type="primary" @click="goEnterpriseStandardInitChange">跳转企标计划立项、变更流程审批</van-button>
|
||||
<van-button type="danger" @click="goESRecheck">跳转企标复审流程</van-button>
|
||||
<van-button type="primary" @click="goESAnnul">跳转企标废止流程</van-button>
|
||||
<van-button type="danger" @click="goESSealSave">跳转企标封存流程</van-button>
|
||||
<van-button type="primary" @click="goESStartUse">跳转已封存企标启用流程</van-button>
|
||||
@@ -40,13 +41,23 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
goESRecheck () {
|
||||
this.$router.push({
|
||||
path: '/workCenter/enterpriseStandardRecheck',
|
||||
query: {
|
||||
processInstanceId: '580001',
|
||||
taskId: '580037',
|
||||
nodeId: 'sid-72303DAD-0B49-471B-828E-66602468BE44'
|
||||
}
|
||||
})
|
||||
},
|
||||
goESAnnul () {
|
||||
this.$router.push({
|
||||
path: '/workCenter/enterpriseStandardAnnul',
|
||||
query: {
|
||||
processInstanceId: '350016',
|
||||
taskId: '350059',
|
||||
nodeId: 'sid-B4157F9F-73E5-48F5-855D-AF87C0DB91C6'
|
||||
processInstanceId: '447681',
|
||||
taskId: '492542',
|
||||
nodeId: 'sid-9C90582D-F71F-4516-B54F-1E9F896C30D8'
|
||||
}
|
||||
})
|
||||
},
|
||||
@@ -55,8 +66,8 @@ export default {
|
||||
path: '/workCenter/enterpriseStandardSealSave',
|
||||
query: {
|
||||
processInstanceId: '467582',
|
||||
taskId: '467648',
|
||||
nodeId: 'sid-0BC5B3BC-ED99-4061-84B4-7320E25DE326'
|
||||
taskId: '492547',
|
||||
nodeId: 'sid-9C90582D-F71F-4516-B54F-1E9F896C30D8'
|
||||
}
|
||||
})
|
||||
},
|
||||
@@ -65,8 +76,8 @@ export default {
|
||||
path: '/workCenter/enterpriseStandardStartUse',
|
||||
query: {
|
||||
processInstanceId: '467650',
|
||||
taskId: '467716',
|
||||
nodeId: 'sid-0BC5B3BC-ED99-4061-84B4-7320E25DE326'
|
||||
taskId: '492552',
|
||||
nodeId: 'sid-9C90582D-F71F-4516-B54F-1E9F896C30D8'
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
@@ -100,7 +100,7 @@
|
||||
type="textarea"
|
||||
rows="1"
|
||||
autosize
|
||||
v-model="baseInfoForm.replacedByStandardNumber" />、
|
||||
v-model="baseInfoForm.replacedByStandardNumber" />
|
||||
<!-- 发布日期 -->
|
||||
<calendar-field
|
||||
:label="$t('esAnnul.releaseDate')"
|
||||
|
||||
+25
-25
@@ -731,22 +731,6 @@
|
||||
</template>
|
||||
{{ $t('turnTo') }}
|
||||
</van-button>
|
||||
<template v-if="![7, 8].includes(currentNode)">
|
||||
<!-- 同意 -->
|
||||
<van-button class="operation-common-btn" type="primary" @click="handleAgree">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="check" />
|
||||
</template>
|
||||
{{ $t('agree') }}
|
||||
</van-button>
|
||||
<!-- 驳回 -->
|
||||
<van-button class="operation-common-btn light-color-button" @click="handleReject">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="close" />
|
||||
</template>
|
||||
{{ $t('reject') }}
|
||||
</van-button>
|
||||
</template>
|
||||
<template v-if="[7, 8].includes(currentNode)">
|
||||
<!-- 保存 -->
|
||||
<van-button class="operation-common-btn light-color-button" @click="handleSave">
|
||||
@@ -763,15 +747,31 @@
|
||||
{{ $t('submit') }}
|
||||
</van-button>
|
||||
</template>
|
||||
</template>
|
||||
<template v-else>
|
||||
<!-- 确定 -->
|
||||
<van-button class="operation-common-btn" type="primary" @click="handleDetermine">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="check" />
|
||||
</template>
|
||||
{{ $t('determine') }}
|
||||
</van-button>
|
||||
<template v-else-if="currentNode === 10">
|
||||
<!-- 确定 -->
|
||||
<van-button class="operation-common-btn" type="primary" @click="handleDetermine">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="check" />
|
||||
</template>
|
||||
{{ $t('determine') }}
|
||||
</van-button>
|
||||
</template>
|
||||
<template v-else>
|
||||
<!-- 同意 -->
|
||||
<van-button class="operation-common-btn" type="primary" @click="handleAgree">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="check" />
|
||||
</template>
|
||||
{{ $t('agree') }}
|
||||
</van-button>
|
||||
<!-- 驳回 -->
|
||||
<van-button class="operation-common-btn light-color-button" @click="handleReject">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="close" />
|
||||
</template>
|
||||
{{ $t('reject') }}
|
||||
</van-button>
|
||||
</template>
|
||||
</template>
|
||||
</template>
|
||||
<select-user ref="selectUserRef" @selected-change="selectUserChange"></select-user>
|
||||
|
||||
@@ -0,0 +1,410 @@
|
||||
<template>
|
||||
<process-common-layout class="page-box" :processKey="ProcessKey.ES_RECHECK.value" :loading="loading">
|
||||
<template v-slot:process>
|
||||
<!-- 流程信息 -->
|
||||
<div class="process-part">
|
||||
<div class="process-part-title">{{ $t('processInformation') }}</div>
|
||||
<van-form
|
||||
ref="form"
|
||||
input-align="right"
|
||||
error-message-align="right"
|
||||
:readonly="readonly"
|
||||
>
|
||||
<!-- 流程名称 -->
|
||||
<van-field
|
||||
:label="$t('processName')"
|
||||
:placeholder="$t('pleaseEnter') + $t('processName')"
|
||||
readonly
|
||||
type="textarea"
|
||||
rows="1"
|
||||
autosize
|
||||
v-model="processInfoForm.prcName" />
|
||||
<!-- 截止日期 -->
|
||||
<calendar-field
|
||||
:label="$t('expirationDate')"
|
||||
v-model="processInfoForm.dueTime"
|
||||
type="date"
|
||||
readonly
|
||||
/>
|
||||
<!-- 流程说明 -->
|
||||
<van-field
|
||||
v-model="processInfoForm.prcMes"
|
||||
:label="$t('processExplain')"
|
||||
type="textarea"
|
||||
autosize
|
||||
disabled
|
||||
rows="2"
|
||||
:placeholder="$t('pleaseEnter')+$t('processExplain')"
|
||||
:border="false"
|
||||
input-align="left"
|
||||
class="vertical-form-item"/>
|
||||
</van-form>
|
||||
</div>
|
||||
<van-form
|
||||
ref="baseInfoFormRef"
|
||||
input-align="right"
|
||||
error-message-align="right"
|
||||
:readonly="readonly"
|
||||
>
|
||||
<!-- 业务基本信息 -->
|
||||
<div class="process-part">
|
||||
<div class="process-part-title">{{ $t('basicServiceInformation') }}</div>
|
||||
<!-- 企标编号 -->
|
||||
<van-field
|
||||
:label="$t('esInitChange.enterpriseStandardNum')"
|
||||
:placeholder="$t('pleaseEnter') + $t('esInitChange.enterpriseStandardNum')"
|
||||
readonly
|
||||
type="textarea"
|
||||
autosize
|
||||
rows="1"
|
||||
v-model="baseInfoForm.standardNumber" />
|
||||
<!-- 企标名称 -->
|
||||
<van-field
|
||||
:label="$t('esInitChange.enterpriseStandardName')"
|
||||
:placeholder="$t('pleaseEnter') + $t('esInitChange.enterpriseStandardName')"
|
||||
readonly
|
||||
type="textarea"
|
||||
rows="1"
|
||||
autosize
|
||||
v-model="baseInfoForm.standardName" />
|
||||
<!-- 主起草人 -->
|
||||
<van-field
|
||||
:label="$t('esInitChange.principalDrafter')"
|
||||
:placeholder="$t('pleaseEnter') + $t('esInitChange.principalDrafter')"
|
||||
readonly
|
||||
v-model="baseInfoForm.mainDraftingUser_dictText" />
|
||||
<!-- 主起草单位 -->
|
||||
<van-field
|
||||
:label="$t('esInitChange.mainDraftUnit')"
|
||||
:placeholder="$t('pleaseEnter') + $t('esInitChange.mainDraftUnit')"
|
||||
readonly
|
||||
v-model="baseInfoForm.mainDraftingUnit_dictText" />
|
||||
<!-- 发布日期 -->
|
||||
<calendar-field
|
||||
:label="$t('esAnnul.releaseDate')"
|
||||
v-model="baseInfoForm.releaseDate"
|
||||
:placeholder="$t('pleaseSelect') + $t('esAnnul.releaseDate')"
|
||||
type="date"
|
||||
readonly
|
||||
/>
|
||||
<!-- 实施日期 -->
|
||||
<calendar-field
|
||||
:label="$t('esAnnul.materialDate')"
|
||||
v-model="baseInfoForm.implementationDate"
|
||||
:placeholder="$t('pleaseSelect') + $t('esAnnul.materialDate')"
|
||||
type="date"
|
||||
readonly
|
||||
/>
|
||||
<!-- 复审日期 -->
|
||||
<van-field
|
||||
:label="$t('esRecheck.recheckDate')"
|
||||
:placeholder="$t('pleaseSelect') + $t('esRecheck.recheckDate')"
|
||||
readonly
|
||||
type="textarea"
|
||||
rows="1"
|
||||
autosize
|
||||
v-model="baseInfoForm.recheckDate" />
|
||||
<!-- 复审 -->
|
||||
<picker-field
|
||||
:rules="baseInfoRule.recheckAdvice"
|
||||
:label="$t('esRecheck.recheck')"
|
||||
:placeholder="$t('pleaseEnter') + $t('esRecheck.recheck')"
|
||||
:readonly="recheckAdviceReadonly"
|
||||
:columnData="recheckColumnData"
|
||||
v-model="baseInfoForm.recheckAdvice" />
|
||||
</div>
|
||||
</van-form>
|
||||
<!-- 流程审批信息 -->
|
||||
<div class="process-part">
|
||||
<div class="process-part-title">{{ $t('processApprovalInformation') }}</div>
|
||||
<van-form
|
||||
ref="processForm"
|
||||
input-align="right"
|
||||
error-message-align="right"
|
||||
:readonly="readonly">
|
||||
<!-- 备注 -->
|
||||
<van-field
|
||||
v-model="processInfoForm.commitText"
|
||||
:rules="processInfoRules.commitText"
|
||||
:label="$t('remark')"
|
||||
name="commitText"
|
||||
type="textarea"
|
||||
autosize
|
||||
rows="2"
|
||||
:placeholder="$t('pleaseEnter')+$t('remark')"
|
||||
:border="false"
|
||||
input-align="left"
|
||||
class="vertical-form-item"/>
|
||||
</van-form>
|
||||
</div>
|
||||
</template>
|
||||
<template v-slot:operation>
|
||||
<!-- 转办 -->
|
||||
<van-button class="operation-common-btn" @click="handleTurnTo">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="xunhuan" />
|
||||
</template>
|
||||
{{ $t('turnTo') }}
|
||||
</van-button>
|
||||
<!-- 节点2起草人填写意见, -->
|
||||
<template v-if="currentNode === 3">
|
||||
<!-- 保存 -->
|
||||
<van-button class="operation-common-btn light-color-button" @click="handleSave">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="baocun" />
|
||||
</template>
|
||||
{{ $t('save') }}
|
||||
</van-button>
|
||||
<!-- 提交 -->
|
||||
<van-button class="operation-common-btn" type="primary" @click="handleSubmit">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="check" />
|
||||
</template>
|
||||
{{ $t('submit') }}
|
||||
</van-button>
|
||||
</template>
|
||||
<template v-else>
|
||||
<!-- 同意 -->
|
||||
<van-button class="operation-common-btn" type="primary" @click="handleAgree">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="check" />
|
||||
</template>
|
||||
{{ $t('agree') }}
|
||||
</van-button>
|
||||
<!-- 驳回 -->
|
||||
<van-button class="operation-common-btn light-color-button" @click="handleReject">
|
||||
<template #icon>
|
||||
<van-icon class="iconfont" class-prefix="icon" name="close" />
|
||||
</template>
|
||||
{{ $t('reject') }}
|
||||
</van-button>
|
||||
</template>
|
||||
</template>
|
||||
<select-user ref="selectUserRef" @selected-change="selectUserChange"></select-user>
|
||||
</process-common-layout>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import PickerField from '@/components/PickerField'
|
||||
import ProcessCommonLayout from '@/components/ProcessCommonLayout'
|
||||
import SelectUser from '@/components/SelectUser'
|
||||
import CalendarField from '@/components/CalendarField'
|
||||
import { Recheck, ProcessKey, EsRecheckNodes } from '@/enums/commonEnums'
|
||||
import {
|
||||
enStandardRecheckSave,
|
||||
enStandardRecheckTurnTo,
|
||||
enStandardRecheckAgree,
|
||||
enStandardRecheckReject,
|
||||
enStandardRecheckGetDataById
|
||||
} from '@/api/api'
|
||||
|
||||
export default {
|
||||
name: 'EnterpriseStandardRecheck',
|
||||
components: { PickerField, ProcessCommonLayout, SelectUser, CalendarField },
|
||||
data () {
|
||||
return {
|
||||
ProcessKey,
|
||||
readonly: false,
|
||||
recheckAdviceReadonly: false, // 复审字段是否只读
|
||||
loading: false,
|
||||
recheckColumnData: [
|
||||
{ value: Recheck.STAND_GOOD.value, text: this.$t('esRecheck.standGood'), name: this.$t('esRecheck.standGood') },
|
||||
{ value: Recheck.REVISE.value, text: this.$t('esRecheck.revise'), name: this.$t('esRecheck.revise') },
|
||||
{ value: Recheck.ANNUL.value, text: this.$t('esRecheck.annul'), name: this.$t('esRecheck.annul') },
|
||||
{ value: Recheck.SEAL_SAVE.value, text: this.$t('esRecheck.sealSave'), name: this.$t('esRecheck.sealSave') }
|
||||
],
|
||||
processInfoForm: {}, // 流程信息表单
|
||||
// 流程信息校验
|
||||
processInfoRules: {
|
||||
commitText: [
|
||||
{ required: false, message: this.$t('pleaseEnter') + this.$t('remark') }
|
||||
]
|
||||
},
|
||||
baseInfoForm: {},
|
||||
baseInfoRule: {
|
||||
recheckAdvice: [
|
||||
{ required: true, message: this.$t('pleaseSelect') + this.$t('esRecheck.recheck') }
|
||||
]
|
||||
},
|
||||
currentNode: 1
|
||||
}
|
||||
},
|
||||
created () {
|
||||
this.initData()
|
||||
},
|
||||
mounted () {
|
||||
// 初始化流程节点
|
||||
const nodeId = this.$route.query.nodeId
|
||||
if (nodeId) {
|
||||
if (nodeId === EsRecheckNodes.standardizationSelectContact.value) {
|
||||
this.currentNode = 1
|
||||
} else if (nodeId === EsRecheckNodes.initiatorStart.value) {
|
||||
this.currentNode = 2
|
||||
} else if (nodeId === EsRecheckNodes.drafterEnterOption.value) {
|
||||
this.currentNode = 3
|
||||
} else if (nodeId === EsRecheckNodes.drafterMinisterApproval.value) {
|
||||
this.currentNode = 4
|
||||
} else if (nodeId === EsRecheckNodes.standardizationApproval.value) {
|
||||
this.currentNode = 5
|
||||
} else {
|
||||
// 预留加签节点
|
||||
this.currentNode = 999
|
||||
}
|
||||
}
|
||||
console.log(this.currentNode)
|
||||
if (this.currentNode === 3) {
|
||||
this.recheckAdviceReadonly = false
|
||||
} else {
|
||||
this.recheckAdviceReadonly = true
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 初始化数据
|
||||
initData () {
|
||||
this.loading = true
|
||||
enStandardRecheckGetDataById(this.$route.query.taskId).then(res => {
|
||||
if (res.success) {
|
||||
const result = res.result
|
||||
this.processInfoForm = result.common
|
||||
this.baseInfoForm = result.data
|
||||
} else {
|
||||
this.$message(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 转交
|
||||
handleTurnTo () {
|
||||
if (this.loading) return
|
||||
// 点击显示选人组件
|
||||
this.$refs.selectUserRef.open()
|
||||
},
|
||||
// 转交选完人的回调
|
||||
selectUserChange (userIds) {
|
||||
this.loading = true
|
||||
const param = {}
|
||||
param.userId = userIds
|
||||
param.taskId = this.$route.query.taskId
|
||||
enStandardRecheckTurnTo(param).then(res => {
|
||||
if (res.success) {
|
||||
this.$message(res.message)
|
||||
this.goBack()
|
||||
} else {
|
||||
this.$message(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 保存
|
||||
handleSave () {
|
||||
if (this.loading) return
|
||||
const param = {}
|
||||
param.common = Object.assign({}, this.processInfoForm)
|
||||
param.common.taskId = this.$route.query.taskId || null
|
||||
param.data = this.baseInfoForm
|
||||
this.loading = true
|
||||
// 保存到草稿
|
||||
enStandardRecheckSave(param).then(res => {
|
||||
if (res.success) {
|
||||
this.$message.success(res.message)
|
||||
this.goBack()
|
||||
} else {
|
||||
this.$message.warning(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 提交
|
||||
handleSubmit () {
|
||||
if (this.loading) return
|
||||
this.$refs.baseInfoFormRef.validate().then(() => {
|
||||
this.$refs.processForm.validate().then(() => {
|
||||
this.loading = true
|
||||
const param = {}
|
||||
param.common = Object.assign({}, this.processInfoForm)
|
||||
param.common.taskId = this.$route.query.taskId
|
||||
param.data = Object.assign({}, this.baseInfoForm)
|
||||
enStandardRecheckAgree(param).then(res => {
|
||||
if (res.success) {
|
||||
this.$message(res.message)
|
||||
this.goBack()
|
||||
} else {
|
||||
this.$message(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
}).catch((errorInfo) => {
|
||||
console.log(errorInfo)
|
||||
})
|
||||
}).catch((errorInfo) => {
|
||||
console.log(errorInfo)
|
||||
})
|
||||
},
|
||||
// 同意
|
||||
handleAgree () {
|
||||
if (this.loading) return
|
||||
this.processInfoRules.commitText[0].required = false
|
||||
if (!this.processInfoForm.commitText) {
|
||||
this.processInfoForm.commitText = '同意'
|
||||
}
|
||||
this.$refs.processForm.validate().then(() => {
|
||||
const param = {} // 需要传给后端的数据
|
||||
param.common = Object.assign({}, this.processInfoForm)
|
||||
param.common.taskId = this.$route.query.taskId
|
||||
this.loading = true
|
||||
enStandardRecheckAgree(param).then(res => {
|
||||
if (res.success) {
|
||||
this.$message(res.message)
|
||||
this.goBack()
|
||||
} else {
|
||||
this.$message(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
}).catch((errorInfo) => {
|
||||
console.log(errorInfo)
|
||||
})
|
||||
},
|
||||
// 驳回
|
||||
handleReject () {
|
||||
if (this.loading) return
|
||||
this.processInfoRules.commitText[0].required = true
|
||||
this.$refs.processForm.validate().then(() => {
|
||||
this.loading = true
|
||||
const param = {}
|
||||
param.common = Object.assign({}, this.processInfoForm)
|
||||
param.common.taskId = this.$route.query.taskId
|
||||
enStandardRecheckReject(param).then(res => {
|
||||
if (res.success) {
|
||||
this.$message(res.message)
|
||||
this.goBack()
|
||||
} else {
|
||||
this.$message(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
this.processInfoRules.commitText[0].required = false
|
||||
})
|
||||
}).catch((errorInfo) => {
|
||||
console.log(errorInfo)
|
||||
if (errorInfo.find(item => item.name === 'commitText')) {
|
||||
// 没通过校验的有备注,弹窗提示输入备注
|
||||
this.$message(this.$t('pleaseEnterRemarks'))
|
||||
}
|
||||
})
|
||||
},
|
||||
goBack () {
|
||||
this.$router.go(-1)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
||||
Reference in New Issue
Block a user