Sha256: 03589abf8368c87a719ea36694be43872a51c3742fb5f583130e7cfc7a1f9768
Contents?: true
Size: 302 Bytes
Versions: 13
Compression:
Stored size: 302 Bytes
Contents
module Pulitzer module PostTypeElement def self.included(klass) klass.before_save :handle_sort_order end def highest_sibling_sort self.post_type.highest_element_sort end def handle_sort_order self.sort_order ||= self.highest_sibling_sort + 1 end end end
Version data entries
13 entries across 13 versions & 1 rubygems