diff --git a/app/views/layouts/base_newcontest.html.erb b/app/views/layouts/base_newcontest.html.erb index e90fc4aa6..07654eddb 100644 --- a/app/views/layouts/base_newcontest.html.erb +++ b/app/views/layouts/base_newcontest.html.erb @@ -74,7 +74,7 @@ <% end %> <% if User.current.logged? %> - <% if @contest.author.id == User.current.id %> + <% if (@contest.author.id == User.current.id) || User.current.admin? %> <%= link_to l(:label_contest_modify_settings), {:controller => 'contests', :action => 'settings', :id => @contest} %> @@ -82,7 +82,7 @@ - <%= link_to '删除竞赛', {:controller => 'contests', :action => 'destroy_contest', :id => @contest}, data: { confirm: '你确定要删除该竞赛吗?' } %> + <%= link_to l(:label_contest_delete), {:controller => 'contests', :action => 'destroy_contest', :id => @contest}, data: { confirm: '你确定要删除该竞赛吗?' } %> <% end %> diff --git a/app/views/my/account.html.erb b/app/views/my/account.html.erb index bec07145b..341c050d7 100644 --- a/app/views/my/account.html.erb +++ b/app/views/my/account.html.erb @@ -110,7 +110,7 @@

<% unless User.current.user_extensions.school.nil? %> - <%= l(:field_occupation) %> *<%= select_tag "province", options_from_collection_for_select(School.find_by_sql("select distinct province from schools"), :province, :province, User.current.user_extensions.school.province), :onchange => "get_options(this.value)" %> + <%= l(:field_occupation) %> *<%= select_tag "province", options_from_collection_for_select(School.find_by_sql("select distinct province from schools"), :province, :province, User.current.user_extensions.school.province), :onclick => "get_options(this.value)" %> @@ -120,7 +120,7 @@ <% else %> - <%= l(:field_occupation) %> *<%= select_tag "province", options_from_collection_for_select(School.find_by_sql("select distinct province from schools"), :province, :province), :onchange => "get_options(this.value)" %> + <%= l(:field_occupation) %> *<%= select_tag "province", options_from_collection_for_select(School.find_by_sql("select distinct province from schools"), :province, :province), :onclick => "get_options(this.value)" %> diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb index 541fa67ed..dd912cfe6 100644 --- a/app/views/users/show.html.erb +++ b/app/views/users/show.html.erb @@ -1,7 +1,7 @@ <% if User.current.id == @user.id%> <%= show_activity @state%> <%= form_tag(:controller => 'users', :action => "show") do %> -

+