Opened 10 years ago

Closed 6 years ago

#9723 closed defect (patchwelcome)

grid passing _item to a formatter has trouble when defaultValue is set

Reported by: dtynan Owned by:
Priority: high Milestone: future
Component: DojoX Grid Version: 1.3.2
Keywords: Cc:
Blocked By: Blocking:


I'm using the latest nightlies. I don't have a testcase to attach, but I have an example available on my site.

URL #1 -- this grid works properly

URL #2 -- this one has trouble

Hopefully you'll be able to see this from remote (timing could be an issue).

I'm passing "_item" to my formatter function in the grid's structure definition. This works great in example #1. However, in example #2, the first several items in the grid will show as "undefined" (and in the console log). The difference between the two is that in example #2, I have added a defaultValue to the grid's layout structure.

In my opinion, having defaultValue set should not cause _item to act like it's asynchronous (which is what it looks like it's doing). The reason I'm setting a defaultValue, by the way, is so that after the grid is sorted & the user scrolls down, the empty rows that are displayed are sized right & don't have the "..." default cell value in there (this makes it look consistent when scrolling .. whether or not you have sorted)

If my example doesn't work, please email me & I'll fix it (dtynan at ye olde is the address.

Thanks, Dylan Tynan

Change History (4)

comment:1 Changed 10 years ago by Nathan Toone

Milestone: tbd1.5
Owner: changed from Bryan Forbes to Nathan Toone

comment:2 Changed 9 years ago by Nathan Toone

Milestone: 1.5future
Owner: Nathan Toone deleted

Moving my tickets to future, as I am not currently working on them.

comment:3 Changed 6 years ago by bill

DojoX Grid and EnhancedGrid are deprecated in favor of dgrid and gridx.

You should upgrade your code to use one of those two grids.

We will consider patches to the old DojoX Grid code though.

comment:4 Changed 6 years ago by bill

Resolution: patchwelcome
Status: newclosed
Note: See TracTickets for help on using tickets.