mirror of
https://github.com/internetee/registry.git
synced 2025-06-06 04:37:30 +02:00
whois migration files
This commit is contained in:
parent
4d420664f6
commit
20ecd289a0
5 changed files with 125 additions and 1 deletions
21
db/migrate/20180515105348_add_contact_requests_table.rb
Normal file
21
db/migrate/20180515105348_add_contact_requests_table.rb
Normal file
|
@ -0,0 +1,21 @@
|
|||
class AddContactRequestsTable < ActiveRecord::Migration[5.0]
|
||||
def change
|
||||
# create_table :contact_requests do |t|
|
||||
# t.integer :whois_record_id, null: false
|
||||
# t.string :secret, null: false
|
||||
# t.string :email, null: false
|
||||
# t.string :name, null: false
|
||||
# t.datetime :valid_to, null: false
|
||||
# t.string :status, null: false, default: 'new'
|
||||
# t.inet :ip_address
|
||||
|
||||
# t.timestamps null: false
|
||||
# end
|
||||
|
||||
# add_foreign_key :contact_requests, :whois_records
|
||||
# add_index :contact_requests, :secret, unique: true
|
||||
# add_index :contact_requests, :email
|
||||
# add_index :contact_requests, :ip_address
|
||||
# add_index :contact_requests, :whois_record_id
|
||||
end
|
||||
end
|
|
@ -0,0 +1,5 @@
|
|||
class RemoveForeignKeyConstraintFromContactRequest < ActiveRecord::Migration[5.0]
|
||||
def change
|
||||
# remove_foreign_key :contact_requests, :whois_records
|
||||
end
|
||||
end
|
9
db/migrate/20181102124618_remove_whois_records_body.rb
Normal file
9
db/migrate/20181102124618_remove_whois_records_body.rb
Normal file
|
@ -0,0 +1,9 @@
|
|||
class RemoveWhoisRecordsBody < ActiveRecord::Migration[5.2]
|
||||
def up
|
||||
# remove_column :whois_records, :body
|
||||
end
|
||||
|
||||
def down
|
||||
# add_column :whois_records, :body, :text
|
||||
end
|
||||
end
|
|
@ -0,0 +1,5 @@
|
|||
class AddMessageIdToContactRequest < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
# add_column :contact_requests, :message_id, :string
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue