Пример #1
0
        public static VIEW_SET_REGION ToViewModel(SET_REGION model)
        {
            VIEW_SET_REGION item = new VIEW_SET_REGION();

            item.REGION_ID   = model.REGION_ID;
            item.REGION_NAME = model.REGION_NAME;
            item.REGION_PID  = model.REGION_PID;
            return(item);
        }
Пример #2
0
        public static SET_REGION ToEntity(VIEW_SET_REGION model)
        {
            SET_REGION item = new SET_REGION();

            item.REGION_ID   = model.REGION_ID;
            item.REGION_NAME = model.REGION_NAME;
            item.REGION_PID  = model.REGION_PID;
            return(item);
        }
Пример #3
0
        public static IEnumerable <VIEW_SET_REGION> ToListViewModel(IEnumerable <SET_REGION> list)
        {
            var listModel = new List <VIEW_SET_REGION>();

            foreach (SET_REGION item in list)
            {
                listModel.Add(VIEW_SET_REGION.ToViewModel(item));
            }
            return(listModel);
        }