Commit Graph

15 Commits

Author SHA1 Message Date
2c5fa52608 tasks/noc-integration/update-village-id-to-desa1-and-fix-sync-logic/20260330-1522 2026-03-30 15:27:12 +08:00
65844bac7e feat(noc): implement sync management UI and backend integration 2026-03-30 14:48:47 +08:00
ed93363de1 feat: enhance complaint seeder with 12 complaints across 7 months
Complaint Data Enhancement:
- Increased from 3 complaints to 12 complaints
- Spread across 7 months (Sep 2025 - Mar 2026)
- Each month has 1-2 complaints for meaningful trend data
- Added variety in categories: INFRASTRUKTUR, KETERTIBAN_UMUM, ADMINISTRASI
- Added variety in priorities: RENDAH, SEDANG, TINGGI, DARURAT
- All complaints have realistic createdAt dates

Expected Trend Chart Data:
- Sep 2025: 1 complaint
- Oct 2025: 1 complaint
- Nov 2025: 1 complaint
- Dec 2025: 2 complaints
- Jan 2026: 2 complaints
- Feb 2026: 2 complaints
- Mar 2026: 3 complaints

Files changed:
- prisma/seeders/seed-public-services.ts: Enhanced seedComplaints()

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-27 16:33:59 +08:00
c6951dec80 fix: add sample data for dashboard stats (weekly service & completed complaints)
- Added 1 service letter with createdAt 5 days ago (within current week)
  → SKT-2025-001 (KTP) now shows in 'Surat Minggu Ini' stat
- Added 1 complaint with status SELESAI
  → COMP-20250320-003 shows in 'Layanan Selesai' stat

Dashboard stats now display:
- Surat Minggu Ini: 1 (was 0)
- Layanan Selesai: 1 (was 0)
- Pengaduan Aktif: 2 (BARU + DIPROSES)
- Total Penduduk: from resident stats

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-27 14:42:09 +08:00
8da53127c7 feat: add duplicate prevention to seed - skip if data already exists
- Added hasExistingData() function to check for existing seed data
- Checks core entities: users (>1), banjars (>=6), divisions (>=4)
- runSeed() now skips entirely if data exists
- runSpecificSeeder() skips non-auth seeders if data exists
- Provides helpful message with reset instructions
- Prevents accidental duplicate data on re-run

Usage:
- bun run seed - Will skip if data exists
- bun x prisma migrate reset - Reset database before re-seeding

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-27 14:36:46 +08:00
354e706dc5 fix: update service letter seed with realistic dates for chart trends
- Added 5 service letters with createdAt dates spread across 6 months
- Changed from upsert to update/create pattern to allow createdAt modification
- This ensures chart-surat.tsx displays proper trend data
- Previous data had all timestamps at seed time, causing empty 6-month trend

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-27 14:34:49 +08:00
c216fa074d [darmasaba-dashboard][2026-03-27] feat: complete all seeders and update Phase 2 schema
Schema Updates:
- Added fields to Umkm model (name, owner, productType, description, timestamps)
- Added fields to Posyandu model (name, location, schedule, type, timestamps)
- Added fields to SecurityReport model (reportNumber, title, description, location, reportedBy, status, timestamps)
- Added fields to EmploymentRecord model (companyName, position, startDate, endDate, isActive, timestamps)
- Added fields to PopulationDynamic model (type, residentName, eventDate, description, timestamps)
- Added fields to BudgetTransaction model (transactionNumber, type, category, amount, description, date, timestamps)
- Added fields to HealthRecord model (type, notes, timestamps)

New Seeders:
- seed-discussions.ts: Documents, Discussions, DivisionMetrics
- seed-phase2.ts: UMKM, Posyandu, SecurityReports, EmploymentRecords, PopulationDynamics, BudgetTransactions

Enhanced Seeders:
- seed-auth.ts: Added seedApiKeys() function
- seed-public-services.ts: Added seedComplaintUpdates() and getComplaintIds()

New NPM Scripts:
- seed:documents - Seed documents and discussions
- seed:phase2 - Seed Phase 2+ features

All 33 Prisma models now have seeder coverage (82% direct, 12% stubs, 6% auto-managed)

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-27 14:05:15 +08:00
44b6b158ef [darmasaba-dashboard][2026-03-27] feat: modular seeders and database-backed dashboard
- Split seeders into modular files per feature category
- Added seed:auth, seed:demographics, seed:divisions, seed:services, seed:dashboard commands
- Connected dashboard components to live database (Budget, SDGs, Satisfaction)
- Added API endpoints: /api/dashboard/budget, /api/dashboard/sdgs, /api/dashboard/satisfaction
- Updated prisma schema with dashboard metrics models
- Added loading states to dashboard components
- Fixed header navigation to /admin

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-27 12:14:19 +08:00
0d0dc187a5 chore: fix linting and type safety across the project 2026-03-26 15:51:45 +08:00
aeedb17402 fix(header): fix missing Divider, Badge, IconUserShield and navigate 2026-03-26 14:13:59 +08:00
1ec10fe623 Fix seed-2 2026-02-26 16:30:22 +08:00
5801eb4596 feat: improve header responsiveness and update seed initialization
- Add text truncation for title on mobile screens
- Hide user info section on mobile, show simplified icons only
- Update seed.ts to create admin and demo users with proper password hashing
- Add bcryptjs for password hashing in seed script
- Update QWEN.md documentation with seed command and default users

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-19 10:14:21 +08:00
48cf6c44f5 feat: Integrate new dashboard design and components, remove old dashboard routes, and update dependencies. 2026-02-10 15:00:11 +08:00
bipproduction
718e7603d1 feat: improve profile UI/UX and migrate to Mantine modals 2026-02-07 15:05:28 +08:00
bipproduction
b9abcaadde Initial commit: Setup Bun, Elysia, Vite, React, TanStack Router, Mantine, and Biome 2026-02-07 02:15:29 +08:00