Pegase745 / sqlalchemy-datatables

SQLAlchemy integration of jQuery DataTables >= 1.10.x (Pyramid and Flask examples)
MIT License
159 stars 67 forks source link

The filtering method is wrong #22

Closed ashl1 closed 8 years ago

ashl1 commented 9 years ago

Might the datatables.py:209 has the wrong test for the search request parameter? In current version no data is displayed, filtered by column search with empty string. The request has always contained the 'sSearch_i' parameters with empty string. The check now test it in according to 'None' but the result is always 'not None'. The code introduced by @tdamsma in the commit 3a99611a4b19258b6f78dc0125df7e1d1dfe8149.

I suggest to use the implicit check: "if search_value2:"

Pegase745 commented 9 years ago

You pasted the bad commit hash

ashl1 commented 9 years ago

Sorry, use my fork commit HASH. update it in the topic, please check again

Pegase745 commented 9 years ago

What version of jQuery Datatables are you using ?

ashl1 commented 9 years ago

I test it with both 1.9.0 (change the home.pt:10) and 1.10.0 with test-project