Skip to content

Commit

Permalink
chore: new migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
hebertzin committed Mar 26, 2024
1 parent e57a138 commit 05b4777
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 28 deletions.
28 changes: 0 additions & 28 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,31 +23,3 @@ jobs:
cache: 'npm'
- run: npm ci
- run: npm install

check-dependencies:
runs-on: ubuntu-latest

steps:
- name: Check for outdated dependencies
uses: actions/setup-node@v3
with:
node-version: '16.x'
cache: 'npm'
- name: Install dependencies
run: npm install
- name: Check for outdated dependencies
run: npm outdated

update-dependencies:
runs-on: ubuntu-latest

steps:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '16.x'
cache: 'npm'
- name: Install dependencies
run: npm install
- name: Update dependencies
run: npm update
20 changes: 20 additions & 0 deletions prisma/migrations/20240326195733_new_tables/migration.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
-- CreateTable
CREATE TABLE "TaskListProject" (
"id" TEXT NOT NULL,
"title" TEXT NOT NULL,
"description" TEXT NOT NULL,
"priority" "Priority" NOT NULL,
"userId" TEXT NOT NULL,
"projectId" TEXT NOT NULL,
"createAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
"updateAt" TIMESTAMP(3) NOT NULL
);

-- CreateIndex
CREATE UNIQUE INDEX "TaskListProject_id_key" ON "TaskListProject"("id");

-- AddForeignKey
ALTER TABLE "TaskListProject" ADD CONSTRAINT "TaskListProject_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE RESTRICT ON UPDATE CASCADE;

-- AddForeignKey
ALTER TABLE "TaskListProject" ADD CONSTRAINT "TaskListProject_projectId_fkey" FOREIGN KEY ("projectId") REFERENCES "Projects"("id") ON DELETE RESTRICT ON UPDATE CASCADE;

0 comments on commit 05b4777

Please sign in to comment.