public LodgingModifiedModel(Lodging lodging) { Name = lodging.Name; TouristSpot = new TouristSpotNoAssociationsModel(lodging.TouristSpot); IsFull = lodging.IsFull; Address = lodging.Address; }
public LodgingBasicInfoModel(Lodging lodging) { Id = lodging.Id; Name = lodging.Name; Description = lodging.Description; Rating = lodging.Rating; IsFull = lodging.IsFull; Images = lodging.Images.Select(x => new LodgingImageBasicInfoModel(x)).ToList(); PricePerNight = lodging.PricePerNight; Address = lodging.Address; Phone = lodging.Phone; ConfirmationMessage = lodging.ConfirmationMessage; TouristSpot = new TouristSpotNoAssociationsModel(lodging.TouristSpot); }