feat: 顶部通知铃铛与站内通知中心
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m7s

This commit is contained in:
luo
2026-07-24 17:12:29 +08:00
parent 4c6d871c35
commit d1ff4d5f6c
18 changed files with 1101 additions and 519 deletions

View File

@@ -119,3 +119,6 @@ export * from './orderPackageInvalidateTask'
// 批量订购任务相关
export * from './bulkPurchase'
// 站内通知相关
export * from './notification'

View File

@@ -0,0 +1,51 @@
export type NotificationCategory = 'approval' | 'expiry' | 'sync' | 'system' | 'balance' | string
export type NotificationReadStatus = 'read' | 'unread' | string
export interface NotificationItem {
id: number | string
title: string
content: string
category?: NotificationCategory | null
type?: string | null
severity?: string | null
read?: boolean
is_read?: boolean
read_status?: NotificationReadStatus | null
created_at?: string | null
updated_at?: string | null
ref_type?: string | null
ref_id?: number | string | null
[key: string]: unknown
}
export interface NotificationQueryParams {
page?: number
page_size?: number
category?: string
type?: string
severity?: string
read_status?: string
}
export interface NotificationListResponse {
items: NotificationItem[]
total: number
page?: number
page_size?: number
size?: number
}
export interface NotificationSummary {
items: NotificationItem[]
categories?: Record<string, number>
total_unread?: number
}
export interface NotificationTarget {
available?: boolean
route_name?: string | null
route_path?: string | null
route_params?: Record<string, string | number> | null
query?: Record<string, string | number | boolean> | null
message?: string | null
}