November Happy Hour will be moved to Thursday December 5th.

Custom DisplayOptions

Vote:
 

Hi, i am using a lot TemplateDescriptor, so I have different Templates for 1 model, 1 model can have like 5 or more templates, and i have like 20 model BlockData.

If i use DisplayOptions i am going to have a huge list about this templates like 100 options, so there is any change to create a new Option in the Block Context Menu that i can set a DropDonw Menu With 2 levels.

Right Now i am using a Block Like a container and i am setting diferents Tags using  ISelectionFactory

public abstract class TagSelection : ISelectionFactory
   {
       public IEnumerable<>ISelectItem> GetSelections(ExtendedMetadata metadata)
       {
           if (Items == null)
               return new List<>SelectItem>();
           return Items.Select(c => new SelectItem { Text = c.NameValue = c.Value });
       }
 
       public abstract IEnumerable<>Tag> Items { get; }
   }

 [EditorDescriptorRegistration(TargetType = typeof(String), UIHint = "TagEditor")]
   public class LinkTagEditor : EditorDescriptor
   {
       public LinkTagEditor()
       {
           ClientEditingClass = "epi.cms.contentediting.editors.SelectionEditor";
       }
 
       public override void ModifyMetadata(ExtendedMetadata metadataIEnumerable<>Attribute> attributes)
       {
           SelectionFactoryType = typeof(LinkTagSelection);
           base.ModifyMetadata(metadataattributes);
       }
   }


And it works, But i don't want to create a Container for every Block


Can i extend the Content Context Menu and Create a new Option by Block Type

Regards
#112553
Oct 30, 2014 5:58
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.