添加了注释

修改了作业提交显示错误(显示成需求)
This commit is contained in:
huangjingquan 2013-10-14 22:40:34 +08:00
parent 20883b92a5
commit 6e10f16c68
3 changed files with 30 additions and 11 deletions

View File

@ -124,14 +124,28 @@
<td width="30%">
<div class="bid-user-message" style="border-left: 1px solid rgb(225, 225, 225); margin-left: 20px; padding-left: 20px;">
<table width="100%">
<% if @bid.reward_type == 3 %>
<tr>
<td><%= l(:label_bidding_user) %>
<td><%= l(:label_bidding_user_studentcode) %> : <%= @user.user_extensions.student_id %></td>
</tr>
<tr>
<td><%= l(:label_bidding_user_homework) %>
<%= link_to(b_project.user.lastname+b_project.user.firstname, user_path(b_project.user)) %>
</td>
</td>
</tr>
<tr>
<td style=" word-wrap: break-word; word-break: break-all"><%= l(:label_bidding_reason_homewrok) %><%= b_project.description %></td>
</tr>
<% else %>
<tr>
<td><%= l(:label_bidding_user) %>
<%= link_to(b_project.user.lastname+b_project.user.firstname, user_path(b_project.user)) %>
</td>
</tr>
<tr>
<td style=" word-wrap: break-word; word-break: break-all"><%= l(:label_bidding_reason) %><%= b_project.description %></td>
</tr>
</tr>
<% end %>
</table>
</div></td>
</tr>

View File

@ -1,19 +1,24 @@
<!-- fq -->
<%= render_flash_messages %>
<% if @bid.reward_type == 3 %>
<% if @bid.reward_type == 3 %>
<% if User.current.user_extensions.identity == 1 %>
<div class="font_lighter">
<p>贴心小提示:</p>
<P>亲,在这里我们的作业将以项目的形式提交,如果小伙伴们还没有创建项目,请先创建一个项目。项目创建成功后,就可以再
回到这里来提交作业哦~ 这样在作业提交后,老师就可以随时关注你的作业进展啦~祝使用愉快^^</P>
</div>
<% end %>
<table width="1000px" border="0" style="padding-left: 15px">
<td class="font_lighter" style="font-size: 15px;"><%= l(:label_homework_project) %>(<%= @bidding_project.count%>)</td>
<% if User.current.logged? %>
<td class="font_lighter" style="font-size: 15px;"><%= l(:label_homework_project) %>(<%= @bidding_project.count%>)</td>
<td>
<% if User.current.logged? && (!Member.where('user_id = ? and project_id = ?', User.current.id, @bid.courses.first.id).first.nil? && (Member.where('user_id = ? and project_id = ?', User.current.id, @bid.courses.first.id).first.roles&Role.where('id = ? or id = ?', 5, 7)).size >0) %>
<% if User.current.logged? && (!Member.where('user_id = ? and project_id = ?', User.current.id, @bid.courses.first.id).first.nil? && (Member.where('user_id = ? and project_id = ?', User.current.id, @bid.courses.first.id).first.roles&Role.where('id = ? or id = ?', 5, 7)).size >0) %>
<div class='icon icon-add'>
<%= toggle_link l(:label_commit_homework), 'put-bid-form' %>
</div>
<% end %>
</td>
<% end %>
</td>
</table>
<!-- <% @bidding_project.each do |b_project|%>
<table width="90%" border="0" align='center'>
<tr>

View File

@ -62,7 +62,7 @@
</script>
<% if User.current.logged? %>
<!-- 点击我要参加 参加竞标 -->
<!--我要竞标弹出框-->
<div id = 'flash' style="float:left; width: 100%; display: none" ></div>
<div id="put-bid-form" style="display: none">
<%= form_for "bid_for_save", :remote=>true, :url => {:controller => 'bids', :action => 'add'},