예제 #1
0
        public static ClassTopic ToEntity(ViewClassTopic model)
        {
            ClassTopic item = new ClassTopic();

            item.Id         = model.Id;
            item.ClassID    = model.ClassID;
            item.TopicID    = model.TopicID;
            item.IsDeleted  = model.IsDeleted;
            item.CreateTime = model.CreateTime;



            return(item);
        }
예제 #2
0
        public static ViewClassTopic ToViewModel(ClassTopic model)
        {
            if (model == null)
            {
                return(null);
            }

            ViewClassTopic item = new ViewClassTopic();


            item.Id         = model.Id;
            item.ClassID    = model.ClassID;
            item.TopicID    = model.TopicID;
            item.IsDeleted  = model.IsDeleted;
            item.CreateTime = model.CreateTime;


            return(item);
        }