Sha256: d5bf8a59b236f8c98529da0f51b59906fe67475eceb2e2347724b6260d5090f9

Contents?: true

Size: 844 Bytes

Versions: 36

Compression:

Stored size: 844 Bytes

Contents

require "pact_broker/db"

module PactBroker
  module Domain
    class Label < Sequel::Model
      unrestrict_primary_key

      associate(:many_to_one, :pacticipant, :class => "PactBroker::Domain::Pacticipant", :key => :pacticipant_id, :primary_key => :id)

      def <=> other
        name <=> other.name
      end

    end

    Label.plugin :timestamps, update_on_create: true
  end
end

# Table: labels
# Primary Key: (name, pacticipant_id)
# Columns:
#  name           | text                        |
#  pacticipant_id | integer                     |
#  created_at     | timestamp without time zone | NOT NULL
#  updated_at     | timestamp without time zone | NOT NULL
# Indexes:
#  labels_pk | PRIMARY KEY btree (pacticipant_id, name)
# Foreign key constraints:
#  labels_pacticipant_id_fkey | (pacticipant_id) REFERENCES pacticipants(id)

Version data entries

36 entries across 36 versions & 1 rubygems

Version Path
pact_broker-2.106.0 lib/pact_broker/domain/label.rb
pact_broker-2.105.0 lib/pact_broker/domain/label.rb
pact_broker-2.104.0 lib/pact_broker/domain/label.rb
pact_broker-2.103.0 lib/pact_broker/domain/label.rb
pact_broker-2.102.2 lib/pact_broker/domain/label.rb
pact_broker-2.102.1 lib/pact_broker/domain/label.rb
pact_broker-2.102.0 lib/pact_broker/domain/label.rb
pact_broker-2.101.0 lib/pact_broker/domain/label.rb
pact_broker-2.100.0 lib/pact_broker/domain/label.rb
pact_broker-2.99.0 lib/pact_broker/domain/label.rb
pact_broker-2.98.0 lib/pact_broker/domain/label.rb
pact_broker-2.97.0 lib/pact_broker/domain/label.rb
pact_broker-2.96.0 lib/pact_broker/domain/label.rb
pact_broker-2.95.1 lib/pact_broker/domain/label.rb
pact_broker-2.95.0 lib/pact_broker/domain/label.rb
pact_broker-2.94.0 lib/pact_broker/domain/label.rb
pact_broker-2.93.4 lib/pact_broker/domain/label.rb
pact_broker-2.93.3 lib/pact_broker/domain/label.rb
pact_broker-2.93.2 lib/pact_broker/domain/label.rb
pact_broker-2.93.1 lib/pact_broker/domain/label.rb