Projection Filter by Custom Field

Topics: Writing modules
Feb 15, 2013 at 1:18 PM
Edited Feb 15, 2013 at 1:20 PM
I create custom field and would like to use it in prejection as filter.
My custom filed stores the values ​​in my custom table.

Can i give to projection a value from code (are not stored in Orchard_Framework_ContentItemVersionRecord)
Feb 15, 2013 at 1:58 PM
Edited Feb 15, 2013 at 1:58 PM
By Custom Field, are you referring to a content field, or a property on a record class?
Feb 15, 2013 at 2:07 PM
My field:
    public class RelationshipField : ContentField {

        internal LazyField<IEnumerable<ContentItem>> _contentItems = new LazyField<IEnumerable<ContentItem>>();

        public IEnumerable<ContentItem> ContentItems {
            get {
                return _contentItems.Value;
I fill _contentItems in RelationshipFieldHandler.
Feb 15, 2013 at 11:48 PM
I whould like to filter by MyField.ContentItems.Count() value