jigoong
76398c3de6
feat(apiservice): add edit client/key functionality in API Management page
...
- PATCH /admin/api-keys/clients/{id} — update client name and is_active
- PATCH /admin/api-keys/{id} — update key name and permissions
- Edit Client modal with name field and active/inactive toggle
- Edit Key modal with name field and permissions JSON textarea (pre-filled)
- Fix JS syntax error: use data-* attributes instead of inline JSON in onclick
2026-06-09 00:41:36 +07:00
jigoong
3a5f9e9001
feat: replace SQLAdmin with Keycloak-protected API management page
...
- Disable SQLAdmin basic auth (comment out mount_admin, statics, redirect)
- Add /api-management page (Keycloak admin role required)
- Add admin_api_keys.py: REST endpoints for list/create clients and keys
- Add api_management.html: manage API clients, keys, permissions with copy-once key display
- Update index.html: API Management link -> /api-management
- Update auth middleware: add /api-management and /admin/users to PROTECTED_PATHS
- Add CHANGES-2026-06-04.md dev notes
2026-06-04 18:22:22 +07:00
jigoong
e4d32b86cb
feat: add VOC data endpoint (POST /api/v1/voc-data)
...
- Add VocDataIn schema (date, topic, sub_topic, level, depart_id, dep_name)
- Add RawVocData SQLAlchemy model (rawdata.raw_voc_data, BIGSERIAL PK)
- Add POST /api/v1/voc-data endpoint with voc.data:write permission
- Dual-write to local PostgreSQL + Supabase
- Table auto-created on startup via Base.metadata.create_all()
2026-06-04 18:22:14 +07:00
jigoong
ee473aca8f
fix: finance upload filepath bug and add extra_hosts for keycloak auth flow
...
- fix NameError: filepath undefined in trigger_airflow call (use filepath_stored)
- add extra_hosts ai.sriphat.com:192.168.100.8 for container DNS resolution
(required for KEYCLOAK_SERVER_URL=http://ai.sriphat.com/keycloak/ to work
inside Docker — host nginx on .8:80 routes /keycloak/ to Keycloak container)
2026-05-27 01:28:57 +07:00
jigoong
a587be08bd
feat: MinIO integration — bucket finance, API service upload, Nginx routing
...
- 01-infra/nginx-configs: add MinIO /minio/ and /minio-console/ location blocks
(port 9000 S3 API, port 9001 Console UI, path stripping via rewrite)
- 03-apiservice: integrate MinIO minio-python SDK for file upload
- requirements.txt: add minio==7.2.11
- app/core/config.py: add MINIO_ENDPOINT, ACCESS_KEY, SECRET_KEY, BUCKET_FINANCE, USE_SSL
- app/services/minio_client.py: new — upload_file(), get_presigned_url(), delete_file()
- app/routes/pages.py: replace local /data/uploads/ write with MinIO upload to finance bucket
- docker-compose.yml: pass MinIO env vars to container
- .env.example: document MinIO vars
- 07-minio/.env.example: add MINIO_SVC_ACCESS_KEY/SECRET_KEY section
- 07-minio/README.md: add Python minio SDK and Airflow DAG usage guide
- CLAUDE.md: project context (servers, SSH, paths, service distribution)
- document-obsidiant/: initial Obsidian docs for all services
2026-05-20 17:42:39 +07:00
jigoong
1dba772e62
update configuration docker setup for data platform
2026-05-07 17:57:42 +07:00
jigoong
550d926139
fix bug merge missing route and supabase-client
2026-02-27 17:24:20 +07:00
jigoong
c57755c09c
fix bug api key managemtn for admin
2026-02-25 02:08:34 +07:00
jigoong
649473d2cc
add admin api management
2026-02-24 23:29:20 +07:00
jigoong
16efd77dfe
add previous fix bug forgotting commit-push
2026-02-24 22:33:37 +07:00
Gamegame101
9abd1f272c
Update API service to use raw_waiting_time table
...
- Change RawOpdCheckpoint model to RawWaitingTime
- Update schema from FeedCheckpointIn to FeedWaitingTimeIn
- Switch to rawdata.raw_waiting_time table
- Keep existing /feed/checkpoint endpoint
- Add new fields: vn, txn, name, doctor_code, doctor_name, location_code, location_name, step_name, time
- Update permission to feed.waiting-time:write
2026-02-24 16:34:34 +07:00
jigoong
300ed08d9e
add files infra docker service for data platform
2026-02-16 17:21:59 +07:00