Sha256: 16dcce0ef29b0fc50f72c7cfe95b383bb19639f845875328614cd2c174838f06

Contents?: true

Size: 925 Bytes

Versions: 16

Compression:

Stored size: 925 Bytes

Contents

require 'ostruct'

class Antecedent

  def initialize(attributes={})
    @ticket = attributes.fetch(:ticket, Ticket.first)
    @reporter = attributes.fetch(:reporter, User.first)
    @created_at = attributes.fetch(:created_at, 1.week.ago)
    @customer = attributes.fetch(:customer, OpenStruct.new(name: "Humphrey Blaughfellow"))
    @notes = attributes.fetch(:notes, "Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo volupt")
  end

  attr_reader :ticket, :reporter, :created_at, :customer, :notes

end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
houston-core-0.7.0 app/models/antecedent.rb
houston-core-0.7.0.beta4 app/models/antecedent.rb
houston-core-0.7.0.beta3 app/models/antecedent.rb
houston-core-0.7.0.beta2 app/models/antecedent.rb
houston-core-0.7.0.beta app/models/antecedent.rb
houston-core-0.6.3 app/models/antecedent.rb
houston-core-0.6.2 app/models/antecedent.rb
houston-core-0.6.1 app/models/antecedent.rb
houston-core-0.6.0 app/models/antecedent.rb
houston-core-0.5.6 app/models/antecedent.rb
houston-core-0.5.5 app/models/antecedent.rb
houston-core-0.5.4 app/models/antecedent.rb
houston-core-0.5.3 app/models/antecedent.rb
houston-core-0.5.2 app/models/antecedent.rb
houston-core-0.5.1 app/models/antecedent.rb
houston-core-0.5.0 app/models/antecedent.rb