-
Notifications
You must be signed in to change notification settings - Fork 22
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
feat: highlights from admin #3236
Conversation
@@ -29,14 +29,14 @@ router.get("/highlights/:slug", async (ctx) => { | |||
if (response.body.hits.total.value === 0) { | |||
ctx.throw(404, `there is no highlights data`); | |||
} | |||
const highlightsData = response.body.hits.hits[0]._source.data; | |||
const highlights = highlightsData.find( | |||
const highlightsCollections = response.body.hits.hits[0]._source.collections; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Je crois que la route highlights retourne tous les champs et ne passe pas par la route items
qui oblige à renseigner tous les champs un par un mais regarder si il ne faut pas rajouter la clé collections
au mapping quand même.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
les highlight / pre-qualified / glossary sont wrappé dans une propriété data {} qui n'est pas présente dans le mapping.
il y a cette issue #2369 dans laquelle on peut compléter la liste
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
je remplace data par collections
côté admin justement (qui côté admin est dans document
), après je sais pas si c'est une bonne chose mais ça me parle un peu plus
5eea9d6
to
7ac6b9c
Compare
7ac6b9c
to
73b297f
Compare
9ea25fc
to
7861c37
Compare
waiting for admin pr to be done / merged first