From d541309455af5b8fccd3a324f9c75d17d777ed38 Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Wed, 15 Oct 2014 17:24:49 +0800 Subject: [PATCH] =?UTF-8?q?#1295=E5=8F=96=E6=B6=88=E7=AB=9E=E8=B5=9B?= =?UTF-8?q?=E5=88=9B=E5=BB=BA=E8=BF=99=E7=9A=84=E5=85=B3=E6=B3=A8=E5=8A=9F?= =?UTF-8?q?=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/layouts/base_contest.html.erb | 81 ++++++++++++---------- app/views/layouts/base_newcontest.html.erb | 80 ++++++++++++--------- 2 files changed, 93 insertions(+), 68 deletions(-) diff --git a/app/views/layouts/base_contest.html.erb b/app/views/layouts/base_contest.html.erb index 740016ff8..ae44933ab 100644 --- a/app/views/layouts/base_contest.html.erb +++ b/app/views/layouts/base_contest.html.erb @@ -27,27 +27,27 @@
- - - - - - - - - - -
<%=l(:label_contest_innovate_community)%><%= l(:label_user_location) %> : - -
<%=link_to request.host()+"/contest", :controller => 'bids', :action => 'contest' %><%=link_to l(:field_homepage), home_path %> > <%=link_to l(:label_contest_innovate), :controller => 'bids', :action => 'contest' %> > - <%= link_to @bid.name, bid_path %>
+ + + + + + + + + + +
<%=l(:label_contest_innovate_community)%><%= l(:label_user_location) %> : + +
<%=link_to request.host()+"/contest", :controller => 'bids', :action => 'contest' %><%=link_to l(:field_homepage), home_path %> > <%=link_to l(:label_contest_innovate), :controller => 'bids', :action => 'contest' %> > + <%= link_to @bid.name, bid_path %>
@@ -86,10 +91,14 @@
- - + + diff --git a/app/views/layouts/base_newcontest.html.erb b/app/views/layouts/base_newcontest.html.erb index adce80d24..d8945a5dc 100644 --- a/app/views/layouts/base_newcontest.html.erb +++ b/app/views/layouts/base_newcontest.html.erb @@ -5,19 +5,17 @@ - - <%= h html_title %> - - - <%= csrf_meta_tag %> - <%= favicon %> - <%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2', 'application', :media => 'all' %> + + <%= h html_title %> + + + <%= csrf_meta_tag %> + <%= favicon %> + <%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2', 'application', :media => 'all' %> <%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %> - <%= javascript_heads %> <%= heads_for_theme %> <%= call_hook :view_layouts_base_html_head %> - <%= yield :header_tags -%> @@ -26,12 +24,15 @@
<%=render :partial => 'layouts/base_header'%>
-
<%=link_to "#{@bid.join_in_contests.count}",:controller => "bids", - :action => "show_participator" %><%=link_to "#{@bid.projects.where('is_public=1').count}", :controller => 'bids', - :action => 'show_project' %> + <%=link_to "#{@bid.join_in_contests.count}",:controller => "bids", + :action => "show_participator" %> + + <%=link_to "#{@bid.projects.where('is_public=1').count}", :controller => 'bids', + :action => 'show_project' %> +
<%= l(:label_participator) %> <%= l(:label_bidding_project) %>
- - + + - +
<%=l(:label_contest_innovate_community)%><%= l(:label_user_location) %> : + <%=l(:label_contest_innovate_community)%> + + <%= l(:label_user_location) %> : +
<%=link_to request.host()+"/contests", :controller=>'contests', :action=>'index' %> + <%=link_to request.host()+"/contests", :controller=>'contests', :action=>'index' %> + <%=link_to l(:field_homepage), home_path %> > <%=link_to l(:label_contest_innovate), :controller=>'contests', :action=>'index' %> > - <%= link_to h(truncate(@contest.name, length: 20, omission: '...')), show_contest_contest_path(@contest) %> + + <%= link_to h(truncate(@contest.name, length: 20, omission: '...')), show_contest_contest_path(@contest) %> +
@@ -61,17 +66,19 @@ <%= image_tag(url_to_avatar(@user), :class => "avatar2") %> - - + <% if User.current.login? %> <% end %> @@ -80,12 +87,17 @@ <% if (@contest.author.id == User.current.id) || User.current.admin? %> <% end %> @@ -116,7 +128,6 @@ - @@ -128,13 +139,22 @@
<%= link_to @contest.name, show_contest_contest_path(@contest) %> + <%= link_to @contest.name, show_contest_contest_path(@contest) %> +
- - <%= new_watcher_link(@contest, User.current) %> + + <%= new_watcher_link(@contest, User.current) unless (@contest.author.id == User.current.id) || User.current.admin? %> +
- <%= link_to l(:label_contest_modify_settings), {:controller => 'contests', :action => 'settings', :id => @contest} %> + + <%= link_to l(:label_contest_modify_settings), {:controller => 'contests', :action => 'settings', :id => @contest} %> +
- <%= link_to l(:label_contest_delete), {:controller => 'contests', :action => 'destroy_contest', :id => @contest}, data: { confirm: '你确定要删除该竞赛吗?' }, method: :delete %> + + <%= link_to l(:label_contest_delete), {:controller => 'contests', :action => 'destroy_contest', :id => @contest}, + data: { confirm: '你确定要删除该竞赛吗?' }, method: :delete %> +
<%= l(:label_contest_watchers) %> <%= l(:label_contest_work) %>
- + - + - +
<%= l(:lable_contest_user) %>: <%= link_to(@user.name, user_path(@user))%> + <%= l(:lable_contest_user) %>:  + <%= link_to(@user.name, user_path(@user))%> +
<%= l(:label_bids_reward_method) %><%= @contest.budget%> + <%= l(:label_bids_reward_method) %> + <%= @contest.budget%> +
<%= l(:label_limit_time) %> : <%= @contest.deadline%> + <%= l(:label_limit_time) %> : + <%= @contest.deadline%> +
@@ -156,7 +176,10 @@
<% end %>
- <%= l(:label_create_time) %>:<%= format_time(@contest.created_on) %> + + <%= l(:label_create_time) %>: + + <%= format_time(@contest.created_on) %>
@@ -173,7 +196,6 @@ -
@@ -193,22 +215,16 @@
- - - -
-
-
<% if display_main_menu?(@contest) %>