easier direct editing of list items
[sgn.git] / js / CXGN / TrialTreeFolders.js
blobb7558e57fa8b1295b039f7a6c54d546429f29ec2
2   jQuery(document).ready(function($) {
3   
4     jQuery("[name='refresh_jstree_html']").click( function() {
5         jQuery.ajax( {
6             url: '/ajax/breeders/get_trials_with_folders',
7             beforeSend: function() {
8                 jQuery("#working_modal").modal("show");
9             },
10             success: function(response) {
11                 jQuery("#working_modal").modal("hide");
12                 location.reload();
13             },
14             error: function(response) {
15                 jQuery("#working_modal").modal("hide");
16                 alert('An error occurred refreshing trial jstree html');
17             }
18         });
19     });
20   });