MorningPeak/db/migrate/20150617094127_create_tickets.rb
Arthur Poulet b865a60bea Ticket is ready
- Ticket in user/admin sides ok (respond tested)
- Fix seeds
- Fix models
- Fix all migrations
- Add client_... controllers (bills/tickets)
2015-06-18 00:56:01 +02:00

16 lines
363 B
Ruby

class CreateTickets < ActiveRecord::Migration
def change
create_table :tickets do |t|
t.references :creator, polymorphic: true, index: true
t.belongs_to :ticket, index: true, foreign_key: true
t.string :title
t.text :description
t.string :state, default: "open", null: false
t.timestamps null: false
end
end
end