diff --git a/app/views/poll/_other_poll.html.erb b/app/views/poll/_other_poll.html.erb new file mode 100644 index 000000000..c899f0d47 --- /dev/null +++ b/app/views/poll/_other_poll.html.erb @@ -0,0 +1,27 @@ +
+
+

将以下问卷导入本课程

+
+
+ <%= form_tag import_other_poll_poll_index_path, + method: :post, + remote: true, + id: "relation_file_form" do %> + + <%= content_tag('div', poll_check_box_tags('polls[]', polls,polls_group_id), :id => 'courses')%> + 导  入 + 取  消 + <% end -%> +
+ + +
+
+ + \ No newline at end of file diff --git a/app/views/poll/_polls_list.html.erb b/app/views/poll/_polls_list.html.erb new file mode 100644 index 000000000..c096f396d --- /dev/null +++ b/app/views/poll/_polls_list.html.erb @@ -0,0 +1,10 @@ +<% polls.each do |poll|%> + +
+<% end%> + + \ No newline at end of file diff --git a/app/views/poll/import_other_poll.js.erb b/app/views/poll/import_other_poll.js.erb new file mode 100644 index 000000000..f60cea1c5 --- /dev/null +++ b/app/views/poll/import_other_poll.js.erb @@ -0,0 +1 @@ +$('#polls_list').html('<%= escape_javascript(render :partial => 'polls_list', :locals => {:polls => @polls,:obj_pages=>@obj_pages,:obj_count=>@obj_count}) %>
'); \ No newline at end of file diff --git a/app/views/poll/other_poll.js.erb b/app/views/poll/other_poll.js.erb new file mode 100644 index 000000000..34f53b73e --- /dev/null +++ b/app/views/poll/other_poll.js.erb @@ -0,0 +1,9 @@ + +$('#ajax-modal').html('<%= escape_javascript(render :partial => 'other_poll',:locals => {:polls => @polls,:polls_group_id=>@polls_group_id}) %>'); + + +showModal('ajax-modal', '513px'); +$('#ajax-modal').siblings().remove(); +$('#ajax-modal').before(""); +$('#ajax-modal').parent().css("top","").css("left",""); +$('#ajax-modal').parent().addClass("popbox_polls"); \ No newline at end of file