Пример #1
0
    protected void CalSalida_SelectionChanged(object sender, EventArgs e)
    {
        metodos m = new metodos();

        m.GetRecordsFecha(CalSalida.SelectedDate);
        GridResumen.DataBind();
    }
Пример #2
0
    public void cargarGridResumen()
    {
        var aux = (from u in objBase.tbm_universidades
                   join c in objBase.tbm_categorias on u.Cod_Cat equals c.Cod_Cat
                   group u by new { c.Txt_Nom, u.Cod_Cat }
                   into g
                   select new { Categorias = g.Key.Txt_Nom, Total = g.Count(item => item.Cod_Cat == g.Key.Cod_Cat) });

        if (aux != null)
        {
            GridResumen.DataSource = aux.ToList();
            GridResumen.DataBind();
        }
    }
Пример #3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["Usuario"] == null)
            {
                Server.Transfer("login.aspx");
            }
            //const string _op3 = "select \"DocNum\" as OF1, \"StartDate\" as FechaProgramada, DAYS_BETWEEN(\"StartDate\", CURRENT_DATE) as DiasAbierta, CASE \"Status\" When 'C' Then 'Cancelada' When 'R' Then 'Liberada' When 'L' Then 'Cerrada' When 'P'  Then 'Planificada' END as Estado,\"ProdName\" as Especie, \"ProdName\" as Articulo, \"PlannedQty\" as Planificado,  'orden.aspx?' as url from  \"SBO04DEMOPROCESADORA\".\"OWOR\" where \"Status\" = 'R'";
            DataTable Dt = new DataTable();

            cUsuario Usuario = (cUsuario)Session["Usuario"];
            int      _Opcion;

            _Opcion = int.Parse(Request.QueryString["vOp"]);

            GridResumen.Columns[0].ItemStyle.Width = 100;
            GridResumen.Columns[1].ItemStyle.Width = 170;
            GridResumen.Columns[2].ItemStyle.Width = 80;
            GridResumen.Columns[3].ItemStyle.Width = 100;
            GridResumen.Columns[4].ItemStyle.Width = 110;
            GridResumen.Columns[5].ItemStyle.Width = 400;
            GridResumen.Columns[6].ItemStyle.Width = 90;
            lblProceso.Text = "Ordenes de Fabricacion";

            switch (_Opcion)
            {
            case 1:
                lblprocesoDesc.Text = "* todas *";
                break;

            case 2:
                lblprocesoDesc.Text = "* cerradas *";
                break;

            case 3:
                lblprocesoDesc.Text = "* abiertas *";
                break;

            case 4:
                lblprocesoDesc.Text = "* planificadas *";
                break;
            }

            cRecordSet rs2 = new cRecordSet();

            GridResumen.DataSource = rs2.clsResumenOF(_Opcion, Usuario);
            GridResumen.DataBind();
        }