Sha256: 1ad687e1e1db55936f36e9d5f358f177ad2e58893b2521553473ee0512308e1c
Contents?: true
Size: 363 Bytes
Versions: 27
Compression:
Stored size: 363 Bytes
Contents
# frozen_string_literal: true # encoding: utf-8 class Page include Mongoid::Document embedded_in :quiz embeds_many :page_questions embedded_in :book, touch: true embeds_many :notes field :content, :type => String after_initialize do if self[:content] self[:text] = self[:content] self.remove_attribute(:content) end end end
Version data entries
27 entries across 27 versions & 2 rubygems