修改《若用户没有填写姓名或者学号,在列表处姓名学号显示不合理》bug
Signed-off-by: alan <547533434@qq.com>
This commit is contained in:
parent
0b0b6c9b6e
commit
d5100e4808
|
@ -56,24 +56,36 @@
|
||||||
</a>
|
</a>
|
||||||
<ul style="margin-left: 15px">
|
<ul style="margin-left: 15px">
|
||||||
<% if @canShowCode %>
|
<% if @canShowCode %>
|
||||||
<li>
|
<% if member.user.show_name == '' && member.user.user_extensions.student_id == '' %>
|
||||||
<%= l(:label_bidding_user_studentname) %> :
|
<li>
|
||||||
<%= link_to member.user.show_name, user_path(member.user) %>
|
<%= l(:label_username)%>
|
||||||
</li>
|
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||||
</br>
|
</li>
|
||||||
|
<% else %>
|
||||||
|
<% unless member.user.show_name == ''%>
|
||||||
|
<li>
|
||||||
|
<%= l(:label_bidding_user_studentname) %> :
|
||||||
|
<%= link_to member.user.show_name, user_path(member.user) %>
|
||||||
|
</li>
|
||||||
|
</br>
|
||||||
|
<% end %>
|
||||||
|
<% unless member.user.user_extensions.student_id == '' %>
|
||||||
|
<li>
|
||||||
|
<%= l(:label_bidding_user_studentcode) %> :
|
||||||
|
<%= link_to member.user.user_extensions.student_id, user_path(member.user) %>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
<%#= content_tag "li", "#{l(:label_bidding_user_studentname)}#{' : '}"link_to(member.user.show_name, user_path(member.user)) %>
|
<%#= content_tag "li", "#{l(:label_bidding_user_studentname)}#{' : '}"link_to(member.user.show_name, user_path(member.user)) %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= content_tag "li", link_to(member.user.name, user_path(member.user)) %>
|
<li>
|
||||||
<% end %>
|
<%= l(:label_username)%>
|
||||||
|
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
<!--teacher's code disapeared moified by huang-->
|
<!--teacher's code disapeared moified by huang-->
|
||||||
|
|
||||||
<% if @canShowCode %>
|
|
||||||
<li>
|
|
||||||
<%= l(:label_bidding_user_studentcode) %> :
|
|
||||||
<%= link_to member.user.user_extensions.student_id, user_path(member.user) %>
|
|
||||||
</li>
|
|
||||||
<%#= content_tag "li", "#{l(:label_bidding_user_studentcode)}#{' : '}#{member.user.user_extensions.student_id}", :style=> "color:#1c9ec7;" %>
|
|
||||||
<% end %>
|
|
||||||
</ul>
|
</ul>
|
||||||
<% if @subPage_title == l(:label_student_list) %>
|
<% if @subPage_title == l(:label_student_list) %>
|
||||||
<%= link_to format("%0.2f",member.score.nil? ? 0 : member.score.to_s), {
|
<%= link_to format("%0.2f",member.score.nil? ? 0 : member.score.to_s), {
|
||||||
|
|
|
@ -7,24 +7,36 @@
|
||||||
<a href="#" class="st_img" style="float:left;"> <%= member.user.nil? ? '' : (image_tag(url_to_avatar(member.user), :width => 40, :height => 40)) %></a>
|
<a href="#" class="st_img" style="float:left;"> <%= member.user.nil? ? '' : (image_tag(url_to_avatar(member.user), :width => 40, :height => 40)) %></a>
|
||||||
<ul style="margin-left: 15px">
|
<ul style="margin-left: 15px">
|
||||||
<% if @canShowCode %>
|
<% if @canShowCode %>
|
||||||
<li>
|
<% if member.user.show_name == '' && member.user.user_extensions.student_id == '' %>
|
||||||
<%= l(:label_bidding_user_studentname) %> :
|
<li>
|
||||||
<%= link_to member.user.show_name, user_path(member.user) %>
|
<%= l(:label_username)%>
|
||||||
|
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||||
</li> </br>
|
</li>
|
||||||
|
<% else %>
|
||||||
|
<% unless member.user.show_name == ''%>
|
||||||
|
<li>
|
||||||
|
<%= l(:label_bidding_user_studentname) %> :
|
||||||
|
<%= link_to member.user.show_name, user_path(member.user) %>
|
||||||
|
</li>
|
||||||
|
</br>
|
||||||
|
<% end %>
|
||||||
|
<% unless member.user.user_extensions.student_id == '' %>
|
||||||
|
<li>
|
||||||
|
<%= l(:label_bidding_user_studentcode) %> :
|
||||||
|
<%= link_to member.user.user_extensions.student_id, user_path(member.user) %>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
<%#= content_tag "li", "#{l(:label_bidding_user_studentname)}#{' : '}"link_to(member.user.show_name, user_path(member.user)) %>
|
<%#= content_tag "li", "#{l(:label_bidding_user_studentname)}#{' : '}"link_to(member.user.show_name, user_path(member.user)) %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= content_tag "li", link_to(member.user.name, user_path(member.user)) %>
|
<li>
|
||||||
|
<%= l(:label_username)%>
|
||||||
|
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||||
|
</li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<!--teacher's code disapeared moified by huang-->
|
<!--teacher's code disapeared moified by huang-->
|
||||||
|
|
||||||
<% if @canShowCode %>
|
|
||||||
<li>
|
|
||||||
<%= l(:label_bidding_user_studentcode) %> :
|
|
||||||
<%= link_to member.user.user_extensions.student_id, user_path(member.user) %>
|
|
||||||
</li>
|
|
||||||
<%#= content_tag "li", "#{l(:label_bidding_user_studentcode)}#{' : '}#{member.user.user_extensions.student_id}", :style=> "color:#1c9ec7;" %>
|
|
||||||
<% end %>
|
|
||||||
</ul>
|
</ul>
|
||||||
<% if @subPage_title == l(:label_student_list) %>
|
<% if @subPage_title == l(:label_student_list) %>
|
||||||
<%= link_to format("%0.2f",member.score.to_s), {
|
<%= link_to format("%0.2f",member.score.to_s), {
|
||||||
|
|
Loading…
Reference in New Issue