okfn-brasil / jarbas

🎩 API for information and suspicions about reimbursements by Brazilian congresspeople
https://jarbas.serenata.ai/
296 stars 61 forks source link

Fix bug when using full text search w/ filters #255

Closed cuducos closed 7 years ago

cuducos commented 7 years ago

252 introduced a small but nasty bug: in the dashboard if you use the search box all filters are ignored. This PR fixes this bug.

How to test it: open the dashboard, select a filter (for example, list only suspicions reimbursements) and then try a text search from the search box. If the results show the filter is combined with the text search it worked, yay!

anaschwendler commented 7 years ago

What I did to test this PR

1 - Clone the project

$ git clone git@github.com:datasciencebr/jarbas.git

2 - Get in the folder

$ cd jarbas

3 - Checkout to @cuducos PR

$ git checkout -b cuducos-combine-full-text-search-ans-filters origin/cuducos-combine-full-text-search-ans-filters

4 - Run the enviroment

$ make run.devel

4 - Access localhost:8000, and the result: With suspicions only filter: image

Searching for restaurante: image

Merging it!