private static PreValueField MapAttributeToField(PreValueFieldAttribute att, PropertyInfo prop) { return(new PreValueField { //set the key to the property name if it is empty Key = att.Key.IsNullOrWhiteSpace() ? prop.Name : att.Key, Name = att.Name, Description = att.Description, HideLabel = att.HideLabel, View = att.View.StartsWith("~/") ? IOHelper.ResolveUrl(att.View) : att.View }); }
private static PreValueField MapAttributeToField(PreValueFieldAttribute att, PropertyInfo prop) { return new PreValueField { //set the key to the property name if it is empty Key = att.Key.IsNullOrWhiteSpace() ? prop.Name : att.Key, Name = att.Name, Description = att.Description, HideLabel = att.HideLabel, View = att.View }; }