mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-04-05 21:01:35 +08:00
Adding dynamic Content property to the Content Item class for easily accessing Parts and Fields. Thanks Sébastien! :)
This commit is contained in:
parent
ab12ff6a05
commit
af76305088
@ -15,6 +15,8 @@ namespace Orchard.ContentManagement {
|
||||
|
||||
ContentItem IContent.ContentItem { get { return this; } }
|
||||
|
||||
public dynamic Content { get { return (dynamic)this; } }
|
||||
|
||||
public int Id { get { return Record == null ? 0 : Record.Id; } }
|
||||
public int Version { get { return VersionRecord == null ? 0 : VersionRecord.Number; } }
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user