Sha256: a379c3287bce3d6443fcf6e3ded694e892ec2069b74cea24368b07ff05361f2b
Contents?: true
Size: 376 Bytes
Versions: 10
Compression:
Stored size: 376 Bytes
Contents
module Kuztuscms class Setting < ActiveRecord::Base validates :value, :presence => true validates :key, :uniqueness => true, :format => { :with => /\A[a-z0-9_-]+\z/, :message => "Only lowercase letters, numbers and dashes allowed"}, :presence => true after_save do Kuztuscms::Settings.clear_cache end end end
Version data entries
10 entries across 10 versions & 1 rubygems