Compare commits
21 Commits
Author | SHA1 | Date |
---|---|---|
zouyf | 6b5164048c | |
“zouyf” | 1f2eb722f1 | |
“zouyf” | b973fd685c | |
朱浩 | f899729db0 | |
朱浩 | 249e1c047c | |
baigl | c9bfd41fc7 | |
白了个白 | 51a8df474a | |
白了个白 | fbbd84df93 | |
朱浩 | 5cc93bb093 | |
朱浩 | eefa9aff63 | |
朱浩 | 3ef73885e1 | |
zouyf | bc63691645 | |
“zouyf” | fa54546f5e | |
朱浩 | d50327bc17 | |
“zouyf” | f20ddc1c58 | |
“zouyf” | 7c1c4e9b7d | |
白了个白 | 78eb65d532 | |
“zouyf” | f2dbf12f3c | |
朱浩 | 77921f7e61 | |
朱浩 | ac1cad8fd0 | |
yangws | 00b58644b1 |
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "aix-win",
|
"name": "aix-win",
|
||||||
"version": "2.1.28",
|
"version": "2.1.30",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "./out/main/index.js",
|
"main": "./out/main/index.js",
|
||||||
"author": "上海交大重庆人工智能研究院",
|
"author": "上海交大重庆人工智能研究院",
|
||||||
|
|
|
@ -24,6 +24,13 @@ export const getPrepareById = (id) => {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const addFileToKj = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/smarttalk/file/addFileToKj/' + id,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
export function deleteSmarttalk(id) {
|
export function deleteSmarttalk(id) {
|
||||||
return request({
|
return request({
|
||||||
url: '/smarttalk/file/' + id,
|
url: '/smarttalk/file/' + id,
|
||||||
|
@ -53,3 +60,14 @@ export const moveSmarttalk = (params) => {
|
||||||
params
|
params
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const addFileToPrepareThird = (data) => {
|
||||||
|
return request({
|
||||||
|
url: '/smarttalk/file/addFileToPrepareThird',
|
||||||
|
method: 'post',
|
||||||
|
headers: {
|
||||||
|
'Content-Type': 'multipart/form-data'
|
||||||
|
},
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
|
@ -55,6 +55,7 @@
|
||||||
<el-col :span="11">
|
<el-col :span="11">
|
||||||
<el-form-item label="知识点" label-width="70">
|
<el-form-item label="知识点" label-width="70">
|
||||||
<el-cascader
|
<el-cascader
|
||||||
|
disabled
|
||||||
v-model="entpCourseWorkQueryParams.point"
|
v-model="entpCourseWorkQueryParams.point"
|
||||||
clearable
|
clearable
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
|
@ -90,7 +91,12 @@
|
||||||
</el-row>
|
</el-row>
|
||||||
<!-- 习题表格 -->
|
<!-- 习题表格 -->
|
||||||
<div class="infinite-list-wrapper" >
|
<div class="infinite-list-wrapper" >
|
||||||
<!-- <el-table :data="workResource.entpCourseWorkList" style="width: 100%; height: 100%;">
|
<el-table
|
||||||
|
:data="workResource.entpCourseWorkList"
|
||||||
|
style="width: 100%; height: 100%;"
|
||||||
|
v-loading="pageParams.loading"
|
||||||
|
ref="tableRef"
|
||||||
|
>
|
||||||
<el-table-column type="index" width="60" />
|
<el-table-column type="index" width="60" />
|
||||||
<el-table-column align="left" >
|
<el-table-column align="left" >
|
||||||
<template #header>
|
<template #header>
|
||||||
|
@ -114,22 +120,18 @@
|
||||||
<el-button type="primary" @click="handleClassWorkQuizAdd('entpcourseworklist', scope.row.id)">添加</el-button>
|
<el-button type="primary" @click="handleClassWorkQuizAdd('entpcourseworklist', scope.row.id)">添加</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table> -->
|
</el-table>
|
||||||
<ul
|
|
||||||
|
<!-- <ul
|
||||||
v-infinite-scroll="pageLoad"
|
v-infinite-scroll="pageLoad"
|
||||||
class="infinite-list"
|
class="infinite-list"
|
||||||
infinite-scroll-immediate="false"
|
infinite-scroll-immediate="false"
|
||||||
infinite-scroll-distance='1'
|
infinite-scroll-distance='100'
|
||||||
infinite-scroll-delay="1000"
|
infinite-scroll-delay="1000"
|
||||||
:infinite-scroll-disabled="pageDisabled"
|
:infinite-scroll-disabled="pageDisabled"
|
||||||
>
|
>
|
||||||
<li v-for="(item,index) in workResource.entpCourseWorkList" :key="item" class="infinite-list-item">
|
<li v-for="(item,index) in workResource.entpCourseWorkList" :key="item" class="infinite-list-item">
|
||||||
<div align="left" style="width: 100%;" >
|
<div align="left" style="width: 100%;" >
|
||||||
<!-- <template #header>
|
|
||||||
<div style="display: flex">
|
|
||||||
<div style="align-items: center;">题目内容</div>
|
|
||||||
</div>
|
|
||||||
</template> -->
|
|
||||||
<div @click="showExamAnalyseDrawer(item)">
|
<div @click="showExamAnalyseDrawer(item)">
|
||||||
<div>
|
<div>
|
||||||
<span style="width: 20px;">{{ index +1 }}. </span>
|
<span style="width: 20px;">{{ index +1 }}. </span>
|
||||||
|
@ -155,18 +157,18 @@
|
||||||
description="未找到相关试题"
|
description="未找到相关试题"
|
||||||
style="width: 100%; height: 200px; margin-top: 20px;"
|
style="width: 100%; height: 200px; margin-top: 20px;"
|
||||||
></el-empty>
|
></el-empty>
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<!-- 分页 这里不用-->
|
<!-- 分页 这里不用-->
|
||||||
<!-- <div style="height: 55px;">
|
<div style="height: 55px;">
|
||||||
<pagination
|
<el-pagination
|
||||||
v-show="entpCourseWorkTotal > 0"
|
v-show="pageParams.total > 0"
|
||||||
v-model:page="paginationParams.pageNum"
|
v-model:page="paginationParams.pageNum"
|
||||||
v-model:limit="paginationParams.pageSize"
|
v-model:limit="paginationParams.pageSize"
|
||||||
:total="entpCourseWorkTotal"
|
:total="pageParams.total"
|
||||||
:style="{ position: 'relative', 'margin-top': '5px' }"
|
:style="{ position: 'relative', 'margin-top': '5px' }"
|
||||||
@pagination="getPaginationList" />
|
@change="getPaginationList" />
|
||||||
</div> -->
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 非习题训练:常规作业、 -->
|
<!-- 非习题训练:常规作业、 -->
|
||||||
<div v-if="classWorkForm.worktype!='习题训练'">
|
<div v-if="classWorkForm.worktype!='习题训练'">
|
||||||
|
@ -276,6 +278,7 @@ import { onMounted, ref, nextTick, watch, reactive, getCurrentInstance, computed
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { cloneDeep } from 'lodash'
|
import { cloneDeep } from 'lodash'
|
||||||
import { useRouter } from 'vue-router'
|
import { useRouter } from 'vue-router'
|
||||||
|
import { Search } from '@element-plus/icons-vue'
|
||||||
|
|
||||||
import {listEntpcoursework, listEntpcourseworkNew, getEntpcoursework} from '@/api/education/entpCourseWork'
|
import {listEntpcoursework, listEntpcourseworkNew, getEntpcoursework} from '@/api/education/entpCourseWork'
|
||||||
import { addClassworkReturnId } from '@/api/teaching/classwork'
|
import { addClassworkReturnId } from '@/api/teaching/classwork'
|
||||||
|
@ -284,6 +287,7 @@ import { listEvaluation } from '@/api/subject'
|
||||||
import { listEntpcoursefile } from '@/api/education/entpcoursefile'
|
import { listEntpcoursefile } from '@/api/education/entpcoursefile'
|
||||||
import { listKnowledgePoint } from "@/api/knowledge/knowledgePoint";
|
import { listKnowledgePoint } from "@/api/knowledge/knowledgePoint";
|
||||||
|
|
||||||
|
|
||||||
import { useGetHomework } from '@/hooks/useGetHomework'
|
import { useGetHomework } from '@/hooks/useGetHomework'
|
||||||
import { processList } from '@/hooks/useProcessList'
|
import { processList } from '@/hooks/useProcessList'
|
||||||
import { getCurrentTime } from '@/utils/date'
|
import { getCurrentTime } from '@/utils/date'
|
||||||
|
@ -409,15 +413,15 @@ const fileLoading = ref(false); // 常规作业loading
|
||||||
|
|
||||||
// 下拉滚动参数
|
// 下拉滚动参数
|
||||||
|
|
||||||
const BASE_LIMIT_COUT = 50; // 总加载额外试题数
|
// const BASE_LIMIT_COUT = 50; // 总加载额外试题数
|
||||||
const pageNoMore = computed( () => {
|
// const pageNoMore = computed( () => {
|
||||||
if (pageParams.value.total < 1) {
|
// if (pageParams.value.total < 1) {
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
let count = BASE_LIMIT_COUT >= pageParams.value.total ? pageParams.value.total : pageParams.value.originCount+BASE_LIMIT_COUT;
|
// let count = BASE_LIMIT_COUT >= pageParams.value.total ? pageParams.value.total : pageParams.value.originCount+BASE_LIMIT_COUT;
|
||||||
return workResource.entpCourseWorkList.length >= count;
|
// return workResource.entpCourseWorkList.length >= count;
|
||||||
});
|
// });
|
||||||
const pageDisabled = computed(() => pageParams.value.loading || pageNoMore.value);
|
// const pageDisabled = computed(() => pageParams.value.loading || pageNoMore.value);
|
||||||
const pageParams = ref({
|
const pageParams = ref({
|
||||||
loading: false, // 是否正在加载中
|
loading: false, // 是否正在加载中
|
||||||
originCount: 0, // 初始条目数量
|
originCount: 0, // 初始条目数量
|
||||||
|
@ -497,7 +501,7 @@ function Apis(key) {
|
||||||
// 年份
|
// 年份
|
||||||
yearStr: entpCourseWorkQueryParams.yearStr !== '-1' ? entpCourseWorkQueryParams.yearStr:'',
|
yearStr: entpCourseWorkQueryParams.yearStr !== '-1' ? entpCourseWorkQueryParams.yearStr:'',
|
||||||
// 知识点
|
// 知识点
|
||||||
thirdId: entpCourseWorkQueryParams.point.length > 0 ? entpCourseWorkQueryParams.point[0]:'',
|
thirdId: entpCourseWorkQueryParams.point && entpCourseWorkQueryParams.point.length > 0 ? entpCourseWorkQueryParams.point[0]:'',
|
||||||
// 关键字
|
// 关键字
|
||||||
keyword: entpCourseWorkQueryParams.keyWord && entpCourseWorkQueryParams.keyWord !== '' ? entpCourseWorkQueryParams.keyWord:'',
|
keyword: entpCourseWorkQueryParams.keyWord && entpCourseWorkQueryParams.keyWord !== '' ? entpCourseWorkQueryParams.keyWord:'',
|
||||||
|
|
||||||
|
@ -508,10 +512,8 @@ function Apis(key) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
const handleQueryFromEntpCourseWork= async (queryType) => {
|
const handleQueryFromEntpCourseWork= async (queryType) => {
|
||||||
|
|
||||||
pageParams.value.loading = true;
|
pageParams.value.loading = true;
|
||||||
|
|
||||||
|
|
||||||
// 初中政治特殊处理( warn: 需确认是否修改 )
|
// 初中政治特殊处理( warn: 需确认是否修改 )
|
||||||
// if (this.courseObj.edusubject=='政治' && this.courseObj.edustage=='初中') {
|
// if (this.courseObj.edusubject=='政治' && this.courseObj.edustage=='初中') {
|
||||||
// // [初中+政治]需改为[初中+道德与法治]
|
// // [初中+政治]需改为[初中+道德与法治]
|
||||||
|
@ -519,16 +521,16 @@ const handleQueryFromEntpCourseWork= async (queryType) => {
|
||||||
// }
|
// }
|
||||||
|
|
||||||
client(t('任务1', 1500)).then(res => {
|
client(t('任务1', 1500)).then(res => {
|
||||||
console.log("请求返回",res);
|
//console.log("请求返回",res);
|
||||||
if(paginationParams.pageNum == 1){
|
// if(paginationParams.pageNum == 1){
|
||||||
workResource.entpCourseWorkList = [];
|
// workResource.entpCourseWorkList = [];
|
||||||
workResource.entpCourseWorkTotal = 0;
|
// workResource.entpCourseWorkTotal = 0;
|
||||||
|
|
||||||
// 初始化下拉滚动条参数
|
// // 初始化下拉滚动条参数
|
||||||
// pageParams.value.loading = false;
|
// // pageParams.value.loading = false;
|
||||||
// pageParams.value.isFirst = true;
|
// // pageParams.value.isFirst = true;
|
||||||
// pageParams.value.originCount = 0;
|
// // pageParams.value.originCount = 0;
|
||||||
}
|
// }
|
||||||
const data = res.data || [];
|
const data = res.data || [];
|
||||||
if(data && data.length>0){
|
if(data && data.length>0){
|
||||||
// workResource.entpCourseWorkList = entpcourseworkres.data;
|
// workResource.entpCourseWorkList = entpcourseworkres.data;
|
||||||
|
@ -542,22 +544,21 @@ const handleQueryFromEntpCourseWork= async (queryType) => {
|
||||||
|
|
||||||
// 格式化试题信息
|
// 格式化试题信息
|
||||||
processList(data);
|
processList(data);
|
||||||
workResource.entpCourseWorkList.push(...data);
|
//workResource.entpCourseWorkList.push(...data);
|
||||||
|
workResource.entpCourseWorkList = data;
|
||||||
|
|
||||||
// 初次加载时更新当前试题数量
|
// 初次加载时更新当前试题数量
|
||||||
if (pageParams.value.isFirst) {
|
if (pageParams.value.isFirst) {
|
||||||
pageParams.value.isFirst = false;
|
pageParams.value.isFirst = false;
|
||||||
pageParams.value.originCount = workResource.entpCourseWorkList.length;
|
pageParams.value.originCount = workResource.entpCourseWorkList.length;
|
||||||
pageParams.value.total = parseInt(res.msg);
|
pageParams.value.total = parseInt(res.msg);
|
||||||
|
paginationParams.pageNum = Math.ceil(parseInt(res.msg)/paginationParams.pageSize);
|
||||||
|
//console.log('first->', pageParams.value, paginationParams);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pageParams.value.loading = false;
|
pageParams.value.loading = false;
|
||||||
});
|
});
|
||||||
|
|
||||||
//const entpcourseworkres = await listEntpcourseworkNew(queryForm);
|
|
||||||
|
|
||||||
// const data = entpcourseworkres.data;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 教学资源,从课标分析、教材分析里来
|
// 教学资源,从课标分析、教材分析里来
|
||||||
|
@ -977,6 +978,15 @@ const showExamAnalyseDrawer = (row) => {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const tableRef = ref();
|
||||||
|
const getPaginationList = ( page, limit ) => {
|
||||||
|
paginationParams.pageNum = page;
|
||||||
|
paginationParams.pageSize = limit;
|
||||||
|
//console.log(page, limit)
|
||||||
|
handleQueryFromEntpCourseWork(0);
|
||||||
|
// 重置滚动条至顶部
|
||||||
|
tableRef.value.setScrollTop(0);
|
||||||
|
}
|
||||||
|
|
||||||
const pageLoad = async() => {
|
const pageLoad = async() => {
|
||||||
console.log("加载中...")
|
console.log("加载中...")
|
||||||
|
|
|
@ -179,7 +179,7 @@ const classWorkAnalysis = reactive({
|
||||||
entpcourseworklistarray: [], // 当前学习任务所包含的试题ID
|
entpcourseworklistarray: [], // 当前学习任务所包含的试题ID
|
||||||
})
|
})
|
||||||
const tableRadio = reactive({
|
const tableRadio = reactive({
|
||||||
value: '1', // 已交
|
value: 1, // 已交
|
||||||
list: [], // 已交list
|
list: [], // 已交list
|
||||||
num1: 0, // 已交人数
|
num1: 0, // 已交人数
|
||||||
num0: 0 // 未交人数
|
num0: 0 // 未交人数
|
||||||
|
@ -219,7 +219,7 @@ const openDialog = (data, isInit=true) => {
|
||||||
classWorkAnalysis.workclass = data.workclass
|
classWorkAnalysis.workclass = data.workclass
|
||||||
// 重置学生列表
|
// 重置学生列表
|
||||||
tableRadio.list = []
|
tableRadio.list = []
|
||||||
tableRadio.value = '1'
|
tableRadio.value = 1
|
||||||
tableRadio.num0 = 0
|
tableRadio.num0 = 0
|
||||||
tableRadio.num1 = 0
|
tableRadio.num1 = 0
|
||||||
|
|
||||||
|
@ -401,7 +401,7 @@ const getClassWorkStudentList = (rowId) => {
|
||||||
tableRadio.list =
|
tableRadio.list =
|
||||||
classWorkAnalysis.classworkdata &&
|
classWorkAnalysis.classworkdata &&
|
||||||
classWorkAnalysis.classworkdata.filter((item) => item.finishtimelength != '0')
|
classWorkAnalysis.classworkdata.filter((item) => item.finishtimelength != '0')
|
||||||
tableRadio.value = '1'
|
tableRadio.value = 1
|
||||||
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length
|
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length
|
||||||
tableRadio.num1 = tableRadio.list.length
|
tableRadio.num1 = tableRadio.list.length
|
||||||
// 自动批阅判断
|
// 自动批阅判断
|
||||||
|
@ -417,7 +417,7 @@ const getClassWorkStudentList = (rowId) => {
|
||||||
*/
|
*/
|
||||||
const teacherCriticism = ()=>{
|
const teacherCriticism = ()=>{
|
||||||
// 已交的list才自动批阅判断
|
// 已交的list才自动批阅判断
|
||||||
if(tableRadio.value == '1'&& classWorkAnalysis.worktype == '习题训练'){
|
if(tableRadio.value == 1 && classWorkAnalysis.worktype == '习题训练'){
|
||||||
// 只有习题训练才会自动批阅
|
// 只有习题训练才会自动批阅
|
||||||
tableRadio.list = tableRadio.list.map((item) => {
|
tableRadio.list = tableRadio.list.map((item) => {
|
||||||
return {
|
return {
|
||||||
|
@ -572,16 +572,16 @@ const tableRadioChange = (e) => {
|
||||||
isopen_dtwk_table.value = false;
|
isopen_dtwk_table.value = false;
|
||||||
console.log(e,'??????')
|
console.log(e,'??????')
|
||||||
console.log("学生列表:", classWorkAnalysis.classworkdata)
|
console.log("学生列表:", classWorkAnalysis.classworkdata)
|
||||||
if(e=='1'){
|
if(e==1){
|
||||||
tableRadio.list = classWorkAnalysis.classworkdata.filter(item => item.finishtimelength != '0')
|
tableRadio.list = classWorkAnalysis.classworkdata.filter(item => item.finishtimelength != '0')
|
||||||
tableRadio.value = '1';
|
tableRadio.value = 1;
|
||||||
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length;
|
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length;
|
||||||
tableRadio.num1 = tableRadio.list.length;
|
tableRadio.num1 = tableRadio.list.length;
|
||||||
// 自动批阅判断
|
// 自动批阅判断
|
||||||
teacherCriticism();
|
teacherCriticism();
|
||||||
}else if(e=='0'){
|
}else if(e==0){
|
||||||
tableRadio.list = classWorkAnalysis.classworkdata.filter(item => item.finishtimelength == '0')
|
tableRadio.list = classWorkAnalysis.classworkdata.filter(item => item.finishtimelength == '0')
|
||||||
tableRadio.value = '0';
|
tableRadio.value = 0;
|
||||||
tableRadio.num0 = tableRadio.list.length;
|
tableRadio.num0 = tableRadio.list.length;
|
||||||
tableRadio.num1 = classWorkAnalysis.classworkdata.length - tableRadio.list.length;
|
tableRadio.num1 = classWorkAnalysis.classworkdata.length - tableRadio.list.length;
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,7 +48,7 @@
|
||||||
const nodeClick = (data) => {
|
const nodeClick = (data) => {
|
||||||
getNodeInfo.value = {
|
getNodeInfo.value = {
|
||||||
textbookId:data.node.rootid,
|
textbookId:data.node.rootid,
|
||||||
bookList:getFullObj(data.node)
|
cataList:getFullObj(data.node)
|
||||||
}
|
}
|
||||||
console.log(getNodeInfo.value,'log')
|
console.log(getNodeInfo.value,'log')
|
||||||
}
|
}
|
||||||
|
|
|
@ -126,6 +126,12 @@
|
||||||
<span>下载</span>
|
<span>下载</span>
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
<div v-if="item.fileSuffix === 'ppt' || item.fileSuffix === 'pptx'" class="item-popover-item">
|
||||||
|
<el-button text @click="adToKj(item)">
|
||||||
|
<i class="iconfont icon-jiahao"></i>
|
||||||
|
<span>加入课件</span>
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
<div class="item-popover-item">
|
<div class="item-popover-item">
|
||||||
<el-button text @click="moveSmarttalkFun(item)">
|
<el-button text @click="moveSmarttalkFun(item)">
|
||||||
<el-icon>
|
<el-icon>
|
||||||
|
@ -153,7 +159,7 @@ import FileImage from '@/components/file-image/index.vue'
|
||||||
import { asyncLocalFile } from '@/utils/talkFile'
|
import { asyncLocalFile } from '@/utils/talkFile'
|
||||||
import { toTimeText } from '@/utils/date'
|
import { toTimeText } from '@/utils/date'
|
||||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||||
import { deleteSmarttalk, updateSmarttalk, getPrepareById } from '@/api/file'
|
import { deleteSmarttalk, updateSmarttalk, getPrepareById, addFileToKj } from '@/api/file'
|
||||||
import useUserStore from '@/store/modules/user'
|
import useUserStore from '@/store/modules/user'
|
||||||
import outLink from '@/utils/linkConfig'
|
import outLink from '@/utils/linkConfig'
|
||||||
|
|
||||||
|
@ -183,6 +189,14 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
adToKj(item) {
|
||||||
|
addFileToKj(item.id).then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
item.fileFlag = "课件"
|
||||||
|
},error=>{
|
||||||
|
console.log(error)
|
||||||
|
})
|
||||||
|
},
|
||||||
editTalk(item) {
|
editTalk(item) {
|
||||||
console.log(item,this.userInfo,'this.userInfo')
|
console.log(item,this.userInfo,'this.userInfo')
|
||||||
ElMessageBox.prompt('请输入新的名称', '重命名', {
|
ElMessageBox.prompt('请输入新的名称', '重命名', {
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
<div v-loading="isLoading" class="page-resource flex">
|
<div v-loading="isLoading" class="page-resource flex">
|
||||||
<ChooseTextbook @node-click="nodeClick" />
|
<ChooseTextbook @node-click="nodeClick" />
|
||||||
<div class="page-center-wrap">
|
<div class="page-center-wrap">
|
||||||
<el-button @click="openChapter" type="primary">打开章节</el-button>
|
|
||||||
<el-tabs v-model="activeAptTab" style="height: 100%;">
|
<el-tabs v-model="activeAptTab" style="height: 100%;">
|
||||||
<el-tab-pane label="教学课件" name="教学课件" class="prepare-center-jxkj">
|
<el-tab-pane label="教学课件" name="教学课件" class="prepare-center-jxkj">
|
||||||
<div class="prepare-center-header">
|
<div class="prepare-center-header">
|
||||||
|
@ -141,8 +140,6 @@
|
||||||
<!-- 上课配置 -->
|
<!-- 上课配置 -->
|
||||||
<class-start ref="calssRef" @close="closeChange"/>
|
<class-start ref="calssRef" @close="closeChange"/>
|
||||||
<PptDialog @add-success="addAiPPT" :currentNode="currentNode" :uploadData="uploadData" v-model="pptDialog"/>
|
<PptDialog @add-success="addAiPPT" :currentNode="currentNode" :uploadData="uploadData" v-model="pptDialog"/>
|
||||||
<!-- 章节弹窗 -->
|
|
||||||
<TreeLog ref="treelogRef"/>
|
|
||||||
<!-- <button @click="test">test</button> -->
|
<!-- <button @click="test">test</button> -->
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
|
@ -796,11 +793,6 @@ export default {
|
||||||
'&reservId=' +
|
'&reservId=' +
|
||||||
id
|
id
|
||||||
})
|
})
|
||||||
},
|
|
||||||
// 打开章节
|
|
||||||
openChapter(){
|
|
||||||
// 打开弹窗
|
|
||||||
this.$refs.treelogRef.openDialog()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,10 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<el-button v-loading="item.loading" size="small" plain round type="primary" @click.stop="openChapter(item)">
|
||||||
|
<i class="iconfont icon-jiahao"></i>
|
||||||
|
备课</el-button
|
||||||
|
>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</el-scrollbar>
|
</el-scrollbar>
|
||||||
|
@ -66,25 +70,27 @@
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<FilePreview ref="thirdPreview" v-model="isViewImg"></FilePreview>
|
<FilePreview ref="thirdPreview" v-model="isViewImg"></FilePreview>
|
||||||
|
<TreeLog ref="treelogRef" @onsuccess="addToPrepare"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
// import { ElMessage, ElMessageBox } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { Clock,View,Folder,Search } from '@element-plus/icons-vue'
|
import { Clock,View,Folder } from '@element-plus/icons-vue'
|
||||||
import FileImage from '@/components/file-image/index.vue'
|
import FileImage from '@/components/file-image/index.vue'
|
||||||
import FilePreview from '@/components/thirdFile-preview/index.vue'
|
import FilePreview from '@/components/thirdFile-preview/index.vue'
|
||||||
import useUserStore from '@/store/modules/user'
|
|
||||||
import useResoureStore from '../store'
|
import useResoureStore from '../store'
|
||||||
|
import { addFileToPrepareThird } from '@/api/file'
|
||||||
|
import TreeLog from '@/views/prepare/components/treeLog.vue'
|
||||||
|
|
||||||
const userstore = useUserStore()
|
|
||||||
const sourceStore = useResoureStore()
|
const sourceStore = useResoureStore()
|
||||||
|
|
||||||
// const userInfo = userstore.user
|
|
||||||
//判断是否预览图片
|
//判断是否预览图片
|
||||||
const isViewImg = ref(false)
|
const isViewImg = ref(false)
|
||||||
const thirdPreview = ref()
|
const thirdPreview = ref()
|
||||||
|
const treelogRef = ref()
|
||||||
|
const currentItem = ref()
|
||||||
|
|
||||||
// 分页change
|
// 分页change
|
||||||
const handleSizeChange = (limit) => {
|
const handleSizeChange = (limit) => {
|
||||||
|
@ -114,6 +120,31 @@ const handleRow = (item) => {
|
||||||
isViewImg.value = true
|
isViewImg.value = true
|
||||||
thirdPreview.value.init(item.itemId)
|
thirdPreview.value.init(item.itemId)
|
||||||
}
|
}
|
||||||
|
const openChapter = (item)=>{
|
||||||
|
currentItem.value = item
|
||||||
|
// 打开弹窗
|
||||||
|
treelogRef.value.openDialog()
|
||||||
|
}
|
||||||
|
const addToPrepare = (data) => {
|
||||||
|
console.log(data)
|
||||||
|
let chapterArr = []
|
||||||
|
for (let i = 0; i < data.cataList.length; i++) {
|
||||||
|
chapterArr.push({id: data.cataList[i].id,name: data.cataList[i].title})
|
||||||
|
}
|
||||||
|
let postData = {
|
||||||
|
itemId: currentItem.value.itemId,
|
||||||
|
textBookId: data.textbookId,
|
||||||
|
chapter: JSON.stringify(chapterArr)
|
||||||
|
}
|
||||||
|
currentItem.value.loading = true
|
||||||
|
addFileToPrepareThird(postData).then((res) => {
|
||||||
|
currentItem.value.loading = false
|
||||||
|
console.log(res)
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage.success("加入备课成功")
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
|
|
Loading…
Reference in New Issue