public static Course Create(CourseCreate.CommandModel commandModel) { var course = new Course { CourseID = commandModel.CourseID, DepartmentID = commandModel.DepartmentID, Title = commandModel.Title, Credits = commandModel.Credits }; return course; }
public static EntityStateWrapperContainer Create(CreateCourse.CommandModel commandModel) { var course = new Course { CourseID = commandModel.CourseID, DepartmentID = commandModel.DepartmentID, Title = commandModel.Title, Credits = commandModel.Credits }; return new EntityStateWrapperContainer().AddEntity(course); }