Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/extjs/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript ExtJS:寻找类似拖放的组件?_Javascript_Extjs_Drag And Drop_Components - Fatal编程技术网

Javascript ExtJS:寻找类似拖放的组件?

Javascript ExtJS:寻找类似拖放的组件?,javascript,extjs,drag-and-drop,components,Javascript,Extjs,Drag And Drop,Components,我需要一个组件,但在厨房水槽示例中找不到 下图中是否有类似的组件 简要地 在左边的集装箱上会有几个项目;项目将通过web服务加载 中间将有一个添加按钮,将左侧容器上的选定项目转移到右侧容器 最后,在正确的容器中,这些项目将被收集,并使用Save按钮,在正确的容器中,这些项目将通过CRUD过程上传到DB 这个功能也可以是拖放式的 提前感谢。您应该使用或您应该使用或您可以使用 或extjs组件 在这个中,我使用itemselector组件创建了一个演示 代码片段 Ext.applicatio

我需要一个组件,但在厨房水槽示例中找不到

下图中是否有类似的组件


简要地

  • 在左边的集装箱上会有几个项目;项目将通过web服务加载

  • 中间将有一个添加按钮,将左侧容器上的选定项目转移到右侧容器

  • 最后,在正确的容器中,这些项目将被收集,并使用
    Save
    按钮,在正确的容器中,这些项目将通过CRUD过程上传到DB

这个功能也可以是拖放式的


提前感谢。

您应该使用或

您应该使用或

您可以使用 或extjs组件

在这个中,我使用
itemselector
组件创建了一个演示

代码片段

Ext.application({
    name: 'Fiddle',

    launch: function () {

        Ext.onReady(function () {

            Ext.define('Items', {
                extend: 'Ext.data.Store',
                alias: 'store.itemsstore',
                fields: ['value', 'text'],
                data: [{
                    text: 'Item 1',
                    value: 'item1'
                }, {
                    text: 'Item 2',
                    value: 'item3'
                }, {
                    text: 'Item 3',
                    value: 'item3'
                }, {
                    text: 'Item 4',
                    value: 'item4'
                }, {
                    text: 'Item 5',
                    value: 'item5'
                }, {
                    text: 'Item 6',
                    value: 'item6'
                }, {
                    text: 'Item 7',
                    value: 'item7'
                }, {
                    text: 'Item 8',
                    value: 'item8'
                }]
            });

            Ext.create({
                xtype: 'form',
                title: 'Drag and Drop example',

                bodyPadding: 10,
                renderTo: Ext.getBody(),
                items: [{
                    xtype: 'itemselector',
                    anchor: '100%',
                    store: {
                        type: 'itemsstore'
                    },
                    displayField: 'text',
                    valueField: 'value',
                    allowBlank: false,
                    msgTarget: 'side',
                    fromTitle: 'Available',
                    toTitle: 'Selected'
                }]
            });

        });
    }
});

您可以使用 或extjs组件

在这个中,我使用
itemselector
组件创建了一个演示

代码片段

Ext.application({
    name: 'Fiddle',

    launch: function () {

        Ext.onReady(function () {

            Ext.define('Items', {
                extend: 'Ext.data.Store',
                alias: 'store.itemsstore',
                fields: ['value', 'text'],
                data: [{
                    text: 'Item 1',
                    value: 'item1'
                }, {
                    text: 'Item 2',
                    value: 'item3'
                }, {
                    text: 'Item 3',
                    value: 'item3'
                }, {
                    text: 'Item 4',
                    value: 'item4'
                }, {
                    text: 'Item 5',
                    value: 'item5'
                }, {
                    text: 'Item 6',
                    value: 'item6'
                }, {
                    text: 'Item 7',
                    value: 'item7'
                }, {
                    text: 'Item 8',
                    value: 'item8'
                }]
            });

            Ext.create({
                xtype: 'form',
                title: 'Drag and Drop example',

                bodyPadding: 10,
                renderTo: Ext.getBody(),
                items: [{
                    xtype: 'itemselector',
                    anchor: '100%',
                    store: {
                        type: 'itemsstore'
                    },
                    displayField: 'text',
                    valueField: 'value',
                    allowBlank: false,
                    msgTarget: 'side',
                    fromTitle: 'Available',
                    toTitle: 'Selected'
                }]
            });

        });
    }
});

非常感谢您的样品。那会很好用的。也非常感谢您的样品。这将非常有效。