Forum


10:01

12/02/2009

I'm trying to put edit/delete buttons in the grid using the "Custom Edit" demo as an example. I'm running into the "elem[0] is undefined" problem which I understand to be a mismatch between the colModel and the dataset returned from the server.
How should one configure the colModel when there is no relation between the column of action buttons and a column in the database?
02:49

09/03/2009

hi,
just do as written in the demo. Add a column in your colNames property and add a column in your colModel property and that's all.
colNames:['Module','Actif','Modifier','Supprimer'],
colModel:[
{name:'name',index:'name', width:150, editable:true, editoptions:{size:30}},
{name:'actifStr',index:'actifStr', width:150, editable:true, edittype:"checkbox", align:'center',editoptions: {value:"Oui:Non"} },
{name:'modif',index:'modif', width:40,sortable:false, align:'center'},
{name:'suppr',index:'suppr', width:50,sortable:false, align:'center'}
],
my "modif" and "suppr" columns doesn't exists in my database nor in the server's response.
regards,
marc
Most Users Ever Online: 715
Currently Online:
53 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66