예제 #1
0
 public MenuEntityPosition GetByID(int _menuEntityPositionID)
 {
     MenuEntityPositionDAC _menuEntityPositionComponent = new MenuEntityPositionDAC();
      IDataReader reader = _menuEntityPositionComponent.GetByIDMenuEntityPosition(_menuEntityPositionID);
      MenuEntityPosition _menuEntityPosition = null;
      while(reader.Read())
      {
          _menuEntityPosition = new MenuEntityPosition();
          if(reader["MenuEntityPositionID"] != DBNull.Value)
              _menuEntityPosition.MenuEntityPositionID = Convert.ToInt32(reader["MenuEntityPositionID"]);
          if(reader["Name"] != DBNull.Value)
              _menuEntityPosition.Name = Convert.ToString(reader["Name"]);
      _menuEntityPosition.NewRecord = false;             }             reader.Close();
      return _menuEntityPosition;
 }
예제 #2
0
 public List<MenuEntityPosition> GetAll()
 {
     MenuEntityPositionDAC _menuEntityPositionComponent = new MenuEntityPositionDAC();
      IDataReader reader =  _menuEntityPositionComponent.GetAllMenuEntityPosition().CreateDataReader();
      List<MenuEntityPosition> _menuEntityPositionList = new List<MenuEntityPosition>();
      while(reader.Read())
      {
      if(_menuEntityPositionList == null)
          _menuEntityPositionList = new List<MenuEntityPosition>();
          MenuEntityPosition _menuEntityPosition = new MenuEntityPosition();
          if(reader["MenuEntityPositionID"] != DBNull.Value)
              _menuEntityPosition.MenuEntityPositionID = Convert.ToInt32(reader["MenuEntityPositionID"]);
          if(reader["Name"] != DBNull.Value)
              _menuEntityPosition.Name = Convert.ToString(reader["Name"]);
      _menuEntityPosition.NewRecord = false;
      _menuEntityPositionList.Add(_menuEntityPosition);
      }             reader.Close();
      return _menuEntityPositionList;
 }
예제 #3
0
 public int UpdateDataset(System.Data.DataSet dataset)
 {
     MenuEntityPositionDAC menuentitypositioncomponent = new MenuEntityPositionDAC();
     return menuentitypositioncomponent.UpdateDataset(dataset);
 }
예제 #4
0
 public bool Update( int MenuEntityPositionID,  string Name,  int Original_MenuEntityPositionID)
 {
     MenuEntityPositionDAC menuentitypositionComponent = new MenuEntityPositionDAC();
     return menuentitypositionComponent.UpdateMenuEntityPosition( MenuEntityPositionID,  Name,  Original_MenuEntityPositionID);
 }
예제 #5
0
 public bool Update(MenuEntityPosition menuentityposition ,int old_menuEntityPositionID)
 {
     MenuEntityPositionDAC menuentitypositionComponent = new MenuEntityPositionDAC();
     return menuentitypositionComponent.UpdateMenuEntityPosition( menuentityposition.MenuEntityPositionID,  menuentityposition.Name,  old_menuEntityPositionID);
 }
예제 #6
0
 public bool Insert( int MenuEntityPositionID,  string Name)
 {
     MenuEntityPositionDAC menuentitypositionComponent = new MenuEntityPositionDAC();
     return menuentitypositionComponent.InsertNewMenuEntityPosition( MenuEntityPositionID,  Name);
 }
예제 #7
0
 public bool Insert(MenuEntityPosition menuentityposition)
 {
     MenuEntityPositionDAC menuentitypositionComponent = new MenuEntityPositionDAC();
     return menuentitypositionComponent.InsertNewMenuEntityPosition( menuentityposition.MenuEntityPositionID,  menuentityposition.Name);
 }
예제 #8
0
 public void Delete(int Original_MenuEntityPositionID)
 {
     MenuEntityPositionDAC menuentitypositionComponent = new MenuEntityPositionDAC();
     menuentitypositionComponent.DeleteMenuEntityPosition(Original_MenuEntityPositionID);
 }