Ejemplo n.º 1
0
        public Horario RetrieveById(int id)
        {
            var hm = new HorarioManagement();
            var h  = new Horario()
            {
                id = id
            };

            return(hm.RetrieveById(h));
        }
Ejemplo n.º 2
0
        public List <Horario> RetrieveBySucursal(int sucursal)
        {
            var hm = new HorarioManagement();
            var h  = new Horario()
            {
                id_sucursal = sucursal
            };

            return(hm.RetrieveBySucursal(h));
        }
Ejemplo n.º 3
0
 public IActionResult Update(HorarioViewModel c)
 {
     try
     {
         var hm = new HorarioManagement();
         hm.Update(c);
         return(Ok());
     }
     catch (Exception ex)
     {
         return(StatusCode(500, ex));
     }
 }
Ejemplo n.º 4
0
        public IActionResult Delete(int id)
        {
            var c = new Horario {
                id = id
            };

            try
            {
                var hm = new HorarioManagement();
                hm.Delete(c);
                return(Ok());
            }
            catch (Exception ex)
            {
                return(StatusCode(500, ex));
            }
        }
Ejemplo n.º 5
0
        public List <Horario> RetrieveAll()
        {
            var hm = new HorarioManagement();

            return(hm.RetrieveAll());
        }