Sha256: f36e1175427147d5efc4b9d3379b7b7e489db2c0f0053248404ce0feac5d0996

Contents?: true

Size: 581 Bytes

Versions: 5

Compression:

Stored size: 581 Bytes

Contents

# To suport "Edit my domain" and "edit my hostgroup" security access control we need
# a mechanism to associate a user with a fact and a criria for thet fact to evaluate against
class CreateUserFacts < ActiveRecord::Migration
  def self.up
    create_table :user_facts do |t|
      t.references :user
      t.references :fact_name
      t.string     :criteria, :limit => 255
      t.string     :operator, :limit => 3, :default => "="
      t.string     :andor,    :limit => 3, :default => "or"
      t.timestamps
    end
  end

  def self.down
    drop_table :user_facts
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
foreman_discovery-1.0.0 test/foreman_app/db/migrate/20100822072954_create_user_facts.rb
foreman_discovery-1.0.0.rc4 test/foreman_app/db/migrate/20100822072954_create_user_facts.rb
foreman_discovery-1.0.0.rc3 test/foreman_app/db/migrate/20100822072954_create_user_facts.rb
foreman_discovery-1.0.0.rc2 test/foreman_app/db/migrate/20100822072954_create_user_facts.rb
foreman_discovery-1.0.0.rc1 test/foreman_app/db/migrate/20100822072954_create_user_facts.rb