Jump to content

column selection check how to fixed?


delagoutte

Recommended Posts

i have a unidbgrid with option for having a column with check box for the selection. How can ido for having this column that is always display ? how to fix it ?

if you have a grid with many column, -> there is a horizontal scrollbar -> if you scroll on the right, this column for selec row is not displayed

Link to comment
Share on other sites

Hi,

One possible solution I think, but check it

1.

function beforeInit(sender, config) 
{
    config.enableLocking = true;

    Ext.define('Ext.overrides.selection.CheckboxModel', {
        override: 'Ext.selection.CheckboxModel',

        hasLockedHeader: function() {
            return this.callParent(arguments) || this.view.ownerGrid.lockable;
        },
        onReconfigure: function(grid, store, columns) {
            if (columns && grid.lockable) {
                grid.lock(this.column, 0);
                grid.view.refreshView();
                return;
            }
            return this.callParent(arguments);
        }
    });
}

2.

function reconfigure(sender, store, columns, oldStore, oldColumns, eOpts)
{
    columns.forEach(function(col){
        col.lockable=false
    });
}

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...