exceptionHandle
parent
8e51ea7327
commit
2c45fb8760
@ -0,0 +1,34 @@
|
||||
<!-- huang -->
|
||||
<script type="text/javascript" language="javascript">
|
||||
function show(id, id_t, label_reward, label_money, label_credit, label_content) {
|
||||
var text = $('#' + id);
|
||||
var text_t = $('#' + id_t);
|
||||
if (text.val() == 0) {
|
||||
text_t.attr("placeholder", label_reward);
|
||||
}
|
||||
if (text.val() == 1) {
|
||||
text_t.attr("placeholder", label_money);
|
||||
}
|
||||
if (text.val() == 3) {
|
||||
text_t.attr("placeholder", label_credit);
|
||||
}
|
||||
if (text.val() == 2) {
|
||||
text_t.attr("placeholder", label_content);
|
||||
}
|
||||
return content;
|
||||
}
|
||||
</script>
|
||||
<%= error_messages_for 'bid' %>
|
||||
<!--[form:project]-->
|
||||
<p style="width:500px;"><%= l(:label_bids_form_contest_new_description) %></p>
|
||||
<p><%= f.text_field :name, :required => true, :size => 60, :style => "width:490px;", :maxlength => Bid::NAME_LENGTH_LIMIT, :placeholder => "#{l(:label_contest_name)}" %></p>
|
||||
|
||||
<p style="margin-left:-10px;padding-right: 20px;"><%= f.text_area :description, :rows => 8, :class => 'wiki-edit', :style => "font-size:small;width:490px;margin-left:10px;", :maxlength => Bid::DESCRIPTION_LENGTH_LIMIT, :placeholder => "#{l(:label_contest_description)}" %></p>
|
||||
<p><%= select_tag 'bid_reward_type', "<option value = '0'>#{l(:label_choose_reward)}</option><option value = '1'>#{l(:label_money)}</option><option value = '2'>#{l(:label_reward_1)}</option>".html_safe,
|
||||
:onChange => "show('bid_reward_type', 'bid_budget', '"+l(:label_bids_reward_what)+"','"+l(:label_bids_new_money)+"','"+l(:label_bids_new_credit)+"','"+l(:label_bids_new_content)+"')" %>
|
||||
<%= f.text_field :budget, :required => true, :size => 60, :style => "width:350px;", :placeholder => l(:label_bids_reward_what) %>
|
||||
|
||||
<!-- 设置奖项设置的打开 关闭开关-->
|
||||
</p>
|
||||
<!-- <em class="info" style="margin-left:95px;"><%= l(:text_contest_reward) %></em> -->
|
||||
<p><%= f.text_field :deadline, :required => true, :size => 60, :style => "width:150px;", :placeholder => "#{l(:label_deadline)}" %><%= calendar_for('bid_deadline')%></p>
|
@ -0,0 +1,53 @@
|
||||
<!-- fq -->
|
||||
<%= form_tag(calls_path, :method => :get) do %>
|
||||
<div class="project-search-block">
|
||||
<table width="100%" valign="center">
|
||||
<tr>
|
||||
<td width="16%"><span style="margin-left:0px">
|
||||
竞赛列表
|
||||
</span></td>
|
||||
<td valign="center"><% if User.current.logged? %>
|
||||
|
||||
<!-- <div class='icon icon-add'> -->
|
||||
<%= link_to(l(:label_newtype_contest), {:controller => 'bids', :action => 'new_contest'}, :class => 'icon icon-add') %>
|
||||
<!-- <%= toggle_link l(:label_new_call), 'put-bid-form', {:focus => 'project_id'} %> -->
|
||||
<!-- </div> -->
|
||||
<% end %></td>
|
||||
|
||||
<td align="right">
|
||||
<div class="project-search">
|
||||
<%= text_field_tag 'name', params[:name], :size => 30 %>
|
||||
|
||||
<%= submit_tag l(:label_search), :class => "small", :name => nil %>
|
||||
|
||||
</div></td>
|
||||
</tr></table>
|
||||
</div>
|
||||
<%end%>
|
||||
|
||||
<% if User.current.logged? %>
|
||||
<div id="put-bid-form" style="display: none">
|
||||
<%= render :partial => 'new_bid' %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<%= sort_bid(@s_state, @project_type)%>
|
||||
|
||||
<!-- <div class="pagination" style="border-bottom: 1px solid rgb(223,223,223); width: 95%; margin-left: 2%; margin-top: 15px" >
|
||||
<ul style="margin-right:0px">
|
||||
<li>
|
||||
<%= link_to l(:label_sort_by_time), calls_path(:bid_sort_type => '0') %>
|
||||
</li>
|
||||
<li>
|
||||
<%= link_to l(:label_sort_by_active), calls_path(:bid_sort_type => '1') %>
|
||||
</li>
|
||||
<!-- <li>
|
||||
<%= link_to l(:label_sort_by_influence), calls_path(:bid_sort_type => '2') %>
|
||||
</li> -->
|
||||
<!-- </ul>
|
||||
</div> -->
|
||||
|
||||
<div id="bid-show">
|
||||
<%= render :partial => 'contest_show', :locals => {:bids => @bids, :bid_pages => @bid_pages} %>
|
||||
</div>
|
||||
|
@ -0,0 +1,10 @@
|
||||
<!-- huang -->
|
||||
<h3><%=l(:label_newtype_contest)%></h3>
|
||||
|
||||
<%= labelled_form_for @bid, :url => {:controller => 'bids', :action => 'create_bid'} do |f| %>
|
||||
<div class="box tabular">
|
||||
<%= render :partial => 'form_contest', :locals => { :f => f } %>
|
||||
<%= submit_tag l(:button_create) %>
|
||||
<%= javascript_tag "$('#bid_name').focus();" %>
|
||||
<% end %>
|
||||
</div>
|
Loading…
Reference in new issue