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
setCell Function with empty Value
16/12/2009
16:01
Avatar
Hannes Käufler
Guest
Guests

Hi!

When I´m using Cell Edit with custom Select, I have an option with value="". But this breaks the Grid.

I had to alter grid.base.js on line 2122

$(tcell).html(v).attr("title",$.jgrid.stripHtml(v));

to 

if (v == "" || v == undefined) {

$(tcell).empty().attr("title", "");

}

else {

$(tcell).html(v).attr("title",$.jgrid.stripHtml(v));

}

There´s most likely a better way to fix this, but that´s what I did.

Greetings, Hannes

Btw. awesome plugin!

17/12/2009
15:24
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Thanks for this and seems reasonable, But this will brake the situation where we want to set a new

class or other attributes without to tuch the cell values.

I will try to find better solution.

Thanks

Best 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.

17/12/2009
16:10
Avatar
ben
Member
Members
Forum Posts: 9
Member Since:
19/10/2009
sp_UserOfflineSmall Offline

Maybe something can be done considering undefined, null and "" are three different values.

22/12/2009
08:56
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

I'm thinking on additional parameter forceUpdate, which maybe will do the job.

Best 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.

17/03/2010
17:37
Avatar
Yurgen
Member
Members
Forum Posts: 8
Member Since:
16/10/2009
sp_UserOfflineSmall Offline

Hi Tony!

Is there any update on this?

I have faced an issue having same nature ..... for some reason it happens under IE6/7 but not under IE8.

Thanks in advance.

Yurgen.

18/03/2010
11:20
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello

Thanks. Fixed. Will publish the fix late this day.

Best 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/03/2010
15:38
Avatar
Yurgen
Member
Members
Forum Posts: 8
Member Since:
16/10/2009
sp_UserOfflineSmall Offline

Hi Tony!

Could you please  tell how/when I can get fix?

Does it gonna be included in new version 'jqGrid 3.6.5' and I should wait until this bug fix release gonna be published? 

Do not wanna hurry you up but I need to check if your fix did help me a well.

Thanks in advance.

Yuri

(BTW, thanks a lot for such good Grid)

19/03/2010
16:02
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello Yuri,

Sorry for this. I really forgot to publish the fix - little busy these days.

Here we are

http://github.com/tonytomov/jq.....4be9a14839

Please let me know if this fixes your problem

Best Regsrds

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.

23/03/2010
14:13
Avatar
Yurgen
Member
Members
Forum Posts: 8
Member Since:
16/10/2009
sp_UserOfflineSmall Offline

Hi Tony!

Thanks a lot for this fix!

It did almost fix my IE6/7 issue. My issue does have same nature as topic_creator stated, but I needed to make a final modification to completely resolve mine 

Let me describe my issue first:

I have simple grid which fed with test data to show. Some of data cell  have value, others are NULL.

And (under IE6/7 only) after grid loaded and I clicked NULL cell, then moved focus to different cell, previously selected cell border got corrupted

Please see screenshot

Your recent fix with setCell() new param forceupd is perfectly Ok for me. The last step is to call setCell() with added param.

And that's it.

So, in gird.celledit.js

   restoreCell : function(iRow, iCol) 

instead of 

$($t).jqGrid("setCell",$t.rows[iRow].id, iCol, $t.p.savedRow[fr].v);

put 

   $($t).jqGrid("setCell",$t.rows[iRow].id, iCol, $t.p.savedRow[fr].v, null, null, true);

Tony, what do you think regarding this fix?

Would it be possible to include in next official release?

I'd like to have as smooth upgrade to future jqGrid as possible. Also hope it would help somebody else as well 🙂

Thanks a lot.

Yurgen.

23/03/2010
18:31
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Thanks. Done. Also I have do these in saveCell too. It really have sense.

Thank you again

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:
49 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