Ext.window.Window

论坛 期权论坛 编程之家     
选择匿名的用户   2021-6-2 17:31   1383   0

            var win = Ext.create("Ext.window.Window", {
                id: "myWin",
                title: "示例窗口",
                width: 500,
                height: 300,
                layout: "fit",
                modal: true, //透明
                closable: false,//右上角关闭按钮是否显示
                items: [
                    {
                        xtype: "form",
                        defaultType: 'textfield',
                        defaults: {
                            anchor: '100%',
                        },
                        fieldDefaults: {
                            labelWidth: 80,
                            labelAlign: "left",
                            flex: 1,
                            margin: 5
                        },
                        items: [
                            {
                                xtype: "container",
                                layout: "hbox",
                                items: [
                                    { xtype: "textfield", name: "name", fieldLabel: "目录", allowBlank: false },
                                    { xtype: "numberfield", name: "age", fieldLabel: "年龄", decimalPrecision: 0, vtype: "age" }
                                ]
                            }
                        ]
                    }
                ],
                buttons: [
                    { xtype: "button", text: "确定", handler: function () { this.up("window").close(); } },
                    { xtype: "button", text: "取消", handler: function () { this.up("window").close(); } }
                ]
            });
            win.show();

转载于:https://www.cnblogs.com/nidongde/p/5286972.html

分享到 :
0 人收藏
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

积分:3875789
帖子:775174
精华:0
期权论坛 期权论坛
发布
内容

下载期权论坛手机APP