rake db:migrate
This commit is contained in:
parent
29fa624e9d
commit
d832a5eecf
|
@ -156,6 +156,7 @@ class HomeworkAttachController < ApplicationController
|
|||
#获取可选成员列表
|
||||
#homework:作业
|
||||
#users:该作业所有成员
|
||||
#q:模糊匹配的用户的昵称
|
||||
def members_for_homework homework,users,q
|
||||
homework.bid.courses.first.members.joins(:member_roles).where("member_roles.role_id IN (:role_id) and user_id not in (:users)", {:role_id => [5, 10],:users => users}).joins(:user).where("users.login like '%#{q}%'")
|
||||
end
|
||||
|
|
|
@ -49,7 +49,7 @@
|
|||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="padding-left: 40px">平均评分:
|
||||
<td style=" padding-left: 40px">平均评分:
|
||||
<%= rating_for @homework, :static => true, dimension: :quality, class: 'rateable div_inline' %>
|
||||
</td>
|
||||
<td>发布时间:<%=format_time @homework.created_at %></td>
|
||||
|
|
|
@ -924,13 +924,11 @@ ActiveRecord::Schema.define(:version => 20140609061903) do
|
|||
add_index "user_preferences", ["user_id"], :name => "index_user_preferences_on_user_id"
|
||||
|
||||
create_table "user_scores", :force => true do |t|
|
||||
t.integer "user_id", :null => false
|
||||
t.integer "user_id"
|
||||
t.integer "collaboration"
|
||||
t.integer "influence"
|
||||
t.integer "skill"
|
||||
t.integer "active"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.integer "activity"
|
||||
end
|
||||
|
||||
create_table "user_statuses", :force => true do |t|
|
||||
|
|
Loading…
Reference in New Issue