Page 2 of 10 FirstFirst 1234 ... LastLast
Results 11 to 20 of 91

Thread: GroupHeaderGrid - Grouped grid column headers

  1. #11
    Ext User
    Join Date
    Mar 2009
    Posts
    71
    Vote Rating
    0
      0  

    Default

    How can I only group the first level of headers (the original column headers)?

    In other words, to replace the existing column header instead of adding a header row to represent a group header.

    thanks

  2. #12
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    118
      0  

    Default

    The original (first-level) headers need to be rendered, because the GridPanel baseclass expects them to be present.

    But that doesn't mean you can't hide them with display:none!

  3. #13
    Ext User
    Join Date
    Mar 2009
    Posts
    71
    Vote Rating
    0
      0  

    Default

    Quote Originally Posted by Condor View Post
    The original (first-level) headers need to be rendered, because the GridPanel baseclass expects them to be present.

    But that doesn't mean you can't hide them with display:none!
    Thanks, so do you mean I've to explicitly get the DOM of header and set the CSS to display:none?

    any faster way to achieve this?

    PS: I've tried to inspect the DOM in firebug and set the <div> to display:none, the header space is still exist in the <td> ...
    If I set the <td> to display:none, the whole header's layout will be corrupted. But I can't add the colspan to the grid original header...

    Since this groupHeader plugin renders the header rows in separate <table>s, the alignment of header cells cannot be dependently aligned.

  4. #14
    Ext User
    Join Date
    Sep 2009
    Posts
    7
    Vote Rating
    0
      0  

    Wink

    Thank you for your share

  5. #15

    Default

    Quote Originally Posted by mattpainter View Post
    Fantastic piece of work. Thanks Condor; works beautifully.
    +1000

  6. #16
    Sencha User calavera's Avatar
    Join Date
    Jan 2008
    Posts
    119
    Vote Rating
    0
      0  

    Default

    Great share! I have noticed that the dataIndex column defined in the GroupHeaderGrid becomes unsortable. Only the first column has this problem.

    LE: The next group of header column has no working sortable column...Any fixes ?

    Thanks.

  7. #17
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    118
      0  

    Default

    Quote Originally Posted by calavera View Post
    Great share! I have noticed that the dataIndex column defined in the GroupHeaderGrid becomes unsortable. Any fix for this ? Only the first column has this problem.
    Can you reproduce the problem with the provided example?

    If not, can you post an example that does?

  8. #18
    Sencha User
    Join Date
    Jul 2009
    Posts
    24
    Vote Rating
    0
      0  

    Default

    Thank you so, so much for sharing this! It's exactly what I was looking for.

  9. #19
    Sencha User
    Join Date
    Jul 2009
    Posts
    24
    Vote Rating
    0
      0  

    Default

    Condor:

    I'm trying to dynamically update the GroupHeader header value from store JSON data but I'm having problems.

    This is because I want the dynamic JSON response from the store to update my Group Column Headers. I'm making a 2 day calendar style grid view - so my previous and next buttons load the store and return data and 2 new dates/days which I want to display in the header.

    I currently do this to standard GridPanel columnHeaders by doing either:

    Code:
    myStore.on('load', function() {
          myColumnModel.setConfig([
                    {header: "New Header", dataIndex: 'foo'}
          ])
    }
    or with:

    Code:
    myStore.on('load', function() {
         myColumnModel.setColumnHeader(1, 'New Header');
    }
    Code:
    |        Tuesday       |     Wednesday        |
    -----------------------------------------------
    | 8 | 9 | 10 | 11 | 12 | 8 | 9 | 10 | 11 | 12 |
    -----------------------------------------------
    I want to change Tuesday/Wednesday dynamically to values from my JSON.

    If you have any suggestions for how I could implement this I would be eternally grateful! Sorry if i've rambled on with too useless detail.

    Thanks
    Martin

  10. #20
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    118
      0  

    Default

    Modify grid.getColumnModel().rows and call grid.getView().updateHeaders() (calling grid.getColumnModel().setConfig() will also update the headers).

Page 2 of 10 FirstFirst 1234 ... LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •