Sha256: 06ec146fb2cb6d08608a4304c5bc7a739ca13a2782f4459e53364aa8859ae307
Contents?: true
Size: 595 Bytes
Versions: 72
Compression:
Stored size: 595 Bytes
Contents
module Kuhsaft class PublishState extend ActiveModel::Translation UNPUBLISHED = 0 PUBLISHED = 1 PUBLISHED_AT = 2 attr_reader :name attr_reader :value def initialize options options.each_pair { |k,v| instance_variable_set("@#{k}", v) if respond_to?(k) } end def self.all @all ||= [ PublishState.new(:name => 'published', :value => PUBLISHED), PublishState.new(:name => 'unpublished', :value => UNPUBLISHED), PublishState.new(:name => 'published_at', :value => PUBLISHED_AT) ] end end end
Version data entries
72 entries across 72 versions & 1 rubygems