Beispiel #1
0
 public ActionResult ElementTypeList(DataModel model)
 {
     ViewBag.Title      = "ElementTypeList";
     model.ElementTypes = ElementTypes.GetElementTypes(model.Query);
     foreach (ElementType item in model.ElementTypes)
     {
         item.AttributesCount = ElementTypeAttributes.CountElementTypeAttributes(item.Id);
     }
     return(View(model));
 }
Beispiel #2
0
        public ActionResult ElementTypeAttributeList(Guid id)
        {
            ViewBag.Title = "ElementTypeAttributes";
            DataModel model = new DataModel();

            model.ElementTypeAttributes = ElementTypeAttributes.GetAttributesByElementTypeId(id);
            model.SelectedElementType   = ElementTypes.GetElementTypeByElementTypeId(id);

            foreach (ElementTypeAttribute item in model.ElementTypeAttributes)
            {
                item.AttrValueCount = Attributes.CountAttributeValues(item.AttributeId);
            }

            return(View(model));
        }