Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

editable and non-editable rows in slickgrid

Tags:

slickgrid

How do I make some rows editable and some rows non-editable in slickgrid?

like image 345
ranendra Avatar asked Dec 15 '10 04:12

ranendra


2 Answers

Set the onBeforeEditCell event handler and return false to prevent the cell from going into edit mode.

like image 135
Tin Avatar answered Nov 14 '22 03:11

Tin


Or you can simply designate some columns not to be editable without specifying any editor attribute.

Ex

columns = [
    {id:"id",name:"#",field:"id"},
    {id:"editable",name:"clicky",field:"editable",editor:Slick.Editors.Text}
];

Depends if you want to loop an auxiliary array and apply if criteria.

Hope it helps

like image 38
cristi _b Avatar answered Nov 14 '22 02:11

cristi _b