mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-11 03:46:45 +08:00
Merge branch 'user-modify'
# Conflicts: # src/api/ThirdApi.js
This commit is contained in:
37
src/App.vue
37
src/App.vue
@@ -28,8 +28,8 @@ import BreadCrumb from "@/components/BreadCrumb";
|
|||||||
import zhCN from "ant-design-vue/es/locale/zh_CN";
|
import zhCN from "ant-design-vue/es/locale/zh_CN";
|
||||||
import * as api1 from "@/api/index1";
|
import * as api1 from "@/api/index1";
|
||||||
import * as api2 from "@/api/index";
|
import * as api2 from "@/api/index";
|
||||||
import {boeRequest, request} from "@/api/request";
|
import {request} from "@/api/request";
|
||||||
import {USER_PERMISSION} from "@/api/apis";
|
import {USER_PERMISSION, VALIDATE_TOKEN} from "@/api/apis";
|
||||||
|
|
||||||
const store = useStore();
|
const store = useStore();
|
||||||
const isLogin = ref(false);
|
const isLogin = ref(false);
|
||||||
@@ -37,13 +37,11 @@ const isLogin = ref(false);
|
|||||||
console.log("版本3.1.2------------");
|
console.log("版本3.1.2------------");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 监听关闭浏览器
|
// 监听关闭浏览器
|
||||||
let time1 = ref(0);
|
let time1 = ref(0);
|
||||||
let time2 = ref(0);
|
let time2 = ref(0);
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
init()
|
|
||||||
window.addEventListener('beforeunload', e => beforeunloadHandler(e));
|
window.addEventListener('beforeunload', e => beforeunloadHandler(e));
|
||||||
window.addEventListener('unload', e => unloadHandler(e));
|
window.addEventListener('unload', e => unloadHandler(e));
|
||||||
})
|
})
|
||||||
@@ -53,18 +51,7 @@ function beforeunloadHandler() {
|
|||||||
time1.value = new Date().getTime();
|
time1.value = new Date().getTime();
|
||||||
}
|
}
|
||||||
|
|
||||||
function init() {
|
|
||||||
getUserInfo();
|
|
||||||
getUserPermission();
|
|
||||||
initDict("content_type"); //内容分类
|
|
||||||
initDict("project_level"); //项目级别
|
|
||||||
initDict("project_sys"); //培训分类
|
|
||||||
initDict("project_pic"); //项目封面
|
|
||||||
initDict("router_pic"); //路径图封面
|
|
||||||
initDict("course_pic"); //课程封面
|
|
||||||
initDict("job_type"); //岗位
|
|
||||||
initDict("band"); //band
|
|
||||||
}
|
|
||||||
|
|
||||||
function unloadHandler() {
|
function unloadHandler() {
|
||||||
time2.value = new Date().getTime() - time1.value;
|
time2.value = new Date().getTime() - time1.value;
|
||||||
@@ -74,23 +61,6 @@ function unloadHandler() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async function getUserInfo() {
|
|
||||||
const userInfo = await api2.userInfo();
|
|
||||||
store.commit("SET_USER", userInfo.data.data);
|
|
||||||
}
|
|
||||||
|
|
||||||
async function initDict(key) {
|
|
||||||
const list = await getDictList(key);
|
|
||||||
store.commit("SET_DICT", {key, data: list});
|
|
||||||
}
|
|
||||||
|
|
||||||
function getUserPermission(){
|
|
||||||
request(USER_PERMISSION,{permissionType:'PAGE'}).then(res=>{
|
|
||||||
store.commit("SET_PERMISSION", res.result.flatMap(t=>t?.permissionPageList.map(s=>s.url)));
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const getDictList = (param) => api1.getDictTree({code: param,}).then((res) => res.data.data);
|
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
#app {
|
#app {
|
||||||
@@ -109,6 +79,7 @@ const getDictList = (param) => api1.getDictTree({code: param,}).then((res) => re
|
|||||||
text-align: center !important;
|
text-align: center !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.ant-table-tbody > tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected) > td {
|
.ant-table-tbody > tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected) > td {
|
||||||
background: #f6f9fd;
|
background: #f6f9fd;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,6 +12,10 @@ export const CASE_PAGE = "/systemapi/xboe/m/boe/cases/pagelist post formData";
|
|||||||
export const EXAM_PAPER_PAGE = "/systemapi/xboe/m/exam/paper/querylist post formData";
|
export const EXAM_PAPER_PAGE = "/systemapi/xboe/m/exam/paper/querylist post formData";
|
||||||
export const TEST_PAGE = "/api/b1/system/quiz/quiz-list post formData";
|
export const TEST_PAGE = "/api/b1/system/quiz/quiz-list post formData";
|
||||||
export const ONLINE_PAGE = "/systemapi/xboe/m/course/manage/pagelist post formData";
|
export const ONLINE_PAGE = "/systemapi/xboe/m/course/manage/pagelist post formData";
|
||||||
|
|
||||||
|
export const LOGOUT = "/userbasic/logout post";
|
||||||
|
export const REFRESH_TOKEN_API = "/userbasic/refreshToken";
|
||||||
|
|
||||||
export const COURSE_AUDIT = "/xboe/m/course/manage/audit post formData";
|
export const COURSE_AUDIT = "/xboe/m/course/manage/audit post formData";
|
||||||
export const OTHER_AUDIT = "/xboe/m/course/audit/appoint post formData";
|
export const OTHER_AUDIT = "/xboe/m/course/audit/appoint post formData";
|
||||||
export const ONLINE_COURSE_DEL = (id, courseId) => `/systemapi/xboe/school/study/course/delete-signup?id=${id}&couserId=${courseId} post`;
|
export const ONLINE_COURSE_DEL = (id, courseId) => `/systemapi/xboe/school/study/course/delete-signup?id=${id}&couserId=${courseId} post`;
|
||||||
@@ -26,9 +26,12 @@ export const ASSESSMENT_DETAIL = (assessmentId)=>`/assessment/queryAssessmentDet
|
|||||||
|
|
||||||
export const USER_LIST_PAGE = "/admin/thirdApi/user/list";
|
export const USER_LIST_PAGE = "/admin/thirdApi/user/list";
|
||||||
//学员列表 没有分页数据 只能通过名称检索 速度较快
|
//学员列表 没有分页数据 只能通过名称检索 速度较快
|
||||||
export const USER_LIST = "/admin/thirdApi/user/searchList";
|
export const USER_LIST = "/admin/thirdApi/user/list";
|
||||||
export const ORG_LIST = "/admin/thirdApi/org/list";
|
export const ORG_LIST = "/admin/thirdApi/org/list";
|
||||||
export const ORG_CHILD_LIST = "/admin/thirdApi/org/info";
|
export const ORG_CHILD_LIST = "/admin/thirdApi/org/info";
|
||||||
|
|
||||||
export const AUDIENCE_LIST = "/admin/thirdApi/audience/userAudiences";
|
export const AUDIENCE_LIST = "/admin/thirdApi/audience/userAudiences";
|
||||||
export const USER_PERMISSION = "/admin/thirdApi/permission/listByUser";
|
export const USER_PERMISSION = "/admin/thirdApi/permission/listByUser";
|
||||||
|
export const VALIDATE_TOKEN = "/admin/thirdApi/validateToken";
|
||||||
|
export const REFRESH_TOKEN = "/admin/thirdApi/refreshToken";
|
||||||
|
export const USER_INFO = "/admin/CheckUser/userInfo";
|
||||||
|
|||||||
@@ -8,6 +8,7 @@
|
|||||||
*/
|
*/
|
||||||
import http from "./config";
|
import http from "./config";
|
||||||
import qs from "qs";
|
import qs from "qs";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
// import { getCookie } from '../api/method'
|
// import { getCookie } from '../api/method'
|
||||||
/**
|
/**
|
||||||
* 接口传参数方式(get)
|
* 接口传参数方式(get)
|
||||||
@@ -188,7 +189,7 @@ export const auditStudentBatch = (obj) => http.post('/admin/student/auditStudent
|
|||||||
// //面授课批量导入成绩
|
// //面授课批量导入成绩
|
||||||
export const batchImportScore = (obj) =>
|
export const batchImportScore = (obj) =>
|
||||||
http.post('/admin/student/importHomeWork', obj, {
|
http.post('/admin/student/importHomeWork', obj, {
|
||||||
headers: { "Content-Type": "multipart/form-data" },
|
headers: { "Content-Type": "multipart/form-data",token:getCookieForName("token") },
|
||||||
});
|
});
|
||||||
//数据导入状态
|
//数据导入状态
|
||||||
export const getImportStatus = (uuid) => http.get('/admin/student/getImportStatus', { params: { uuid: uuid } })
|
export const getImportStatus = (uuid) => http.get('/admin/student/getImportStatus', { params: { uuid: uuid } })
|
||||||
@@ -197,7 +198,7 @@ export const getImportStatus = (uuid) => http.get('/admin/student/getImportStatu
|
|||||||
// export const exportHomeWork=(obj)=>http.get('admin/student/exportHomeWork',{params:obj})
|
// export const exportHomeWork=(obj)=>http.get('admin/student/exportHomeWork',{params:obj})
|
||||||
|
|
||||||
// 面授课导入学员
|
// 面授课导入学员
|
||||||
export const FaceTeachImportStudent = (obj) => http.post('/admin/student/importStudent', obj, { headers: { "Content-Type": "multipart/form-data" } })
|
export const FaceTeachImportStudent = (obj) => http.post('/admin/student/importStudent', obj, { headers: { "Content-Type": "multipart/form-data" },token:getCookieForName("token") })
|
||||||
//成绩录入
|
//成绩录入
|
||||||
export const updateStudent = (obj) => http.post('/admin/student/homeWorkScoreEntry', obj)
|
export const updateStudent = (obj) => http.post('/admin/student/homeWorkScoreEntry', obj)
|
||||||
|
|
||||||
@@ -227,7 +228,7 @@ export const createExamination = (obj) => http.post('/examination/createExaminat
|
|||||||
//催促考试
|
//催促考试
|
||||||
export const batchSendMessage = (obj) => http.post('/admin/taskmanage/batchSendMessage', obj)
|
export const batchSendMessage = (obj) => http.post('/admin/taskmanage/batchSendMessage', obj)
|
||||||
// 外部考试导入成绩
|
// 外部考试导入成绩
|
||||||
export const ImportExternalExamScore = (obj) => http.post('/admin/external/exam/manage/importExternalExamScore', obj, { headers: { "Content-Type": "multipart/form-data" } })
|
export const ImportExternalExamScore = (obj) => http.post('/admin/external/exam/manage/importExternalExamScore', obj, { headers: { "Content-Type": "multipart/form-data",token:getCookieForName("token") } })
|
||||||
//分组
|
//分组
|
||||||
export const changeGroupByStudentId = (obj) => http.post('/admin/student/changeGroupByStudentId', obj)
|
export const changeGroupByStudentId = (obj) => http.post('/admin/student/changeGroupByStudentId', obj)
|
||||||
//导入小组
|
//导入小组
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import http from "./config";
|
import http from "./config";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
// import qs from 'qs';
|
// import qs from 'qs';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -42,13 +43,13 @@ export const createEvaluation = (obj) =>
|
|||||||
//上传组件
|
//上传组件
|
||||||
export const fileUp = (data) =>
|
export const fileUp = (data) =>
|
||||||
http.post("/file/upload", data, {
|
http.post("/file/upload", data, {
|
||||||
headers: { "Content-Type": "multipart/form-data" },
|
headers: { "Content-Type": "multipart/form-data",token:getCookieForName("token") },
|
||||||
});
|
});
|
||||||
|
|
||||||
//上传文件
|
//上传文件
|
||||||
export const baseVoteupload = (data) =>
|
export const baseVoteupload = (data) =>
|
||||||
http.post("/vote/baseVoteupload", data, {
|
http.post("/vote/baseVoteupload", data, {
|
||||||
headers: { "Content-Type": "multipart/form-data" },
|
headers: { "Content-Type": "multipart/form-data",token:getCookieForName("token") },
|
||||||
});
|
});
|
||||||
|
|
||||||
//删除测评信息
|
//删除测评信息
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import http from "./config";
|
import http from "./config";
|
||||||
import qs from "qs";
|
import qs from "qs";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 接口传参数方式(get)
|
* 接口传参数方式(get)
|
||||||
@@ -44,7 +45,7 @@ import qs from "qs";
|
|||||||
export const baseVoteupload = (obj) =>
|
export const baseVoteupload = (obj) =>
|
||||||
http.post("/vote/baseVoteupload", obj, {
|
http.post("/vote/baseVoteupload", obj, {
|
||||||
headers: {
|
headers: {
|
||||||
token: "123",
|
token: getCookieForName("token"),
|
||||||
"Content-Type": "multipart/form-data",
|
"Content-Type": "multipart/form-data",
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,8 +1,10 @@
|
|||||||
import {isRef, reactive, ref, toRefs, unref, watch, watchEffect} from "vue";
|
import {isRef, reactive, ref, toRefs, unref, watch, watchEffect} from "vue";
|
||||||
import {getCookieForName, throttle} from "@/api/method";
|
import {getCookieForName, setCookie, throttle} from "@/api/method";
|
||||||
import JSONBigInt from "json-bigint";
|
import JSONBigInt from "json-bigint";
|
||||||
import router from "@/router";
|
import router from "@/router";
|
||||||
import {message} from "ant-design-vue";
|
import {message} from "ant-design-vue";
|
||||||
|
import {REFRESH_TOKEN, VALIDATE_TOKEN} from "@/api/apis";
|
||||||
|
import {REFRESH_TOKEN_API} from "@/api/ThirdApi";
|
||||||
|
|
||||||
const JSONBigIntStr = JSONBigInt({ storeAsString: true });
|
const JSONBigIntStr = JSONBigInt({ storeAsString: true });
|
||||||
|
|
||||||
@@ -79,68 +81,68 @@ export function useBoeApiPage(_url, params = {}, config = {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export function useBoeApi(_url, params = {}, config = {
|
// export function useBoeApi(_url, params = {}, config = {
|
||||||
init: true,
|
// init: true,
|
||||||
result: res => res.result,
|
// result: res => res.result,
|
||||||
}) {
|
// }) {
|
||||||
|
//
|
||||||
|
// const state = reactive({
|
||||||
|
// data: [],
|
||||||
|
// loading: false,
|
||||||
|
// });
|
||||||
|
// watch(() => params, () => {
|
||||||
|
// fetch();
|
||||||
|
// });
|
||||||
|
//
|
||||||
|
// function fetch() {
|
||||||
|
// state.loading = true;
|
||||||
|
// return boeRequest(_url, params).then(r => {
|
||||||
|
// state.data = config.result(r);
|
||||||
|
// state.loading = false;
|
||||||
|
// });
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// config.init && fetch();
|
||||||
|
// return {
|
||||||
|
// ...toRefs(state),
|
||||||
|
// fetch,
|
||||||
|
// };
|
||||||
|
// }
|
||||||
|
|
||||||
const state = reactive({
|
// export function useBoeUserListPage(_url, params = {}, init = true) {
|
||||||
data: [],
|
//
|
||||||
loading: false,
|
// const state = reactive({
|
||||||
});
|
// data: [],
|
||||||
watch(() => params, () => {
|
// loading: false,
|
||||||
fetch();
|
// total: 0,
|
||||||
});
|
// totalPage: 0,
|
||||||
|
// page: 1,
|
||||||
function fetch() {
|
// ...params
|
||||||
state.loading = true;
|
// });
|
||||||
return boeRequest(_url, params).then(r => {
|
//
|
||||||
state.data = config.result(r);
|
// watch(() => params.keyword, throttle(fetch, 600));
|
||||||
state.loading = false;
|
// watch(() => params.page, fetch);
|
||||||
});
|
//
|
||||||
}
|
// function fetch() {
|
||||||
|
// state.loading = true;
|
||||||
config.init && fetch();
|
// if (!params.keyword) {
|
||||||
return {
|
// state.loading = false;
|
||||||
...toRefs(state),
|
// return;
|
||||||
fetch,
|
// }
|
||||||
};
|
// return boeRequest(_url, params).then(r => {
|
||||||
}
|
// state.data = params.page === 1 ? r.result.userInfoList : [...state.data, ...r.result.userInfoList];
|
||||||
|
// state.totalPage = r.result.totalPage;
|
||||||
export function useBoeUserListPage(_url, params = {}, init = true) {
|
// state.total = r.result.totalElement;
|
||||||
|
// state.loading = false;
|
||||||
const state = reactive({
|
// });
|
||||||
data: [],
|
// }
|
||||||
loading: false,
|
//
|
||||||
total: 0,
|
// init && fetch();
|
||||||
totalPage: 0,
|
// return {
|
||||||
page: 1,
|
// ...toRefs(state),
|
||||||
...params
|
// fetch,
|
||||||
});
|
// };
|
||||||
|
// }
|
||||||
watch(() => params.keyword, throttle(fetch, 600));
|
|
||||||
watch(() => params.page, fetch);
|
|
||||||
|
|
||||||
function fetch() {
|
|
||||||
state.loading = true;
|
|
||||||
if (!params.keyword) {
|
|
||||||
state.loading = false;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return boeRequest(_url, params).then(r => {
|
|
||||||
state.data = params.page === 1 ? r.result.userInfoList : [...state.data, ...r.result.userInfoList];
|
|
||||||
state.totalPage = r.result.totalPage;
|
|
||||||
state.total = r.result.totalElement;
|
|
||||||
state.loading = false;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
init && fetch();
|
|
||||||
return {
|
|
||||||
...toRefs(state),
|
|
||||||
fetch,
|
|
||||||
};
|
|
||||||
}
|
|
||||||
export function useNewRowsPageNoInit(_url, params) {
|
export function useNewRowsPageNoInit(_url, params) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
data: [],
|
data: [],
|
||||||
@@ -247,6 +249,57 @@ export function useRowsPage(_url, params, init = true) {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页只返回 total 无分页信息
|
||||||
|
* @param _url
|
||||||
|
* @param params
|
||||||
|
* @param init
|
||||||
|
* @param listing
|
||||||
|
*/
|
||||||
|
export function useTotalPage(_url, params, init = true,listing = false) {
|
||||||
|
|
||||||
|
const state = reactive({
|
||||||
|
data: [],
|
||||||
|
total: 1,
|
||||||
|
current: 1,
|
||||||
|
pages: 1,
|
||||||
|
pageNo: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
loading: false
|
||||||
|
});
|
||||||
|
|
||||||
|
if (isRef(params) && listing) {
|
||||||
|
watch(params.value, () => {
|
||||||
|
fetch();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
if (isRef(_url)) {
|
||||||
|
watchEffect(fetch);
|
||||||
|
} else {
|
||||||
|
init && fetch();
|
||||||
|
}
|
||||||
|
|
||||||
|
function reset() {
|
||||||
|
state.data = [];
|
||||||
|
state.loading = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
function fetch() {
|
||||||
|
state.loading = true;
|
||||||
|
return request(unref(_url), unref(params)).then(r => {
|
||||||
|
state.data = r.data.list;
|
||||||
|
state.total = r.data.total;
|
||||||
|
state.loading = false;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
...toRefs(state),
|
||||||
|
fetch,
|
||||||
|
reset,
|
||||||
|
};
|
||||||
|
}
|
||||||
export function usePage(_url, params, init = true,listing = false) {
|
export function usePage(_url, params, init = true,listing = false) {
|
||||||
|
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
@@ -291,6 +344,42 @@ export function usePage(_url, params, init = true,listing = false) {
|
|||||||
reset,
|
reset,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
export function useThrottlePage(_url, params = {}, init = true) {
|
||||||
|
|
||||||
|
const state = reactive({
|
||||||
|
data: [],
|
||||||
|
loading: false,
|
||||||
|
total: 0,
|
||||||
|
totalPage: 0,
|
||||||
|
page: 1,
|
||||||
|
pageNo: 1,
|
||||||
|
...params
|
||||||
|
});
|
||||||
|
|
||||||
|
watch(() => params.keyword, throttle(fetch, 600));
|
||||||
|
watch(() => params.page, fetch);
|
||||||
|
|
||||||
|
function fetch() {
|
||||||
|
state.loading = true;
|
||||||
|
if (!params.keyword) {
|
||||||
|
state.loading = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
return request(_url, params).then(r => {
|
||||||
|
state.data = params.pageNo === 1 ? r.data.list : [...state.data, ...r.data.list];
|
||||||
|
state.totalPage = r.data.total/10 || 1;
|
||||||
|
state.total = r.data.total;
|
||||||
|
state.loading = false;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
init && fetch();
|
||||||
|
return {
|
||||||
|
...toRefs(state),
|
||||||
|
fetch,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
export function useRequest(_url, params, init = true) {
|
export function useRequest(_url, params, init = true) {
|
||||||
|
|
||||||
@@ -318,7 +407,32 @@ export function useRequest(_url, params, init = true) {
|
|||||||
fetchData,
|
fetchData,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
export function useArrayRequest(_url, params, init = true) {
|
||||||
|
|
||||||
|
const data = ref([]);
|
||||||
|
const loading = ref(false);
|
||||||
|
|
||||||
|
if (isRef(params)) {
|
||||||
|
watch(params.value, () => {
|
||||||
|
fetchData();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function fetchData() {
|
||||||
|
loading.value = true;
|
||||||
|
request(_url, unref(params)).then(r => {
|
||||||
|
data.value = r.data;
|
||||||
|
loading.value = false;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
init && fetchData();
|
||||||
|
return {
|
||||||
|
data,
|
||||||
|
loading,
|
||||||
|
fetchData,
|
||||||
|
};
|
||||||
|
}
|
||||||
export async function boeRequest(_url, params = {}) {
|
export async function boeRequest(_url, params = {}) {
|
||||||
const s = _url.split(" ");
|
const s = _url.split(" ");
|
||||||
let url = s[0];
|
let url = s[0];
|
||||||
@@ -380,13 +494,20 @@ export async function request(_url, params) {
|
|||||||
if (res.code === 0 || res.code === 200) {
|
if (res.code === 0 || res.code === 200) {
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
if (res.code === 1000) {
|
if (res.code === 1000 || res.code === 1002) {
|
||||||
(process.env.NODE_ENV === 'development' || process.env.NODE_ENV === 'alpine') ?
|
(process.env.NODE_ENV === 'development' || process.env.NODE_ENV === 'alpine') ?
|
||||||
router.push({path: 'login', query: { returnUrl: router.currentRoute.value.fullPath }}) :
|
router.push({path: 'login', query: { returnUrl: router.currentRoute.value.fullPath }}) :
|
||||||
(window.location.href = process.env.VUE_APP_LOGIN_URL + encodeURIComponent(window.location.protocol + process.env.VUE_APP_BOE_API_URL + process.env.VUE_APP_BASE + router.currentRoute.value.fullPath))
|
(window.location.href = process.env.VUE_APP_LOGIN_URL + encodeURIComponent(window.location.protocol + process.env.VUE_APP_BOE_API_URL + process.env.VUE_APP_BASE + router.currentRoute.value.fullPath))
|
||||||
localStorage.removeItem('refreshPage')
|
localStorage.removeItem('refreshPage')
|
||||||
return Promise.reject(res);
|
return Promise.reject(res);
|
||||||
|
}else if(res.code=== 1001){
|
||||||
|
return boeRequest(REFRESH_TOKEN_API).then((res)=>{
|
||||||
|
if(res.code===0 || res.code === 200){
|
||||||
|
return request(_url, params)
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
//刷新token
|
||||||
res.show ? message.error(res.msg):message.error('系统接口数据异常,请联系管理员');
|
res.show ? message.error(res.msg):message.error('系统接口数据异常,请联系管理员');
|
||||||
return Promise.reject(res);
|
return Promise.reject(res);
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -174,26 +174,26 @@
|
|||||||
<router-link to="/researchmanage">评估管理</router-link>
|
<router-link to="/researchmanage">评估管理</router-link>
|
||||||
</a-menu-item>
|
</a-menu-item>
|
||||||
|
|
||||||
<a-sub-menu key="sub6">
|
<!-- <a-sub-menu key="sub6">-->
|
||||||
<template #icon>
|
<!-- <template #icon>-->
|
||||||
<div class="imgBox">
|
<!-- <div class="imgBox">-->
|
||||||
<img
|
<!-- <img-->
|
||||||
style="width: 22px; height: 22px"
|
<!-- style="width: 22px; height: 22px"-->
|
||||||
src="../assets/images/navleft/review.png"
|
<!-- src="../assets/images/navleft/review.png"-->
|
||||||
/>
|
<!-- />-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
</template>
|
<!-- </template>-->
|
||||||
<template #title>系统管理</template>
|
<!-- <template #title>系统管理</template>-->
|
||||||
<a-menu-item key="sub6-1">
|
<!-- <a-menu-item key="sub6-1">-->
|
||||||
<span
|
<!-- <span-->
|
||||||
:class="{
|
<!-- :class="{-->
|
||||||
circleActive: selectedKeys[0] === 'sub6-1',
|
<!-- circleActive: selectedKeys[0] === 'sub6-1',-->
|
||||||
circle: selectedKeys[0]!=='sub6-1',
|
<!-- circle: selectedKeys[0]!=='sub6-1',-->
|
||||||
}"
|
<!-- }"-->
|
||||||
></span>
|
<!-- ></span>-->
|
||||||
<router-link to="/dictmanage">字典管理</router-link>
|
<!-- <router-link to="/dictmanage">字典管理</router-link>-->
|
||||||
</a-menu-item>
|
<!-- </a-menu-item>-->
|
||||||
</a-sub-menu>
|
<!-- </a-sub-menu>-->
|
||||||
|
|
||||||
<a-menu-item key="sub5" v-if="checkMenu('systemManage')">
|
<a-menu-item key="sub5" v-if="checkMenu('systemManage')">
|
||||||
<div class="imgBox">
|
<div class="imgBox">
|
||||||
@@ -438,7 +438,6 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<a target="_blank" :href="oldManage">旧版管理员界面</a>
|
<a target="_blank" :href="oldManage">旧版管理员界面</a>
|
||||||
<!-- <router-link target="_blank" to="/oldsystemmanage">旧版管理员界面</router-link> -->
|
|
||||||
</a-menu-item>
|
</a-menu-item>
|
||||||
<a-menu-item key="sub17" v-if="checkMenu('ReadingClubManage')">
|
<a-menu-item key="sub17" v-if="checkMenu('ReadingClubManage')">
|
||||||
<div class="imgBox">
|
<div class="imgBox">
|
||||||
|
|||||||
@@ -49,6 +49,8 @@ import {computed, reactive} from "vue";
|
|||||||
import {studentUrl,teacherUrl} from "@/api/method";
|
import {studentUrl,teacherUrl} from "@/api/method";
|
||||||
import router from "@/router";
|
import router from "@/router";
|
||||||
import {useStore, createStore} from "vuex";
|
import {useStore, createStore} from "vuex";
|
||||||
|
import {boeRequest, request} from "@/api/request";
|
||||||
|
import {LOGOUT} from "@/api/ThirdApi";
|
||||||
|
|
||||||
const store = useStore();
|
const store = useStore();
|
||||||
|
|
||||||
@@ -83,9 +85,11 @@ const changeRole = (value) => {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
const logOut = () => {
|
const logOut = async () => {
|
||||||
|
await boeRequest(LOGOUT,{from:'pc'})
|
||||||
store.replaceState(createStore({state: {openpages: []}}).state);
|
store.replaceState(createStore({state: {openpages: []}}).state);
|
||||||
localStorage.clear();
|
localStorage.clear();
|
||||||
|
sessionStorage.clear();
|
||||||
(process.env.NODE_ENV === 'development' || process.env.NODE_ENV === 'alpine') ? router.push({path: '/login'}) : (window.location.href = window.location.protocol + process.env.VUE_APP_LOGIN_URL)
|
(process.env.NODE_ENV === 'development' || process.env.NODE_ENV === 'alpine') ? router.push({path: '/login'}) : (window.location.href = window.location.protocol + process.env.VUE_APP_LOGIN_URL)
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
:show-upload-list="showUploadList"
|
:show-upload-list="showUploadList"
|
||||||
:multiple="multiple"
|
:multiple="multiple"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
|
:headers="headers"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
ref="imageRef"
|
ref="imageRef"
|
||||||
>
|
>
|
||||||
@@ -17,6 +18,7 @@
|
|||||||
import {defineProps, defineEmits, defineExpose, ref, watch} from "vue";
|
import {defineProps, defineEmits, defineExpose, ref, watch} from "vue";
|
||||||
import {message} from "ant-design-vue";
|
import {message} from "ant-design-vue";
|
||||||
import {FILE_UPLOAD_URL} from "@/api/config";
|
import {FILE_UPLOAD_URL} from "@/api/config";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
value: {
|
value: {
|
||||||
@@ -41,7 +43,7 @@ const emit = defineEmits({})
|
|||||||
|
|
||||||
const files = ref([])
|
const files = ref([])
|
||||||
const imageRef = ref()
|
const imageRef = ref()
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
watch(props, () => {
|
watch(props, () => {
|
||||||
props.value.length !== files.value.length && (files.value = props.value)
|
props.value.length !== files.value.length && (files.value = props.value)
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -31,6 +31,7 @@
|
|||||||
:data="data"
|
:data="data"
|
||||||
:multiple="true"
|
:multiple="true"
|
||||||
:name="name"
|
:name="name"
|
||||||
|
:headers="headers"
|
||||||
:accept="accept"
|
:accept="accept"
|
||||||
:action="uploadUrl"
|
:action="uploadUrl"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
@@ -99,6 +100,7 @@ import {getImportStatus} from "@/api/index1";
|
|||||||
import {useTimeout} from "@/utils/useCommon";
|
import {useTimeout} from "@/utils/useCommon";
|
||||||
import err from "@/assets/images/err.png";
|
import err from "@/assets/images/err.png";
|
||||||
import success from "@/assets/images/success.png";
|
import success from "@/assets/images/success.png";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
url: String,
|
url: String,
|
||||||
@@ -115,6 +117,7 @@ const props = defineProps({
|
|||||||
const emit = defineEmits({});
|
const emit = defineEmits({});
|
||||||
const visible = ref(false);
|
const visible = ref(false);
|
||||||
const fileList = ref([]);
|
const fileList = ref([]);
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const uploadUrl = ref(process.env.VUE_APP_BASE_API + props.url);
|
const uploadUrl = ref(process.env.VUE_APP_BASE_API + props.url);
|
||||||
const { start } = useTimeout(async ({ uuid, file }) => {
|
const { start } = useTimeout(async ({ uuid, file }) => {
|
||||||
const { data: { data: upData } } = await getImportStatus(uuid);
|
const { data: { data: upData } } = await getImportStatus(uuid);
|
||||||
|
|||||||
@@ -35,6 +35,7 @@
|
|||||||
v-model:fileList="fileList"
|
v-model:fileList="fileList"
|
||||||
:action="importStudent"
|
:action="importStudent"
|
||||||
name="uploadFile"
|
name="uploadFile"
|
||||||
|
:headers="headers"
|
||||||
:multiple="false"
|
:multiple="false"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
:data="{
|
:data="{
|
||||||
@@ -187,6 +188,7 @@ import { message } from "ant-design-vue";
|
|||||||
import * as api from "../../api/index1";
|
import * as api from "../../api/index1";
|
||||||
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
||||||
import { useStore } from "vuex";
|
import { useStore } from "vuex";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "ImpStu",
|
name: "ImpStu",
|
||||||
props: {
|
props: {
|
||||||
@@ -222,7 +224,7 @@ export default {
|
|||||||
showBottomBar: false, // 显示底部成功条数和失败条数
|
showBottomBar: false, // 显示底部成功条数和失败条数
|
||||||
fileName: "",
|
fileName: "",
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const userInfo = computed(() => store.state.userInfo);
|
const userInfo = computed(() => store.state.userInfo);
|
||||||
|
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
@@ -341,6 +343,7 @@ export default {
|
|||||||
userInfo,
|
userInfo,
|
||||||
closeDrawer,
|
closeDrawer,
|
||||||
// change,
|
// change,
|
||||||
|
headers,
|
||||||
handleChange,
|
handleChange,
|
||||||
BATCH_IMPORT_SCORE,
|
BATCH_IMPORT_SCORE,
|
||||||
downloadEeeorData,
|
downloadEeeorData,
|
||||||
|
|||||||
@@ -86,6 +86,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="item_inp" style="background-color: #fff;">
|
<div class="item_inp" style="background-color: #fff;">
|
||||||
<a-upload name="avatar" list-type="picture-card" class="avatar-uploader" :show-upload-list="false"
|
<a-upload name="avatar" list-type="picture-card" class="avatar-uploader" :show-upload-list="false"
|
||||||
|
:headers="headers"
|
||||||
:before-upload="beforeUpload">
|
:before-upload="beforeUpload">
|
||||||
<img class="i_upload_img" v-if="imageUrl" :src="imageUrl" alt="avatar" />
|
<img class="i_upload_img" v-if="imageUrl" :src="imageUrl" alt="avatar" />
|
||||||
<div class="i_upload" v-else>
|
<div class="i_upload" v-else>
|
||||||
@@ -227,6 +228,7 @@ import AddInvistRoot from "@/components/drawers/AddInvistRoot.vue";
|
|||||||
import { Form, message } from "ant-design-vue";
|
import { Form, message } from "ant-design-vue";
|
||||||
import { fileUp } from "../../api/indexEval";
|
import { fileUp } from "../../api/indexEval";
|
||||||
import {useResetRef} from "@/utils/useCommon";
|
import {useResetRef} from "@/utils/useCommon";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
const removePG = () => {
|
const removePG = () => {
|
||||||
formData.value.assessmentId = "";
|
formData.value.assessmentId = "";
|
||||||
@@ -243,6 +245,7 @@ const props = defineProps({
|
|||||||
taskList: [],
|
taskList: [],
|
||||||
});
|
});
|
||||||
const visible = ref(false);
|
const visible = ref(false);
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const formData = useResetRef({
|
const formData = useResetRef({
|
||||||
liveName: "",
|
liveName: "",
|
||||||
liveLink: "",
|
liveLink: "",
|
||||||
|
|||||||
@@ -33,6 +33,7 @@
|
|||||||
:action="importScore"
|
:action="importScore"
|
||||||
name="uploadFile"
|
name="uploadFile"
|
||||||
:multiple="true"
|
:multiple="true"
|
||||||
|
:headers="headers"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
:showUploadList="false"
|
:showUploadList="false"
|
||||||
:data="{
|
:data="{
|
||||||
@@ -195,6 +196,7 @@ import { reactive, toRefs } from "vue";
|
|||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import * as api from "../../api/index1";
|
import * as api from "../../api/index1";
|
||||||
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "EScore",
|
name: "EScore",
|
||||||
@@ -255,6 +257,7 @@ export default {
|
|||||||
process.env.VUE_APP_FILE_PATH,
|
process.env.VUE_APP_FILE_PATH,
|
||||||
template: process.env.VUE_APP_UP_LOAD_STUDENT_SCORE_TEMPLATE,
|
template: process.env.VUE_APP_UP_LOAD_STUDENT_SCORE_TEMPLATE,
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("closeDraw", true);
|
ctx.emit("closeDraw", true);
|
||||||
ctx.emit("update:eScorevisibleExternalExternal", false);
|
ctx.emit("update:eScorevisibleExternalExternal", false);
|
||||||
@@ -405,6 +408,7 @@ export default {
|
|||||||
BATCH_IMPORT_SCORE,
|
BATCH_IMPORT_SCORE,
|
||||||
beforeUpload,
|
beforeUpload,
|
||||||
handleUpload,
|
handleUpload,
|
||||||
|
headers,
|
||||||
removeUpload,
|
removeUpload,
|
||||||
downloadEeeorData,
|
downloadEeeorData,
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -21,6 +21,7 @@
|
|||||||
<div class="right">
|
<div class="right">
|
||||||
<div style="height: 176px; margin-bottom: 20px">
|
<div style="height: 176px; margin-bottom: 20px">
|
||||||
<a-upload-dragger v-model:fileList="fileList" :action="importHomeWork" name="uploadFile" :multiple="true"
|
<a-upload-dragger v-model:fileList="fileList" :action="importHomeWork" name="uploadFile" :multiple="true"
|
||||||
|
:headers="headers"
|
||||||
@change="handleChange" :showUploadList="false" :data="{
|
@change="handleChange" :showUploadList="false" :data="{
|
||||||
type: type,
|
type: type,
|
||||||
taskId: Number(id),
|
taskId: Number(id),
|
||||||
@@ -155,6 +156,7 @@ import { reactive, toRefs } from "vue";
|
|||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import * as api from "../../api/index1";
|
import * as api from "../../api/index1";
|
||||||
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "EScore",
|
name: "EScore",
|
||||||
props: {
|
props: {
|
||||||
@@ -201,6 +203,8 @@ export default {
|
|||||||
downloadErrUrl: null, //下载失败数据
|
downloadErrUrl: null, //下载失败数据
|
||||||
fileName: "",
|
fileName: "",
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:eScorevisible", false);
|
ctx.emit("update:eScorevisible", false);
|
||||||
state.fileList = [];
|
state.fileList = [];
|
||||||
@@ -344,6 +348,7 @@ export default {
|
|||||||
closeDrawer,
|
closeDrawer,
|
||||||
handleChange,
|
handleChange,
|
||||||
downTemplate,
|
downTemplate,
|
||||||
|
headers,
|
||||||
BATCH_IMPORT_SCORE,
|
BATCH_IMPORT_SCORE,
|
||||||
beforeUpload,
|
beforeUpload,
|
||||||
handleUpload,
|
handleUpload,
|
||||||
|
|||||||
@@ -30,6 +30,7 @@
|
|||||||
:action="importLeader"
|
:action="importLeader"
|
||||||
name="uploadFile"
|
name="uploadFile"
|
||||||
:multiple="true"
|
:multiple="true"
|
||||||
|
:headers="headers"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
:showUploadList="false"
|
:showUploadList="false"
|
||||||
>
|
>
|
||||||
@@ -252,6 +253,7 @@ import { reactive, toRefs } from "vue";
|
|||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import * as api from "../../api/index1";
|
import * as api from "../../api/index1";
|
||||||
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "ImportStu",
|
name: "ImportStu",
|
||||||
props: {
|
props: {
|
||||||
@@ -279,6 +281,7 @@ export default {
|
|||||||
process.env.VUE_APP_FILE_PATH,
|
process.env.VUE_APP_FILE_PATH,
|
||||||
template: process.env.VUE_APP_UP_LOAD_STUDENT_SCORE_TEMPLATE,
|
template: process.env.VUE_APP_UP_LOAD_STUDENT_SCORE_TEMPLATE,
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("closeDraw", true);
|
ctx.emit("closeDraw", true);
|
||||||
ctx.emit("update:TaskFaceImpStuvisible", false);
|
ctx.emit("update:TaskFaceImpStuvisible", false);
|
||||||
@@ -422,6 +425,7 @@ export default {
|
|||||||
afterVisibleChange,
|
afterVisibleChange,
|
||||||
closeDrawer,
|
closeDrawer,
|
||||||
handleChange,
|
handleChange,
|
||||||
|
headers,
|
||||||
downTemplate,
|
downTemplate,
|
||||||
BATCH_IMPORT_SCORE,
|
BATCH_IMPORT_SCORE,
|
||||||
beforeUpload,
|
beforeUpload,
|
||||||
|
|||||||
@@ -31,6 +31,7 @@
|
|||||||
:action="importLeader"
|
:action="importLeader"
|
||||||
name="uploadFile"
|
name="uploadFile"
|
||||||
:multiple="true"
|
:multiple="true"
|
||||||
|
:headers="headers"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
:showUploadList="false"
|
:showUploadList="false"
|
||||||
>
|
>
|
||||||
@@ -183,6 +184,7 @@ import { reactive, toRefs } from "vue";
|
|||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import * as api from "../../api/index1";
|
import * as api from "../../api/index1";
|
||||||
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
import { BATCH_IMPORT_SCORE } from "@/api/config";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "TaskImpStu",
|
name: "TaskImpStu",
|
||||||
props: {
|
props: {
|
||||||
@@ -221,6 +223,8 @@ export default {
|
|||||||
process.env.VUE_APP_FILE_PATH,
|
process.env.VUE_APP_FILE_PATH,
|
||||||
template: process.env.VUE_APP_UP_LOAD_STUDENT_SCORE_TEMPLATE,
|
template: process.env.VUE_APP_UP_LOAD_STUDENT_SCORE_TEMPLATE,
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("closeDraw", true);
|
ctx.emit("closeDraw", true);
|
||||||
ctx.emit("update:TaskFaceImpStuvisible", false);
|
ctx.emit("update:TaskFaceImpStuvisible", false);
|
||||||
@@ -364,6 +368,7 @@ export default {
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
|
headers,
|
||||||
afterVisibleChange,
|
afterVisibleChange,
|
||||||
closeDrawer,
|
closeDrawer,
|
||||||
handleChange,
|
handleChange,
|
||||||
|
|||||||
@@ -59,6 +59,7 @@
|
|||||||
style="width: 200px"
|
style="width: 200px"
|
||||||
list-type="picture-card"
|
list-type="picture-card"
|
||||||
class="avatar-uploader"
|
class="avatar-uploader"
|
||||||
|
:headers="headers"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
>
|
>
|
||||||
@@ -326,6 +327,7 @@ import CreateCertificate from "../../../components/drawers/project/CreateCertifi
|
|||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import * as api from "@/api/index1";
|
import * as api from "@/api/index1";
|
||||||
import { fileUp } from "../../../api/indexEval";
|
import { fileUp } from "../../../api/indexEval";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "AddCertificate",
|
name: "AddCertificate",
|
||||||
components: {
|
components: {
|
||||||
@@ -380,6 +382,8 @@ export default {
|
|||||||
|
|
||||||
fileType: ["jpg", "jpeg", "png", "gif", "svg", "bmp"],
|
fileType: ["jpg", "jpeg", "png", "gif", "svg", "bmp"],
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const reset = () => {
|
const reset = () => {
|
||||||
state.certificateName = null;
|
state.certificateName = null;
|
||||||
state.certificateRemark = null;
|
state.certificateRemark = null;
|
||||||
@@ -673,6 +677,7 @@ export default {
|
|||||||
};
|
};
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
|
headers,
|
||||||
afterVisibleChange,
|
afterVisibleChange,
|
||||||
closeDrawer,
|
closeDrawer,
|
||||||
selectCondition,
|
selectCondition,
|
||||||
|
|||||||
@@ -68,6 +68,7 @@
|
|||||||
style="width: 200px"
|
style="width: 200px"
|
||||||
list-type="picture-card"
|
list-type="picture-card"
|
||||||
class="avatar-uploader"
|
class="avatar-uploader"
|
||||||
|
:headers="headers"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
action="https://www.mocky.io/v2/5cc8019d300000980a055e76"
|
action="https://www.mocky.io/v2/5cc8019d300000980a055e76"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
@@ -118,6 +119,7 @@ import * as apiTask from "../../../api/indexTaskadd";
|
|||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import { RouterEditTask } from "@/api/indexTask";
|
import { RouterEditTask } from "@/api/indexTask";
|
||||||
import { addTempTask } from "../../../api/indexTaskadd";
|
import { addTempTask } from "../../../api/indexTaskadd";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "AddRef",
|
name: "AddRef",
|
||||||
props: {
|
props: {
|
||||||
@@ -178,6 +180,7 @@ export default {
|
|||||||
title: null,
|
title: null,
|
||||||
isClick: false,
|
isClick: false,
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:CCertificate", false);
|
ctx.emit("update:CCertificate", false);
|
||||||
ctx.emit("update:edit", false);
|
ctx.emit("update:edit", false);
|
||||||
@@ -335,6 +338,7 @@ export default {
|
|||||||
};
|
};
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
|
headers,
|
||||||
afterVisibleChange,
|
afterVisibleChange,
|
||||||
closeDrawer,
|
closeDrawer,
|
||||||
handleFinish,
|
handleFinish,
|
||||||
|
|||||||
@@ -31,6 +31,7 @@
|
|||||||
:data="data"
|
:data="data"
|
||||||
:multiple="true"
|
:multiple="true"
|
||||||
:accept="accept"
|
:accept="accept"
|
||||||
|
:headers="headers"
|
||||||
:action="uploadUrl"
|
:action="uploadUrl"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
v-model:file-list="fileList"
|
v-model:file-list="fileList"
|
||||||
@@ -95,6 +96,7 @@ import {getImportStatus} from "@/api/index1";
|
|||||||
import {useTimeout} from "@/utils/useCommon";
|
import {useTimeout} from "@/utils/useCommon";
|
||||||
import err from "@/assets/images/err.png";
|
import err from "@/assets/images/err.png";
|
||||||
import success from "@/assets/images/success.png";
|
import success from "@/assets/images/success.png";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
url: String,
|
url: String,
|
||||||
@@ -109,6 +111,7 @@ const emit = defineEmits({})
|
|||||||
const visible = ref(false)
|
const visible = ref(false)
|
||||||
const fileList = ref([])
|
const fileList = ref([])
|
||||||
const uploadUrl = ref(process.env.VUE_APP_BASE_API + props.url);
|
const uploadUrl = ref(process.env.VUE_APP_BASE_API + props.url);
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const {start} = useTimeout(async ({uuid,file}) => {
|
const {start} = useTimeout(async ({uuid,file}) => {
|
||||||
const {data: {data: upData}} = await getImportStatus(uuid)
|
const {data: {data: upData}} = await getImportStatus(uuid)
|
||||||
file.uploadState = upData;
|
file.uploadState = upData;
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
:load-data="onLoadData"
|
:load-data="onLoadData"
|
||||||
:tree-data="options"
|
:tree-data="options"
|
||||||
:fieldNames="{
|
:fieldNames="{
|
||||||
children: 'treeChildList',
|
children: 'directChildList',
|
||||||
label: 'name',
|
label: 'name',
|
||||||
value: 'id',
|
value: 'id',
|
||||||
}"
|
}"
|
||||||
@@ -36,7 +36,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import { defineEmits, defineProps, ref, watch } from "vue";
|
import { defineEmits, defineProps, ref, watch } from "vue";
|
||||||
import {boeRequest, useBoeApi, useRequest} from "@/api/request";
|
import {request, useArrayRequest, useRequest} from "@/api/request";
|
||||||
import {ORG_CHILD_LIST, ORG_LIST} from "@/api/apis";
|
import {ORG_CHILD_LIST, ORG_LIST} from "@/api/apis";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
@@ -50,7 +50,7 @@ const props = defineProps({
|
|||||||
const emit = defineEmits({});
|
const emit = defineEmits({});
|
||||||
const stuTreeExpandedKeys = ref([]);
|
const stuTreeExpandedKeys = ref([]);
|
||||||
const labelValue = ref({ value: props.value, label: props.name });
|
const labelValue = ref({ value: props.value, label: props.name });
|
||||||
const { data: options, loading: orgLoading } = useRequest(
|
const { data: options, loading: orgLoading } = useArrayRequest(
|
||||||
ORG_LIST,
|
ORG_LIST,
|
||||||
{ keyword: "" },
|
{ keyword: "" },
|
||||||
);
|
);
|
||||||
@@ -66,9 +66,9 @@ watch(props, () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
function onLoadData(treeNode) {
|
function onLoadData(treeNode) {
|
||||||
return boeRequest(ORG_CHILD_LIST, { keyword: "", orgId: treeNode.id }).then(
|
return request(ORG_CHILD_LIST, { keyword: "", orgId: treeNode.id }).then(
|
||||||
(r) => {
|
(r) => {
|
||||||
treeNode.dataRef.treeChildList = r.result.directChildList;
|
treeNode.dataRef.directChildList = r.data;
|
||||||
options.value = [...options.value];
|
options.value = [...options.value];
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
@@ -83,7 +83,6 @@ function change(
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
) {
|
) {
|
||||||
console.log("label2222", label, namePath, value);
|
|
||||||
emit("update:name", label);
|
emit("update:name", label);
|
||||||
emit("update:fullName", namePath);
|
emit("update:fullName", namePath);
|
||||||
emit("update:value", value);
|
emit("update:value", value);
|
||||||
|
|||||||
@@ -37,7 +37,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import {defineEmits, defineProps, ref, watch, watchEffect} from "vue";
|
import {defineEmits, defineProps, ref, watch, watchEffect} from "vue";
|
||||||
import {boeRequest, useBoeApi, useRequest} from "@/api/request";
|
import {request, useRequest} from "@/api/request";
|
||||||
import { ORG_CHILD_LIST, ORG_LIST } from "@/api/ThirdApi";
|
import { ORG_CHILD_LIST, ORG_LIST } from "@/api/ThirdApi";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
@@ -80,9 +80,9 @@ watch(props, () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
function onLoadData(treeNode) {
|
function onLoadData(treeNode) {
|
||||||
return boeRequest(ORG_CHILD_LIST, { keyword: "", orgId: treeNode.id }).then(
|
return request(ORG_CHILD_LIST, { keyword: "", orgId: treeNode.id }).then(
|
||||||
(r) => {
|
(r) => {
|
||||||
treeNode.dataRef.treeChildList = r.result.directChildList;
|
treeNode.dataRef.treeChildList = r.data;
|
||||||
options.value = [...options.value];
|
options.value = [...options.value];
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -28,7 +28,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import {computed, defineEmits, defineProps, onMounted, ref, watch} from "vue";
|
import {computed, defineEmits, defineProps, onMounted, ref, watch} from "vue";
|
||||||
import {useBoeUserListPage, usePage} from "@/api/request";
|
import {useThrottlePage} from "@/api/request";
|
||||||
import {USER_LIST} from "@/api/apis";
|
import {USER_LIST} from "@/api/apis";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
@@ -56,9 +56,9 @@ const emit = defineEmits({})
|
|||||||
|
|
||||||
const isOpen = ref(false)
|
const isOpen = ref(false)
|
||||||
|
|
||||||
const memberParam = ref({keyword: '', page: 1, pageSize: 20})
|
const memberParam = ref({keyword: '', pageNo:1, pageSize: 20})
|
||||||
|
|
||||||
const {data: userList, loading} = usePage(USER_LIST, memberParam.value, false)
|
const {data: userList, loading} = useThrottlePage(USER_LIST, memberParam.value, false)
|
||||||
|
|
||||||
const options = computed(() => userList.value.filter(e => !(props.value + '').includes(e.id)).map(e => ({
|
const options = computed(() => userList.value.filter(e => !(props.value + '').includes(e.id)).map(e => ({
|
||||||
label: e.realName + e.userNo,
|
label: e.realName + e.userNo,
|
||||||
@@ -83,7 +83,7 @@ onMounted(() => {
|
|||||||
|
|
||||||
|
|
||||||
const memberScroll = ({target: {scrollHeight, scrollTop, clientHeight}}) => {
|
const memberScroll = ({target: {scrollHeight, scrollTop, clientHeight}}) => {
|
||||||
scrollHeight === (clientHeight + scrollTop) && memberParam.value.page++
|
scrollHeight === (clientHeight + scrollTop) && memberParam.value.pageNo++
|
||||||
};
|
};
|
||||||
|
|
||||||
//搜索学员
|
//搜索学员
|
||||||
@@ -92,19 +92,20 @@ const searchMember = (keyword) => {
|
|||||||
loading.value = true
|
loading.value = true
|
||||||
isOpen.value = true
|
isOpen.value = true
|
||||||
userList.value = []
|
userList.value = []
|
||||||
memberParam.value.page = 1
|
memberParam.value.pageNo = 1
|
||||||
memberParam.value.keyword = keyword
|
memberParam.value.keyword = keyword
|
||||||
|
console.log('searchMember', memberParam.value)
|
||||||
};
|
};
|
||||||
|
|
||||||
function blur() {
|
function blur() {
|
||||||
isOpen.value = false
|
isOpen.value = false
|
||||||
memberParam.value.keyword = ''
|
memberParam.value.keyword = ''
|
||||||
memberParam.value.page = 1
|
memberParam.value.pageNo = 1
|
||||||
}
|
}
|
||||||
|
|
||||||
function change(e, l) {
|
function change(e, l) {
|
||||||
memberParam.value.keyword = ''
|
memberParam.value.keyword = ''
|
||||||
memberParam.value.page = 1
|
memberParam.value.pageNo = 1
|
||||||
isOpen.value = false
|
isOpen.value = false
|
||||||
Array.isArray(l) && (selectOptions.value = l)
|
Array.isArray(l) && (selectOptions.value = l)
|
||||||
Array.isArray(selectOptions.value) && emit('onChange', e, l, selectOptions.value.find(e => e.departId)?.departId, selectOptions.value.find(e => e.departId)?.departName, selectOptions.value.find(e => e.departId)?.orgName)
|
Array.isArray(selectOptions.value) && emit('onChange', e, l, selectOptions.value.find(e => e.departId)?.departId, selectOptions.value.find(e => e.departId)?.departName, selectOptions.value.find(e => e.departId)?.orgName)
|
||||||
|
|||||||
@@ -132,7 +132,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="tableBox tabb">
|
<div class="tableBox tabb">
|
||||||
<BaseTable ref="auditTableRef" :columns="audiColums" :url="AUDIENCE_LIST" page-key="pageNo"
|
<BaseTable ref="auditTableRef" :columns="audiColums" :url="AUDIENCE_LIST" page-key="pageNo"
|
||||||
v-model:params="audienceName"
|
v-model:params="audienceName" :request="useTotalPage"
|
||||||
v-model:selectedRows="auditSelectRows" v-model:selectedRowKeys="auditSelectRowKeys"
|
v-model:selectedRows="auditSelectRows" v-model:selectedRowKeys="auditSelectRowKeys"
|
||||||
type="checkbox"></BaseTable>
|
type="checkbox"></BaseTable>
|
||||||
</div>
|
</div>
|
||||||
@@ -296,7 +296,7 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
import {message} from "ant-design-vue";
|
import {message} from "ant-design-vue";
|
||||||
import {computed, defineEmits, defineProps, ref, watch} from "vue";
|
import {computed, defineEmits, defineProps, ref, watch} from "vue";
|
||||||
import {boeRequest, useBoeApi, useBoeApiPage, useBoeApiUserInfoPage, useBoeApiAuditPage, usePage, useNewRowsPageNoInit, request, useRequest} from "@/api/request";
|
import {useNewRowsPageNoInit, request, useRequest, useTotalPage} from "@/api/request";
|
||||||
import {
|
import {
|
||||||
saveStu,
|
saveStu,
|
||||||
} from "@/api/index1";
|
} from "@/api/index1";
|
||||||
@@ -507,14 +507,6 @@ const audiColums = ref([
|
|||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
{
|
|
||||||
title: "类型",
|
|
||||||
dataIndex: "audienceType",
|
|
||||||
key: "audienceType",
|
|
||||||
width: 40,
|
|
||||||
align: "center",
|
|
||||||
className: "h",
|
|
||||||
},
|
|
||||||
]);
|
]);
|
||||||
const orgSelectKeys = ref([]);
|
const orgSelectKeys = ref([]);
|
||||||
const auditTableRef = ref();
|
const auditTableRef = ref();
|
||||||
|
|||||||
@@ -22,6 +22,7 @@
|
|||||||
<a-upload
|
<a-upload
|
||||||
v-show="!item.imgVal"
|
v-show="!item.imgVal"
|
||||||
class="in uploadBtn"
|
class="in uploadBtn"
|
||||||
|
:headers="headers"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
>
|
>
|
||||||
@@ -50,6 +51,7 @@
|
|||||||
import { reactive, toRefs, ref } from "vue";
|
import { reactive, toRefs, ref } from "vue";
|
||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import { fileUp } from "../../api/indexEval";
|
import { fileUp } from "../../api/indexEval";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "VoteQuestionItem",
|
name: "VoteQuestionItem",
|
||||||
@@ -66,6 +68,7 @@ export default {
|
|||||||
const state = reactive({
|
const state = reactive({
|
||||||
hasImgName: "",
|
hasImgName: "",
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const handleInput = (value) => {
|
const handleInput = (value) => {
|
||||||
console.log(value.target.value);
|
console.log(value.target.value);
|
||||||
@@ -121,6 +124,7 @@ export default {
|
|||||||
handleDel,
|
handleDel,
|
||||||
handleCancel,
|
handleCancel,
|
||||||
beforeUpload,
|
beforeUpload,
|
||||||
|
headers,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
<div class="delete" @click="handleDel">删除</div>
|
<div class="delete" @click="handleDel">删除</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="name uploadContent">
|
<div class="name uploadContent">
|
||||||
<a-upload v-show="!formData.optionPictureAddress" class="in uploadBtn" :show-upload-list="false" :before-upload="beforeUpload">
|
<a-upload v-show="!formData.optionPictureAddress" class="in uploadBtn" :headers="headers" :show-upload-list="false" :before-upload="beforeUpload">
|
||||||
<div class="addimg">+添加图片</div>
|
<div class="addimg">+添加图片</div>
|
||||||
</a-upload>
|
</a-upload>
|
||||||
<div v-show="formData.optionPictureAddress" class="picture" style="position: relative">
|
<div v-show="formData.optionPictureAddress" class="picture" style="position: relative">
|
||||||
@@ -35,13 +35,14 @@
|
|||||||
import { defineEmits, defineProps, ref } from "vue";
|
import { defineEmits, defineProps, ref } from "vue";
|
||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import { fileUp } from "../../api/indexEval";
|
import { fileUp } from "../../api/indexEval";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
item: {},
|
item: {},
|
||||||
index: Number
|
index: Number
|
||||||
})
|
})
|
||||||
const emit = defineEmits(['del'])
|
const emit = defineEmits(['del'])
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const formData = ref(props.item)
|
const formData = ref(props.item)
|
||||||
|
|
||||||
const beforeUpload = (file) => {
|
const beforeUpload = (file) => {
|
||||||
|
|||||||
48
src/main.js
48
src/main.js
@@ -16,6 +16,10 @@ import 'element-plus/dist/index.css'
|
|||||||
import "@/assets/scss/common.scss"
|
import "@/assets/scss/common.scss"
|
||||||
import Antd from 'ant-design-vue';
|
import Antd from 'ant-design-vue';
|
||||||
import 'ant-design-vue/dist/antd.css';
|
import 'ant-design-vue/dist/antd.css';
|
||||||
|
import {request} from "@/api/request";
|
||||||
|
import {USER_INFO, USER_PERMISSION, VALIDATE_TOKEN} from "@/api/apis";
|
||||||
|
import * as api1 from "@/api/index1";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
// import axios from 'axios'
|
// import axios from 'axios'
|
||||||
// axios.defaults.withCredentials = true;
|
// axios.defaults.withCredentials = true;
|
||||||
// import zhCN from 'ant-design-vue/es/locale/zh_CN';
|
// import zhCN from 'ant-design-vue/es/locale/zh_CN';
|
||||||
@@ -25,7 +29,51 @@ app.config.warnHandler = () => null;
|
|||||||
// app.use(ElementPlus, {
|
// app.use(ElementPlus, {
|
||||||
// locale: zhCn,
|
// locale: zhCn,
|
||||||
// })
|
// })
|
||||||
|
|
||||||
|
router.beforeEach(async (to, from, next) => {
|
||||||
|
if (!getCookieForName("token")) {
|
||||||
|
window.location.href = process.env.VUE_APP_LOGIN_URL + encodeURIComponent(window.location.protocol + process.env.VUE_APP_BOE_API_URL + process.env.VUE_APP_BASE + router.currentRoute.value.fullPath)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
//第一次进入 没有用户信息
|
||||||
|
if(!store.state.userInfo.userId){
|
||||||
|
try{
|
||||||
|
await request(VALIDATE_TOKEN)
|
||||||
|
await getUserInfo()
|
||||||
|
await getUserPermission();
|
||||||
|
init()
|
||||||
|
}catch (e){
|
||||||
|
console.log('token失效 跳转到登录页')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
next();
|
||||||
|
})
|
||||||
app.use(Antd);
|
app.use(Antd);
|
||||||
app.use(router);
|
app.use(router);
|
||||||
app.use(store);
|
app.use(store);
|
||||||
app.mount('#app');
|
app.mount('#app');
|
||||||
|
async function getUserPermission() {
|
||||||
|
return request(USER_PERMISSION, {permissionType: 'PAGE'}).then(res => {
|
||||||
|
store.commit("SET_PERMISSION", res.data?.map(s => s.url));
|
||||||
|
})
|
||||||
|
}
|
||||||
|
async function getUserInfo() {
|
||||||
|
const userInfo = await request(USER_INFO);
|
||||||
|
store.commit("SET_USER", userInfo.data);
|
||||||
|
}
|
||||||
|
async function initDict(key) {
|
||||||
|
const list = await getDictList(key);
|
||||||
|
store.commit("SET_DICT", {key, data: list});
|
||||||
|
}
|
||||||
|
const getDictList = (param) => api1.getDictTree({code: param,}).then((res) => res.data.data);
|
||||||
|
|
||||||
|
async function init() {
|
||||||
|
initDict("content_type"); //内容分类
|
||||||
|
initDict("project_level"); //项目级别
|
||||||
|
initDict("project_sys"); //培训分类
|
||||||
|
initDict("project_pic"); //项目封面
|
||||||
|
initDict("router_pic"); //路径图封面
|
||||||
|
initDict("course_pic"); //课程封面
|
||||||
|
initDict("job_type"); //岗位
|
||||||
|
initDict("band"); //band
|
||||||
|
}
|
||||||
@@ -612,6 +612,7 @@
|
|||||||
<div class="item_inp">
|
<div class="item_inp">
|
||||||
<a-upload
|
<a-upload
|
||||||
multiple
|
multiple
|
||||||
|
:headers="headers"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
:before-upload="beforeUpload2"
|
:before-upload="beforeUpload2"
|
||||||
>
|
>
|
||||||
@@ -1051,6 +1052,7 @@
|
|||||||
<div class="item_inp">
|
<div class="item_inp">
|
||||||
<a-upload
|
<a-upload
|
||||||
multiple
|
multiple
|
||||||
|
:headers="headers"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
:before-upload="beforeUpload2"
|
:before-upload="beforeUpload2"
|
||||||
>
|
>
|
||||||
@@ -2356,6 +2358,7 @@
|
|||||||
<a-upload
|
<a-upload
|
||||||
name="file"
|
name="file"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
|
:headers="headers"
|
||||||
:before-upload="beforeUpload3"
|
:before-upload="beforeUpload3"
|
||||||
>
|
>
|
||||||
<div class="upload_box">
|
<div class="upload_box">
|
||||||
@@ -3142,6 +3145,7 @@ import ProjectManager from "@/components/project/ProjectManagerNew";
|
|||||||
|
|
||||||
import SeeModal from "./components/seeModal.vue";
|
import SeeModal from "./components/seeModal.vue";
|
||||||
import * as moment from "moment";
|
import * as moment from "moment";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
//列表表格
|
//列表表格
|
||||||
const columns1 = [
|
const columns1 = [
|
||||||
@@ -3923,7 +3927,7 @@ export default defineComponent({
|
|||||||
assessmentName: "",
|
assessmentName: "",
|
||||||
assessmentVisible: false,
|
assessmentVisible: false,
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const showStuAdd = (record) => {
|
const showStuAdd = (record) => {
|
||||||
state.selectCourseId = record.offcoursePlanId;
|
state.selectCourseId = record.offcoursePlanId;
|
||||||
state.shipType = 2;
|
state.shipType = 2;
|
||||||
@@ -5690,6 +5694,7 @@ export default defineComponent({
|
|||||||
};
|
};
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
|
headers,
|
||||||
getdateToDateFn,
|
getdateToDateFn,
|
||||||
moment,
|
moment,
|
||||||
getdateToTimeFn,
|
getdateToTimeFn,
|
||||||
|
|||||||
@@ -685,6 +685,7 @@
|
|||||||
v-if="docChecked == true"
|
v-if="docChecked == true"
|
||||||
v-model:file-list="fileList"
|
v-model:file-list="fileList"
|
||||||
name="file"
|
name="file"
|
||||||
|
:headers="headers"
|
||||||
:action="uploadAction"
|
:action="uploadAction"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
>
|
>
|
||||||
@@ -1415,6 +1416,7 @@ import ImpoterGroupLeader from "@/components/drawers/project/ImpoterGroupLeader.
|
|||||||
import TaskImpStu from "../../components/drawers/TaskFaceIn";
|
import TaskImpStu from "../../components/drawers/TaskFaceIn";
|
||||||
|
|
||||||
import { checkPer,fixDoublePer } from "@/utils/utils";
|
import { checkPer,fixDoublePer } from "@/utils/utils";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "LevelAdd",
|
name: "LevelAdd",
|
||||||
@@ -1446,6 +1448,7 @@ export default {
|
|||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const stuRef = ref();
|
const stuRef = ref();
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
// const store = useStore();
|
// const store = useStore();
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
createId: null,
|
createId: null,
|
||||||
@@ -2911,6 +2914,7 @@ export default {
|
|||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
...toRefs(levelList),
|
...toRefs(levelList),
|
||||||
stuRef,
|
stuRef,
|
||||||
|
headers,
|
||||||
clearChooseStu,
|
clearChooseStu,
|
||||||
showDeleteALLModal,
|
showDeleteALLModal,
|
||||||
closeDeleteALLModal,
|
closeDeleteALLModal,
|
||||||
|
|||||||
@@ -104,6 +104,7 @@
|
|||||||
class="avatar-uploader"
|
class="avatar-uploader"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
action="/api/file/upload"
|
action="/api/file/upload"
|
||||||
|
:headers="headers"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
:disabled="viewDetail ? true : false"
|
:disabled="viewDetail ? true : false"
|
||||||
@@ -401,7 +402,7 @@ import { useRouter, useRoute } from "vue-router";
|
|||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
import * as api from "../../api/index";
|
import * as api from "../../api/index";
|
||||||
import * as api1 from "../../api/index1";
|
import * as api1 from "../../api/index1";
|
||||||
import { toDate, scrollLoad } from "../../api/method";
|
import {toDate, scrollLoad, getCookieForName} from "../../api/method";
|
||||||
import { useStore } from "vuex";
|
import { useStore } from "vuex";
|
||||||
export default {
|
export default {
|
||||||
name: "projectAdd",
|
name: "projectAdd",
|
||||||
@@ -413,7 +414,7 @@ export default {
|
|||||||
const isEdit = ref(false);
|
const isEdit = ref(false);
|
||||||
let peojectID = "";
|
let peojectID = "";
|
||||||
let paraentID = "";
|
let paraentID = "";
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
classifySelect: null,
|
classifySelect: null,
|
||||||
classifySelectId: null,
|
classifySelectId: null,
|
||||||
@@ -1040,7 +1041,7 @@ export default {
|
|||||||
uplodaFileCount,
|
uplodaFileCount,
|
||||||
createProject,
|
createProject,
|
||||||
removeFile,
|
removeFile,
|
||||||
|
headers,
|
||||||
isEdit,
|
isEdit,
|
||||||
backPage,
|
backPage,
|
||||||
dateFormatList,
|
dateFormatList,
|
||||||
|
|||||||
@@ -606,6 +606,7 @@
|
|||||||
v-model:file-list="fileList"
|
v-model:file-list="fileList"
|
||||||
name="file"
|
name="file"
|
||||||
:action="uploadAction"
|
:action="uploadAction"
|
||||||
|
:headers="headers"
|
||||||
@change="handleChange2"
|
@change="handleChange2"
|
||||||
>
|
>
|
||||||
<span
|
<span
|
||||||
@@ -759,6 +760,7 @@ import {useRoute, useRouter} from "vue-router";
|
|||||||
import {scoreRule, setScoreRule} from "@/api/indexTaskadd";
|
import {scoreRule, setScoreRule} from "@/api/indexTaskadd";
|
||||||
import ProjectLevel from "@/components/project/ProjectLevel";
|
import ProjectLevel from "@/components/project/ProjectLevel";
|
||||||
import TrainClass from "@/components/project/TrainClass";
|
import TrainClass from "@/components/project/TrainClass";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
name: "LibraryAdd",
|
name: "LibraryAdd",
|
||||||
@@ -924,6 +926,8 @@ export default defineComponent({
|
|||||||
editFlag: false,
|
editFlag: false,
|
||||||
uploadAction: process.env.VUE_APP_BASE_API + '/file/uploadunlimit'
|
uploadAction: process.env.VUE_APP_BASE_API + '/file/uploadunlimit'
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const value = ref("");
|
const value = ref("");
|
||||||
const textnum = "150";
|
const textnum = "150";
|
||||||
const routered = useRouter();
|
const routered = useRouter();
|
||||||
@@ -1397,6 +1401,7 @@ export default defineComponent({
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
|
headers,
|
||||||
value,
|
value,
|
||||||
projectId,
|
projectId,
|
||||||
textnum,
|
textnum,
|
||||||
|
|||||||
@@ -1337,6 +1337,7 @@
|
|||||||
"
|
"
|
||||||
v-model:file-list="fileList"
|
v-model:file-list="fileList"
|
||||||
name="file"
|
name="file"
|
||||||
|
:headers="headers"
|
||||||
:action="uploadAction"
|
:action="uploadAction"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
>
|
>
|
||||||
@@ -2309,7 +2310,7 @@ import { message, Modal } from "ant-design-vue";
|
|||||||
import * as apitl from "../../api/index";
|
import * as apitl from "../../api/index";
|
||||||
import { getTask } from "../../api/indexTaskadd";
|
import { getTask } from "../../api/indexTaskadd";
|
||||||
import { editProjDoc } from "../../api/indexTaskadd";
|
import { editProjDoc } from "../../api/indexTaskadd";
|
||||||
import { toDate } from "../../api/method";
|
import {getCookieForName, toDate} from "../../api/method";
|
||||||
import projSet from "../../components/Modals/projSet";
|
import projSet from "../../components/Modals/projSet";
|
||||||
import { overview } from "../../api/indexProjStu";
|
import { overview } from "../../api/indexProjStu";
|
||||||
import TwoDimensionalCode from "../../components/TwoDimensionalCode.vue";
|
import TwoDimensionalCode from "../../components/TwoDimensionalCode.vue";
|
||||||
@@ -2362,6 +2363,8 @@ export default {
|
|||||||
setup() {
|
setup() {
|
||||||
const store = useStore();
|
const store = useStore();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
createId: "",
|
createId: "",
|
||||||
permissions: "",
|
permissions: "",
|
||||||
@@ -4912,6 +4915,7 @@ export default {
|
|||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
...toRefs(levelList),
|
...toRefs(levelList),
|
||||||
|
headers,
|
||||||
stageChange,
|
stageChange,
|
||||||
showStudent,
|
showStudent,
|
||||||
settingTopFlag,
|
settingTopFlag,
|
||||||
|
|||||||
@@ -68,7 +68,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
<a-space style="padding-right: 10px">
|
<a-space style="padding-right: 10px">
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus === '1' && checkPer(record.permissions)
|
record.releaseStatus === '1'
|
||||||
"
|
"
|
||||||
@click="handleOper(record, 'push')"
|
@click="handleOper(record, 'push')"
|
||||||
type="link"
|
type="link"
|
||||||
@@ -76,7 +76,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus === '1' && checkPer(record.permissions)
|
record.releaseStatus === '1'
|
||||||
"
|
"
|
||||||
@click="editOper(record)"
|
@click="editOper(record)"
|
||||||
type="link"
|
type="link"
|
||||||
@@ -84,7 +84,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus === '1' && checkPer(record.permissions)
|
record.releaseStatus === '1'
|
||||||
"
|
"
|
||||||
@click="handleEditPage(record.id)"
|
@click="handleEditPage(record.id)"
|
||||||
type="link"
|
type="link"
|
||||||
@@ -92,7 +92,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus === '2' && checkPer(record.permissions)
|
record.releaseStatus === '2'
|
||||||
"
|
"
|
||||||
@click="toManage(record.id, record)"
|
@click="toManage(record.id, record)"
|
||||||
type="link"
|
type="link"
|
||||||
@@ -106,7 +106,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus === '2' && checkPer(record.permissions)
|
record.releaseStatus === '2'
|
||||||
"
|
"
|
||||||
@click="() => handleOper(record, 'withdraw')"
|
@click="() => handleOper(record, 'withdraw')"
|
||||||
type="link"
|
type="link"
|
||||||
@@ -114,7 +114,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus === '2' && checkPer(record.permissions)
|
record.releaseStatus === '2'
|
||||||
"
|
"
|
||||||
@click="handleOper(record, 'end')"
|
@click="handleOper(record, 'end')"
|
||||||
type="link"
|
type="link"
|
||||||
@@ -122,7 +122,7 @@ shan<!-- 评估管理页面 -->
|
|||||||
</a-button>
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="
|
v-if="
|
||||||
record.releaseStatus !== '2' && checkPer(record.permissions)
|
record.releaseStatus !== '2'
|
||||||
"
|
"
|
||||||
@click="handleOper(record, 'del')"
|
@click="handleOper(record, 'del')"
|
||||||
type="link"
|
type="link"
|
||||||
|
|||||||
@@ -27,6 +27,7 @@
|
|||||||
<a-upload
|
<a-upload
|
||||||
v-show="!item[imgKey]"
|
v-show="!item[imgKey]"
|
||||||
class="in uploadBtn"
|
class="in uploadBtn"
|
||||||
|
:headers="headers"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
>
|
>
|
||||||
@@ -53,9 +54,12 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
import {message} from "ant-design-vue";
|
import {message} from "ant-design-vue";
|
||||||
import {fileUp} from "@/api/indexEval";
|
import {fileUp} from "@/api/indexEval";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
|
|
||||||
const props = defineProps({ index: Number, list: Array, item: Object ,nameKey:String,imgKey:String});
|
const props = defineProps({ index: Number, list: Array, item: Object ,nameKey:String,imgKey:String});
|
||||||
const VUE_APP_FILE_PATH = process.env.VUE_APP_FILE_PATH;
|
const VUE_APP_FILE_PATH = process.env.VUE_APP_FILE_PATH;
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
|
|
||||||
const handleCancel = () => props.item[props.imgKey] = "";
|
const handleCancel = () => props.item[props.imgKey] = "";
|
||||||
const handleDel = () => props.item.id?(props.item.deleted = true):(props.list.splice(props.index, 1))
|
const handleDel = () => props.item.id?(props.item.deleted = true):(props.list.splice(props.index, 1))
|
||||||
const beforeUpload = (file) => {
|
const beforeUpload = (file) => {
|
||||||
|
|||||||
@@ -28,6 +28,7 @@
|
|||||||
name="avatar"
|
name="avatar"
|
||||||
action="/api/file/upload"
|
action="/api/file/upload"
|
||||||
list-type="picture-card"
|
list-type="picture-card"
|
||||||
|
:headers="headers"
|
||||||
class="avatar-uploader"
|
class="avatar-uploader"
|
||||||
:show-upload-list="false"
|
:show-upload-list="false"
|
||||||
:before-upload="beforeUpload"
|
:before-upload="beforeUpload"
|
||||||
@@ -139,6 +140,7 @@ import html2canvas from "html2canvas";
|
|||||||
import TwoDimensionalCode from "../../components/TwoDimensionalCode.vue";
|
import TwoDimensionalCode from "../../components/TwoDimensionalCode.vue";
|
||||||
import SubsetManage from "../../components/drawers/SubsetManage.vue";
|
import SubsetManage from "../../components/drawers/SubsetManage.vue";
|
||||||
import AddGroup from "../../components/drawers/AddGroup.vue";
|
import AddGroup from "../../components/drawers/AddGroup.vue";
|
||||||
|
import {getCookieForName} from "@/api/method";
|
||||||
export default {
|
export default {
|
||||||
name: "SystemManage",
|
name: "SystemManage",
|
||||||
components: {
|
components: {
|
||||||
@@ -262,7 +264,7 @@ export default {
|
|||||||
Svisible: false,
|
Svisible: false,
|
||||||
Avisible: false,
|
Avisible: false,
|
||||||
});
|
});
|
||||||
|
const headers = { token: getCookieForName("token") };
|
||||||
const showDrawer = () => {
|
const showDrawer = () => {
|
||||||
state.visible = true;
|
state.visible = true;
|
||||||
};
|
};
|
||||||
@@ -456,7 +458,7 @@ export default {
|
|||||||
downloadQr,
|
downloadQr,
|
||||||
changeCodevisible,
|
changeCodevisible,
|
||||||
changeCodevisible2,
|
changeCodevisible2,
|
||||||
|
headers,
|
||||||
onSelectChange,
|
onSelectChange,
|
||||||
randomgroup,
|
randomgroup,
|
||||||
showAddGroup,
|
showAddGroup,
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ module.exports = defineConfig({
|
|||||||
port: 8070,
|
port: 8070,
|
||||||
proxy: {
|
proxy: {
|
||||||
"/manageApi": {
|
"/manageApi": {
|
||||||
target: 'http:' + process.env.VUE_APP_PROXY_URL,
|
target: 'https:' + process.env.VUE_APP_PROXY_URL,
|
||||||
changeOrigin: true, //表示是否改变原域名
|
changeOrigin: true, //表示是否改变原域名
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
"^/manageApi": "",
|
"^/manageApi": "",
|
||||||
|
|||||||
Reference in New Issue
Block a user