diff --git a/api/modules/cousre_subject_classification.ts b/api/modules/cousre_subject_classification.ts new file mode 100644 index 0000000..7a4f8cd --- /dev/null +++ b/api/modules/cousre_subject_classification.ts @@ -0,0 +1,55 @@ +// api/modules/course.ts +import { createRequestClient } from '../request' +import { SERVICE_MAP } from '../config' +import type { + ICourseMedicalTreeResponse, + IUserLateCourseListResponse, + IMarketCourseListResponse +} from '@/types/course' +import type { ISearchRequest, ISearchResponse } from '@/types/search' + +const client = createRequestClient({ baseURL: SERVICE_MAP.MAIN }) + +/** + * 课程相关API + */ +export const courseSubjectClassificationApi = { + /** + * 医学 + * 获取课程分类树 + * @returns 分类数据 + */ + getCourseMedicalTree() { + return client.request({ + url: 'medical/home/getCourseMedicalTree', + method: 'POST', + data: {} + }) + }, + + /** + * 心理学 + * 获取课程分类树 + * @returns 分类数据 + */ + getCourseSoulTree() { + return client.request({ + url: 'psyche/home/getPsycheLabels', + method: 'POST', + data: { id: 0 } + }) + }, + + /** + * 国学 + * 获取课程分类树 + * @returns 分类数据 + */ + getCourseSociologyTree() { + return client.request({ + url: 'sociology/home/getSociologyLabels', + method: 'POST', + data: { id: 0 } + }) + } +} diff --git a/manifest.json b/manifest.json index 2bb601b..111a643 100644 --- a/manifest.json +++ b/manifest.json @@ -31,10 +31,12 @@ "permissions" : [ "", "", + "", "", "", "", - "" + "", + "" ], "abiFilters" : [ "armeabi-v7a", "arm64-v8a", "x86" ], "minSdkVersion" : 23, diff --git a/pages/book/index.vue b/pages/book/index.vue index 6614d5a..584db7e 100644 --- a/pages/book/index.vue +++ b/pages/book/index.vue @@ -1,7 +1,7 @@