Sha256: 5e3c49a657ec808bd28018b5065479a7ac16db6ce51cbff0b43009138ad47035
Contents?: true
Size: 229 Bytes
Versions: 2
Compression:
Stored size: 229 Bytes
Contents
class Post < ActiveRecord::Base validates :title, presence: true, length: {within: 20..50}, numericality: {greater_than_or_equal_to: 20} validates :title, format: { with: /\A[a-zA-Z]+\z/, message: "only allows letters" } end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
bootstrap_validator_rails-0.4.1 | test/dummy/app/models/post.rb |
bootstrap_validator_rails-0.4.0 | test/dummy/app/models/post.rb |