Beispiel #1
0
        protected void btnAlert1Search_Click(object sender, EventArgs e)
        {
            DateTime? from;
            DateTime? until;
            bool? license;
            WayOfDelivery? wayOfDelivery;
            AlertPurchaseOrderType? type = GetAlert1Filters(out from, out until, out license, out wayOfDelivery);

            List<AlertPurchaseOrder> lstConfNoEntregadas = ControllerManager.AlertPurchaseOrder.Search(type, txtProvider.Text, txtProduct.Text, txtPurchaseOrder.Text, from, until, license, string.Empty, string.Empty, wayOfDelivery);
            GVSeguimientoOc.DataSource = lstConfNoEntregadas;
            GVSeguimientoOc.DataBind();
            btnExportToExcel.Visible = (lstConfNoEntregadas.Count > 0);
            lblTotalCountAlert1.Text = "Total: " + lstConfNoEntregadas.Count + " registros";
        }
Beispiel #2
0
 protected void GVOcConfirmadasNoEntregadas_Sorting(object sender, GridViewSortEventArgs e)
 {
     if (OrderField == e.SortExpression)
         ChangeOrder();
     OrderField = e.SortExpression;
     DateTime? from;
     DateTime? until;
     bool? license;
     WayOfDelivery? wayOfDelivery;
     AlertPurchaseOrderType? type = GetAlert1Filters(out from, out until, out license, out wayOfDelivery);
     List<AlertPurchaseOrder> lstConfNoEntregadas = ControllerManager.AlertPurchaseOrder.Search(type, txtProvider.Text, txtProduct.Text, txtPurchaseOrder.Text, from, until, license, OrderField, sortOrder, wayOfDelivery); 
     GVSeguimientoOc.DataSource = lstConfNoEntregadas;
     GVSeguimientoOc.DataBind();
     pnSeguimientoOc.Visible = true;
     lblTotalCountAlert1.Text = "Total: " + lstConfNoEntregadas.Count + " registros";
 }
Beispiel #3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!IsPostBack)
     {
         ViewState["sortOrder"] = "";
     }
     if (Request.QueryString["alert"] != null)
     {
         List<Provider> providers = ControllerManager.Provider.GetFullProviderList();
         switch (Request.QueryString["alert"])
         {
             case "1":
                 {
                     lblAlertName.Text = "Seguimiento de Ordenes de Compra";
                     DateTime? from;
                     DateTime? until;
                     bool? license;
                     WayOfDelivery? wayOfDelivery;
                     AlertPurchaseOrderType? type = GetAlert1Filters(out from, out until, out license, out wayOfDelivery);
                     List<AlertPurchaseOrder> lstConfNoEntregadas = ControllerManager.AlertPurchaseOrder.Search(type, txtProvider.Text, txtProduct.Text, txtPurchaseOrder.Text, from, until, license, OrderField, sortOrder, wayOfDelivery);
                     GVSeguimientoOc.DataSource = lstConfNoEntregadas;
                     GVSeguimientoOc.DataBind();
                     pnSeguimientoOc.Visible = true;
                     btnExportToExcel.Visible = (lstConfNoEntregadas.Count > 0);
                     Form.DefaultButton = btnAlert1Search.UniqueID;
                     lblTotalCountAlert1.Text = "Total: " + lstConfNoEntregadas.Count + " registros";
                     break;
                 }
             case "3":
                 {
                     lblAlertName.Text = "Productos con Stock Negativo";
                     List<AlertProduct> lstStockNegativo = ControllerManager.AlertProduct.ShowAlert(OrderField, sortOrder, 1);
                     GVStockNegativo.DataSource = lstStockNegativo;
                     GVStockNegativo.DataBind();
                     pnStockNegativo.Visible = true;
                     btnExportToExcel.Visible = (lstStockNegativo.Count > 0);
                     lblTotalCountAlert3.Text = "Total: " + lstStockNegativo.Count + " registros";
                     break;
                 }
             case "4":
                 {
                     lblAlertName.Text = "Seguimiento de Entregas";
                     if (Page.Request.Form.HasKeys())
                     {
                         Alert4Search(Page.Request.Form.Get("ctl00$cphContent$ddlClient"), OrderField);
                         pnSeguimientoOv.Visible = true;
                     }
                     else
                     {
                         List<AlertSaleOrder> lstNoCumplimentadas = ControllerManager.AlertSaleOrder.ShowAlert4();
                         FillAlert4(lstNoCumplimentadas, string.Empty);
                     }
                     Form.DefaultButton = btnAlert4Search.UniqueID;
                     break;
                 }
             case "6":
                 {
                     lblAlertName.Text = "Nivel de Reposición";
                     GVRepositionFill();
                     break;
                 }
         }
     }
 }
Beispiel #4
0
 protected void GVOcConfirmadasNoEntregadas_PageIndexChanging(object sender, GridViewPageEventArgs e)
 {
     GVSeguimientoOc.PageIndex = e.NewPageIndex;
     GVSeguimientoOc.DataBind();
 }