-
Notifications
You must be signed in to change notification settings - Fork 361
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added search by columns, ie. Filtering, and more #280
base: master
Are you sure you want to change the base?
Conversation
This looks really cool! |
I am instantiating the bootgrid as follows: $("[data-toggle=bootgrid]").bootgrid({..... How to use your implementation? |
@renerlemes var grid = $("#idOfHtmlTable").bootgrid({maybe some stuff here}); You only use "data-toggle=bootgrid" if you wanted to initialize a basic bootgrid on a html table without calling any Javascript See the examples here: As for my own work, once the table is initialized properly, you should only have to call the functions like I showed in my pull request. If anyone finds any bugs/issues, let me know. |
I was able to use its implementation. So could implement in an HTML page without using JavaScript |
Updated to add new stuff that was necessary for my project. I wonder if it would've been easier to go with a more complete table implementation..? haha |
I'm trying to use the |
@EdwardsNick: where did you end up with this? It would be nice to see a usage example for getRowData |
@bellwood I haven't looked at this code since using it last year, but it was used in a University project which can be found here: https://github.com/EdwardsNick/lackingllamas There should be examples of using everything in that project if you search, but if you just want to see an example of what it can do without building the project, I will host it here for you: http://e7a3f6e9.ngrok.io |
Github's repo search is being abhorrently annoying... Searching your repo for getRowData yields no results, grr. If you simply had usage snippet for that one piece of functionality that would be fine vs spinning up a hosted instance, etc. Thanks =) |
Here I get the row data by passing in the id for the row I want. IIRC the row ids, I believe are the first column of the table. For example, if the first column you used was just indexes, you could access the first row with grid.bootgrid("getRowData", "1"); You can then access the data in the row using the name of the column id defined in the html like so: . ie. I could access the data in the desc column with row.desc. Hopefully, that works for you. Like I said, it's been awhile since I've looked at this code. |
@EdwardsNick thank you very much... This fixes so many issues accessing data =) |
Why is this not merged already? |
@manumuve the author has been absent for quite some time. |
@bellwood it seems like that indeed.. :( |
This is one example of a feature that I would greatly enjoy to use. Is there no way to get hold of RStaib? Someone with the right skill set maybe taking over? |
@rstaib was active on Github last month. If you go to their profile page, there is a contact email you could try? |
Closes #242
Closes #241
Closes #207
Closes #50
Closes #247
Closes #175
Closes #57
Closes #143 ?
Closes #266 ?
Edit 2.0 : Filtering by Columns, Constraints for column filtering, changing default sort, allow tree like structure filtering (IE showing sub elements on match), as well as pulling individual row data with ease
Needed this for a project, so I implemented it.
To search on columns you use the following functions:
To add a greater than or less than constraint to the search instead on simple regex match
Use other sorting orders
To allow sub elements to match on filtering
Note: The identifier used for the table must be formatting in such a way to allow this.
For example: 1, 1.1, 1.1.1, 1.2.1, 1.2.2 as identifiers would work great.
If the row with identifier 1.2 matched the filters or search, then 1.2.1 and 1.2.2 would also match
To grab the data for a row given its identifier
Also, Searching via the default search bar still works after filtering. The search is simply applied to the results of the filters.
For a complete example, I will be making the project I used this on public within a few days, stay tuned: