annotate .svn/pristine/4a/4a0b59f652c0c5306fec4e23a9b966da98c95f60.svn-base @ 1327:287f201c2802 redmine-2.2-integration

Add italic
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Wed, 19 Jun 2013 20:56:22 +0100
parents cbb26bc654de
children
rev   line source
Chris@909 1 class CreateTimeEntries < ActiveRecord::Migration
Chris@909 2 def self.up
Chris@909 3 create_table :time_entries do |t|
Chris@909 4 t.column :project_id, :integer, :null => false
Chris@909 5 t.column :user_id, :integer, :null => false
Chris@909 6 t.column :issue_id, :integer
Chris@909 7 t.column :hours, :float, :null => false
Chris@909 8 t.column :comments, :string, :limit => 255
Chris@909 9 t.column :activity_id, :integer, :null => false
Chris@909 10 t.column :spent_on, :date, :null => false
Chris@909 11 t.column :tyear, :integer, :null => false
Chris@909 12 t.column :tmonth, :integer, :null => false
Chris@909 13 t.column :tweek, :integer, :null => false
Chris@909 14 t.column :created_on, :datetime, :null => false
Chris@909 15 t.column :updated_on, :datetime, :null => false
Chris@909 16 end
Chris@909 17 add_index :time_entries, [:project_id], :name => :time_entries_project_id
Chris@909 18 add_index :time_entries, [:issue_id], :name => :time_entries_issue_id
Chris@909 19 end
Chris@909 20
Chris@909 21 def self.down
Chris@909 22 drop_table :time_entries
Chris@909 23 end
Chris@909 24 end