Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
Editable Grid - Process changes on client side
16/04/2010
15:05
Avatar
essey
Member
Members
Forum Posts: 10
Member Since:
16/04/2010
sp_UserOfflineSmall Offline

Hi,

I have an editable Grid where I wanna process changes on client side (without 'editURL'). Is there an event which is called when I press the 'Enter' key. If yes how do I get access to the changed fields.

Here is my code:

  

    var lastsel;
    $("#adminGroupPermissions").jqGrid({
       datatype: "local",
       height: 250,
       colNames:['ID','Queue Pattern', 'Read Queue', 'Write Queue','Read Topic','Write Topic'],
       colModel:[
          {name:'id',index:'id', width:60, sorttype:"int"},
          {name:'queuePattern',index:'queuePattern', width:150, editable:true, sorttype:"text"},
          {name:'permReadQueue',index:'permReadQueue', width:80, editable:true, formatter:'checkbox', edittype:'checkbox', stype:'select', editoptions:{value:'1:0'}},
          {name:'permWriteQueue',index:'permWriteQueue', width:80, editable:true, formatter:'checkbox', edittype:'checkbox', stype:'select', editoptions:{value:'1:0'}},
          {name:'permReadTopic',index:'permReadTopic', width:80, editable:true, formatter:'checkbox', edittype:'checkbox', stype:'select', editoptions:{value:'1:0'}},
          {name:'permWriteTopic',index:'permWriteTopic', width:80, editable:true, formatter:'checkbox', edittype:'checkbox', stype:'select', editoptions:{value:'1:0'}}
       ],
       multiselect: false,
       caption: "Group Permissions",
       rowNum:10,
       rowList:[10,20,30],
       pager: '#pager',
       sortname: 'id',
       viewrecords: true,
       sortorder: "asc",
       onSelectRow: function(id) {
          if(id && id!==lastsel) {
             $('#adminGroupPermissions').jqGrid('restoreRow',lastsel);
             $('#adminGroupPermissions').jqGrid('editRow',id,true);
             lastsel=id;
          }
       },
       editurl: "server.php",
    });
    $("#adminGroupPermissions").jqGrid('navGrid',"#pager",{edit:false,add:false,del:false});

Regards,

Essey

19/04/2010
13:36
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

Please consult the docs how to do this. For inline edit (your case) and cell edit this is possible.

http://www.trirand.com/jqgridw.....ne_editing

Regards

Tony

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.

19/04/2010
18:20
Avatar
essey
Member
Members
Forum Posts: 10
Member Since:
16/04/2010
sp_UserOfflineSmall Offline

tony said:

Hello,

Please consult the docs how to do this. For inline edit (your case) and cell edit this is possible.

http://www.trirand.com/jqgridw.....ne_editing

Regards

Tony


Thank Tony

Regards

Essey

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
146 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.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information