Sha256: 814cff58a78dd9f3f166c39ea92e5e73d8aec82b216171a29ebf65db9b73a5e3
Contents?: true
Size: 473 Bytes
Versions: 4
Compression:
Stored size: 473 Bytes
Contents
# frozen_string_literal: true module Csvbuilder module Model module Base extend ActiveSupport::Concern included do attr_reader :context, :initialized_at end # @param [Hash] options # @option options [Hash] :context extra data you want to work with the model def initialize(options = {}) @initialized_at = DateTime.now @context = OpenStruct.new(options[:context] || {}) end end end end
Version data entries
4 entries across 4 versions & 1 rubygems