Giao diện
Thông báo
Trang sinh tự động
Phần nghiệp vụ viết tay; API, dữ liệu, quyền, đường dẫn và file nguồn do bộ sinh điền từ source tại ad83b0aea.
Làm gì
Mẫu thông báo, deep link và theo dõi việc gửi. Thông báo đi qua outbox nên gửi lại được và kiểm được.
Quy mô
| Domain API | notification |
| Query / Mutation | 3 / 1 |
| Nguồn dữ liệu | — |
| Bảng | 0 |
| Luật phân quyền | 2 |
| Đường dẫn Web Admin | 4 |
Thao tác (mutation)
| Mutation | Domain | Mô tả |
|---|---|---|
markNotificationRead | notification | Mark one of the caller's notifications read. Idempotent: the first read |
Phép đọc (query)
| Query | Domain | Mô tả |
|---|---|---|
myNotifications | notification | The caller's own notifications, newest first. notification.read (own). |
notificationEvent | notification | One ledger entry by id; not_found when there is none. Requires notification_event.read. |
notificationEvents | notification | The in-app notification ledger, newest first. Filters: recipient app, kind, |
Quyền
| Mã | Quyền | Ứng dụng | Vai trò | Phạm vi | Trạng thái |
|---|---|---|---|---|---|
NTF-01 | notification.read | APP_USER | user | OWN | PROPOSED |
NTF-02 | notification.mark_read | APP_USER | user | OWN | PROPOSED |
Danh sách đầy đủ và cách đọc các cờ: Ma trận quyền.
Giao diện Web Admin
| Đường dẫn | Hằng số |
|---|---|
/notifications | NOTIFICATIONS |
/notifications/:id | NOTIFICATION_DETAIL |
/notifications/deep-links | NOTIFICATION_DEEP_LINKS |
/notifications/templates | NOTIFICATION_TEMPLATES |
File nguồn
Backend:
code/apps/api/supabase/functions/graphql/domains/notification/