news-catalyst / reproducible-tinynews-content-api

A webiny installation complete with scripted content models and graphql
0 stars 0 forks source link

Added a docIDs searchable field to articles #46

Closed jacqui closed 3 years ago

jacqui commented 3 years ago

This will allow us to look up an article by a google doc ID.

The new field is docIDs and is a space delimited list of google doc IDs associated with this article (in other words, the Object.values of article.googleDocs locale info). The implementation is the same as authorSlugs or availableLocales.

Use case: I've created a google doc for an existing article in a new locale, like, I had American English and I've created Spanish. I open the Spanish document, which has no metadata (limitation of the platform; can create new document, but no data on it except the title); I open the sidebar, which looks for an article with this google doc ID, finds it, fills in the missing info.