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

Producers: Certifications filter (add 'All Certifications' option on API) #69

Open
kirstenalarsen opened this issue Mar 6, 2024 · 18 comments

Comments

@kirstenalarsen
Copy link

@JbPasquier comment on Slack

It seems that there are no relation between https://api.regenerative.org.au/webhook/regen/assurance?id=recllpzAo2WyaVvGz and https://api.regenerative.org.au/webhook/regen/certification?id=Organic
So I have no way to filter those certifications.
Maybe you can replace ofn:Certification_status with an ofn:certification with a value like this {"@id": "https://api.regenerative.org.au/webhook/regen/certification?id=Organic"} ?

@mkllnk thinks there may be a missing attribute, working on this today

@kirstenalarsen
Copy link
Author

I think you are suggesting in Slack that there are potentially two problems here: one is the same as the Supporting Evidence filter (i.e. in the framework at your end) and the other could be related to data. Can you tell us any more about your hunch with data - is there anything @maikel can investigate or this is really with you?

@JbPasquier
Copy link

JbPasquier commented Mar 6, 2024

@mkllnk already fixed the issue with the datas. Maybe there are something more but for now it's all on Startin'blox end.

@kirstenalarsen
Copy link
Author

Great, thanks

@JbPasquier
Copy link

Fixed!

@kirstenalarsen
Copy link
Author

kirstenalarsen commented Mar 13, 2024

Hurray!! Getting there!

Image

Couple of comments
[] This needs to be multi-select, as per #20
[] How hard would it be to have an 'all Certified' option? (this could be a @mkllnk question) - this would then work the same as the 'Certified' option under 'Ecological Outcomes -> Supporting Evidence'

@JbPasquier
Copy link

For reference.

How hard would it be to have an 'all Certified' option? - this would then work the same as the 'Certified' option under '#21

#21 (comment)

@kirstenalarsen kirstenalarsen changed the title Filter Producers by certifications Producers: Certifications filter Mar 21, 2024
@kirstenalarsen
Copy link
Author

@mkllnk can you please implement an 'all Certifications' option on the API so that it can appear on the filter

@kirstenalarsen kirstenalarsen changed the title Producers: Certifications filter Producers: Certifications filter (add 'All Certifications' option on API) Mar 21, 2024
@mariocarabotta
Copy link

it should be shown at the top of the list

@rioug
Copy link

rioug commented Apr 16, 2024

Added 'all Certifications' option in the API.
I believe it's for @JbPasquier to fix the filtering now.

@JbPasquier
Copy link

What needs to be fixed?

@mariocarabotta
Copy link

not sure if it requires @rioug or @JbPasquier, apologies.

the option in the dropdown is now coming through BUT it doesn't filter as it should (doesn't show any producer)

Screenshot 2024-04-17 at 9 14 16

you can test it here https://regenerative.org.au/directory/

@kirstenalarsen
Copy link
Author

Is this back to @mkllnk or @JbPasquier ?

@kirstenalarsen
Copy link
Author

kirstenalarsen commented Apr 17, 2024 via email

@rioug
Copy link

rioug commented Apr 17, 2024

@JbPasquier If am not mistaken the filtering is handled by the component, so the filtering should to be fixed as explained above :

When 'All Certifications' is selected, it should show every Producer that
has a certification (any one of them)

@JbPasquier
Copy link

JbPasquier commented Apr 17, 2024

The filtering is data-driven. If your producer datas does not include this entry on their certifications, then it'll not be filtered.

@mkllnk
Copy link
Member

mkllnk commented Apr 19, 2024

I'm not sure how we proceed here. Right now we have a filter by certain certification types. We added a special "All Certifications" option to the list and we would like it to show all producers that have any certification.

@JbPasquier, you are suggesting to add data to the producers. We could do that. So any producer which has a certification would get one additional certification of the type "All Certifications". The problem with this is that it would also appear in other parts of the directory as an actual certification, but it's just a dummy entry for the filter.

Two possible solutions:

  • We add that All Certifications certification to producers and the component needs to hide this special one from the details pages. This is work for you and me.
  • We somehow make that one option special to become an any filter. It does sound reasonable to me for a filter component to support an "any" and a "nothing" option, corresponding to "show me enterprises with at least on certification from the options list" and "show me enterprises with no certifications from the options list". I'm mentioning the no option just for completeness, we don't actually need. That would be work for you. Scope is a bit grey because the original spec was a multi-select which needs new endpoints. That brings me to the next solution:
  • We implement an endpoint for this filtering. Then you could easily do a multi-select and since we do the filtering on our side, we can have any option we like, right?

@mariocarabotta
Copy link

it has been decided that we are NOT going to show the All Certification option for the 6th May launch. We will address this more comprehensively together with a few other updates to filters.

@rioug to remove the filter option and push this back to Design / Planning / Estimate

@rioug
Copy link

rioug commented Apr 23, 2024

Done.

@JbPasquier JbPasquier removed their assignment May 2, 2024
@mkllnk mkllnk transferred this issue from openfoodfoundation/openfoodnetwork Jun 5, 2024
@mkllnk mkllnk unassigned mkllnk and rioug Jun 5, 2024
@kirstenalarsen kirstenalarsen moved this from Design / Planning / Estimate to Delete in Discover Regenerative Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Icebox
Status: All the things 💤
Development

No branches or pull requests

5 participants