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
New ver 3.3 Cell Editing error: No url is set
06/10/2008
10:34
Avatar
Renso
PA
Member
Members
Forum Posts: 118
Member Since:
11/09/2008
sp_UserOfflineSmall Offline

Getting an error when doing an inine cell edit via the new version 3.3             cellEdit: true option. When editing the filed and pressing tab or enter, gives me error: "No url is set" message. My editUrl is set and works fine for formedit. Do I need to set another property other than cellEdit?

06/10/2008
11:27
Avatar
zupert
Member
Members
Forum Posts: 18
Member Since:
29/07/2008
sp_UserOfflineSmall Offline

Man, you know that reading the source code is the best way to learn ?

have a look at the 'cellsubmit' property ...

just put  cellsubmit: 'clientArray', and here you got the magic ..

06/10/2008
12:24
Avatar
Renso
PA
Member
Members
Forum Posts: 118
Member Since:
11/09/2008
sp_UserOfflineSmall Offline

I used cellsubmit: 'remote' to force an ajax call.

What does 'clientArray' do and for what is it used for?

Also, how can I add post data to the remote ajax request on save, I tried the following and it did not work:

            beforeSubmitCell: function()    {
                $(item).setPostData({'oper':'editCell'});
            },

so that the server knows what kind of operation is performed; i.e. edit of entire row, save of a new record, delete or editing a specific cell only.

06/10/2008
12:33
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

I have put the 3.3 version for download. You should wait a little until the docs are ready.

In you case there is another option for this

cellurl :'someurl'

Use this and all wil be ok

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.

06/10/2008
14:48
Avatar
Renso
PA
Member
Members
Forum Posts: 118
Member Since:
11/09/2008
sp_UserOfflineSmall Offline

Thank you Tony! Yes, I simply appended my parms to the url, thanks again. Maybe we can add a parm to indicate the actual field name updated during a cell update so that a person does not have to check each field to see which one was updated, maybe there is a easy way to do it with the existing framework?

Example, the user can update Street Address 1, 2, 3, City, State zip, etc, on the server I have to check on cellEdit which one is not null to figure out what had changed.

06/10/2008
14:56
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

You do not need this. To this url automatically are passed the 

{id: rowid, cellname: cellvalue}

If you want to pass other parameters use beforeSubmitCell and return 

the needed values

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.

06/10/2008
15:05
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

You can use the savedRow parameter to check if the value is changed.

This array contain the data before editing the cell.

I hope this help

getGridParam('savedRow') will return

{id:iRow,ic:iCol,name:cellname,v:cellvalue_before_edit}

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.

06/10/2008
16:25
Avatar
Renso
PA
Member
Members
Forum Posts: 118
Member Since:
11/09/2008
sp_UserOfflineSmall Offline

Tony, thanks again, but how do I get the new value? and once I have it and compare them to be the same, do I return false to avoid the ajax call?

06/10/2008
16:55
Avatar
Renso
PA
Member
Members
Forum Posts: 118
Member Since:
11/09/2008
sp_UserOfflineSmall Offline

Added the following line to the jqGrid to set a new property for the posted data, but it is not extended/added in grid.celledit.js line 145 in method saveCell. In lines 153 can we add an extend to add the additional custom properties to the post?

            beforeSubmitCell: function(id, cellName)    {
                $(myGrid).appendPostData({editCellColumn:cellName});
            },

So basically the appendPostData works but is not added to the postData property in saceCell. is this an issue or is there another way to do it?

07/10/2008
08:52
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

beforeSubmitCell is something little difficult to other. It should return

values that can be posted to the server. Something like this

beforeSubmitCell: function(rowid,celname,celvalue, iRow,iCol) {

// do something here

return {myname1:myvalue,...}

These will be passed to the url again with rowid and cellname: cellvalue

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.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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