public static DAL.SuggestionTraveler ToDAL(SuggestionTravelerDto suggestionTravelerDto) { DAL.SuggestionTraveler suggestionTraveler = new DAL.SuggestionTraveler() { SuggestionId = suggestionTravelerDto.SuggestionId, TravelerId = suggestionTravelerDto.TravelerId, Status = suggestionTravelerDto.Status }; return(suggestionTraveler); }
public IHttpActionResult AddOrUpdateSuggestionStatus(SuggestionTravelerDto suggestionTravelerDto) { SuggestionTravelerDto st = BL.ManageSuggestion.SaveSuggestionTraveler(suggestionTravelerDto); if (st != null) { return(Created <SuggestionTravelerDto>("The content inserted into the database successfully", st)); } return(InternalServerError()); }
public static SuggestionTravelerDto ToDTO(DAL.SuggestionTraveler model) { SuggestionTravelerDto suggestionTravelerDto = new SuggestionTravelerDto() { SuggestionId = model.SuggestionId, TravelerId = model.TravelerId, Status = model.Status }; return(suggestionTravelerDto); }
/// <summary> /// שמירת הצעה למטייל /// </summary> /// <param name="suggestionTravelerDto"></param> /// <returns></returns> public static SuggestionTravelerDto SaveSuggestionTraveler(SuggestionTravelerDto suggestionTravelerDto) { return(SuggestionTraveler.ToDTO(DAL.ManageSuggestion.SaveSuggestionTraveler(SuggestionTraveler.ToDAL(suggestionTravelerDto)))); }