Compare commits
4 Commits
51943f0595
...
9f5115f4a3
Author | SHA1 | Date |
---|---|---|
lyc | 9f5115f4a3 | |
lyc | 12332348b0 | |
lyc | d5165fa3b0 | |
lyc | b65cd95558 |
|
@ -9,7 +9,6 @@ export const listEvaluation = (params)=> {
|
|||
})
|
||||
}
|
||||
|
||||
|
||||
export const addFileToPrepare = (params) => {
|
||||
return request({
|
||||
url: '/smarttalk/file/addFileToPrepare',
|
||||
|
@ -17,3 +16,4 @@ export const addFileToPrepare = (params) => {
|
|||
params
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
import request from '@/utils/request'
|
||||
|
||||
// 查询classwork列表
|
||||
export function homeworklist(params) {
|
||||
return request({
|
||||
url: '/education/classwork/list',
|
||||
method: 'get',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
// 查询entpcourse列表
|
||||
export function listEntpcourse(query) {
|
||||
return request({
|
||||
url: '/education/entpcourse/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
|
@ -1,9 +1,9 @@
|
|||
@font-face {
|
||||
font-family: "iconfont"; /* Project id 2794390 */
|
||||
src: url('iconfont.woff2?t=1721815727687') format('woff2'),
|
||||
url('iconfont.woff?t=1721815727687') format('woff'),
|
||||
url('iconfont.ttf?t=1721815727687') format('truetype'),
|
||||
url('iconfont.svg?t=1721815727687#iconfont') format('svg');
|
||||
src: url('iconfont.woff2?t=1722323882803') format('woff2'),
|
||||
url('iconfont.woff?t=1722323882803') format('woff'),
|
||||
url('iconfont.ttf?t=1722323882803') format('truetype'),
|
||||
url('iconfont.svg?t=1722323882803#iconfont') format('svg');
|
||||
}
|
||||
|
||||
.iconfont {
|
||||
|
@ -14,6 +14,10 @@
|
|||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.icon-zuoye1:before {
|
||||
content: "\e610";
|
||||
}
|
||||
|
||||
.icon-xiazai9:before {
|
||||
content: "\e60b";
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -5,6 +5,13 @@
|
|||
"css_prefix_text": "icon-",
|
||||
"description": "",
|
||||
"glyphs": [
|
||||
{
|
||||
"icon_id": "8023423",
|
||||
"name": "作业",
|
||||
"font_class": "zuoye1",
|
||||
"unicode": "e610",
|
||||
"unicode_decimal": 58896
|
||||
},
|
||||
{
|
||||
"icon_id": "720967",
|
||||
"name": "更多",
|
||||
|
|
|
@ -14,6 +14,8 @@
|
|||
/>
|
||||
<missing-glyph />
|
||||
|
||||
<glyph glyph-name="zuoye1" unicode="" d="M839.415605-127.976172H184.563842A111.949251 111.949251 0 0 0 70.355065-18.697271V687.096536a111.949251 111.949251 0 0 0 114.208777 109.278902h133.928278a30.81172 30.81172 0 0 0 0-61.623441H184.563842A50.32581 50.32581 0 0 1 131.978506 687.096536v-705.793807a50.32581 50.32581 0 0 1 52.585336-47.655461h654.851763A50.32581 50.32581 0 0 1 892.000941-18.697271V687.096536a50.32581 50.32581 0 0 1-52.585336 47.655461h-121.809001a30.81172 30.81172 0 0 0 0 61.623441h121.809001A111.949251 111.949251 0 0 0 953.624381 687.096536v-705.793807a111.949251 111.949251 0 0 0-114.208776-109.278901zM662.145507 834.376559a20.541147 20.541147 0 0 0 20.541147-20.541147v-82.164587a20.541147 20.541147 0 0 0-20.541147-20.541147h-287.576056a20.541147 20.541147 0 0 0-20.541147 20.541147V813.835412a20.541147 20.541147 0 0 0 20.541147 20.541147h287.576056m0 61.623441h-287.576056a82.164588 82.164588 0 0 1-82.164588-82.164588v-82.164587a82.164588 82.164588 0 0 1 82.164588-82.164588h287.576056a82.164588 82.164588 0 0 1 82.164588 82.164588V813.835412a82.164588 82.164588 0 0 1-82.164588 82.164588zM757.251017 265.386791H274.534065a30.81172 30.81172 0 0 0 0 61.62344h482.716952a30.81172 30.81172 0 0 0 0-61.62344zM538.898626 429.715966H274.534065a30.81172 30.81172 0 0 0 0 61.62344h264.364561a30.81172 30.81172 0 0 0 0-61.62344zM662.145507 121.598762H274.534065a30.81172 30.81172 0 0 0 0 61.623441h387.611442a30.81172 30.81172 0 1 0 0-61.623441z" horiz-adv-x="1024" />
|
||||
|
||||
<glyph glyph-name="xiazai9" unicode="" d="M102.4 486.4C46.08 486.4 0 440.32 0 384s46.08-102.4 102.4-102.4 102.4 46.08 102.4 102.4C204.8 440.32 158.72 486.4 102.4 486.4zM921.6 486.4c-56.32 0-102.4-46.08-102.4-102.4s46.08-102.4 102.4-102.4S1024 327.68 1024 384C1024 440.32 977.92 486.4 921.6 486.4zM512 486.4c-56.32 0-102.4-46.08-102.4-102.4s46.08-102.4 102.4-102.4 102.4 46.08 102.4 102.4C614.4 440.32 568.32 486.4 512 486.4z" horiz-adv-x="1024" />
|
||||
|
||||
<glyph glyph-name="hudong" unicode="" d="M99.776 554.24c0 169.408 141.056 306.816 315.008 306.816h0.768v-85.312h-0.768c-125.44 0-227.456-99.328-227.456-221.504v-1.92h106.944L147.2 409.344-0.064 552.32h99.84v1.92zM923.52 213.248c0-169.408-141.12-306.816-314.944-306.816h-0.768v85.312h0.768c125.44 0 227.456 99.392 227.456 221.568v1.92H729.088l147.072 142.976 147.2-142.976h-99.84v-1.984zM398.912 259.392c27.584 0 50.048-21.184 50.048-47.104v-194.752c0-25.984-22.464-47.104-49.984-47.104H114.048c-27.584 0-50.048 21.184-50.048 47.104v194.752c0 25.984 22.464 47.104 50.048 47.104h284.864m0 64H114.048c-62.976 0-114.048-49.792-114.048-111.104v-194.752c0-61.312 51.008-111.104 114.048-111.104h284.928c62.976 0 113.984 49.856 113.984 111.104v194.752c0 61.312-51.008 111.104-114.048 111.104zM906.176 797.184c27.584 0 50.048-21.12 50.048-47.104v-194.752c0-25.984-22.464-47.168-50.048-47.168H621.248c-27.584 0-49.984 21.184-49.984 47.168V750.08c0 25.984 22.464 47.104 49.984 47.104h284.928m0 64H621.248c-62.976 0-113.984-49.728-113.984-111.104v-194.752c0-61.376 51.008-111.168 113.984-111.168h284.992c62.912 0 114.048 49.728 114.048 111.168V750.08c-0.064 61.312-51.072 111.104-114.112 111.104z" horiz-adv-x="1024" />
|
||||
|
|
Before Width: | Height: | Size: 60 KiB After Width: | Height: | Size: 61 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<svg class="icon file-icon" aria-hidden="true" :style="{'font-size': size + 'px'}">
|
||||
<svg class="icon file-icon" aria-hidden="true" :style="{ 'font-size': size + 'px' }">
|
||||
<use :xlink:href="getFileTypeIcon()"></use>
|
||||
</svg>
|
||||
</template>
|
||||
|
@ -36,10 +36,15 @@ const getFileTypeIcon = () => {
|
|||
rar: 'icon-rar',
|
||||
|
||||
}
|
||||
if (iconObj[name]) {
|
||||
return '#' + iconObj[name]
|
||||
}
|
||||
else {
|
||||
return '#icon-zuoye1'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
</style>
|
||||
<style lang="scss" scoped></style>
|
|
@ -4,6 +4,7 @@ import useUserStore from '@/store/modules/user'
|
|||
const userStore = useUserStore()
|
||||
const baseConfig = {
|
||||
// Electron 设置cookie
|
||||
// url: import.meta.env.VITE_APP_BASE_API,
|
||||
url: 'https://file.ysaix.com:7868',
|
||||
//cookie 名称 这里为 token
|
||||
name: 'Admin-Token',
|
||||
|
@ -14,13 +15,20 @@ const baseConfig = {
|
|||
|
||||
}
|
||||
|
||||
// 作业
|
||||
// 作业布置
|
||||
const homeWork = {
|
||||
data: { ...baseConfig},
|
||||
// 完整路径
|
||||
fullPath: `${baseConfig.url}/teaching/classtaskassign?titleName=%E4%BD%9C%E4%B8%9A%E5%B8%83%E7%BD%AE`
|
||||
}
|
||||
|
||||
// 作业反馈
|
||||
const feedback = {
|
||||
data: { ...baseConfig},
|
||||
// 完整路径
|
||||
fullPath: `${baseConfig.url}/teaching/classtaskassign?titleName=作业反馈`
|
||||
}
|
||||
|
||||
// 高考研读
|
||||
const gk = {
|
||||
data: { ...baseConfig},
|
||||
|
@ -41,6 +49,7 @@ const aiModel = {
|
|||
|
||||
export default {
|
||||
homeWork,
|
||||
feedback,
|
||||
gk,
|
||||
standard,
|
||||
aiModel
|
||||
|
|
|
@ -10,6 +10,10 @@
|
|||
</div>
|
||||
<div class="prepare-item-info-message">
|
||||
<div style="width: 60px">
|
||||
<template v-if="item.uniquekey">
|
||||
{{ item.worktype }}
|
||||
</template>
|
||||
<template v-else>
|
||||
<el-icon
|
||||
v-loading="item.async === 'on'"
|
||||
style="background-color: green; border-radius: 20px; color: white; top: 2px"
|
||||
|
@ -20,13 +24,15 @@
|
|||
{{ item.async === true ? '已同步' : '' }}
|
||||
{{ !item.async ? '待同步' : '' }}
|
||||
{{ item.async === 'on' ? '同步中' : '' }}
|
||||
</template>
|
||||
</div>
|
||||
|
|
||||
<div style="width: 70px">{{ formatFileSize(item.fileSize) }}</div>
|
||||
|
|
||||
<div style="width: 70px">{{ toTimeText(item.uploadTime, true) }}</div>
|
||||
|
|
||||
<template v-if="item.fileSize">|</template>
|
||||
<div style="width: 70px" v-if="item.fileSize">{{ formatFileSize(item.fileSize) }}</div>
|
||||
<template v-if="item.uploadTime">|</template>
|
||||
<div style="width: 70px" v-if="item.uploadTime">{{ toTimeText(item.uploadTime, true) }}</div>
|
||||
<template v-if="item.levelFirstName">| </template>
|
||||
<div
|
||||
v-if="item.levelFirstName"
|
||||
style="
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
|
@ -59,6 +65,21 @@
|
|||
<template #default>
|
||||
<div style="width: 100%">
|
||||
<div class="item-popover" @click="closePopver(index)">
|
||||
<template v-if="item.uniquekey">
|
||||
<div class="item-popover-item">
|
||||
<el-button text @click="editTalk(item, index)">
|
||||
<i class="iconfont icon-bianji"></i>
|
||||
<span>布置</span>
|
||||
</el-button>
|
||||
</div>
|
||||
<div class="item-popover-item">
|
||||
<el-button text @click="deleteTalk(item)">
|
||||
<i class="iconfont icon-shanchu"></i>
|
||||
<span>删除</span>
|
||||
</el-button>
|
||||
</div>
|
||||
</template>
|
||||
<template v-else>
|
||||
<div class="item-popover-item">
|
||||
<el-button text @click="editTalk(item, index)">
|
||||
<i class="iconfont icon-bianji"></i>
|
||||
|
@ -85,6 +106,7 @@
|
|||
<span>移动</span>
|
||||
</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -236,6 +258,10 @@ export default {
|
|||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
.icon-zuoye{
|
||||
font-size: 40px;
|
||||
color: #707070
|
||||
}
|
||||
}
|
||||
|
||||
.prepare-body-main-item-tool {
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
</el-popover>
|
||||
</div>
|
||||
<div style="display: flex">
|
||||
<el-button @click="handleOutLink('feedback')">作业反馈</el-button>
|
||||
<el-button @click="handleOutLink('homeWork')">布置作业</el-button>
|
||||
<el-button @click="isDialogOpen = true">上传资料</el-button>
|
||||
<el-button type="primary" style="margin-left: 10px" @click="createFile">新建课件</el-button>
|
||||
|
@ -67,15 +68,19 @@ import ChooseTextbook from '@/components/choose-textbook/index.vue'
|
|||
import uploadDialog from '@/components/upload-dialog/index.vue'
|
||||
import { Refresh } from '@element-plus/icons-vue'
|
||||
import uploaderState from '@/store/modules/uploader'
|
||||
import useUserStore from '@/store/modules/user'
|
||||
import MoveFile from '@/components/move-file/index.vue'
|
||||
import FileListItem from '@/views/prepare/container/file-list-item.vue'
|
||||
import { getSmarttalkPage, moveSmarttalk } from '@/api/file'
|
||||
import { homeworklist, listEntpcourse } from '@/api/teaching/classwork'
|
||||
import { toTimeText } from '@/utils/date'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import { parseCataByNode, creatPPT, asyncLocalFile } from '@/utils/talkFile'
|
||||
import FileOperBatch from '@/views/prepare/container/file-oper-batch.vue'
|
||||
import outLink from '@/utils/linkConfig'
|
||||
import { createWindow } from '@/utils/tool'
|
||||
import { uniqBy, cloneDeep } from 'lodash'
|
||||
|
||||
const { ipcRenderer } = window.electron || {}
|
||||
|
||||
export default {
|
||||
|
@ -103,6 +108,10 @@ export default {
|
|||
},
|
||||
// 当前教材封面图
|
||||
curBookImg: '',
|
||||
// 用户信息
|
||||
userStore: '',
|
||||
entpcourseid: '',
|
||||
timerId: null
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
@ -113,6 +122,7 @@ export default {
|
|||
}
|
||||
},
|
||||
created() {
|
||||
this.userStore = useUserStore().user
|
||||
ipcRenderer.removeAllListeners('copy-file-default-reply')
|
||||
ipcRenderer.on('copy-file-default-reply', (e, param) => {
|
||||
this.callback(param)
|
||||
|
@ -244,7 +254,7 @@ export default {
|
|||
this.isLoading = false
|
||||
})
|
||||
},
|
||||
nodeClick(data) {
|
||||
async nodeClick(data) {
|
||||
if (this.currentNode.id === data.node.id) return
|
||||
this.curBookImg = data.textBook.curBookImg
|
||||
this.checkFileList = []
|
||||
|
@ -255,15 +265,100 @@ export default {
|
|||
this.uploadData.levelThirdId = cata[2]
|
||||
this.uploadData.textbookId = data.textBook.curBookId
|
||||
this.asyncAllFile()
|
||||
if (this.uploadData.levelSecondId) {
|
||||
// 获取作业列表所需ID
|
||||
const res = await this.getChapterId()
|
||||
this.entpcourseid = res.rows[0].id
|
||||
// 查询作业
|
||||
this.getHomeWorkList()
|
||||
}
|
||||
},
|
||||
|
||||
// 打开外部链接
|
||||
handleOutLink(key){
|
||||
handleOutLink(key) {
|
||||
if (key == 'homeWork') {
|
||||
// 查询作业
|
||||
this.createTimer()
|
||||
}
|
||||
// key 对应的 linkConfig.js 外部链接配置
|
||||
let configObj = outLink[key]
|
||||
// 通知主进程
|
||||
ipcRenderer.send('openWindow', {
|
||||
fullPath: configObj.fullPath,
|
||||
cookieData: {...(configObj.data)}
|
||||
cookieData: { ...(configObj.data) }
|
||||
})
|
||||
},
|
||||
// 根据教材章节单元ID 查询作业列表所需ID
|
||||
getChapterId() {
|
||||
return listEntpcourse({ evalid: this.uploadData.levelSecondId, edituserid: this.userStore.userId, pageSize: 500 })
|
||||
},
|
||||
//
|
||||
createTimer() {
|
||||
this.timerId = setInterval(() => {
|
||||
this.getHomeWorkList()
|
||||
}, 1500)
|
||||
},
|
||||
// 查询作业列表
|
||||
getHomeWorkList() {
|
||||
homeworklist({ entpcourseid: this.entpcourseid, edituserid: this.userStore.userId, pageSize: 100 }).then(res => {
|
||||
|
||||
//以下代码 参照AIx web端 作业布置
|
||||
let list = []
|
||||
for (var i = 0; i < res.rows.length; i++) {
|
||||
|
||||
res.rows[i].taskconfig = [];
|
||||
|
||||
// 找child
|
||||
for (var j = 0; j < res.rows.length; j++) {
|
||||
if (res.rows[j].parentid == res.rows[i].id) {
|
||||
var ss = [];
|
||||
if (res.rows[j].classworkdatastudentids != null) {
|
||||
ss = JSON.parse('[' + res.rows[j].classworkdatastudentids + ']');
|
||||
}
|
||||
var js = {
|
||||
id: res.rows[j].id,
|
||||
classid: res.rows[j].classid,
|
||||
classcaption: res.rows[j].classcaption,
|
||||
parentid: 0,
|
||||
worktype: '',
|
||||
workkey: res.rows[j].workkey,
|
||||
worktag: '',
|
||||
entpcourseid: 0,
|
||||
evalid: 0,
|
||||
edusubject: '',
|
||||
edudegree: '',
|
||||
workdate: '',
|
||||
title: '',
|
||||
workcodes: '',
|
||||
studentlist: ss,
|
||||
deaddate: res.rows[j].deaddate,
|
||||
timelength: res.rows[j].timelength,
|
||||
weights: res.rows[j].weights,
|
||||
feedtype: res.rows[j].feedtype
|
||||
}
|
||||
res.rows[i].taskconfig.push(js);
|
||||
}
|
||||
}
|
||||
res.rows[i].fileShowName = res.rows[i].uniquekey
|
||||
|
||||
// 注意slideid>0的,这一些作业是添加到PPT页面的,所以在作业管理中不能出现
|
||||
// 2024-05-15,酉阳,jackyshen
|
||||
if (res.rows[i].classid == 0 && res.rows[i].slideid == 0) {
|
||||
list.push(res.rows[i]);
|
||||
}
|
||||
|
||||
|
||||
// 如果是习题训练任务,则检查一共有多少道
|
||||
if (res.rows[i].entpcourseworklist != '') {
|
||||
res.rows[i].entpcourseworklistarray = JSON.parse('[' + res.rows[i].entpcourseworklist + ']');
|
||||
} else {
|
||||
res.rows[i].entpcourseworklistarray = [];
|
||||
}
|
||||
}
|
||||
// 去重
|
||||
let ary = uniqBy([...this.currentFileList, ...list], 'id')
|
||||
// 深度克隆
|
||||
this.currentFileList = cloneDeep(ary)
|
||||
})
|
||||
},
|
||||
// 打开PDF-课件
|
||||
|
@ -274,6 +369,13 @@ export default {
|
|||
openLesson() {
|
||||
createWindow('tool-sphere', { url: '/tool/sphere' })
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
$route(to) {
|
||||
if (to.path != '/prepare' && this.timerId) {
|
||||
clearInterval(this.timerId)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
@ -329,7 +431,8 @@ export default {
|
|||
justify-content: center;
|
||||
position: relative;
|
||||
background: linear-gradient(#b0d1ef, #3e7bcb);
|
||||
.top-zoom-style{
|
||||
|
||||
.top-zoom-style {
|
||||
position: absolute;
|
||||
width: 90%;
|
||||
height: 30px;
|
||||
|
@ -337,7 +440,8 @@ export default {
|
|||
bottom: 0;
|
||||
clip-path: polygon(3% 0%, 97% 0%, 100% 100%, 0% 100%);
|
||||
}
|
||||
.textbook-img{
|
||||
|
||||
.textbook-img {
|
||||
height: 120px;
|
||||
background-color: #ffffff;
|
||||
padding: 5px;
|
||||
|
@ -346,36 +450,43 @@ export default {
|
|||
margin-right: 20px;
|
||||
z-index: 1;
|
||||
}
|
||||
.top-item{
|
||||
|
||||
.top-item {
|
||||
width: 230px;
|
||||
position: relative;
|
||||
flex-wrap: wrap;
|
||||
z-index: 1;
|
||||
.btn{
|
||||
|
||||
.btn {
|
||||
width: 102px;
|
||||
background: none;
|
||||
color: #ffffff;
|
||||
border-width: 2px;
|
||||
border-color: #ffffff;
|
||||
&:hover{
|
||||
|
||||
&:hover {
|
||||
background: rgba(255, 255, 255, 0.3)
|
||||
}
|
||||
&:first-child{
|
||||
|
||||
&:first-child {
|
||||
margin-left: 12px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
&:nth-child(2){
|
||||
|
||||
&:nth-child(2) {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.to-class-btn{
|
||||
|
||||
.to-class-btn {
|
||||
width: 130px;
|
||||
height: 80px;
|
||||
margin-left: 25px;
|
||||
font-size: 18px;
|
||||
z-index: 1;
|
||||
.icon-lingdang{
|
||||
|
||||
.icon-lingdang {
|
||||
margin-right: 5px;
|
||||
color: #ffffff;
|
||||
font-size: 20px;
|
||||
|
|
Loading…
Reference in New Issue