Forum
13:16
10/08/2009
Hello Kiran,
you wrote that you need an example for Add/Edit/Delete on local data. It means that all operation will be done in JavaScript without any code on the server side. So the words like "Gridview" and "I want ASP.NET example" seems me strange. the local editing example is pure JacaScript example without any ASP.NET or other server side code.
The methods delRowData, setRowData, addRowData exist before the version 3.7. The methods allow to make modification of grid contain without user interractionand without any requests to the servr. New in version 3.7 is that jqGrid can hold local data accociated with the grid which are more as the current page displayed. Starting with version 3.7 jqGrid support pure local paging, sorting and filtering/searching. To use it one should use datatype:'local' as the jqGrid parameter. The best wat to fill the data of the local grid is to use data parameter of jqGrid. See here an example.
Now about the local editing of the data. If you have jqGrid with local data (as described above) you can use two editing methods: inline editing and cell editing to edit the local data. One should use editurl:'clientArray' for inline editing and cellsubmit:'clientArray' for cell editing to use local data editing. The form editing implemented in 3.7 has not full local editing support, so jqGrid will do make some requests to the server.
Because you want all Add/Edit and Delete operation on local data you probably want the use form editing.
In my post here and here I describe one trick and include the demo which shows how one do can implement full local form editing in the current version of jqGrid. The demo use jqGrid 3.8.2, but the same idea should work in jqGrid 4.0 and 3.7. The code is not small, but it is probably what you need.
I suggested Tony to modify the code of jqGrid to implement full local form data editing in jqGrid without the tricks which I use. Probably in the next version of jqGrid the feature will be the part of jqGrid.
Best regards
Oleg
11:06
01/11/2014
OlegK said
Hello Kiran,you wrote that you need an example for Add/Edit/Delete on local data. It means that all operation will be done in JavaScript without any code on the server side. So the words like "Gridview" and "I want ASP.NET example" seems me strange. the local editing example is pure JacaScript example without any ASP.NET or other server side code.
The methods delRowData, setRowData, addRowData exist before the version 3.7. The methods allow to make modification of grid contain without user interractionand without any requests to the servr. New in version 3.7 is that jqGrid can hold local data accociated with the grid which are more as the current page displayed. Starting with version 3.7 jqGrid support pure local paging, sorting and filtering/searching. To use it one should use datatype:'local' as the jqGrid parameter. The best wat to fill the data of the local grid is to use data parameter of jqGrid. See here an example.
Now about the local editing of the data. If you have jqGrid with local data (as described above) you can use two editing methods: inline editing and cell editing to edit the local data. One should use editurl:'clientArray' for inline editing and cellsubmit:'clientArray' for cell editing to use local data editing. The form editing implemented in 3.7 has not full local editing support, so jqGrid will do make some requests to the server.
Because you want all Add/Edit and Delete operation on local data you probably want the use form editing.
In my post here and here I describe one trick and include the demo which shows how one do can implement full local form editing in the current version of jqGrid. The demo use jqGrid 3.8.2, but the same idea should work in jqGrid 4.0 and 3.7. The code is not small, but it is probably what you need.
I suggested Tony to modify the code of jqGrid to implement full local form data editing in jqGrid without the tricks which I use. Probably in the next version of jqGrid the feature will be the part of jqGrid.
Best regards
Oleg
Hello Oleg,
Thanks for the Demo you provided above.
I have tried it and i am not able to edit and save in form edit. When I click on submit button nothing happens. No process at all. Please guide me through this issue
15:25
10/08/2009
Try to use more the recent demo created for the answer. It should work with the current version of jqGrid too.
Best regards
Oleg
11:49
Moderators
30/10/2007
Hello Oleg,
Â
Thanks.
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Most Users Ever Online: 715
Currently Online:
47 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