Replies: 1 comment 3 replies
-
Once you attach the content part to a content type, the content item will be versionable |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
The document table's version isn't sequence number. So I will add a part to keep some thing about version in ContentPartHandler<>. But I can't save into document table. My code:
public override Task PublishedAsync(PublishContentContext context, GWDocumentPart part)
{
if (context.PreviousItem == null)
{
part.DocumentVersion = 1;
}
else
{
part.DocumentVersion = context.PreviousItem.As().DocumentVersion + 1;
}
_contentManager.UpdateAsync(part.ContentItem);
}
Please somebody give me suggestion. Thanks!
Beta Was this translation helpful? Give feedback.
All reactions