帖子内容可以为空

This commit is contained in:
yanxd 2014-03-14 21:25:59 +08:00
parent b5215e95e0
commit af3b32fa89
1 changed files with 1 additions and 1 deletions

View File

@ -4,7 +4,7 @@ class Memo < ActiveRecord::Base
belongs_to :author, :class_name => "User", :foreign_key => 'author_id'
validates_presence_of :author_id, :forum_id, :subject
validates :content, presence: true
#validates :content, presence: true
validates_length_of :subject, maximum: 50
#validates_length_of :content, maximum: 3072
validate :cannot_reply_to_locked_topic, :on => :create