将原有的新建参赛作品时弹出新页面变为了本页弹出下拉框
This commit is contained in:
parent
bc07f4c9e5
commit
7d33bb9b2d
|
@ -562,9 +562,9 @@ class ContestsController < ApplicationController
|
|||
@contest = Contest.find(params[:id])
|
||||
@user = @contest.author
|
||||
end
|
||||
rescue
|
||||
rescue
|
||||
render_404
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
|
|
@ -53,6 +53,11 @@
|
|||
function cancel() {
|
||||
$("#put-bid-form").hide();
|
||||
}
|
||||
|
||||
function cancel() {
|
||||
$("#put-project-form").hide();
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<!--参赛步骤-->
|
||||
|
@ -67,9 +72,9 @@
|
|||
</div>
|
||||
<div style="padding-left: 82px; ">
|
||||
<span style="padding-top: 50px">步骤1:</span>
|
||||
<span><%= link_to '新建参赛作品', new_softapplication_path(:target=>'_blank'), :target=>'_blank' %></span>
|
||||
<span><%#= link_to '新建参赛作品', new_softapplication_path(:target=>'_blank'), :target=>'_blank' %></span>
|
||||
<span><%= link_to '新建参赛作品', "javascript:void(0);", onclick: "$('#put-project-form').toggle();" %></span>
|
||||
<span style="font-size: 12px; color: grey">(先点击“新建参赛作品”, 然后返回本页继续步骤2即可。)</span>
|
||||
<span style="font-size: 12px; color: grey">(先点击“新建参赛作品”,然后刷新页面,再继续步骤2。)</span>
|
||||
</div>
|
||||
<div style="padding-left: 82px; ">
|
||||
<span style="padding-top: 50px">步骤2:</span>
|
||||
|
@ -79,7 +84,7 @@
|
|||
|
||||
<!--点击新建参赛作品弹出框-->
|
||||
<div id="put-project-form" style="display: none; padding-left: 83px; width: 70%">
|
||||
<%= form_for "project_for_save", :remote=>true, :url => {:controller => 'softapplications', :action => 'new'}, :complete => '$("#put-bid-form").hide();' do |f| %>
|
||||
<%= form_for Softapplication.new, :remote=>true, :url => softapplications_path, :complete => '$("#put-bid-form").hide();' do |f| %>
|
||||
<fieldset class="contes-new-box", style="padding-left: 36px">
|
||||
|
||||
<tr style="width:700px; margin-left: -10px">
|
||||
|
@ -142,7 +147,7 @@
|
|||
</fieldset>
|
||||
</fieldset></br>
|
||||
<div class="align-center", style="padding-top: -3px; padding-bottom: 8px">
|
||||
<%= submit_tag l(:button_create), :onclick => "return true" %>
|
||||
<%= submit_tag l(:button_create), :onclick => "cancel();" %>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue