feat: 学生信息管理系统开发完成
- 完成学生信息管理核心功能开发 - 新增学生信息采集批次管理功能 - 完成班干部管理模块开发 - 修复物业报修模块附件上传逻辑 - 完善数据库表结构和权限配置 - 更新API文档和变更记录 - 优化前端页面交互体验 详细变更记录见: - docs/变更管理/code-adjust-record-2025-01-13-wuzhen.md - docs/变更管理/code-adjust-record-2025-07-11-wuzilong.md - docs/变更管理/code-adjust-record-2025-07-12-wuzhen.md
This commit is contained in:
commit
8697b21b4d
237 files changed
+35787
-2878
No files matched your search
+37
-26
@@ -1,39 +1,48 @@
|
||||
# 安全保卫管理模块 - API接口
|
||||
|
||||
## 📋 模块说明
|
||||
|
||||
- **模块名称**: 安全保卫管理 (Security Management)
|
||||
- **模块简称**: aqbw
|
||||
- **对应后端**: backend/ruoyi-modules/ruoyi-aqbw/
|
||||
- **对应前端**: web/src/views/aqbw/
|
||||
|
||||
## 📁 目录结构
|
||||
|
||||
此目录用于存放安全保卫管理模块的所有API接口定义,建议按功能模块细分:
|
||||
|
||||
### 🔒 门禁管理 (access/)
|
||||
|
||||
- `access/index.ts` - 门禁管理API
|
||||
- 门禁权限、进出记录、访客管理
|
||||
|
||||
### 📹 监控管理 (monitor/)
|
||||
|
||||
- `monitor/index.ts` - 监控管理API
|
||||
- 监控设备、录像查看、异常报警
|
||||
|
||||
### 🚨 安全事件 (incident/)
|
||||
|
||||
- `incident/index.ts` - 安全事件管理API
|
||||
- 事件报告、事件处理、应急预案
|
||||
|
||||
### 👮 安保人员 (security/)
|
||||
|
||||
- `security/index.ts` - 安保人员管理API
|
||||
- 人员管理、值班安排、巡逻记录
|
||||
|
||||
### 🚗 车辆管理 (vehicle/)
|
||||
|
||||
- `vehicle/index.ts` - 车辆管理API
|
||||
- 车辆登记、停车管理、违章处理
|
||||
|
||||
### 📊 统计分析 (statistics/)
|
||||
|
||||
- `statistics/index.ts` - 安全统计分析API
|
||||
- 安全数据统计、事件分析、风险评估
|
||||
|
||||
## 🎯 API规范
|
||||
|
||||
- 统一使用TypeScript定义接口类型
|
||||
- 请求路径前缀:`/aqbw/`
|
||||
- 权限编码格式:`aqbw:功能:操作`
|
||||
@@ -41,36 +50,37 @@
|
||||
- 安全相关接口需要特别的权限控制
|
||||
|
||||
## 📝 接口示例
|
||||
|
||||
```typescript
|
||||
// 安全事件查询接口
|
||||
export interface SecurityIncidentQuery {
|
||||
pageNum?: number
|
||||
pageSize?: number
|
||||
incidentTitle?: string
|
||||
incidentType?: string
|
||||
severity?: string
|
||||
status?: string
|
||||
startDate?: string
|
||||
endDate?: string
|
||||
pageNum?: number;
|
||||
pageSize?: number;
|
||||
incidentTitle?: string;
|
||||
incidentType?: string;
|
||||
severity?: string;
|
||||
status?: string;
|
||||
startDate?: string;
|
||||
endDate?: string;
|
||||
}
|
||||
|
||||
export interface SecurityIncidentVO {
|
||||
id: number
|
||||
incidentTitle: string
|
||||
incidentCode: string
|
||||
incidentType: string
|
||||
severity: string
|
||||
description: string
|
||||
location: string
|
||||
reporterId: number
|
||||
reporterName: string
|
||||
handleId?: number
|
||||
handlerName?: string
|
||||
status: string
|
||||
occurTime: string
|
||||
reportTime: string
|
||||
handleTime?: string
|
||||
createTime: string
|
||||
id: number;
|
||||
incidentTitle: string;
|
||||
incidentCode: string;
|
||||
incidentType: string;
|
||||
severity: string;
|
||||
description: string;
|
||||
location: string;
|
||||
reporterId: number;
|
||||
reporterName: string;
|
||||
handleId?: number;
|
||||
handlerName?: string;
|
||||
status: string;
|
||||
occurTime: string;
|
||||
reportTime: string;
|
||||
handleTime?: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
// 获取安全事件列表
|
||||
@@ -79,14 +89,15 @@ export function listSecurityIncident(query: SecurityIncidentQuery) {
|
||||
url: '/aqbw/incident/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
});
|
||||
}
|
||||
```
|
||||
|
||||
## 📝 注意事项
|
||||
|
||||
- 所有接口类型定义需要与后端VO对象保持一致
|
||||
- 分页查询统一使用TableDataInfo响应格式
|
||||
- 非分页接口使用R类型响应格式
|
||||
- 安全相关数据需要严格的权限控制
|
||||
- 敏感操作需要详细的日志记录
|
||||
- 紧急事件处理接口需要考虑实时性
|
||||
- 紧急事件处理接口需要考虑实时性
|
||||
@@ -4,7 +4,7 @@
|
||||
* @date 2025-01-23
|
||||
*/
|
||||
|
||||
import request from '@/utils/request'
|
||||
import request from '@/utils/request';
|
||||
|
||||
// 此处导出安全保卫管理模块相关的所有API接口
|
||||
// 示例:
|
||||
@@ -15,4 +15,4 @@ import request from '@/utils/request'
|
||||
// export * from './vehicle' // 车辆管理
|
||||
|
||||
// 临时导出一个空对象,防止编译错误
|
||||
export default {}
|
||||
export default {};
|
||||
+29
-18
@@ -1,39 +1,48 @@
|
||||
# 财务管理模块 - 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:功能:操作`
|
||||
@@ -41,28 +50,29 @@
|
||||
- 金额字段统一使用number类型,保留2位小数
|
||||
|
||||
## 📝 接口示例
|
||||
|
||||
```typescript
|
||||
// 预算查询接口
|
||||
export interface BudgetQuery {
|
||||
pageNum?: number
|
||||
pageSize?: number
|
||||
budgetName?: string
|
||||
budgetType?: string
|
||||
fiscalYear?: number
|
||||
status?: string
|
||||
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
|
||||
id: number;
|
||||
budgetName: string;
|
||||
budgetCode: string;
|
||||
budgetType: string;
|
||||
fiscalYear: number;
|
||||
totalAmount: number;
|
||||
usedAmount: number;
|
||||
remainingAmount: number;
|
||||
status: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
// 获取预算列表
|
||||
@@ -71,13 +81,14 @@ export function listBudget(query: BudgetQuery) {
|
||||
url: '/cw/budget/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
});
|
||||
}
|
||||
```
|
||||
|
||||
## 📝 注意事项
|
||||
|
||||
- 所有接口类型定义需要与后端VO对象保持一致
|
||||
- 分页查询统一使用TableDataInfo响应格式
|
||||
- 非分页接口使用R类型响应格式
|
||||
- 财务数据要特别注意精度和安全性
|
||||
- 金额计算避免使用浮点数运算
|
||||
- 金额计算避免使用浮点数运算
|
||||
@@ -4,7 +4,7 @@
|
||||
* @date 2025-01-23
|
||||
*/
|
||||
|
||||
import request from '@/utils/request'
|
||||
import request from '@/utils/request';
|
||||
|
||||
// 此处导出财务管理模块相关的所有API接口
|
||||
// 示例:
|
||||
@@ -15,4 +15,4 @@ import request from '@/utils/request'
|
||||
// export * from './report' // 财务报表
|
||||
|
||||
// 临时导出一个空对象,防止编译错误
|
||||
export default {}
|
||||
export default {};
|
||||
@@ -1,13 +1,6 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import {
|
||||
SatSurveyVO,
|
||||
SatSurveyForm,
|
||||
SatSurveyQuery,
|
||||
SubmitSurveyAnswerForm,
|
||||
SatRecordVO,
|
||||
SurveyStatisticsVO
|
||||
} from '@/api/hq/answerSurvey/types';
|
||||
import { SatSurveyVO, SatSurveyForm, SatSurveyQuery, SubmitSurveyAnswerForm, SatRecordVO, SurveyStatisticsVO } from '@/api/hq/answerSurvey/types';
|
||||
|
||||
/**
|
||||
* 查询问卷列表
|
||||
|
||||
@@ -68,7 +68,6 @@ export interface SatSurveyVO {
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatSurveyForm extends BaseEntity {
|
||||
@@ -141,11 +140,9 @@ export interface SatSurveyForm extends BaseEntity {
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatSurveyQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志
|
||||
*/
|
||||
@@ -206,10 +203,10 @@ export interface SatSurveyQuery extends PageQuery {
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
// ==========================================
|
||||
|
||||
@@ -4,37 +4,34 @@ import { HallReservationVO } from '../hallReservation/types';
|
||||
* 报告厅预约审核表单
|
||||
*/
|
||||
export interface HallReservationAuditForm {
|
||||
/** 预约ID列表 */
|
||||
ids: Array<string | number>;
|
||||
/** 审核状态 */
|
||||
status: string;
|
||||
/** 审核备注 */
|
||||
auditRemark?: string;
|
||||
/** 预约ID列表 */
|
||||
ids: Array<string | number>;
|
||||
/** 审核状态 */
|
||||
status: string;
|
||||
/** 审核备注 */
|
||||
auditRemark?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* 时间冲突检查参数
|
||||
*/
|
||||
export interface TimeCheckParams {
|
||||
/** 报告厅ID */
|
||||
hallId: string | number;
|
||||
/** 预约开始时间 */
|
||||
startTime: string;
|
||||
/** 预约结束时间 */
|
||||
endTime: string;
|
||||
/** 排除的预约ID */
|
||||
excludeId?: string | number;
|
||||
/** 报告厅ID */
|
||||
hallId: string | number;
|
||||
/** 预约开始时间 */
|
||||
startTime: string;
|
||||
/** 预约结束时间 */
|
||||
endTime: string;
|
||||
/** 排除的预约ID */
|
||||
excludeId?: string | number;
|
||||
}
|
||||
|
||||
/**
|
||||
* 时间冲突检查结果
|
||||
*/
|
||||
export interface TimeCheckResult {
|
||||
/** 是否存在冲突 */
|
||||
hasConflict: boolean;
|
||||
/** 冲突的预约列表 */
|
||||
conflictList: HallReservationVO[];
|
||||
/** 是否存在冲突 */
|
||||
hasConflict: boolean;
|
||||
/** 冲突的预约列表 */
|
||||
conflictList: HallReservationVO[];
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -27,7 +27,6 @@ export interface HallInfoVO {
|
||||
* 报告厅描述
|
||||
*/
|
||||
hallDescription: string;
|
||||
|
||||
}
|
||||
|
||||
export interface HallInfoForm extends BaseEntity {
|
||||
@@ -55,11 +54,9 @@ export interface HallInfoForm extends BaseEntity {
|
||||
* 报告厅描述
|
||||
*/
|
||||
hallDescription?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface HallInfoQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 报告厅名称
|
||||
*/
|
||||
@@ -70,11 +67,8 @@ export interface HallInfoQuery extends PageQuery {
|
||||
*/
|
||||
hallStatus?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -68,7 +68,6 @@ export interface HallReservationVO {
|
||||
* 审核备注
|
||||
*/
|
||||
auditRemark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface HallReservationForm extends BaseEntity {
|
||||
@@ -141,11 +140,9 @@ export interface HallReservationForm extends BaseEntity {
|
||||
* 审核备注
|
||||
*/
|
||||
auditRemark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface HallReservationQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 报告厅ID
|
||||
*/
|
||||
@@ -191,11 +188,8 @@ export interface HallReservationQuery extends PageQuery {
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -73,7 +73,7 @@ export const getRepairCategoryTree = (): AxiosPromise<RepairCategoryVO[]> => {
|
||||
/**
|
||||
* 获取维修类型下拉选项
|
||||
*/
|
||||
export const getRepairCategoryOptions = (): AxiosPromise<Array<{value: string | number, label: string}>> => {
|
||||
export const getRepairCategoryOptions = (): AxiosPromise<Array<{ value: string | number; label: string }>> => {
|
||||
return request({
|
||||
url: '/hq/pm/repairCategory/options',
|
||||
method: 'get'
|
||||
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
RepairStatisticsVO,
|
||||
ServiceEvaluationForm,
|
||||
ServiceEvaluationVO
|
||||
} from '@/api/hq/hq/pm/types';
|
||||
} from '@/api/hq/pm/types';
|
||||
|
||||
/**
|
||||
* 查询报修工单列表
|
||||
@@ -153,7 +153,12 @@ export const getRepairAttachments = (orderId: string | number): AxiosPromise<Rep
|
||||
* @param file 文件
|
||||
* @param description 描述
|
||||
*/
|
||||
export const uploadAttachment = (orderId: string | number, uploadStage: string, file: File, description?: string): AxiosPromise<RepairAttachmentVO> => {
|
||||
export const uploadAttachment = (
|
||||
orderId: string | number,
|
||||
uploadStage: string,
|
||||
file: File,
|
||||
description?: string
|
||||
): AxiosPromise<RepairAttachmentVO> => {
|
||||
const formData = new FormData();
|
||||
formData.append('orderId', orderId.toString());
|
||||
formData.append('uploadStage', uploadStage);
|
||||
@@ -161,7 +166,7 @@ export const uploadAttachment = (orderId: string | number, uploadStage: string,
|
||||
if (description) {
|
||||
formData.append('description', description);
|
||||
}
|
||||
|
||||
|
||||
return request({
|
||||
url: '/hq/pm/attachment/upload',
|
||||
method: 'post',
|
||||
@@ -179,21 +184,26 @@ export const uploadAttachment = (orderId: string | number, uploadStage: string,
|
||||
* @param files 文件列表
|
||||
* @param descriptions 描述列表
|
||||
*/
|
||||
export const uploadAttachments = (orderId: string | number, uploadStage: string, files: File[], descriptions?: string[]): AxiosPromise<RepairAttachmentVO[]> => {
|
||||
export const uploadAttachments = (
|
||||
orderId: string | number,
|
||||
uploadStage: string,
|
||||
files: File[],
|
||||
descriptions?: string[]
|
||||
): AxiosPromise<RepairAttachmentVO[]> => {
|
||||
const formData = new FormData();
|
||||
formData.append('orderId', orderId.toString());
|
||||
formData.append('uploadStage', uploadStage);
|
||||
|
||||
|
||||
files.forEach((file, index) => {
|
||||
formData.append('files', file);
|
||||
});
|
||||
|
||||
|
||||
if (descriptions) {
|
||||
descriptions.forEach((desc, index) => {
|
||||
formData.append('descriptions', desc);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
return request({
|
||||
url: '/hq/pm/attachment/upload/batch',
|
||||
method: 'post',
|
||||
@@ -293,3 +303,31 @@ export const getServiceEvaluation = (orderId: string | number): AxiosPromise<Ser
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 更新附件的工单ID(用于新增工单时关联已上传的附件)
|
||||
* @param attachmentId 附件ID
|
||||
* @param orderId 工单ID
|
||||
*/
|
||||
export const updateAttachmentOrderId = (attachmentId: string | number, orderId: string | number): AxiosPromise<any> => {
|
||||
return request({
|
||||
url: `/hq/pm/attachment/${attachmentId}/order/${orderId}`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 批量更新附件的工单ID(用于新增工单时关联已上传的附件)
|
||||
* @param attachmentIds 附件ID列表
|
||||
* @param orderId 工单ID
|
||||
*/
|
||||
export const batchUpdateAttachmentOrderId = (attachmentIds: Array<string | number>, orderId: string | number): AxiosPromise<any> => {
|
||||
return request({
|
||||
url: '/hq/pm/attachment/batch-update-order',
|
||||
method: 'put',
|
||||
data: {
|
||||
attachmentIds: attachmentIds,
|
||||
orderId: orderId
|
||||
}
|
||||
});
|
||||
};
|
||||
@@ -38,7 +38,6 @@ export interface SatCategoryVO {
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatCategoryForm extends BaseEntity {
|
||||
@@ -81,11 +80,9 @@ export interface SatCategoryForm extends BaseEntity {
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatCategoryQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志
|
||||
*/
|
||||
@@ -116,11 +113,8 @@ export interface SatCategoryQuery extends PageQuery {
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -28,7 +28,6 @@ export interface SatDetailVO {
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatDetailForm extends BaseEntity {
|
||||
@@ -61,11 +60,9 @@ export interface SatDetailForm extends BaseEntity {
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatDetailQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志
|
||||
*/
|
||||
@@ -86,11 +83,8 @@ export interface SatDetailQuery extends PageQuery {
|
||||
*/
|
||||
answerScore?: number;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -33,7 +33,6 @@ export interface SatOptionVO {
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatOptionForm extends BaseEntity {
|
||||
@@ -71,11 +70,9 @@ export interface SatOptionForm extends BaseEntity {
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatOptionQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志
|
||||
*/
|
||||
@@ -101,11 +98,8 @@ export interface SatOptionQuery extends PageQuery {
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -48,7 +48,6 @@ export interface SatQuestionVO {
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatQuestionForm extends BaseEntity {
|
||||
@@ -101,11 +100,9 @@ export interface SatQuestionForm extends BaseEntity {
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatQuestionQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志
|
||||
*/
|
||||
@@ -146,11 +143,8 @@ export interface SatQuestionQuery extends PageQuery {
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -68,7 +68,6 @@ export interface SatSurveyVO {
|
||||
* 备注
|
||||
*/
|
||||
remark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatSurveyForm extends BaseEntity {
|
||||
@@ -141,11 +140,9 @@ export interface SatSurveyForm extends BaseEntity {
|
||||
* 备注
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface SatSurveyQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志
|
||||
*/
|
||||
@@ -206,10 +203,10 @@ export interface SatSurveyQuery extends PageQuery {
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -535,11 +532,11 @@ export interface SatisfactionAnalysisVO {
|
||||
* 满意度分布
|
||||
*/
|
||||
distribution: {
|
||||
excellent: number; // 非常满意
|
||||
good: number; // 满意
|
||||
fair: number; // 一般
|
||||
poor: number; // 不满意
|
||||
terrible: number; // 非常不满意
|
||||
excellent: number; // 非常满意
|
||||
good: number; // 满意
|
||||
fair: number; // 一般
|
||||
poor: number; // 不满意
|
||||
terrible: number; // 非常不满意
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -599,6 +596,3 @@ export interface RecordQuery extends PageQuery {
|
||||
*/
|
||||
scoreRange?: number[];
|
||||
}
|
||||
|
||||
|
||||
|
||||
+28
-18
@@ -1,64 +1,73 @@
|
||||
# 人事管理模块 - API接口
|
||||
|
||||
## 📋 模块说明
|
||||
|
||||
- **模块名称**: 人事管理 (Human Resources)
|
||||
- **模块简称**: rs
|
||||
- **对应后端**: backend/ruoyi-modules/ruoyi-rs/
|
||||
- **对应前端**: web/src/views/rs/
|
||||
|
||||
## 📁 目录结构
|
||||
|
||||
此目录用于存放人事管理模块的所有API接口定义,建议按功能模块细分:
|
||||
|
||||
### 👥 员工管理 (employee/)
|
||||
|
||||
- `employee/index.ts` - 员工信息相关API
|
||||
- 员工列表查询、详情、新增、修改、删除
|
||||
- 员工档案管理、入职离职流程
|
||||
|
||||
### 📊 部门管理 (department/)
|
||||
|
||||
- `department/index.ts` - 部门组织架构API
|
||||
- 部门树形结构、部门信息管理
|
||||
|
||||
### 💼 岗位管理 (position/)
|
||||
|
||||
- `position/index.ts` - 岗位职级管理API
|
||||
- 岗位信息、职级体系、岗位分配
|
||||
|
||||
### 💰 薪酬管理 (salary/)
|
||||
|
||||
- `salary/index.ts` - 薪酬绩效管理API
|
||||
- 薪资结构、绩效考核、福利管理
|
||||
|
||||
### 📈 统计报表 (statistics/)
|
||||
|
||||
- `statistics/index.ts` - 人事统计分析API
|
||||
- 人员统计、考勤分析、绩效报表
|
||||
|
||||
## 🎯 API规范
|
||||
|
||||
- 统一使用TypeScript定义接口类型
|
||||
- 请求路径前缀:`/rs/`
|
||||
- 权限编码格式:`rs:功能:操作`
|
||||
- 统一使用request工具发送请求
|
||||
|
||||
## 📝 接口示例
|
||||
|
||||
```typescript
|
||||
// 员工列表查询接口
|
||||
export interface EmployeeQuery {
|
||||
pageNum?: number
|
||||
pageSize?: number
|
||||
employeeName?: string
|
||||
departmentId?: number
|
||||
status?: string
|
||||
pageNum?: number;
|
||||
pageSize?: number;
|
||||
employeeName?: string;
|
||||
departmentId?: number;
|
||||
status?: string;
|
||||
}
|
||||
|
||||
export interface EmployeeVO {
|
||||
id: number
|
||||
employeeName: string
|
||||
employeeCode: string
|
||||
departmentId: number
|
||||
departmentName: string
|
||||
positionId: number
|
||||
positionName: string
|
||||
phone: string
|
||||
email: string
|
||||
status: string
|
||||
createTime: string
|
||||
id: number;
|
||||
employeeName: string;
|
||||
employeeCode: string;
|
||||
departmentId: number;
|
||||
departmentName: string;
|
||||
positionId: number;
|
||||
positionName: string;
|
||||
phone: string;
|
||||
email: string;
|
||||
status: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
// 获取员工列表
|
||||
@@ -67,12 +76,13 @@ export function listEmployee(query: EmployeeQuery) {
|
||||
url: '/rs/employee/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
});
|
||||
}
|
||||
```
|
||||
|
||||
## 📝 注意事项
|
||||
|
||||
- 所有接口类型定义需要与后端VO对象保持一致
|
||||
- 分页查询统一使用TableDataInfo响应格式
|
||||
- 非分页接口使用R类型响应格式
|
||||
- 人事敏感信息注意权限控制和数据脱敏
|
||||
- 人事敏感信息注意权限控制和数据脱敏
|
||||
@@ -4,7 +4,7 @@
|
||||
* @date 2025-01-23
|
||||
*/
|
||||
|
||||
import request from '@/utils/request'
|
||||
import request from '@/utils/request';
|
||||
|
||||
// 此处导出人事管理模块相关的所有API接口
|
||||
// 示例:
|
||||
@@ -14,4 +14,4 @@ import request from '@/utils/request'
|
||||
// export * from './salary' // 薪酬管理
|
||||
|
||||
// 临时导出一个空对象,防止编译错误
|
||||
export default {}
|
||||
export default {};
|
||||
@@ -7,7 +7,7 @@ export function getDicts(dictType: string): AxiosPromise<DictDataVO[]> {
|
||||
url: '/system/dict/data/type/' + dictType,
|
||||
method: 'get',
|
||||
headers: {
|
||||
isToken: false // 字典数据不需要token认证
|
||||
isToken: false // 字典数据不需要token认证
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -221,7 +221,6 @@ export function listUsersByPermission(permission: string, tenantId?: string): Ax
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
export default {
|
||||
listUser,
|
||||
getUser,
|
||||
|
||||
@@ -13,7 +13,6 @@ export interface StuMsgVO {
|
||||
* 学生工号
|
||||
*/
|
||||
stuNo: number;
|
||||
|
||||
}
|
||||
|
||||
export interface StuMsgForm extends BaseEntity {
|
||||
@@ -31,11 +30,9 @@ export interface StuMsgForm extends BaseEntity {
|
||||
* 学生工号
|
||||
*/
|
||||
stuNo?: number;
|
||||
|
||||
}
|
||||
|
||||
export interface StuMsgQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
@@ -46,11 +43,8 @@ export interface StuMsgQuery extends PageQuery {
|
||||
*/
|
||||
stuNo?: number;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,396 @@
|
||||
import { BaseEntity, PageQuery } from './types';
|
||||
|
||||
/**
|
||||
* 学年管理 VO
|
||||
*/
|
||||
export interface AcademicYearVO {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 租户编号
|
||||
*/
|
||||
tenantId: string;
|
||||
|
||||
/**
|
||||
* 学年编码
|
||||
*/
|
||||
yearCode: string;
|
||||
|
||||
/**
|
||||
* 学年名称
|
||||
*/
|
||||
yearName: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate: string;
|
||||
|
||||
/**
|
||||
* 是否当前学年:0-否,1-是
|
||||
*/
|
||||
isCurrent: boolean;
|
||||
|
||||
/**
|
||||
* 学年状态:1-启用,0-停用
|
||||
*/
|
||||
yearStatus: string;
|
||||
|
||||
/**
|
||||
* 学年描述
|
||||
*/
|
||||
description?: string;
|
||||
|
||||
/**
|
||||
* 排序序号
|
||||
*/
|
||||
sortOrder: number;
|
||||
|
||||
/**
|
||||
* 备注信息
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
createBy: string | number;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
createTime: string;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
updateBy?: string | number;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
updateTime?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* 学年管理 Form
|
||||
*/
|
||||
export interface AcademicYearForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 学年编码
|
||||
*/
|
||||
yearCode?: string;
|
||||
|
||||
/**
|
||||
* 学年名称
|
||||
*/
|
||||
yearName?: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate?: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate?: string;
|
||||
|
||||
/**
|
||||
* 是否当前学年
|
||||
*/
|
||||
isCurrent?: boolean;
|
||||
|
||||
/**
|
||||
* 学年状态
|
||||
*/
|
||||
yearStatus?: string;
|
||||
|
||||
/**
|
||||
* 学年描述
|
||||
*/
|
||||
description?: string;
|
||||
|
||||
/**
|
||||
* 排序序号
|
||||
*/
|
||||
sortOrder?: number;
|
||||
|
||||
/**
|
||||
* 备注信息
|
||||
*/
|
||||
remark?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* 学年管理 Query
|
||||
*/
|
||||
export interface AcademicYearQuery extends PageQuery {
|
||||
/**
|
||||
* 学年编码
|
||||
*/
|
||||
yearCode?: string;
|
||||
|
||||
/**
|
||||
* 学年名称
|
||||
*/
|
||||
yearName?: string;
|
||||
|
||||
/**
|
||||
* 是否当前学年
|
||||
*/
|
||||
isCurrent?: boolean;
|
||||
|
||||
/**
|
||||
* 学年状态
|
||||
*/
|
||||
yearStatus?: string;
|
||||
|
||||
/**
|
||||
* 开始日期范围
|
||||
*/
|
||||
startDateRange?: string[];
|
||||
|
||||
/**
|
||||
* 结束日期范围
|
||||
*/
|
||||
endDateRange?: string[];
|
||||
|
||||
/**
|
||||
* 创建时间范围
|
||||
*/
|
||||
createTimeRange?: string[];
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
/**
|
||||
* 学期管理 VO
|
||||
*/
|
||||
export interface SemesterVO {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 租户编号
|
||||
*/
|
||||
tenantId: string;
|
||||
|
||||
/**
|
||||
* 学年ID
|
||||
*/
|
||||
academicYearId: string | number;
|
||||
|
||||
/**
|
||||
* 学年名称
|
||||
*/
|
||||
academicYearName?: string;
|
||||
|
||||
/**
|
||||
* 学期编码
|
||||
*/
|
||||
semesterCode: string;
|
||||
|
||||
/**
|
||||
* 学期名称
|
||||
*/
|
||||
semesterName: string;
|
||||
|
||||
/**
|
||||
* 学期类型:1-春季学期,2-秋季学期,3-夏季学期,4-短学期
|
||||
*/
|
||||
semesterType: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate: string;
|
||||
|
||||
/**
|
||||
* 是否当前学期:0-否,1-是
|
||||
*/
|
||||
isCurrent: boolean;
|
||||
|
||||
/**
|
||||
* 学期状态:1-启用,0-停用
|
||||
*/
|
||||
semesterStatus: string;
|
||||
|
||||
/**
|
||||
* 学期描述
|
||||
*/
|
||||
description?: string;
|
||||
|
||||
/**
|
||||
* 排序序号
|
||||
*/
|
||||
sortOrder: number;
|
||||
|
||||
/**
|
||||
* 备注信息
|
||||
*/
|
||||
remark?: string;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
createBy: string | number;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
createTime: string;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
updateBy?: string | number;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
updateTime?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* 学期管理 Form
|
||||
*/
|
||||
export interface SemesterForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 学年ID
|
||||
*/
|
||||
academicYearId?: string | number;
|
||||
|
||||
/**
|
||||
* 学期编码
|
||||
*/
|
||||
semesterCode?: string;
|
||||
|
||||
/**
|
||||
* 学期名称
|
||||
*/
|
||||
semesterName?: string;
|
||||
|
||||
/**
|
||||
* 学期类型
|
||||
*/
|
||||
semesterType?: string;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
startDate?: string;
|
||||
|
||||
/**
|
||||
* 结束日期
|
||||
*/
|
||||
endDate?: string;
|
||||
|
||||
/**
|
||||
* 是否当前学期
|
||||
*/
|
||||
isCurrent?: boolean;
|
||||
|
||||
/**
|
||||
* 学期状态
|
||||
*/
|
||||
semesterStatus?: string;
|
||||
|
||||
/**
|
||||
* 学期描述
|
||||
*/
|
||||
description?: string;
|
||||
|
||||
/**
|
||||
* 排序序号
|
||||
*/
|
||||
sortOrder?: number;
|
||||
|
||||
/**
|
||||
* 备注信息
|
||||
*/
|
||||
remark?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* 学期管理 Query
|
||||
*/
|
||||
export interface SemesterQuery extends PageQuery {
|
||||
/**
|
||||
* 学年ID
|
||||
*/
|
||||
academicYearId?: string | number;
|
||||
|
||||
/**
|
||||
* 学期编码
|
||||
*/
|
||||
semesterCode?: string;
|
||||
|
||||
/**
|
||||
* 学期名称
|
||||
*/
|
||||
semesterName?: string;
|
||||
|
||||
/**
|
||||
* 学期类型
|
||||
*/
|
||||
semesterType?: string;
|
||||
|
||||
/**
|
||||
* 是否当前学期
|
||||
*/
|
||||
isCurrent?: boolean;
|
||||
|
||||
/**
|
||||
* 学期状态
|
||||
*/
|
||||
semesterStatus?: string;
|
||||
|
||||
/**
|
||||
* 开始日期范围
|
||||
*/
|
||||
startDateRange?: string[];
|
||||
|
||||
/**
|
||||
* 结束日期范围
|
||||
*/
|
||||
endDateRange?: string[];
|
||||
|
||||
/**
|
||||
* 创建时间范围
|
||||
*/
|
||||
createTimeRange?: string[];
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
@@ -0,0 +1,152 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { AcademicYearVO, AcademicYearForm, AcademicYearQuery } from './academicTypes';
|
||||
|
||||
/**
|
||||
* 查询学年管理列表
|
||||
* @param query 查询参数
|
||||
*/
|
||||
export const listAcademicYear = (query?: AcademicYearQuery): AxiosPromise<AcademicYearVO[]> => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询学年管理详细信息
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const getAcademicYear = (id: string | number): AxiosPromise<AcademicYearVO> => {
|
||||
return request({
|
||||
url: `/xg-xx/academicYear/${id}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增学年管理
|
||||
* @param data 学年管理数据
|
||||
*/
|
||||
export const addAcademicYear = (data: AcademicYearForm) => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改学年管理
|
||||
* @param data 学年管理数据
|
||||
*/
|
||||
export const updateAcademicYear = (data: AcademicYearForm) => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除学年管理
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const delAcademicYear = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: `/xg-xx/academicYear/${id}`,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 导出学年管理列表
|
||||
* @param query 查询参数
|
||||
*/
|
||||
export const exportAcademicYear = (query?: AcademicYearQuery) => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear/export',
|
||||
method: 'post',
|
||||
data: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询当前学年
|
||||
*/
|
||||
export const getCurrentAcademicYear = (): AxiosPromise<AcademicYearVO> => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear/current',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 设置当前学年
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const setCurrentAcademicYear = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xg-xx/academicYear/setCurrent/${id}`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询可用的学年选项
|
||||
*/
|
||||
export const getAvailableAcademicYearOptions = (): AxiosPromise<AcademicYearVO[]> => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear/availableOptions',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 校验学年名称是否唯一
|
||||
* @param yearName 学年名称
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const checkAcademicYearName = (yearName: string, id?: string | number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear/checkYearName',
|
||||
method: 'get',
|
||||
params: { yearName, id }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 校验学年编码是否唯一
|
||||
* @param yearCode 学年编码
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const checkAcademicYearCode = (yearCode: string, id?: string | number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg-xx/academicYear/checkYearCode',
|
||||
method: 'get',
|
||||
params: { yearCode, id }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 激活学年
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const activateAcademicYear = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xg-xx/academicYear/activate/${id}`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 停用学年
|
||||
* @param id 学年ID
|
||||
*/
|
||||
export const deactivateAcademicYear = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xg-xx/academicYear/deactivate/${id}`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
@@ -0,0 +1,194 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
|
||||
/**
|
||||
* 业务期间查询参数
|
||||
*/
|
||||
export interface XgBusinessPeriodQuery {
|
||||
id?: number;
|
||||
batchId?: number;
|
||||
periodName?: string;
|
||||
periodType?: string;
|
||||
targetRole?: string;
|
||||
startTime?: string;
|
||||
endTime?: string;
|
||||
status?: string;
|
||||
enabled?: boolean;
|
||||
keyword?: string;
|
||||
batchName?: string;
|
||||
pageNum?: number;
|
||||
pageSize?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* 业务期间表单
|
||||
*/
|
||||
export interface XgBusinessPeriodForm {
|
||||
id?: number;
|
||||
batchId?: number;
|
||||
periodName?: string;
|
||||
periodType?: string;
|
||||
targetRole?: string;
|
||||
startTime?: string;
|
||||
endTime?: string;
|
||||
status?: string;
|
||||
description?: string;
|
||||
sortOrder?: number;
|
||||
enabled?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* 业务期间视图对象
|
||||
*/
|
||||
export interface XgBusinessPeriodVO {
|
||||
id?: number;
|
||||
batchId?: number;
|
||||
batchName?: string;
|
||||
periodName?: string;
|
||||
periodType?: string;
|
||||
targetRole?: string;
|
||||
startTime?: string;
|
||||
endTime?: string;
|
||||
status?: string;
|
||||
description?: string;
|
||||
sortOrder?: number;
|
||||
enabled?: boolean;
|
||||
createTime?: string;
|
||||
updateTime?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询业务期间列表
|
||||
*/
|
||||
export const listBusinessPeriod = (query: XgBusinessPeriodQuery): AxiosPromise<XgBusinessPeriodVO[]> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询所有业务期间列表(不分页)
|
||||
*/
|
||||
export const listAllBusinessPeriod = (query: XgBusinessPeriodQuery): AxiosPromise<XgBusinessPeriodVO[]> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/listAll',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取业务期间详细信息
|
||||
*/
|
||||
export const getBusinessPeriod = (id: string | number): AxiosPromise<XgBusinessPeriodVO> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增业务期间
|
||||
*/
|
||||
export const addBusinessPeriod = (data: XgBusinessPeriodForm) => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改业务期间
|
||||
*/
|
||||
export const updateBusinessPeriod = (data: XgBusinessPeriodForm) => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除业务期间
|
||||
*/
|
||||
export const delBusinessPeriod = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 导出业务期间
|
||||
*/
|
||||
export const exportBusinessPeriod = (query: XgBusinessPeriodQuery) => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/export',
|
||||
method: 'post',
|
||||
data: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 根据批次ID查询业务期间列表
|
||||
*/
|
||||
export const queryByBatchId = (batchId: number): AxiosPromise<XgBusinessPeriodVO[]> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/byBatch/' + batchId,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询当前活跃的业务期间
|
||||
*/
|
||||
export const queryActivePeriods = (): AxiosPromise<XgBusinessPeriodVO[]> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/active',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 检查业务期间是否开放
|
||||
*/
|
||||
export const checkPeriodOpen = (batchId: number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/checkOpen/' + batchId,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 开启业务期间
|
||||
*/
|
||||
export const openPeriod = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/open/' + id,
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 关闭业务期间
|
||||
*/
|
||||
export const closePeriod = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/close/' + id,
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 校验业务期间时间是否冲突
|
||||
*/
|
||||
export const checkPeriodTimeConflict = (data: XgBusinessPeriodForm): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg/businessPeriod/checkTimeConflict',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
@@ -0,0 +1,265 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { XgClassCadreVO, XgClassCadreForm, XgClassCadreQuery } from '@/api/xg-xx/types';
|
||||
|
||||
// 查询班级干部信息列表
|
||||
export const listClassCadre = (query: XgClassCadreQuery): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
// 查询班级干部信息详细
|
||||
export const getClassCadre = (id: string | number): AxiosPromise<XgClassCadreVO> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 新增班级干部信息
|
||||
export const addClassCadre = (data: XgClassCadreForm) => {
|
||||
return request({
|
||||
url: '/xg/classCadre',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 修改班级干部信息
|
||||
export const updateClassCadre = (data: XgClassCadreForm) => {
|
||||
return request({
|
||||
url: '/xg/classCadre',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 删除班级干部信息
|
||||
export const delClassCadre = (ids: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/' + ids,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
// 导出班级干部信息
|
||||
export const exportClassCadre = (query: XgClassCadreQuery) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/export',
|
||||
method: 'post',
|
||||
data: query
|
||||
});
|
||||
};
|
||||
|
||||
// ==================== 业务功能接口 ====================
|
||||
|
||||
// 根据班级ID查询班干部列表
|
||||
export const getCadresByClass = (classId: string | number): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/class/' + classId,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 根据学生ID查询班干部信息
|
||||
export const getCadresByStudent = (studentId: string | number): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/student/' + studentId,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 查询当前在任班干部列表
|
||||
export const getCurrentCadres = (classId?: string | number): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/current',
|
||||
method: 'get',
|
||||
params: { classId }
|
||||
});
|
||||
};
|
||||
|
||||
// 根据职务查询班干部
|
||||
export const getCadreByPosition = (classId: string | number, positionCode: string): AxiosPromise<XgClassCadreVO> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/position',
|
||||
method: 'get',
|
||||
params: { classId, positionCode }
|
||||
});
|
||||
};
|
||||
|
||||
// 任命班干部
|
||||
export const appointCadre = (data: XgClassCadreForm) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/appoint',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 免职班干部
|
||||
export const dismissCadre = (cadreId: string | number, dismissalReason: string, dismissalDate: string) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/dismiss/' + cadreId,
|
||||
method: 'put',
|
||||
params: { dismissalReason, dismissalDate }
|
||||
});
|
||||
};
|
||||
|
||||
// 调任班干部
|
||||
export const transferCadre = (
|
||||
cadreId: string | number,
|
||||
newPositionCode: string,
|
||||
newPositionName: string,
|
||||
transferReason: string,
|
||||
effectiveDate: string
|
||||
) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/transfer/' + cadreId,
|
||||
method: 'put',
|
||||
params: { newPositionCode, newPositionName, transferReason, effectiveDate }
|
||||
});
|
||||
};
|
||||
|
||||
// 续任班干部
|
||||
export const renewCadre = (cadreId: string | number, newTermDuration: number, renewalReason: string) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/renew/' + cadreId,
|
||||
method: 'put',
|
||||
params: { newTermDuration, renewalReason }
|
||||
});
|
||||
};
|
||||
|
||||
// 班干部辞职
|
||||
export const resignCadre = (cadreId: string | number, resignationReason: string, resignationDate: string) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/resign/' + cadreId,
|
||||
method: 'put',
|
||||
params: { resignationReason, resignationDate }
|
||||
});
|
||||
};
|
||||
|
||||
// ==================== 统计查询接口 ====================
|
||||
|
||||
// 查询即将到期的班干部列表
|
||||
export const getExpiringCadres = (days: number = 30): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/expiring',
|
||||
method: 'get',
|
||||
params: { days }
|
||||
});
|
||||
};
|
||||
|
||||
// 查询已到期的班干部列表
|
||||
export const getExpiredCadres = (): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/expired',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 根据学院查询班干部统计
|
||||
export const getCadresByCollege = (collegeName: string): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/college/' + collegeName,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 根据年级查询班干部统计
|
||||
export const getCadresByGrade = (grade: string): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/grade/' + grade,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 查询班干部任期统计
|
||||
export const getCadreTermStatistics = (startDate: string, endDate: string): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/term-statistics',
|
||||
method: 'get',
|
||||
params: { startDate, endDate }
|
||||
});
|
||||
};
|
||||
|
||||
// 根据职务级别查询班干部
|
||||
export const getCadresByLevel = (positionLevel: number): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/level/' + positionLevel,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 查询班干部工作表现统计
|
||||
export const getCadresByPerformance = (performance: string): AxiosPromise<XgClassCadreVO[]> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/performance/' + performance,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// ==================== 辅助功能接口 ====================
|
||||
|
||||
// 检查职务是否已被占用
|
||||
export const checkPositionOccupied = (classId: string | number, positionCode: string, excludeId?: string | number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/check-position',
|
||||
method: 'get',
|
||||
params: { classId, positionCode, excludeId }
|
||||
});
|
||||
};
|
||||
|
||||
// 检查学生是否已有其他职务
|
||||
export const checkStudentHasOtherPosition = (studentId: string | number, excludeId?: string | number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg/classCadre/check-student',
|
||||
method: 'get',
|
||||
params: { studentId, excludeId }
|
||||
});
|
||||
};
|
||||
|
||||
// 批量更新班干部状态
|
||||
export const batchUpdateCadreStatus = (cadreIds: Array<string | number>, status: string) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/batch-status',
|
||||
method: 'put',
|
||||
params: { cadreIds: cadreIds.join(','), status }
|
||||
});
|
||||
};
|
||||
|
||||
// 自动处理到期班干部
|
||||
export const autoProcessExpiredCadres = () => {
|
||||
return request({
|
||||
url: '/xg/classCadre/auto-process-expired',
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
// 发送到期提醒通知
|
||||
export const sendExpirationReminder = (days: number = 30) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/send-reminder',
|
||||
method: 'post',
|
||||
params: { days }
|
||||
});
|
||||
};
|
||||
|
||||
// 导入班干部信息
|
||||
export const importClassCadre = (data: FormData) => {
|
||||
return request({
|
||||
url: '/xg/classCadre/import',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 获取导入模板
|
||||
export const importTemplate = () => {
|
||||
return request({
|
||||
url: '/xg/classCadre/import-template',
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
@@ -1,12 +1,6 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import {
|
||||
ClassInfoVO,
|
||||
ClassInfoForm,
|
||||
ClassInfoQuery,
|
||||
ClassOption,
|
||||
TeacherOption
|
||||
} from './types';
|
||||
import { ClassInfoVO, ClassInfoForm, ClassInfoQuery, ClassOption, TeacherOption } from './types';
|
||||
|
||||
/**
|
||||
* 查询班级信息列表
|
||||
@@ -178,7 +172,9 @@ export const generateClassCode = (params: {
|
||||
* 查询班级学生统计
|
||||
* @param classId 班级ID
|
||||
*/
|
||||
export const getClassStudentStatistics = (classId: string | number): AxiosPromise<{
|
||||
export const getClassStudentStatistics = (
|
||||
classId: string | number
|
||||
): AxiosPromise<{
|
||||
totalCount: number;
|
||||
maleCount: number;
|
||||
femaleCount: number;
|
||||
|
||||
@@ -0,0 +1,162 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { XgCollectionBatchVO, XgCollectionBatchForm, XgCollectionBatchQuery } from './types';
|
||||
|
||||
/**
|
||||
* 查询信息采集批次列表
|
||||
*/
|
||||
export const listCollectionBatch = (query: XgCollectionBatchQuery): AxiosPromise<XgCollectionBatchVO[]> => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询所有信息采集批次列表(不分页)
|
||||
*/
|
||||
export const listAllCollectionBatch = (query: XgCollectionBatchQuery): AxiosPromise<XgCollectionBatchVO[]> => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/listAll',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询信息采集批次详细
|
||||
*/
|
||||
export const getCollectionBatch = (id: string | number): AxiosPromise<XgCollectionBatchVO> => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增信息采集批次
|
||||
*/
|
||||
export const addCollectionBatch = (data: XgCollectionBatchForm) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改信息采集批次
|
||||
*/
|
||||
export const updateCollectionBatch = (data: XgCollectionBatchForm) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除信息采集批次
|
||||
*/
|
||||
export const delCollectionBatch = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 导出信息采集批次
|
||||
*/
|
||||
export const exportCollectionBatch = (query: XgCollectionBatchQuery) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/export',
|
||||
method: 'post',
|
||||
data: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取当前活跃的批次列表
|
||||
*/
|
||||
export const getActiveBatches = (): AxiosPromise<XgCollectionBatchVO[]> => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/active',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 发布批次
|
||||
*/
|
||||
export const publishBatch = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/publish/' + id,
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 取消发布批次
|
||||
*/
|
||||
export const unpublishBatch = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/unpublish/' + id,
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 结束批次
|
||||
*/
|
||||
export const completeBatch = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/complete/' + id,
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 复制批次
|
||||
*/
|
||||
export const copyBatch = (id: string | number, newBatchName: string, newBatchCode: string) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/copy/' + id,
|
||||
method: 'post',
|
||||
params: {
|
||||
newBatchName,
|
||||
newBatchCode
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取批次统计信息
|
||||
*/
|
||||
export const getBatchStatistics = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/statistics/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 更新批次统计信息
|
||||
*/
|
||||
export const updateBatchStatistics = (id: string | number) => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/updateStatistics/' + id,
|
||||
method: 'post'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取批次选项列表(用于下拉框)
|
||||
*/
|
||||
export const getBatchOptions = () => {
|
||||
return request({
|
||||
url: '/xg/collectionBatch/options',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
@@ -6,4 +6,13 @@
|
||||
export * from './studentInfo';
|
||||
// 班级信息管理
|
||||
export * from './classInfo';
|
||||
// 班级干部管理
|
||||
export * from './classCadre';
|
||||
// 学年管理
|
||||
export * from './academicYear';
|
||||
// 学期管理
|
||||
export * from './semester';
|
||||
// 类型定义
|
||||
export * from './types';
|
||||
export * from './academicTypes';
|
||||
export * from './collectionBatch';
|
||||
@@ -0,0 +1,128 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { SemesterVO, SemesterForm, SemesterQuery } from './academicTypes';
|
||||
|
||||
/**
|
||||
* 查询学期管理列表
|
||||
* @param query 查询参数
|
||||
*/
|
||||
export const listSemester = (query?: SemesterQuery): AxiosPromise<SemesterVO[]> => {
|
||||
return request({
|
||||
url: '/xg-xx/semester/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询学期管理详细信息
|
||||
* @param id 学期ID
|
||||
*/
|
||||
export const getSemester = (id: string | number): AxiosPromise<SemesterVO> => {
|
||||
return request({
|
||||
url: `/xg-xx/semester/${id}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增学期管理
|
||||
* @param data 学期管理数据
|
||||
*/
|
||||
export const addSemester = (data: SemesterForm) => {
|
||||
return request({
|
||||
url: '/xg-xx/semester',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改学期管理
|
||||
* @param data 学期管理数据
|
||||
*/
|
||||
export const updateSemester = (data: SemesterForm) => {
|
||||
return request({
|
||||
url: '/xg-xx/semester',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除学期管理
|
||||
* @param id 学期ID
|
||||
*/
|
||||
export const delSemester = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: `/xg-xx/semester/${id}`,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 导出学期管理列表
|
||||
* @param query 查询参数
|
||||
*/
|
||||
export const exportSemester = (query?: SemesterQuery) => {
|
||||
return request({
|
||||
url: '/xg-xx/semester/export',
|
||||
method: 'post',
|
||||
data: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 根据学年ID查询学期列表
|
||||
* @param academicYearId 学年ID
|
||||
*/
|
||||
export const getSemestersByAcademicYear = (academicYearId: string | number): AxiosPromise<SemesterVO[]> => {
|
||||
return request({
|
||||
url: `/xg-xx/semester/getByAcademicYear/${academicYearId}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询当前学期
|
||||
*/
|
||||
export const getCurrentSemester = (): AxiosPromise<SemesterVO> => {
|
||||
return request({
|
||||
url: '/xg-xx/semester/current',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 设置当前学期
|
||||
* @param id 学期ID
|
||||
*/
|
||||
export const setCurrentSemester = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xg-xx/semester/setCurrent/${id}`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询可用的学期选项
|
||||
*/
|
||||
export const getAvailableSemesterOptions = (): AxiosPromise<SemesterVO[]> => {
|
||||
return request({
|
||||
url: '/xg-xx/semester/availableOptions',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 校验学期名称是否唯一
|
||||
* @param semesterName 学期名称
|
||||
* @param id 学期ID
|
||||
*/
|
||||
export const checkSemesterName = (semesterName: string, id?: string | number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg-xx/semester/checkSemesterName',
|
||||
method: 'get',
|
||||
params: { semesterName, id }
|
||||
});
|
||||
};
|
||||
@@ -311,3 +311,168 @@ export const generateStudentNo = (collegeCode: string, enrollmentYear: number):
|
||||
params: { collegeCode, enrollmentYear }
|
||||
});
|
||||
};
|
||||
|
||||
// ==================== 批次相关接口 ====================
|
||||
|
||||
/**
|
||||
* 根据批次ID查询学生信息
|
||||
* @param batchId 批次ID
|
||||
* @param query 查询参数
|
||||
*/
|
||||
export const getStudentsByBatch = (batchId: string | number, query?: StudentInfoQuery): AxiosPromise<StudentInfoVO[]> => {
|
||||
return request({
|
||||
url: `/xg/studentInfo/batch/${batchId}`,
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 关联学生到批次
|
||||
* @param studentId 学生ID
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const associateStudentToBatch = (studentId: string | number, batchId: string | number) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/associateToBatch',
|
||||
method: 'post',
|
||||
data: { studentId, batchId }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 批量关联学生到批次
|
||||
* @param studentIds 学生ID数组
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const batchAssociateStudentsToBatch = (studentIds: (string | number)[], batchId: string | number) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/batchAssociateToBatch',
|
||||
method: 'post',
|
||||
data: { studentIds, batchId }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 提交学生信息到批次
|
||||
* @param studentId 学生ID
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const submitStudentInfo = (studentId: string | number, batchId: string | number) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/submit',
|
||||
method: 'post',
|
||||
data: { studentId, batchId }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 撤回学生信息提交
|
||||
* @param studentId 学生ID
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const withdrawStudentInfo = (studentId: string | number, batchId: string | number) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/withdraw',
|
||||
method: 'post',
|
||||
data: { studentId, batchId }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取学生批次进度
|
||||
* @param studentId 学生ID
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const getStudentBatchProgress = (studentId: string | number, batchId: string | number) => {
|
||||
return request({
|
||||
url: `/xg/studentInfo/batchProgress/${studentId}/${batchId}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 批量审核学生信息
|
||||
* @param studentIds 学生ID数组
|
||||
* @param batchId 批次ID
|
||||
* @param approvalStatus 审核状态
|
||||
* @param approvalComments 审核意见
|
||||
*/
|
||||
export const batchAuditStudentInfo = (data: {
|
||||
studentIds: (string | number)[];
|
||||
batchId: string | number;
|
||||
approvalStatus: string;
|
||||
approvalComments?: string;
|
||||
}) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/batchAudit',
|
||||
method: 'post',
|
||||
data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 检查学生编辑权限
|
||||
* @param studentId 学生ID
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const checkEditPermission = (studentId: string | number, batchId: string | number) => {
|
||||
return request({
|
||||
url: `/xg/studentInfo/checkEditPermission/${studentId}/${batchId}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取学生批次统计信息
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const getStudentBatchStatistics = (batchId: string | number) => {
|
||||
return request({
|
||||
url: `/xg/studentInfo/batchStatistics/${batchId}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 批量提交学生信息
|
||||
* @param studentIds 学生ID数组
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const batchSubmitStudentInfo = (studentIds: (string | number)[], batchId: string | number) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/batchSubmit',
|
||||
method: 'post',
|
||||
data: { studentIds, batchId }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 批量撤回学生信息
|
||||
* @param studentIds 学生ID数组
|
||||
* @param batchId 批次ID
|
||||
*/
|
||||
export const batchWithdrawStudentInfo = (studentIds: (string | number)[], batchId: string | number) => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/batchWithdraw',
|
||||
method: 'post',
|
||||
data: { studentIds, batchId }
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取所有学生选项(用于批次关联)
|
||||
* @param query 查询参数
|
||||
*/
|
||||
export const getAllStudentOptions = (query?: {
|
||||
name?: string;
|
||||
studentNo?: string;
|
||||
classCode?: string;
|
||||
collegeCode?: string;
|
||||
}): AxiosPromise<Array<{ id: string | number; name: string; studentNo: string; className?: string; collegeName?: string }>> => {
|
||||
return request({
|
||||
url: '/xg/studentInfo/allOptions',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
@@ -0,0 +1,182 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
|
||||
/**
|
||||
* 学生信息审核查询参数
|
||||
*/
|
||||
export interface XgStudentInfoApprovalQuery {
|
||||
batchId?: number;
|
||||
studentId?: number;
|
||||
studentName?: string;
|
||||
studentNo?: string;
|
||||
classCode?: string;
|
||||
className?: string;
|
||||
collegeCode?: string;
|
||||
collegeName?: string;
|
||||
submissionStatus?: string;
|
||||
approvalStatus?: string;
|
||||
submissionTimeStart?: string;
|
||||
submissionTimeEnd?: string;
|
||||
approvalTimeStart?: string;
|
||||
approvalTimeEnd?: string;
|
||||
approvalBy?: number;
|
||||
approvalByName?: string;
|
||||
keyword?: string;
|
||||
pageNum?: number;
|
||||
pageSize?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* 学生信息审核视图对象
|
||||
*/
|
||||
export interface XgStudentInfoApprovalVO {
|
||||
id?: number;
|
||||
batchId?: number;
|
||||
batchName?: string;
|
||||
studentId?: number;
|
||||
studentName?: string;
|
||||
studentNo?: string;
|
||||
classCode?: string;
|
||||
className?: string;
|
||||
collegeCode?: string;
|
||||
collegeName?: string;
|
||||
majorCode?: string;
|
||||
majorName?: string;
|
||||
submissionStatus?: string;
|
||||
approvalStatus?: string;
|
||||
submissionTime?: string;
|
||||
approvalTime?: string;
|
||||
approvalBy?: number;
|
||||
approvalByName?: string;
|
||||
approvalComments?: string;
|
||||
phone?: string;
|
||||
idCard?: string;
|
||||
createTime?: string;
|
||||
updateTime?: string;
|
||||
totalCount?: number;
|
||||
pendingCount?: number;
|
||||
approvedCount?: number;
|
||||
rejectedCount?: number;
|
||||
submittedCount?: number;
|
||||
draftCount?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询待审核的学生信息列表
|
||||
*/
|
||||
export const queryPendingApprovalList = (query: XgStudentInfoApprovalQuery): AxiosPromise<XgStudentInfoApprovalVO[]> => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/pending',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询已审核的学生信息列表
|
||||
*/
|
||||
export const queryApprovedList = (query: XgStudentInfoApprovalQuery): AxiosPromise<XgStudentInfoApprovalVO[]> => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/approved',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 审核学生信息
|
||||
*/
|
||||
export const approveStudentInfo = (studentId: number, batchId: number, approved: boolean, comments?: string) => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/approve',
|
||||
method: 'post',
|
||||
params: {
|
||||
studentId,
|
||||
batchId,
|
||||
approved,
|
||||
comments
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 批量审核学生信息
|
||||
*/
|
||||
export const batchApproveStudentInfo = (studentIds: number[], batchId: number, approved: boolean, comments?: string) => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/batchApprove',
|
||||
method: 'post',
|
||||
data: studentIds,
|
||||
params: {
|
||||
batchId,
|
||||
approved,
|
||||
comments
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 撤销审核
|
||||
*/
|
||||
export const revokeApproval = (studentId: number, batchId: number, reason?: string) => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/revoke',
|
||||
method: 'post',
|
||||
params: {
|
||||
studentId,
|
||||
batchId,
|
||||
reason
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询学生信息审核历史
|
||||
*/
|
||||
export const queryApprovalHistory = (studentId: number, batchId: number): AxiosPromise<XgStudentInfoApprovalVO[]> => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/history',
|
||||
method: 'get',
|
||||
params: {
|
||||
studentId,
|
||||
batchId
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取审核统计信息
|
||||
*/
|
||||
export const getApprovalStatistics = (batchId: number): AxiosPromise<XgStudentInfoApprovalVO> => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/statistics',
|
||||
method: 'get',
|
||||
params: {
|
||||
batchId
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 检查审核权限
|
||||
*/
|
||||
export const checkApprovalPermission = (batchId: number): AxiosPromise<boolean> => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/checkPermission',
|
||||
method: 'get',
|
||||
params: {
|
||||
batchId
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 导出审核结果
|
||||
*/
|
||||
export const exportApprovalResults = (query: XgStudentInfoApprovalQuery) => {
|
||||
return request({
|
||||
url: '/xg/studentInfoApproval/export',
|
||||
method: 'post',
|
||||
data: query
|
||||
});
|
||||
};
|
||||
File diff suppressed because it is too large.
Load diff
+35
-23
@@ -1,76 +1,87 @@
|
||||
# 学工管理模块 - API接口
|
||||
|
||||
## 📋 模块说明
|
||||
|
||||
- **模块名称**: 学工管理 (Student Affairs Management)
|
||||
- **模块简称**: xg
|
||||
- **对应后端**: backend/ruoyi-modules/ruoyi-xg/
|
||||
- **对应前端**: web/src/views/xg/
|
||||
|
||||
## 📁 目录结构
|
||||
|
||||
此目录用于存放学工管理模块的所有API接口定义,建议按功能模块细分:
|
||||
|
||||
### 👨🎓 学生管理 (student/)
|
||||
|
||||
- `student/index.ts` - 学生信息管理API
|
||||
- 学生信息、学生档案、学生状态管理
|
||||
|
||||
### 🏠 宿舍管理 (dormitory/)
|
||||
|
||||
- `dormitory/index.ts` - 宿舍管理API
|
||||
- 宿舍分配、宿舍检查、住宿费管理
|
||||
|
||||
### 🎓 班级管理 (class/)
|
||||
|
||||
- `class/index.ts` - 班级管理API
|
||||
- 班级信息、班委管理、班级活动
|
||||
|
||||
### 💰 奖助管理 (scholarship/)
|
||||
|
||||
- `scholarship/index.ts` - 奖助学金管理API
|
||||
- 奖学金、助学金、困难补助管理
|
||||
|
||||
### 📚 德育管理 (moral/)
|
||||
|
||||
- `moral/index.ts` - 德育管理API
|
||||
- 德育评价、违纪处理、综合测评
|
||||
|
||||
### 🎯 活动管理 (activity/)
|
||||
|
||||
- `activity/index.ts` - 活动管理API
|
||||
- 社团活动、文体活动、社会实践
|
||||
|
||||
### 📊 统计分析 (statistics/)
|
||||
|
||||
- `statistics/index.ts` - 学工统计分析API
|
||||
- 学生数据统计、活动统计、综合分析
|
||||
|
||||
## 🎯 API规范
|
||||
|
||||
- 统一使用TypeScript定义接口类型
|
||||
- 请求路径前缀:`/xg/`
|
||||
- 权限编码格式:`xg:功能:操作`
|
||||
- 统一使用request工具发送请求
|
||||
|
||||
## 📝 接口示例
|
||||
|
||||
```typescript
|
||||
// 学生查询接口
|
||||
export interface StudentQuery {
|
||||
pageNum?: number
|
||||
pageSize?: number
|
||||
studentName?: string
|
||||
studentCode?: string
|
||||
classId?: number
|
||||
grade?: string
|
||||
status?: string
|
||||
pageNum?: number;
|
||||
pageSize?: number;
|
||||
studentName?: string;
|
||||
studentCode?: string;
|
||||
classId?: number;
|
||||
grade?: string;
|
||||
status?: string;
|
||||
}
|
||||
|
||||
export interface StudentVO {
|
||||
id: number
|
||||
studentName: string
|
||||
studentCode: string
|
||||
idCard: string
|
||||
classId: number
|
||||
className: string
|
||||
grade: string
|
||||
major: string
|
||||
phone: string
|
||||
email: string
|
||||
dormitoryId?: number
|
||||
dormitoryName?: string
|
||||
status: string
|
||||
createTime: string
|
||||
id: number;
|
||||
studentName: string;
|
||||
studentCode: string;
|
||||
idCard: string;
|
||||
classId: number;
|
||||
className: string;
|
||||
grade: string;
|
||||
major: string;
|
||||
phone: string;
|
||||
email: string;
|
||||
dormitoryId?: number;
|
||||
dormitoryName?: string;
|
||||
status: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
// 获取学生列表
|
||||
@@ -79,13 +90,14 @@ export function listStudent(query: StudentQuery) {
|
||||
url: '/xg/student/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
});
|
||||
}
|
||||
```
|
||||
|
||||
## 📝 注意事项
|
||||
|
||||
- 所有接口类型定义需要与后端VO对象保持一致
|
||||
- 分页查询统一使用TableDataInfo响应格式
|
||||
- 非分页接口使用R类型响应格式
|
||||
- 学生个人信息需要严格的隐私保护
|
||||
- 敏感信息如身份证号需要脱敏处理
|
||||
- 敏感信息如身份证号需要脱敏处理
|
||||
@@ -4,7 +4,7 @@
|
||||
* @date 2025-01-23
|
||||
*/
|
||||
|
||||
import request from '@/utils/request'
|
||||
import request from '@/utils/request';
|
||||
|
||||
// 此处导出学工管理模块相关的所有API接口
|
||||
// 示例:
|
||||
@@ -15,4 +15,4 @@ import request from '@/utils/request'
|
||||
// export * from './activity' // 活动管理
|
||||
|
||||
// 临时导出一个空对象,防止编译错误
|
||||
export default {}
|
||||
export default {};
|
||||
+32
-21
@@ -1,70 +1,80 @@
|
||||
# 招生就业管理模块 - API接口
|
||||
|
||||
## 📋 模块说明
|
||||
|
||||
- **模块名称**: 招生就业管理 (Enrollment & Employment Management)
|
||||
- **模块简称**: zsjy
|
||||
- **对应后端**: backend/ruoyi-modules/ruoyi-zsjy/
|
||||
- **对应前端**: web/src/views/zsjy/
|
||||
|
||||
## 📁 目录结构
|
||||
|
||||
此目录用于存放招生就业管理模块的所有API接口定义,建议按功能模块细分:
|
||||
|
||||
### 📋 招生管理 (enrollment/)
|
||||
|
||||
- `enrollment/index.ts` - 招生管理API
|
||||
- 招生计划、报名管理、考试安排、录取管理
|
||||
|
||||
### 💼 就业管理 (employment/)
|
||||
|
||||
- `employment/index.ts` - 就业管理API
|
||||
- 就业信息发布、就业指导、就业跟踪
|
||||
|
||||
### 🏢 企业管理 (enterprise/)
|
||||
|
||||
- `enterprise/index.ts` - 企业管理API
|
||||
- 合作企业、招聘信息、校企合作
|
||||
|
||||
### 🎯 职业规划 (career/)
|
||||
|
||||
- `career/index.ts` - 职业规划API
|
||||
- 职业测评、简历管理、面试指导
|
||||
|
||||
### 🤝 校企合作 (cooperation/)
|
||||
|
||||
- `cooperation/index.ts` - 校企合作API
|
||||
- 实习基地、合作项目、实习管理
|
||||
|
||||
### 📊 统计分析 (statistics/)
|
||||
|
||||
- `statistics/index.ts` - 招生就业统计API
|
||||
- 招生统计、就业率统计、质量分析
|
||||
|
||||
## 🎯 API规范
|
||||
|
||||
- 统一使用TypeScript定义接口类型
|
||||
- 请求路径前缀:`/zsjy/`
|
||||
- 权限编码格式:`zsjy:功能:操作`
|
||||
- 统一使用request工具发送请求
|
||||
|
||||
## 📝 接口示例
|
||||
|
||||
```typescript
|
||||
// 招生计划查询接口
|
||||
export interface EnrollmentPlanQuery {
|
||||
pageNum?: number
|
||||
pageSize?: number
|
||||
planName?: string
|
||||
major?: string
|
||||
enrollmentYear?: number
|
||||
status?: string
|
||||
pageNum?: number;
|
||||
pageSize?: number;
|
||||
planName?: string;
|
||||
major?: string;
|
||||
enrollmentYear?: number;
|
||||
status?: string;
|
||||
}
|
||||
|
||||
export interface EnrollmentPlanVO {
|
||||
id: number
|
||||
planName: string
|
||||
planCode: string
|
||||
major: string
|
||||
majorCode: string
|
||||
enrollmentYear: number
|
||||
plannedNumber: number
|
||||
actualNumber: number
|
||||
remainingNumber: number
|
||||
startDate: string
|
||||
endDate: string
|
||||
status: string
|
||||
createTime: string
|
||||
id: number;
|
||||
planName: string;
|
||||
planCode: string;
|
||||
major: string;
|
||||
majorCode: string;
|
||||
enrollmentYear: number;
|
||||
plannedNumber: number;
|
||||
actualNumber: number;
|
||||
remainingNumber: number;
|
||||
startDate: string;
|
||||
endDate: string;
|
||||
status: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
// 获取招生计划列表
|
||||
@@ -73,13 +83,14 @@ export function listEnrollmentPlan(query: EnrollmentPlanQuery) {
|
||||
url: '/zsjy/enrollment/plan/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
});
|
||||
}
|
||||
```
|
||||
|
||||
## 📝 注意事项
|
||||
|
||||
- 所有接口类型定义需要与后端VO对象保持一致
|
||||
- 分页查询统一使用TableDataInfo响应格式
|
||||
- 非分页接口使用R类型响应格式
|
||||
- 招生和就业数据需要确保准确性和时效性
|
||||
- 学生和企业信息需要适当的隐私保护
|
||||
- 学生和企业信息需要适当的隐私保护
|
||||
@@ -4,7 +4,7 @@
|
||||
* @date 2025-01-23
|
||||
*/
|
||||
|
||||
import request from '@/utils/request'
|
||||
import request from '@/utils/request';
|
||||
|
||||
// 此处导出招生就业管理模块相关的所有API接口
|
||||
// 示例:
|
||||
@@ -15,4 +15,4 @@ import request from '@/utils/request'
|
||||
// export * from './statistics' // 统计分析
|
||||
|
||||
// 临时导出一个空对象,防止编译错误
|
||||
export default {}
|
||||
export default {};
|
||||
Reference in new issue
Block a user