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_Related Related Topics sp_TopicIcon
Send own ID when deleting row
16/03/2011
11:38
Avatar
KevinES
New Member
Members
Forum Posts: 2
Member Since:
16/03/2011
sp_UserOfflineSmall Offline

Hi, i have a small problem.

When i try to delete a row, the post only send the RowID and the operation (del). How can i pass my DatabaseID?

jQuery("#toolbar").jqGrid({
           url:'/bla/Benutzer?a=get',
           datatype: "xml",
           height: 255,
           width: 600,
           colNames:['uID','Login', 'Vorname', 'Nachname', 'Mail'],
           colModel:[
             {name:'user_id',index:'user_id', width:65, editable:true, editoptions:{readonly:true,size:10}},
             {name:'login',index:'login', width:150, sortable:true, editable:true},
             {name:'vorname',index:'vorname', width:100, sortable:true, editable:true},
             {name:'nachname',index:'nachname', width:100, sortable:true, editable:true},
             {name:'mail',index:'mail', width:100, sortable:true, editable:true}
           ],
           rowNum:50,
           rowList : [10,30,50],
           mtype: "POST",
           rownumbers: true,
           rownumWidth: 40,
           gridview: true,
           pager: '#ptoolbar',
           sortname: 'user_id',
           viewrecords: true,
           sortorder: "asc",
           caption: "Toolbar Searching",
           editurl: "/bla/Benutzer?a=set"
         });

         jQuery("#toolbar").jqGrid('navGrid','#ptoolbar',{del:true,add:true,edit:true,search:true});
         jQuery("#toolbar").jqGrid('filterToolbar',{stringResult: true,searchOnEnter : false});

Thank you,

Kevin

16/03/2011
12:17
Avatar
OlegK
Germany
Member
Members
Forum Posts: 1255
Member Since:
10/08/2009
sp_UserOfflineSmall Offline

Hello Kevin,

please define what do you mean under the DatabaseID and why it is not the same as RowID? With which data you fill the grid? Is user_id is the qnique id for your data? Do you fill the same id in the "id" field attribute of the xml data? If jqGrid find no id information in your input it uses 1,2,3... as ids. Probably it is your problem?

You can additionally define key:true property in the 'user_id' column. I hope this will also fix you problem. Nevertheless I recommend you to read this part of the documentation amd change either you XML data to be readed by jqGrid inclusive ids or include xmlReader parameter which follows to the same results.

Best regards
Oleg 

16/03/2011
12:59
Avatar
KevinES
New Member
Members
Forum Posts: 2
Member Since:
16/03/2011
sp_UserOfflineSmall Offline

Thank you,

the key:true attribute was a good workaround 🙂

My DatabaseID: thats the PrimaryKey in the DatabaseTable - the unique key.

Maybe i change my XML. But for now, it works. (its only a prototype)

-Kevin

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
23 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