This repository has been archived on 2024-08-27. You can view files and clone it, but cannot push or open issues or pull requests.
redstoner.com/app/models/info.rb
2017-06-18 13:11:36 -04:00

15 lines
194 B
Ruby

class Info < ActiveRecord::Base
self.table_name = "info"
validates_presence_of :title, :content
def to_s
title
end
def to_param
[id, to_s.parameterize].join("-")
end
end