diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2014-04-05 14:00:19 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2014-04-05 14:00:19 +0000 |
commit | 43d70360512379c4a544892f3589ae1bc9861f7b (patch) | |
tree | 6dd317e4f9e6f16b1fdbdbfbb9b99eaf78663d83 /app/helpers/admin_helper.rb | |
parent | 4920bb9d4d9a13d97c21a621d3659967b57b93f4 (diff) | |
download | redmine-43d70360512379c4a544892f3589ae1bc9861f7b.tar.gz redmine-43d70360512379c4a544892f3589ae1bc9861f7b.zip |
Adds "Check for updates" for installed plugins (#3177).
git-svn-id: http://svn.redmine.org/redmine/trunk@13042 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/helpers/admin_helper.rb')
-rw-r--r-- | app/helpers/admin_helper.rb | 8 |
1 files changed, 8 insertions, 0 deletions
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 |