Sha256: 8a4f74cc8410bb71ec3e8d93ba21afa11721cd67f3f0b425e080ac36ad2a1399

Contents?: true

Size: 938 Bytes

Versions: 53

Compression:

Stored size: 938 Bytes

Contents

class Auth::Workflow::Entity
		
	include Mongoid::Document

	embedded_in :category, :class_name => Auth.configuration.category_class
	
	field :duration, type: Integer

	field :booked, type: Boolean

	## a location id from which this entity is going to depart.
	field :departs_from_location_id, type: String

	## the location categories of the location from which this entity is departing.
	field :location_categories_for_departs_from, type: Array

	## a location id to which this entity is going.
	field :arrives_at_location_id, type: String

	## the location categories of the location to which this entity is going to arrive.
	field :arrives_at_location_categories, type: Array	

	field :arrives_at_location_coordinates, type: Array, default: []

	field :transport_capacity, type: Float

	
	def get_type
		return "default" unless arrives_at_location_id
		return departs_from_location_id.to_s + "_" + arrives_at_location_id.to_s
	end
end

Version data entries

53 entries across 53 versions & 1 rubygems

Version Path
wordjelly-auth-1.6.0 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.9 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.8 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.7 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.6 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.5 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.4 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.3 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.2 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.1 app/models/auth/workflow/entity.rb
wordjelly-auth-1.5.0 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.9 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.8 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.7 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.6 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.5 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.4 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.3 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.2 app/models/auth/workflow/entity.rb
wordjelly-auth-1.4.0 app/models/auth/workflow/entity.rb