story validation, member link
This commit is contained in:
@ -3,6 +3,9 @@ class Story < ApplicationRecord
|
||||
|
||||
mount_uploader :picture, PictureUploader
|
||||
|
||||
validates :text, length: { maximum: 1000 }
|
||||
validates :header , length: { minimum: 5 }
|
||||
|
||||
def name
|
||||
header
|
||||
end
|
||||
|
Reference in New Issue
Block a user