From 43235f3cef7f3f7f0eb8339a6f9c753e7145637d Mon Sep 17 00:00:00 2001 From: Hagen Schink Date: Thu, 6 Mar 2014 09:23:27 +0100 Subject: [PATCH] Adds missing edit accesskeys --- app/views/messages/show.html.erb | 3 ++- app/views/my/page.html.erb | 2 +- app/views/reportings/show.html.erb | 3 ++- app/views/timelines/show.html.erb | 3 ++- app/views/users/show.html.erb | 5 ++++- app/views/versions/show.html.erb | 2 +- app/views/wiki/annotate.html.erb | 5 ++++- app/views/workflows/edit.html.erb | 2 +- 8 files changed, 17 insertions(+), 8 deletions(-) diff --git a/app/views/messages/show.html.erb b/app/views/messages/show.html.erb index d0ad37fc3e..3be927943f 100644 --- a/app/views/messages/show.html.erb +++ b/app/views/messages/show.html.erb @@ -40,7 +40,8 @@ See doc/COPYRIGHT.rdoc for more details. { :class => 'icon icon-quote'} ) unless @topic.locked? %> <%= link_to(l(:button_edit), edit_topic_path(@topic), - :class => 'icon icon-edit') if @message.editable_by?(User.current) %> + :class => 'icon icon-edit', + accesskey: accesskey(:edit)) if @message.editable_by?(User.current) %> <%= link_to(l(:button_delete), topic_path(@topic), :method => :delete, diff --git a/app/views/my/page.html.erb b/app/views/my/page.html.erb index 2335b032c7..adef3dc41a 100644 --- a/app/views/my/page.html.erb +++ b/app/views/my/page.html.erb @@ -29,7 +29,7 @@ See doc/COPYRIGHT.rdoc for more details. <% breadcrumb_paths(l(:label_my_page)) %> <% content_for :action_menu_specific do %> - <%= link_to l(:label_personalize_page), :action => 'page_layout' %> + <%= link_to l(:label_personalize_page), action: 'page_layout', accesskey: accesskey(:edit) %> <% end %>

<%=l(:label_my_page)%>

diff --git a/app/views/reportings/show.html.erb b/app/views/reportings/show.html.erb index a55312d61a..85e1b0cefd 100644 --- a/app/views/reportings/show.html.erb +++ b/app/views/reportings/show.html.erb @@ -35,7 +35,8 @@ See doc/COPYRIGHT.rdoc for more details. <% content_for :action_menu_specific do %> <%= link_to_if_authorized(l(:button_edit), {:action => :edit, :project_id => @project, :id => @reporting}, - :class => 'icon icon-edit') %> + :class => 'icon icon-edit', + accesskey: accesskey(:edit)) %> <%= link_to_if_authorized(l(:button_delete), {:action => :confirm_destroy, :project_id => @project, :id => @reporting}, :class => 'icon icon-delete') %> diff --git a/app/views/timelines/show.html.erb b/app/views/timelines/show.html.erb index cb1dc0c50a..c96ffd36ee 100644 --- a/app/views/timelines/show.html.erb +++ b/app/views/timelines/show.html.erb @@ -40,7 +40,8 @@ See doc/COPYRIGHT.rdoc for more details. :action => 'edit', :project_id => @project, :id => @timeline}, - :class => 'icon icon-edit') do %> + :class => 'icon icon-edit', + :accesskey => accesskey(:edit)) do %> <%= l(:button_edit) %><%= h(@timeline.name) %> <% end) %> diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb index c034a27f3b..3def3b6fd5 100644 --- a/app/views/users/show.html.erb +++ b/app/views/users/show.html.erb @@ -32,7 +32,10 @@ See doc/COPYRIGHT.rdoc for more details. <% end %> <% content_for :action_menu_specific do %> - <%= link_to(l(:button_edit), edit_user_path(@user), :class => 'icon icon-edit') if User.current.admin? %> + <%= link_to(l(:button_edit), + edit_user_path(@user), + :class => 'icon icon-edit', + accesskey: accesskey(:edit)) if User.current.admin? %> <% end %>

<%= avatar @user, :size => "50" %> <%=h @user.name %>

diff --git a/app/views/versions/show.html.erb b/app/views/versions/show.html.erb index b07778090d..2d57abb26a 100644 --- a/app/views/versions/show.html.erb +++ b/app/views/versions/show.html.erb @@ -28,7 +28,7 @@ See doc/COPYRIGHT.rdoc for more details. ++#%> <% content_for :action_menu_specific do %> - <%= link_to_if_authorized l(:button_edit), {:controller => '/versions', :action => 'edit', :id => @version}, :class => 'icon icon-edit' %> + <%= link_to_if_authorized l(:button_edit), {:controller => '/versions', :action => 'edit', :id => @version}, :class => 'icon icon-edit', accesskey: accesskey(:edit) %> <%= link_to_if_authorized(l(:button_edit_associated_wikipage, :page_title => @version.wiki_page_title), {:controller => '/wiki', :action => 'edit', :project_id => @version.project, :id => Wiki.titleize(@version.wiki_page_title)}, :class => 'icon icon-edit') unless @version.wiki_page_title.blank? || @version.project.wiki.nil? %> <%= call_hook(:view_versions_show_contextual, { :version => @version, :project => @project }) %> <% end %> diff --git a/app/views/wiki/annotate.html.erb b/app/views/wiki/annotate.html.erb index f1cdc4a46d..b6f056c5e5 100644 --- a/app/views/wiki/annotate.html.erb +++ b/app/views/wiki/annotate.html.erb @@ -28,7 +28,10 @@ See doc/COPYRIGHT.rdoc for more details. ++#%> <% content_for :action_menu_specific do %> - <%= link_to(l(:button_edit), {:action => 'edit', :id => @page}, :class => 'icon icon-edit') %> + <%= link_to(l(:button_edit), + {:action => 'edit', :id => @page}, + :class => 'icon icon-edit', + :accesskey => accesskey(:edit)) %> <%= link_to(l(:label_history), {:action => 'history', :id => @page}, :class => 'icon icon-wiki') %> <% end %> diff --git a/app/views/workflows/edit.html.erb b/app/views/workflows/edit.html.erb index aee0130c55..2c09dee62a 100644 --- a/app/views/workflows/edit.html.erb +++ b/app/views/workflows/edit.html.erb @@ -47,7 +47,7 @@ See doc/COPYRIGHT.rdoc for more details.

-<%= submit_tag l(:button_edit), :name => nil %> +<%= submit_tag l(:button_edit), :name => nil, :accesskey => accesskey(:edit) %>

<% end %>