Exemple #1
0
        /// <summary>
        /// קבלת כל הצעות
        /// </summary>
        /// <returns></returns>
        public static List <SuggestionDto> GetSuggestionsAll()
        {
            List <SuggestionDto> dto = new List <SuggestionDto>();

            foreach (var item in DAL.ManageSuggestion.GetSuggestionsAll())
            {
                dto.Add(Suggestion.ToDTO(item));
            }
            return(dto);
        }
Exemple #2
0
        /// <summary>
        ///  קבלת כל ההצעות עם סטטוס
        /// </summary>
        /// <returns></returns>
        public static List <SuggestionDto> GetSuggestionsWithStatus(int travelerId)
        {
            List <SuggestionDto> dto = new List <SuggestionDto>();

            foreach (var item in DAL.ManageSuggestion.GetSuggestionsAll())
            {
                dto.Add(Suggestion.ToDTO(item, travelerId));
            }
            return(dto);
        }
Exemple #3
0
 public static List <SuggestionDto> GetMatchingSuggestions(RequestDto requestDto)
 {
     return(DAL.Match.GetMatchingSuggestions(requestDto).ConvertAll <SuggestionDto>(s =>
                                                                                    { return Suggestion.ToDTO(s); }));
 }
Exemple #4
0
 /// <summary>
 /// עדכון הצעה
 /// </summary>
 /// <param name="suggestionDto"></param>
 /// <returns></returns>
 public static SuggestionDto UpdateSuggestion(SuggestionDto suggestionDto)
 {
     return(Suggestion.ToDTO(DAL.ManageSuggestion.UpdateSuggestion(Suggestion.ToDAL(suggestionDto))));
 }
Exemple #5
0
 /// <summary>
 /// קבלת הצעה לפי קוד
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public static SuggestionDto GetSuggestion(int id)
 {
     return(Suggestion.ToDTO(DAL.ManageSuggestion.GetSuggestion(id)));
 }