9 lines
392 B
Ruby
9 lines
392 B
Ruby
class WebFooterCompany < ActiveRecord::Base
|
|
attr_accessible :logo_size, :name, :url
|
|
validates :name, presence: true, length: { maximum: 500 }
|
|
validates :url, length: { maximum: 500 },
|
|
format: { with: /(http|https):\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:\/~\+#]*[\w\-\@?^=%&\/~\+#])?/,
|
|
message: l(:is_not_url_error)
|
|
}
|
|
end
|