$(document).ready(function(){

  $(document).on('click', '.trashbtnRestore_bankd', function () {
    
    var bank_id=$(this).data('id');
    restorebankdetail(bank_id);

  });

});


function restorebankdetail(bank_id)
{
  $.ajaxSetup({

    headers: {

        'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')

    } 

  });


  $.ajax({ 
  
    url:url_restorebankDetail,

    method:"POST",

    data:{bank_id:bank_id},

    success:function(result)

    {
      $("#bankdetail_trashed").modal('hide');

        var success="";

        success=success+
      
        '<p style="text-align:center;"><b>Bank Detail Restore Successfully !!!</b></p>';
      
        $('#bankdetail_success').append(success);
        $('#bankdetail_success').removeClass("hide");
      
        setTimeout(function(){
         location.reload();
        }, 200);
    }

 });

}