fix : 修复细节
This commit is contained in:
@@ -60,3 +60,12 @@ export function addProcessDefinition(param) {
|
|||||||
data: param
|
data: param
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getTypeOption() {
|
||||||
|
return request({
|
||||||
|
url: "/workflow/process/definition/type/option",
|
||||||
|
method: "get",
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -119,6 +119,7 @@ const loadInitFrom = () => {
|
|||||||
let design = {
|
let design = {
|
||||||
processDefinitionKey: 'pro' + getRandomId(),
|
processDefinitionKey: 'pro' + getRandomId(),
|
||||||
deploymentName: "未命名表单",
|
deploymentName: "未命名表单",
|
||||||
|
processKey:'',
|
||||||
// logo: {
|
// logo: {
|
||||||
// icon: "el-icon-eleme",
|
// icon: "el-icon-eleme",
|
||||||
// background: "#1e90ff"
|
// background: "#1e90ff"
|
||||||
|
|||||||
@@ -1,13 +1,26 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-input v-model="processData.deploymentName" placeholder="请输入流程名称" />
|
<el-input v-model="processData.deploymentName" placeholder="请输入流程名称"/>
|
||||||
流程设置{{ processData.deploymentName }}
|
<div v-if="!processData.processDefinitionKey">
|
||||||
|
<el-select v-model="processData.processKey" placeholder="请选择流程环节">
|
||||||
|
<el-option v-for="item in optionList" :label="item.label" :value="item.value"/>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
<div v-else>
|
||||||
|
{{processData.processName}}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
流程设置{{ processData.deploymentName }}
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import {useProcessStore} from '@/stores/processStore.js'
|
import {useProcessStore} from '@/stores/processStore.js'
|
||||||
import {computed, defineExpose} from "vue";
|
import {computed, defineExpose} from "vue";
|
||||||
|
import {getTypeOption} from "@/api/workflow/process-definition";
|
||||||
|
|
||||||
const processStore = useProcessStore()
|
const processStore = useProcessStore()
|
||||||
|
|
||||||
|
const optionList = ref([])
|
||||||
|
|
||||||
const processData = computed(() => {
|
const processData = computed(() => {
|
||||||
return processStore.getDesign()
|
return processStore.getDesign()
|
||||||
})
|
})
|
||||||
@@ -18,9 +31,17 @@ const validate = () => {
|
|||||||
return []
|
return []
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const init = () => {
|
||||||
|
getTypeOption().then(res => {
|
||||||
|
console.log(res)
|
||||||
|
optionList.value = res.data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
defineExpose({
|
defineExpose({
|
||||||
validate
|
validate
|
||||||
})
|
})
|
||||||
|
init()
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user