develoop
yh 5 months ago
parent 695d72d132
commit f39d5d0cd6
  1. 2
      .env.production
  2. 1
      .env_1.production
  3. BIN
      dist.zip
  4. 34
      generated/core/ApiError.ts
  5. 31
      generated/core/ApiRequestOptions.ts
  6. 12
      generated/core/ApiResult.ts
  7. 105
      generated/core/CancelablePromise.ts
  8. 36
      generated/core/OpenAPI.ts
  9. 299
      generated/core/request.ts
  10. 139
      generated/index.ts
  11. 9
      generated/models/BaseResponse.ts
  12. 11
      generated/models/BaseResponse_CoursesDTO_.ts
  13. 11
      generated/models/BaseResponse_List_CourseObjectivesTreeVO_.ts
  14. 11
      generated/models/BaseResponse_List_CourseResources_.ts
  15. 11
      generated/models/BaseResponse_List_LearningRecords_.ts
  16. 11
      generated/models/BaseResponse_List_ObjectivesType_.ts
  17. 11
      generated/models/BaseResponse_List_TeacherInfVO_.ts
  18. 9
      generated/models/BaseResponse_Map_string_object_.ts
  19. 11
      generated/models/BaseResponse_ObjectiveContentKnowVO_.ts
  20. 11
      generated/models/BaseResponse_ObjectiveContents_.ts
  21. 11
      generated/models/BaseResponse_PageDTO_CoursesVO_.ts
  22. 11
      generated/models/BaseResponse_Page_.ts
  23. 11
      generated/models/BaseResponse_Page_CourseFavourDetailVO_.ts
  24. 11
      generated/models/BaseResponse_Page_CourseResources_.ts
  25. 9
      generated/models/BaseResponse_boolean_.ts
  26. 9
      generated/models/BaseResponse_long_.ts
  27. 9
      generated/models/BaseResponse_string_.ts
  28. 9
      generated/models/CommonResult.ts
  29. 11
      generated/models/CommonResult_UmsAdmin_.ts
  30. 9
      generated/models/CommonResult_string_.ts
  31. 7
      generated/models/CourseFavourAddRequest.ts
  32. 5
      generated/models/CourseFavourAllRequest.ts
  33. 15
      generated/models/CourseFavourDetailVO.ts
  34. 13
      generated/models/CourseFavourQueryRequest.ts
  35. 11
      generated/models/CourseObjectivesDTO.ts
  36. 25
      generated/models/CourseObjectivesTreeVO.ts
  37. 19
      generated/models/CourseResources.ts
  38. 7
      generated/models/CourseThumbAddRequest.ts
  39. 33
      generated/models/CoursesDTO.ts
  40. 23
      generated/models/CoursesVO.ts
  41. 14
      generated/models/Know.ts
  42. 9
      generated/models/KnowFavourAddRequest.ts
  43. 8
      generated/models/KnowQueryRequest.ts
  44. 13
      generated/models/KnowRequest.ts
  45. 7
      generated/models/KnowThumbAddRequest.ts
  46. 14
      generated/models/KnowupdateRequest.ts
  47. 33
      generated/models/LearningRecords.ts
  48. 9
      generated/models/ObjectiveContentKnowDTO.ts
  49. 13
      generated/models/ObjectiveContentKnowVO.ts
  50. 9
      generated/models/ObjectiveContents_.ts
  51. 7
      generated/models/ObjectivesType_.ts
  52. 7
      generated/models/OrderItem.ts
  53. 25
      generated/models/Page.ts
  54. 11
      generated/models/PageDTO_CoursesVO_.ts
  55. 27
      generated/models/Page_CourseFavourDetailVO_.ts
  56. 27
      generated/models/Page_CourseResources_.ts
  57. 7
      generated/models/ResourceFavourAddRequest.ts
  58. 15
      generated/models/ResourceFavourQueryRequest.ts
  59. 7
      generated/models/ResourceThumbAddRequest.ts
  60. 9
      generated/models/StudentCoursesDTO.ts
  61. 7
      generated/models/TeacherInfVO.ts
  62. 19
      generated/models/UmsAdmin.ts
  63. 13
      generated/models/UmsAdminParam.ts
  64. 41
      generated/models/UmsStudentAndTeacherDTO.ts
  65. 9
      generated/models/UpdateAdminPasswordParam.ts
  66. 38
      generated/services/CourseResourceControllerService.ts
  67. 24
      generated/services/FavourInformationControllerService.ts
  68. 97
      generated/services/KnowControllerService.ts
  69. 38
      generated/services/LearningRecordsControllerService.ts
  70. 18
      generated/services/ResourceControllerService.ts
  71. 34
      generated/services/SeCourseFavourControllerService.ts
  72. 20
      generated/services/SeCourseThumbControllerService.ts
  73. 14
      generated/services/SeKnowFavourControllerService.ts
  74. 14
      generated/services/SeKnowThumbControllerService.ts
  75. 22
      generated/services/SeResourceFavourControllerService.ts
  76. 14
      generated/services/SeResourceThumbControllerService.ts
  77. 164
      generated/services/Service.ts
  78. 78
      generated/services/UmsAdminControllerService.ts
  79. 2
      package.json
  80. 4
      src/api/record.js
  81. 16
      src/api/user/crouse.js
  82. 6
      src/api/user/index.ts
  83. 18
      src/api/user/user.js

@ -1,3 +1,3 @@
NODE_ENV = 'production'
VITE_APP_TITLE = '无糖运营平台'
VITE_APP_BASE_API = '/prod-api'
# VITE_APP_BASE_API = '/prod-api'

@ -1,3 +1,2 @@
NODE_ENV = 'production'
VITE_APP_TITLE = '无糖运营平台'
VITE_APP_BASE_API = '/prod-api'

Binary file not shown.

@ -2,28 +2,24 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ApiRequestOptions } from './ApiRequestOptions'
import type { ApiResult } from './ApiResult'
import type { ApiRequestOptions } from './ApiRequestOptions';
import type { ApiResult } from './ApiResult';
export class ApiError extends Error {
public readonly url: string
public readonly status: number
public readonly statusText: string
public readonly body: any
public readonly request: ApiRequestOptions
public readonly url: string;
public readonly status: number;
public readonly statusText: string;
public readonly body: any;
public readonly request: ApiRequestOptions;
constructor(
request: ApiRequestOptions,
response: ApiResult,
message: string,
) {
super(message)
constructor(request: ApiRequestOptions, response: ApiResult, message: string) {
super(message);
this.name = 'ApiError'
this.url = response.url
this.status = response.status
this.statusText = response.statusText
this.body = response.body
this.request = request
this.name = 'ApiError';
this.url = response.url;
this.status = response.status;
this.statusText = response.statusText;
this.body = response.body;
this.request = request;
}
}

@ -3,22 +3,15 @@
/* tslint:disable */
/* eslint-disable */
export type ApiRequestOptions = {
readonly method:
| 'GET'
| 'PUT'
| 'POST'
| 'DELETE'
| 'OPTIONS'
| 'HEAD'
| 'PATCH'
readonly url: string
readonly path?: Record<string, any>
readonly cookies?: Record<string, any>
readonly headers?: Record<string, any>
readonly query?: Record<string, any>
readonly formData?: Record<string, any>
readonly body?: any
readonly mediaType?: string
readonly responseHeader?: string
readonly errors?: Record<number, string>
}
readonly method: 'GET' | 'PUT' | 'POST' | 'DELETE' | 'OPTIONS' | 'HEAD' | 'PATCH';
readonly url: string;
readonly path?: Record<string, any>;
readonly cookies?: Record<string, any>;
readonly headers?: Record<string, any>;
readonly query?: Record<string, any>;
readonly formData?: Record<string, any>;
readonly body?: any;
readonly mediaType?: string;
readonly responseHeader?: string;
readonly errors?: Record<number, string>;
};

@ -3,9 +3,9 @@
/* tslint:disable */
/* eslint-disable */
export type ApiResult = {
readonly url: string
readonly ok: boolean
readonly status: number
readonly statusText: string
readonly body: any
}
readonly url: string;
readonly ok: boolean;
readonly status: number;
readonly statusText: string;
readonly body: any;
};

@ -3,128 +3,129 @@
/* tslint:disable */
/* eslint-disable */
export class CancelError extends Error {
constructor(message: string) {
super(message)
this.name = 'CancelError'
super(message);
this.name = 'CancelError';
}
public get isCancelled(): boolean {
return true
return true;
}
}
export interface OnCancel {
readonly isResolved: boolean
readonly isRejected: boolean
readonly isCancelled: boolean
readonly isResolved: boolean;
readonly isRejected: boolean;
readonly isCancelled: boolean;
(cancelHandler: () => void): void
(cancelHandler: () => void): void;
}
export class CancelablePromise<T> implements Promise<T> {
#isResolved: boolean
#isRejected: boolean
#isCancelled: boolean
readonly #cancelHandlers: (() => void)[]
readonly #promise: Promise<T>
#resolve?: (value: T | PromiseLike<T>) => void
#reject?: (reason?: any) => void
#isResolved: boolean;
#isRejected: boolean;
#isCancelled: boolean;
readonly #cancelHandlers: (() => void)[];
readonly #promise: Promise<T>;
#resolve?: (value: T | PromiseLike<T>) => void;
#reject?: (reason?: any) => void;
constructor(
executor: (
resolve: (value: T | PromiseLike<T>) => void,
reject: (reason?: any) => void,
onCancel: OnCancel,
) => void,
onCancel: OnCancel
) => void
) {
this.#isResolved = false
this.#isRejected = false
this.#isCancelled = false
this.#cancelHandlers = []
this.#isResolved = false;
this.#isRejected = false;
this.#isCancelled = false;
this.#cancelHandlers = [];
this.#promise = new Promise<T>((resolve, reject) => {
this.#resolve = resolve
this.#reject = reject
this.#resolve = resolve;
this.#reject = reject;
const onResolve = (value: T | PromiseLike<T>): void => {
if (this.#isResolved || this.#isRejected || this.#isCancelled) {
return
}
this.#isResolved = true
if (this.#resolve) this.#resolve(value)
return;
}
this.#isResolved = true;
if (this.#resolve) this.#resolve(value);
};
const onReject = (reason?: any): void => {
if (this.#isResolved || this.#isRejected || this.#isCancelled) {
return
}
this.#isRejected = true
if (this.#reject) this.#reject(reason)
return;
}
this.#isRejected = true;
if (this.#reject) this.#reject(reason);
};
const onCancel = (cancelHandler: () => void): void => {
if (this.#isResolved || this.#isRejected || this.#isCancelled) {
return
}
this.#cancelHandlers.push(cancelHandler)
return;
}
this.#cancelHandlers.push(cancelHandler);
};
Object.defineProperty(onCancel, 'isResolved', {
get: (): boolean => this.#isResolved,
})
});
Object.defineProperty(onCancel, 'isRejected', {
get: (): boolean => this.#isRejected,
})
});
Object.defineProperty(onCancel, 'isCancelled', {
get: (): boolean => this.#isCancelled,
})
});
return executor(onResolve, onReject, onCancel as OnCancel)
})
return executor(onResolve, onReject, onCancel as OnCancel);
});
}
get [Symbol.toStringTag]() {
return 'Cancellable Promise'
return "Cancellable Promise";
}
public then<TResult1 = T, TResult2 = never>(
onFulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | null,
onRejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null,
onRejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null
): Promise<TResult1 | TResult2> {
return this.#promise.then(onFulfilled, onRejected)
return this.#promise.then(onFulfilled, onRejected);
}
public catch<TResult = never>(
onRejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null,
onRejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null
): Promise<T | TResult> {
return this.#promise.catch(onRejected)
return this.#promise.catch(onRejected);
}
public finally(onFinally?: (() => void) | null): Promise<T> {
return this.#promise.finally(onFinally)
return this.#promise.finally(onFinally);
}
public cancel(): void {
if (this.#isResolved || this.#isRejected || this.#isCancelled) {
return
return;
}
this.#isCancelled = true
this.#isCancelled = true;
if (this.#cancelHandlers.length) {
try {
for (const cancelHandler of this.#cancelHandlers) {
cancelHandler()
cancelHandler();
}
} catch (error) {
console.warn('Cancellation threw an error', error)
return
console.warn('Cancellation threw an error', error);
return;
}
}
this.#cancelHandlers.length = 0
if (this.#reject) this.#reject(new CancelError('Request aborted'))
this.#cancelHandlers.length = 0;
if (this.#reject) this.#reject(new CancelError('Request aborted'));
}
public get isCancelled(): boolean {
return this.#isCancelled
return this.#isCancelled;
}
}

@ -2,35 +2,31 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ApiRequestOptions } from './ApiRequestOptions';
import type { ApiRequestOptions } from './ApiRequestOptions'
// @ts-expect-error
import { GET_TKOEN } from '@/utils/token'
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>
type Headers = Record<string, string>
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>;
type Headers = Record<string, string>;
export type OpenAPIConfig = {
BASE: string
VERSION: string
WITH_CREDENTIALS: boolean
CREDENTIALS: 'include' | 'omit' | 'same-origin'
TOKEN?: string | Resolver<string> | undefined
USERNAME?: string | Resolver<string> | undefined
PASSWORD?: string | Resolver<string> | undefined
HEADERS?: Headers | Resolver<Headers> | undefined
ENCODE_PATH?: ((path: string) => string) | undefined
}
BASE: string;
VERSION: string;
WITH_CREDENTIALS: boolean;
CREDENTIALS: 'include' | 'omit' | 'same-origin';
TOKEN?: string | Resolver<string> | undefined;
USERNAME?: string | Resolver<string> | undefined;
PASSWORD?: string | Resolver<string> | undefined;
HEADERS?: Headers | Resolver<Headers> | undefined;
ENCODE_PATH?: ((path: string) => string) | undefined;
};
export const OpenAPI: OpenAPIConfig = {
BASE: 'http://39.106.16.162:8080',
VERSION: '1.0.0',
WITH_CREDENTIALS: false,
CREDENTIALS: 'include',
TOKEN: GET_TKOEN('TOKEN') || undefined,
TOKEN: undefined,
USERNAME: undefined,
PASSWORD: undefined,
HEADERS: {
Authorization: 'Bearer ' + GET_TKOEN('TOKEN'),
},
HEADERS: undefined,
ENCODE_PATH: undefined,
}
};

@ -2,35 +2,28 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import axios from 'axios'
import type {
AxiosError,
AxiosRequestConfig,
AxiosResponse,
AxiosInstance,
} from 'axios'
import FormData from 'form-data'
import { ApiError } from './ApiError'
import type { ApiRequestOptions } from './ApiRequestOptions'
import type { ApiResult } from './ApiResult'
import { CancelablePromise } from './CancelablePromise'
import type { OnCancel } from './CancelablePromise'
import type { OpenAPIConfig } from './OpenAPI'
export const isDefined = <T>(
value: T | null | undefined,
): value is Exclude<T, null | undefined> => {
return value !== undefined && value !== null
}
import axios from 'axios';
import type { AxiosError, AxiosRequestConfig, AxiosResponse, AxiosInstance } from 'axios';
import FormData from 'form-data';
import { ApiError } from './ApiError';
import type { ApiRequestOptions } from './ApiRequestOptions';
import type { ApiResult } from './ApiResult';
import { CancelablePromise } from './CancelablePromise';
import type { OnCancel } from './CancelablePromise';
import type { OpenAPIConfig } from './OpenAPI';
export const isDefined = <T>(value: T | null | undefined): value is Exclude<T, null | undefined> => {
return value !== undefined && value !== null;
};
export const isString = (value: any): value is string => {
return typeof value === 'string'
}
return typeof value === 'string';
};
export const isStringWithValue = (value: any): value is string => {
return isString(value) && value !== ''
}
return isString(value) && value !== '';
};
export const isBlob = (value: any): value is Blob => {
return (
@ -42,134 +35,124 @@ export const isBlob = (value: any): value is Blob => {
typeof value.constructor.name === 'string' &&
/^(Blob|File)$/.test(value.constructor.name) &&
/^(Blob|File)$/.test(value[Symbol.toStringTag])
)
}
);
};
export const isFormData = (value: any): value is FormData => {
return value instanceof FormData
}
return value instanceof FormData;
};
export const isSuccess = (status: number): boolean => {
return status >= 200 && status < 300
}
return status >= 200 && status < 300;
};
export const base64 = (str: string): string => {
try {
return btoa(str)
return btoa(str);
} catch (err) {
// @ts-ignore
return Buffer.from(str).toString('base64')
return Buffer.from(str).toString('base64');
}
}
};
export const getQueryString = (params: Record<string, any>): string => {
const qs: string[] = []
const qs: string[] = [];
const append = (key: string, value: any) => {
qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`)
}
qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);
};
const process = (key: string, value: any) => {
if (isDefined(value)) {
if (Array.isArray(value)) {
value.forEach((v) => {
process(key, v)
})
value.forEach(v => {
process(key, v);
});
} else if (typeof value === 'object') {
Object.entries(value).forEach(([k, v]) => {
process(`${key}[${k}]`, v)
})
process(`${key}[${k}]`, v);
});
} else {
append(key, value)
}
append(key, value);
}
}
};
Object.entries(params).forEach(([key, value]) => {
process(key, value)
})
process(key, value);
});
if (qs.length > 0) {
return `?${qs.join('&')}`
return `?${qs.join('&')}`;
}
return ''
}
return '';
};
const getUrl = (config: OpenAPIConfig, options: ApiRequestOptions): string => {
const encoder = config.ENCODE_PATH || encodeURI
const encoder = config.ENCODE_PATH || encodeURI;
const path = options.url
.replace('{api-version}', config.VERSION)
.replace(/{(.*?)}/g, (substring: string, group: string) => {
if (options.path?.hasOwnProperty(group)) {
return encoder(String(options.path[group]))
return encoder(String(options.path[group]));
}
return substring
})
return substring;
});
const url = `${config.BASE}${path}`
const url = `${config.BASE}${path}`;
if (options.query) {
return `${url}${getQueryString(options.query)}`
return `${url}${getQueryString(options.query)}`;
}
return url
}
return url;
};
export const getFormData = (
options: ApiRequestOptions,
): FormData | undefined => {
export const getFormData = (options: ApiRequestOptions): FormData | undefined => {
if (options.formData) {
const formData = new FormData()
const formData = new FormData();
const process = (key: string, value: any) => {
if (isString(value) || isBlob(value)) {
formData.append(key, value)
formData.append(key, value);
} else {
formData.append(key, JSON.stringify(value))
}
formData.append(key, JSON.stringify(value));
}
};
Object.entries(options.formData)
.filter(([_, value]) => isDefined(value))
.forEach(([key, value]) => {
if (Array.isArray(value)) {
value.forEach((v) => process(key, v))
value.forEach(v => process(key, v));
} else {
process(key, value)
process(key, value);
}
})
});
return formData
return formData;
}
return undefined
}
return undefined;
};
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>;
export const resolve = async <T>(
options: ApiRequestOptions,
resolver?: T | Resolver<T>,
): Promise<T | undefined> => {
export const resolve = async <T>(options: ApiRequestOptions, resolver?: T | Resolver<T>): Promise<T | undefined> => {
if (typeof resolver === 'function') {
return (resolver as Resolver<T>)(options)
return (resolver as Resolver<T>)(options);
}
return resolver
}
return resolver;
};
export const getHeaders = async (
config: OpenAPIConfig,
options: ApiRequestOptions,
formData?: FormData,
): Promise<Record<string, string>> => {
export const getHeaders = async (config: OpenAPIConfig, options: ApiRequestOptions, formData?: FormData): Promise<Record<string, string>> => {
const [token, username, password, additionalHeaders] = await Promise.all([
resolve(options, config.TOKEN),
resolve(options, config.USERNAME),
resolve(options, config.PASSWORD),
resolve(options, config.HEADERS),
])
]);
const formHeaders =
(typeof formData?.getHeaders === 'function' && formData?.getHeaders()) || {}
const formHeaders = typeof formData?.getHeaders === 'function' && formData?.getHeaders() || {}
const headers = Object.entries({
Accept: 'application/json',
@ -178,44 +161,41 @@ export const getHeaders = async (
...formHeaders,
})
.filter(([_, value]) => isDefined(value))
.reduce(
(headers, [key, value]) => ({
.reduce((headers, [key, value]) => ({
...headers,
[key]: String(value),
}),
{} as Record<string, string>,
)
}), {} as Record<string, string>);
if (isStringWithValue(token)) {
headers['Authorization'] = `Bearer ${token}`
headers['Authorization'] = `Bearer ${token}`;
}
if (isStringWithValue(username) && isStringWithValue(password)) {
const credentials = base64(`${username}:${password}`)
headers['Authorization'] = `Basic ${credentials}`
const credentials = base64(`${username}:${password}`);
headers['Authorization'] = `Basic ${credentials}`;
}
if (options.body !== undefined) {
if (options.mediaType) {
headers['Content-Type'] = options.mediaType
headers['Content-Type'] = options.mediaType;
} else if (isBlob(options.body)) {
headers['Content-Type'] = options.body.type || 'application/octet-stream'
headers['Content-Type'] = options.body.type || 'application/octet-stream';
} else if (isString(options.body)) {
headers['Content-Type'] = 'text/plain'
headers['Content-Type'] = 'text/plain';
} else if (!isFormData(options.body)) {
headers['Content-Type'] = 'application/json'
headers['Content-Type'] = 'application/json';
}
}
return headers
}
return headers;
};
export const getRequestBody = (options: ApiRequestOptions): any => {
if (options.body) {
return options.body
return options.body;
}
return undefined
}
return undefined;
};
export const sendRequest = async <T>(
config: OpenAPIConfig,
@ -225,9 +205,9 @@ export const sendRequest = async <T>(
formData: FormData | undefined,
headers: Record<string, string>,
onCancel: OnCancel,
axiosClient: AxiosInstance,
axiosClient: AxiosInstance
): Promise<AxiosResponse<T>> => {
const source = axios.CancelToken.source()
const source = axios.CancelToken.source();
const requestConfig: AxiosRequestConfig = {
url,
@ -235,48 +215,41 @@ export const sendRequest = async <T>(
data: body ?? formData,
method: options.method,
withCredentials: config.WITH_CREDENTIALS,
withXSRFToken:
config.CREDENTIALS === 'include' ? config.WITH_CREDENTIALS : false,
withXSRFToken: config.CREDENTIALS === 'include' ? config.WITH_CREDENTIALS : false,
cancelToken: source.token,
}
};
onCancel(() => source.cancel('The user aborted a request.'))
onCancel(() => source.cancel('The user aborted a request.'));
try {
return await axiosClient.request(requestConfig)
return await axiosClient.request(requestConfig);
} catch (error) {
const axiosError = error as AxiosError<T>
const axiosError = error as AxiosError<T>;
if (axiosError.response) {
return axiosError.response
return axiosError.response;
}
throw error
throw error;
}
}
};
export const getResponseHeader = (
response: AxiosResponse<any>,
responseHeader?: string,
): string | undefined => {
export const getResponseHeader = (response: AxiosResponse<any>, responseHeader?: string): string | undefined => {
if (responseHeader) {
const content = response.headers[responseHeader]
const content = response.headers[responseHeader];
if (isString(content)) {
return content
return content;
}
}
return undefined
}
return undefined;
};
export const getResponseBody = (response: AxiosResponse<any>): any => {
if (response.status !== 204) {
return response.data
return response.data;
}
return undefined
}
return undefined;
};
export const catchErrorCodes = (
options: ApiRequestOptions,
result: ApiResult,
): void => {
export const catchErrorCodes = (options: ApiRequestOptions, result: ApiResult): void => {
const errors: Record<number, string> = {
400: 'Bad Request',
401: 'Unauthorized',
@ -288,29 +261,27 @@ export const catchErrorCodes = (
...options.errors,
}
const error = errors[result.status]
const error = errors[result.status];
if (error) {
throw new ApiError(options, result, error)
throw new ApiError(options, result, error);
}
if (!result.ok) {
const errorStatus = result.status ?? 'unknown'
const errorStatusText = result.statusText ?? 'unknown'
const errorStatus = result.status ?? 'unknown';
const errorStatusText = result.statusText ?? 'unknown';
const errorBody = (() => {
try {
return JSON.stringify(result.body, null, 2)
return JSON.stringify(result.body, null, 2);
} catch (e) {
return undefined
return undefined;
}
})()
})();
throw new ApiError(
options,
result,
`Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`,
)
throw new ApiError(options, result,
`Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`
);
}
}
};
/**
* Request method
@ -320,34 +291,18 @@ export const catchErrorCodes = (
* @returns CancelablePromise<T>
* @throws ApiError
*/
export const request = <T>(
config: OpenAPIConfig,
options: ApiRequestOptions,
axiosClient: AxiosInstance = axios,
): CancelablePromise<T> => {
export const request = <T>(config: OpenAPIConfig, options: ApiRequestOptions, axiosClient: AxiosInstance = axios): CancelablePromise<T> => {
return new CancelablePromise(async (resolve, reject, onCancel) => {
try {
const url = getUrl(config, options)
const formData = getFormData(options)
const body = getRequestBody(options)
const headers = await getHeaders(config, options, formData)
const url = getUrl(config, options);
const formData = getFormData(options);
const body = getRequestBody(options);
const headers = await getHeaders(config, options, formData);
if (!onCancel.isCancelled) {
const response = await sendRequest<T>(
config,
options,
url,
body,
formData,
headers,
onCancel,
axiosClient,
)
const responseBody = getResponseBody(response)
const responseHeader = getResponseHeader(
response,
options.responseHeader,
)
const response = await sendRequest<T>(config, options, url, body, formData, headers, onCancel, axiosClient);
const responseBody = getResponseBody(response);
const responseHeader = getResponseHeader(response, options.responseHeader);
const result: ApiResult = {
url,
@ -355,14 +310,14 @@ export const request = <T>(
status: response.status,
statusText: response.statusText,
body: responseHeader ?? responseBody,
}
};
catchErrorCodes(options, result)
catchErrorCodes(options, result);
resolve(result.body)
resolve(result.body);
}
} catch (error) {
reject(error)
reject(error);
}
})
}
});
};

@ -2,72 +2,77 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export { ApiError } from './core/ApiError'
export { CancelablePromise, CancelError } from './core/CancelablePromise'
export { OpenAPI } from './core/OpenAPI'
export type { OpenAPIConfig } from './core/OpenAPI'
export { ApiError } from './core/ApiError';
export { CancelablePromise, CancelError } from './core/CancelablePromise';
export { OpenAPI } from './core/OpenAPI';
export type { OpenAPIConfig } from './core/OpenAPI';
export type { BaseResponse } from './models/BaseResponse'
export type { BaseResponse_boolean_ } from './models/BaseResponse_boolean_'
export type { BaseResponse_CoursesDTO_ } from './models/BaseResponse_CoursesDTO_'
export type { BaseResponse_List_CourseObjectivesTreeVO_ } from './models/BaseResponse_List_CourseObjectivesTreeVO_'
export type { BaseResponse_List_CourseResources_ } from './models/BaseResponse_List_CourseResources_'
export type { BaseResponse_List_LearningRecords_ } from './models/BaseResponse_List_LearningRecords_'
export type { BaseResponse_List_ObjectivesType_ } from './models/BaseResponse_List_ObjectivesType_'
export type { BaseResponse_List_TeacherInfVO_ } from './models/BaseResponse_List_TeacherInfVO_'
export type { BaseResponse_long_ } from './models/BaseResponse_long_'
export type { BaseResponse_Map_string_object_ } from './models/BaseResponse_Map_string_object_'
export type { BaseResponse_ObjectiveContentKnowVO_ } from './models/BaseResponse_ObjectiveContentKnowVO_'
export type { BaseResponse_ObjectiveContents_ } from './models/BaseResponse_ObjectiveContents_'
export type { BaseResponse_Page_ } from './models/BaseResponse_Page_'
export type { BaseResponse_Page_CourseFavourDetailVO_ } from './models/BaseResponse_Page_CourseFavourDetailVO_'
export type { BaseResponse_Page_CourseResources_ } from './models/BaseResponse_Page_CourseResources_'
export type { BaseResponse_PageDTO_CoursesVO_ } from './models/BaseResponse_PageDTO_CoursesVO_'
export type { BaseResponse_string_ } from './models/BaseResponse_string_'
export type { CommonResult } from './models/CommonResult'
export type { CommonResult_string_ } from './models/CommonResult_string_'
export type { CommonResult_UmsAdmin_ } from './models/CommonResult_UmsAdmin_'
export type { CourseFavourAddRequest } from './models/CourseFavourAddRequest'
export type { CourseFavourAllRequest } from './models/CourseFavourAllRequest'
export type { CourseFavourDetailVO } from './models/CourseFavourDetailVO'
export type { CourseFavourQueryRequest } from './models/CourseFavourQueryRequest'
export type { CourseObjectivesDTO } from './models/CourseObjectivesDTO'
export type { CourseObjectivesTreeVO } from './models/CourseObjectivesTreeVO'
export type { CourseResources } from './models/CourseResources'
export type { CoursesDTO } from './models/CoursesDTO'
export type { CoursesVO } from './models/CoursesVO'
export type { CourseThumbAddRequest } from './models/CourseThumbAddRequest'
export type { KnowFavourAddRequest } from './models/KnowFavourAddRequest'
export type { KnowThumbAddRequest } from './models/KnowThumbAddRequest'
export type { LearningRecords } from './models/LearningRecords'
export type { ObjectiveContentKnowDTO } from './models/ObjectiveContentKnowDTO'
export type { ObjectiveContentKnowVO } from './models/ObjectiveContentKnowVO'
export type { ObjectiveContents_ } from './models/ObjectiveContents_'
export type { ObjectivesType_ } from './models/ObjectivesType_'
export type { OrderItem } from './models/OrderItem'
export type { Page } from './models/Page'
export type { Page_CourseFavourDetailVO_ } from './models/Page_CourseFavourDetailVO_'
export type { Page_CourseResources_ } from './models/Page_CourseResources_'
export type { PageDTO_CoursesVO_ } from './models/PageDTO_CoursesVO_'
export type { ResourceFavourAddRequest } from './models/ResourceFavourAddRequest'
export type { ResourceFavourQueryRequest } from './models/ResourceFavourQueryRequest'
export type { ResourceThumbAddRequest } from './models/ResourceThumbAddRequest'
export type { StudentCoursesDTO } from './models/StudentCoursesDTO'
export type { TeacherInfVO } from './models/TeacherInfVO'
export type { UmsAdmin } from './models/UmsAdmin'
export type { UmsAdminParam } from './models/UmsAdminParam'
export type { UmsStudentAndTeacherDTO } from './models/UmsStudentAndTeacherDTO'
export type { UpdateAdminPasswordParam } from './models/UpdateAdminPasswordParam'
export type { BaseResponse } from './models/BaseResponse';
export type { BaseResponse_boolean_ } from './models/BaseResponse_boolean_';
export type { BaseResponse_CoursesDTO_ } from './models/BaseResponse_CoursesDTO_';
export type { BaseResponse_List_CourseObjectivesTreeVO_ } from './models/BaseResponse_List_CourseObjectivesTreeVO_';
export type { BaseResponse_List_CourseResources_ } from './models/BaseResponse_List_CourseResources_';
export type { BaseResponse_List_LearningRecords_ } from './models/BaseResponse_List_LearningRecords_';
export type { BaseResponse_List_ObjectivesType_ } from './models/BaseResponse_List_ObjectivesType_';
export type { BaseResponse_List_TeacherInfVO_ } from './models/BaseResponse_List_TeacherInfVO_';
export type { BaseResponse_long_ } from './models/BaseResponse_long_';
export type { BaseResponse_Map_string_object_ } from './models/BaseResponse_Map_string_object_';
export type { BaseResponse_ObjectiveContentKnowVO_ } from './models/BaseResponse_ObjectiveContentKnowVO_';
export type { BaseResponse_ObjectiveContents_ } from './models/BaseResponse_ObjectiveContents_';
export type { BaseResponse_Page_ } from './models/BaseResponse_Page_';
export type { BaseResponse_Page_CourseFavourDetailVO_ } from './models/BaseResponse_Page_CourseFavourDetailVO_';
export type { BaseResponse_Page_CourseResources_ } from './models/BaseResponse_Page_CourseResources_';
export type { BaseResponse_PageDTO_CoursesVO_ } from './models/BaseResponse_PageDTO_CoursesVO_';
export type { BaseResponse_string_ } from './models/BaseResponse_string_';
export type { CommonResult } from './models/CommonResult';
export type { CommonResult_string_ } from './models/CommonResult_string_';
export type { CommonResult_UmsAdmin_ } from './models/CommonResult_UmsAdmin_';
export type { CourseFavourAddRequest } from './models/CourseFavourAddRequest';
export type { CourseFavourAllRequest } from './models/CourseFavourAllRequest';
export type { CourseFavourDetailVO } from './models/CourseFavourDetailVO';
export type { CourseFavourQueryRequest } from './models/CourseFavourQueryRequest';
export type { CourseObjectivesDTO } from './models/CourseObjectivesDTO';
export type { CourseObjectivesTreeVO } from './models/CourseObjectivesTreeVO';
export type { CourseResources } from './models/CourseResources';
export type { CoursesDTO } from './models/CoursesDTO';
export type { CoursesVO } from './models/CoursesVO';
export type { CourseThumbAddRequest } from './models/CourseThumbAddRequest';
export type { Know } from './models/Know';
export type { KnowFavourAddRequest } from './models/KnowFavourAddRequest';
export type { KnowQueryRequest } from './models/KnowQueryRequest';
export type { KnowRequest } from './models/KnowRequest';
export type { KnowThumbAddRequest } from './models/KnowThumbAddRequest';
export type { KnowupdateRequest } from './models/KnowupdateRequest';
export type { LearningRecords } from './models/LearningRecords';
export type { ObjectiveContentKnowDTO } from './models/ObjectiveContentKnowDTO';
export type { ObjectiveContentKnowVO } from './models/ObjectiveContentKnowVO';
export type { ObjectiveContents_ } from './models/ObjectiveContents_';
export type { ObjectivesType_ } from './models/ObjectivesType_';
export type { OrderItem } from './models/OrderItem';
export type { Page } from './models/Page';
export type { Page_CourseFavourDetailVO_ } from './models/Page_CourseFavourDetailVO_';
export type { Page_CourseResources_ } from './models/Page_CourseResources_';
export type { PageDTO_CoursesVO_ } from './models/PageDTO_CoursesVO_';
export type { ResourceFavourAddRequest } from './models/ResourceFavourAddRequest';
export type { ResourceFavourQueryRequest } from './models/ResourceFavourQueryRequest';
export type { ResourceThumbAddRequest } from './models/ResourceThumbAddRequest';
export type { StudentCoursesDTO } from './models/StudentCoursesDTO';
export type { TeacherInfVO } from './models/TeacherInfVO';
export type { UmsAdmin } from './models/UmsAdmin';
export type { UmsAdminParam } from './models/UmsAdminParam';
export type { UmsStudentAndTeacherDTO } from './models/UmsStudentAndTeacherDTO';
export type { UpdateAdminPasswordParam } from './models/UpdateAdminPasswordParam';
export { Service } from './services/Service'
export { CourseResourceControllerService } from './services/CourseResourceControllerService'
export { FavourInformationControllerService } from './services/FavourInformationControllerService'
export { LearningRecordsControllerService } from './services/LearningRecordsControllerService'
export { ResourceControllerService } from './services/ResourceControllerService'
export { SeCourseFavourControllerService } from './services/SeCourseFavourControllerService'
export { SeCourseThumbControllerService } from './services/SeCourseThumbControllerService'
export { SeKnowFavourControllerService } from './services/SeKnowFavourControllerService'
export { SeKnowThumbControllerService } from './services/SeKnowThumbControllerService'
export { SeResourceFavourControllerService } from './services/SeResourceFavourControllerService'
export { SeResourceThumbControllerService } from './services/SeResourceThumbControllerService'
export { UmsAdminControllerService } from './services/UmsAdminControllerService'
export { Service } from './services/Service';
export { CourseResourceControllerService } from './services/CourseResourceControllerService';
export { FavourInformationControllerService } from './services/FavourInformationControllerService';
export { KnowControllerService } from './services/KnowControllerService';
export { LearningRecordsControllerService } from './services/LearningRecordsControllerService';
export { ResourceControllerService } from './services/ResourceControllerService';
export { SeCourseFavourControllerService } from './services/SeCourseFavourControllerService';
export { SeCourseThumbControllerService } from './services/SeCourseThumbControllerService';
export { SeKnowFavourControllerService } from './services/SeKnowFavourControllerService';
export { SeKnowThumbControllerService } from './services/SeKnowThumbControllerService';
export { SeResourceFavourControllerService } from './services/SeResourceFavourControllerService';
export { SeResourceThumbControllerService } from './services/SeResourceThumbControllerService';
export { UmsAdminControllerService } from './services/UmsAdminControllerService';

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type BaseResponse = {
code?: number
data?: any
message?: string
}
code?: number;
data?: any;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CoursesDTO } from './CoursesDTO'
import type { CoursesDTO } from './CoursesDTO';
export type BaseResponse_CoursesDTO_ = {
code?: number
data?: CoursesDTO
message?: string
}
code?: number;
data?: CoursesDTO;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CourseObjectivesTreeVO } from './CourseObjectivesTreeVO'
import type { CourseObjectivesTreeVO } from './CourseObjectivesTreeVO';
export type BaseResponse_List_CourseObjectivesTreeVO_ = {
code?: number
data?: Array<CourseObjectivesTreeVO>
message?: string
}
code?: number;
data?: Array<CourseObjectivesTreeVO>;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CourseResources } from './CourseResources'
import type { CourseResources } from './CourseResources';
export type BaseResponse_List_CourseResources_ = {
code?: number
data?: Array<CourseResources>
message?: string
}
code?: number;
data?: Array<CourseResources>;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { LearningRecords } from './LearningRecords'
import type { LearningRecords } from './LearningRecords';
export type BaseResponse_List_LearningRecords_ = {
code?: number
data?: Array<LearningRecords>
message?: string
}
code?: number;
data?: Array<LearningRecords>;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ObjectivesType_ } from './ObjectivesType_'
import type { ObjectivesType_ } from './ObjectivesType_';
export type BaseResponse_List_ObjectivesType_ = {
code?: number
data?: Array<ObjectivesType_>
message?: string
}
code?: number;
data?: Array<ObjectivesType_>;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { TeacherInfVO } from './TeacherInfVO'
import type { TeacherInfVO } from './TeacherInfVO';
export type BaseResponse_List_TeacherInfVO_ = {
code?: number
data?: Array<TeacherInfVO>
message?: string
}
code?: number;
data?: Array<TeacherInfVO>;
message?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type BaseResponse_Map_string_object_ = {
code?: number
data?: any
message?: string
}
code?: number;
data?: any;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ObjectiveContentKnowVO } from './ObjectiveContentKnowVO'
import type { ObjectiveContentKnowVO } from './ObjectiveContentKnowVO';
export type BaseResponse_ObjectiveContentKnowVO_ = {
code?: number
data?: ObjectiveContentKnowVO
message?: string
}
code?: number;
data?: ObjectiveContentKnowVO;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ObjectiveContents_ } from './ObjectiveContents_'
import type { ObjectiveContents_ } from './ObjectiveContents_';
export type BaseResponse_ObjectiveContents_ = {
code?: number
data?: ObjectiveContents_
message?: string
}
code?: number;
data?: ObjectiveContents_;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { PageDTO_CoursesVO_ } from './PageDTO_CoursesVO_'
import type { PageDTO_CoursesVO_ } from './PageDTO_CoursesVO_';
export type BaseResponse_PageDTO_CoursesVO_ = {
code?: number
data?: PageDTO_CoursesVO_
message?: string
}
code?: number;
data?: PageDTO_CoursesVO_;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Page } from './Page'
import type { Page } from './Page';
export type BaseResponse_Page_ = {
code?: number
data?: Page
message?: string
}
code?: number;
data?: Page;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Page_CourseFavourDetailVO_ } from './Page_CourseFavourDetailVO_'
import type { Page_CourseFavourDetailVO_ } from './Page_CourseFavourDetailVO_';
export type BaseResponse_Page_CourseFavourDetailVO_ = {
code?: number
data?: Page_CourseFavourDetailVO_
message?: string
}
code?: number;
data?: Page_CourseFavourDetailVO_;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Page_CourseResources_ } from './Page_CourseResources_'
import type { Page_CourseResources_ } from './Page_CourseResources_';
export type BaseResponse_Page_CourseResources_ = {
code?: number
data?: Page_CourseResources_
message?: string
}
code?: number;
data?: Page_CourseResources_;
message?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type BaseResponse_boolean_ = {
code?: number
data?: boolean
message?: string
}
code?: number;
data?: boolean;
message?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type BaseResponse_long_ = {
code?: number
data?: number
message?: string
}
code?: number;
data?: number;
message?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type BaseResponse_string_ = {
code?: number
data?: string
message?: string
}
code?: number;
data?: string;
message?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type CommonResult = {
code?: number
data?: any
message?: string
}
code?: number;
data?: any;
message?: string;
};

@ -2,9 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { UmsAdmin } from './UmsAdmin'
import type { UmsAdmin } from './UmsAdmin';
export type CommonResult_UmsAdmin_ = {
code?: number
data?: UmsAdmin
message?: string
}
code?: number;
data?: UmsAdmin;
message?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type CommonResult_string_ = {
code?: number
data?: string
message?: string
}
code?: number;
data?: string;
message?: string;
};

@ -3,6 +3,7 @@
/* tslint:disable */
/* eslint-disable */
export type CourseFavourAddRequest = {
courseId?: string
userId?: string
}
courseId?: string;
userId?: string;
};

@ -3,5 +3,6 @@
/* tslint:disable */
/* eslint-disable */
export type CourseFavourAllRequest = {
courseId?: string
}
courseId?: string;
};

@ -6,16 +6,17 @@ export type CourseFavourDetailVO = {
/**
*
*/
classhours: number
classhours: number;
/**
*
*/
credit: number
id?: string
img?: string
name?: string
credit: number;
id?: string;
img?: string;
name?: string;
/**
* id
*/
teacher?: string
}
teacher?: string;
};

@ -3,9 +3,10 @@
/* tslint:disable */
/* eslint-disable */
export type CourseFavourQueryRequest = {
current?: number
pageSize?: number
sortField?: string
sortOrder?: string
userId?: string
}
current?: number;
pageSize?: number;
sortField?: string;
sortOrder?: string;
userId?: string;
};

@ -9,17 +9,18 @@ export type CourseObjectivesDTO = {
/**
* id
*/
id?: string
id?: string;
/**
*
*/
name: string
name: string;
/**
* pid
*/
pid: string
pid: string;
/**
*
*/
type: number
}
type: number;
};

@ -2,7 +2,7 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ObjectiveContents_ } from './ObjectiveContents_'
import type { ObjectiveContents_ } from './ObjectiveContents_';
/**
*
*/
@ -10,41 +10,42 @@ export type CourseObjectivesTreeVO = {
/**
*
*/
contents?: Array<ObjectiveContents_>
contents?: Array<ObjectiveContents_>;
/**
* id
*/
courseId?: string
courseId?: string;
/**
*
*/
courseObjectivesTrees?: Array<CourseObjectivesTreeVO>
courseObjectivesTrees?: Array<CourseObjectivesTreeVO>;
/**
*
*/
hasChild?: number
hasChild?: number;
/**
*
*/
id?: string
id?: string;
/**
*
*/
name?: string
name?: string;
/**
*
*/
pid?: string
pid?: string;
/**
* id
*/
requireid?: string
requireid?: string;
/**
*
*/
temp?: string
temp?: string;
/**
*
*/
type?: number
}
type?: number;
};

@ -3,12 +3,13 @@
/* tslint:disable */
/* eslint-disable */
export type CourseResources = {
description?: string
id?: number
img?: string
name?: string
path?: string
status?: number
tags?: string
type?: number
}
description?: string;
id?: number;
img?: string;
name?: string;
path?: string;
status?: number;
tags?: string;
type?: number;
};

@ -3,6 +3,7 @@
/* tslint:disable */
/* eslint-disable */
export type CourseThumbAddRequest = {
courseId?: string
userId?: string
}
courseId?: string;
userId?: string;
};

@ -9,61 +9,62 @@ export type CoursesDTO = {
/**
* 1 2
*/
assessmenttype: string
assessmenttype: string;
/**
* 1 2 3
*/
assessmentway: string
assessmentway: string;
/**
* 1 2
*/
category: string
category: string;
/**
*
*/
classhours: number
classhours: number;
/**
*
*/
code: string
code: string;
/**
*
*/
createTime?: string
createTime?: string;
/**
*
*/
credit: number
credit: number;
/**
*
*/
description?: string
description?: string;
/**
* id
*/
id?: string
id?: string;
/**
*
*/
img?: string
img: string;
/**
*
*/
name: string
name: string;
/**
* 1 2 3
*/
nature: string
nature: string;
/**
*
*/
teacher: string
teacher: string;
/**
*
*/
teachermethod?: string
teachermethod?: string;
/**
*
*/
teacherway?: string
}
teacherway?: string;
};

@ -9,41 +9,42 @@ export type CoursesVO = {
/**
*
*/
classhours: number
classhours: number;
/**
*
*/
credit: number
credit: number;
/**
*
*/
description: string
description: string;
/**
* id
*/
id?: string
id?: string;
/**
*
*/
img?: string
img?: string;
/**
*
*/
name: string
name: string;
/**
*
*/
teacher?: string
teacher?: string;
/**
*
*/
totalHours: number
totalHours: number;
/**
*
*/
totalKnow: number
totalKnow: number;
/**
*
*/
totalchapter: number
}
totalchapter: number;
};

@ -0,0 +1,14 @@
/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type Know = {
content?: string;
hour?: number;
id?: number;
img?: string;
info?: string;
name?: string;
resourceid?: string;
};

@ -3,7 +3,8 @@
/* tslint:disable */
/* eslint-disable */
export type KnowFavourAddRequest = {
courseId?: string
knowId?: string
userId?: string
}
courseId?: string;
knowId?: string;
userId?: string;
};

@ -0,0 +1,8 @@
/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type KnowQueryRequest = {
name?: string;
};

@ -0,0 +1,13 @@
/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type KnowRequest = {
content?: string;
hour?: number;
img?: string;
info?: string;
name?: string;
resourceid?: string;
};

@ -3,6 +3,7 @@
/* tslint:disable */
/* eslint-disable */
export type KnowThumbAddRequest = {
knowId?: number
userId?: string
}
knowId?: number;
userId?: string;
};

@ -0,0 +1,14 @@
/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type KnowupdateRequest = {
content?: string;
hour?: number;
id?: number;
img?: string;
info?: string;
name?: string;
resourceid?: string;
};

@ -3,19 +3,20 @@
/* tslint:disable */
/* eslint-disable */
export type LearningRecords = {
accessTime?: string
address?: string
chapterId?: string
content?: string
coursesId?: string
download?: string
id?: string
isCompleted?: string
knowledgePointId?: string
open?: string
parentNode?: string
resourceId?: string
status?: string
type?: string
userId?: string
}
accessTime?: string;
address?: string;
chapterId?: string;
content?: string;
coursesId?: string;
download?: string;
id?: string;
isCompleted?: string;
knowledgePointId?: string;
open?: string;
parentNode?: string;
resourceId?: string;
status?: string;
type?: string;
userId?: string;
};

@ -9,7 +9,8 @@ export type ObjectiveContentKnowDTO = {
/**
*
*/
id?: string
know?: string
objectiveOrContent?: string
}
id?: string;
know?: string;
objectiveOrContent?: string;
};

@ -6,18 +6,19 @@
* VO实体
*/
export type ObjectiveContentKnowVO = {
contentKnowsData?: Array<ObjectiveContentKnowVO>
contentKnowsData?: Array<ObjectiveContentKnowVO>;
/**
*
*/
knowsNumber?: number
knowsNumber?: number;
/**
*
*/
knowsTime?: number
objectiveOrContent?: string
knowsTime?: number;
objectiveOrContent?: string;
/**
*
*/
persent?: string
}
persent?: string;
};

@ -6,10 +6,11 @@ export type ObjectiveContents_ = {
/**
*
*/
content: string
id?: string
content: string;
id?: string;
/**
* id
*/
objectiveId: string
}
objectiveId: string;
};

@ -6,9 +6,10 @@ export type ObjectivesType_ = {
/**
* 使
*/
id?: number
id?: number;
/**
*
*/
typeName: string
}
typeName: string;
};

@ -3,6 +3,7 @@
/* tslint:disable */
/* eslint-disable */
export type OrderItem = {
asc?: boolean
column?: string
}
asc?: boolean;
column?: string;
};

@ -2,16 +2,17 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { OrderItem } from './OrderItem'
import type { OrderItem } from './OrderItem';
export type Page = {
countId?: string
current?: number
maxLimit?: number
optimizeCountSql?: boolean
orders?: Array<OrderItem>
pages?: number
records?: Array<any>
searchCount?: boolean
size?: number
total?: number
}
countId?: string;
current?: number;
maxLimit?: number;
optimizeCountSql?: boolean;
orders?: Array<OrderItem>;
pages?: number;
records?: Array<any>;
searchCount?: boolean;
size?: number;
total?: number;
};

@ -2,7 +2,7 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CoursesVO } from './CoursesVO'
import type { CoursesVO } from './CoursesVO';
/**
*
*/
@ -10,13 +10,14 @@ export type PageDTO_CoursesVO_ = {
/**
*
*/
list?: Array<CoursesVO>
list?: Array<CoursesVO>;
/**
*
*/
pages?: number
pages?: number;
/**
*
*/
total?: number
}
total?: number;
};

@ -2,17 +2,18 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CourseFavourDetailVO } from './CourseFavourDetailVO'
import type { OrderItem } from './OrderItem'
import type { CourseFavourDetailVO } from './CourseFavourDetailVO';
import type { OrderItem } from './OrderItem';
export type Page_CourseFavourDetailVO_ = {
countId?: string
current?: number
maxLimit?: number
optimizeCountSql?: boolean
orders?: Array<OrderItem>
pages?: number
records?: Array<CourseFavourDetailVO>
searchCount?: boolean
size?: number
total?: number
}
countId?: string;
current?: number;
maxLimit?: number;
optimizeCountSql?: boolean;
orders?: Array<OrderItem>;
pages?: number;
records?: Array<CourseFavourDetailVO>;
searchCount?: boolean;
size?: number;
total?: number;
};

@ -2,17 +2,18 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CourseResources } from './CourseResources'
import type { OrderItem } from './OrderItem'
import type { CourseResources } from './CourseResources';
import type { OrderItem } from './OrderItem';
export type Page_CourseResources_ = {
countId?: string
current?: number
maxLimit?: number
optimizeCountSql?: boolean
orders?: Array<OrderItem>
pages?: number
records?: Array<CourseResources>
searchCount?: boolean
size?: number
total?: number
}
countId?: string;
current?: number;
maxLimit?: number;
optimizeCountSql?: boolean;
orders?: Array<OrderItem>;
pages?: number;
records?: Array<CourseResources>;
searchCount?: boolean;
size?: number;
total?: number;
};

@ -3,6 +3,7 @@
/* tslint:disable */
/* eslint-disable */
export type ResourceFavourAddRequest = {
resourceId?: number
userId?: string
}
resourceId?: number;
userId?: string;
};

@ -3,10 +3,11 @@
/* tslint:disable */
/* eslint-disable */
export type ResourceFavourQueryRequest = {
current?: number
pageSize?: number
sortField?: string
sortOrder?: string
type?: number
userId?: string
}
current?: number;
pageSize?: number;
sortField?: string;
sortOrder?: string;
type?: number;
userId?: string;
};

@ -3,6 +3,7 @@
/* tslint:disable */
/* eslint-disable */
export type ResourceThumbAddRequest = {
resourceId?: number
userId?: string
}
resourceId?: number;
userId?: string;
};

@ -6,7 +6,8 @@
*
*/
export type StudentCoursesDTO = {
course?: string
id?: string
student?: string
}
course?: string;
id?: string;
student?: string;
};

@ -9,9 +9,10 @@ export type TeacherInfVO = {
/**
* name
*/
name?: string
name?: string;
/**
* username
*/
username?: string
}
username?: string;
};

@ -3,12 +3,13 @@
/* tslint:disable */
/* eslint-disable */
export type UmsAdmin = {
createTime?: string
icon?: string
id?: number
nickName?: string
password?: string
phone?: string
status?: number
username?: string
}
createTime?: string;
icon?: string;
id?: number;
nickName?: string;
password?: string;
phone?: string;
status?: number;
username?: string;
};

@ -3,9 +3,10 @@
/* tslint:disable */
/* eslint-disable */
export type UmsAdminParam = {
icon?: string
nickName?: string
password?: string
phone?: string
username?: string
}
icon?: string;
nickName?: string;
password?: string;
phone?: string;
username?: string;
};

@ -3,23 +3,24 @@
/* tslint:disable */
/* eslint-disable */
export type UmsStudentAndTeacherDTO = {
birthday?: string
className?: string
degree?: string
education?: string
emergencyContact?: string
faculty?: string
id?: number
joinWorkTime?: string
major?: string
name?: string
nationality?: string
number?: string
phone?: string
politicalStatus?: string
profession?: string
professionalTitle?: string
roleId?: number
sex?: string
yearAge?: string
}
birthday?: string;
className?: string;
degree?: string;
education?: string;
emergencyContact?: string;
faculty?: string;
id?: number;
joinWorkTime?: string;
major?: string;
name?: string;
nationality?: string;
number?: string;
phone?: string;
politicalStatus?: string;
profession?: string;
professionalTitle?: string;
roleId?: number;
sex?: string;
yearAge?: string;
};

@ -6,13 +6,14 @@ export type UpdateAdminPasswordParam = {
/**
*
*/
newPassword: string
newPassword: string;
/**
*
*/
oldPassword: string
oldPassword: string;
/**
*
*/
username: string
}
username: string;
};

@ -2,13 +2,13 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_List_CourseResources_ } from '../models/BaseResponse_List_CourseResources_'
import type { BaseResponse_Page_ } from '../models/BaseResponse_Page_'
import type { BaseResponse_string_ } from '../models/BaseResponse_string_'
import type { CourseResources } from '../models/CourseResources'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_List_CourseResources_ } from '../models/BaseResponse_List_CourseResources_';
import type { BaseResponse_Page_ } from '../models/BaseResponse_Page_';
import type { BaseResponse_string_ } from '../models/BaseResponse_string_';
import type { CourseResources } from '../models/CourseResources';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class CourseResourceControllerService {
/**
* All
@ -18,13 +18,13 @@ export class CourseResourceControllerService {
public static allUsingGet1(): CancelablePromise<BaseResponse_List_CourseResources_> {
return __request(OpenAPI, {
method: 'GET',
url: '/courses/all',
url: '/api/courses/all',
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* deleteRecords
@ -37,15 +37,15 @@ export class CourseResourceControllerService {
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/courses/delete',
url: '/api/courses/delete',
query: {
ids: ids,
'ids': ids,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
})
});
}
/**
* getAll
@ -62,18 +62,18 @@ export class CourseResourceControllerService {
): CancelablePromise<BaseResponse_Page_> {
return __request(OpenAPI, {
method: 'GET',
url: '/courses/getall',
url: '/api/courses/getall',
query: {
pagenum: pagenum,
pagesize: pagesize,
type: type,
'pagenum': pagenum,
'pagesize': pagesize,
'type': type,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* saveCourseResource
@ -86,13 +86,13 @@ export class CourseResourceControllerService {
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'GET',
url: '/courses/save',
url: '/api/courses/save',
body: courseResources,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,10 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_Page_CourseResources_ } from '../models/BaseResponse_Page_CourseResources_'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_Page_CourseResources_ } from '../models/BaseResponse_Page_CourseResources_';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class FavourInformationControllerService {
/**
* getInformation2
@ -28,20 +28,20 @@ export class FavourInformationControllerService {
): CancelablePromise<BaseResponse_Page_CourseResources_> {
return __request(OpenAPI, {
method: 'GET',
url: '/Favour/get',
url: '/api/Favour/get',
query: {
current: current,
pageSize: pageSize,
sortField: sortField,
sortOrder: sortOrder,
resourceIdList: resourceIdList,
type: type,
'current': current,
'pageSize': pageSize,
'sortField': sortField,
'sortOrder': sortOrder,
'resourceIdList': resourceIdList,
'type': type,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -0,0 +1,97 @@
/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Know } from '../models/Know';
import type { KnowQueryRequest } from '../models/KnowQueryRequest';
import type { KnowRequest } from '../models/KnowRequest';
import type { KnowupdateRequest } from '../models/KnowupdateRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class KnowControllerService {
/**
* add
* @param knowAddRequest knowAddRequest
* @returns boolean OK
* @returns any Created
* @throws ApiError
*/
public static addUsingPost1(
knowAddRequest: KnowRequest,
): CancelablePromise<boolean | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/api/know/add',
body: knowAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* deleteKnow
* @param ids ids
* @returns number OK
* @returns any Created
* @throws ApiError
*/
public static deleteKnowUsingPost1(
ids: Array<number>,
): CancelablePromise<number | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/api/know/delete',
body: ids,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* query
* @param knowQueryRequest knowQueryRequest
* @returns Know OK
* @returns any Created
* @throws ApiError
*/
public static queryUsingPost1(
knowQueryRequest: KnowQueryRequest,
): CancelablePromise<Array<Know> | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/api/know/query',
body: knowQueryRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
/**
* update
* @param knowAddRequest knowAddRequest
* @returns boolean OK
* @returns any Created
* @throws ApiError
*/
public static updateUsingPost1(
knowAddRequest: KnowupdateRequest,
): CancelablePromise<boolean | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/api/know/update',
body: knowAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
});
}
}

@ -2,13 +2,13 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_List_LearningRecords_ } from '../models/BaseResponse_List_LearningRecords_'
import type { BaseResponse_Page_ } from '../models/BaseResponse_Page_'
import type { BaseResponse_string_ } from '../models/BaseResponse_string_'
import type { LearningRecords } from '../models/LearningRecords'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_List_LearningRecords_ } from '../models/BaseResponse_List_LearningRecords_';
import type { BaseResponse_Page_ } from '../models/BaseResponse_Page_';
import type { BaseResponse_string_ } from '../models/BaseResponse_string_';
import type { LearningRecords } from '../models/LearningRecords';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class LearningRecordsControllerService {
/**
* All
@ -18,13 +18,13 @@ export class LearningRecordsControllerService {
public static allUsingGet3(): CancelablePromise<BaseResponse_List_LearningRecords_> {
return __request(OpenAPI, {
method: 'GET',
url: '/learningrecords/all',
url: '/api/learningrecords/all',
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* deleteRecords
@ -37,15 +37,15 @@ export class LearningRecordsControllerService {
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/learningrecords/delete',
url: '/api/learningrecords/delete',
query: {
ids: ids,
'ids': ids,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
})
});
}
/**
* getAll
@ -62,18 +62,18 @@ export class LearningRecordsControllerService {
): CancelablePromise<BaseResponse_Page_> {
return __request(OpenAPI, {
method: 'GET',
url: '/learningrecords/getall',
url: '/api/learningrecords/getall',
query: {
pagenum: pagenum,
pagesize: pagesize,
userId: userId,
'pagenum': pagenum,
'pagesize': pagesize,
'userId': userId,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* saveRecords
@ -87,13 +87,13 @@ export class LearningRecordsControllerService {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/learningrecords/saverecords',
url: '/api/learningrecords/saverecords',
body: learningRecords,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,10 +2,10 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_string_ } from '../models/BaseResponse_string_'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_string_ } from '../models/BaseResponse_string_';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class ResourceControllerService {
/**
* download
@ -22,15 +22,15 @@ export class ResourceControllerService {
method: 'GET',
url: '/download',
query: {
Id: id,
path: path,
'Id': id,
'path': path,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* upload
@ -46,13 +46,13 @@ export class ResourceControllerService {
method: 'POST',
url: '/upload',
formData: {
file: file,
'file': file,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,15 +2,15 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_'
import type { BaseResponse_long_ } from '../models/BaseResponse_long_'
import type { BaseResponse_Page_CourseFavourDetailVO_ } from '../models/BaseResponse_Page_CourseFavourDetailVO_'
import type { CourseFavourAddRequest } from '../models/CourseFavourAddRequest'
import type { CourseFavourAllRequest } from '../models/CourseFavourAllRequest'
import type { CourseFavourQueryRequest } from '../models/CourseFavourQueryRequest'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_';
import type { BaseResponse_long_ } from '../models/BaseResponse_long_';
import type { BaseResponse_Page_CourseFavourDetailVO_ } from '../models/BaseResponse_Page_CourseFavourDetailVO_';
import type { CourseFavourAddRequest } from '../models/CourseFavourAddRequest';
import type { CourseFavourAllRequest } from '../models/CourseFavourAllRequest';
import type { CourseFavourQueryRequest } from '../models/CourseFavourQueryRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class SeCourseFavourControllerService {
/**
* doFavour
@ -24,14 +24,14 @@ export class SeCourseFavourControllerService {
): CancelablePromise<BaseResponse_boolean_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_favour/add',
url: '/api/course_favour/add',
body: courseFavourAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* favourCount
@ -45,14 +45,14 @@ export class SeCourseFavourControllerService {
): CancelablePromise<BaseResponse_long_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_favour/count',
url: '/api/course_favour/count',
body: courseFavourAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* courseCount
@ -66,14 +66,14 @@ export class SeCourseFavourControllerService {
): CancelablePromise<BaseResponse_long_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_favour/countAll',
url: '/api/course_favour/countAll',
body: courseFavourAllRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* listPostByPage
@ -87,13 +87,13 @@ export class SeCourseFavourControllerService {
): CancelablePromise<BaseResponse_Page_CourseFavourDetailVO_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_favour/list/page',
url: '/api/course_favour/list/page',
body: courseFavourQueryRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,12 +2,12 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_'
import type { BaseResponse_long_ } from '../models/BaseResponse_long_'
import type { CourseThumbAddRequest } from '../models/CourseThumbAddRequest'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_';
import type { BaseResponse_long_ } from '../models/BaseResponse_long_';
import type { CourseThumbAddRequest } from '../models/CourseThumbAddRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class SeCourseThumbControllerService {
/**
* doThumb
@ -21,14 +21,14 @@ export class SeCourseThumbControllerService {
): CancelablePromise<BaseResponse_boolean_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_thumb/',
url: '/api/course_thumb/',
body: courseThumbAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* thumbCount
@ -42,13 +42,13 @@ export class SeCourseThumbControllerService {
): CancelablePromise<BaseResponse_long_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_thumb/count',
url: '/api/course_thumb/count',
body: courseThumbAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,11 +2,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_'
import type { KnowFavourAddRequest } from '../models/KnowFavourAddRequest'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_';
import type { KnowFavourAddRequest } from '../models/KnowFavourAddRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class SeKnowFavourControllerService {
/**
* doFavour
@ -20,13 +20,13 @@ export class SeKnowFavourControllerService {
): CancelablePromise<BaseResponse_boolean_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/know_favour/add',
url: '/api/know_favour/add',
body: knowFavourAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,11 +2,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_'
import type { KnowThumbAddRequest } from '../models/KnowThumbAddRequest'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_';
import type { KnowThumbAddRequest } from '../models/KnowThumbAddRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class SeKnowThumbControllerService {
/**
* doThumb
@ -20,13 +20,13 @@ export class SeKnowThumbControllerService {
): CancelablePromise<BaseResponse_boolean_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/know_thumb/add',
url: '/api/know_thumb/add',
body: knowThumbAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,13 +2,13 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_'
import type { BaseResponse_Page_CourseResources_ } from '../models/BaseResponse_Page_CourseResources_'
import type { ResourceFavourAddRequest } from '../models/ResourceFavourAddRequest'
import type { ResourceFavourQueryRequest } from '../models/ResourceFavourQueryRequest'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_';
import type { BaseResponse_Page_CourseResources_ } from '../models/BaseResponse_Page_CourseResources_';
import type { ResourceFavourAddRequest } from '../models/ResourceFavourAddRequest';
import type { ResourceFavourQueryRequest } from '../models/ResourceFavourQueryRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class SeResourceFavourControllerService {
/**
* doFavour
@ -22,14 +22,14 @@ export class SeResourceFavourControllerService {
): CancelablePromise<BaseResponse_boolean_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/resource_favour/add',
url: '/api/resource_favour/add',
body: resourceFavourAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* listPostByPage
@ -43,13 +43,13 @@ export class SeResourceFavourControllerService {
): CancelablePromise<BaseResponse_Page_CourseResources_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/resource_favour/list/page',
url: '/api/resource_favour/list/page',
body: resourceFavourQueryRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,11 +2,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_'
import type { ResourceThumbAddRequest } from '../models/ResourceThumbAddRequest'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_boolean_ } from '../models/BaseResponse_boolean_';
import type { ResourceThumbAddRequest } from '../models/ResourceThumbAddRequest';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class SeResourceThumbControllerService {
/**
* doThumb
@ -20,13 +20,13 @@ export class SeResourceThumbControllerService {
): CancelablePromise<BaseResponse_boolean_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/resource_thumb/add',
url: '/api/resource_thumb/add',
body: resourceThumbAddRequest,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,24 +2,24 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse } from '../models/BaseResponse'
import type { BaseResponse_CoursesDTO_ } from '../models/BaseResponse_CoursesDTO_'
import type { BaseResponse_List_CourseObjectivesTreeVO_ } from '../models/BaseResponse_List_CourseObjectivesTreeVO_'
import type { BaseResponse_List_ObjectivesType_ } from '../models/BaseResponse_List_ObjectivesType_'
import type { BaseResponse_Map_string_object_ } from '../models/BaseResponse_Map_string_object_'
import type { BaseResponse_ObjectiveContentKnowVO_ } from '../models/BaseResponse_ObjectiveContentKnowVO_'
import type { BaseResponse_ObjectiveContents_ } from '../models/BaseResponse_ObjectiveContents_'
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 { ObjectiveContentKnowDTO } from '../models/ObjectiveContentKnowDTO'
import type { ObjectiveContents_ } from '../models/ObjectiveContents_'
import type { ObjectivesType_ } from '../models/ObjectivesType_'
import type { StudentCoursesDTO } from '../models/StudentCoursesDTO'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse } from '../models/BaseResponse';
import type { BaseResponse_CoursesDTO_ } from '../models/BaseResponse_CoursesDTO_';
import type { BaseResponse_List_CourseObjectivesTreeVO_ } from '../models/BaseResponse_List_CourseObjectivesTreeVO_';
import type { BaseResponse_List_ObjectivesType_ } from '../models/BaseResponse_List_ObjectivesType_';
import type { BaseResponse_Map_string_object_ } from '../models/BaseResponse_Map_string_object_';
import type { BaseResponse_ObjectiveContentKnowVO_ } from '../models/BaseResponse_ObjectiveContentKnowVO_';
import type { BaseResponse_ObjectiveContents_ } from '../models/BaseResponse_ObjectiveContents_';
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 { ObjectiveContentKnowDTO } from '../models/ObjectiveContentKnowDTO';
import type { ObjectiveContents_ } from '../models/ObjectiveContents_';
import type { ObjectivesType_ } from '../models/ObjectivesType_';
import type { StudentCoursesDTO } from '../models/StudentCoursesDTO';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class Service {
/**
*
@ -33,14 +33,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/course_objectives',
url: '/api/course_objectives',
body: courseObjectivesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* -
@ -54,14 +54,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/course_objectives/addobjectives',
url: '/api/course_objectives/addobjectives',
body: courseObjectivesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -74,16 +74,16 @@ export class Service {
): CancelablePromise<BaseResponse_List_CourseObjectivesTreeVO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/course_objectives/list/{id}',
url: '/api/course_objectives/list/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* --
@ -96,15 +96,15 @@ export class Service {
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/course_objectives/{id}',
url: '/api/course_objectives/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
})
});
}
/**
* id修改课程
@ -118,14 +118,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/coursesteacher',
url: '/api/coursesteacher',
body: coursesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* --
@ -139,14 +139,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/coursesteacher/addcourse',
url: '/api/coursesteacher/addcourse',
body: coursesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* word
@ -156,13 +156,13 @@ export class Service {
public static testUsingGet1(): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'GET',
url: '/coursesteacher/down',
url: '/api/coursesteacher/down',
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -177,17 +177,17 @@ export class Service {
): CancelablePromise<BaseResponse_Map_string_object_> {
return __request(OpenAPI, {
method: 'GET',
url: '/coursesteacher/index',
url: '/api/coursesteacher/index',
query: {
page: page,
pageSize: pageSize,
'page': page,
'pageSize': pageSize,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -218,25 +218,25 @@ export class Service {
): CancelablePromise<BaseResponse_PageDTO_CoursesVO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/coursesteacher/page',
url: '/api/coursesteacher/page',
query: {
assessmenttype: assessmenttype,
category: category,
isAsc: isAsc,
name: name,
nature: nature,
pageNo: pageNo,
pageSize: pageSize,
sortBy: sortBy,
teacher: teacher,
username: username,
'assessmenttype': assessmenttype,
'category': category,
'isAsc': isAsc,
'name': name,
'nature': nature,
'pageNo': pageNo,
'pageSize': pageSize,
'sortBy': sortBy,
'teacher': teacher,
'username': username,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* id查询课程
@ -249,16 +249,16 @@ export class Service {
): CancelablePromise<BaseResponse_CoursesDTO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/coursesteacher/{id}',
url: '/api/coursesteacher/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* id删除课程
@ -271,15 +271,15 @@ export class Service {
): CancelablePromise<BaseResponse> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/coursesteacher/{id}',
url: '/api/coursesteacher/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
})
});
}
/**
*
@ -293,14 +293,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/objective_content_know/addknows',
url: '/api/objective_content_know/addknows',
body: objectiveContentKnowDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -313,16 +313,16 @@ export class Service {
): CancelablePromise<BaseResponse_ObjectiveContentKnowVO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/objective_content_know/{objectiveId}',
url: '/api/objective_content_know/{objectiveId}',
path: {
objectiveId: objectiveId,
'objectiveId': objectiveId,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -336,14 +336,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/objective_contents/addcontent',
url: '/api/objective_contents/addcontent',
body: objectiveContents,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -357,14 +357,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/objective_contents/update',
url: '/api/objective_contents/update',
body: objectiveContents,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* id查询目标内容
@ -377,16 +377,16 @@ export class Service {
): CancelablePromise<BaseResponse_ObjectiveContents_> {
return __request(OpenAPI, {
method: 'GET',
url: '/objective_contents/{id}',
url: '/api/objective_contents/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -399,15 +399,15 @@ export class Service {
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/objective_contents/{id}',
url: '/api/objective_contents/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
})
});
}
/**
*
@ -421,14 +421,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/objectives_type',
url: '/api/objectives_type',
body: objectivesType,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -442,14 +442,14 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/objectives_type/addobjectives',
url: '/api/objectives_type/addobjectives',
body: objectivesType,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -462,15 +462,15 @@ export class Service {
): CancelablePromise<BaseResponse_string_> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/objectives_type/deleteobjectives/{id}',
url: '/api/objectives_type/deleteobjectives/{id}',
path: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
},
})
});
}
/**
*
@ -480,13 +480,13 @@ export class Service {
public static objectivesListUsingGet1(): CancelablePromise<BaseResponse_List_ObjectivesType_> {
return __request(OpenAPI, {
method: 'GET',
url: '/objectives_type/list',
url: '/api/objectives_type/list',
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -500,13 +500,13 @@ export class Service {
): CancelablePromise<BaseResponse_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/student_courses/addcoursess',
url: '/api/student_courses/addcoursess',
body: studentCoursesDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -2,17 +2,17 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BaseResponse_List_TeacherInfVO_ } from '../models/BaseResponse_List_TeacherInfVO_'
import type { CommonResult } from '../models/CommonResult'
import type { CommonResult_string_ } from '../models/CommonResult_string_'
import type { CommonResult_UmsAdmin_ } from '../models/CommonResult_UmsAdmin_'
import type { UmsAdmin } from '../models/UmsAdmin'
import type { UmsAdminParam } from '../models/UmsAdminParam'
import type { UmsStudentAndTeacherDTO } from '../models/UmsStudentAndTeacherDTO'
import type { UpdateAdminPasswordParam } from '../models/UpdateAdminPasswordParam'
import type { CancelablePromise } from '../core/CancelablePromise'
import { OpenAPI } from '../core/OpenAPI'
import { request as __request } from '../core/request'
import type { BaseResponse_List_TeacherInfVO_ } from '../models/BaseResponse_List_TeacherInfVO_';
import type { CommonResult } from '../models/CommonResult';
import type { CommonResult_string_ } from '../models/CommonResult_string_';
import type { CommonResult_UmsAdmin_ } from '../models/CommonResult_UmsAdmin_';
import type { UmsAdmin } from '../models/UmsAdmin';
import type { UmsAdminParam } from '../models/UmsAdminParam';
import type { UmsStudentAndTeacherDTO } from '../models/UmsStudentAndTeacherDTO';
import type { UpdateAdminPasswordParam } from '../models/UpdateAdminPasswordParam';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class UmsAdminControllerService {
/**
*
@ -26,16 +26,16 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult_string_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/code',
url: '/api/user/code',
query: {
phone: phone,
'phone': phone,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* username和name
@ -45,13 +45,13 @@ export class UmsAdminControllerService {
public static getTeacherInfListUsingGet1(): CancelablePromise<BaseResponse_List_TeacherInfVO_> {
return __request(OpenAPI, {
method: 'GET',
url: '/user/get_teacherinf_list',
url: '/api/user/get_teacherinf_list',
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -64,16 +64,16 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult> {
return __request(OpenAPI, {
method: 'GET',
url: '/user/info',
url: '/api/user/info',
query: {
name: name,
'name': name,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* token
@ -87,14 +87,14 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/login',
url: '/api/user/login',
body: umsAdmin,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -108,16 +108,16 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/personal/info',
url: '/api/user/personal/info',
query: {
id: id,
'id': id,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* token
@ -131,16 +131,16 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/phone/login',
url: '/api/user/phone/login',
query: {
phone: phone,
'phone': phone,
},
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -154,14 +154,14 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult_UmsAdmin_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/phone/register',
url: '/api/user/phone/register',
body: umsAdminParam,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
* token
@ -171,13 +171,13 @@ export class UmsAdminControllerService {
public static refreshTokenUsingGet1(): CancelablePromise<CommonResult> {
return __request(OpenAPI, {
method: 'GET',
url: '/user/refreshToken',
url: '/api/user/refreshToken',
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -191,14 +191,14 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult_UmsAdmin_ | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/register',
url: '/api/user/register',
body: umsAdminParam,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -212,14 +212,14 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/update',
url: '/api/user/update',
body: umsadmin,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -233,14 +233,14 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/update/PersonalInfo',
url: '/api/user/update/PersonalInfo',
body: umsStudentAndTeacherDto,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
/**
*
@ -254,13 +254,13 @@ export class UmsAdminControllerService {
): CancelablePromise<CommonResult | any> {
return __request(OpenAPI, {
method: 'POST',
url: '/user/updatePassword',
url: '/api/user/updatePassword',
body: updatePasswordParam,
errors: {
401: `Unauthorized`,
403: `Forbidden`,
404: `Not Found`,
},
})
});
}
}

@ -5,7 +5,7 @@
"type": "module",
"scripts": {
"dev": "vite --open",
"build": "vue-tsc && vite build",
"build": "vite build",
"preview": "vite preview",
"build:test": "vue-tsc && vite build --mode test",
"build:pro": "vue-tsc && vite build --mode production",

@ -1,8 +1,8 @@
import request from '@/utils/request'
//获取浏览记录列表
export const getRecordListService = (params) =>
request.get('/learningrecords/getall', { params })
request.get('/api/learningrecords/getall', { params })
//删除浏览记录
export function DelRecordService(ids) {
return request.delete(`h/learningrecords/delete?ids=${ids}`)
return request.delete(`h//api/learningrecords/delete?ids=${ids}`)
}

@ -1,35 +1,35 @@
import request from '@/utils/request'
// 获取课程列表
export const getCourseListApi = (params) => {
return request.get('/coursesteacher/page', {
return request.get('/api/coursesteacher/page', {
params,
})
}
// 编辑课程
export const editCourseApi = (params) => {
return request.put('/coursesteacher', params)
return request.put('/api/coursesteacher', params)
}
// 添加课程
export const addCourseApi = (data) => {
return request.post(`/coursesteacher/addcourse`, data)
return request.post(`/api/coursesteacher/addcourse`, data)
}
// 获取课程详情
export const getCourseDetailApi = (id) => {
return request.get(`/coursesteacher/${id}`)
return request.get(`/api/coursesteacher/${id}`)
}
// 删除课程
export const deleteCourseApi = (id) => {
return request.delete(`/coursesteacher/${id}`)
return request.delete(`/api/coursesteacher/${id}`)
}
// 获取课程id
export const getCourseObjectApi = (id) => {
return request.get(`/course_objectives/list/${id}`)
return request.get(`/api/course_objectives/list/${id}`)
}
// 获取教师列表
export const getTeacherListApi = () => {
return request.get('/user/get_teacherinf_list')
return request.get('/api/user/get_teacherinf_list')
}
export const fnNameGet = (params) => {
@ -44,7 +44,7 @@ export const getPageCourses = (data) => {
console.log(data.pageSize)
// return request.get(`/courses/index`,data)
return request.get(
`/coursesteacher/index?page=${data.page}&pageSize=${data.pageSize}`,
`/api/coursesteacher/index?page=${data.page}&pageSize=${data.pageSize}`,
)
}
// {id:1}

@ -3,9 +3,9 @@ import { loginType, loginResponseType, userInfoType } from './types'
//项目用户相关的请求地址
enum API {
LOGIN_URL = '/user/login',
USERINFO_URL = '/user/info',
LOGOUT_URL = '/user/logout',
LOGIN_URL = '/api/user/login',
USERINFO_URL = '/api/user/info',
LOGOUT_URL = '/api/user/logout',
}
// 用户登录
export const reqLogin = (data: loginType) =>

@ -1,48 +1,48 @@
import request from '@/utils/request'
//账号登录接口
export const userLoginService = (loginData) => {
return request.post('/user/login', loginData, {
return request.post('/api/user/login', loginData, {
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
})
}
//手机号登录接口
export const userPhoneLoginService = (phones) => {
return request.post('/user/phone/login?phone=' + phones)
return request.post('/api/user/phone/login?phone=' + phones)
}
//账号注册接口
export const userRegisterService = (jsonData) => {
return request.post('/user/register', jsonData, {
return request.post('/api/user/register', jsonData, {
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
})
}
//手机号注册接口
export const userPhoneRegisterService = (jsonData) => {
return request.post('/user/phone/register', jsonData, {
return request.post('/api/user/phone/register', jsonData, {
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
})
}
//手机号验证码请求
export const userCodeRegisterService = (phoness) => {
return request.post('/user/code?phone=' + phoness)
return request.post('/api/user/code?phone=' + phoness)
}
//用户信息接口
export const userGetInfoService = (token) =>
request.get('/user/info', {
request.get('/api/user/info', {
headers: { Authorization: `Bearer ${token}` },
})
//修改用户信息
export const userChangeService = (jsonData) => {
return request.post('/user/update', jsonData, {
return request.post('/api/user/update', jsonData, {
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
})
}
//获取身份信息
export const userIdenService = (id) => {
return request.post('/user/personal/info?id=' + id)
return request.post('/api/user/personal/info?id=' + id)
}
//修改身份信息
export const userIdenChangeService = (dataToSend) => {
return request.post('/user/update/PersonalInfo', dataToSend, {
return request.post('/api/user/update/PersonalInfo', dataToSend, {
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
})
}

Loading…
Cancel
Save