Results 1 to 3 of 3

Thread: How to add items to a grid column header? (with modern theme)

  1. #1
    Sencha User
    Join Date
    Aug 2014
    Posts
    3
    Vote Rating
    0
      0  

    Default How to add items to a grid column header? (with modern theme)

    Hi,
    I would to add some items to grid column header.

    It works with classic theme (using Ext.grid.Panel)
    https://fiddle.sencha.com/#view/editor&fiddle/2s7u

    but it does not work with modern theme (using Ext.grid.Grid)
    https://fiddle.sencha.com/#view/editor&fiddle/2s7v

    All items get to div with .x-gridcolumn.x-leaf .x-gridcolumn-body-el class with "display: none;" CSS style.

    thanks

  2. #2
    Sencha User
    Join Date
    Mar 2019
    Posts
    3
    Answers
    1
    Vote Rating
    0
      0  

    Default

    Hello, try this :

    Ext.create('Ext.grid.Grid', {
    store: store,
    columns: [{
    text: 'Name <div><input type"text"></input><div>',
    dataIndex: 'name',
    flex: 1,
    items: [
    {
    xtype: 'textfield'
    }
    ]
    }, {
    text: 'Email',
    flex: 1,
    dataIndex: 'email',
    items: [
    {
    xtype: 'textfield'
    }
    ]
    }],
    fullscreen: true
    });

    Basically adding the <div> <element you want> </> <div> to the text it worked when I added it to the fiddle. It still sorts when you click inside the text field, so that may not be wanted. But if you explain the functionality your looking to implement, there could be a better solution.

  3. #3
    Sencha User
    Join Date
    Aug 2014
    Posts
    3
    Vote Rating
    0
      0  

    Default

    Thanks. It works. But no extjs items created( no handlers, no bindings
    I will keep it as a last resort

Tags for this Thread

Posting Permissions

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