Exemple #1
0
        public static List <ChildCardModel> ConvertToChildCardModelList(this ICollection <Child> chList)
        {
            List <ChildCardModel> chModelList = new List <ChildCardModel>();

            try
            {
                foreach (var ch in chList)
                {
                    ChildCardModel chModel = new ChildCardModel();
                    chModel = ch;
                    chModelList.Add(chModel);
                }
            }catch (Exception)
            {
                chModelList = null;
            }
            return(chModelList);
        }
       public static List<ChildCardModel> ConvertToChildCardModelList(this ICollection<Child> chList)
        {
            List<ChildCardModel> chModelList = new List<ChildCardModel>();

            try
            {
                foreach (var ch in chList)
                {
                    ChildCardModel chModel = new ChildCardModel();
                    chModel = ch;
                    chModelList.Add(chModel);
                }

            }catch(Exception)
            {
                chModelList = null;
            }
            return chModelList;
        }