Ask - Test
[JournalArticle] How to identify the creator of a version with workflow
[JournalArticle] How to identify the creator of a version with workflow
New Member Posts: 3 Join Date: 6/26/20 Recent PostsHi everyone,
I'm working with Liferay 7.4 (DXP) and I have a
question about the behavior of the approval workflow for web content (JournalArticle).
In a workflow-enabled scenario, I expected each version of a JournalArticle to properly track the user who actually created or updated it. In Liferay 7.1, this was the behavior I observed:
-
The
userName
anduserId
fields in theJournalArticle
table were set to the user who created or updated the version. -
The
statusByUserName
andstatusByUserId
fields tracked the user who approved the content via workflow.
However, in Liferay 7.4, I noticed that userName
and
userId
for each new version are always inherited from the
previous version (typically the original creator), even if another
user actually modified and saved the content (and someone else
approved it).
Example:
-
User 1 creates the content → approved by User 2
-
User 3 edits and saves the content → approved again by User 2
Result: Version 2 still hasuserName = User 1
, which is misleading.
Question:
Is this the expected behavior in Liferay 7.4?
Is there a
reliable way to retrieve the user who actually created or modified
each version of the content, even when workflow is enabled?
Any tips on how to extract this information (via API, database, or customization) would be greatly appreciated.
Thanks in advance!
Tommaso
Powered by Liferay™