Initial commit - you can create, edit and delete a blog post and it respects the fact that it is draft or not.
This commit is contained in:
parent
9a8b95e9aa
commit
837ea01a34
21 changed files with 370 additions and 0 deletions
8
app/models/blog_comment.rb
Normal file
8
app/models/blog_comment.rb
Normal file
|
@ -0,0 +1,8 @@
|
|||
class BlogPost < ActiveRecord::Base
|
||||
|
||||
acts_as_indexed :fields => [:name, :email, :body]
|
||||
|
||||
validates_presence_of :title
|
||||
validates_uniqueness_of :title
|
||||
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue