解决以下问题:1.编辑个人首页后,返回至个人动态;2.个人名片中,正确显示个人信息;3.同意申请子域名后,显示已同意申请。

This commit is contained in:
ouyangxuhua 2016-01-26 10:35:54 +08:00
parent 1607508887
commit dda64245b3
3 changed files with 10 additions and 5 deletions

View File

@ -55,8 +55,8 @@ class BlogCommentsController < ApplicationController
if params[:in_act]
redirect_to user_path(params[:user_id])
else
if params[:is_homepage]
redirect_to user_blogs_path(params[:user_id])
if @article.id.eql?(User.find(params[:user_id]).blog.homepage_id)
redirect_to user_path(params[:user_id])
else
redirect_to user_blog_blog_comment_path(:user_id=>params[:user_id],:blog_id=>params[:blog_id],:id=>params[:id])
end

View File

@ -6,11 +6,16 @@
</div>
<div class="fl">
<p class="homepageImageName mb5 hidden" style="max-width:88px;font-size:16px; color:#484848; margin-left:15px; margin-right:8px; height:21px; float:left;"><%= user %></p>
<span class="homepageImageSex"></span>
<% if (user.user_extensions && (user.user_extensions.identity != 2) ) %>
<span class="<%= user.user_extensions.gender == 1 ? 'homepageImageSexWomen' : 'homepageImageSexMan' %> "></span>
<% end %>
<!--<span class="homepageImageSex"></span>-->
<div class="cl"></div>
<p class="mb8 c_dark f14">
<span class="mr15 hidden fl ml15" style="max-width:90px;"><%= user.show_name %></span>
<%= user.user_extensions.technical_title %>
<% if user.user_extensions && user.user_extensions.identity %>
<%= get_user_roll(user) %>
<% end %>
</p>
</div>
<div class="cl"></div>

View File

@ -12,7 +12,7 @@
<%= ma.content %>
</li>
<li class="homepageHomeworkContentWarn fl">
<%=link_to (ma.organization.domain.nil? || (ma.organization.domain && ma.organization.domain != ma.content)) ? "同意申请":"已同意申请",
<%=link_to (ma.organization.domain.nil? || (ma.organization.domain && ma.organization.domain != ma.content)) ? "同意申请":"申请已批准",
agree_apply_subdomain_organizations_path( :organization_id => ma.organization_id, :org_domain => ma.content, :user_id => ma.sender_id, :act_id => ma.id ),
:id => "agree_apply_subdomain_#{ma.id}",
:method => 'post',