<% if @user.avatar? %>
<%= image_tag(@user.avatar.thumb.url) %>
<% else %>
<%= image_tag "person.png" %>
<% end %>
<%= file_field_tag 'file' %>
<%= hidden_field_tag :avatar_cache %>
<% @user_info_models.each do |ua| %>
<%= ua.i18n_variable[I18n.locale] %>
<%= render :partial => 'user_attribute',
:object => (@user.user_infos.detect {|u| u.key == ua.key } || @user.user_infos.build),
:locals => {:ua => ua, :type => 'info'} %>
<% end -%>
<% @user_role_models.each do |ua| %>
>
<%= ua.i18n_variable[I18n.locale] %>
<%= render :partial => 'user_attribute',
:object => (@user.user_roles.detect {|u| u.key == ua.key } || @user.user_roles.build),
:locals => {:ua => ua, :type => 'role'} %>
<% end -%>
<% content_for :page_specific_javascript do %>
<%= javascript_include_tag "user_form" %>
<% end -%>