Aplikasi penomoran surat digital yang modern dan fleksibel. Dibangun dengan Next.js, PostgreSQL (Neon), dan shadcn/ui.
- Framework: Next.js 16 (App Router)
- Database: PostgreSQL (Neon)
- ORM: Prisma 7
- Auth: NextAuth v5 (Google OAuth)
- UI: shadcn/ui + Tailwind CSS v4
- Deployment: Vercel
- Login dengan Google
- Template nomor surat fleksibel (bisa diatur sesuka hati)
- Generate nomor surat otomatis berdasarkan template
- Dashboard dengan statistik
- Responsive (mobile-friendly)
- Modern, clean, minimalist UI
Placeholder yang tersedia:
| Placeholder | Deskripsi |
|---|---|
{NUMBER} |
Nomor urut (001, 002, ...) |
{PREFIX} |
Prefix surat (SKL, UND, ...) |
{DIVISION} |
Kode divisi (DWP, HRD, ...) |
{MONTH} |
Bulan romawi (I, II, ..., XII) |
{MONTH_NUM} |
Bulan angka (01-12) |
{YEAR} |
Tahun penuh (2025) |
{YEAR_SHORT} |
Tahun singkat (25) |
{DAY} |
Tanggal (01-31) |
Contoh: {PREFIX}/{NUMBER}/{DIVISION}/{MONTH}/{YEAR} → SKL/001/DWP/V/2025
npm installCopy .env.example ke .env dan isi:
# Database - Neon PostgreSQL
DATABASE_URL="postgresql://user:password@host.neon.tech/dbname?sslmode=require"
# NextAuth
AUTH_SECRET="generate-with: openssl rand -base64 32"
AUTH_URL="http://localhost:3000"
# Google OAuth
AUTH_GOOGLE_ID="your-google-client-id"
AUTH_GOOGLE_SECRET="your-google-client-secret"npx prisma migrate dev --name initnpm run dev- Buka Google Cloud Console
- Buat project baru atau pilih yang sudah ada
- Aktifkan Google+ API
- Buat OAuth 2.0 credentials
- Tambahkan authorized redirect URI:
http://localhost:3000/api/auth/callback/google - Copy Client ID dan Client Secret ke
.env
- Push ke GitHub
- Import project di Vercel
- Tambahkan environment variables
- Deploy
Untuk production, update AUTH_URL ke domain Vercel dan tambahkan redirect URI di Google Cloud Console.