From 43d70360512379c4a544892f3589ae1bc9861f7b Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sat, 5 Apr 2014 14:00:19 +0000 Subject: Adds "Check for updates" for installed plugins (#3177). git-svn-id: http://svn.redmine.org/redmine/trunk@13042 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/helpers/admin_helper.rb | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'app/helpers/admin_helper.rb') diff --git a/app/helpers/admin_helper.rb b/app/helpers/admin_helper.rb index fa487a2f6..b5dc67982 100644 --- a/app/helpers/admin_helper.rb +++ b/app/helpers/admin_helper.rb @@ -24,4 +24,12 @@ module AdminHelper [l(:project_status_closed), '5'], [l(:project_status_archived), '9']], selected.to_s) end + + def plugin_data_for_updates(plugins) + data = {"v" => Redmine::VERSION.to_s, "p" => {}} + plugins.each do |plugin| + data["p"].merge! plugin.id => {"v" => plugin.version, "n" => plugin.name, "a" => plugin.author} + end + data + end end -- cgit v1.2.3