Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9ed69ca

Browse files
committed
refactor: split prisma schema file
1 parent7fc45b1 commit9ed69ca

File tree

12 files changed

+505
-309
lines changed

12 files changed

+505
-309
lines changed

‎.vscode/settings.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@
124124
"Tyranor",
125125
"unfollow",
126126
"unnest",
127+
"unrs",
127128
"unstorage",
128129
"urlset",
129130
"vercel",

‎package.json‎

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
"@next/mdx":"^15.4.4",
5656
"@nivo/line":"^0.99.0",
5757
"@noble/hashes":"^1.8.0",
58-
"@prisma/client":"^6.12.0",
58+
"@prisma/client":"^6.16.2",
5959
"@tailwindcss/postcss":"^4.1.11",
6060
"@tanstack/react-query":"^5.83.0",
6161
"@types/mdx":"^2.0.13",
@@ -172,7 +172,7 @@
172172
"postcss-scss":"^4.0.9",
173173
"prettier":"^3.6.2",
174174
"pretty-quick":"^4.2.2",
175-
"prisma":"^6.12.0",
175+
"prisma":"^6.16.2",
176176
"sass":"^1.89.2",
177177
"stylelint":"^16.22.0",
178178
"stylelint-config-html":"^1.1.0",
@@ -182,5 +182,21 @@
182182
"stylelint-order":"^7.0.0",
183183
"tailwindcss":"^4.1.11",
184184
"typescript":"^5.8.3"
185+
},
186+
"pnpm": {
187+
"onlyBuiltDependencies": [
188+
"@heroui/shared-utils",
189+
"@parcel/watcher",
190+
"@prisma/client",
191+
"@prisma/engines",
192+
"@tailwindcss/oxide",
193+
"aws-sdk",
194+
"bcrypt",
195+
"core-js",
196+
"esbuild",
197+
"prisma",
198+
"sharp",
199+
"unrs-resolver"
200+
]
185201
}
186202
}

‎pnpm-lock.yaml‎

Lines changed: 215 additions & 40 deletions
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎prisma.config.ts‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import{defineConfig}from'prisma/config'
2+
import'dotenv/config'
3+
4+
exportdefaultdefineConfig({
5+
earlyAccess:true,
6+
schema:'./prisma/schema',
7+
migrations:{
8+
path:'./prisma/migrations'
9+
}
10+
})

‎prisma/schema.prisma‎

Lines changed: 0 additions & 267 deletions
This file was deleted.

‎prisma/schema/admin.prisma‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
modeladmin_log {
2+
idInt@id@default(autoincrement())
3+
typeString
4+
contentString@db.VarChar(10007)
5+
statusInt@default(0)
6+
7+
user_idInt
8+
useruser@relation(fields:[user_id],references:[id],onDelete:Cascade,onUpdate:NoAction)
9+
10+
createdDateTime@default(now())
11+
updatedDateTime@updatedAt
12+
}

‎prisma/schema/patch-comment.prisma‎

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
modelpatch_comment {
2+
idInt@id@default(autoincrement())
3+
contentString@default("")@db.VarChar(10007)
4+
editString@default("")
5+
6+
like_byuser_patch_comment_like_relation[]
7+
8+
replypatch_comment[]@relation("comment_reply")
9+
parent_idInt?
10+
parentpatch_comment?@relation("comment_reply",fields:[parent_id],references:[id],onDelete:Cascade,onUpdate:NoAction)
11+
user_idInt
12+
useruser@relation("user_patch_comment",fields:[user_id],references:[id],onDelete:Cascade,onUpdate:NoAction)
13+
patch_idInt
14+
patchpatch@relation("patch_comment",fields:[patch_id],references:[id],onDelete:Cascade,onUpdate:NoAction)
15+
16+
createdDateTime@default(now())
17+
updatedDateTime@updatedAt
18+
}
19+
20+
modeluser_patch_comment_like_relation {
21+
idInt@id@default(autoincrement())
22+
23+
user_idInt
24+
useruser@relation(fields:[user_id],references:[id],onDelete:Cascade,onUpdate:NoAction)
25+
comment_idInt
26+
commentpatch_comment@relation(fields:[comment_id],references:[id],onDelete:Cascade,onUpdate:NoAction)
27+
28+
createdDateTime@default(now())
29+
updatedDateTime@updatedAt
30+
31+
@@unique([user_id,comment_id])
32+
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp