12312
This commit is contained in:
commit
239fa7b92a
249 files changed
+43765
-999
No files matched your search
@@ -7,7 +7,7 @@ import request from '@/utils/request'
|
||||
* @param expireSeconds 过期时间(秒),默认300秒
|
||||
* @returns 临时访问URL
|
||||
*/
|
||||
export function getFileAccessUrl(ossId: number, bucketPassword?: string, expireSeconds: number = 300) {
|
||||
export function getFileAccessUrl(ossId: number | string | bigint, bucketPassword?: string, expireSeconds: number = 300) {
|
||||
return request({
|
||||
url: `/resource/file/access/${ossId}`,
|
||||
method: 'get',
|
||||
@@ -44,9 +44,9 @@ export function getBatchFileAccessUrl(ossIds: number[], bucketPassword?: string,
|
||||
* @param expireSeconds 过期时间(秒),默认300秒
|
||||
* @returns 下载URL
|
||||
*/
|
||||
export function getFileDownloadUrl(ossId: number, bucketPassword?: string, expireSeconds: number = 300) {
|
||||
export function getFileDownloadUrl(ossId: number | string | bigint, bucketPassword?: string, expireSeconds: number = 300) {
|
||||
return request({
|
||||
url: `/resource/file/download/${ossId}`,
|
||||
url: `/resource/oss/download/${ossId}`,
|
||||
method: 'get',
|
||||
params: {
|
||||
bucketPassword,
|
||||
@@ -62,7 +62,7 @@ export function getFileDownloadUrl(ossId: number, bucketPassword?: string, expir
|
||||
* @param expireSeconds 过期时间(秒),默认300秒
|
||||
* @returns 预览URL
|
||||
*/
|
||||
export function getFilePreviewUrl(ossId: number, bucketPassword?: string, expireSeconds: number = 300) {
|
||||
export function getFilePreviewUrl(ossId: number | string | bigint, bucketPassword?: string, expireSeconds: number = 300) {
|
||||
return request({
|
||||
url: `/resource/file/preview/${ossId}`,
|
||||
method: 'get',
|
||||
@@ -80,7 +80,7 @@ export function getFilePreviewUrl(ossId: number, bucketPassword?: string, expire
|
||||
* @param bucketPassword bucket访问密码
|
||||
* @returns Promise<void>
|
||||
*/
|
||||
export async function secureDownloadFile(ossId: number, fileName: string, bucketPassword?: string) {
|
||||
export async function secureDownloadFile(ossId: number | string | bigint, fileName: string, bucketPassword?: string) {
|
||||
try {
|
||||
// 获取临时下载URL
|
||||
const { data: downloadUrl } = await getFileDownloadUrl(ossId, bucketPassword)
|
||||
@@ -119,7 +119,7 @@ export async function secureDownloadFile(ossId: number, fileName: string, bucket
|
||||
* @param bucketPassword bucket访问密码
|
||||
* @returns Promise<string> 预览URL
|
||||
*/
|
||||
export async function securePreviewFile(ossId: number, contentType?: string, bucketPassword?: string) {
|
||||
export async function securePreviewFile(ossId: number | string | bigint, contentType?: string, bucketPassword?: string) {
|
||||
try {
|
||||
// 获取临时预览URL
|
||||
const { data: previewUrl } = await getFilePreviewUrl(ossId, bucketPassword)
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { StudentLeaveVO, StudentLeaveForm, StudentLeaveQuery } from '@/api/workflow/studentLeave/studentLeave/types';
|
||||
|
||||
/**
|
||||
* 查询学生请假 - 记录学生的请假申请、审批和销假信息列表
|
||||
* @param query
|
||||
* @returns {*}
|
||||
*/
|
||||
|
||||
export const listStudentLeave = (query?: StudentLeaveQuery): AxiosPromise<StudentLeaveVO[]> => {
|
||||
return request({
|
||||
url: '/studentLeave/studentLeave/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询学生请假 - 记录学生的请假申请、审批和销假信息详细
|
||||
* @param id
|
||||
*/
|
||||
export const getStudentLeave = (id: string | number): AxiosPromise<StudentLeaveVO> => {
|
||||
return request({
|
||||
url: '/studentLeave/studentLeave/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增学生请假 - 记录学生的请假申请、审批和销假信息
|
||||
* @param data
|
||||
*/
|
||||
export const addStudentLeave = (data: StudentLeaveForm) => {
|
||||
return request({
|
||||
url: '/studentLeave/studentLeave',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改学生请假 - 记录学生的请假申请、审批和销假信息
|
||||
* @param data
|
||||
*/
|
||||
export const updateStudentLeave = (data: StudentLeaveForm) => {
|
||||
return request({
|
||||
url: '/studentLeave/studentLeave',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除学生请假 - 记录学生的请假申请、审批和销假信息
|
||||
* @param id
|
||||
*/
|
||||
export const delStudentLeave = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/studentLeave/studentLeave/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
@@ -0,0 +1,511 @@
|
||||
export interface StudentLeaveVO {
|
||||
/**
|
||||
* 主键ID(雪花ID)
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 删除标志(0代表存在 1代表删除)
|
||||
*/
|
||||
deleted: number;
|
||||
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId: string | number;
|
||||
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName: string;
|
||||
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo: string;
|
||||
|
||||
/**
|
||||
* 班级ID
|
||||
*/
|
||||
classId: string | number;
|
||||
|
||||
/**
|
||||
* 班级名称
|
||||
*/
|
||||
className: string;
|
||||
|
||||
/**
|
||||
* 专业ID
|
||||
*/
|
||||
majorId: string | number;
|
||||
|
||||
/**
|
||||
* 专业名称
|
||||
*/
|
||||
majorName: string;
|
||||
|
||||
/**
|
||||
* 学院ID
|
||||
*/
|
||||
collegeId: string | number;
|
||||
|
||||
/**
|
||||
* 学院名称
|
||||
*/
|
||||
collegeName: string;
|
||||
|
||||
/**
|
||||
* 请假类型编码
|
||||
*/
|
||||
leaveTypeCode: string;
|
||||
|
||||
/**
|
||||
* 请假类型名称
|
||||
*/
|
||||
leaveTypeName: string;
|
||||
|
||||
/**
|
||||
* 开始时间(年月日时分秒)
|
||||
*/
|
||||
startTime: string;
|
||||
|
||||
/**
|
||||
* 结束时间(年月日时分秒)
|
||||
*/
|
||||
endTime: string;
|
||||
|
||||
/**
|
||||
* 请假时长(天)
|
||||
*/
|
||||
leaveDuration: number;
|
||||
|
||||
/**
|
||||
* 是否离校:0-否,1-是
|
||||
*/
|
||||
isLeaveSchool: string;
|
||||
|
||||
/**
|
||||
* 是否需要销假:0-否,1-是
|
||||
*/
|
||||
needCancel: string;
|
||||
|
||||
/**
|
||||
* 紧急联系人
|
||||
*/
|
||||
emergencyContact: string;
|
||||
|
||||
/**
|
||||
* 紧急联系电话
|
||||
*/
|
||||
emergencyPhone: string;
|
||||
|
||||
/**
|
||||
* 请假原因
|
||||
*/
|
||||
leaveReason: string;
|
||||
|
||||
/**
|
||||
* 请假时地理位置
|
||||
*/
|
||||
leaveLocation: string;
|
||||
|
||||
/**
|
||||
* 附件OSS文件ID(逗号分隔)
|
||||
*/
|
||||
attachmentOssIds: string | number;
|
||||
|
||||
/**
|
||||
* 审批状态:0-待审批,1-已通过,2-已拒绝,3-已取消
|
||||
*/
|
||||
approvalStatus: string;
|
||||
|
||||
/**
|
||||
* 审批意见
|
||||
*/
|
||||
approvalOpinion: string;
|
||||
|
||||
/**
|
||||
* 审批时间
|
||||
*/
|
||||
approvalTime: string;
|
||||
|
||||
/**
|
||||
* 审批人ID
|
||||
*/
|
||||
approvalBy: number;
|
||||
|
||||
/**
|
||||
* 审批人姓名
|
||||
*/
|
||||
approvalByName: string;
|
||||
|
||||
/**
|
||||
* 销假状态:0-未销假,1-已销假,2-逾期未销假
|
||||
*/
|
||||
cancelStatus: string;
|
||||
|
||||
/**
|
||||
* 销假时间
|
||||
*/
|
||||
cancelTime: string;
|
||||
|
||||
/**
|
||||
* 销假地理位置
|
||||
*/
|
||||
cancelLocation: string;
|
||||
|
||||
/**
|
||||
* 销假照片OSS文件ID(逗号分隔)
|
||||
*/
|
||||
cancelPhotoOssIds: string | number;
|
||||
|
||||
/**
|
||||
* 销假备注
|
||||
*/
|
||||
cancelRemark: string;
|
||||
|
||||
}
|
||||
|
||||
export interface StudentLeaveForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID(雪花ID)
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 删除标志(0代表存在 1代表删除)
|
||||
*/
|
||||
deleted?: number;
|
||||
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId?: string | number;
|
||||
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName?: string;
|
||||
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
|
||||
/**
|
||||
* 班级ID
|
||||
*/
|
||||
classId?: string | number;
|
||||
|
||||
/**
|
||||
* 班级名称
|
||||
*/
|
||||
className?: string;
|
||||
|
||||
/**
|
||||
* 专业ID
|
||||
*/
|
||||
majorId?: string | number;
|
||||
|
||||
/**
|
||||
* 专业名称
|
||||
*/
|
||||
majorName?: string;
|
||||
|
||||
/**
|
||||
* 学院ID
|
||||
*/
|
||||
collegeId?: string | number;
|
||||
|
||||
/**
|
||||
* 学院名称
|
||||
*/
|
||||
collegeName?: string;
|
||||
|
||||
/**
|
||||
* 请假类型编码
|
||||
*/
|
||||
leaveTypeCode?: string;
|
||||
|
||||
/**
|
||||
* 请假类型名称
|
||||
*/
|
||||
leaveTypeName?: string;
|
||||
|
||||
/**
|
||||
* 开始时间(年月日时分秒)
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 结束时间(年月日时分秒)
|
||||
*/
|
||||
endTime?: string;
|
||||
|
||||
/**
|
||||
* 请假时长(天)
|
||||
*/
|
||||
leaveDuration?: number;
|
||||
|
||||
/**
|
||||
* 是否离校:0-否,1-是
|
||||
*/
|
||||
isLeaveSchool?: string;
|
||||
|
||||
/**
|
||||
* 是否需要销假:0-否,1-是
|
||||
*/
|
||||
needCancel?: string;
|
||||
|
||||
/**
|
||||
* 紧急联系人
|
||||
*/
|
||||
emergencyContact?: string;
|
||||
|
||||
/**
|
||||
* 紧急联系电话
|
||||
*/
|
||||
emergencyPhone?: string;
|
||||
|
||||
/**
|
||||
* 请假原因
|
||||
*/
|
||||
leaveReason?: string;
|
||||
|
||||
/**
|
||||
* 请假时地理位置
|
||||
*/
|
||||
leaveLocation?: string;
|
||||
|
||||
/**
|
||||
* 附件OSS文件ID(逗号分隔)
|
||||
*/
|
||||
attachmentOssIds?: string | number;
|
||||
|
||||
/**
|
||||
* 审批状态:0-待审批,1-已通过,2-已拒绝,3-已取消
|
||||
*/
|
||||
approvalStatus?: string;
|
||||
|
||||
/**
|
||||
* 审批意见
|
||||
*/
|
||||
approvalOpinion?: string;
|
||||
|
||||
/**
|
||||
* 审批时间
|
||||
*/
|
||||
approvalTime?: string;
|
||||
|
||||
/**
|
||||
* 审批人ID
|
||||
*/
|
||||
approvalBy?: number;
|
||||
|
||||
/**
|
||||
* 审批人姓名
|
||||
*/
|
||||
approvalByName?: string;
|
||||
|
||||
/**
|
||||
* 销假状态:0-未销假,1-已销假,2-逾期未销假
|
||||
*/
|
||||
cancelStatus?: string;
|
||||
|
||||
/**
|
||||
* 销假时间
|
||||
*/
|
||||
cancelTime?: string;
|
||||
|
||||
/**
|
||||
* 销假地理位置
|
||||
*/
|
||||
cancelLocation?: string;
|
||||
|
||||
/**
|
||||
* 销假照片OSS文件ID(逗号分隔)
|
||||
*/
|
||||
cancelPhotoOssIds?: string | number;
|
||||
|
||||
/**
|
||||
* 销假备注
|
||||
*/
|
||||
cancelRemark?: string;
|
||||
|
||||
/**
|
||||
* 操作类型:add-新增,update-修改,view-查看
|
||||
*/
|
||||
type?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface StudentLeaveQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志(0代表存在 1代表删除)
|
||||
*/
|
||||
deleted?: number;
|
||||
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId?: string | number;
|
||||
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName?: string;
|
||||
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
|
||||
/**
|
||||
* 班级ID
|
||||
*/
|
||||
classId?: string | number;
|
||||
|
||||
/**
|
||||
* 班级名称
|
||||
*/
|
||||
className?: string;
|
||||
|
||||
/**
|
||||
* 专业ID
|
||||
*/
|
||||
majorId?: string | number;
|
||||
|
||||
/**
|
||||
* 专业名称
|
||||
*/
|
||||
majorName?: string;
|
||||
|
||||
/**
|
||||
* 学院ID
|
||||
*/
|
||||
collegeId?: string | number;
|
||||
|
||||
/**
|
||||
* 学院名称
|
||||
*/
|
||||
collegeName?: string;
|
||||
|
||||
/**
|
||||
* 请假类型编码
|
||||
*/
|
||||
leaveTypeCode?: string;
|
||||
|
||||
/**
|
||||
* 请假类型名称
|
||||
*/
|
||||
leaveTypeName?: string;
|
||||
|
||||
/**
|
||||
* 开始时间(年月日时分秒)
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 结束时间(年月日时分秒)
|
||||
*/
|
||||
endTime?: string;
|
||||
|
||||
/**
|
||||
* 请假时长(天)
|
||||
*/
|
||||
leaveDuration?: number;
|
||||
|
||||
/**
|
||||
* 是否离校:0-否,1-是
|
||||
*/
|
||||
isLeaveSchool?: string;
|
||||
|
||||
/**
|
||||
* 是否需要销假:0-否,1-是
|
||||
*/
|
||||
needCancel?: string;
|
||||
|
||||
/**
|
||||
* 紧急联系人
|
||||
*/
|
||||
emergencyContact?: string;
|
||||
|
||||
/**
|
||||
* 紧急联系电话
|
||||
*/
|
||||
emergencyPhone?: string;
|
||||
|
||||
/**
|
||||
* 请假原因
|
||||
*/
|
||||
leaveReason?: string;
|
||||
|
||||
/**
|
||||
* 请假时地理位置
|
||||
*/
|
||||
leaveLocation?: string;
|
||||
|
||||
/**
|
||||
* 附件OSS文件ID(逗号分隔)
|
||||
*/
|
||||
attachmentOssIds?: string | number;
|
||||
|
||||
/**
|
||||
* 审批状态:0-待审批,1-已通过,2-已拒绝,3-已取消
|
||||
*/
|
||||
approvalStatus?: string;
|
||||
|
||||
/**
|
||||
* 审批意见
|
||||
*/
|
||||
approvalOpinion?: string;
|
||||
|
||||
/**
|
||||
* 审批时间
|
||||
*/
|
||||
approvalTime?: string;
|
||||
|
||||
/**
|
||||
* 审批人ID
|
||||
*/
|
||||
approvalBy?: number;
|
||||
|
||||
/**
|
||||
* 审批人姓名
|
||||
*/
|
||||
approvalByName?: string;
|
||||
|
||||
/**
|
||||
* 销假状态:0-未销假,1-已销假,2-逾期未销假
|
||||
*/
|
||||
cancelStatus?: string;
|
||||
|
||||
/**
|
||||
* 销假时间
|
||||
*/
|
||||
cancelTime?: string;
|
||||
|
||||
/**
|
||||
* 销假地理位置
|
||||
*/
|
||||
cancelLocation?: string;
|
||||
|
||||
/**
|
||||
* 销假照片OSS文件ID(逗号分隔)
|
||||
*/
|
||||
cancelPhotoOssIds?: string | number;
|
||||
|
||||
/**
|
||||
* 销假备注
|
||||
*/
|
||||
cancelRemark?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
import request from '@/utils/request';
|
||||
import { AxiosPromise } from 'axios';
|
||||
import { XgLeaveTypeConfigVO, XgLeaveTypeConfigForm, XgLeaveTypeConfigQuery } from '@/api/xg/xsjcxx/xgLeaveTypeConfig/xgLeaveTypeConfig/types';
|
||||
|
||||
/**
|
||||
* 查询学生请假类型配置列表
|
||||
* @param query
|
||||
* @returns {*}
|
||||
*/
|
||||
|
||||
export const listXgLeaveTypeConfig = (query?: XgLeaveTypeConfigQuery): AxiosPromise<XgLeaveTypeConfigVO[]> => {
|
||||
return request({
|
||||
url: '/xgLeaveTypeConfig/xgLeaveTypeConfig/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 查询学生请假类型配置详细
|
||||
* @param id
|
||||
*/
|
||||
export const getXgLeaveTypeConfig = (id: string | number): AxiosPromise<XgLeaveTypeConfigVO> => {
|
||||
return request({
|
||||
url: '/xgLeaveTypeConfig/xgLeaveTypeConfig/' + id,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 新增学生请假类型配置
|
||||
* @param data
|
||||
*/
|
||||
export const addXgLeaveTypeConfig = (data: XgLeaveTypeConfigForm) => {
|
||||
return request({
|
||||
url: '/xgLeaveTypeConfig/xgLeaveTypeConfig',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 修改学生请假类型配置
|
||||
* @param data
|
||||
*/
|
||||
export const updateXgLeaveTypeConfig = (data: XgLeaveTypeConfigForm) => {
|
||||
return request({
|
||||
url: '/xgLeaveTypeConfig/xgLeaveTypeConfig',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 删除学生请假类型配置
|
||||
* @param id
|
||||
*/
|
||||
export const delXgLeaveTypeConfig = (id: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: '/xgLeaveTypeConfig/xgLeaveTypeConfig/' + id,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
@@ -0,0 +1,166 @@
|
||||
export interface XgLeaveTypeConfigVO {
|
||||
/**
|
||||
* 主键ID(雪花ID)
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 请假类型名称
|
||||
*/
|
||||
leaveTypeName: string;
|
||||
|
||||
/**
|
||||
* 请假类型编码
|
||||
*/
|
||||
leaveTypeCode: string;
|
||||
|
||||
/**
|
||||
* 请假类型描述
|
||||
*/
|
||||
leaveTypeDesc: string;
|
||||
|
||||
/**
|
||||
* 排序号
|
||||
*/
|
||||
sortOrder: number;
|
||||
|
||||
/**
|
||||
* 请假是否需要上传地理位置:0-否,1-是
|
||||
*/
|
||||
needLocationOnApply: string;
|
||||
|
||||
/**
|
||||
* 销假是否必须上传照片:0-否,1-是
|
||||
*/
|
||||
needPhotoOnCancel: string;
|
||||
|
||||
/**
|
||||
* 销假是否需要上传地理位置:0-否,1-是
|
||||
*/
|
||||
needLocationOnCancel: string;
|
||||
|
||||
/**
|
||||
* 非离校请假是否需要销假:0-否,1-是
|
||||
*/
|
||||
needCancelForNonLeave: string;
|
||||
|
||||
/**
|
||||
* 是否可以提前请假:0-否,1-是
|
||||
*/
|
||||
canApplyInAdvance: string;
|
||||
|
||||
/**
|
||||
* 是否开启:0-关闭,1-开启
|
||||
*/
|
||||
isEnabled: string;
|
||||
|
||||
/**
|
||||
* 请假最大申请时长(天)
|
||||
*/
|
||||
maxApplyDuration: number;
|
||||
|
||||
/**
|
||||
* 销假逾期多少时长给予提醒(天)
|
||||
*/
|
||||
cancelOverdueReminder: number;
|
||||
|
||||
}
|
||||
|
||||
export interface XgLeaveTypeConfigForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID(雪花ID)
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 请假类型名称
|
||||
*/
|
||||
leaveTypeName?: string;
|
||||
|
||||
/**
|
||||
* 请假类型编码
|
||||
*/
|
||||
leaveTypeCode?: string;
|
||||
|
||||
/**
|
||||
* 请假类型描述
|
||||
*/
|
||||
leaveTypeDesc?: string;
|
||||
|
||||
/**
|
||||
* 排序号
|
||||
*/
|
||||
sortOrder?: number;
|
||||
|
||||
/**
|
||||
* 请假是否需要上传地理位置:0-否,1-是
|
||||
*/
|
||||
needLocationOnApply?: string;
|
||||
|
||||
/**
|
||||
* 销假是否必须上传照片:0-否,1-是
|
||||
*/
|
||||
needPhotoOnCancel?: string;
|
||||
|
||||
/**
|
||||
* 销假是否需要上传地理位置:0-否,1-是
|
||||
*/
|
||||
needLocationOnCancel?: string;
|
||||
|
||||
/**
|
||||
* 非离校请假是否需要销假:0-否,1-是
|
||||
*/
|
||||
needCancelForNonLeave?: string;
|
||||
|
||||
/**
|
||||
* 是否可以提前请假:0-否,1-是
|
||||
*/
|
||||
canApplyInAdvance?: string;
|
||||
|
||||
/**
|
||||
* 是否开启:0-关闭,1-开启
|
||||
*/
|
||||
isEnabled?: string;
|
||||
|
||||
/**
|
||||
* 请假最大申请时长(天)
|
||||
*/
|
||||
maxApplyDuration?: number;
|
||||
|
||||
/**
|
||||
* 销假逾期多少时长给予提醒(天)
|
||||
*/
|
||||
cancelOverdueReminder?: number;
|
||||
|
||||
}
|
||||
|
||||
export interface XgLeaveTypeConfigQuery extends PageQuery {
|
||||
|
||||
/**
|
||||
* 删除标志(0代表存在 1代表删除)
|
||||
*/
|
||||
deleted?: number;
|
||||
|
||||
/**
|
||||
* 请假类型名称
|
||||
*/
|
||||
leaveTypeName?: string;
|
||||
|
||||
/**
|
||||
* 请假类型编码
|
||||
*/
|
||||
leaveTypeCode?: string;
|
||||
|
||||
/**
|
||||
* 是否开启:0-关闭,1-开启
|
||||
*/
|
||||
isEnabled?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
|
||||
@@ -0,0 +1,214 @@
|
||||
import request from '@/utils/request';
|
||||
import {
|
||||
XljkConsultationScheduleVO,
|
||||
XljkConsultationScheduleForm,
|
||||
XljkConsultationScheduleQuery,
|
||||
XljkConsultationAppointmentVO,
|
||||
XljkConsultationAppointmentForm,
|
||||
XljkConsultationAppointmentQuery,
|
||||
AvailableTimeSlot,
|
||||
TimeSlotDetail,
|
||||
CounselorOption
|
||||
} from './types';
|
||||
|
||||
// ===== 预约时段管理 API =====
|
||||
|
||||
// 查询预约时段列表
|
||||
export const listSchedule = (query: XljkConsultationScheduleQuery) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/schedule/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
// 查询预约时段详细信息
|
||||
export const getSchedule = (id: string | number) => {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/schedule/${id}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 新增预约时段
|
||||
export const addSchedule = (data: any) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/schedule',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 修改预约时段
|
||||
export const updateSchedule = (data: XljkConsultationScheduleForm) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/schedule',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 删除预约时段
|
||||
export const delSchedule = (ids: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/schedule/${typeof ids === 'object' ? ids.join(',') : ids}`,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
// ===== 预约记录管理 API =====
|
||||
|
||||
// 查询预约记录列表
|
||||
export const listAppointment = (query: XljkConsultationAppointmentQuery) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
// 查询预约记录详细信息
|
||||
export const getAppointment = (id: string | number) => {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/appointment/${id}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 修改预约记录
|
||||
export const updateAppointment = (data: XljkConsultationAppointmentForm) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 删除预约记录
|
||||
export const delAppointment = (ids: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/appointment/${typeof ids === 'object' ? ids.join(',') : ids}`,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
|
||||
// 获取可预约时段列表(用于日历视图)
|
||||
export const getAvailableTimeSlots = (startDate: string, endDate: string) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/available-slots',
|
||||
method: 'get',
|
||||
params: { startDate, endDate }
|
||||
});
|
||||
};
|
||||
|
||||
// 获取可用的详细时段列表(30分钟一个时段)
|
||||
export const getAvailableDetailSlots = (date: string, timeSlot: string) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/available-detail-slots',
|
||||
method: 'get',
|
||||
params: { date, timeSlot }
|
||||
});
|
||||
};
|
||||
|
||||
// 学生提交预约
|
||||
export const submitAppointment = async (data: XljkConsultationAppointmentForm) => {
|
||||
// 检查是否被限制预约
|
||||
try {
|
||||
const { checkLimitation } = await import('./noshow');
|
||||
if (data.studentId) {
|
||||
const res = await checkLimitation(data.studentId);
|
||||
if (res.code === 200 && res.data && res.data.limited) {
|
||||
return {
|
||||
code: 400,
|
||||
msg: `由于您近期多次未按时到访,暂时无法预约咨询服务。限制将于 ${res.data.expireDateStr} 自动解除。如有特殊情况,请联系心理咨询中心。`,
|
||||
data: null
|
||||
};
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('检查预约限制失败', error);
|
||||
// 检查失败不阻止预约,继续提交
|
||||
}
|
||||
|
||||
// 提交预约申请
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/submit',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 获取我的预约记录(学生用)
|
||||
export const getMyAppointments = (studentId: string | number, forceRefresh: boolean = false) => {
|
||||
let url = `/api/xljk/consultation/appointment/my-appointments/${studentId}`;
|
||||
|
||||
// 强制添加时间戳参数,确保绕过浏览器缓存
|
||||
url += `?_t=${new Date().getTime()}`;
|
||||
|
||||
// 如果需要额外强制刷新(如用户手动点击刷新按钮)
|
||||
if (forceRefresh) {
|
||||
url += `&force=true`;
|
||||
}
|
||||
|
||||
return request({
|
||||
url,
|
||||
method: 'get',
|
||||
headers: {
|
||||
// 禁止所有缓存
|
||||
'Cache-Control': 'no-cache, no-store, must-revalidate',
|
||||
'Pragma': 'no-cache',
|
||||
'Expires': '0'
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
// 记录咨询结果
|
||||
export const recordConsultation = (id: string | number, data: any) => {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/appointment/record-consultation/${id}`,
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
};
|
||||
|
||||
// 获取咨询师选项
|
||||
export const getCounselorOptions = () => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/schedule/options/counselors',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 获取学生信息(通过学号)
|
||||
export const getStudentByNo = (studentNo: string) => {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/student/${studentNo}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 获取院系选项
|
||||
export const getCollegeOptions = () => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/options/colleges',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 获取专业选项
|
||||
export const getMajorOptions = (collegeName?: string) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/options/majors',
|
||||
method: 'get',
|
||||
params: { collegeName }
|
||||
});
|
||||
};
|
||||
|
||||
// 获取班级选项
|
||||
export const getClassOptions = (collegeName?: string, majorName?: string) => {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/appointment/options/classes',
|
||||
method: 'get',
|
||||
params: { collegeName, majorName }
|
||||
});
|
||||
};
|
||||
@@ -0,0 +1,60 @@
|
||||
import request from '@/utils/request';
|
||||
import { NoShowQuery, NoShowVO } from './types';
|
||||
|
||||
/**
|
||||
* 查询未到访记录列表
|
||||
* @param query 查询参数
|
||||
* @returns 未到访记录列表
|
||||
*/
|
||||
export function listNoShow(query: NoShowQuery) {
|
||||
// 创建一个新的查询对象,避免修改原始对象
|
||||
const params = { ...query };
|
||||
|
||||
// 如果状态是'all',表示"全部",则从参数中移除
|
||||
if (params.status === 'all') {
|
||||
delete params.status;
|
||||
}
|
||||
|
||||
return request({
|
||||
url: '/api/xljk/consultation/no-show/list',
|
||||
method: 'get',
|
||||
params
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取未到访记录详情
|
||||
* @param id 未到访记录ID
|
||||
* @returns 未到访记录详情
|
||||
*/
|
||||
export function getNoShow(id: string | number) {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/no-show/${id}`,
|
||||
method: 'get'
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 解除预约限制
|
||||
* @param id 未到访记录ID
|
||||
* @returns 操作结果
|
||||
*/
|
||||
export function releaseNoShowLimitation(id: string | number) {
|
||||
return request({
|
||||
url: `/api/xljk/consultation/no-show/${id}/release`,
|
||||
method: 'put'
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查学生是否被限制预约
|
||||
* @param studentId 学生ID
|
||||
* @returns 限制状态
|
||||
*/
|
||||
export function checkLimitation(studentId: string | number) {
|
||||
return request({
|
||||
url: '/api/xljk/consultation/no-show/check-limitation',
|
||||
method: 'get',
|
||||
params: { studentId }
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,604 @@
|
||||
export interface XljkConsultationScheduleVO {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId: number;
|
||||
|
||||
/**
|
||||
* 咨询师姓名(关联展示字段)
|
||||
*/
|
||||
counselorName?: string;
|
||||
|
||||
/**
|
||||
* 排班日期
|
||||
*/
|
||||
scheduleDate: string;
|
||||
|
||||
/**
|
||||
* 时段类型(0上午 1下午)
|
||||
*/
|
||||
timeSlot: string;
|
||||
|
||||
/**
|
||||
* 开始时间(HH:mm)
|
||||
*/
|
||||
startTime: string;
|
||||
|
||||
/**
|
||||
* 结束时间(HH:mm)
|
||||
*/
|
||||
endTime: string;
|
||||
|
||||
/**
|
||||
* 状态(0正常 1停用)
|
||||
*/
|
||||
status: string;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
createBy: number;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
createTime: string;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
updateBy: number;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
updateTime: string;
|
||||
}
|
||||
|
||||
export interface XljkConsultationScheduleForm extends BaseEntity {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId?: number;
|
||||
|
||||
/**
|
||||
* 排班日期
|
||||
*/
|
||||
scheduleDate?: string;
|
||||
|
||||
/**
|
||||
* 时段类型(0上午 1下午)
|
||||
*/
|
||||
timeSlot?: string;
|
||||
|
||||
/**
|
||||
* 开始时间(HH:mm)
|
||||
*/
|
||||
startTime?: string;
|
||||
|
||||
/**
|
||||
* 结束时间(HH:mm)
|
||||
*/
|
||||
endTime?: string;
|
||||
|
||||
/**
|
||||
* 状态(0正常 1停用)
|
||||
*/
|
||||
status?: string;
|
||||
}
|
||||
|
||||
export interface XljkConsultationScheduleQuery extends PageQuery {
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId?: number;
|
||||
|
||||
/**
|
||||
* 排班日期开始
|
||||
*/
|
||||
beginScheduleDate?: string;
|
||||
|
||||
/**
|
||||
* 排班日期结束
|
||||
*/
|
||||
endScheduleDate?: string;
|
||||
|
||||
/**
|
||||
* 时段类型(0上午 1下午)
|
||||
*/
|
||||
timeSlot?: string;
|
||||
|
||||
/**
|
||||
* 状态(0正常 1停用)
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
export interface XljkConsultationAppointmentVO extends BaseEntity {
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId?: number;
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId?: number;
|
||||
/**
|
||||
* 排班ID
|
||||
*/
|
||||
scheduleId?: number;
|
||||
/**
|
||||
* 预约日期
|
||||
*/
|
||||
appointmentDate?: string;
|
||||
/**
|
||||
* 预约时段
|
||||
*/
|
||||
appointmentTime?: string;
|
||||
/**
|
||||
* 具体预约时间段,如"08:30-09:00"
|
||||
*/
|
||||
appointmentDetailTime?: string;
|
||||
/**
|
||||
* 咨询原因
|
||||
*/
|
||||
reason?: string;
|
||||
/**
|
||||
* 状态(0待咨询 1已完成 2已取消 3未到访)
|
||||
*/
|
||||
status?: number;
|
||||
/**
|
||||
* 实际到访时间
|
||||
*/
|
||||
actualVisitTime?: any;
|
||||
/**
|
||||
* 沟通时长(分钟)
|
||||
*/
|
||||
communicationDuration?: number;
|
||||
/**
|
||||
* 咨询内容
|
||||
*/
|
||||
consultationContent?: string;
|
||||
/**
|
||||
* 咨询师建议
|
||||
*/
|
||||
counselorSuggestion?: string;
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName?: string;
|
||||
/**
|
||||
* 班级
|
||||
*/
|
||||
className?: string;
|
||||
/**
|
||||
* 咨询师姓名
|
||||
*/
|
||||
counselorName?: string;
|
||||
/**
|
||||
* 院系
|
||||
*/
|
||||
collegeName?: string;
|
||||
/**
|
||||
* 专业
|
||||
*/
|
||||
majorName?: string;
|
||||
}
|
||||
|
||||
export interface XljkConsultationAppointmentForm {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
id?: string | number;
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId?: string | number;
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId?: number;
|
||||
/**
|
||||
* 排班ID
|
||||
*/
|
||||
scheduleId?: number;
|
||||
/**
|
||||
* 预约日期
|
||||
*/
|
||||
appointmentDate?: string;
|
||||
/**
|
||||
* 预约时段
|
||||
*/
|
||||
appointmentTime?: string;
|
||||
/**
|
||||
* 具体预约时间段,如"08:30-09:00"
|
||||
*/
|
||||
appointmentDetailTime?: string;
|
||||
/**
|
||||
* 咨询原因
|
||||
*/
|
||||
reason?: string;
|
||||
/**
|
||||
* 状态(0待咨询 1已完成 2已取消 3未到访)
|
||||
*/
|
||||
status?: number;
|
||||
/**
|
||||
* 实际到访时间
|
||||
*/
|
||||
actualVisitTime?: any;
|
||||
/**
|
||||
* 沟通时长(分钟)
|
||||
*/
|
||||
communicationDuration?: number;
|
||||
/**
|
||||
* 咨询内容
|
||||
*/
|
||||
consultationContent?: string;
|
||||
/**
|
||||
* 咨询师建议
|
||||
*/
|
||||
counselorSuggestion?: string;
|
||||
}
|
||||
|
||||
export interface XljkConsultationAppointmentQuery extends PageQuery {
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId?: number;
|
||||
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName?: string;
|
||||
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
|
||||
/**
|
||||
* 院系
|
||||
*/
|
||||
collegeName?: string;
|
||||
|
||||
/**
|
||||
* 专业
|
||||
*/
|
||||
majorName?: string;
|
||||
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId?: number;
|
||||
|
||||
/**
|
||||
* 预约日期开始
|
||||
*/
|
||||
beginAppointmentDate?: string;
|
||||
|
||||
/**
|
||||
* 预约日期结束
|
||||
*/
|
||||
endAppointmentDate?: string;
|
||||
|
||||
/**
|
||||
* 状态(0待咨询 1已完成 2已取消 3未到访)
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
export interface AvailableTimeSlot {
|
||||
/**
|
||||
* 预约时段ID
|
||||
*/
|
||||
scheduleId: number;
|
||||
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
counselorId: number;
|
||||
|
||||
/**
|
||||
* 咨询师姓名
|
||||
*/
|
||||
counselorName?: string;
|
||||
|
||||
/**
|
||||
* 日期
|
||||
*/
|
||||
date: string;
|
||||
|
||||
/**
|
||||
* 时段类型(0上午 1下午)
|
||||
*/
|
||||
timeSlot: string;
|
||||
|
||||
/**
|
||||
* 开始时间
|
||||
*/
|
||||
startTime: string;
|
||||
|
||||
/**
|
||||
* 结束时间
|
||||
*/
|
||||
endTime: string;
|
||||
|
||||
/**
|
||||
* 是否全部约满
|
||||
*/
|
||||
allBooked?: boolean;
|
||||
|
||||
/**
|
||||
* 可用数量
|
||||
*/
|
||||
availableCount?: number;
|
||||
|
||||
/**
|
||||
* 是否已过期
|
||||
*/
|
||||
isExpired?: boolean;
|
||||
|
||||
/**
|
||||
* 日历事件标题
|
||||
*/
|
||||
title?: string;
|
||||
|
||||
/**
|
||||
* 日历事件开始时间
|
||||
*/
|
||||
start?: string;
|
||||
|
||||
/**
|
||||
* 日历事件结束时间
|
||||
*/
|
||||
end?: string;
|
||||
}
|
||||
|
||||
export interface TimeSlotDetail {
|
||||
/**
|
||||
* 开始时间(HH:mm)
|
||||
*/
|
||||
startTime: string;
|
||||
|
||||
/**
|
||||
* 结束时间(HH:mm)
|
||||
*/
|
||||
endTime: string;
|
||||
|
||||
/**
|
||||
* 是否已预约
|
||||
*/
|
||||
isBooked: boolean;
|
||||
|
||||
/**
|
||||
* 是否已过期
|
||||
*/
|
||||
isExpired: boolean;
|
||||
|
||||
/**
|
||||
* 完整时段表示(如"08:30-09:00")
|
||||
*/
|
||||
timeSlot: string;
|
||||
}
|
||||
|
||||
export interface CounselorOption {
|
||||
/**
|
||||
* 咨询师ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 咨询师姓名
|
||||
*/
|
||||
name: string;
|
||||
}
|
||||
|
||||
// 预约时段汇总视图对象
|
||||
export interface XljkConsultationScheduleSummaryVO {
|
||||
id: number;
|
||||
tenantId: string;
|
||||
createDept: number;
|
||||
createBy: number;
|
||||
createTime: string;
|
||||
updateBy: number;
|
||||
updateTime: string;
|
||||
deleted: number;
|
||||
counselorId: number;
|
||||
counselorName: string;
|
||||
dateRange: string;
|
||||
morningEnabled: boolean;
|
||||
morningTime: string;
|
||||
afternoonEnabled: boolean;
|
||||
afternoonTime: string;
|
||||
status: string;
|
||||
scheduleCount: number;
|
||||
batchId: string;
|
||||
}
|
||||
|
||||
// 院系选项
|
||||
export interface CollegeOption {
|
||||
/**
|
||||
* 院系ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 院系名称
|
||||
*/
|
||||
name: string;
|
||||
}
|
||||
|
||||
// 专业选项
|
||||
export interface MajorOption {
|
||||
/**
|
||||
* 专业ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 专业名称
|
||||
*/
|
||||
name: string;
|
||||
}
|
||||
|
||||
// 班级选项
|
||||
export interface ClassOption {
|
||||
/**
|
||||
* 班级ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 班级名称
|
||||
*/
|
||||
name: string;
|
||||
}
|
||||
|
||||
// 未到访记录查询参数
|
||||
export interface NoShowQuery extends PageQuery {
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName?: string;
|
||||
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
|
||||
/**
|
||||
* 状态(0生效中 1已过期 2已解除 'all'全部)
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 未到访日期开始
|
||||
*/
|
||||
startDate?: string;
|
||||
|
||||
/**
|
||||
* 未到访日期结束
|
||||
*/
|
||||
endDate?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
||||
|
||||
// 未到访记录VO
|
||||
export interface NoShowVO {
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 学生ID
|
||||
*/
|
||||
studentId: string | number;
|
||||
|
||||
/**
|
||||
* 学生姓名
|
||||
*/
|
||||
studentName?: string;
|
||||
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
studentNo?: string;
|
||||
|
||||
/**
|
||||
* 院系
|
||||
*/
|
||||
collegeName?: string;
|
||||
|
||||
/**
|
||||
* 专业
|
||||
*/
|
||||
majorName?: string;
|
||||
|
||||
/**
|
||||
* 班级
|
||||
*/
|
||||
className?: string;
|
||||
|
||||
/**
|
||||
* 咨询师名称
|
||||
*/
|
||||
counselorName?: string;
|
||||
|
||||
/**
|
||||
* 预约日期
|
||||
*/
|
||||
appointmentDate?: string;
|
||||
|
||||
/**
|
||||
* 预约时段
|
||||
*/
|
||||
appointmentDetailTime?: string;
|
||||
|
||||
/**
|
||||
* 咨询原因
|
||||
*/
|
||||
reason?: string;
|
||||
|
||||
/**
|
||||
* 预约记录ID
|
||||
*/
|
||||
appointmentId: string | number;
|
||||
|
||||
/**
|
||||
* 未到访日期
|
||||
*/
|
||||
noShowDate: string;
|
||||
|
||||
/**
|
||||
* 限制到期日
|
||||
*/
|
||||
expireDate?: string;
|
||||
|
||||
/**
|
||||
* 状态(0生效中 1已过期 2已解除)
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
createTime?: string;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
updateTime?: string;
|
||||
}
|
||||
@@ -15,7 +15,7 @@ import {
|
||||
// 查询心理健康测评列表
|
||||
export const listEvaluation = (query: XljkEvaluationQuery) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/list',
|
||||
url: '/api/xljk/evaluation/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
@@ -24,7 +24,7 @@ export const listEvaluation = (query: XljkEvaluationQuery) => {
|
||||
// 查询心理健康测评详细信息
|
||||
export const getEvaluation = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xljk/evaluation/${id}`,
|
||||
url: `/api/xljk/evaluation/${id}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
@@ -45,7 +45,7 @@ export const addEvaluation = (data: XljkEvaluationForm) => {
|
||||
}
|
||||
|
||||
return request({
|
||||
url: '/xljk/evaluation',
|
||||
url: '/api/xljk/evaluation',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
@@ -54,7 +54,7 @@ export const addEvaluation = (data: XljkEvaluationForm) => {
|
||||
// 修改心理健康测评
|
||||
export const updateEvaluation = (data: XljkEvaluationForm) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation',
|
||||
url: '/api/xljk/evaluation',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
@@ -63,7 +63,7 @@ export const updateEvaluation = (data: XljkEvaluationForm) => {
|
||||
// 删除心理健康测评
|
||||
export const delEvaluation = (ids: string | number | Array<string | number>) => {
|
||||
return request({
|
||||
url: `/xljk/evaluation/${typeof ids === 'object' ? ids.join(',') : ids}`,
|
||||
url: `/api/xljk/evaluation/${typeof ids === 'object' ? ids.join(',') : ids}`,
|
||||
method: 'delete'
|
||||
});
|
||||
};
|
||||
@@ -71,7 +71,7 @@ export const delEvaluation = (ids: string | number | Array<string | number>) =>
|
||||
// 获取院系选项
|
||||
export const getDepartmentOptions = () => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/options/department',
|
||||
url: '/api/xljk/evaluation/options/department',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
@@ -79,7 +79,7 @@ export const getDepartmentOptions = () => {
|
||||
// 获取院系选项(新接口)
|
||||
export const getCollegeOptions = () => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/options/colleges',
|
||||
url: '/api/xljk/evaluation/options/colleges',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
@@ -87,7 +87,7 @@ export const getCollegeOptions = () => {
|
||||
// 获取专业选项
|
||||
export const getMajorOptions = (collegeName?: string) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/options/majors',
|
||||
url: '/api/xljk/evaluation/options/majors',
|
||||
method: 'get',
|
||||
params: { collegeName }
|
||||
});
|
||||
@@ -96,7 +96,7 @@ export const getMajorOptions = (collegeName?: string) => {
|
||||
// 获取班级选项
|
||||
export const getClassOptions = (collegeName?: string, majorName?: string) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/options/classes',
|
||||
url: '/api/xljk/evaluation/options/classes',
|
||||
method: 'get',
|
||||
params: { collegeName, majorName }
|
||||
});
|
||||
@@ -105,7 +105,7 @@ export const getClassOptions = (collegeName?: string, majorName?: string) => {
|
||||
// 获取班级学生列表
|
||||
export const getStudentsByClass = (collegeName?: string, majorName?: string, className?: string) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/students',
|
||||
url: '/api/xljk/evaluation/students',
|
||||
method: 'get',
|
||||
params: { collegeName, majorName, className }
|
||||
});
|
||||
@@ -114,23 +114,23 @@ export const getStudentsByClass = (collegeName?: string, majorName?: string, cla
|
||||
// 获取学期选项
|
||||
export const getSemesterOptions = () => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/options/semester',
|
||||
url: '/api/xljk/evaluation/options/semester',
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
|
||||
// 发布测评
|
||||
// 发布测评(已废弃,改为提交功能)
|
||||
export const publishEvaluation = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xljk/evaluation/${id}/publish`,
|
||||
url: `/api/xljk/evaluation/${id}/publish`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
|
||||
// 完成测评
|
||||
// 提交测评
|
||||
export const completeEvaluation = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xljk/evaluation/${id}/complete`,
|
||||
url: `/api/xljk/evaluation/${id}/complete`,
|
||||
method: 'put'
|
||||
});
|
||||
};
|
||||
@@ -138,7 +138,7 @@ export const completeEvaluation = (id: string | number) => {
|
||||
// 获取测评统计数据
|
||||
export const getEvaluationStatistics = (id: string | number) => {
|
||||
return request({
|
||||
url: `/xljk/evaluation/${id}/statistics`,
|
||||
url: `/api/xljk/evaluation/${id}/statistics`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
@@ -146,7 +146,7 @@ export const getEvaluationStatistics = (id: string | number) => {
|
||||
// 获取重点关注学生统计
|
||||
export const getFocusStudentsStatistics = (query: XljkEvaluationQuery) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/statistics/focus',
|
||||
url: '/api/xljk/evaluation/statistics/focus',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
@@ -155,7 +155,7 @@ export const getFocusStudentsStatistics = (query: XljkEvaluationQuery) => {
|
||||
// 查询测评明细列表
|
||||
export const listEvaluationDetail = (query: XljkEvaluationDetailQuery) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/detail/list',
|
||||
url: '/api/xljk/evaluation/detail/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
@@ -164,7 +164,7 @@ export const listEvaluationDetail = (query: XljkEvaluationDetailQuery) => {
|
||||
// 获取测评明细列表
|
||||
export const getEvaluationDetailsByEvaluationId = (evaluationId: string | number) => {
|
||||
return request({
|
||||
url: `/xljk/evaluation/detail/evaluation/${evaluationId}`,
|
||||
url: `/api/xljk/evaluation/detail/evaluation/${evaluationId}`,
|
||||
method: 'get'
|
||||
});
|
||||
};
|
||||
@@ -172,7 +172,7 @@ export const getEvaluationDetailsByEvaluationId = (evaluationId: string | number
|
||||
// 批量新增测评明细
|
||||
export const batchAddEvaluationDetails = (data: XljkEvaluationDetailForm[]) => {
|
||||
return request({
|
||||
url: '/xljk/evaluation/detail/batch',
|
||||
url: '/api/xljk/evaluation/detail/batch',
|
||||
method: 'post',
|
||||
data: data
|
||||
});
|
||||
@@ -184,7 +184,7 @@ export const batchUpdateMentalStatus = (data: XljkEvaluationDetailForm[]) => {
|
||||
console.log('批量更新数据 - 第一条记录evaluationId:', data[0]?.evaluationId);
|
||||
|
||||
return request({
|
||||
url: '/xljk/evaluation/detail/batch/mentalStatus',
|
||||
url: '/api/xljk/evaluation/detail/batch/mentalStatus',
|
||||
method: 'put',
|
||||
data: data
|
||||
});
|
||||
|
||||
@@ -45,7 +45,7 @@ export interface XljkEvaluationVO {
|
||||
semester: string;
|
||||
|
||||
/**
|
||||
* 状态(0-草稿,1-已发布,2-已完成)
|
||||
* 状态(0-草稿,2-已完成)
|
||||
*/
|
||||
status: string;
|
||||
|
||||
@@ -137,7 +137,7 @@ export interface XljkEvaluationForm extends BaseEntity {
|
||||
semester?: string;
|
||||
|
||||
/**
|
||||
* 状态(0-草稿,1-已发布,2-已完成)
|
||||
* 状态(0-草稿,2-已完成)
|
||||
*/
|
||||
status?: string;
|
||||
|
||||
@@ -443,6 +443,11 @@ export interface StudentInfo {
|
||||
}
|
||||
|
||||
export interface CollegeOption {
|
||||
/**
|
||||
* 院系ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 院系名称
|
||||
*/
|
||||
@@ -450,6 +455,11 @@ export interface CollegeOption {
|
||||
}
|
||||
|
||||
export interface MajorOption {
|
||||
/**
|
||||
* 专业ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 专业名称
|
||||
*/
|
||||
@@ -457,6 +467,11 @@ export interface MajorOption {
|
||||
}
|
||||
|
||||
export interface ClassOption {
|
||||
/**
|
||||
* 班级ID
|
||||
*/
|
||||
id: number;
|
||||
|
||||
/**
|
||||
* 班级名称
|
||||
*/
|
||||
|
||||
Reference in new issue
Block a user