Initial implementation of projects, tasks and their basic actions #1

Open
KaungKaung wants to merge 24 commits from development into main
8 changed files with 53 additions and 0 deletions
Showing only changes of commit de19e675c8 - Show all commits

2
app/models/project.rb Normal file
View File

@@ -0,0 +1,2 @@
class Project < ApplicationRecord
end

2
app/models/task.rb Normal file
View File

@@ -0,0 +1,2 @@
class Task < ApplicationRecord
end

View File

@@ -0,0 +1,9 @@
class CreateProjects < ActiveRecord::Migration[8.1]
def change
create_table :projects do |t|
t.string :project_name
t.timestamps
end
end
end

View File

@@ -0,0 +1,10 @@
class CreateTasks < ActiveRecord::Migration[8.1]
def change
create_table :tasks do |t|
t.string :title
t.string :status
t.timestamps
end
end
end

7
test/fixtures/projects.yml vendored Normal file
View File

@@ -0,0 +1,7 @@
# Read about fixtures at https://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
one:
project_name: MyString
two:
project_name: MyString

9
test/fixtures/tasks.yml vendored Normal file
View File

@@ -0,0 +1,9 @@
# Read about fixtures at https://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
one:
title: MyString
status: MyString
two:
title: MyString
status: MyString

View File

@@ -0,0 +1,7 @@
require "test_helper"
class ProjectTest < ActiveSupport::TestCase
# test "the truth" do
# assert true
# end
end

7
test/models/task_test.rb Normal file
View File

@@ -0,0 +1,7 @@
require "test_helper"
class TaskTest < ActiveSupport::TestCase
# test "the truth" do
# assert true
# end
end