【问题标题】:Extjs-3.4 Checkbox in specified column of checkbox groupExtjs-3.4 复选框组指定列中的复选框
【发布时间】:2015-11-26 11:50:48
【问题描述】:

我正在使用 ExtJS-3.4 ,其中我需要显示带有 9 个复选框的复选框组,并且我能够在带有两列的复选框组中显示复选框。 两列控件(复选框)自动分布在复选框组列中。

{
                    xtype:'checkboxgroup',
                    id:'randomId',
                    fieldLabel: 'CheckboxGroupLabel',
                    autoScroll:false,
                    labelSeparator : '',
                    columns: 2,
                    items: [
                      {
                        boxLabel: "CB1", 
                        name: "CB1".toLowerCase(),
                        id:'CheckBoxId1'
                       }
                      .....
                       {
                        boxLabel: "CB9", 
                        name: "CB9".toLowerCase(),
                        id:'CheckBoxId9'
                       }
                     ]
}

现在我需要在 checkboxgroup 的第 1 列中显示 checkbox1 到 checkbox6 以及从checkboxgroup第2列的checkbox7到checkbox9。

上述情况可能吗?如果有人遇到这种情况,请提供帮助。

【问题讨论】:

    标签: extjs checkbox extjs3


    【解决方案1】:

    我已经通过使用vertical 配置和一些不可见的虚拟复选框实现了这一点:

                    vertical: true,
                    items: [
                      {
                        boxLabel: "CB1", 
                        name: "CB1".toLowerCase(),
                        id:'CheckBoxId1'
                       }
                      .....
                       {
                        boxLabel: "CB9", 
                        name: "CB9".toLowerCase(),
                        id:'CheckBoxId9'
                       },
                       {
                        style:'visibility:hidden'
                       },
                       {
                        style:'visibility:hidden'
                       },
                       {
                        style:'visibility:hidden'
                       }
                     ]
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2011-04-03
      • 1970-01-01
      • 1970-01-01
      • 2014-10-30
      • 1970-01-01
      • 2014-01-19
      • 2023-03-18
      相关资源
      最近更新 更多