Local avatars Plugin v.0.0.1
Added by Andrew Chaika over 15 years ago
I use Redmine in intranet, and can't register corporate emails in gravatar.
Because of it I decide to make this plugin.
- Avatars can be changed only by administrator for any user (Avatar Tab)
- No modifications or restrictions on avatar size
- No settings to disable avatars
- Avatars can't be deleted once uploaded, only replaced
Replies (51)
RE: Local avatars Plugin v.0.0.1
-
Added by Łukasz Rżanek almost 15 years ago
Polish translation, very simple to do.
Please add that to the tree...
RE: Local avatars Plugin v.0.0.1
-
Added by K S over 14 years ago
Andrew Chaika wrote:
I use Redmine in intranet, and can't register corporate emails in gravatar.
Restrictons of 0.0.1 version:
Because of it I decide to make this plugin.
- Avatars can be changed only by administrator for any user (Avatar Tab)
- No modifications or restrictions on avatar size
- No settings to disable avatars
- Avatars can't be deleted once uploaded, only replaced
I have a problem with redmine_local_avatar 001 and _02 plugin.
rage gie me this error, when I add plugin to /vendor/plugin directory:
@-bash-3.00# rake db:migrate_plugins RAILS_ENV=production --trace(in /opt/redmine-0.8.7)
- Invoke db:migrate_plugins (first_time)
- Invoke environment (first_time)
- Execute environment
rake aborted!
Missing session secret. Please run 'rake config/initializers/session_store.rb' to generate one
/opt/redmine-0.8.7/app/controllers/application.rb:29
/opt/coolstack/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
/opt/coolstack/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:355:in `new_constants_in'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require'
/opt/redmine-0.8.7/vendor/plugins/redmine_local_avatars/lib/users_avatar_patch.rb:1
/opt/coolstack/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
/opt/coolstack/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:355:in `new_constants_in'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require'
/opt/redmine-0.8.7/vendor/plugins/redmine_local_avatars/init.rb:3:in `evaluate_init_rb'
/opt/redmine-0.8.7/vendor/rails/railties/lib/rails/plugin.rb:95:in `evaluate_init_rb'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/core_ext/kernel/reporting.rb:11:in `silence_warnings'
/opt/redmine-0.8.7/vendor/rails/railties/lib/rails/plugin.rb:91:in `evaluate_init_rb'
/opt/redmine-0.8.7/vendor/rails/railties/lib/rails/plugin.rb:44:in `load'
/opt/redmine-0.8.7/config/../vendor/plugins/engines/lib/engines/plugin.rb:77:in `load'
/opt/redmine-0.8.7/vendor/rails/railties/lib/rails/plugin/loader.rb:33:in `load_plugins'
/opt/redmine-0.8.7/vendor/rails/railties/lib/rails/plugin/loader.rb:32:in `each'
/opt/redmine-0.8.7/vendor/rails/railties/lib/rails/plugin/loader.rb:32:in `load_plugins'
/opt/redmine-0.8.7/vendor/rails/railties/lib/initializer.rb:292:in `load_plugins'
/opt/redmine-0.8.7/vendor/rails/railties/lib/initializer.rb:142:in `process'
/opt/redmine-0.8.7/vendor/rails/railties/lib/initializer.rb:97:in `send'
/opt/redmine-0.8.7/vendor/rails/railties/lib/initializer.rb:97:in `run'
/opt/redmine-0.8.7/config/environment.rb:22
/opt/coolstack/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
/opt/coolstack/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:355:in `new_constants_in'
/opt/redmine-0.8.7/vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require'
/opt/redmine-0.8.7/vendor/rails/railties/lib/tasks/misc.rake:3
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `call'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `execute'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `each'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `execute'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:597:in `invoke_with_call_chain'
/opt/coolstack/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in `invoke_with_call_chain'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:607:in `invoke_prerequisites'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in `each'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in `invoke_prerequisites'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:596:in `invoke_with_call_chain'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:583:in `invoke'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2051:in `invoke_task'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `top_level'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `each'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `top_level'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in `standard_exception_handling'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2023:in `top_level'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2001:in `run'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in `standard_exception_handling'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:1998:in `run'
/opt/coolstack/lib/ruby/gems/1.8/gems/rake-0.8.7/bin/rake:31
/usr/bin/rake:19:in `load'
/usr/bin/rake:19@
And proces are stopped.
I have a redmine-0.8.7 stable version.
I still generate rake config/initializers/session_store.rb...
RE: Local avatars Plugin v.0.0.1
-
Added by Colin Fahrion over 14 years ago
Anyone got this working? I'm running the latest stable version of Redmine. Tried installing this, copied to plugins, migrated db, and all it did was break the entire redmine app. I'd love to set up local avatars for my users.
RE: Local avatars Plugin v.0.0.1
-
Added by Amy E over 14 years ago
I have also tried installing both 0.0.1 and 0.0.2 and it doesn't seem to be working with 0.8.7.
С наступающим Новым годом всех форумчан!
-
Added by kinjorak kinjorak over 14 years ago
Поздравляю всех присутствующих ( и отсутствующих ) с Новым, 2010 годом! Счастья, успехов и всех благ в следующем году, пусть следующий год станет годом исполнения всех ваших желаний.
RE: Local avatars Plugin v.0.0.1
-
Added by Vitaly Klimov over 14 years ago
It seems that latest trunk version of users_controller.rb also uses before_filter, so if you try to add Local Avatars plugin you will not be able to see user's info at all (unless you are admin) (somehow before_filter in Local Avatars overrides except rule for require_admin filter)
It could be temporarily solved by modifying line in Local Avatar's users_controller.rb to
before_filter :require_admin, :except => [:get_avatar, :show]
but apparently we would need normal solution here
Also regarding missing constant:
Jérémy Lal wrote:
I tried the plugin version 0.0.2 against redmine trunk (before rails 2.3.4 migration), and i get this when i start redmine with webrick :
[...]
Tell me if you want the full stack trace.
I have solved this issue by adding following lines to lib\users_avatar_patch.rb
require_dependency 'principal' require_dependency 'user'
Hope this helps
Всех с наступившим Рождеством и прошедшим Новым годом!
-
Added by kinjorak kinjorak over 14 years ago
Всех со Светлым Рождеством! Желаю счастья, успехов, благополучия и душевного равновесия Вам и Вашим близким родным людям. Вашему сайту желаю всегда иметь топовые позиции в поисковых без искуственного повышения рейтинга, и чтобы вам никогда не требовалась [url=http://sd-spb.ru]раскрутка сайта[/url] сторонними специалистами, а все шло проложенным путем - и раскрутка сайта, и нормальный прирост
посетителей и положение в поисковых.
RE: Local avatars Plugin v.0.0.1
-
Added by Chris Ligon over 14 years ago
Vitaly Klimov wrote:
I have solved this issue by adding following lines to libusers_avatar_patch.rb
[...]
Hope this helps
This does not work for me. Even after adding these lines I still get this stack trace when running migrate_plugins...
- Invoke db:migrate_plugins (first_time)
- Invoke environment (first_time)
- Execute environment
rake aborted!
no such file to load -- application
/home/cligon/jruby-1.4.0/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
/home/cligon/jruby-1.4.0/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
/home/cligon/redmine-0.9.1/vendor/rails/activesupport/lib/active_support/depende
ncies.rb:158:in `require'
/home/cligon/redmine-0.9.1/vendor/plugins/redmine_local_avatars/lib/users_avatar
_patch.rb:1
/home/cligon/redmine-0.9.1/vendor/plugins/redmine_local_avatars/lib/users_avatar
_patch.rb:31:in `require'
/home/cligon/jruby-1.4.0/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
/home/cligon/redmine-0.9.1/vendor/rails/activesupport/lib/active_support/depende
ncies.rb:158:in `require'
/home/cligon/redmine-0.9.1/vendor/plugins/redmine_local_avatars/init.rb:3:in `ev
aluate_init_rb'
RE: Local avatars Plugin v.0.0.1
-
Added by Michael Jahn over 14 years ago
I use the local avatars plugin with Redmine 0.9.1 and it works. I had to change the first lines of the file users_avatar_patch.rb:
require 'application_controller' #require 'user' require_dependency 'principal' require_dependency 'user' module LocalAvatarsPlugin module UsersAvatarPatch def self.included(base) # :nodoc: ...
BTW: I added the german translation file to this post.
RE: Local avatars Plugin v.0.0.1
-
Added by Admins Q3 over 14 years ago
Thanks Michael, that worked for me with Redmine trunk.
Added Spanish translation.
RE: Local avatars Plugin v.0.0.1
-
Added by Michael Jahn over 14 years ago
Tyler Mulligan wrote:
Has anyone gotten this working for r3009+ ? I'm getting a 500 internal server error when I try to upload the avatars.
NoMethodError (undefined method `original_filename' for "z.gif":String):
app/models/attachment.rb:58:in `file='
app/controllers/application_controller.rb:199:in `attach_files'
app/controllers/application_controller.rb:196:in `each_value'
app/controllers/application_controller.rb:196:in `attach_files'
[...]
Yes, I got it with Redmine 0.9.2 + local avatars plugin 0.0.2.
I fixed it in app\views\my\account.html
- :html => { :id => 'my_account_form' } do |f| %> + :html => { :id => 'my_account_form', :multipart => true } do |f| %>
I'm not sure if there is another way without changing the redmine source code base.
RE: Local avatars Plugin v.0.0.1
-
Added by Tyler Mulligan over 14 years ago
Michael Jahn's fix worked for me.
I just wish users could change their own avatars.
RE: Local avatars Plugin v.0.0.1
-
Added by Tyler Mulligan over 14 years ago
I spoke too soon. My users are getting a 403
http://website.com/users/get_avatar/22
Where I as an admin have no issue viewing them.
RE: Local avatars Plugin v.0.0.1
-
Added by Tyler Mulligan over 14 years ago
adding the following to line 6 in users_controller.rb fixed it
before_filter :require_admin, :except => [:get_avatar, :show]
thanks to Vitaly Klimov on that one
Я что-то не врубаюсь! Шо за дела!
-
Added by viktorriakiyvskaya viktorriakiyvskaya over 14 years ago
Привет. Сбрендили ващеееее!
P/S вот нашел[url=http://www.rezultat.com.ua/page_service_service149.html] срочная регистрация торговой марки[/url], там пишут, что таки да
RE: Local avatars Plugin v.0.0.1
-
Added by Alexander Kulemin over 14 years ago
If you have a problem with editing users avatar in trunc ver.:
1. add string acts_as_attachable
to redmine_local_avatars/lib/users_avatar_patch.rb
base.class_eval do unloadable acts_as_attachable #++ has_many :att
2. in redmine_local_avatars/lib/users_controller.rb
change
attachments = attach_files(@user, {'first' => {'file' => file_field, 'description' => 'avatar'}})
TO
attachments = Attachment.attach_files(@user, {'first' => {'file' => file_field, 'description' => 'avatar'}})
RE: Local avatars Plugin v.0.0.1
-
Added by Daniel S about 14 years ago
At http://github.com/dseifert/redmine_local_avatars I added a fork with all patches mentioned in this thread and also support for users deleting their avatar. Tested on Redmine 1.0.0.
RE: Local avatars Plugin v.0.0.1
-
Added by Hugo Leo almost 14 years ago
Alexander Kulemin wrote:
If you have a problem with editing users avatar in trunc ver.:
1. add string
acts_as_attachable
toredmine_local_avatars/lib/users_avatar_patch.rb
[...]2. in
redmine_local_avatars/lib/users_controller.rb
change
[...]
TO
[...]
for backwards compatibility:
1: redmine_local_avatars/app/controllers/users_controller.rb
attachments = defined?(attach_files) ? attach_files(@user, {'first' => {'file' => file_field, 'description' => 'avatar'}}) : Attachment.attach_files(@user, {'first' => {'file' => file_field, 'description' => 'avatar'}})
2: redmine_local_avatars/lib/my_account_patch.rb
attachments = defined?(attach_files) ? attach_files(@user, {'first' => {'file' => file_field, 'description' => 'avatar'}}) : Attachment.attach_files(@user, {'first' => {'file' => file_field, 'description' => 'avatar'}})
RE: Local avatars Plugin v.0.0.1
-
Added by Victor Dulepov over 13 years ago
RE: Local avatars Plugin v.0.0.1
-
Added by Dirk Schmidt over 13 years ago
Version 0.0.3 is not working with Redmine 1.1.0.
If i install the plugin and restart redmine (using mongrel) the Website is not responding.
Removing the plugin helps, but is there anyone having an idea what kind of Problem this is?
RE: Local avatars Plugin v.0.0.1
-
Added by Marcelo Fernandes over 13 years ago
Daniel S wrote:
At http://github.com/dseifert/redmine_local_avatars I added a fork with all patches mentioned in this thread and also support for users deleting their avatar. Tested on Redmine 1.0.0.
I tested this plugin and the only problem is that avatar image is not shown at global activity link.
I'm using redmine 1.1.2
RE: Local avatars Plugin v.0.0.1
-
Added by Steven Wong over 12 years ago
could it support the redmine 1.4.X?
anyone knows?
RE: Local avatars Plugin v.0.0.1
-
Added by Dima Antonov over 12 years ago
could it support the redmine 1.4.X? anyone knows?
NO
RE: Local avatars Plugin v.0.0.1
-
Added by Martin G about 12 years ago
Dima Antonov wrote:
[...]
NO
Anyone knows what's the problem?
RE: Local avatars Plugin v.0.0.1
-
Added by Martin G about 12 years ago
This version will work with 1.4: