This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class NavController : Controller | |
{ | |
public PartialViewResult Menu() | |
{ | |
var controllers = new List<string> { | |
"Home", "Page", "User" | |
}; | |
return PartialView(controllers); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ObjectIdConverter : TypeConverter | |
{ | |
public override bool CanConvertFrom(ITypeDescriptorContext context, | |
Type sourceType) | |
{ | |
if (sourceType == typeof(string)) | |
return true; | |
return base.CanConvertFrom(context, sourceType); | |
} |