Sha256: 5faf4f489cc946dd9d78a783842bb567d8e0f9e8e0586f97ab749f0348c5f188

Contents?: true

Size: 228 Bytes

Versions: 2

Compression:

Stored size: 228 Bytes

Contents

class News < ActiveRecord::Base
  extend FriendlyId
  friendly_id :title, use: :slugged

  mount_uploader :photo, PhotoUploader

  belongs_to :user, class_name: 'Users::Admin'

  validates :title,
            presence: true
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
beerify-0.1.1 app/models/news.rb
beerify-0.1.0 app/models/news.rb