fix link to

This commit is contained in:
xianbo 2013-11-02 12:42:30 +08:00
parent 606b2d0587
commit 003b4704cc
6 changed files with 12 additions and 15 deletions

View File

@ -1354,7 +1354,7 @@ module ApplicationHelper
html << (content_tag "span", l(:label_no_current_watchers))
end
for user in User.watched_by(obj.id)
html << (image_tag(url_to_avatar(user), :class => "avatar"))
html << (link_to image_tag(url_to_avatar(user), :class => "avatar"), user_path(user), :class => "avatar", :title => "#{user.name}")
count = count + 1
if count >= 12
break
@ -1379,7 +1379,7 @@ module ApplicationHelper
html << (content_tag "span", l(:label_no_current_fans))
end
for user in obj.watcher_users
html << (image_tag(url_to_avatar(user), :class => "avatar"))
html << (link_to image_tag(url_to_avatar(user), :class => "avatar"), user_path(user), :class => "avatar", :title => "#{user.name}")
count = count + 1
if count >= 12
break
@ -1393,7 +1393,7 @@ module ApplicationHelper
html = ''
count = 0
for user in User.watched_by(user.id)
html << (image_tag(url_to_avatar(user), :class => "avatar"))
html << (link_to image_tag(url_to_avatar(user), :class => "avatar"), user_path(user), :class => "avatar", :title => "#{user.name}")
count = count + 1
if count >= 12
break

View File

@ -93,8 +93,7 @@
<% if @bid.watcher_users.size>0 %>
<% for user in @bid.watcher_users%>
<%= image_tag(url_to_avatar(user), :class => "avatar", :title => user.name ) %>
<% end %>
<%= link_to image_tag(url_to_avatar(user), :class => "avatar", :title => user.name ), user_path(user), :class => "avatar" %> <% end %>
<% else %>
<p class="font_lighter"><%= l(:label_project_no_follow) %></p>
<% end%>
@ -115,7 +114,7 @@
<td style="padding-top: 5px">
<% if @bid.projects.size>0 %>
<% for project in @bid.projects%>
<%= image_tag(url_to_avatar(project), :class => "avatar", :title => project.name) %>
<%= link_to image_tag(url_to_avatar(project), :class => "avatar", :title => project.name), project_path(project), :class => "avatar" %> <%= image_tag(url_to_avatar(project), :class => "avatar", :title => project.name) %>
<% end%>
<% else %>
<p class="font_lighter"><%= l(:label_no_bid_project) %></p>

View File

@ -104,8 +104,7 @@
<td style="padding-top: 5px"> <% if @bid.homework_type == 1%>
<% if @bid.homeworks.size>0 %>
<% for homework in @bid.homeworks %>
<%= image_tag(url_to_avatar(homework.user), :class => "avatar", :title => homework.user.name) %>
<% end %>
<%= link_to image_tag(url_to_avatar(homework.user), :class => "avatar", :title => homework.user.name), user_path(homework.user), :class => "avatar" %> <% end %>
<% else %>
<p class="font_lighter">
<%= l(:label_no_course_project) %>
@ -113,8 +112,7 @@
<% else %>
<% if @bid.projects.size>0 %>
<% for project in @bid.projects%>
<%= image_tag(url_to_avatar(project), :class => "avatar", :title => project.name) %>
<% end %>
<%= link_to image_tag(url_to_avatar(project), :class => "avatar", :title => project.name), project_path(project), :class => "avatar" %> <% end %>
<% else %>
<p class="font_lighter">
<%= l(:label_no_course_project) %>

View File

@ -35,7 +35,7 @@
<div class="inf_user_image">
<table>
<tr>
<td align="left" valign="middle" ><%= image_tag(url_to_avatar(@user), :class => 'avatar2') %></td>
<td align="left" valign="middle" ><%= image_tag(url_to_avatar(@user), :class => 'avatar2') %></td>
<td>
<table>
<tr>

View File

@ -5,8 +5,8 @@
<ul class="list_watch"><li>
<table width="660px" border="0" align="center">
<tr>
<td colspan="2" valign="top" width="50" ><%= image_tag(url_to_avatar(user), :class => "avatar") %></td>
<td><table width="580px" border="0">
<td colspan="2" valign="top" width="50" ><%= link_to image_tag(url_to_avatar(user), :class => "avatar"), user_path(user), :title => "#{user.name}" %></td>
<td><table width="580px" border="0">
<tr>
<td colspan="2" valign="top"><strong><%= content_tag "div", link_to_user(user), :class => "project_avatar_name" %>
</td>

View File

@ -4,8 +4,8 @@
<ul class="list_watch"><li>
<table width="660px" border="0" align="center">
<tr>
<td colspan="2" valign="top" width="50" ><%= image_tag(url_to_avatar(user), :class => "avatar") %></td>
<td><table width="580px" border="0">
<td colspan="2" valign="top" width="50" ><%= link_to image_tag(url_to_avatar(user), :class => "avatar"), user_path(user), :title => "#{user.name}" %></td>
<td><table width="580px" border="0">
<tr>
<td colspan="2" valign="top"><strong><%= content_tag "div", link_to_user(user), :class => "project_avatar_name" %>
</td>