diff --git a/src/api/uav/chapter.js b/src/api/uav/chapter.js new file mode 100644 index 0000000..cf5957b --- /dev/null +++ b/src/api/uav/chapter.js @@ -0,0 +1,28 @@ +import request from '@/config/axios' +export const searchChapter = async (param) => { + return await request.get({ + url: '/admin-api/applet/wrj/chapter/list', + params: param + }) +} + +export const updateChapter = async (data) => { + return await request.put({ + url: '/admin-api/applet/wrj/chapter/update', + data: data + }) +} + +export const addChapter = async (data) => { + return await request.post({ + url: '/admin-api/applet/wrj/chapter/add', + data: data, + isSubmitForm: true + }) +} + +export const deleteChapter = async (id) => { + return await request.delete({ + url: `/admin-api/applet/wrj/chapter/delete?id=${id}` + }) +} diff --git a/src/api/uav/question.js b/src/api/uav/question.js new file mode 100644 index 0000000..a95316e --- /dev/null +++ b/src/api/uav/question.js @@ -0,0 +1,35 @@ +import request from '@/config/axios' +export const searchQuestion = async (param) => { + return await request.get({ + url: '/admin-api/applet/wrj/question/list', + params: param + }) +} + +export const updateQuestion = async (data) => { + return await request.put({ + url: '/admin-api/applet/wrj/question/update', + data: data + }) +} + +export const addQuestion = async (data) => { + return await request.post({ + url: '/admin-api/applet/wrj/question/add', + data: data, + isSubmitForm: true + }) +} + +export const deleteQuestion = async (id) => { + return await request.delete({ + url: `/admin-api/applet/wrj/question/delete?id=${id}` + }) +} + +export const uploadFile = async (data) => { + return await request.post({ + url: '/admin-api/applet/wrj/question/upload', + data: data + }) +} diff --git a/src/views/Question/UAV/Components/QuestionAddForm.vue b/src/views/Question/UAV/Components/QuestionAddForm.vue index 5163ed3..7e1186e 100644 --- a/src/views/Question/UAV/Components/QuestionAddForm.vue +++ b/src/views/Question/UAV/Components/QuestionAddForm.vue @@ -121,7 +121,7 @@ - + - +