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
afterSaveCell not firing when value was empty in combination with custom selectbox via selectize.js
21/02/2014
18:21
Avatar
nexenator
Member
Members
Forum Posts: 6
Member Since:
27/10/2010
sp_UserOfflineSmall Offline

Please check out this jsfiddle: http://jsfiddle.net/chLyz/1/

I am using selectize.js to enhance the selectboxes. This works with cell editing when the cell value before editing is not empty (!=""). However if the value is "" before editing the cell the new changed value is not accepted and neither veforeSaveCell nor afterSaveCell is being triggered.

I tried to fix this all day but till now I have not found any solution.

When you check out the jsfiddle please see the difference when changing the value in the "ship column" especially in the last 2 rows.

I hope some one of you has any idea.

thanks for taking a look into this!

PS: when the selectbox is set to "multiple" this error does not occure

24/02/2014
12:31
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Please, try not to use selectize and see if this work. Just use simple select box definition.

Please, let me know if this in this case work.

I that there is a problem with the used selectize. If I select a value nothing is selected and empty value is set always.

Regards

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.

24/02/2014
13:09
Avatar
nexenator
Member
Members
Forum Posts: 6
Member Since:
27/10/2010
sp_UserOfflineSmall Offline

Hi and thanks for looking in to this.

It works fine without selectize. In the jsfiddle a no value is returned because of the alert – if you take out the alert it shows the correct value with selectize if the original value is not empty.

Is there any way to force a return value back to jqgrid (if you inspect the original select element it carries the correct value on change of selectize)?

One idea is to reinitialize the before and afterSaveCell events as I suspect selectize to somehow catch/overwrite those events.

EDIT: It does not return a value even if the alert is taken out - however in my live-app this is the case (I'm on the latest version of jqGrid)

24/02/2014
17:04
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

It seems this plugin make some changes that are not compatible. Note that the pugin  attach  a lot of events whch may cause the problem. Maybe you will need to find some other solution.

Regards

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.

24/02/2014
17:29
Avatar
nexenator
Member
Members
Forum Posts: 6
Member Since:
27/10/2010
sp_UserOfflineSmall Offline

Please check out the updated fiddle: http://jsfiddle.net/chLyz/2/

In the last column i've added a multiselectbox using selectize as well. What is really wierd is that the afterSaveCell event catches the correct values but the cell is not updated correctly.

This is what makes me think it's got something to do with jqGrid.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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