2014-03-19 40 views
0

我有一個手風琴面板,可容納3個GridPanels。當頁面第一次顯示時,前兩個面板被展開,最後一個面板被摺疊。ExtJS手風琴GridPanels不同高度

是否有可能使第一個GridPanel比其他兩個稍微大一些?

@lmno:

xtype: 'container', 
flex: 2, 
layout: { type: 'accordion', border: false, multi: true }, 
items: [ 
    { xtype: 'myGrid' }, 
    { xtype: 'pendingGrid' } 
] 

可以的Ext.layout.container.Accordionmulti屬性設置爲true使多個手風琴項目一次打開。

之後,你可以玩collapsedcollapsible網格屬性。

+0

你有你的手風琴與2開放面板的例子。我的印象是手風琴在打開時關閉了其他容器。 – lmno

+0

是的,我明天會發布,我剛剛離開工作。 – hermann

+0

@lmno檢查出來 – hermann

回答

0

這是專門爲當你想實現這一點,但也有多種:真

layout: { 
       type: 'accordion', 
       animate: true, 
       multi: true, 
       fill: false 
      }, 
      items: [{ 
       title: 'Panel 1', 
       html: 'Panel content!', flex: 2 // or height 
      }, { 
       title: 'Panel 2', 
       html: 'Panel content!', flex: 1 
      }, { 
       title: 'Panel 3', 
       html: 'Panel content!', flex: 1 
      }], 

從煎茶論壇注意到https://www.sencha.com/forum/showthread.php?283045-How-to-have-Grids-under-accordion-panel-with-different-height (發佈的代碼反正在情況下,鏈接變成打破未來。)