Vue3 重构:流程实例的创建的目录调整
This commit is contained in:
parent
7587acedb0
commit
ddd6bbbee1
@ -37,31 +37,20 @@
|
|||||||
/>
|
/>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-card class="box-card">
|
<!-- 流程图预览 -->
|
||||||
<div class="clearfix">
|
<ProcessInstanceBpmnViewer :bpmn-xml="bpmnXML" />
|
||||||
<span class="el-icon-picture-outline">流程图</span>
|
|
||||||
</div>
|
|
||||||
<!-- TODO 芋艿:待完成??? -->
|
|
||||||
<my-process-viewer
|
|
||||||
key="designer"
|
|
||||||
v-model="bpmnXML"
|
|
||||||
:value="bpmnXML"
|
|
||||||
v-bind="bpmnControlForm"
|
|
||||||
:prefix="bpmnControlForm.prefix"
|
|
||||||
/>
|
|
||||||
</el-card>
|
|
||||||
</div>
|
</div>
|
||||||
</ContentWrap>
|
</ContentWrap>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
import { DICT_TYPE } from '@/utils/dict'
|
||||||
// 业务相关的 import
|
// 业务相关的 import
|
||||||
import { allSchemas } from './process.create'
|
import { allSchemas } from './process.create'
|
||||||
import * as DefinitionApi from '@/api/bpm/definition'
|
import * as DefinitionApi from '@/api/bpm/definition'
|
||||||
import * as ProcessInstanceApi from '@/api/bpm/processInstance'
|
import * as ProcessInstanceApi from '@/api/bpm/processInstance'
|
||||||
import { setConfAndFields2 } from '@/utils/formCreate'
|
import { setConfAndFields2 } from '@/utils/formCreate'
|
||||||
import type { ApiAttrs } from '@form-create/element-ui/types/config'
|
import type { ApiAttrs } from '@form-create/element-ui/types/config'
|
||||||
import { DICT_TYPE } from '@/utils/dict'
|
import ProcessInstanceBpmnViewer from '../detail/ProcessInstanceBpmnViewer.vue'
|
||||||
|
|
||||||
const router = useRouter() // 路由
|
const router = useRouter() // 路由
|
||||||
const message = useMessage() // 消息
|
const message = useMessage() // 消息
|
||||||
|
|
||||||
@ -126,7 +115,6 @@ const submitForm = async (formData) => {
|
|||||||
})
|
})
|
||||||
// 提示
|
// 提示
|
||||||
message.success('发起流程成功')
|
message.success('发起流程成功')
|
||||||
// this.$tab.closeOpenPage();
|
|
||||||
router.go(-1)
|
router.go(-1)
|
||||||
} finally {
|
} finally {
|
||||||
fApi.value.btn.loading(false)
|
fApi.value.btn.loading(false)
|
||||||
@ -137,18 +125,4 @@ const submitForm = async (formData) => {
|
|||||||
|
|
||||||
// // BPMN 数据
|
// // BPMN 数据
|
||||||
const bpmnXML = ref(null)
|
const bpmnXML = ref(null)
|
||||||
const bpmnControlForm = ref({
|
|
||||||
prefix: 'flowable'
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
|
||||||
.my-process-designer {
|
|
||||||
height: calc(100vh - 200px);
|
|
||||||
}
|
|
||||||
|
|
||||||
.box-card {
|
|
||||||
width: 100%;
|
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
|
||||||
</style>
|
|
@ -40,9 +40,11 @@ const activityList = ref([]) // 任务列表
|
|||||||
|
|
||||||
/** 初始化 */
|
/** 初始化 */
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
activityList.value = await ActivityApi.getActivityList({
|
if (props.id) {
|
||||||
processInstanceId: props.id
|
activityList.value = await ActivityApi.getActivityList({
|
||||||
})
|
processInstanceId: props.id
|
||||||
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
<style>
|
<style>
|
||||||
|
Loading…
Reference in New Issue
Block a user