plazi / BLR-website

1 stars 0 forks source link

Facets filtering incorrect on test server #38

Closed tcatapano closed 4 years ago

tcatapano commented 4 years ago

on the test site (http://blr.uplaysandbox.website) a "Journal" search for term "European" (http://z2.punkish.org/v2/treatments?facets=true&stats=true&journalTitle=European) returns a Treatments result set with the following JOURNALTITLE facet values counts:

European Jornal of Taxonomy (20)

European Journal of Protistology (1)

European Journal of Taxonomy (2168)

European Mosqito Bulletin (15)

Setting aside the issue of the misspelled "Jornal" in one of the values, filtering on the value "European Jornal of Taxonomy" does not seem to reduce the results to 20 as would be expected. Possibly related, when the facet value is selected and the results rewritten the API URL does not change to show whether the facet query was made.

Not clear where the bug source is so assigning to both @punkish and @teodorgeorgiev

punkish commented 4 years ago

this is a website bug. In fact, there are two related website bugs, but first, if the query were to be made correctly, it would be http://z2.punkish.org/v2/treatments?facets=true&stats=true&journalTitle=European%20Jornal%20of%20Taxonomy which would result in 20 record as the facet suggested

{
  "value": {
    "search-criteria": {
      "journalTitle": "European Jornal of Taxonomy",
      "page": "1",
      "path": "treatments",
      "size": "30",
      "sortBy": "treatmentId:ASC",
      "xml": "false"
    },
    "num-of-records": 20,
    "_links": {
      "self": {
        "href": "http://z2.punkish.org/v2/treatments?journalTitle=European Jornal of Taxonomy&page=1&size=30&sortBy=treatmentId:ASC&xml=false"
      },
      "prev": {
        "href": "http://z2.punkish.org/v2/treatments?journalTitle=European Jornal of Taxonomy&page=1&size=30&sortBy=treatmentId:ASC&xml=false"
      },
      "next": {
        "href": "http://z2.punkish.org/v2/treatments?journalTitle=European Jornal of Taxonomy&page=1&size=30&sortBy=treatmentId:ASC&xml=false"
      }
    },
…

The two problems with the website:

  1. When checking the facet, the query did not change
  2. The website, strangely, reverted back to a page with no results (the standard starting page)

two bonus bugs or issues with the website

Note: I will try to assign only @teodorgeorgiev to this

teodorgeorgiev commented 4 years ago

@tcatapano - all fixed, please check. All query parameters have been added to the URL, so now you can share searches and report problems. With regards to the Safari issue - we couldn't make to reproduce it, but so far we have tested only on Safari on a virtual box. Sorry, no MAC at home :)