0

Is it possible to add row id to the setColProp() of jqGrid?

When I dynamically set "editable":false for a column, it sets "editable":false for ALL columns in the grid and not for a particular column of a particular row.

techlead
  • 779
  • 7
  • 24
  • 44

2 Answers2

0

You can using properties of column

{ name: 'COMPANY_ID', index: 'COMPANY_ID', align: 'left', editable: true }

After that you can set for col:

$("#grid").jqGrid('setColProp', 'COMPANY_ID', { editable: false });
Hong Van Vit
  • 2,884
  • 3
  • 18
  • 43
0

You can change the column property (for any column) before you call editRow and reset it back directly after the call editRow. In the way you can implement full dynamical editable option. See the answer for the code example.

Community
  • 1
  • 1
Oleg
  • 220,925
  • 34
  • 403
  • 798
  • It works if `editable` is not set in JSON response. But I have `editable` set in JSON and I'm checking for this value on `loadComplete`. Since I have the value coming in from JSON, it doesn't work if I change the order of row editing. – techlead Nov 14 '11 at 18:57