|
|
|
@ -2,7 +2,7 @@
|
|
|
|
|
class Competition < ActiveRecord::Base
|
|
|
|
|
# status 0:下架, 1:上架
|
|
|
|
|
attr_accessible :end_time, :identifier, :name, :online_time, :start_time, :status, :visits, :competition_lists_count,
|
|
|
|
|
:min_num, :max_num, :enroll_end_time, :sub_title, :published_at, :rate
|
|
|
|
|
:min_num, :max_num, :enroll_end_time, :sub_title, :published_at
|
|
|
|
|
|
|
|
|
|
has_many :competition_modules, :dependent => :destroy
|
|
|
|
|
has_many :competition_stages, :dependent => :destroy
|
|
|
|
|