Skip to content
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

Search fails on columns in data set but not included in table #213

Closed
sandikbarr opened this issue Jan 14, 2016 · 6 comments
Closed

Search fails on columns in data set but not included in table #213

sandikbarr opened this issue Jan 14, 2016 · 6 comments
Labels

Comments

@sandikbarr
Copy link

The search function fails with error in v1.4.1/src/store/TableDataStore.js line 210, Cannot read property 'format' of undefined. I have a dataset where not all columns are included in the table. colInfos[key] from the row set is undefined, so it fails with error.

(Also a request: Since you are in very active development, it would be super helpful if you could distribute with source maps to help us help you.)

@AllenFang AllenFang added the bug label Jan 15, 2016
@AllenFang
Copy link
Owner

@sandikbarr, thanks your suggestions :) if interesting, you can join gitter :)

Anyway, about your problem, could please give me your examples code? because colInfos is created from src/BootstrapTable.js and it's according to your definition of TableHeaderColumn. So I think there's should not be any problem If not all columns are included in the table.

Thanks 👍

@sandikbarr
Copy link
Author

Hi. Here is a rough example showing the problem I am having: https://github.com/sandikbarr/show-me-what-you-got If you use the custom search control I added, it errors with "Cannot read property 'format' of undefined" (Sorry about all the linting errors, it's late here. Lmk if you have any trouble getting it running.)

@AllenFang
Copy link
Owner

Fixed it, check the v1.4.2

@sandikbarr
Copy link
Author

I updated my example at https://github.com/sandikbarr/show-me-what-you-got to v1.4.2. I'm seeing a lot of "Uncaught TypeError: Cannot read property '__html' of undefined" errors when I use my custom filter. I also tried 1.4.3, and I saw the same errors when I used the clear button on my custom search. My custom filter is just calling the handleFilterData, and search is calling handleSearch. Let me know how I can help track this down. Thanks.

@AllenFang
Copy link
Owner

@sandikbarr, I'll check this out :)

@AllenFang
Copy link
Owner

@sandikbarr, sorry for a long fixing, please check the newest version :0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants