public IList <EntityEmpleadoPaginacion> SelectPagging(ref EntityEmpleadoPaginacion oEntityEmployeePaginacion) { DataProcedure run = new DataProcedure(); run.CollectionParams.AddInputParameter("Nombres", oEntityEmployeePaginacion.Nombres); run.CollectionParams.AddInputParameter("Estado", oEntityEmployeePaginacion.Estado); run.CollectionParams.AddInputParameter("PageIndex", oEntityEmployeePaginacion.EntityPaginacion.PageIndex); run.CollectionParams.AddInputParameter("PageSize", oEntityEmployeePaginacion.EntityPaginacion.RowsPerPage); run.CollectionParams.AddOutputParameter("TotalRows"); IList <EntityEmpleadoPaginacion> oListEmployee = new List <EntityEmpleadoPaginacion>(); using (IDataReader reader = run.ExecuteReader(CTransaction.Empty, Procedimientos.Empleado_Select_Paginado)) { while (reader.Read()) { oListEmployee.Add(EntityEmpleadoPaginacion.CreatePag(reader)); } } run.AssignReturnParameters(); oEntityEmployeePaginacion.EntityPaginacion.RowCount = DataCreator.CreateInt32(run.CollectionParams.GetParameter("TotalRows").Value); return(oListEmployee); }
public IList <EntityEmpleadoPaginacion> SelectPagging(ref EntityEmpleadoPaginacion oEntityEmployeePaginacion) { try { return(EmployeeApp.SelectPagging(ref oEntityEmployeePaginacion)); } catch (Exception) { throw new FaultException("Error al seleccionar empleados"); } }
public IList <EntityEmpleadoPaginacion> SelectPagging(ref EntityEmpleadoPaginacion oEntityEmployeePaginacion) { try { return(Repo.SelectPagging(ref oEntityEmployeePaginacion)); } catch (Exception ex) { throw ex; } }
public IList <EntityEmpleadoPaginacion> SelectPagging(ref EntityEmpleadoPaginacion oEntityEmployeePaginacion) { try { DataEmpleadoRepository data = new DataEmpleadoRepository(EntityEmpleado.Empty, "empleado"); return(data.SelectPagging(ref oEntityEmployeePaginacion)); } catch (Exception ex) { throw ex; } }
public IList <EntityEmpleadoPaginacion> SelectPagging(ref EntityEmpleadoPaginacion oEntityEmpleadoPaginacion) { try { using (EmpleadoServicesClient oEmpleadoServices = new EmpleadoServicesClient()) { return(oEmpleadoServices.SelectPagging(ref oEntityEmpleadoPaginacion)); } } catch (Exception ex) { throw ex; } }
public ActionResult EmpleadoGridPV(EmpleadoViewModel oEmpleadoViewModel, Int32 pageIndex) { EmpleadoServicesController oServices = new EmpleadoServicesController(); if (null == oEmpleadoViewModel.EntityEmpleadoPaginacion.EntityPaginacion) { oEmpleadoViewModel.EntityEmpleadoPaginacion.EntityPaginacion = new SGI.Proxy.Services.EmpleadoServices.EntityPaginacion(); oEmpleadoViewModel.EntityEmpleadoPaginacion.EntityPaginacion.PageIndex = (pageIndex != Constantes.Cero) ? pageIndex : Constantes.PageIndex; oEmpleadoViewModel.EntityEmpleadoPaginacion.EntityPaginacion.RowsPerPage = Constantes.RowsPerPage; } EntityEmpleadoPaginacion oEntityEmpleadoPaginacion = oEmpleadoViewModel.EntityEmpleadoPaginacion; IList <EntityEmpleadoPaginacion> oListEmpleado = oServices.SelectPagging(ref oEntityEmpleadoPaginacion); oEmpleadoViewModel.ListEmpleadoPaginado = oListEmpleado; oEmpleadoViewModel.EntityEmpleadoPaginacion = oEntityEmpleadoPaginacion; return(PartialView(Constantes.EmpleadoGridPV, oEmpleadoViewModel)); }