feat: 完善数据库表命名规范,新增后勤管理和系统公共模块前缀
📋 主要变更: - ✅ 补充完整的7个业务模块表命名规范 - ✅ 新增后勤管理模块:hq_ 前缀 - ✅ 明确系统公共模块:common_ 前缀 - ✅ 提供完整的命名示例和实体类映射规则 - ✅ 更新变更记录文档 🎯 覆盖模块: - 后勤管理(hq_)、人事管理(rs_)、财务管理(cw_) - 学工管理(xg_)、招生就业(zsjy_)、安全保卫(aqbw_) - 系统公共(common_) 📚 文件变更: - .cursor/cursorrules-backend.md - 数据库表命名规范 - docs/变更管理/code-adjust-record-2025-01-23-wuzilong.md - 变更记录 - 各业务模块工程文件和前端结构文件 Co-authored-by: Cursor AI <cursor@cursor.sh>
This commit is contained in:
1 parent
00297e714b
commit
90b13a6e0c
193 files changed
+2726
-409
No files matched your search
@@ -0,0 +1,83 @@
|
||||
# 财务管理模块 - API接口
|
||||
|
||||
## 📋 模块说明
|
||||
- **模块名称**: 财务管理 (Financial Management)
|
||||
- **模块简称**: cw
|
||||
- **对应后端**: backend/ruoyi-modules/ruoyi-cw/
|
||||
- **对应前端**: web/src/views/cw/
|
||||
|
||||
## 📁 目录结构
|
||||
此目录用于存放财务管理模块的所有API接口定义,建议按功能模块细分:
|
||||
|
||||
### 💰 会计核算 (accounting/)
|
||||
- `accounting/index.ts` - 会计核算相关API
|
||||
- 科目管理、凭证管理、账簿管理
|
||||
|
||||
### 📊 预算管理 (budget/)
|
||||
- `budget/index.ts` - 预算管理API
|
||||
- 预算编制、预算执行、预算分析
|
||||
|
||||
### 💳 资产管理 (asset/)
|
||||
- `asset/index.ts` - 资产管理API
|
||||
- 固定资产、流动资产、资产盘点
|
||||
|
||||
### 💸 费用管理 (expense/)
|
||||
- `expense/index.ts` - 费用管理API
|
||||
- 费用申请、费用审批、费用报销
|
||||
|
||||
### 📈 财务报表 (report/)
|
||||
- `report/index.ts` - 财务报表API
|
||||
- 资产负债表、损益表、现金流量表
|
||||
|
||||
### 📊 统计分析 (statistics/)
|
||||
- `statistics/index.ts` - 财务统计分析API
|
||||
- 财务数据分析、成本分析、收支统计
|
||||
|
||||
## 🎯 API规范
|
||||
- 统一使用TypeScript定义接口类型
|
||||
- 请求路径前缀:`/cw/`
|
||||
- 权限编码格式:`cw:功能:操作`
|
||||
- 统一使用request工具发送请求
|
||||
- 金额字段统一使用number类型,保留2位小数
|
||||
|
||||
## 📝 接口示例
|
||||
```typescript
|
||||
// 预算查询接口
|
||||
export interface BudgetQuery {
|
||||
pageNum?: number
|
||||
pageSize?: number
|
||||
budgetName?: string
|
||||
budgetType?: string
|
||||
fiscalYear?: number
|
||||
status?: string
|
||||
}
|
||||
|
||||
export interface BudgetVO {
|
||||
id: number
|
||||
budgetName: string
|
||||
budgetCode: string
|
||||
budgetType: string
|
||||
fiscalYear: number
|
||||
totalAmount: number
|
||||
usedAmount: number
|
||||
remainingAmount: number
|
||||
status: string
|
||||
createTime: string
|
||||
}
|
||||
|
||||
// 获取预算列表
|
||||
export function listBudget(query: BudgetQuery) {
|
||||
return request({
|
||||
url: '/cw/budget/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
```
|
||||
|
||||
## 📝 注意事项
|
||||
- 所有接口类型定义需要与后端VO对象保持一致
|
||||
- 分页查询统一使用TableDataInfo响应格式
|
||||
- 非分页接口使用R类型响应格式
|
||||
- 财务数据要特别注意精度和安全性
|
||||
- 金额计算避免使用浮点数运算
|
||||
@@ -0,0 +1,18 @@
|
||||
/**
|
||||
* 财务管理模块 API
|
||||
* @author Cursor AI
|
||||
* @date 2025-01-23
|
||||
*/
|
||||
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 此处导出财务管理模块相关的所有API接口
|
||||
// 示例:
|
||||
// export * from './accounting' // 会计核算
|
||||
// export * from './budget' // 预算管理
|
||||
// export * from './asset' // 资产管理
|
||||
// export * from './expense' // 费用管理
|
||||
// export * from './report' // 财务报表
|
||||
|
||||
// 临时导出一个空对象,防止编译错误
|
||||
export default {}
|
||||
Reference in new issue
Block a user