mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-14 05:16:45 +08:00
t
This commit is contained in:
@@ -7,8 +7,7 @@
|
|||||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||||
*/
|
*/
|
||||||
import http from "./config";
|
import http from "./config";
|
||||||
import qs from 'qs';
|
import qs from "qs";
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 接口传参数方式(get)
|
* 接口传参数方式(get)
|
||||||
@@ -33,7 +32,7 @@ import qs from 'qs';
|
|||||||
* (request的Header:'Content-Type'= 'application/x-www-form-urlencoded')
|
* (request的Header:'Content-Type'= 'application/x-www-form-urlencoded')
|
||||||
* let data = {"code":"1234","name":"yyyy"};
|
* let data = {"code":"1234","name":"yyyy"};
|
||||||
* axios.post(`${this.$url}/test/testRequest`,qs.stringify({data})).then()
|
* axios.post(`${this.$url}/test/testRequest`,qs.stringify({data})).then()
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* 3.'Content-Type'= 'application/json,传参格式为 raw (JSON格式)。
|
* 3.'Content-Type'= 'application/json,传参格式为 raw (JSON格式)。
|
||||||
* (全局请求头:'Content-Type'= 'application/x-www-form-urlencoded')
|
* (全局请求头:'Content-Type'= 'application/x-www-form-urlencoded')
|
||||||
@@ -44,59 +43,65 @@ import qs from 'qs';
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
//上传文件
|
//上传文件
|
||||||
export const uploadFile = (obj) => http.post('/test/testRequest', qs.stringify({ obj }));
|
export const uploadFile = (obj) =>
|
||||||
|
http.post("/test/testRequest", qs.stringify({ obj }));
|
||||||
|
|
||||||
// 接口-请求
|
// 接口-请求
|
||||||
|
|
||||||
//创建学习路径
|
//创建学习路径
|
||||||
export const createLearnPath = (obj) => http.post('/admin/router/edit', obj);
|
export const createLearnPath = (obj) => http.post("/admin/router/edit", obj);
|
||||||
// 获取学习路径图列表
|
// 获取学习路径图列表
|
||||||
export const getLearnPath = (obj) => http.post('/admin/router/list', obj);
|
export const getLearnPath = (obj) => http.post("/admin/router/list", obj);
|
||||||
//学习路径图的发布、停用、删除
|
//学习路径图的发布、停用、删除
|
||||||
export const handleLearnPath = (obj) => http.post('/admin/router/handle', obj);
|
export const handleLearnPath = (obj) => http.post("/admin/router/handle", obj);
|
||||||
//获取路径图统计数据
|
//获取路径图统计数据
|
||||||
export const getLearnCount = (routerId) => http.get('/admin/router/getCount', { params: { routerId: routerId } })
|
export const getLearnCount = (routerId) =>
|
||||||
|
http.get("/admin/router/getCount", { params: { routerId: routerId } });
|
||||||
|
|
||||||
//新建或编辑关卡
|
//新建或编辑关卡
|
||||||
export const editChapter = (obj) => http.post('/admin/router/editChapter', obj);
|
export const editChapter = (obj) => http.post("/admin/router/editChapter", obj);
|
||||||
// 编辑路径图设置
|
// 编辑路径图设置
|
||||||
export const setConfig = (obj) => http.post('/admin/router/setConfig', obj);
|
export const setConfig = (obj) => http.post("/admin/router/setConfig", obj);
|
||||||
//获取学员列表
|
//获取学员列表
|
||||||
export const getStudent = (obj) => http.post('/admin/router/studentList', obj);
|
export const getStudent = (obj) => http.post("/admin/router/studentList", obj);
|
||||||
//获取路径图详情-包含关卡及任务列表
|
//获取路径图详情-包含关卡及任务列表
|
||||||
export const getRouterDetail = (routerId) => http.get('/admin/router/detail', {
|
export const getRouterDetail = (routerId) =>
|
||||||
params: {
|
http.get("/admin/router/detail", {
|
||||||
routerId: routerId,
|
params: {
|
||||||
}
|
routerId: routerId,
|
||||||
});
|
},
|
||||||
|
});
|
||||||
//添加学员
|
//添加学员
|
||||||
export const addStudent = (obj) => http.post('/admin/router/addStudent', obj);
|
export const addStudent = (obj) => http.post("/admin/router/addStudent", obj);
|
||||||
//删除学员
|
//删除学员
|
||||||
export const delStudent = (obj) => http.post('/admin/router/deleteStudent', obj);
|
export const delStudent = (obj) =>
|
||||||
|
http.post("/admin/router/deleteStudent", obj);
|
||||||
// 获取学员路径图进度明细
|
// 获取学员路径图进度明细
|
||||||
export const stuProgress = (obj) => http.post('/admin/router/studentProcess', obj);
|
export const stuProgress = (obj) =>
|
||||||
|
http.post("/admin/router/studentProcess", obj);
|
||||||
|
|
||||||
//项目基础信息-----------------------------------
|
//项目基础信息-----------------------------------
|
||||||
//项目积分榜单
|
//项目积分榜单
|
||||||
export const scoreRank = (obj) => http.post('/admin/project/scoreRank', obj);
|
export const scoreRank = (obj) => http.post("/admin/project/scoreRank", obj);
|
||||||
//排行榜
|
//排行榜
|
||||||
export const billboard = (obj) => http.post('/admin/project/billboard', obj);
|
export const billboard = (obj) => http.post("/admin/project/billboard", obj);
|
||||||
//项目基础信息-----------------------------------
|
//项目基础信息-----------------------------------
|
||||||
|
|
||||||
//获取字典信息
|
//获取字典信息
|
||||||
export const getDict = (obj) => http.post('/dict/getList', obj)
|
export const getDict = (obj) => http.post("/dict/getList", obj);
|
||||||
//获取组织树
|
//获取组织树
|
||||||
export const getOrgTree = (obj) => http.post('/admin/router/orgList', obj)
|
export const getOrgTree = (obj) => http.post("/admin/router/orgList", obj);
|
||||||
|
|
||||||
|
|
||||||
// 获取组织结构树
|
// 获取组织结构树
|
||||||
export const orgtree = () => http.get('/org/tree');
|
export const orgtree = () => http.get("/org/tree");
|
||||||
|
|
||||||
|
|
||||||
//获取积分列表
|
//获取积分列表
|
||||||
export const noticeList = (projectId) => http.post(`http://localhost:8080/api/admin/project/noticeList?projectId=` + projectId + ``)
|
export const noticeList = (projectId) =>
|
||||||
|
http.post(
|
||||||
|
`http://localhost:8080/api/admin/project/noticeList?projectId=` +
|
||||||
|
projectId +
|
||||||
|
``
|
||||||
|
);
|
||||||
|
|
||||||
// 测试方法
|
// 测试方法
|
||||||
// import * as api from '../../api/index'
|
// import * as api from '../../api/index'
|
||||||
@@ -106,5 +111,4 @@ export const noticeList = (projectId) => http.post(`http://localhost:8080/api/ad
|
|||||||
// console.log(err)
|
// console.log(err)
|
||||||
// })
|
// })
|
||||||
|
|
||||||
|
// export const choiceEvaluation = (obj) => http.post('/evaluation/choiceEvaluation', obj);
|
||||||
// export const choiceEvaluation = (obj) => http.post('/evaluation/choiceEvaluation', obj);
|
|
||||||
|
|||||||
@@ -8,21 +8,21 @@
|
|||||||
*/
|
*/
|
||||||
const { defineConfig } = require("@vue/cli-service");
|
const { defineConfig } = require("@vue/cli-service");
|
||||||
module.exports = defineConfig({
|
module.exports = defineConfig({
|
||||||
publicPath: '/manage',
|
publicPath: "/manage",
|
||||||
// transpileDependencies: true,
|
// transpileDependencies: true,
|
||||||
devServer: {
|
devServer: {
|
||||||
port: 8080,
|
port: 8080,
|
||||||
proxy: {
|
proxy: {
|
||||||
"/manageApi": {
|
"/manageApi": {
|
||||||
// target:"http://192.168.100.208:30001",
|
// target:"http://192.168.100.208:30001",
|
||||||
target: "http://111.231.196.214:30001/", //这里后台的地址模拟的;应该填写你们真实的后台接口
|
target: "http://111.231.196.214:30001/", //这里后台的地址模拟的;应该填写你们真实的后台接口
|
||||||
changeOrigin: true, //表示是否改变原域名
|
changeOrigin: true, //表示是否改变原域名
|
||||||
// secure: false,
|
// secure: false,
|
||||||
// ws: false, //表示WebSocket协议
|
// ws: false, //表示WebSocket协议
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
"^/manageApi": "",
|
"^/manageApi": "",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user