Opened 10 years ago

Closed 6 years ago

#9122 closed defect (invalid)

[patch] [cla] dojox.grid.DataGrid: setStore doesn't resize the grid if there are no items in the store

Reported by: msmith Owned by: msmith
Priority: high Milestone: future
Component: DojoX Grid Version: 1.3.0
Keywords: DataGrid resize setStore Cc:
Blocked By: Blocking:

Description

Using the setStore() function in the Grid is very handy to refresh the Grid with new data. In the event that the new data does not contain any items, the DataGrid? will display the NoDataMessage? below the existing div node for the Views. Re-rendering the views and calling the private _resize() function addresses the issue. Please see the attached patch.

It's been a while since I've submitted a patch, so if it's not quite the right format, please let me know.

Attachments (1)

DataGridSetStore.patch (6.3 KB) - added by msmith 10 years ago.
Patch file with unit tests

Download all attachments as: .zip

Change History (8)

Changed 10 years ago by msmith

Attachment: DataGridSetStore.patch added

Patch file with unit tests

comment:1 Changed 10 years ago by Nathan Toone

(In [20270]) Refs #9122 - fixes issue with empty store - thanks for the patch and test case. !strict

comment:2 Changed 10 years ago by Nathan Toone

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

The previous commit addresses the empty store issue - however, there are still issues if you try to switch stores while the slow-loading-store is loading, as well as if you choose the error store (it appears you can't change any store after setting the error store).

comment:3 Changed 10 years ago by Nathan Toone

(In [20271]) Fixes #9158 Refs #9122 - clear pending requests when an error occurs !strict

comment:4 Changed 10 years ago by Nathan Toone

The previous patch addresses the changing of the store after setting the error store. The only remaining problem is if you switch stores during a slow-loading-store load.

comment:5 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:6 Changed 6 years ago by Kitson Kelly

Owner: set to msmith
Status: newpending

I am afraid this patch is horribly stale. If still interested in this patch and if it is still needed, if you could update it against trunk and resubmit.

comment:7 Changed 6 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Note: See TracTickets for help on using tickets.