amalia/29-apr-26 #16

Merged
amaliadwiy merged 15 commits from amalia/29-apr-26 into main 2026-04-29 17:40:58 +08:00

15 Commits

Author SHA1 Message Date
83e8becaa3 upd: mcp json 2026-04-29 17:39:43 +08:00
a2c7be7cfa chore: bump version to 0.1.1 2026-04-29 16:38:19 +08:00
f44a8216bf fix: jalankan prisma migrate deploy otomatis jika ada pending migrations
Sebelumnya pipeline dibatalkan saat ada pending migrations.
Sekarang langsung deploy migrations lalu lanjut ke step berikutnya.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 16:26:35 +08:00
7609204a13 feat: tambah deploy pipeline tool di MCP deploy-stg
Tool baru `deploy` menjalankan full pipeline:
1. Cek pending migrations → batalkan jika ada
2. Version bump package.json ke tag baru
3. Commit + push ke build/stg
4. Trigger publish.yml → polling hingga selesai
5. Trigger re-pull.yml → polling hingga selesai
6. Cek version di STG_URL vs local untuk konfirmasi

Env baru: STG_URL (staging app URL), VERSION_PATH (default /api/system/version)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 16:12:22 +08:00
d3a4f97d0e feat: tambah MCP server deploy-stg untuk trigger GitHub workflow
- scripts/mcp-deploy.ts: MCP server dengan 2 tool:
  - publish: trigger publish.yml (build & push image stg)
  - repull: trigger re-pull.yml (redeploy stack di Portainer)
- .mcp.json: registrasi server dengan env GH_TOKEN, STACK_NAME, BASE_URL

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 16:01:16 +08:00
5050835d81 upd: tambah notifikasi success/error saat simpan Settings
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 15:54:38 +08:00
d17b49cf8f upd: gabungkan Settings menjadi 1 form dengan tombol Simpan Semua
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 15:51:51 +08:00
8bcb30a85b feat: tambah API Key Desa Plus ke Settings panel dan proxy
- Tambah kolom API_KEY_DESA_PLUS di CONFIG_DEFINITIONS (ditampilkan sebagai password field)
- Proxy otomatis menyertakan X-API-Key header jika API key sudah dikonfigurasi

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 15:51:09 +08:00
ccc43e0c96 feat: runtime config via DB — ganti VITE_URL_API_DESA_PLUS dengan proxy
- Tambah model AppConfig (key-value) ke schema + migration
- Tambah GET/PUT /api/admin/config (DEVELOPER only)
- Tambah proxy /api/proxy/desa-plus/* yang baca URL dari DB
- Hapus VITE_URL_API_DESA_PLUS dari frontend, ganti semua URL desa-plus ke relative proxy path
- Aktifkan Settings tab di /dev dengan UI untuk set URL_API_DESA_PLUS

URL desa-plus kini bisa diubah via /dev → Settings tanpa rebuild image.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 15:47:21 +08:00
b63117694b feat: add /api/system/version endpoint with changelog
Mengembalikan versi aplikasi, git commit hash, branch aktif, dan 20 commit terakhir untuk memverifikasi apakah staging/production sudah terupdate.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 13:56:23 +08:00
dbbe53584c upd: sync compose.yml and .env.example with all env vars in env.ts
Add missing required vars: API_KEY, MINIO_*, and optional REDIS_URL, BUN_PUBLIC_BASE_URL

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 12:01:44 +08:00
06794524fd feat: block inactive users from login and fix activity log on dev operators
- Block inactive users on email/password login (403)
- Block inactive users on Google OAuth (redirect to account_disabled)
- Auto-logout inactive users on session check (deleteMany sessions)
- Delete sessions when user is deactivated via PATCH /api/operators/:id
- Add account_disabled error message on login page
- Show inactive indicator on users table with reactivate button
- Add createSystemLog calls to /api/admin/users role and activate endpoints

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 11:58:31 +08:00
73aa9729b8 upd: remove Settings menu item from DashboardLayout user menu
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 11:39:13 +08:00
7c5a491ba9 upd: update role management descriptions and add USER role card
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 11:33:39 +08:00
3c6fac1943 feat: redesign /logs page with table UI and date range filter
- Replace timeline view with table layout (Time, Operator, Type, Message)
- Add date range filter using @mantine/dates DatePickerInput
- Add SegmentedControl for log type filter
- Disable App Logs and Settings menu on /dev
- Remove Activity Logs menu from /dev (moved to /logs)
- Add dateFrom/dateTo query params to /api/logs backend
- Import @mantine/dates/styles.css to fix datepicker styling

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-29 11:27:05 +08:00