I have a data transfer object named SchoolyearEditRequest which has 4 properties holding domain objects.
1) Is it wrong that my DTO wraps domain entities?
2) If yes do I have to create for every domain entity a xxxDTO "wrapper" with only the really needed properties for the client side?
public class SchoolyearEditRequest
{
// Create a SchoolclassCodeDTO ???
// Create a SchoolyearDTO ???
// Create a collection of TimeTableDTO`s ???
public IEnumerable<SchoolclassCode> SchoolclassCodes { get; set; }
public IEnumerable<TimeTable> TimeTablesWeekA { get; set; }
public IEnumerable<TimeTable> TimeTablesWeekB { get; set; }
public Schoolyear Schoolyear { get; set; }
}