1 $('body > .modal-container').html("<%= escape_javascript(render partial: 'choose.html', locals: {multiple: multiple}) %>");
2 $('body > .modal-container .modal').modal('show');
3 $('body > .modal-container .modal .modal-footer .btn-primary').
4 addClass('<%= j params[:action_class] %>').
5 attr('data-action-href', '<%= j params[:action_href] %>').
6 attr('data-method', '<%= j params[:action_method] %>').
7 data('action-data', <%= raw params[:action_data] %>);
8 $(".chooser-show-project").on("click", function() {
9 $("#choose-scroll").html("<div class=\"spinner spinner-32px spinner-h-center\"></div>");
10 $(".modal-dialog-preview-pane").html('');
14 multiple: <%= multiple || "false" %>
16 if (t.attr("data-project-uuid") != null) {
17 d.project_uuid = t.attr("data-project-uuid");
19 $.ajax('<%=j url_for %>', {
23 }).done(function(data, status, jqxhr) {
24 $("#chooser-breadcrumb").text(t.text());
25 $("#choose-scroll").html(data.content);
26 $("#choose-scroll").prop("data-infinite-content-href", "next_page_href");