fix: use pgEnum for steamReviewSentiment
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
CREATE TYPE "public"."steam_review_sentiment" AS ENUM('overwhelmingly_positive', 'very_positive', 'positive', 'mostly_positive', 'mixed', 'mostly_negative', 'negative', 'very_negative', 'overwhelmingly_negative');--> statement-breakpoint
|
||||
ALTER TABLE "games" ALTER COLUMN "steam_review_sentiment" SET DATA TYPE "public"."steam_review_sentiment" USING "steam_review_sentiment"::"public"."steam_review_sentiment";
|
||||
File diff suppressed because it is too large
Load Diff
@@ -113,6 +113,13 @@
|
||||
"when": 1777545844610,
|
||||
"tag": "0015_nappy_the_phantom",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 16,
|
||||
"version": "7",
|
||||
"when": 1777546237462,
|
||||
"tag": "0016_zippy_eternals",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
+13
-1
@@ -21,6 +21,18 @@ export const onlineMultiplayerStatusEnum = pgEnum(
|
||||
["none", "supported", "unknown"],
|
||||
)
|
||||
|
||||
export const steamReviewSentimentEnum = pgEnum("steam_review_sentiment", [
|
||||
"overwhelmingly_positive",
|
||||
"very_positive",
|
||||
"positive",
|
||||
"mostly_positive",
|
||||
"mixed",
|
||||
"mostly_negative",
|
||||
"negative",
|
||||
"very_negative",
|
||||
"overwhelmingly_negative",
|
||||
])
|
||||
|
||||
export const games = pgTable(
|
||||
"games",
|
||||
{
|
||||
@@ -50,7 +62,7 @@ export const games = pgTable(
|
||||
metacriticUrl: text("metacritic_url"),
|
||||
recommendationsTotal: integer("recommendations_total"),
|
||||
steamReviewScore: integer("steam_review_score"), // 0-100 normalized score
|
||||
steamReviewSentiment: text("steam_review_sentiment"), // "Overwhelmingly Positive", etc.
|
||||
steamReviewSentiment: steamReviewSentimentEnum("steam_review_sentiment"),
|
||||
steamReviewCount: integer("steam_review_count"), // Total review count from Steam
|
||||
priceCurrent: integer("price_current"),
|
||||
priceInitial: integer("price_initial"),
|
||||
|
||||
@@ -24,6 +24,16 @@ const nextConfig: NextConfig = {
|
||||
{
|
||||
protocol: "https",
|
||||
hostname: "cdn2.steamgriddb.com",
|
||||
},
|
||||
// Google
|
||||
{
|
||||
protocol: 'https',
|
||||
hostname: 'lh3.googleusercontent.com'
|
||||
},
|
||||
// Discord
|
||||
{
|
||||
protocol: 'https',
|
||||
hostname: 'cdn.discordapp.com'
|
||||
}
|
||||
],
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user