parent
1744102a5b
commit
d1e6770428
@ -1,6 +1,7 @@
|
||||
class HackUserCode < ApplicationRecord
|
||||
# 用户编程题的信息
|
||||
belongs_to :hack
|
||||
belongs_to :hack_user_lastest_code
|
||||
|
||||
scope :created_order, ->{ order("created_at desc")}
|
||||
end
|
||||
|
@ -1,4 +1,8 @@
|
||||
json.(@hack_user, :id, :status, :error_line, :error_msg, :expected_output,
|
||||
:input, :output, :execute_time, :execute_memory, :created_at, :code)
|
||||
json.language @hack_user.hack.language
|
||||
json.name @hack_user.hack.name
|
||||
json.name @hack_user.hack.name
|
||||
json.myproblem_identifier @my_hack.identifier
|
||||
json.user do
|
||||
json.partial! 'users/user', user: current_user
|
||||
end
|
Loading…
Reference in new issue