commit
d48cc8073a
@ -1,7 +1,11 @@
|
||||
<% if User.current.logged?%>
|
||||
<% if User.current == target%>
|
||||
<%= link_to("编辑资料", my_account_path, :class => "fl UsersEditBtn")%>
|
||||
<% else%>
|
||||
<%if(target.watched_by?(User.current))%>
|
||||
<%= link_to "",watch_path(:object_type=> 'user',:object_id=>target.id,:target_id=>target.id),:class => "homepageFollow", :method => "delete",:remote => "true", :title => "取消关注"%>
|
||||
<%= link_to "取消关注",watch_path(:object_type=> 'user',:object_id=>target.id,:target_id=>target.id),:class => "UsersApBtn", :method => "delete",:remote => "true", :title => "取消关注"%>
|
||||
<% else %>
|
||||
<%= link_to "",watch_path(:object_type=> 'user',:object_id=>target.id,:target_id=>target.id),:class => "homepageFollowCancel", :method => "post",:remote => "true", :title => "添加关注"%>
|
||||
<%= link_to "添加关注",watch_path(:object_type=> 'user',:object_id=>target.id,:target_id=>target.id),:class => "UsersAttBtn", :method => "post",:remote => "true", :title => "添加关注"%>
|
||||
<% end %>
|
||||
<% end%>
|
||||
<% end %>
|
@ -1,3 +1,3 @@
|
||||
$("#nh_user_tx").replaceWith('<%= image_tag(url_to_avatar(@user), :id=>'nh_user_tx',:style=>"width:214px;height:214px;overflow:hidden",:alt=>"头像") %>');
|
||||
$("#nh_user_tx").replaceWith('<%= image_tag(url_to_avatar(@user), :id=>'nh_user_tx',:style=>"width:90px;height:90px;overflow:hidden",:alt=>"头像") %>');
|
||||
$("#nh_user_logo").replaceWith('<%= image_tag(url_to_avatar(@user), :id=>'nh_user_logo',:width =>"40",:height => "40",:alt=>"头像") %>');
|
||||
hideModal();
|
@ -1,16 +1,9 @@
|
||||
class CreateUserActivity < ActiveRecord::Migration
|
||||
def up
|
||||
create_table :user_activities do |t|
|
||||
t.string :act_type
|
||||
t.integer :act_id
|
||||
t.string :container_type
|
||||
t.integer :container_id
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
|
||||
def down
|
||||
drop_table :user_activities
|
||||
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in new issue