Esempio n. 1
0
        /// <summary>
        /// 获得数据列表
        /// </summary>
        private List <Model.article_category> DataTableToList(DataTable dt)
        {
            List <Model.article_category> modelList = new List <Model.article_category>();
            int rowsCount = dt.Rows.Count;

            if (rowsCount > 0)
            {
                for (int n = 0; n < rowsCount; n++)
                {
                    modelList.Add(dal.DataRowToModel(dt.Rows[n]));
                }
            }
            return(modelList);
        }