【缺陷修复】1、条件配置的表单字段必须为必填 2、配置方式 bug

pull/610/MERGE
jason 2024-12-06 22:40:37 +08:00
parent 8e4d91f43e
commit 9bdafb0f6f
1 changed files with 9 additions and 13 deletions

View File

@ -26,19 +26,13 @@
</div>
</template>
<div>
<div class="mb-3 font-size-16px" v-if="currentNode.defaultFlow"></div>
<div class="mb-3 font-size-16px" v-if="currentNode.defaultFlow"
>未满足其它条件时将进入此分支该分支不可编辑和删除</div
>
<div v-else>
<el-form
ref="formRef"
:model="currentNode"
:rules="formRules"
label-position="top"
>
<el-form ref="formRef" :model="currentNode" :rules="formRules" label-position="top">
<el-form-item label="配置方式" prop="conditionType">
<el-radio-group
v-model="currentNode.conditionType"
@change="changeConditionType"
>
<el-radio-group v-model="currentNode.conditionType" @change="changeConditionType">
<el-radio
v-for="(dict, index) in conditionConfigTypes"
:key="index"
@ -112,6 +106,7 @@
:key="index"
:label="item.title"
:value="item.field"
:disabled ="!item.required"
/>
</el-select>
</div>
@ -169,6 +164,7 @@ import {
} from '../consts'
import { getDefaultConditionNodeName } from '../utils'
import { useFormFields } from '../node'
import { BpmModelFormType } from '@/utils/constants'
const message = useMessage() //
defineOptions({
name: 'ConditionNodeConfig'
@ -177,8 +173,8 @@ const formType = inject<Ref<number>>('formType') // 表单类型
const conditionConfigTypes = computed(() => {
return CONDITION_CONFIG_TYPES.filter((item) => {
//
if (formType?.value !== 10) {
return item.value === ConditionType.RULE
if (formType?.value === BpmModelFormType.CUSTOM && item.value === ConditionType.RULE) {
return false
} else {
return true
}