页面内容调整

This commit is contained in:
18571350067 2021-11-26 16:44:03 +08:00
parent 26ba23320c
commit 3c4dc139ac
5 changed files with 47 additions and 52 deletions

View File

@ -175,10 +175,8 @@ export default {
methods: {
//
onChange(dataValue) {
console.log('changed', dataValue)
},
save() {
console.log(this.form)
courseAdd(this.form).then((res) => {
if (res.code == 200) {
this.$message.info('保存成功')
@ -205,12 +203,9 @@ export default {
//
dictionaryDropDown({dictionaryCode: '0008'}).then((res) => {
const tagList = res.data
console.log(tagList)
for ( let i = 0; i < tagList.length; i++) {
console.log(tagList[i]);
tagList[i].value = tagList[i].value.toString()
}
console.log(tagList)
this.dictCourseTag = tagList
})
},
@ -231,7 +226,6 @@ export default {
return hreader
},
onSuccess(file) {
console.log('1---', file)
},
handleCancel() {
this.previewVisible = false
@ -252,7 +246,6 @@ export default {
//
handleTagChange(value) {
console.log('value------' ,value);
this.form.tags = value;
},
},

View File

@ -62,7 +62,6 @@ export default {
},
created() {
this.dictionaryDropDown()
console.log('aaa', this.dictCourseTag)
},
methods: {
//
@ -72,12 +71,9 @@ export default {
//
dictionaryDropDown({ dictionaryCode: '0008' }).then((res) => {
const tagList = res.data
console.log(tagList)
for (let i = 0; i < tagList.length; i++) {
console.log(tagList[i])
tagList[i].id = tagList[i].value.toString()
}
console.log(tagList)
this.queryOptions[1].options = tagList
})
},

View File

@ -1,26 +1,26 @@
<template>
<a-card :bordered="false" title="课件信息">
<template slot="extra">
<a-button size="small" @click="goback">返回</a-button>
<a-card :bordered="false" title="课件信息">
<template slot="extra">
<a-button size="small" @click="goback">返回</a-button>
</template>
<div class="button" style="width: 100%; height: 32px; margin-bottom: 8px; margin-right: 10%;">
<!-- <a-button type="primary" @click="goback">返回</a-button> -->
<a-button type="primary" @click="coursewareAdd">上传课件</a-button>
</div>
<s-table ref="table" size="default" rowKey="id" :columns="columns" :data="loadData">
<template slot="action" slot-scope="text, record">
<a href="javascript:;" @click="detail(record)">预览</a>
<a-divider type="vertical" />
<a href="javascript:;" @click="courseWare(record)">重新上传</a>
<a-divider type="vertical" />
<a-popconfirm title="是否删除?" @confirm="() => del(record)">
<a href="javascript:;">删除</a>
</a-popconfirm>
<a-divider type="vertical" />
<a href="javascript:;" @click="courseQuestion(record)">抽考题</a>
</template>
<div class="button" style="width: 100%; height: 32px; margin-bottom: 8px; margin-right: 10%;">
<!-- <a-button type="primary" @click="goback">返回</a-button> -->
<a-button type="primary" @click="coursewareAdd">上传课件</a-button>
</div>
<s-table ref="table" size="default" rowKey="id" :columns="columns" :data="loadData">
<template slot="action" slot-scope="text, record">
<a href="javascript:;" @click="detail(record)">预览</a>
<a-divider type="vertical" />
<a href="javascript:;" @click="courseWare(record)">重新上传</a>
<a-divider type="vertical" />
<a-popconfirm title="是否删除?" @confirm="() => del(record)">
<a href="javascript:;">删除</a>
</a-popconfirm>
<a-divider type="vertical" />
<a href="javascript:;" @click="courseQuestion(record)">抽考题</a>
</template>
</s-table>
</a-card>
</s-table>
</a-card>
</template>
<script>
import { STable, SearchCom } from '@/components'
@ -43,36 +43,47 @@ export default {
},
columns: [
{ title: '课件名称', width: '160px', align: 'center', dataIndex: 'name', key: 'name' },
{ title: '课件分类',width: '300px',align: 'center', dataIndex: 'coursewareClassifyId', key: 'coursewareClassifyId',},
{
title: '课件分类',
width: '300px',
align: 'center',
dataIndex: 'coursewareClassifyId',
key: 'coursewareClassifyId',
},
{ title: '课时/分', width: '160px', align: 'center', dataIndex: 'duration', key: 'duration' },
{ title: '课件大小(MB)', width: '160px', align: 'center', dataIndex: 'sizeStr', key: 'sizeStr'},
{ title: '课件大小(MB)', width: '160px', align: 'center', dataIndex: 'sizeStr', key: 'sizeStr' },
{ title: '操作', key: 'operation', width: '200px', align: 'center', scopedSlots: { customRender: 'action' } },
],
}
},
methods: {
//
coursewareAdd(){
this.$router.push({path:"/course/CoursewareAddOrUpdate",query:{courseId: this.$route.query.id}})
console.log('IDIDIDID',this.$route.query.id)
coursewareAdd() {
this.$router.push({ path: '/course/CoursewareAddOrUpdate', query: { courseId: this.$route.query.id } })
console.log('IDIDIDID', this.$route.query.id)
},
//
goback(){
this.$router.push({path:"/course/CourseList",query:{} })
goback() {
this.$router.push({ path: '/course/CourseList', query: {} })
},
//
del(record){
deleteCourseware({id:record.id}).then(res => {
if(res.code == 200) this.$refs.table.refresh(true);
});
del(record) {
deleteCourseware({ id: record.id }).then((res) => {
if (res.code == 200) {
this.$refs.table.refresh(true)
this.$message.success('删除成功!');
} else {
this.$message.error('删除失败!');
}
})
},
//
courseQuestion(record){
console.log("哈哈");
this.$router.push({path :'/course/question/examQuestion',query:{id : record.id} });
}
courseQuestion(record) {
console.log('哈哈')
this.$router.push({ path: '/course/question/examQuestion', query: { id: record.id } })
},
},
}
</script>

View File

@ -337,7 +337,6 @@ export default {
//
estimateV() {
console.log('rightAnswers', this.estimate.rightAnswers)
//
if (!this.estimate.questionName || this.estimate.questionName === '') {
this.$message.error('题干不能为空!')
@ -390,7 +389,6 @@ export default {
if(this.multiselect.rightAnswers.indexOf('B') > -1) this.multiselect.b = true;
if(this.multiselect.rightAnswers.indexOf('C') > -1) this.multiselect.c = true;
if(this.multiselect.rightAnswers.indexOf('D') > -1) this.multiselect.d = true;
console.log('1---', this.multiselect)
},
},

View File

@ -130,7 +130,6 @@ export default {
quesionId: function (i, index) {
if (this.quesitonList != null && this.quesitonList.length != 0) {
//ID
console.log('题目!!!!', this.quesitonList.length)
this.isactive = index
this.questionId = i
@ -168,7 +167,6 @@ export default {
})
},
edit(record) {
console.log(record)
this.$router.push({
path: '/course/question/QuestionAdd',
query: {
@ -227,7 +225,6 @@ export default {
this.visible = true
},
handleOk(e) {
console.log(e)
this.visible = false
},