Files
itstudio_manager/README.md
T
2026-08-09 20:51:28 +08:00

77 lines
1.8 KiB
Markdown

# itstudio_manager
## 目前完成的 API 列表
[完整信息](./API.md)
- /api
- /test
- /hello
- /v1
- /auth
- /login
- /logout
- /relogin
- /ask-code
- /register
- /reset
- /email
- /notification-settings
- /toggle-email-status
- /finance
- /
- /{id}/upload_images
- /{id}
- /categories
- /items
- /
- /{id}/upload_images
- /{id}/set_primary_image
- /{id}/borrow
- /{id}/return_item
- /available
- /in_use
- /categories
- /images
- /proof-images
- /
- /{id}
- /usages
- /
- /{id}/upload_images
- /current
- /by_user
- /images
#### 认证方式
所有 API 均使用 **JWT 认证**(除了需要特殊处理的端点)
```
Authorization: Bearer <token>
```
## 数据库结构
[schema.sql](./schema.sql)
- users/account (系统用户/认证信息)
- categories (物品类别)
- parent_id -> categories.id (自关联父级)
- items (物品基本信息)
- category_id -> categories.id
- created_by -> account.id
- item_transactions (物品出入库流水)
- item_id -> items.id (ON DELETE CASCADE)
- operator_id -> account.id
- borrow_records (借用/归还记录)
- item_id -> items.id (ON DELETE CASCADE)
- borrower (借入人,字符串)
- approver (借出/审批人,字符串)
- finance_records (财务相关记录)
- related_item_id -> items.id
- recorded_by -> account.id
- email_notices (邮件通知规则/历史)
- attachments (文件附件存储索引表)
- uploaded_by -> account.id