mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 03:46:44 +08:00
案例的问题
This commit is contained in:
@@ -180,7 +180,7 @@
|
|||||||
<!-- <i class="el-icon-menu"></i> -->
|
<!-- <i class="el-icon-menu"></i> -->
|
||||||
<span slot="title" class="textl">我的授课记录</span>
|
<span slot="title" class="textl">我的授课记录</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
<el-menu-item index="/need/mycaseRecord">
|
<el-menu-item index="/case/mylist">
|
||||||
<!-- <i class="el-icon-menu"></i> -->
|
<!-- <i class="el-icon-menu"></i> -->
|
||||||
<span slot="title" class="textl">我的案例记录</span>
|
<span slot="title" class="textl">我的案例记录</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ export const pages=[
|
|||||||
{title:'文章管理',path:'manage',component:'article/ManageList',hidden:false}
|
{title:'文章管理',path:'manage',component:'article/ManageList',hidden:false}
|
||||||
]},
|
]},
|
||||||
{title:'案例',path:'/case',hidden:false,children:[
|
{title:'案例',path:'/case',hidden:false,children:[
|
||||||
{title:'我的案例',path:'mylist',component:'case/MyList',hidden:false},
|
{title:'我的案例记录',path:'mylist',component:'case/MyList',hidden:false},
|
||||||
{title:'案例管理',path:'manage',component:'case/ManageList',hidden:false}
|
{title:'案例管理',path:'manage',component:'case/ManageList',hidden:false}
|
||||||
]},
|
]},
|
||||||
{title: '我的待办',path: '/examine',hidden: false,children: [
|
{title: '我的待办',path: '/examine',hidden: false,children: [
|
||||||
@@ -56,7 +56,7 @@ export const pages=[
|
|||||||
{title:'已回答问题',path:'qafinish',component:'qa/TeacherList',hidden:false},
|
{title:'已回答问题',path:'qafinish',component:'qa/TeacherList',hidden:false},
|
||||||
{title:'我开发课程',path:'course',component:'course/TeacherList',hidden:false},
|
{title:'我开发课程',path:'course',component:'course/TeacherList',hidden:false},
|
||||||
{title:'我的授课记录',path:'mylecnotes',component:'course/Mylecnotes',hidden:false},
|
{title:'我的授课记录',path:'mylecnotes',component:'course/Mylecnotes',hidden:false},
|
||||||
{title:'我的案例记录',path:'mycaseRecord',component:'course/MycaseRecord',hidden:false},
|
// {title:'我的案例记录',path:'mycaseRecord',component:'course/MycaseRecord',hidden:false},
|
||||||
{title:'待审核的课程',path:'waitaudit',component:'course/WaitAudit',hidden:true},
|
{title:'待审核的课程',path:'waitaudit',component:'course/WaitAudit',hidden:true},
|
||||||
{title:'已审核的课程',path:'waitaudited',component:'course/WaitAudited',hidden:true},
|
{title:'已审核的课程',path:'waitaudited',component:'course/WaitAudited',hidden:true},
|
||||||
]},
|
]},
|
||||||
|
|||||||
@@ -195,7 +195,7 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
open(item) {
|
open(item) {
|
||||||
this.$confirm('是否推荐该案例为优秀案例?', '提示', {
|
this.$confirm('是否设置此案例为优秀案例吗?', '提示', {
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: '确定',
|
||||||
cancelButtonText: '取消',
|
cancelButtonText: '取消',
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
@@ -210,7 +210,7 @@ export default {
|
|||||||
if(res.status == 200){
|
if(res.status == 200){
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
message: '推荐成功!'
|
message: '设置优秀案例成功!'
|
||||||
});
|
});
|
||||||
this.getData()
|
this.getData()
|
||||||
}
|
}
|
||||||
@@ -218,7 +218,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'info',
|
type: 'info',
|
||||||
message: '已取消推荐'
|
message: '已取消优秀案例设置'
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,11 +1,110 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="u-page">
|
<div style="padding: 12px 32px 10px 12px;">
|
||||||
只是显示推荐给我的案例,这里只是查看.目录中没有“我的案例”,所以此页面当前没有用到
|
<div style="display: flex;justify-content: flex-start;">
|
||||||
</div>
|
<div style="margin-left:10px"><el-input v-model="caseData.keyWord" placeholder="名称关键字" clearable></el-input></div>
|
||||||
|
<div style="padding-left: 10px;"><el-button type="primary" icon="el-icon-search" @click="getsearch()">搜索</el-button></div>
|
||||||
|
<div style="padding: 0px 5px;"><el-button icon="el-icon-refresh-right" type="primary" @click="reset">重置</el-button></div>
|
||||||
|
<div style="padding: 0px 5px;"><el-button icon="el-icon-refresh-right" type="primary" @click="Export">导出</el-button></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div style="margin-top:20px;">
|
||||||
|
<el-table :data="params" border stripe >
|
||||||
|
<el-table-column label="案例名称" prop="title" width="200px"> </el-table-column>
|
||||||
|
<el-table-column label="状态" prop="status" width="100px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span v-if="scope.row.status == 0">草稿</span>
|
||||||
|
<span v-if="scope.row.status == 1">待审核</span>
|
||||||
|
<span v-if="scope.row.status == 2">未通过</span>
|
||||||
|
<span v-if="scope.row.status == 3">已发布</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="审批完成时间" prop="endTime" width="200px"></el-table-column>
|
||||||
|
<el-table-column label="公开范围" prop="caseScope" width="100px"> </el-table-column>
|
||||||
|
<el-table-column label="浏览量" prop="views" ></el-table-column>
|
||||||
|
<el-table-column label="点赞量" prop="praises" width="100px"></el-table-column>
|
||||||
|
<el-table-column label="分享量" prop="shares" width="100px"></el-table-column>
|
||||||
|
<el-table-column label="收藏量" width="100px" prop="favorites"></el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</div>
|
||||||
|
<div v-if="count > 0" style="text-align: center; margin-top:57px">
|
||||||
|
<el-pagination
|
||||||
|
background
|
||||||
|
@size-change="handleSizeChange"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
:current-page="caseData.pageIndex"
|
||||||
|
:page-sizes="[10, 20, 30, 40]"
|
||||||
|
:page-size="caseData.pageSize"
|
||||||
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
|
:total="count"
|
||||||
|
></el-pagination>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import aipCase from '../../api/modules/cases.js';
|
||||||
|
import { mapGetters,mapActions } from 'vuex';
|
||||||
|
export default {
|
||||||
|
computed: {
|
||||||
|
...mapGetters(['userInfo']),
|
||||||
|
},
|
||||||
|
data(){
|
||||||
|
return {
|
||||||
|
count:0,
|
||||||
|
caseData:{
|
||||||
|
pageIndex:1,
|
||||||
|
pageSize:10,
|
||||||
|
keyWord:'',
|
||||||
|
status:0,
|
||||||
|
},
|
||||||
|
params:[],
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted(){
|
||||||
|
this.getcaseData();
|
||||||
|
},
|
||||||
|
|
||||||
|
methods:{
|
||||||
|
Export(){
|
||||||
|
let data = {
|
||||||
|
keyWord:this.caseData.keyWord,
|
||||||
|
}
|
||||||
|
aipCase.exportCases(data).then(res =>{
|
||||||
|
|
||||||
|
})
|
||||||
|
},
|
||||||
|
getsearch(){
|
||||||
|
this.caseData.pageIndex = 1;
|
||||||
|
this.getcaseData();
|
||||||
|
},
|
||||||
|
handleSizeChange(val) {
|
||||||
|
this.caseData.pageSize = val;
|
||||||
|
this.caseData.pageIndex = 1;
|
||||||
|
this.getcaseData();
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.caseData.pageIndex = val;
|
||||||
|
this.getcaseData();
|
||||||
|
},
|
||||||
|
getcaseData(){
|
||||||
|
aipCase.mylist(this.caseData).then(res =>{
|
||||||
|
//console.log(res);
|
||||||
|
this.count = res.result.count;
|
||||||
|
this.params = res.result.list
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
reset(){
|
||||||
|
this.caseData.keyWord = '';
|
||||||
|
this.getcaseData();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style lang="scss" scoped>
|
||||||
|
.Export{
|
||||||
|
display: flex;
|
||||||
|
padding-top: 10px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user