Closed jduss4 closed 7 years ago
I decided to stick with a pipe for now, and the API is just looking for either |
or %7C
which is the pipe encoded.
This is how the following are being handled, now. Input requested from @techgique and @karindalziel
Filter separators: |
f[]=category|Writings
f[]=date|1884
f[]=date|1884-09-12|1887-01-01
Sorting filters: |
sort[]=term|asc
Nested Fields: .
f[]=creator.name=Cather
facet[]=contributor.role
Faux Nested Fields (aka DATE HISTOGRAMS): .
facet[]=date.year
returns 1884, 1885, 1886, etcfacet[]=date
returns 1884-01-01, 1884-09-10, etcf[]=date|1884
<-- filter does not need to know "year" since it will create rangeDoes the above make sense? I can come up with some other examples, too, if needed. I specifically want to make sure that the date distinctions make sense to everybody.
Ah, I thought we were using the | only to separate multiples, I misunderstood. I guess we just repeat the field for those, huh?
I have a slight preference for f[]=category:Writings
but you're right that : might be used elsewhere. In solr, the standard is to put things in quotation marks f[]=category:"Writings"
if there's likey to be any confusion.
Do you think we should add the option of quotation marks just in case the | characters shows up somewhere? (f[]=person|"Weird|Person"
) or do you think that's too paranoid?
We're going with the pipe for now! This will require more testing if something has a pipe in its name, but we can investigate that in a different issue
In the Swagger docs we were using a pipe for things like:
Need to find a character that will likely not be used in titles, categories, names, etc. (gorram
"Yellowstone Kelly: That Dude's Name"
) and use that