feat: 添加用户认证系统

引入基于 Basic Auth 的用户认证系统,包括用户管理、登录界面和 API 鉴权
- 新增用户实体和管理功能
- 实现前端登录界面和凭证管理
- 重构 API 鉴权为 Basic Auth 模式
- 添加用户管理脚本工具
This commit is contained in:
dmy
2026-01-18 12:47:16 +08:00
parent a55dfd78d2
commit b6a6398864
30 changed files with 2042 additions and 82 deletions

View File

@@ -0,0 +1,72 @@
/**
* 共享数据模型
* 用于HTTP和IPC框架的统一数据结构定义
*/
/**
* 投标项目数据模型
*/
export interface BidItem {
id: string
title: string
url: string
publishDate: string
source: string
pin: boolean
createdAt: string
updatedAt: string
}
/**
* AI推荐数据模型
*/
export interface AiRecommendation {
id: string
title: string
confidence: number
createdAt: string
}
/**
* 爬虫统计信息数据模型
*/
export interface CrawlInfoStat {
source: string
count: number
latestUpdate: string
latestPublishDate: string
error: string
}
/**
* 关键词数据模型
*/
export interface Keyword {
id: string
word: string
weight: number
createdAt: string
updatedAt: string
}
/**
* 投标查询参数
*/
export interface BidQueryParams {
limit?: number
offset?: number
startDate?: string
endDate?: string
source?: string
keyword?: string
}
/**
* 分页响应
*/
export interface PaginatedResponse<T> {
data: T[]
total: number
page: number
pageSize: number
}