feat: implement initial fullstack portfolio application including dashboard, CMS, and analytics features.

This commit is contained in:
Moh Dzulfikri Maulana
2026-03-07 16:32:49 +07:00
commit bdd61d11d3
59 changed files with 11107 additions and 0 deletions

107
prisma/schema.prisma Normal file
View File

@@ -0,0 +1,107 @@
generator client {
provider = "prisma-client-js"
}
datasource db {
provider = "postgresql"
}
model User {
id String @id @default(cuid())
email String @unique
name String
password String
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
}
model Session {
id String @id @default(cuid())
visitorId String
startedAt DateTime @default(now())
lastSeenAt DateTime @updatedAt
pageViews PageView[]
}
model PageView {
id String @id @default(cuid())
sessionId String
path String
createdAt DateTime @default(now())
session Session @relation(fields: [sessionId], references: [id])
}
model Project {
id String @id @default(cuid())
title String
description String
imageUrl String?
liveUrl String?
githubUrl String?
techStack String[] // Array of tech names
featured Boolean @default(false)
order Int @default(0)
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
}
model Experience {
id String @id @default(cuid())
company String
role String
startDate DateTime
endDate DateTime?
current Boolean @default(false)
description String
highlights String[]
techStack String[]
order Int @default(0)
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
}
model ContactMessage {
id String @id @default(cuid())
name String
email String
subject String
message String
read Boolean @default(false)
createdAt DateTime @default(now())
}
enum BlogStatus {
DRAFT
SCHEDULED
PUBLISHED
}
model Blog {
id String @id @default(cuid())
title String
slug String @unique
content String
excerpt String?
status BlogStatus @default(DRAFT)
scheduledAt DateTime?
publishedAt DateTime?
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
tags Tag[]
@@index([status])
@@index([scheduledAt])
}
model Tag {
id String @id @default(cuid())
name String @unique
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
blogs Blog[]
}