parent
a69f804bd3
commit
e3433c9ea9
|
|
@ -2,7 +2,7 @@
|
||||||
* @Description: 组件属性控件
|
* @Description: 组件属性控件
|
||||||
-->
|
-->
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { Checkbox, Col, Empty, Form, FormItem, Select } from 'ant-design-vue'
|
import { Checkbox, Col, Empty, FormItem, Select } from 'ant-design-vue'
|
||||||
import { computed, ref, watch } from 'vue'
|
import { computed, ref, watch } from 'vue'
|
||||||
import { useFormDesignState } from '../../../hooks/useFormDesignState'
|
import { useFormDesignState } from '../../../hooks/useFormDesignState'
|
||||||
import {
|
import {
|
||||||
|
|
@ -14,10 +14,10 @@ import {
|
||||||
import { formItemsForEach, remove } from '../../../utils'
|
import { formItemsForEach, remove } from '../../../utils'
|
||||||
import type { IBaseFormAttrs } from '../config/formItemPropsConfig'
|
import type { IBaseFormAttrs } from '../config/formItemPropsConfig'
|
||||||
import FormOptions from './FormOptions.vue'
|
import FormOptions from './FormOptions.vue'
|
||||||
import { componentMap } from '../../../../../Form/src/componentMap.ts'
|
import { componentMap } from '@/components/Form/src/componentMap'
|
||||||
|
|
||||||
const { formConfig } = useFormDesignState()
|
const { formConfig } = useFormDesignState()
|
||||||
// 让compuated属性自动更新
|
// 让 computed 属性自动更新
|
||||||
const allOptions = ref([] as Omit<IBaseFormAttrs, 'tag'>[])
|
const allOptions = ref([] as Omit<IBaseFormAttrs, 'tag'>[])
|
||||||
function showControlAttrs(includes: string[] | undefined) {
|
function showControlAttrs(includes: string[] | undefined) {
|
||||||
if (!includes)
|
if (!includes)
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,12 @@
|
||||||
-->
|
-->
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { computed, defineComponent} from 'vue'
|
import { computed, defineComponent} from 'vue'
|
||||||
import { Empty, Form, FormItem, } from 'ant-design-vue'
|
import { Empty, FormItem } from 'ant-design-vue'
|
||||||
import { isArray } from 'lodash-es'
|
import { isArray } from 'lodash-es'
|
||||||
import { baseItemColumnProps } from '../config/formItemPropsConfig'
|
import { baseItemColumnProps } from '../config/formItemPropsConfig'
|
||||||
|
|
||||||
import { useFormDesignState } from '../../../hooks/useFormDesignState'
|
import { useFormDesignState } from '../../../hooks/useFormDesignState'
|
||||||
import { componentMap } from '../../../../../Form/src/componentMap.ts'
|
import { componentMap } from '@/components/Form/src/componentMap'
|
||||||
|
|
||||||
const { formConfig } = useFormDesignState()
|
const { formConfig } = useFormDesignState()
|
||||||
function showProps(exclude: string[] | undefined) {
|
function showProps(exclude: string[] | undefined) {
|
||||||
|
|
@ -21,7 +21,6 @@ function showProps(exclude: string[] | undefined) {
|
||||||
const Com = computed(() => {
|
const Com = computed(() => {
|
||||||
return com => componentMap.get(com) as ReturnType<typeof defineComponent>
|
return com => componentMap.get(com) as ReturnType<typeof defineComponent>
|
||||||
})
|
})
|
||||||
console.log(baseItemColumnProps);
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
-->
|
-->
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { computed, watch, defineComponent } from 'vue'
|
import { computed, watch, defineComponent } from 'vue'
|
||||||
import { Checkbox, Col, Empty, Form, FormItem, Input, Switch } from 'ant-design-vue'
|
import { Checkbox, Col, Empty, FormItem, Input, Switch } from 'ant-design-vue'
|
||||||
import { isArray } from 'lodash-es'
|
import { isArray } from 'lodash-es'
|
||||||
import {
|
import {
|
||||||
advanceFormItemColProps,
|
advanceFormItemColProps,
|
||||||
|
|
@ -11,7 +11,7 @@ import {
|
||||||
baseFormItemControlAttrs,
|
baseFormItemControlAttrs,
|
||||||
baseFormItemProps,
|
baseFormItemProps,
|
||||||
} from '../../VFormDesign/config/formItemPropsConfig'
|
} from '../../VFormDesign/config/formItemPropsConfig'
|
||||||
import { componentMap } from '../../../../../Form/src/componentMap.ts'
|
import { componentMap } from '@/components/Form/src/componentMap'
|
||||||
import { useFormDesignState } from '../../../hooks/useFormDesignState'
|
import { useFormDesignState } from '../../../hooks/useFormDesignState'
|
||||||
import RuleProps from './RuleProps.vue'
|
import RuleProps from './RuleProps.vue'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ import type { RadioChangeEvent } from 'ant-design-vue'
|
||||||
import {
|
import {
|
||||||
Checkbox,
|
Checkbox,
|
||||||
Col,
|
Col,
|
||||||
Form,
|
|
||||||
FormItem,
|
FormItem,
|
||||||
InputNumber,
|
InputNumber,
|
||||||
Slider,
|
Slider,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue