I'm using the community version of Ag-Grid in a react-redux application. Even though AG-Grid is generally compatible with redux, implementing server-side pagination seems to be impossible!
The reasons:
Redux is asynchronous - data update does not occur right after dispatching the action
The only way to update rows and counter (lastRow index) without re-rendering the whole grid, is via successCallback as part of the grid event
Unfortunately, I couldn't find any solution for this scenario on the web. I know that other developers raised very similar concerns a couple of years ago, as can be seen here. However, no concrete update / info from the AG-Grid team is to be found.
Did anyone come across this scenario and was able to find a proper solution?
Do you know what is the official channel to reach the tech team and clarify that with them? (AG-Grid documentation does not suggest any concrete example).
Thanks in advance!
Related
I'm attempting to design a project in Laravel. I ran the following command to initialize the project: "laravel new demo --jet". When prompted to choose between inertia and livewire I chose livewire as I've heard better things about it.
A little back story, I'm about 2-3 weeks into learning Laravel and I've never used livewire before, although I am very familiar with using Javascript and am very experienced with Vue.js. I've looked elsewhere for a solution to my problem but now I'm not quite sure if Laravel even supports exactly what I'm looking for.
TL/DR:
I'm wondering what the best practice would be for rendering child components on a page. I would like to create a dashboard that has several options to choose from on the left side of the page. When a user selects an option, I'd like for a corresponding component to appear in the center of the page. If a user were to select a different option, the original child component would disappear and a new corresponding child component would become visible.
Ideally, I'd like to avoid using the router for this, although that might just be because I'm not entirely comfortable with using it. I do understand it's pretty heavily integrated into the Laravel workflow. As I mentioned, I'm used to using Vue where you can easily integrate JS functionality into your html and use conditional statements to hide/show child components without changing routes.
If anything I've said above is causing any confusion, let me know. Thanks.
P.S. If anyone has any good resources for learning livewire & laravel together please let me know about them! Laracasts has been great but I think Laravel recently updated their auth scaffolding and it's causing some confusion for me.
I'm currently working on a school project where we need to display database info in a web UI.
I have a YUI3 Datatable with built in client side pagination. Now I would like to implement server side pagination due to the massive amount of data I will have to work with.
Are there any good solid tutorials on how to implement server side pagination in YUI3?
I've already gone through the API and the YUI2 tutorials I've come across have features no longer supported in YUI3..
No, not that I can find.
I've used this paginator with great success. But the documentation that did exist seems to have vanished both from the github repo and from http://blunderalong.com/yui/gallery/datatable-paginator/paginator_examples.html where it used to live. It may be worth pinging the author a message about it.
Like barnyr, I've used Todd Smith's paginator with great success. I agree that the closest you can get to a tutorial is by perusing Todd's comments in the code.
When I pinged Todd with a fix for a resizing problem, he responded that he had stopped working on it. I guess it's up to us to figure it out now. Also, he seemed to believe that YUI must have either picked up his code from the gallery or developed an equivalent solution; neither seems to be the case right now.
It is sad that blunderalong is gone -- it had lots of goodies -- but I have Todd's server-side pagination example fossilised in my repo:
https://github.com/selkovjr/bfs/blob/master/mojits/Samples/binders/index.js
And here is the server-side model that provides the data for it:
https://github.com/selkovjr/bfs/blob/master/mojits/Samples/models/samples.server.js
It is a bigger pile than you're asking for (the binder code also has row selection and inline cell editing), but at least it has the example you're looking for, almost unchanged.
We are still using YUI 2 which is really good large amounts of data.
Try http://yui.github.io/yui2/docs/yui_2.9.0_full/examples/datatable/dt_dynamicdata.html
and it might be good to do SQL sort for heavy loads which is cheaper.
You can try following examples
http://jafl.github.io/yui-modules/querybuilder/ for complete datatable implementation
or http://jafl.github.io/yui-modules/paginator/ for different pagination samples.
I have implemented paginator successfully using this example.
My users browse products and add some of them to their baskets.
I use KnockoutJS to update the listing of the basket content.
However, users can open product links on multiple tabs/windows in the same session and pick one product on the first, another product on the second tab. I'd like to display the same basket content on each page, of course.
Is KnockoutJS able to update the DOMs of different tabs simultaneously?
I'd like a solution which updates the changes only, and immediately as KnockoutJS does on a single page. I was mentioning a basket to illustrate the problem, but a basket's content is relatively small and could be retrieved by an AJAX call easily when the user brings up a background tab. The real problem is different views of a huge database, which can be updated in multiple tabs and should look consistent on every tab. It takes several seconds to build up the DOM of a tab.
(This question is NOT about jQuery UI Tabs. The situation is as described in http://thesocialtester.co.uk/20-days-of-web-testing-multiple-tabs-and-windows/)
If the answer is not possible, I'd like to hear about workarounds or good practices.
Thanks in advance.
Knockout does not address the underlying general problem of communicating across browser tabs with javascript. There are other questions on this topic, and the same solutions will be usable with whatever framework you pick.
But no, Knockout makes no attempt to solve this problem.
As stated in the accepted answer, Knockout does not solve the cross-tab problem.
If your problem is strictly confined to the case of synching several tabs in the same browser, then using localStorage to pass messages (as described in this answer cited in the accepted answer seems like a sane solution.
The question is whether you don't really want to go further in solving this problem, and implement some form of server push to your shopping page, which would then also work cross-browser and cross-machine.
In this case, you'd want some solution which uses WebSocket (real server push to the client), possibly combined with a HTTP polling fallback for older browsers (if you need to support those).
Zend Framework 2 has implemented a lot of stuff for all the layers, but like nothing for GUI.
I am missings things like datagrids, dialogs, tree-views, autocomplete fields and all the stuff one has in JSF and Richfaces.
I thougt maybe extJS could be an alternative, but theres no production ready integration yet.
Why use ZF2 when I have to write code for hours and weeks for such simple things that should already be integrated in an enterprise ready framework ?
I spent very much time now for digging into ZF2 and I learned a lot.
But because of the missing View stuff in ZF2 I'm thinking of changing to another Framework now, after weeks of hard work.
Does someone have a better solution ?
Have a look at this module, you may find what you need :
https://github.com/mwillbanks/ZfcTwitterBootstrap
Also, I suggest you to have a look at the modules page :
http://modules.zendframework.com/
I don't like to answer my own questions, but I want to close this old one and maybe it helps someone else.
At the moment I am very happy with ZfcDatagrid by ThaDafinser.
https://github.com/ThaDafinser/ZfcDatagrid/commits/master
It didn't exist when I asked the question. And as you can see in this great module, it is a lot of work to create such a component for ZF2 and as you can see, it's not just a javascript being served. There's much much more logic behind with pagination, filtering, datasources, output formatting and much more.
You don't want to do this in your controller code, because you want to reuse the grid logic and every grid instance. And you don't want all that logic on client side, because of the same reason.
I am currently evaluating grid components for our new portal project. I came across the jqGrid which I find quite interesting. One requirement I have is that the portal should work with javascript switched off.
I found this article on StackOverflow but it does not answer the question. Does anyone can tell me how jqGrid is dealing with this?
In the question which you referenced I could fine the following
Can we create the table using C# and then lay the JS over the top for
extra functionality?
Is it what you plan? Do you want that your portal works without JavaScript and produce pure HTML tables which hold the data without any Ajax requests, but in case of the user do has JavaScript on you want to use JavaScript, jQuery and jqGrid?
In the corresponding answer it was suggested to use tableToGrid function to convert the existing HTML table inclusive the contain to the jqGrid. It seems me the way which you can also follow. Why you are not satisfied with the answer?
To tell the trust I have no customers more where JavaScript is switched off. Do you want to develop the portal for some mobile devices or some other special endpoints which has no JavaScript? In my opinion JavaScript have to be on to be able to use Internet for the better productivity. So the portal which work without JavaScript will have the interface which is not up to date now. Either you have very special customer environment or the requirement seems me too hard.