public Spartane.Core.Domain.Detalle_Planes_Alimenticios.Detalle_Planes_AlimenticiosPagingModel ListaSelAll(int startRowIndex, int maximumRows, string Where, string Order)
        {
            Detalle_Planes_AlimenticiosPagingModel result = null;

            return(result);
        }
Пример #2
0
        public Spartane.Core.Classes.Detalle_Planes_Alimenticios.Detalle_Planes_AlimenticiosPagingModel ListaSelAll(int startRowIndex, int maximumRows, string Where, string Order)
        {
            var padstartRowIndex = _dataProvider.GetParameter();

            padstartRowIndex.ParameterName = "startRowIndex";
            padstartRowIndex.DbType        = DbType.Int32;
            padstartRowIndex.Value         = startRowIndex;

            var padmaximumRows = _dataProvider.GetParameter();

            padmaximumRows.ParameterName = "maximumRows";
            padmaximumRows.DbType        = DbType.Int32;
            padmaximumRows.Value         = maximumRows;

            var padWhere = _dataProvider.GetParameter();

            padWhere.ParameterName = "Where";
            padWhere.DbType        = DbType.String;
            padWhere.Value         = Where;

            var padOrder = _dataProvider.GetParameter();

            padOrder.ParameterName = "Order";
            padOrder.DbType        = DbType.String;
            padOrder.Value         = Order;

            var data = _dbContext.ExecuteStoredProcedureList <Spartane.Core.Classes.StoredProcedure.SpListSelAllDetalle_Planes_Alimenticios>("sp_ListSelAll_Detalle_Planes_Alimenticios", padWhere, padOrder, padstartRowIndex, padmaximumRows);

            Detalle_Planes_AlimenticiosPagingModel result = null;

            if (data != null)
            {
                result = new Detalle_Planes_AlimenticiosPagingModel
                {
                    Detalle_Planes_Alimenticioss =
                        data.Select(m => new Spartane.Core.Classes.Detalle_Planes_Alimenticios.Detalle_Planes_Alimenticios
                    {
                        Folio = m.Detalle_Planes_Alimenticios_Folio
                        , Folio_Planes_Alimenticios          = m.Detalle_Planes_Alimenticios_Folio_Planes_Alimenticios
                        , Tiempo_de_Comida                   = m.Detalle_Planes_Alimenticios_Tiempo_de_Comida
                        , Tiempo_de_Comida_Tiempos_de_Comida = new Core.Classes.Tiempos_de_Comida.Tiempos_de_Comida()
                        {
                            Clave = m.Detalle_Planes_Alimenticios_Tiempo_de_Comida.GetValueOrDefault(), Comida = m.Detalle_Planes_Alimenticios_Tiempo_de_Comida_Comida
                        }
                        , Numero_de_Dia = m.Detalle_Planes_Alimenticios_Numero_de_Dia
                        , Numero_de_Dia_Dias_de_la_semana = new Core.Classes.Dias_de_la_semana.Dias_de_la_semana()
                        {
                            Clave = m.Detalle_Planes_Alimenticios_Numero_de_Dia.GetValueOrDefault(), Dia = m.Detalle_Planes_Alimenticios_Numero_de_Dia_Dia
                        }
                        , Fecha              = m.Detalle_Planes_Alimenticios_Fecha
                        , Platillo           = m.Detalle_Planes_Alimenticios_Platillo
                        , Platillo_Platillos = new Core.Classes.Platillos.Platillos()
                        {
                            Folio = m.Detalle_Planes_Alimenticios_Platillo.GetValueOrDefault(), Nombre_de_Platillo = m.Detalle_Planes_Alimenticios_Platillo_Nombre_de_Platillo
                        }
                        , Modificado = m.Detalle_Planes_Alimenticios_Modificado ?? false

                                       //,Id = m.Id
                    }).ToList()
                };
            }
            return(result);
        }