If I fetch the issue list as an atom feed and I want to refresh the feed it doesn't work.
I made a small hack to fix the issue but I'm not a ruby programmer. I think there are better solutions then mine.
It also fixes some troubles with TurtleMine (a Tortoise Redmine Plugin) when grabbing the issue list as atom feed.
module RedmineIssuesTree::IssuesControllerPatch
extend ActiveSupport::Concern
included do
alias_method_chain :index, :redmine_issues_tree
end
def index_with_redmine_issues_tree
case params[:format]
when 'csv', 'pdf', 'atom', 'xml', 'json'
index_without_redmine_issues_tree
else
skip_issues_tree_redirect = params.delete(:skip_issues_tree_redirect)
if params[:project_id].present?
if Setting.plugin_redmine_issues_tree.with_indifferent_access[:default_redirect_to_tree_view] == 'true'
# @note: add additional parameter into all links on issues#index looks not so good as parsing a referer
# @reason: we must prevent redirect to the tree_view if we do some actions on a plain view
if skip_issues_tree_redirect == 'true' || URI(request.referer).path == project_issues_path
index_without_redmine_issues_tree
else
redirect_to tree_index_project_issues_trees_path(request.query_parameters)
end
else
index_without_redmine_issues_tree
end
else
if Setting.plugin_redmine_issues_tree.with_indifferent_access[:default_redirect_to_tree_view_without_project] == 'true'
# @note: add additional parameter into all links on issues#index looks not so good as parsing a referer
# @reason: we must prevent redirect to the tree_view if we do some actions on a plain view
if skip_issues_tree_redirect == 'true' || URI(request.referer).path == issues_path
index_without_redmine_issues_tree
else
redirect_to tree_index_issues_trees_path(request.query_parameters)
end
else
index_without_redmine_issues_tree
end
end
end
end
module ClassMethods
# stub
end
end
Redmine 3.2.x, plugin from the 3.2 branch
If I fetch the issue list as an atom feed and I want to refresh the feed it doesn't work. I made a small hack to fix the issue but I'm not a ruby programmer. I think there are better solutions then mine. It also fixes some troubles with TurtleMine (a Tortoise Redmine Plugin) when grabbing the issue list as atom feed.