Ejemplo n.º 1
0
 public List<ConferenceHallsLanguage> GetAll(int ParentID)
 {
     ConferenceHallsLanguageDAC _conferenceHallsLanguageComponent = new ConferenceHallsLanguageDAC();
     IDataReader reader = _conferenceHallsLanguageComponent.GetAllConferenceHallsLanguage("ConferenceHallsParentID="+ParentID).CreateDataReader();
     List<ConferenceHallsLanguage> _conferenceHallsLanguageList = new List<ConferenceHallsLanguage>();
     while (reader.Read())
     {
         if (_conferenceHallsLanguageList == null)
             _conferenceHallsLanguageList = new List<ConferenceHallsLanguage>();
         ConferenceHallsLanguage _conferenceHallsLanguage = new ConferenceHallsLanguage();
         if (reader["ConferenceHallsId"] != DBNull.Value)
             _conferenceHallsLanguage.ConferenceHallsId = Convert.ToInt32(reader["ConferenceHallsId"]);
         if (reader["Name"] != DBNull.Value)
             _conferenceHallsLanguage.Name = Convert.ToString(reader["Name"]);
         if (reader["ConferenceId"] != DBNull.Value)
             _conferenceHallsLanguage.ConferenceId = Convert.ToInt32(reader["ConferenceId"]);
         if (reader["MapPath"] != DBNull.Value)
             _conferenceHallsLanguage.MapPath = Convert.ToString(reader["MapPath"]);
         if (reader["LanguageID"] != DBNull.Value)
             _conferenceHallsLanguage.LanguageID = Convert.ToInt32(reader["LanguageID"]);
         if (reader["ConferenceHallsParentID"] != DBNull.Value)
             _conferenceHallsLanguage.ConferenceHallsParentID = Convert.ToInt32(reader["ConferenceHallsParentID"]);
         _conferenceHallsLanguage.NewRecord = false;
         _conferenceHallsLanguageList.Add(_conferenceHallsLanguage);
     } reader.Close();
     return _conferenceHallsLanguageList;
 }
Ejemplo n.º 2
0
 public ConferenceHallsLanguage GetByID(int _conferenceHallsId)
 {
     ConferenceHallsLanguageDAC _conferenceHallsLanguageComponent = new ConferenceHallsLanguageDAC();
      IDataReader reader = _conferenceHallsLanguageComponent.GetByIDConferenceHallsLanguage(_conferenceHallsId);
      ConferenceHallsLanguage _conferenceHallsLanguage = null;
      while(reader.Read())
      {
          _conferenceHallsLanguage = new ConferenceHallsLanguage();
          if(reader["ConferenceHallsId"] != DBNull.Value)
              _conferenceHallsLanguage.ConferenceHallsId = Convert.ToInt32(reader["ConferenceHallsId"]);
          if(reader["Name"] != DBNull.Value)
              _conferenceHallsLanguage.Name = Convert.ToString(reader["Name"]);
          if(reader["ConferenceId"] != DBNull.Value)
              _conferenceHallsLanguage.ConferenceId = Convert.ToInt32(reader["ConferenceId"]);
          if(reader["MapPath"] != DBNull.Value)
              _conferenceHallsLanguage.MapPath = Convert.ToString(reader["MapPath"]);
          if(reader["LanguageID"] != DBNull.Value)
              _conferenceHallsLanguage.LanguageID = Convert.ToInt32(reader["LanguageID"]);
          if(reader["ConferenceHallsParentID"] != DBNull.Value)
              _conferenceHallsLanguage.ConferenceHallsParentID = Convert.ToInt32(reader["ConferenceHallsParentID"]);
      _conferenceHallsLanguage.NewRecord = false;             }             reader.Close();
      return _conferenceHallsLanguage;
 }
Ejemplo n.º 3
0
 public bool Update(ConferenceHallsLanguage conferencehallslanguage ,int old_conferenceHallsId)
 {
     ConferenceHallsLanguageDAC conferencehallslanguageComponent = new ConferenceHallsLanguageDAC();
     return conferencehallslanguageComponent.UpdateConferenceHallsLanguage( conferencehallslanguage.Name,  conferencehallslanguage.ConferenceId,  conferencehallslanguage.MapPath,  conferencehallslanguage.LanguageID,  conferencehallslanguage.ConferenceHallsParentID,  old_conferenceHallsId);
 }
Ejemplo n.º 4
0
 public bool Insert(ConferenceHallsLanguage conferencehallslanguage)
 {
     int autonumber = 0;
     ConferenceHallsLanguageDAC conferencehallslanguageComponent = new ConferenceHallsLanguageDAC();
     bool endedSuccessfuly = conferencehallslanguageComponent.InsertNewConferenceHallsLanguage( ref autonumber,  conferencehallslanguage.Name,  conferencehallslanguage.ConferenceId,  conferencehallslanguage.MapPath,  conferencehallslanguage.LanguageID,  conferencehallslanguage.ConferenceHallsParentID);
     if(endedSuccessfuly)
     {
         conferencehallslanguage.ConferenceHallsId = autonumber;
     }
     return endedSuccessfuly;
 }