Beispiel #1
0
 /// <summary>
 /// Método insere um registro na tabela cliente. Recebe um objeto DTO com os campos a serem inseridos
 /// </summary>
 /// <param name="dto"> Registro a ser inserido</param>
 /// <returns>Retorna void.</returns>
 public void Insert(DTO.cliente dto)
 {
     try
     {
         _cliente = new DAL.cliente();
         _cliente.Insert(dto);
     }
     catch (Exception)
     {
         throw;
     }
 }
Beispiel #2
0
 /// <summary>
 /// Método exclui um registro na tabela cliente. Recebe um objeto DTO com os operadores para selecionar um registro especifico do banco a ser deletado
 /// </summary>
 /// <param name="dto"> Campo(s) WHERE dto.id </param>
 /// <returns>Retorna void.</returns>
 public void Delete(DTO.cliente dto)
 {
     try
     {
         _cliente = new DAL.cliente();
         _cliente.Delete(dto);
     }
     catch (Exception)
     {
         throw;
     }
 }
Beispiel #3
0
 /// <summary>
 /// Método retorna uma tabela com os registros relacionados a tabela cliente. Recebe um objeto DTO com os operadores para selecionar um registro especifico do banco e devolver uma tabela
 /// </summary>
 /// <param name="VAR"> Campo(s) WHERE VAR.id </param>
 /// <returns>Retorna DataTable.</returns>
 public DataTable GetDataTableJoinByID(DTO.cliente VAR)
 {
     try
     {
         _cliente = new DAL.cliente();
         return(_cliente.GetDataTableJoinByID(VAR));
     }
     catch (Exception)
     {
         throw;
     }
 }
Beispiel #4
0
 /// <summary>
 /// Método retorna uma lista com os registros da tabela cliente. Recebe um objeto DTO com os operadores para selecionar um registro especifico do banco e devolver uma lista
 /// </summary>
 /// <param name="VAR"> Campo(s) WHERE VAR.id </param>
 /// <returns>Retorna List.</returns>
 public List <DTO.cliente> GetListByID(DTO.cliente VAR)
 {
     try
     {
         _cliente = new DAL.cliente();
         return(_cliente.GetListByID(VAR));
     }
     catch (Exception)
     {
         throw;
     }
 }
Beispiel #5
0
 /// <summary>
 /// Método retorna uma tabela com todos os registros relacionados a tabela cliente. Retorna a tabelas relacionadas por join
 /// </summary>
 /// <returns>Retorna DataTable.</returns>
 public DataTable GetDataTableJoin( )
 {
     try
     {
         _cliente = new DAL.cliente();
         return(_cliente.GetDataTableJoin());
     }
     catch (Exception)
     {
         throw;
     }
 }
Beispiel #6
0
 public void Delete(Model.cliente cliente)
 {
     DAL.cliente dalCliente = new DAL.cliente();
     dalCliente.Delete(cliente);
 }
Beispiel #7
0
 public void Update(Model.cliente cliente)
 {
     DAL.cliente dalCliente = new DAL.cliente();
     dalCliente.Update(cliente);
 }
Beispiel #8
0
 public void Insert(Model.cliente cliente)
 {
     DAL.cliente dalCliente = new DAL.cliente();
     dalCliente.Insert(cliente);
 }
Beispiel #9
0
 public List <Model.cliente> Select()
 {
     DAL.cliente dalCliente = new DAL.cliente();
     return(dalCliente.Select());
 }