socialforge/app/models/pull_request.rb

8 lines
335 B
Ruby
Raw Normal View History

class PullRequest < ActiveRecord::Base
# status 1创建 2接受 3重新打开 4关闭
attr_accessible :gpid, :pull_request_id, :user_id, :project_id, :title, :status
validates_uniqueness_of :pull_request_id
has_many :forge_messages, :class_name => 'ForgeMessage', :as => :forge_message, :dependent => :destroy
end