首页:如图关注列表中添加关注、取消关注后关注数统计未自动刷新
This commit is contained in:
parent
e29eb67f68
commit
d6c51cce2a
|
@ -143,7 +143,7 @@
|
|||
<li>
|
||||
<a href="<%= user_watchlist_user_path(@user) %>">
|
||||
<strong>关注</strong><br />
|
||||
<span class="sy_cgrey"><%= User.watched_by(@user).count %></span>
|
||||
<span class="sy_cgrey" id="user_watchers_number"><%= User.watched_by(@user).count %></span>
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
|
|
|
@ -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]}) %>");
|
||||
|
|
Loading…
Reference in New Issue