Open
Conversation
An example and corresponding edits to stream_table.js to be able to use multiple StreamTable.js on one page
The progress indicator was removed when first one hit 2000.
The new selector is slightly more restrictive, in case somebody has .active in container for other purposes.
Author
|
There is actually still a small bug, that breaks the original stream.html example. (In a case where search_box hasn't been given an id in initialization. I'll look into fixing it, and submitting a new pull request once fixed. |
As my code prepends a '#' to the search_box id later on, this caused issues (double ##) when search_box wasn't provided in initialization parameter as in multiple.html-example. Now fixed.
Author
|
Now fixed. Tested with original examples: index.html, sorting.html, stream.html as well as new multiple.html. All worked. |
There was a problem hiding this comment.
I'm not the maintainer on this, but as a user, I'd much rather be able to provide any jQuery selector and not be constrained to an ID.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Here is an example of multiple stream_tables on same page. The example closely resembles the stream.html example, but it has the initial HTML for two tables. It requires that the HTML has uniqueIds for elements. If both tables contain same columns, one template can be utilized. Also a few slight modifications to the stream_table.js were necessary in order to have the paging/searching work as intended. I hope you can review this, and merge it back to the project?