Sha256: 5aa230beec6bd27fcc0fa033b10bc163212d9c0f16d1c8054cfbdd931e0be232

Contents?: true

Size: 858 Bytes

Versions: 18

Compression:

Stored size: 858 Bytes

Contents

<%= autogenerated_migration_warning %>

class CreateAssignments < ActiveRecord::Migration[5.1]
  def change
    create_table :assignments do |t|
      t.bigint :canvas_assignment_id, null: false
      t.string :title
      t.text :description
      t.datetime :due_at
      t.datetime :unlock_at
      t.datetime :lock_at
      t.float :points_possible
      t.float :min_score
      t.float :max_score
      t.float :mastery_score
      t.string :grading_type
      t.string :submission_types
      t.string :workflow_state
      t.integer :context_id
      t.string :context_type
      t.integer :canvas_assignment_group_id
      t.integer :grading_scheme_id
      t.integer :grading_standard_id

      t.timestamps
    end

    add_index :assignments, :canvas_assignment_id, unique: true
    add_index :assignments, [:context_id, :context_type]
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
canvas_sync-0.9.4 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.9.3 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.9.2 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.9.1 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.9.0 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.8.4 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.8.3 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.8.2 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.8.1 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.8.0 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.7.3 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.7.2 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.7.1 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.7.0 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.6.4 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.6.3 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.6.2 lib/canvas_sync/generators/templates/models/create_assignments.rb
canvas_sync-0.6.1 lib/canvas_sync/generators/templates/models/create_assignments.rb