function formulario(id) {
    window.location = "verFormulario/"+id;
}
function eliminarFormulario(url, url2) {swal({
    title: "Eliminar Formulario?",
    text: "Al ejecutar esta accion no podra revertir los datos?",
    icon: "warning",
    buttons: true,
    dangerMode: true,
  })
  .then((willDelete) => {
    if (willDelete) {
      swal("Formulario Eliminado!", {
        icon: "success",
      });    
        $.ajax({                         
        url: url,                      
        success: function(data)             
        {
            setTimeout(function(){
                location.assign(url2)
            },2000);
        }
     });
    }
  });

}
$('.eliminar-container #iconoEliminarFormulario').click(function (e) { 
    var $this = $(this);
    swal({
        title: "Eliminar Formulario?",
        text: "Al ejecutar esta accion no podra revertir los datos?",
        icon: "warning",
        buttons: true,
        dangerMode: true,
      })
      .then((willDelete) => {
        if (willDelete) {
          swal("Formulario Eliminado!", {
            icon: "success",
          });    
            $.ajax({                         
            url: $this.attr('url'),                      
            success: function(data)             
            {
                setTimeout(function(){
                    location.assign($this.attr('url2'))
                },2000);
            }
         });
        }
      });
    
  });