Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User steffenk's Avatar
    Join Date
    Jul 2007
    Location
    Haan, Germany
    Posts
    2,664
    Vote Rating
    7
    steffenk has a spectacular aura about steffenk has a spectacular aura about steffenk has a spectacular aura about

      0  

    Default [FIXED-EXTJSIV-206] Grid columns miss a default configuration

    [FIXED-EXTJSIV-206] Grid columns miss a default configuration


    In Ext3 whe had some general properties for the columns eg for disable move, resize, sort etc.

    Now these properties are moved to columns configuration, which is great because there is more flexibility.

    But if you want to disable a feature for all columns, you have to set the property for each column.

    It would be great to have a default array for all columns to apply configuration for all columns, eg

    Code:
    columnsDefaults: {
      draggable: false
    }
    vg Steffen
    --------------------------------------
    Release Manager of TYPO3 4.5

  2. #2

  3. #3
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,358
    Vote Rating
    127
    aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold

      0  

    Default


    A coming change will support you providing your own HeaderContainer.

    Because HeaderContainer is a standard container you can use the defaults configuration. Attaching this thread to that ticket.
    Aaron Conran
    @aconran
    Sencha Architect Development Team

  4. #4
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,358
    Vote Rating
    127
    aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold

      0  

    Default


    In the next build you can pass in an instance of a HeaderContainer in the headers configuration.

    You can use the defaults configuration of a standard Container.
    Aaron Conran
    @aconran
    Sencha Architect Development Team

  5. #5
    Sencha User
    Join Date
    Jun 2010
    Location
    Buenos Aires, Argentina
    Posts
    213
    Vote Rating
    9
    ldonofrio will become famous soon enough

      0  

    Default


    Also "actioncolumn" takes by default sortable: true, draggable: true, fixed: false, i think that this have to be false, false, true by default

  6. #6
    Sencha User steffenk's Avatar
    Join Date
    Jul 2007
    Location
    Haan, Germany
    Posts
    2,664
    Vote Rating
    7
    steffenk has a spectacular aura about steffenk has a spectacular aura about steffenk has a spectacular aura about

      0  

    Default


    what's happened here? HeaderContainer is private now, not in the docs. No example for such config is given, and it looks like unsupported.

    Any statement, maybe an example for such default config?
    vg Steffen
    --------------------------------------
    Release Manager of TYPO3 4.5

  7. #7
    Ext JS Premium Member
    Join Date
    Mar 2010
    Location
    Barcelona
    Posts
    33
    Vote Rating
    1
    deister is on a distinguished road

      0  

    Default


    +1 !
    Where is headerContainer? How do I attach a headerclick listener?

  8. #8
    Ext JS Premium Member
    Join Date
    Mar 2010
    Location
    Barcelona
    Posts
    33
    Vote Rating
    1
    deister is on a distinguished road

      0  

    Default


    Hi,

    I figured out myself looking at the source code, here's an example:
    Code:
    var grid  = Ext.create('Ext.grid.Panel', {
        stripeRows          : true,
        enableColumnResize  : false,
        columns            : Ext.create('Ext.grid.header.Container',{
            items : cols,     // The usual  array of column definition objects.
            sortable : false,
            listeners : {
                headerclick : function(ct,column, e, t) {
                    console.log('headerclick', column)
                }
            }
        })
    })
    The documentation doesn't mention the possibility of passing an Ext.grid.header.Container instance instead of the columns array.

Similar Threads

  1. Replies: 2
    Last Post: 18 Apr 2011, 2:14 PM
  2. Replies: 1
    Last Post: 10 Apr 2011, 12:24 PM
  3. Replies: 1
    Last Post: 4 Apr 2011, 3:26 PM
  4. Grid columns configuration to unhidden if 2 columns remain
    By kanny in forum Ext 3.x: Help & Discussion
    Replies: 6
    Last Post: 12 Jul 2010, 11:48 PM
  5. Replies: 1
    Last Post: 24 Aug 2009, 12:22 AM

Thread Participants: 4