Merge branch 'main' of http://123.132.248.154:10000/HC_YFZX/CaiYuanYiTiHua
commit
c7dddbd5be
|
|
@ -12,9 +12,9 @@ VITE_BUILD_COMPRESS = 'none'
|
||||||
|
|
||||||
# Basic interface address SPA
|
# Basic interface address SPA
|
||||||
#财源
|
#财源
|
||||||
VITE_GLOB_API_URL=http://192.168.10.102:9500
|
#VITE_GLOB_API_URL=http://192.168.10.102:9500
|
||||||
#基础框架
|
#基础框架
|
||||||
#VITE_GLOB_API_URL=http://192.168.10.102:9023
|
VITE_GLOB_API_URL=http://192.168.10.102:9023
|
||||||
|
|
||||||
# File upload address, optional
|
# File upload address, optional
|
||||||
# It can be forwarded by nginx or write the actual address directly
|
# It can be forwarded by nginx or write the actual address directly
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="my-form-viewer">
|
<div class="my-form-viewer">
|
||||||
{{ formColumns }}
|
|
||||||
<template v-if="tabsColumns.length > 1">
|
<template v-if="tabsColumns.length > 1">
|
||||||
<a-tabs style="width: 100%" @change="tabsChange">
|
<a-tabs style="width: 100%" @change="tabsChange">
|
||||||
<a-tab-pane v-for="(colItem, index) in tabsColumns" :tab="colItem.label" :key="index">
|
<a-tab-pane v-for="(colItem, index) in tabsColumns" :tab="colItem.label" :key="index">
|
||||||
|
|
@ -112,7 +111,16 @@
|
||||||
|
|
||||||
const keyValue = ref('');
|
const keyValue = ref('');
|
||||||
const FieldsValue = ref({});
|
const FieldsValue = ref({});
|
||||||
|
const [registerForm, { getFieldsValue, setFieldsValue, updateSchema, resetFields, validate }] =
|
||||||
|
useForm({
|
||||||
|
labelWidth: 100,
|
||||||
|
schemas: formColumns,
|
||||||
|
showActionButtonGroup: false,
|
||||||
|
baseColProps: { lg: 24, md: 24 },
|
||||||
|
});
|
||||||
async function getFormHistory() {
|
async function getFormHistory() {
|
||||||
|
console.log('getFormHistory');
|
||||||
|
|
||||||
const data = await LoadFormScheme({
|
const data = await LoadFormScheme({
|
||||||
schemeId: props.formVerison,
|
schemeId: props.formVerison,
|
||||||
});
|
});
|
||||||
|
|
@ -122,11 +130,13 @@
|
||||||
console.log(props.formConfig);
|
console.log(props.formConfig);
|
||||||
console.log("subTableColumns",subTableColumns)
|
console.log("subTableColumns",subTableColumns)
|
||||||
subTableDB.value = scheme.db;
|
subTableDB.value = scheme.db;
|
||||||
|
let disDetail = false;
|
||||||
scheme.formInfo.tabList.forEach((tabElement, index) => {
|
scheme.formInfo.tabList.forEach((tabElement, index) => {
|
||||||
tabElement.schemas.forEach((element) => {
|
tabElement.schemas.forEach((element) => {
|
||||||
if (element.field == props.formRelationId) {
|
if (element.field == props.formRelationId) {
|
||||||
keyValue.value = element.componentProps.fieldName;
|
keyValue.value = element.componentProps.fieldName;
|
||||||
getFormDetail();
|
getFormDetail();
|
||||||
|
disDetail = true;
|
||||||
}
|
}
|
||||||
//流程设置的表单显示和编辑与表单做关联
|
//流程设置的表单显示和编辑与表单做关联
|
||||||
props.formConfig.forEach((configElement) => {
|
props.formConfig.forEach((configElement) => {
|
||||||
|
|
@ -213,11 +223,22 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
formModalVisible.value = true;
|
formModalVisible.value = true;
|
||||||
resetFields();
|
setTimeout(() => {
|
||||||
|
resetFields();
|
||||||
|
console.log(props.flowFormData);
|
||||||
|
if (!disDetail) {
|
||||||
|
console.log('赋值赋值');
|
||||||
|
if (props.flowFormData) {
|
||||||
|
setFieldsValue(props.flowFormData);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, 10);
|
||||||
scrollValue.value = { x: (subTableColumns.value.length - 1) * 140, y: 400 };
|
scrollValue.value = { x: (subTableColumns.value.length - 1) * 140, y: 400 };
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
async function tabsChange(e) {
|
async function tabsChange(e) {
|
||||||
|
console.log('tabsChange');
|
||||||
|
|
||||||
formColumns.forEach((element) => {
|
formColumns.forEach((element) => {
|
||||||
element.show = false;
|
element.show = false;
|
||||||
if (element.parentValue == e) {
|
if (element.parentValue == e) {
|
||||||
|
|
@ -227,7 +248,6 @@
|
||||||
// 切换时保存值
|
// 切换时保存值
|
||||||
const values = await validate();
|
const values = await validate();
|
||||||
console.log(values);
|
console.log(values);
|
||||||
console.log(Object.keys(FieldsValue.value));
|
|
||||||
if (Object.keys(FieldsValue.value).length == 0) {
|
if (Object.keys(FieldsValue.value).length == 0) {
|
||||||
FieldsValue.value = values;
|
FieldsValue.value = values;
|
||||||
}
|
}
|
||||||
|
|
@ -247,14 +267,9 @@
|
||||||
});
|
});
|
||||||
console.log(FieldsValue.value);
|
console.log(FieldsValue.value);
|
||||||
}
|
}
|
||||||
const [registerForm, { getFieldsValue, setFieldsValue, updateSchema, resetFields, validate }] =
|
|
||||||
useForm({
|
|
||||||
labelWidth: 100,
|
|
||||||
schemas: formColumns,
|
|
||||||
showActionButtonGroup: false,
|
|
||||||
baseColProps: { lg: 24, md: 24 },
|
|
||||||
});
|
|
||||||
async function getFormDetail() {
|
async function getFormDetail() {
|
||||||
|
console.log('getFormDetail');
|
||||||
var instance = JSON.parse(props.instanceInfo);
|
var instance = JSON.parse(props.instanceInfo);
|
||||||
const querys = {
|
const querys = {
|
||||||
id: props.formVerison,
|
id: props.formVerison,
|
||||||
|
|
@ -283,28 +298,18 @@
|
||||||
}
|
}
|
||||||
async function getForm() {
|
async function getForm() {
|
||||||
try {
|
try {
|
||||||
console.log(getFieldsValue());
|
|
||||||
const values = await validate();
|
const values = await validate();
|
||||||
console.log(values);
|
|
||||||
console.log(FieldsValue.value);
|
|
||||||
for (const key in values) {
|
for (const key in values) {
|
||||||
for (const fieKey in FieldsValue.value) {
|
for (const fieKey in FieldsValue.value) {
|
||||||
if (key == fieKey) {
|
if (key == fieKey) {
|
||||||
if (values[key] != undefined) {
|
if (values[key] != undefined) {
|
||||||
FieldsValue.value[key] = values[key];
|
values[key] = FieldsValue.value[key];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
console.log(values);
|
|
||||||
console.log(FieldsValue.value);
|
|
||||||
let saveSubTableList = [];
|
let saveSubTableList = [];
|
||||||
let query;
|
let query = values;
|
||||||
if (Object.keys(FieldsValue.value).length == 0) {
|
|
||||||
query = values;
|
|
||||||
} else {
|
|
||||||
query = FieldsValue.value;
|
|
||||||
}
|
|
||||||
console.log(query);
|
console.log(query);
|
||||||
subTableList.value.forEach((item) => {
|
subTableList.value.forEach((item) => {
|
||||||
let emptyObj = {};
|
let emptyObj = {};
|
||||||
|
|
@ -327,12 +332,11 @@
|
||||||
getForm,
|
getForm,
|
||||||
});
|
});
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
if (props.flowFormData) {
|
||||||
|
FieldsValue.value = props.flowFormData;
|
||||||
|
}
|
||||||
if (props.formVerison) {
|
if (props.formVerison) {
|
||||||
getFormHistory();
|
getFormHistory();
|
||||||
} else {
|
|
||||||
setFieldsValue({
|
|
||||||
...props.flowFormData,
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
const addListItem = () => {
|
const addListItem = () => {
|
||||||
|
|
|
||||||
|
|
@ -71,13 +71,14 @@
|
||||||
<a-radio-button value="1" @click="handlePostClick(false)">岗位</a-radio-button>
|
<a-radio-button value="1" @click="handlePostClick(false)">岗位</a-radio-button>
|
||||||
<a-radio-button value="2" @click="handleRoleClick(false)">角色</a-radio-button>
|
<a-radio-button value="2" @click="handleRoleClick(false)">角色</a-radio-button>
|
||||||
<a-radio-button value="3" @click="handleAccountClick(false)">用户</a-radio-button>
|
<a-radio-button value="3" @click="handleAccountClick(false)">用户</a-radio-button>
|
||||||
<a-radio-button value="3" @click="handleLevelClick(false)">上下级</a-radio-button>
|
<a-radio-button value="4" @click="handleLevelClick(false)">上下级</a-radio-button>
|
||||||
<a-radio-button value="3" @click="handleNodeAuditorClick(false)"
|
<a-radio-button value="5" @click="handleNodeAuditorClick(false)"
|
||||||
>节点执行人</a-radio-button
|
>节点执行人</a-radio-button
|
||||||
>
|
>
|
||||||
<a-radio-button value="3" @click="handleAuditorSqlClick(false)"
|
<a-radio-button value="6" @click="handleAuditorSqlClick(false)"
|
||||||
>表字段</a-radio-button
|
>表字段</a-radio-button
|
||||||
>
|
>
|
||||||
|
<a-radio-button value="7" @click="handleSQLClick(false)">执行SQL</a-radio-button>
|
||||||
</a-radio-group>
|
</a-radio-group>
|
||||||
</a-space>
|
</a-space>
|
||||||
<a-table
|
<a-table
|
||||||
|
|
@ -486,6 +487,15 @@
|
||||||
>
|
>
|
||||||
<SelectForm ref="formRef" />
|
<SelectForm ref="formRef" />
|
||||||
</a-modal>
|
</a-modal>
|
||||||
|
<a-modal
|
||||||
|
width="40%"
|
||||||
|
v-model:open="data.SQLOpen"
|
||||||
|
title="添加SQL"
|
||||||
|
@ok="executeSQLHandleOk"
|
||||||
|
:destroyOnClose="true"
|
||||||
|
>
|
||||||
|
<ExecuteSQL ref="executeSQLRef" />
|
||||||
|
</a-modal>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
@ -494,7 +504,7 @@
|
||||||
import { SelectPos } from '@/components/SelectPos/index';
|
import { SelectPos } from '@/components/SelectPos/index';
|
||||||
import { SelectRole } from '@/components/SelectRole/index';
|
import { SelectRole } from '@/components/SelectRole/index';
|
||||||
import { SelectAccount } from '@/components/SelectAccount/index';
|
import { SelectAccount } from '@/components/SelectAccount/index';
|
||||||
import { AuditorLevel, AuditorSql, AuditorNode } from './page';
|
import { AuditorLevel, AuditorSql, AuditorNode, ExecuteSQL } from './page';
|
||||||
import { DeleteOutlined, PlusOutlined } from '@ant-design/icons-vue';
|
import { DeleteOutlined, PlusOutlined } from '@ant-design/icons-vue';
|
||||||
import { flowStore } from '@/store/modules/flow';
|
import { flowStore } from '@/store/modules/flow';
|
||||||
import { SelectForm } from '@/components/SelectForm/index';
|
import { SelectForm } from '@/components/SelectForm/index';
|
||||||
|
|
@ -601,6 +611,7 @@
|
||||||
formOpen: false,
|
formOpen: false,
|
||||||
formVerisons: [],
|
formVerisons: [],
|
||||||
formName: '',
|
formName: '',
|
||||||
|
SQLOpen: false,
|
||||||
});
|
});
|
||||||
|
|
||||||
watch(
|
watch(
|
||||||
|
|
@ -642,6 +653,8 @@
|
||||||
return '节点';
|
return '节点';
|
||||||
case '6':
|
case '6':
|
||||||
return '表字段';
|
return '表字段';
|
||||||
|
case '7':
|
||||||
|
return 'SQL';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -669,10 +682,14 @@
|
||||||
node.value.lookUsers = node.value.lookUsers.concat(addData2);
|
node.value.lookUsers = node.value.lookUsers.concat(addData2);
|
||||||
updateWfData('lookUsers');
|
updateWfData('lookUsers');
|
||||||
} else {
|
} else {
|
||||||
let addData = selectData.filter(
|
if (selectData.type == 7) {
|
||||||
(t) => node.value.auditUsers.findIndex((t2) => t2.id == t.id && t2.type == t.type) == -1,
|
node.value.auditUsers.push(selectData);
|
||||||
);
|
} else {
|
||||||
node.value.auditUsers = node.value.auditUsers.concat(addData);
|
let addData = selectData.filter(
|
||||||
|
(t) => node.value.auditUsers.findIndex((t2) => t2.id == t.id && t2.type == t.type) == -1,
|
||||||
|
);
|
||||||
|
node.value.auditUsers = node.value.auditUsers.concat(addData);
|
||||||
|
}
|
||||||
updateWfData('auditUsers');
|
updateWfData('auditUsers');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -739,6 +756,22 @@
|
||||||
data.nodeOpen = false;
|
data.nodeOpen = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// 执行SQL
|
||||||
|
const executeSQLRef = ref<any>();
|
||||||
|
|
||||||
|
function handleSQLClick(isLooker) {
|
||||||
|
nodeId.value = node.value.id;
|
||||||
|
data.isLooker = isLooker;
|
||||||
|
data.SQLOpen = true;
|
||||||
|
}
|
||||||
|
function executeSQLHandleOk() {
|
||||||
|
executeSQLRef.value.validateForm();
|
||||||
|
let obj = executeSQLRef.value.getForm();
|
||||||
|
if (obj.Sql != '') {
|
||||||
|
addTableData(obj);
|
||||||
|
data.SQLOpen = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 数据表字段选择
|
// 数据表字段选择
|
||||||
const sqlRef = ref<any>();
|
const sqlRef = ref<any>();
|
||||||
|
|
@ -889,7 +922,6 @@
|
||||||
obj.fieldName = element.componentProps.fieldName;
|
obj.fieldName = element.componentProps.fieldName;
|
||||||
fields.push(obj);
|
fields.push(obj);
|
||||||
} else if (['Grid'].includes(element.component) || element.type == 'subTable') {
|
} else if (['Grid'].includes(element.component) || element.type == 'subTable') {
|
||||||
console.log('gridtable');
|
|
||||||
fields.push({
|
fields.push({
|
||||||
field: `${element.field}_add`,
|
field: `${element.field}_add`,
|
||||||
label: `${element.label || '表格'}-添加按钮`,
|
label: `${element.label || '表格'}-添加按钮`,
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
export { default as AuditorLevel } from './src/auditorLevel.vue';
|
export { default as AuditorLevel } from './src/auditorLevel.vue';
|
||||||
export { default as AuditorSql } from './src/auditorSql.vue';
|
export { default as AuditorSql } from './src/auditorSql.vue';
|
||||||
export { default as AuditorNode } from './src/auditorNode.vue';
|
export { default as AuditorNode } from './src/auditorNode.vue';
|
||||||
|
export { default as ExecuteSQL } from './src/executeSQL.vue';
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,56 @@
|
||||||
|
<template>
|
||||||
|
<div class="l-from-body">
|
||||||
|
<a-form
|
||||||
|
ref="formRef"
|
||||||
|
:rules="data.rules"
|
||||||
|
:model="data.formData"
|
||||||
|
labelAlign="left"
|
||||||
|
:label-col="labelCol"
|
||||||
|
:wrapper-col="wrapperCol"
|
||||||
|
>
|
||||||
|
<a-form-item label="SQL语句" name="Sql">
|
||||||
|
<a-textarea v-model:value="data.formData.Sql" placeholder="SQL语句" :rows="4" />
|
||||||
|
</a-form-item>
|
||||||
|
</a-form>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { reactive, ref } from 'vue';
|
||||||
|
|
||||||
|
const formRef = ref<any>();
|
||||||
|
const labelCol = { span: 7 };
|
||||||
|
const wrapperCol = { span: 17 };
|
||||||
|
const data = reactive({
|
||||||
|
formData: {
|
||||||
|
Sql: '',
|
||||||
|
type: '7',
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
Sql: [{ required: true, message: '请输入SQL语句' }],
|
||||||
|
},
|
||||||
|
});
|
||||||
|
function validateForm() {
|
||||||
|
formRef.value
|
||||||
|
.validate()
|
||||||
|
.then(async () => {
|
||||||
|
return true;
|
||||||
|
})
|
||||||
|
.catch(async () => {
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function getForm() {
|
||||||
|
let rows = data.formData;
|
||||||
|
rows.name = data.formData.Sql;
|
||||||
|
return rows;
|
||||||
|
}
|
||||||
|
defineExpose({
|
||||||
|
getForm,
|
||||||
|
validateForm,
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
.l-from-body {
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
@ -94,7 +94,7 @@
|
||||||
/>
|
/>
|
||||||
</FormItem>
|
</FormItem>
|
||||||
<FormItem label="脚本" v-if="['Button'].includes(formConfig.currentItem.component)">
|
<FormItem label="脚本" v-if="['Button'].includes(formConfig.currentItem.component)">
|
||||||
<a-button type="primary" size="mini" @click="handleButtonClick"> 点击脚本 </a-button>
|
<a-button size="mini" @click="handleButtonClick"> 点击脚本 </a-button>
|
||||||
</FormItem>
|
</FormItem>
|
||||||
|
|
||||||
<FormItem
|
<FormItem
|
||||||
|
|
@ -283,9 +283,9 @@
|
||||||
watch(
|
watch(
|
||||||
() => formConfig.value.currentItem?.field,
|
() => formConfig.value.currentItem?.field,
|
||||||
(_newValue, oldValue) => {
|
(_newValue, oldValue) => {
|
||||||
currentIndex.value = formConfig.value.schemas.findIndex(
|
// currentIndex.value = formConfig.value.schemas.findIndex(
|
||||||
(element) => element.field === formConfig.value.currentItem.field,
|
// (element) => element.field === formConfig.value.currentItem.field,
|
||||||
);
|
// );
|
||||||
formConfig.value.schemas &&
|
formConfig.value.schemas &&
|
||||||
formItemsForEach(formConfig.value.schemas, (item) => {
|
formItemsForEach(formConfig.value.schemas, (item) => {
|
||||||
if (item.link) {
|
if (item.link) {
|
||||||
|
|
@ -310,9 +310,9 @@
|
||||||
() => formConfig.value.currentItem && formConfig.value.currentItem.component,
|
() => formConfig.value.currentItem && formConfig.value.currentItem.component,
|
||||||
() => {
|
() => {
|
||||||
// console.log(formConfig.value);
|
// console.log(formConfig.value);
|
||||||
currentIndex.value = formConfig.value.schemas.findIndex(
|
// currentIndex.value = formConfig.value.schemas.findIndex(
|
||||||
(element) => element.field === formConfig.value.currentItem.field,
|
// (element) => element.field === formConfig.value.currentItem.field,
|
||||||
);
|
// );
|
||||||
allOptions.value = [];
|
allOptions.value = [];
|
||||||
baseComponentControlAttrs.forEach((item) => {
|
baseComponentControlAttrs.forEach((item) => {
|
||||||
item.category = 'control';
|
item.category = 'control';
|
||||||
|
|
@ -378,7 +378,8 @@
|
||||||
let arr = allOptions.value.filter((item) => {
|
let arr = allOptions.value.filter((item) => {
|
||||||
return item.category == 'input';
|
return item.category == 'input';
|
||||||
});
|
});
|
||||||
|
console.log(arr);
|
||||||
|
console.log(currentIndex.value);
|
||||||
arr.forEach((item) => {
|
arr.forEach((item) => {
|
||||||
if (item.name == 'dataTable') {
|
if (item.name == 'dataTable') {
|
||||||
if (currentIndex.value == -1) {
|
if (currentIndex.value == -1) {
|
||||||
|
|
|
||||||
|
|
@ -76,7 +76,6 @@
|
||||||
<a-space direction="vertical">
|
<a-space direction="vertical">
|
||||||
<a-button
|
<a-button
|
||||||
v-model:value="formConfig.beforeSetData"
|
v-model:value="formConfig.beforeSetData"
|
||||||
type="primary"
|
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleBtnClick('beforeSetData')"
|
@click="handleBtnClick('beforeSetData')"
|
||||||
>
|
>
|
||||||
|
|
@ -84,7 +83,6 @@
|
||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-model:value="formConfig.afterValidateForm"
|
v-model:value="formConfig.afterValidateForm"
|
||||||
type="primary"
|
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleBtnClick('afterValidateForm')"
|
@click="handleBtnClick('afterValidateForm')"
|
||||||
>
|
>
|
||||||
|
|
@ -92,7 +90,6 @@
|
||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-model:value="formConfig.afterSaveEvent"
|
v-model:value="formConfig.afterSaveEvent"
|
||||||
type="primary"
|
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleBtnClick('afterSaveEvent')"
|
@click="handleBtnClick('afterSaveEvent')"
|
||||||
>
|
>
|
||||||
|
|
@ -100,7 +97,6 @@
|
||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-model:value="formConfig.changeDataEvent"
|
v-model:value="formConfig.changeDataEvent"
|
||||||
type="primary"
|
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleBtnClick('changeDataEvent')"
|
@click="handleBtnClick('changeDataEvent')"
|
||||||
>
|
>
|
||||||
|
|
@ -209,11 +205,9 @@
|
||||||
}
|
}
|
||||||
// 脚本窗口提交
|
// 脚本窗口提交
|
||||||
function handleSubmit() {
|
function handleSubmit() {
|
||||||
if (formContent.value.indexOf('=>') != -1) {
|
if (!checkChinese(formContent.value)) {
|
||||||
// 表示是老版本,提示其修改为新的版本
|
message.warning('脚本的代码部分不能含有中文字符!');
|
||||||
message.warning('脚本没有更新为最新的版本!');
|
|
||||||
return;
|
return;
|
||||||
// } else if() {
|
|
||||||
}
|
}
|
||||||
if (btnClickEvent_now) {
|
if (btnClickEvent_now) {
|
||||||
if (btnClickEvent_now == 'beforeSetData') {
|
if (btnClickEvent_now == 'beforeSetData') {
|
||||||
|
|
@ -228,6 +222,33 @@
|
||||||
}
|
}
|
||||||
closeModal();
|
closeModal();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function checkChinese(str) {
|
||||||
|
// 分割字符串为多行
|
||||||
|
const lines = str.split('\n');
|
||||||
|
let flag = true;
|
||||||
|
|
||||||
|
// 遍历每一行
|
||||||
|
for (const line of lines) {
|
||||||
|
// 先检查并移除console.log及其后的内容
|
||||||
|
const consoleIndex = line.indexOf('console.log');
|
||||||
|
let partToCheck = line;
|
||||||
|
if (consoleIndex !== -1) {
|
||||||
|
partToCheck = line.substring(0, consoleIndex).trim(); // 移除console.log及其后的内容,并去掉前导空格
|
||||||
|
}
|
||||||
|
|
||||||
|
// 再检查'//'
|
||||||
|
const commentIndex = partToCheck.indexOf('//');
|
||||||
|
// 如果有'//',检查'//'前的部分并去掉前导空格;如果没有,保留原部分
|
||||||
|
partToCheck =
|
||||||
|
commentIndex !== -1 ? partToCheck.substring(0, commentIndex).trim() : partToCheck;
|
||||||
|
// 代码部分不能含有中文字符
|
||||||
|
if (!/[\u4e00-\u9fa5]/.test(partToCheck)) {
|
||||||
|
flag = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return flag;
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,12 @@
|
||||||
<template v-if="tabsColumns.length > 1">
|
<template v-if="tabsColumns.length > 1">
|
||||||
<a-tabs style="width: 100%" @change="tabsChange">
|
<a-tabs style="width: 100%" @change="tabsChange">
|
||||||
<a-tab-pane v-for="(colItem, index) in tabsColumns" :tab="colItem.label" :key="index">
|
<a-tab-pane v-for="(colItem, index) in tabsColumns" :tab="colItem.label" :key="index">
|
||||||
<BasicForm ref="myDataBaseFormRef" @register="registerForm" />
|
<BasicForm
|
||||||
|
ref="myDataBaseFormRef"
|
||||||
|
@register="registerForm"
|
||||||
|
@click="codeClickFunction('beforeSetData', beforeSetData)"
|
||||||
|
@change="codeClickFunction('changeDataEvent', changeDataEvent)"
|
||||||
|
/>
|
||||||
</a-tab-pane>
|
</a-tab-pane>
|
||||||
</a-tabs>
|
</a-tabs>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -23,6 +28,8 @@
|
||||||
ref="myDataBaseFormRef"
|
ref="myDataBaseFormRef"
|
||||||
@register="registerForm"
|
@register="registerForm"
|
||||||
v-if="formModalVisible && tabsColumns.length < 1"
|
v-if="formModalVisible && tabsColumns.length < 1"
|
||||||
|
@click="codeClickFunction('beforeSetData', beforeSetData)"
|
||||||
|
@change="codeClickFunction('changeDataEvent', changeDataEvent)"
|
||||||
/>
|
/>
|
||||||
<template v-for="(item, index) in cardLayout" :key="index">
|
<template v-for="(item, index) in cardLayout" :key="index">
|
||||||
<a-row style="width: 100%">
|
<a-row style="width: 100%">
|
||||||
|
|
@ -44,6 +51,20 @@
|
||||||
</a-col>
|
</a-col>
|
||||||
</a-row>
|
</a-row>
|
||||||
</template>
|
</template>
|
||||||
|
<template v-for="(item, index) in buttonLayout" :key="index">
|
||||||
|
<a-row style="width: 100%">
|
||||||
|
<a-col :span="item?.colProps?.span || 24" style="padding: 10px">
|
||||||
|
<a-button
|
||||||
|
:type="item.componentProps.type"
|
||||||
|
:shape="item.componentProps.shape"
|
||||||
|
:size="item.componentProps.size"
|
||||||
|
@click="codeClickFunction('codeClick', item.componentProps.clickCode)"
|
||||||
|
>
|
||||||
|
{{ item.label }}
|
||||||
|
</a-button>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</template>
|
||||||
<a-table
|
<a-table
|
||||||
class="sub-table"
|
class="sub-table"
|
||||||
:columns="subTableColumns"
|
:columns="subTableColumns"
|
||||||
|
|
@ -86,6 +107,7 @@
|
||||||
import { v4 as uuidv4 } from 'uuid';
|
import { v4 as uuidv4 } from 'uuid';
|
||||||
import FormItem from './ShowFormModal/FormItem/index.vue';
|
import FormItem from './ShowFormModal/FormItem/index.vue';
|
||||||
import CallModalFormItem from './CallModalFormItem/index.vue';
|
import CallModalFormItem from './CallModalFormItem/index.vue';
|
||||||
|
|
||||||
// import FormRender from '@/views/demo/form-design/components/VFormCreate/components/FormRender.vue';
|
// import FormRender from '@/views/demo/form-design/components/VFormCreate/components/FormRender.vue';
|
||||||
|
|
||||||
const emit = defineEmits(['success']);
|
const emit = defineEmits(['success']);
|
||||||
|
|
@ -112,8 +134,21 @@
|
||||||
const scrollValue = ref();
|
const scrollValue = ref();
|
||||||
const cardLayout = ref([]);
|
const cardLayout = ref([]);
|
||||||
const createOrModifyList = ref([]);
|
const createOrModifyList = ref([]);
|
||||||
|
// 按钮
|
||||||
|
const buttonLayout = ref([]);
|
||||||
|
// 脚本
|
||||||
|
const beforeSetData = ref('');
|
||||||
|
const afterValidateForm = ref('');
|
||||||
|
const afterSaveEvent = ref('');
|
||||||
|
const changeDataEvent = ref('');
|
||||||
const [registerModal, { setModalProps, closeModal }] = useModalInner((data: any) => {
|
const [registerModal, { setModalProps, closeModal }] = useModalInner((data: any) => {
|
||||||
console.log('daaaaa', data);
|
console.log('daaaaa', data);
|
||||||
|
// 脚本
|
||||||
|
beforeSetData.value = data?.beforeSetData;
|
||||||
|
afterValidateForm.value = data?.afterValidateForm;
|
||||||
|
afterSaveEvent.value = data?.afterSaveEvent;
|
||||||
|
changeDataEvent.value = data?.changeDataEvent;
|
||||||
|
|
||||||
isUpdate.value = !!data?.isUpdate;
|
isUpdate.value = !!data?.isUpdate;
|
||||||
isDetail.value = !!data?.isDetail;
|
isDetail.value = !!data?.isDetail;
|
||||||
const arr: FormSchema[] = [];
|
const arr: FormSchema[] = [];
|
||||||
|
|
@ -133,6 +168,9 @@
|
||||||
if (opt.component === 'Card') {
|
if (opt.component === 'Card') {
|
||||||
cardLayout.value.push(opt);
|
cardLayout.value.push(opt);
|
||||||
}
|
}
|
||||||
|
if (opt.component === 'Button') {
|
||||||
|
buttonLayout.value.push(opt);
|
||||||
|
}
|
||||||
if (['createuser', 'createtime', 'modifyuser', 'modifytime'].includes(opt.type)) {
|
if (['createuser', 'createtime', 'modifyuser', 'modifytime'].includes(opt.type)) {
|
||||||
createOrModifyList.value.push(opt);
|
createOrModifyList.value.push(opt);
|
||||||
}
|
}
|
||||||
|
|
@ -163,6 +201,20 @@
|
||||||
scrollValue.value = { x: (subTableColumns.value.length - 1) * 140, y: 300 };
|
scrollValue.value = { x: (subTableColumns.value.length - 1) * 140, y: 300 };
|
||||||
subTableData.value = tableData;
|
subTableData.value = tableData;
|
||||||
}
|
}
|
||||||
|
if (opt.columns) {
|
||||||
|
opt.columns.forEach((itemColumn) => {
|
||||||
|
itemColumn.children.forEach((itemColumnChild) => {
|
||||||
|
console.log('itemColumnChild', itemColumnChild);
|
||||||
|
itemColumnChild.itemProps.hidden = true;
|
||||||
|
if (index == 0) {
|
||||||
|
itemColumnChild.itemProps.hidden = false;
|
||||||
|
}
|
||||||
|
arr.push(itemColumnChild);
|
||||||
|
val.children.push(itemColumnChild);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
opt.itemProps.hidden = true;
|
opt.itemProps.hidden = true;
|
||||||
if (index == 0) {
|
if (index == 0) {
|
||||||
opt.itemProps.hidden = false;
|
opt.itemProps.hidden = false;
|
||||||
|
|
@ -173,6 +225,7 @@
|
||||||
});
|
});
|
||||||
tabsColumns.value = item.componentProps.options;
|
tabsColumns.value = item.componentProps.options;
|
||||||
console.log('tabsColumns', tabsColumns.value);
|
console.log('tabsColumns', tabsColumns.value);
|
||||||
|
console.log('formColumns', formColumns.value);
|
||||||
} else {
|
} else {
|
||||||
if (item.rules !== undefined) {
|
if (item.rules !== undefined) {
|
||||||
let myString = item.rules[0].pattern;
|
let myString = item.rules[0].pattern;
|
||||||
|
|
@ -188,6 +241,9 @@
|
||||||
if (item.component === 'Card') {
|
if (item.component === 'Card') {
|
||||||
cardLayout.value.push(item);
|
cardLayout.value.push(item);
|
||||||
}
|
}
|
||||||
|
if (item.component === 'Button') {
|
||||||
|
buttonLayout.value.push(item);
|
||||||
|
}
|
||||||
if (['createuser', 'createtime', 'modifyuser', 'modifytime'].includes(item.type)) {
|
if (['createuser', 'createtime', 'modifyuser', 'modifytime'].includes(item.type)) {
|
||||||
createOrModifyList.value.push(item);
|
createOrModifyList.value.push(item);
|
||||||
}
|
}
|
||||||
|
|
@ -272,14 +328,14 @@
|
||||||
console.log('eee', e);
|
console.log('eee', e);
|
||||||
console.log('tabsColumns', tabsColumns);
|
console.log('tabsColumns', tabsColumns);
|
||||||
const columns: FormSchema[] = [];
|
const columns: FormSchema[] = [];
|
||||||
// tabsColumns.value.forEach((item) => {
|
tabsColumns.value.forEach((item) => {
|
||||||
// item.children.forEach((val) => {
|
item.children.forEach((val) => {
|
||||||
// val.itemProps.hidden = true;
|
val.itemProps.hidden = true;
|
||||||
// });
|
});
|
||||||
// });
|
});
|
||||||
// tabsColumns.value[e].children.forEach((item) => {
|
tabsColumns.value[e].children.forEach((item) => {
|
||||||
// item.itemProps.hidden = false;
|
item.itemProps.hidden = false;
|
||||||
// });
|
});
|
||||||
tabsColumns.value.forEach((item) => {
|
tabsColumns.value.forEach((item) => {
|
||||||
item.children.forEach((val) => {
|
item.children.forEach((val) => {
|
||||||
columns.push(val);
|
columns.push(val);
|
||||||
|
|
@ -287,10 +343,16 @@
|
||||||
});
|
});
|
||||||
console.log('columns', columns);
|
console.log('columns', columns);
|
||||||
console.log('formColumns', formColumns);
|
console.log('formColumns', formColumns);
|
||||||
|
const obj = getFieldsValue();
|
||||||
|
console.log('values', getFieldsValue());
|
||||||
|
// resetFields();
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
updateSchema(columns);
|
updateSchema(columns);
|
||||||
console.log('values', getFieldsValue());
|
resetFields();
|
||||||
}, 100);
|
}, 100);
|
||||||
|
setTimeout(() => {
|
||||||
|
setFieldsValue(obj);
|
||||||
|
}, 500);
|
||||||
}
|
}
|
||||||
function generateUniqueDigits(length: number): number[] {
|
function generateUniqueDigits(length: number): number[] {
|
||||||
const digits = new Set<number>();
|
const digits = new Set<number>();
|
||||||
|
|
@ -328,18 +390,20 @@
|
||||||
async function ModalSureClick() {
|
async function ModalSureClick() {
|
||||||
try {
|
try {
|
||||||
const values = await validate();
|
const values = await validate();
|
||||||
|
// 添加校验后脚本
|
||||||
|
codeClickFunction('afterValidateForm', afterValidateForm.value);
|
||||||
console.log('values', values);
|
console.log('values', values);
|
||||||
let query = values;
|
let query = values;
|
||||||
let saveSubTableList = [];
|
let saveSubTableList = [];
|
||||||
// subTableList.value.forEach((item) => {
|
subTableList.value.forEach((item) => {
|
||||||
// let emptyObj = {};
|
let emptyObj = {};
|
||||||
// for (const key in item) {
|
for (const key in item) {
|
||||||
// if (key === 'key') continue;
|
if (key === 'key') continue;
|
||||||
// emptyObj[key] = item[key];
|
emptyObj[key] = item[key];
|
||||||
// }
|
}
|
||||||
// saveSubTableList.push(emptyObj);
|
saveSubTableList.push(emptyObj);
|
||||||
// });
|
});
|
||||||
// query[subTableId.value] = JSON.stringify(saveSubTableList);
|
query[subTableId.value] = JSON.stringify(saveSubTableList);
|
||||||
let params: any = {
|
let params: any = {
|
||||||
schemeId: primaryQuery.value.id,
|
schemeId: primaryQuery.value.id,
|
||||||
isUpdate: isUpdate.value,
|
isUpdate: isUpdate.value,
|
||||||
|
|
@ -376,6 +440,9 @@
|
||||||
}
|
}
|
||||||
} finally {
|
} finally {
|
||||||
setModalProps({ confirmLoading: false });
|
setModalProps({ confirmLoading: false });
|
||||||
|
// 添加保存后脚本
|
||||||
|
codeClickFunction('afterSaveEvent', afterSaveEvent.value);
|
||||||
|
closeFunc();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
async function handleCreateFlow(processId) {
|
async function handleCreateFlow(processId) {
|
||||||
|
|
@ -399,7 +466,37 @@
|
||||||
return createMessage.error('保存草稿失败');
|
return createMessage.error('保存草稿失败');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// 脚本执行方法
|
||||||
|
async function codeClickFunction(code, codeClick) {
|
||||||
|
try {
|
||||||
|
// 动态导入utils模块
|
||||||
|
const { utils } = await import('./utils');
|
||||||
|
eval(codeClick);
|
||||||
|
} catch (e) {
|
||||||
|
switch (code) {
|
||||||
|
case 'codeClick':
|
||||||
|
createMessage.success('【按钮组件脚本】错误:' + e);
|
||||||
|
break;
|
||||||
|
case 'beforeSetData':
|
||||||
|
createMessage.success('【添加赋值前脚本】错误:' + e);
|
||||||
|
break;
|
||||||
|
case 'afterValidateForm':
|
||||||
|
createMessage.success('【添加校验后脚本】错误:' + e);
|
||||||
|
break;
|
||||||
|
case 'afterSaveEvent':
|
||||||
|
createMessage.success('【添加保存后脚本】错误:' + e);
|
||||||
|
break;
|
||||||
|
case 'changeDataEvent':
|
||||||
|
createMessage.success('【添加数据改变脚本】错误:' + e);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
createMessage.success('【未知脚本】错误:' + e);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
const closeFunc = () => {
|
const closeFunc = () => {
|
||||||
|
buttonLayout.value = [];
|
||||||
cardLayout.value = [];
|
cardLayout.value = [];
|
||||||
createOrModifyList.value = [];
|
createOrModifyList.value = [];
|
||||||
return true;
|
return true;
|
||||||
|
|
|
||||||
|
|
@ -320,7 +320,7 @@
|
||||||
let chlidKey: any = ref();
|
let chlidKey: any = ref();
|
||||||
if (val.type === 'chlid') {
|
if (val.type === 'chlid') {
|
||||||
getOutKeyList(params).then((res: Recordable) => {
|
getOutKeyList(params).then((res: Recordable) => {
|
||||||
console.log('ressss', res)
|
console.log('ressss', res);
|
||||||
if (res[0]) {
|
if (res[0]) {
|
||||||
res[0].db_codecolumnsList.forEach((item) => {
|
res[0].db_codecolumnsList.forEach((item) => {
|
||||||
if (item.isPrimaryKey == 1) {
|
if (item.isPrimaryKey == 1) {
|
||||||
|
|
@ -331,7 +331,7 @@
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
console.log('chlidKey', chlidKey.value)
|
console.log('chlidKey', chlidKey.value);
|
||||||
}, 500);
|
}, 500);
|
||||||
|
|
||||||
if (rel.formInfo.schemas.length > 1) {
|
if (rel.formInfo.schemas.length > 1) {
|
||||||
|
|
@ -407,6 +407,10 @@
|
||||||
},
|
},
|
||||||
activeKey: 1,
|
activeKey: 1,
|
||||||
status: 'Add',
|
status: 'Add',
|
||||||
|
beforeSetData: '',
|
||||||
|
afterValidateForm: '',
|
||||||
|
afterSaveEvent: '',
|
||||||
|
changeDataEvent: '',
|
||||||
});
|
});
|
||||||
|
|
||||||
const handleClickForm = (status) => {
|
const handleClickForm = (status) => {
|
||||||
|
|
@ -430,7 +434,7 @@
|
||||||
if (rows.length > 0) {
|
if (rows.length > 0) {
|
||||||
query.value.keyValue = rows[0][str.value];
|
query.value.keyValue = rows[0][str.value];
|
||||||
}
|
}
|
||||||
console.log('config', config)
|
console.log('config', config);
|
||||||
switch (status) {
|
switch (status) {
|
||||||
case 'Add':
|
case 'Add':
|
||||||
btnList.value.forEach((element) => {
|
btnList.value.forEach((element) => {
|
||||||
|
|
@ -447,6 +451,10 @@
|
||||||
query: query.value,
|
query: query.value,
|
||||||
addParams: addParamsArr.value,
|
addParams: addParamsArr.value,
|
||||||
btnList: btnList.value,
|
btnList: btnList.value,
|
||||||
|
beforeSetData: config.beforeSetData,
|
||||||
|
afterValidateForm: config.afterValidateForm,
|
||||||
|
afterSaveEvent: config.afterSaveEvent,
|
||||||
|
changeDataEvent: config.changeDataEvent,
|
||||||
};
|
};
|
||||||
if (haveMap.value) {
|
if (haveMap.value) {
|
||||||
showFormModalData.value = toProps;
|
showFormModalData.value = toProps;
|
||||||
|
|
@ -481,6 +489,10 @@
|
||||||
recordChildren: formData.value,
|
recordChildren: formData.value,
|
||||||
query: query.value,
|
query: query.value,
|
||||||
btnList: btnList.value,
|
btnList: btnList.value,
|
||||||
|
beforeSetData: config.beforeSetData,
|
||||||
|
afterValidateForm: config.afterValidateForm,
|
||||||
|
afterSaveEvent: config.afterSaveEvent,
|
||||||
|
changeDataEvent: config.changeDataEvent,
|
||||||
};
|
};
|
||||||
if (haveMap.value) {
|
if (haveMap.value) {
|
||||||
showFormModalData.value = toProps;
|
showFormModalData.value = toProps;
|
||||||
|
|
@ -609,6 +621,7 @@
|
||||||
layerFields: {},
|
layerFields: {},
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
console.log('columnObj', columnObj)
|
||||||
paramsId.value = res.formScheme.id;
|
paramsId.value = res.formScheme.id;
|
||||||
btnList.value = columnObj.table.btns;
|
btnList.value = columnObj.table.btns;
|
||||||
if (columnObj.table.columns) {
|
if (columnObj.table.columns) {
|
||||||
|
|
@ -648,6 +661,11 @@
|
||||||
unref(asyncExpandTreeRef)?.expandAll(true);
|
unref(asyncExpandTreeRef)?.expandAll(true);
|
||||||
});
|
});
|
||||||
formConfig.value.schemas = formObj.formInfo.schemas;
|
formConfig.value.schemas = formObj.formInfo.schemas;
|
||||||
|
// 表单脚本
|
||||||
|
formConfig.value.beforeSetData = formObj.formInfo.beforeSetData;
|
||||||
|
formConfig.value.afterValidateForm = formObj.formInfo.afterValidateForm;
|
||||||
|
formConfig.value.afterSaveEvent = formObj.formInfo.afterSaveEvent;
|
||||||
|
formConfig.value.changeDataEvent = formObj.formInfo.changeDataEvent;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
//弹窗确定后返回调用
|
//弹窗确定后返回调用
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
// utils.ts
|
||||||
|
export const utils = {
|
||||||
|
add: function add(a: number, b: number): number {
|
||||||
|
return a + b;
|
||||||
|
},
|
||||||
|
subtract: function subtract(a: number, b: number): number {
|
||||||
|
return a - b;
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
@ -213,9 +213,19 @@
|
||||||
const arr: any = [];
|
const arr: any = [];
|
||||||
formScheme.value.formInfo.tabList.forEach((item, index) => {
|
formScheme.value.formInfo.tabList.forEach((item, index) => {
|
||||||
item.schemas.forEach((val) => {
|
item.schemas.forEach((val) => {
|
||||||
arr.push(val);
|
if (val.type == 'subTable' && val.columns) {
|
||||||
|
console.log('val', val)
|
||||||
|
val.columns.forEach((col) => {
|
||||||
|
col.children.forEach((chil) => {
|
||||||
|
arr.push(chil);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
arr.push(val);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
console.log('item.columns', arr)
|
||||||
formScheme.value.formInfo.schemas = arr;
|
formScheme.value.formInfo.schemas = arr;
|
||||||
}
|
}
|
||||||
if (formScheme.value.formInfo.tabList && formScheme.value.formInfo.tabList.length == 1) {
|
if (formScheme.value.formInfo.tabList && formScheme.value.formInfo.tabList.length == 1) {
|
||||||
|
|
|
||||||
|
|
@ -154,6 +154,7 @@
|
||||||
let query: any = { keyValue: record.schemeId };
|
let query: any = { keyValue: record.schemeId };
|
||||||
const preview: any = await functionGetPreviewForm(query);
|
const preview: any = await functionGetPreviewForm(query);
|
||||||
let scheme = JSON.parse(preview.scheme);
|
let scheme = JSON.parse(preview.scheme);
|
||||||
|
console.log('scheme1111', scheme);
|
||||||
if (scheme.formInfo.tabList && scheme.formInfo.tabList.length > 1) {
|
if (scheme.formInfo.tabList && scheme.formInfo.tabList.length > 1) {
|
||||||
const arr: any = [];
|
const arr: any = [];
|
||||||
scheme.formInfo.tabList.forEach((item, index) => {
|
scheme.formInfo.tabList.forEach((item, index) => {
|
||||||
|
|
|
||||||
|
|
@ -126,6 +126,7 @@
|
||||||
let tableData = await getTableColumnData(schems);
|
let tableData = await getTableColumnData(schems);
|
||||||
let tabArr: any = [];
|
let tabArr: any = [];
|
||||||
let tabLabelArr: any = [];
|
let tabLabelArr: any = [];
|
||||||
|
console.log('beforedesignTab', designTab);
|
||||||
designTab.schemas.forEach((item) => {
|
designTab.schemas.forEach((item) => {
|
||||||
if (item.component !== 'Tabs') {
|
if (item.component !== 'Tabs') {
|
||||||
if (item.componentProps.defaultValue) {
|
if (item.componentProps.defaultValue) {
|
||||||
|
|
@ -167,7 +168,7 @@
|
||||||
}
|
}
|
||||||
// 设计子表给里面的控件增加csType字段
|
// 设计子表给里面的控件增加csType字段
|
||||||
if (list.type == 'subTable') {
|
if (list.type == 'subTable') {
|
||||||
list.columns = changeCloums(item.columns, tableData);
|
list.columns = changeCloums(list.columns, tableData);
|
||||||
}
|
}
|
||||||
tabArr.push(list.componentProps.fieldName);
|
tabArr.push(list.componentProps.fieldName);
|
||||||
if (!list.componentProps.fieldName) {
|
if (!list.componentProps.fieldName) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue