The parent field was being set to null because the id wasn't set yet. I referenced this webiny source file, the form model for a beforeCreate hook implementation that did this well.
Result is that the parent ID value is now set correctly on createArticle and createArticleFrom. This screenshot below shows that. It also shows that I need to do some work on the listArticles function as I don't think it should be returning all revisions of a single article, as also shown in the screenshot.
Issue #54
The
parent
field was being set tonull
because theid
wasn't set yet. I referenced this webiny source file, the form model for abeforeCreate
hook implementation that did this well.Result is that the parent ID value is now set correctly on
createArticle
andcreateArticleFrom
. This screenshot below shows that. It also shows that I need to do some work on thelistArticles
function as I don't think it should be returning all revisions of a single article, as also shown in the screenshot.