diff --git a/.env.boe b/.env.boe index aa7b463c..cac81a6a 100644 --- a/.env.boe +++ b/.env.boe @@ -1,10 +1,6 @@ NODE_ENV=boe VUE_APP_BASE=/manage VUE_APP_BASE_API=/manageApi -# 教师节上传图片文件夹id -VUE_APP_PIC_FOLDERID=1147577187794841600 -# 教师节上传zip文件夹id -VUE_APP_TOOL_FOLDERID=1147577145918910464 VUE_APP_LOGIN_URL=//u-pre.boe.com/web?returnUrl= VUE_APP_BOE_API_URL=//u-pre.boe.com diff --git a/.env.prod b/.env.prod index fcf6b999..6d9bc76a 100644 --- a/.env.prod +++ b/.env.prod @@ -1,6 +1,10 @@ NODE_ENV=prod VUE_APP_BASE=/manage VUE_APP_BASE_API=/manageApi +# 教师节上传图片文件夹id +VUE_APP_PIC_FOLDERID=1148997110156759040 +# 教师节上传zip文件夹id +VUE_APP_TOOL_FOLDERID=1148996610925531136 VUE_APP_PROXY_URL=//u.boe.com/ diff --git a/src/api/grateful.js b/src/api/grateful.js index ea1341d4..59f52444 100644 --- a/src/api/grateful.js +++ b/src/api/grateful.js @@ -80,6 +80,14 @@ const opinionDelete = (params) => http.delete(`${ACTIVITYAPI}/xboe/m/boe/opinion const query = (type) => http.get('/systemapi/xboe/m/assistance/protocol/query?type=' + type); +// 上传图片接口 +const importPic = (data = {}) => http.post(`/systemapi/api/m/xfile/base/file/upload`, data, { + headers: { + 'Content-Type': 'multipart/form-data' + } +}); + + @@ -109,5 +117,6 @@ export { teachersDelete, opinionList, opinionDelete, - query + query, + importPic } \ No newline at end of file diff --git a/src/components/Grateful/AddTeacherInfo.vue b/src/components/Grateful/AddTeacherInfo.vue index e5df0230..61ba2ffe 100644 --- a/src/components/Grateful/AddTeacherInfo.vue +++ b/src/components/Grateful/AddTeacherInfo.vue @@ -1,5 +1,5 @@ diff --git a/src/views/gratefulteacher/GratefulCarousel.vue b/src/views/gratefulteacher/GratefulCarousel.vue index fee58201..4577a940 100644 --- a/src/views/gratefulteacher/GratefulCarousel.vue +++ b/src/views/gratefulteacher/GratefulCarousel.vue @@ -143,7 +143,7 @@ const handle = ({ id }) => ({ }); const handleMsg = { - del: "你确定要删除这条意见吗?", + del: "你确定要删除这条轮播图吗?", }; function handleOper(record, type, status = "") { diff --git a/src/views/gratefulteacher/TeacherTopic.vue b/src/views/gratefulteacher/TeacherTopic.vue index e25e313c..e1feb80a 100644 --- a/src/views/gratefulteacher/TeacherTopic.vue +++ b/src/views/gratefulteacher/TeacherTopic.vue @@ -28,16 +28,16 @@
-
添加教师
+
添加师资
-
-
导入教师
+
导入师资
@@ -98,18 +98,18 @@ const column = ref([ ); }, }, - { - title: "授课时长(H)", - dataIndex: "teacherTime", - key: "teacherTime", - width: 20, - align: "center", - customRender: ({ record }) => { - return ( - {record.teacherTime ? record.teacherTime : '-'} - ); - }, - }, + // { + // title: "授课时长(H)", + // dataIndex: "teacherTime", + // key: "teacherTime", + // width: 20, + // align: "center", + // customRender: ({ record }) => { + // return ( + // {record.teacherTime ? record.teacherTime : '-'} + // ); + // }, + // }, { title: "教师等级", dataIndex: "teacherLevel", @@ -118,7 +118,7 @@ const column = ref([ align: "center", customRender: ({ record }) => { return ( - {record.teacherLevel ? record.teacherLevel + '级' : '-'} + {record.teacherLevel ? record.teacherLevel : '-'} ); }, }, @@ -183,7 +183,11 @@ const teacherLevelList = ref([{ label: "5级", }, ]) - +const change = (value) => { + if (value === 'done') { + searchInfo() + } +} const carouselTableRef = ref(); const searchInfo = () => { diff --git a/src/views/gratefulteacher/ToolDown.vue b/src/views/gratefulteacher/ToolDown.vue index 86db5ffc..40d7399c 100644 --- a/src/views/gratefulteacher/ToolDown.vue +++ b/src/views/gratefulteacher/ToolDown.vue @@ -130,23 +130,24 @@ const reseatDownloadList = () => { const downLoadFile = (toolInfo) => { if (!toolInfo.filePath) return; console.log(toolInfo); - toolDown({ - urlStr: `https:${process.env.VUE_APP_BOE_API_URL}/upload${toolInfo.filePath}`, - fileName: toolInfo.name - }).then((result) => { - if (!result.data) { - return - } - const link = document.createElement('a');// 创建a标签 - let blob = new Blob([result.data], { type: '' }); // 设置文件类型 - link.style.display = "none"; - link.href = URL.createObjectURL(blob); // 创建URL - link.setAttribute("download", `${toolInfo.name}`); - document.body.appendChild(link); - link.click(); - URL.revokeObjectURL(link.href); - document.body.removeChild(link); - }) + window.open(`/activityApi/xboe/m/boe/tools/url/download?urlStr=https:${process.env.VUE_APP_BOE_API_URL}/upload${toolInfo.filePath}&fileName=${toolInfo.name}`) + // toolDown({ + // urlStr: `https:${process.env.VUE_APP_BOE_API_URL}/upload${toolInfo.filePath}`, + // fileName: toolInfo.name + // }).then((result) => { + // if (!result.data) { + // return + // } + // const link = document.createElement('a');// 创建a标签 + // let blob = new Blob([result.data], { type: 'application/zip' }); // 设置文件类型 + // link.style.display = "none"; + // link.href = URL.createObjectURL(blob); // 创建URL + // link.setAttribute("download", `${toolInfo.name}`); + // document.body.appendChild(link); + // link.click(); + // URL.revokeObjectURL(link.href); + // document.body.removeChild(link); + // }) }; const handle = ({ id }) => ({