|
|
|
@ -10,7 +10,7 @@
|
|
|
|
|
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2', 'new_public', 'user_leftside', :media => 'all' %>
|
|
|
|
|
<%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
|
|
|
|
|
<%= javascript_heads %>
|
|
|
|
|
<%= javascript_include_tag "bootstrap"%>
|
|
|
|
|
<%= javascript_include_tag "bootstrap","avatars"%>
|
|
|
|
|
<%= heads_for_theme %>
|
|
|
|
|
<%= call_hook :view_layouts_base_html_head %>
|
|
|
|
|
<%= yield :header_tags -%>
|
|
|
|
@ -30,12 +30,12 @@
|
|
|
|
|
<div class="homepageLeft">
|
|
|
|
|
<div class="homepagePortraitContainer">
|
|
|
|
|
<div class="homepagePortraitImage">
|
|
|
|
|
<%= image_tag(url_to_avatar(@user),width:"206", height: "206") %>
|
|
|
|
|
<%= image_tag(url_to_avatar(@user),width:"206", height: "206", :id=>'nh_user_tx') %>
|
|
|
|
|
<% if User.current.logged?%>
|
|
|
|
|
<% if User.current == @user%>
|
|
|
|
|
<div>
|
|
|
|
|
<div class="homepageEditProfile">
|
|
|
|
|
<a href="javascript:void(0);" class="homepageEditProfileIcon"></a>
|
|
|
|
|
<a href="<%= url_for(:controller => 'my', :action => 'clear_user_avatar_temp') %>" data-remote="true" class="homepageEditProfileIcon"></a>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<% else %>
|
|
|
|
@ -174,5 +174,66 @@
|
|
|
|
|
</div>
|
|
|
|
|
<%= render :partial => 'layouts/new_feedback' %>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div id="ajax-modal" style="display:none;"></div>
|
|
|
|
|
<div id="ajax-indicator" style="display:none;">
|
|
|
|
|
<span><%= l(:label_loading) %></span>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="nh_tx_dialog_html" class="white_content" style="display:none;">
|
|
|
|
|
<div>
|
|
|
|
|
<div><a href="javascript:hideModal();" class="box_close"></a></div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div class="pro_new">
|
|
|
|
|
<h3 class="box_h3 mb10">头像设置</h3>
|
|
|
|
|
<div class="uppicBox">
|
|
|
|
|
<%= file_field_tag 'avatar[image]',
|
|
|
|
|
:id => nil,
|
|
|
|
|
:class => 'uppic_btn',
|
|
|
|
|
:style => 'width:70px;',#added by young
|
|
|
|
|
:size => "1",
|
|
|
|
|
:multiple => false,
|
|
|
|
|
:onchange => 'addInputAvatar(this);',
|
|
|
|
|
:data => {
|
|
|
|
|
:max_file_size => Setting.attachment_max_size.to_i.kilobytes,
|
|
|
|
|
:max_file_size_message => l(:error_attachment_too_big, :max_size => number_to_human_size(Setting.attachment_max_size.to_i.kilobytes)),
|
|
|
|
|
:max_concurrent_uploads => Redmine::Configuration['max_concurrent_ajax_uploads'].to_i,
|
|
|
|
|
:file_type => Redmine::Configuration['pic_types'].to_s,
|
|
|
|
|
:type_support_message => l(:error_pic_type),
|
|
|
|
|
:upload_path => upload_avatar_path(:format => 'js'),
|
|
|
|
|
:description_placeholder => nil ,# l(:label_optional_description)
|
|
|
|
|
:source_type => @user.class.to_s,
|
|
|
|
|
:source_id => @user.id.to_s
|
|
|
|
|
} %>
|
|
|
|
|
<!--<br/>-->
|
|
|
|
|
<!--<span>只支持jpg,png,gif,大小不超过5M</span>-->
|
|
|
|
|
</div>
|
|
|
|
|
<div class="showpicBox">
|
|
|
|
|
<p>预览</p>
|
|
|
|
|
<%= image_tag(url_to_avatar(@user), :style=>"width:96px;height:96px;",:class=>"mb5 mt10",:nhname=>'avatar_image') %>
|
|
|
|
|
<span >96px*96px</span> <br />
|
|
|
|
|
<div class="mb20"></div>
|
|
|
|
|
<%= image_tag(url_to_avatar(@user), :style=>"width:48px;height:48px;",:class=>"mb5",:nhname=>'avatar_image') %>
|
|
|
|
|
<br />
|
|
|
|
|
<span>48px*48px</span> <br />
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl mb10"></div>
|
|
|
|
|
<a href="javascript:hideModal();" class=" fr grey_btn mr15"> 取 消</a>
|
|
|
|
|
<a href="<%= url_for(:controller => 'my', :action => 'save_user_avatar') %>" data-remote="true" class="blue_btn fr mr10">确 定</a>
|
|
|
|
|
</div><!--talknew end-->
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
</div><!--floatbox end-->
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
$(function(){
|
|
|
|
|
if($(".top_new").length==0){
|
|
|
|
|
$("#RSide").css("min-height",$("#LSide").height()-30);
|
|
|
|
|
}
|
|
|
|
|
else{
|
|
|
|
|
$("#RSide").css("min-height",$("#LSide").height()-87);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
</script>
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|
|
|
|
|