修复创新竞赛中,竞赛名称过长时,页面显示不协调的BUG #1231

解决方案:当超过指定字符数时以省略号代替
course_group
sw 11 years ago
parent 05f1df1922
commit d159b4324a

@ -138,7 +138,7 @@
<!--tags--> <!--tags-->
<div class="user_fans"> <div class="user_fans">
<div class="user_underline"></div> <div class="user_underline"></div>
<table style="font-family:微软雅黑"> <table style="font-family:'微软雅黑'">
<tr> <tr>
<td><!-- added by william -for tag --> <td><!-- added by william -for tag -->
<%= render :partial => 'tags/tag', :locals => {:obj => @bid, :object_flag => "4"}%> <%= render :partial => 'tags/tag', :locals => {:obj => @bid, :object_flag => "4"}%>

@ -28,28 +28,28 @@
<div id="main" class=""> <div id="main" class="">
<div class="top-content"> <div class="top-content">
<table> <table>
<tr> <tr>
<td class="info_font" style="width: 240px; color: #15bccf"><%=l(:label_contest_innovate_community)%></td> <td class="info_font" style="width: 240px; color: #15bccf"><%=l(:label_contest_innovate_community)%></td>
<td style="width: 430px; color: #15bccf"><strong><%= l(:label_user_location) %> : </strong></td> <td style="width: 430px; color: #15bccf"><strong><%= l(:label_user_location) %> : </strong></td>
<td rowspan="2" width="250px"> <td rowspan="2" width="250px">
<div class="project-search"> <div class="project-search">
<%= form_tag({controller: 'contests', action: 'index'}, method: :get) do %> <%= form_tag({controller: 'contests', action: 'index'}, method: :get) do %>
<%= text_field_tag 'name', params[:name], :size => 20 %> <%= text_field_tag 'name', params[:name], :size => 20 %>
<%= hidden_field_tag 'project_type', params[:project_type] %> <%= hidden_field_tag 'project_type', params[:project_type] %>
<%= submit_tag l(:label_search), :class => "enterprise", :name => nil %> <%= submit_tag l(:label_search), :class => "enterprise", :name => nil %>
<% end %> <% end %>
</div> </div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td style="padding-left: 8px"><%=link_to request.host()+"/contests", :controller=>'contests', :action=>'index' %></td> <td style="padding-left: 8px"><%=link_to request.host()+"/contests", :controller=>'contests', :action=>'index' %></td>
<td ><%=link_to l(:field_homepage), home_path %> > <td><%=link_to l(:field_homepage), home_path %> >
<%=link_to l(:label_contest_innovate), :controller=>'contests', :action=>'index' %> > <%=link_to l(:label_contest_innovate), :controller=>'contests', :action=>'index' %> >
<span><%= link_to @contest.name, show_contest_contest_path(@contest) %></span> <span title="<%= @contest.name%>"><%= link_to h(truncate(@contest.name, length: 20, omission: '...')), show_contest_contest_path(@contest) %></span>
</td> </td>
</tr> </tr>
</table> </table>
</div> </div>
<div id="sidebar"> <div id="sidebar">
@ -65,7 +65,7 @@
<td> <td>
<table> <table>
<tr> <tr>
<td class="info_font" style=" word-wrap: break-word; word-break: break-all"><%= link_to @contest.name, show_contest_contest_path(@contest) %></td> <td class="info_font" title="<%= @contest.name%>"><%= link_to h(truncate(@contest.name, length: 13, omission: '...')), show_contest_contest_path(@contest) %></td>
</tr> </tr>
<% if User.current.login? %> <% if User.current.login? %>
<tr colspan='3'> <tr colspan='3'>
@ -170,7 +170,7 @@
<!--标签--> <!--标签-->
<div class="user_fans"> <div class="user_fans">
<div class="user_underline"></div> <div class="user_underline"></div>
<table style="font-family:微软雅黑"> <table style="font-family:'微软雅黑'">
<tr> <tr>
<td> <td>
<%= render :partial => 'tags/tag', :locals => {:obj => @contest, :object_flag => "7"}%> <%= render :partial => 'tags/tag', :locals => {:obj => @contest, :object_flag => "7"}%>

Loading…
Cancel
Save