jsgrid icon indicating copy to clipboard operation
jsgrid copied to clipboard

"noDataContent" text is shown during loading

Open gp-slick-coder opened this issue 9 years ago • 5 comments

Should be shown if the json web-response returns an empty object.

How to reproduce:

  • go to http://js-grid.com/demos/odata-service.html
  • press F5
  • and you should see "No found" during the loading

gp-slick-coder avatar Feb 05 '16 12:02 gp-slick-coder

I agree, looks like not something expected. Thanks for the report!

tabalinas avatar Feb 07 '16 02:02 tabalinas

Any update on this issue? Thanks.

Kiongku avatar Aug 15 '16 04:08 Kiongku

I still don't see a good solution to this one. It happens because the data option is an empty array on the grid creation, and grid has no items indeed. So technically, this is the right behavior. We could show the grid without rows on the first load, but this also seems not correct. Imagine you have autoload: false, and grid is not loading automatically, but you want to load data yourself, or even don't want to use controller and just set data option when you want later. In this case you will have an empty grid, and this is not right behavior. Feel free to share how you see the right behavior.

tabalinas avatar Aug 15 '16 18:08 tabalinas

I would say all you need is if autoload: true simply show the loading overlay until its been loaded and if no data comes back then show the noDataContext. If data has been specified on initialising then simply show the noDataContext straight away.

almightyju avatar Dec 19 '16 23:12 almightyju

hello, any solution?

MaikRide avatar Apr 12 '23 00:04 MaikRide