0

I currently have a jqGrid that edits data in the database using editurl. How do I do actions after receiving a reply from the server, for example check if the updated succeeded, or a message returned by the server.

if there's no jqGrid function that does this, how then can I go about doing this?

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
laurenceputra
  • 317
  • 2
  • 5
  • 16
  • Which editing mode you use: inline editing or form editing? All the editing modes has the corresponding events, but the name of the events and its parameters are different. – Oleg Mar 21 '11 at 09:15
  • was using inline. fixed already tho. thx – laurenceputra Mar 21 '11 at 09:38
  • Requesting to close the Question as this is Solved and no more answers are needed. – Tareq Apr 25 '11 at 17:54

1 Answers1

0

The OP wrote:

solved. API for edit row is as below.

jQuery("#grid_id").jqGrid('editRow',rowid, keys, oneditfunc, succesfunc, url, extraparam, aftersavefunc,errorfunc, afterrestorefunc);

Put the function you want under aftersavefunc, and take in 2 params, the row_id and the response. the response is a XMLhttpRequest Object.

Community
  • 1
  • 1
Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129