Ramble
가치 있는 활동을 위한 마켓플레이스
저장소 정보는 아직 수집하지 않았습니다.
아직 감지된 업데이트가 없습니다. GitHub 릴리스가 나오면 여기에 보입니다.
메이커가 쓴 소개는 위의 한 줄이 전부입니다. 더 자세한 내용은 저장소 README에서 읽을 수 있습니다. 저장소 README ↗
README 전체를 불러오는 중입니다.
README 전문 보기 ↗Starter backend for the sales app. The data model (users, customers, products, orders) is a first draft and will be updated to match the Base44 app.
winget is built into Windows 10/11.
# Node.js (LTS) - includes npm and npx
winget install --id OpenJS.NodeJS.LTS -e
# Git (recommended)
winget install --id Git.Git -e
# PostgreSQL 17 (the installer asks you to choose a password for the "postgres" user - remember it)
winget install --id PostgreSQL.PostgreSQL.17 -e
Close and reopen the terminal, then check:
node -v
npm -v
psql --version
If psql isn't found, add it to PATH (adjust version number if different):
setx PATH "$env:PATH;C:\Program Files\PostgreSQL\17\bin"
psql -U postgres
Then inside psql:
CREATE USER sales WITH PASSWORD 'sales_password';
CREATE DATABASE sales_app OWNER sales;
ALTER USER sales CREATEDB; -- needed by Prisma for migrations (shadow DB)
\q
Alternative — Postgres via Docker (instead of installing it):
winget install --id Docker.DockerDesktop -e
# after Docker Desktop is running:
docker compose up -d
Prisma is installed per project (no global install needed). It's already listed
in package.json, so npm install gets it. If you ever start a new project:
npm install prisma --save-dev
npm install @prisma/client
npx prisma init --datasource-provider postgresql
NestJS CLI (optional, useful for generating new modules):
npm install -g @nestjs/cli
cd $HOME\Documents\sales-app
copy .env.example .env # then edit DATABASE_URL if needed
npm install
npx prisma generate
npx prisma migrate dev --name init
npx prisma db seed
npm run start:dev
Or run everything at once: powershell -ExecutionPolicy Bypass -File .\setup.ps1
Open http://localhost:3000/api/health — you should see {"status":"ok","db":"up"}.
Browse/edit data visually: npx prisma studio
/api)| Method | Path | Description |
|---|---|---|
| GET | /health | API + DB check |
| GET/POST | /customers | List (?search=) / create |
| GET/PATCH/DELETE | /customers/:id | Read / update / delete |
| GET/POST | /products | List / create |
| GET/PATCH/DELETE | /products/:id | Read / update / deactivate |
| GET/POST | /orders | List / create (totals computed server-side) |
| GET | /orders/:id | Order with items |
| PATCH | /orders/:id/status | Change status |
Example order body:
{ "customerId": "<id>", "items": [{ "productId": "<id>", "quantity": 2 }] }
prisma/schema.prisma database models
prisma/seed.ts demo data
src/main.ts app entry (CORS, validation, /api prefix)
src/prisma/ PrismaService (DB connection)
src/customers|products|orders/ feature modules
docker-compose.yml optional local Postgres
Production start: npm run build → npx prisma migrate deploy → npm run start:prod.
Set DATABASE_URL, PORT, CORS_ORIGIN as environment variables on the host.