/// <summary> /// 카테고리 정보를 가져온다. /// </summary> /// <returns></returns> public static CategoryModel GetMyCategorys(Type type) { SqlParameter[] param = { CreateInParam("@PeridoNewIcon", SqlDbType.Int, 4, Blog.BlogManager.GetInstance().BlogBaseModel.BlogModel.PeridoNewIcon) }; SqlCommand cmd = GetSpCommand("UBI_GetMyCategorys", param); try { SqlDataReader reader = cmd.ExecuteReader(CommandBehavior.CloseConnection); CategoryModel model = CreateCategoryModelFactory(type); while (reader.Read()) { CategoryModel item = new CategoryModel(); item.CategoryID = (int)reader["CategoryID"]; item.CategoryTitle = reader["CategoryTitle"].ToString(); item.CategoryLCode = (int)reader["CategoryLCode"]; item.CategoryMCode = (int)reader["CategoryMCode"]; item.CategoryGroup = (int)reader["CategoryGroup"]; item.CategoryStep = (int)reader["CategoryStep"]; item.CategoryOrder = (int)reader["CategoryOrder"]; item.ArticleCount = (int)reader["ArticleCount"]; item.NewIcon = (bool)reader["NewIcon"]; model.Add(item); item = null; } return(model); } catch (Exception ex) { throw new UmcDataException("UBI_GetMyCategorys 프로시져 호출중 에러", ex.Message); } finally { ReleaseCommand(cmd); } }