\\$refs
引入的组件'
},
bb: {
type: 'combo',
multiple: true,
multiLine: true,
remark: 'combo
中的子项引入自身,实现嵌套的效果',
controls: [
{
label: 'combo 1',
type: 'text',
name: 'key'
},
{
label: 'combo 2',
name: 'value',
$refs: 'aa',
remark: 'definitions
中可以引用 definitions
中其他的属性'
},
{
name: 'children',
label: 'children',
$refs: 'bb'
}
]
}
},
type: 'page',
title: '引用',
body: [
{
type: 'form',
api: 'api/xxx',
actions: [],
controls: [
{
label: 'text2',
$refs: 'aa',
name: 'refs1'
},
{
label: 'combo',
$refs: 'bb',
name: 'refs2'
}
]
},
{
type: 'form',
api: 'api/xxx',
actions: [],
controls: [
{
label: 'select',
$refs: 'aa',
name: 'select',
type: 'select',
value: 1,
options: [
{
label: 'Option A',
value: 1
},
{
label: 'Option B',
value: 2
}
],
remark: '原属性会覆盖引用中的属性'
},
{
label: 'radios',
$refs: 'bb',
type: 'radios',
name: 'radios',
value: 'Option A',
options: [
'Option A',
'Option B',
],
remark: '原属性会覆盖引用中的属性'
}
]
}
]
};