You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

204 lines
6.0 KiB

/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_CoursesDTO_ } from '../models/BaseResponse_CoursesDTO_';
import type { BaseResponse_PageDTO_CoursesVO_ } from '../models/BaseResponse_PageDTO_CoursesVO_';
import type { BaseResponse_string_ } from '../models/BaseResponse_string_';
import type { CourseObjectivesDTO } from '../models/CourseObjectivesDTO';
import type { CoursesDTO } from '../models/CoursesDTO';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class Service {
/**
* 编辑分项目标
* @param courseObjectivesDto courseObjectivesDTO
* @returns BaseResponse_string_ OK
* @returns any Created
* @throws ApiError
*/
public static updateCourseObjectivesUsingPut(
courseObjectivesDto: CourseObjectivesDTO,
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/course_objectives',
body: courseObjectivesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* 新增分项目标-默认第一个必须添加思政目标
* @param courseObjectivesDto courseObjectivesDTO
* @returns BaseResponse_string_ OK
* @returns any Created
* @throws ApiError
*/
public static saveCourseObjectivesUsingPost(
courseObjectivesDto: CourseObjectivesDTO,
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_objectives/addobjectives',
body: courseObjectivesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* 删除分项目标-只能最后一个删除思政目标
* @param id id
* @returns BaseResponse_string_ OK
* @throws ApiError
*/
public static deleteCourseObjectivesByIdsUsingDelete(
id: string,
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/course_objectives/{id}',
path: {
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
});
}
/**
* 根据id修改课程
* @param coursesDto coursesDTO
* @returns BaseResponse_string_ OK
* @returns any Created
* @throws ApiError
*/
public static editCourseUsingPut(
coursesDto: CoursesDTO,
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/coursesteacher',
body: coursesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* 新增课程--同步新增课程的总体目标
* @param coursesDto coursesDTO
* @param teacherId teacherId
* @returns BaseResponse_string_ OK
* @returns any Created
* @throws ApiError
*/
public static saveCourseUsingPost(
coursesDto: CoursesDTO,
teacherId: string,
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/coursesteacher/addcourse',
query: {
'teacherId': teacherId,
},
body: coursesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* 查询课程列表
* @param teacherId teacherId
* @param isAsc 是否升序
* @param name 课程名称关键字
* @param pageNo 页码
* @param pageSize 页码
* @param sortBy 排序字段
* @returns BaseResponse_PageDTO_CoursesVO_ OK
* @throws ApiError
*/
public static getCoursesUsingGet(
teacherId: string,
isAsc?: boolean,
name?: string,
pageNo?: number,
pageSize?: number,
sortBy?: string,
): CancelablePromise<BaseResponse_PageDTO_CoursesVO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/coursesteacher/page',
query: {
'isAsc': isAsc,
'name': name,
'pageNo': pageNo,
'pageSize': pageSize,
'sortBy': sortBy,
'teacherId': teacherId,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* 根据ids批量删除课程
* @param ids ids
* @returns BaseResponse_string_ OK
* @throws ApiError
*/
public static deleteCoursesUsingDelete(
ids: string,
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/coursesteacher/{ids}',
path: {
'ids': ids,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
});
}
/**
* 根据id查询课程
* @param id id
* @returns BaseResponse_CoursesDTO_ OK
* @throws ApiError
*/
public static getByIdCourseUsingGet(
id: string,
): CancelablePromise<BaseResponse_CoursesDTO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/coursesteacher/{id}',
path: {
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
}