From 00faafc1723fa8e818d4673de9195e8730ad8979 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 7 Jun 2016 15:42:55 +0200 Subject: [PATCH 1/4] Moving the render so that 'Related projects' be listed right after redmine's default 'Related issues' --- app/overrides/issues/show.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/overrides/issues/show.rb b/app/overrides/issues/show.rb index 60eb533..299ffda 100644 --- a/app/overrides/issues/show.rb +++ b/app/overrides/issues/show.rb @@ -1,5 +1,6 @@ Deface::Override.new :virtual_path => 'issues/show', :original => 'ee65ebb813ba3bbf55bc8dc6279f431dbb405c48', :name => 'show-projects-in-issue-description', - :insert_after => '.attributes', + #:insert_after => '.attributes', + :insert_after => '#relations', :partial => 'issues/show_projects' From 946bb28213ed73ecf6909aee5065ae92f28825d0 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 7 Jun 2016 15:49:43 +0200 Subject: [PATCH 2/4] Commenting-out un-necessary margin-top value for 'Related project' links; un-necessary as removed the class 'list_projects_names' from the view's render (leaving the class for edit/.js views which can keep using this border-boxed-style) --- app/views/issues/_projects_list.html.erb | 2 +- assets/stylesheets/multiprojects_issue.css | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/issues/_projects_list.html.erb b/app/views/issues/_projects_list.html.erb index 82372be..f05f7c2 100644 --- a/app/views/issues/_projects_list.html.erb +++ b/app/views/issues/_projects_list.html.erb @@ -8,7 +8,7 @@ <% issue_projects.each do |project| %> <% if allowed_projects.include?(project) %> - <%= content_tag("span", link_to(project.name.gsub(/ /," ").html_safe, project_issues_path(project)), class: "list_projects_names") %> + <%= content_tag("span", link_to(project.name.gsub(/ /," ").html_safe, project_issues_path(project))) %> <% nb_visible_projects += 1 %> <% else %> <% nb_other_projects += 1 %> diff --git a/assets/stylesheets/multiprojects_issue.css b/assets/stylesheets/multiprojects_issue.css index 0213597..a0103f6 100644 --- a/assets/stylesheets/multiprojects_issue.css +++ b/assets/stylesheets/multiprojects_issue.css @@ -28,7 +28,7 @@ a.list_projects_names.current{ font-weight: bold; display: inline-block; /* vertical-align: super; */ - margin-top: 4px; + /* margin-top: 4px; */ } .projects_container{ From ff2e30f9f51ecc32fe7c74d56fef1a19e1acb5e1 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 7 Jun 2016 15:50:35 +0200 Subject: [PATCH 3/4] closing
--- app/views/issues/_show_projects.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/issues/_show_projects.html.erb b/app/views/issues/_show_projects.html.erb index 42d77e7..fe1023f 100644 --- a/app/views/issues/_show_projects.html.erb +++ b/app/views/issues/_show_projects.html.erb @@ -1,5 +1,5 @@ <% if (@issue.projects-[@issue.project]).present? %> -
+
<%= l("concerned_projects") %><%= render 'projects_list' %>
From afde100d3422ab604071c23b5dae12d84e53b14a Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 7 Jun 2016 15:52:52 +0200 Subject: [PATCH 4/4] Changed name to 'Related projects', as it fits in better with redmine's default 'Related issues' section --- config/locales/en.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/locales/en.yml b/config/locales/en.yml index 7473cb1..aa52d13 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -1,6 +1,6 @@ # English strings go here for Rails i18n en: - concerned_projects: "Impacted projects" + concerned_projects: "Related projects" modify_projects: "Edit projects list" select_none: "None" select_all: "All" @@ -13,6 +13,6 @@ en: text_journal_project_deleted: "deleted project" text_journal_project_added: "added project" label_hide_details: "hide" - field_projects: "Impacted projects" + field_projects: "Related projects" field_answers_on_secondary_projects: "Answers allowed" multiprojects_selection_available_custom_fields: "Available custom fields to quickly select projects"