Sha256: 5d847009436623e9f8ad24e1c1da9d150b3e99034bdee9fb0a1584f880b5aee7

Contents?: true

Size: 176 Bytes

Versions: 5

Compression:

Stored size: 176 Bytes

Contents

class Account
	include Mongoid::Document
	field :period, :type => TimeSpan

  def self.create_it! duration
    s = self.new
    s.period = {duration: duration}
    s
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
timespan-0.2.8 spec/timespan/mongoid/account.rb
timespan-0.2.7 spec/timespan/mongoid/account.rb
timespan-0.2.6 spec/timespan/mongoid/account.rb
timespan-0.2.5 spec/timespan/mongoid/account.rb
timespan-0.2.4 spec/timespan/mongoid/account.rb