Transfer

Updated at:

Introduction

The Transfer component lets you select multiple items from a list by moving them between two columns.

Configurations

Category

Configuration

Example

Description

Content

Data Source

The data source for the Transfer component. Data from the source is rendered in the left column, except for items specified in the Key collection for the right column.

Key collection for the right column

image

A collection of keys for the data displayed in the right column.

Key collection for selected data

image

A collection of keys for the selected data.

Title

The title bar of the top multi-select box contains a left title and a right title.

Operation text

The text for the buttons that move items left and right.

Interaction

Hide

Controls the default display state of the Transfer component. If set to true, the component is hidden. For more information, see Common properties.

Disable

Specifies whether to disable the Transfer component.

Show search box

Enables the search feature. This feature filters data based on user input.

Show select all checkbox

You can select all elements within the box.

One-way mode

Allows items to be moved only from the left column to the right column.

Style

Margin

For more information, see Common properties.

Properties and methods

Name

Type

Example

Description

targetKeys

array

transfer1.targetKeys

The collection of keys in the right column of the Transfer component.

selectedKeys

array

transfer1.selectedKeys

The collection of keys for the selected items in the Transfer component.

dataSource

array

transfer1.disabled

The data source of the Transfer component.

disabled

boolean

transfer1.disabled

Specifies whether the Transfer component is disabled.

oneWay

boolean

transfer1.oneWay

Specifies whether the Transfer component is in one-way mode.

hidden

boolean

transfer1.hidden

Specifies whether the component is hidden.

setTargetKeys

func

transfer1.setTargetKeys(['option1'])

Sets the data in the right column of the Transfer component to option1.

clearTargetKeys

func

transfer1.clearTargetKeys()

Clears the data in the right column of the Transfer component.

setDisabled

func

transfer1.setDisabled(true)

Disables the Transfer component.

clearDisabled

func

transfer1.clearDisabled()

Clears the disabled state of the Transfer component.

setHidden

func

transfer1.setHidden(false)

Sets whether the Transfer component is hidden. The parameter can be true or false.

clearHidden

func

transfer1.clearHidden()

Clears the hidden state of the Transfer component.

Event callbacks

Configuration

Description

The event that is triggered when an option is transferred between the two columns.

The event that is triggered when the selected items change.

Scenario examples

  • Task list scenario
    • You can use the Transfer component to view task progress.