Last active
August 29, 2015 14:08
-
-
Save JustinK/f5821a3e1899d778b2a8 to your computer and use it in GitHub Desktop.
This file contains 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
[WebMethod] | |
public static List<Type> GetTypeList(string categoryId) | |
{ | |
var types = new List<Type> | |
{ | |
new Type(){ Name = "Red", Id=1, CategoryId=5 }, | |
new Type(){ Name = "Blue", Id=2, CategoryId=5 }, | |
new Type(){ Name = "Green", Id=3, CategoryId=3 } | |
}; | |
var catId = Convert.ToInt32(categoryId); | |
types = types.Select(p => p.CategoryId == catId).ToList(); | |
return types; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment