Exemple #1
0
        protected void gvTickets_OnRowCommand(object sender, GridViewCommandEventArgs e)
        {
            try
            {
                switch (e.CommandName)
                {
                case "sort":
                    Sortingtype = Sortingtype == "asc" ? "desc" : "asc";
                    Sorting     = e.CommandArgument.ToString();
                    ObtenerTicketsPage(0);
                    break;

                case "redirect":
                    AgenteMaster master = Master as AgenteMaster;
                    if (master != null)
                    {
                        master.AddTicketOpen(int.Parse(e.CommandArgument.ToString()), "prueba");
                    }
                    Response.Redirect("~/Agente/FrmTicket.aspx?id=" + e.CommandArgument);
                    break;
                }
            }
            catch (Exception ex)
            {
                if (_lstError == null)
                {
                    _lstError = new List <string>();
                }
                _lstError.Add(ex.Message);
                Alerta = _lstError;
            }
        }
Exemple #2
0
 private void UcTicketDetalle_OnCargarTicket(int idTicket, string titulo, bool asigna)
 {
     try
     {
         AgenteMaster master = Master as AgenteMaster;
         if (master != null)
         {
             master.CambiaTicket = true;
             master.AddTicketOpen(idTicket, titulo, asigna);
         }
     }
     catch (Exception ex)
     {
         if (_lstError == null)
         {
             _lstError = new List <string>();
         }
         _lstError.Add(ex.Message);
         Alerta = _lstError;
     }
 }
Exemple #3
0
 protected void OnClick(object sender, EventArgs e)
 {
     try
     {
         AgenteMaster master = Master as AgenteMaster;
         if (master != null)
         {
             master.AddTicketOpen(1, "prueba");
             master.AddTicketOpen(2, "prueba");
             master.AddTicketOpen(3, "prueba");
             master.AddTicketOpen(4, "prueba");
             master.AddTicketOpen(5, "prueba");
             master.AddTicketOpen(6, "prueba");
             master.AddTicketOpen(7, "prueba");
             master.AddTicketOpen(8, "prueba");
             master.AddTicketOpen(9, "prueba");
             master.AddTicketOpen(11, "prueba");
             master.AddTicketOpen(12, "prueba");
             master.AddTicketOpen(13, "prueba");
             master.AddTicketOpen(14, "prueba");
             master.AddTicketOpen(15, "prueba");
             master.AddTicketOpen(16, "prueba");
             master.AddTicketOpen(17, "prueba");
             master.AddTicketOpen(18, "prueba");
             master.AddTicketOpen(19, "prueba");
             master.AddTicketOpen(20, "prueba");
         }
     }
     catch (Exception ex)
     {
         if (_lstError == null)
         {
             _lstError = new List <string>();
         }
         _lstError.Add(ex.Message);
         Alerta = _lstError;
     }
 }