a guest May 31st, 2019 76 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- class Engine < ApplicationRecord
- belongs_to :brand
- belongs_to :series
- mount_uploaders :images, EngineImageUploader
- validates :name, :article, :catalog_number, :content, :title, :description, :weight, :power_output, :price, :displacement, :model, :producer, :images, presence:true
- extend FriendlyId
- friendly_id :permalink, use: :slugged
- def should_generate_new_friendly_id?
RAW Paste Data