Exemplo n.º 1
0
        public static internalDTO.Schooling MapFromDAL(externalDTO.Schooling schooling)
        {
            var res = schooling == null ? null : new internalDTO.Schooling
            {
                Id            = schooling.Id,
                SchoolingName = new internalDTO.MultiLangString(schooling.SchoolingName),
                Start         = schooling.Start,
                MaterialId    = schooling.MaterialId,
                Material      = DAL.App.EF.Mappers.MaterialMapper.MapFromDAL(schooling.Material),
                LocationId    = schooling.LocationId,
                Location      = DAL.App.EF.Mappers.LocationMapper.MapFromDAL(schooling.Location),
            };

            return(res);
        }
Exemplo n.º 2
0
        public static externalDTO.Schooling MapFromInternal(internalDTO.Schooling schooling)
        {
            var res = schooling == null ? null : new externalDTO.Schooling
            {
                Id            = schooling.Id,
                SchoolingName = schooling.SchoolingName,
                Start         = schooling.Start,
                MaterialId    = schooling.MaterialId,
                Material      = MaterialMapper.MapFromInternal(schooling.Material),
                LocationId    = schooling.LocationId,
                Location      = LocationMapper.MapFromInternal(schooling.Location)
            };

            return(res);
        }