diff --git a/src/components/Audit/InfoModal/index.vue b/src/components/Audit/InfoModal/index.vue index 428de54c..f104679a 100644 --- a/src/components/Audit/InfoModal/index.vue +++ b/src/components/Audit/InfoModal/index.vue @@ -246,7 +246,6 @@ import { getChildrenTree } from '@/api/demo/system'; import MapboxMap from '@/components/MapboxMaps/MapComponent.vue'; import { getGeom } from '@/api/sys/layerManagement'; import { typenameKey } from '@/views/demo/audit/util' -import { UpdateCaseInfoBySubject } from '@/api/audit/index' import axios from "axios"; const props = defineProps(['infoData','control','type','modalLoading']) @@ -364,22 +363,11 @@ const submitApi = () => { okText: '确认', cancelText: '取消', onOk: () => { - emits('changeLoading',true) - try{ - let params = { - ...props.infoData, - subject: props.type, - } - console.log(params) - UpdateCaseInfoBySubject(params).then(res => { - console.log('变更后返回数据',res) - if(res){ - emits('handleOk') - } - }) - } catch (error){ - emits('changeLoading',false) + let params = { + ...props.infoData, + subject: props.type, } + emits('handleOk',params) } }) diff --git a/src/views/demo/audit/audit/index.vue b/src/views/demo/audit/audit/index.vue index c66fdef1..084bfcbf 100644 --- a/src/views/demo/audit/audit/index.vue +++ b/src/views/demo/audit/audit/index.vue @@ -72,6 +72,7 @@ import { UpdateCaseNoBySubject, LoadCaseImportInfoLast, ExportapprovalCaseInfoShapefile, + UpdateCaseInfoBySubject } from '@/api/audit/index'; import { useRouter } from 'vue-router'; @@ -136,12 +137,13 @@ function handleAudit(record) { openModal.value = true }) } -const handleOk = async () => { +const handleOk = async (params) => { changeLoading(true) try { const { id, case_description } = infoData.value.info const checkValue = await GetDraft({id}) if(checkValue.process == null){ + await UpdateCaseInfoBySubject(params) let data = await getDetail({ code }); let content = JSON.parse(data.scheme.content); const currentNode = content.wfData.find((t) => t.type == 'bpmn:StartEvent');