mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-15 17:31:18 +08:00
fix:[穿梭框] 默认设置项的回填效果 amis-saas-6031
Change-Id: I512f442dba6524233b9b109f73bc82f68b50a4f7
This commit is contained in:
parent
ab614c7d74
commit
7f70f61ea5
@ -35,24 +35,9 @@ export class TransferPlugin extends BasePlugin {
|
||||
{
|
||||
label: '曹操',
|
||||
value: 'caocao'
|
||||
},
|
||||
{
|
||||
label: '钟无艳',
|
||||
value: 'zhongwuyan'
|
||||
},
|
||||
{
|
||||
label: '李白',
|
||||
value: 'libai'
|
||||
},
|
||||
{
|
||||
label: '韩信',
|
||||
value: 'hanxin'
|
||||
},
|
||||
{
|
||||
label: '云中君',
|
||||
value: 'yunzhongjun'
|
||||
}
|
||||
]
|
||||
],
|
||||
selectMode: 'list'
|
||||
};
|
||||
previewSchema: any = {
|
||||
type: 'form',
|
||||
@ -187,6 +172,14 @@ export class TransferPlugin extends BasePlugin {
|
||||
required: true
|
||||
}),
|
||||
getSchemaTpl('label'),
|
||||
getSchemaTpl('valueFormula', {
|
||||
rendererSchema: {
|
||||
...context?.schema,
|
||||
type: 'select',
|
||||
multiple: true
|
||||
},
|
||||
visibleOn: 'data.options.length > 0',
|
||||
}),
|
||||
getSchemaTpl('labelRemark'),
|
||||
getSchemaTpl('remark'),
|
||||
getSchemaTpl('placeholder'),
|
||||
@ -221,6 +214,7 @@ export class TransferPlugin extends BasePlugin {
|
||||
],
|
||||
onChange: (value: any, origin: any, item: any, form: any) => {
|
||||
form.setValueByName('options', undefined);
|
||||
form.setValueByName('value', "");
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -300,7 +300,7 @@ const renderInput = (
|
||||
export default class TransferTableOption extends React.Component<OptionControlProps, {}> {
|
||||
|
||||
addColumns() {
|
||||
const { columns = [{ type: 'text' }] } = this.props.data;
|
||||
const { columns = [{ type: 'text', name: 'label' }] } = this.props.data;
|
||||
return {
|
||||
type: 'action',
|
||||
actionType: 'dialog',
|
||||
|
Loading…
Reference in New Issue
Block a user