Added notion of author (owner) and editor to allow the editing of node by non owner users.

This commit is contained in:
2017-03-03 11:12:51 +01:00
parent 4cbdfeff06
commit 6cb6dd1609
18 changed files with 248 additions and 70 deletions

View File

@@ -276,7 +276,11 @@ feature -- Hooks
if l_entity.is_published then
if l_entity.author = Void then
-- FIXME!!!
l_entity.set_author (l_blog_api.cms_api.user)
if attached l_entity.editor as l_last_editor then
l_entity.set_author (l_last_editor)
else
l_entity.set_author (l_blog_api.cms_api.user)
end
a_import_ctx.log (l_node_type.name + " %"" + fp.utf_8_name + "%" WARNING (Author is unknown!)")
end
if attached l_entity.author as l_author then