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

Planning issue for advanced search UI #987

Closed
5 tasks
jywarren opened this issue Nov 15, 2016 · 4 comments · Fixed by #3357
Closed
5 tasks

Planning issue for advanced search UI #987

jywarren opened this issue Nov 15, 2016 · 4 comments · Fixed by #3357
Labels
break-me-up break up for cleaner code separation, discrete tests, and, easier and iterative collaboration fto-candidate issues which are meant to be solved by first timers but aren't well-formatted yet help wanted requires help by anyone willing to contribute Ruby

Comments

@jywarren
Copy link
Member

jywarren commented Nov 15, 2016

This needs to be broken up into several sub-issues, some of which could be first-timers-only candidates:

https://publiclab.org/search/dynamic is a new search system based on the RESTful API, but it has some rough edges.

  • some items appear more than once (need a uniqueness parameter somewhere?)
  • limiting # of results and paginating with .paginate() as is done on many other parts of the site (will improve speed)
  • shortening descriptions shown if paragraphs are too long
  • possibly displaying author and how recently a piece of content was updated
  • advertise dynamic search as a beta service at /search

and more?

image

@jywarren jywarren added break-me-up break up for cleaner code separation, discrete tests, and, easier and iterative collaboration fto-candidate issues which are meant to be solved by first timers but aren't well-formatted yet help wanted requires help by anyone willing to contribute Ruby labels Nov 15, 2016
@Pk13055
Copy link
Contributor

Pk13055 commented Dec 10, 2016

Have you reached some stand on which issues are to be tackled first? I could get a headstart if you've decided upon something

@jywarren
Copy link
Member Author

I think a number of them could be broken out, but need hints to where they appear in lines of code.

The .paginate() one is one which is probably in this controller -- but the dynamic search page action is empty:

https://github.com/publiclab/plots2/blob/master/app/controllers/searches_controller.rb#L32

So I think it makes calls via JavaScript to other actions, but am not sure which. That needs some exploration (or input from @david-days?) and we could leave some helpful comments in that controller to describe what the actions do.

I'm also not sure -- can we run .paginate() (a feature of will_paginate_rails gem) on these search records?

As to the too-long descriptions, i think thatd be in javascript in this page of code, but am also not sure:

https://github.com/publiclab/plots2/blob/master/app/assets/javascripts/dynamic_search.js#L155

For either of these, we could write tests (and examine existing ones) to confirm this, starting with this page and moving on to JavaScript testing in Jasmine:

https://github.com/publiclab/plots2/blob/master/test/functional/restful_search_test.rb

There is a simple unit test for search result documents here, and perhaps we could test out the pagination by adding a new test there, once we get more info on it:

https://github.com/publiclab/plots2/blob/master/test/unit/doc_result_test.rb

So, plenty of starting places and investigating and adding comments is actually a good first step.

@jywarren jywarren added this to the API and search improvements milestone Jan 17, 2018
@ebarry
Copy link
Member

ebarry commented Mar 7, 2018

I'm wondering, with the recent updates, what of this issue is still current generally as "next steps for search"?

Also, is there a way to use Google search inside our site, or use something from the information sciences? Perhaps we don't have to write each of these features? Wondering.

@jywarren
Copy link
Member Author

jywarren commented Mar 7, 2018

Hi, this is for dynamic search, not search overall -- see leading link above. All of these are still up for grabs, as dynamic search may eventually replace standard search (i.e. http://publiclab.org/search/wind)

@jywarren jywarren changed the title Tweaks and next steps for dynamic search Planning issue for advanced search UI Jul 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
break-me-up break up for cleaner code separation, discrete tests, and, easier and iterative collaboration fto-candidate issues which are meant to be solved by first timers but aren't well-formatted yet help wanted requires help by anyone willing to contribute Ruby
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants