diff --git a/app/views/layouts/new_base_user.html.erb b/app/views/layouts/new_base_user.html.erb index 35b106059..dfa6afb0a 100644 --- a/app/views/layouts/new_base_user.html.erb +++ b/app/views/layouts/new_base_user.html.erb @@ -143,7 +143,7 @@
  • 关注
    - <%= User.watched_by(@user).count %> + <%= User.watched_by(@user).count %>
  • diff --git a/app/views/watchers/_set_watcher.js.erb b/app/views/watchers/_set_watcher.js.erb index 83358b049..016465391 100644 --- a/app/views/watchers/_set_watcher.js.erb +++ b/app/views/watchers/_set_watcher.js.erb @@ -14,6 +14,8 @@ $("#fans_user_number_div").html('<%= escape_javascript ( link_to User.find(params[:target_id]).watcher_users.count.to_s, {:controller=>"users", :action=>"user_fanslist",:id=>params[:target_id]},:class=>"homepageImageNumber", :id => "user_fans_number") %>'); $("#fans_span").html('<%= count %>'); $("#watch_span").html('<%= count %>'); + $("#user_watchers_number").html('<%= User.watched_by(User.current).count %>'); + $("#user_fans_number").html('<%= User.current.watcher_users.count %>'); //在其他用户的粉丝、关注页面 <% else %> $("#users_list").html("<%= escape_javascript (render :partial => 'users/user_fans_item', :locals => {:list => list,:target=>User.find(params[:target_id]),:action_name=>action_name,:page=>params[:page]}) %>");