Added enum to Task model. Added project to project to tasks. Changed Status data type in Tasks.

This commit is contained in:
KaungKaung
2026-01-26 21:50:14 +06:30
parent 6bbbc67a3c
commit f72af5d45f
6 changed files with 25 additions and 3 deletions

View File

@@ -0,0 +1,6 @@
class ChangeStatusTypeInTasks < ActiveRecord::Migration[8.1]
def change
remove_column :tasks, :status, :string
add_column :tasks, :status, :integer, default: 0, null: false
end
end

View File

@@ -0,0 +1,5 @@
class AddProjectToTasks < ActiveRecord::Migration[8.1]
def change
add_reference :tasks, :project, null: false, foreign_key: true
end
end