mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 11:56:44 +08:00
案例小优化
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="item-author">
|
<div class="item-author">
|
||||||
<div @click="toHome()">
|
<div v-if="userName" @click="toHome()">
|
||||||
<!-- <el-avatar shape="square" size="small" :src="userAvatar" v-if="userAvatar"></el-avatar> -->
|
<!-- <el-avatar shape="square" size="small" :src="userAvatar" v-if="userAvatar"></el-avatar> -->
|
||||||
<!-- <div v-else class="uavatar"><span class="uavatar-text">{{avatarText}}</span></div> -->
|
<!-- <div v-else class="uavatar"><span class="uavatar-text">{{avatarText}}</span></div> -->
|
||||||
<el-avatar shape="circle" size="small" :src="userAvatar" v-if="userAvatar"></el-avatar>
|
<el-avatar shape="circle" size="small" :src="userAvatar" v-if="userAvatar"></el-avatar>
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="!onlyAvatar" style="padding-left: 14px;padding-top: 6px;font-size: 14px;">
|
<div v-if="!onlyAvatar&&userName" style="padding-left: 14px;padding-top: 6px;font-size: 14px;">
|
||||||
<span style="color: #333333;font-weight: 600;font-size: 16px;">{{userName}}</span>
|
<span style="color: #333333;font-weight: 600;font-size: 16px;">{{userName}}</span>
|
||||||
<span class="author-text" v-if="userInfo && userInfo!=''"> {{userInfo}} </span>
|
<span class="author-text" v-if="userInfo && userInfo!=''"> {{userInfo}} </span>
|
||||||
<span style="margin-left: 15px;" class="comWords" v-if="authorTags.length != 0" v-for="tag in authorTags">{{tag}}</span>
|
<span style="margin-left: 15px;" class="comWords" v-if="authorTags.length != 0" v-for="tag in authorTags">{{tag}}</span>
|
||||||
|
|||||||
@@ -289,7 +289,7 @@ export default {
|
|||||||
this.$message.error('最多推荐10个')
|
this.$message.error('最多推荐10个')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.$confirm('你确认要推荐此案例么?', '提示', {
|
this.$confirm('你确认要推荐此案例吗?', '提示', {
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: '确定',
|
||||||
cancelButtonText: '取消',
|
cancelButtonText: '取消',
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
@@ -304,7 +304,7 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleNotRank(record){
|
handleNotRank(record){
|
||||||
this.$confirm('你确认要取消推荐么?', '提示', {
|
this.$confirm('你确认要取消推荐吗?', '提示', {
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: '确定',
|
||||||
cancelButtonText: '取消',
|
cancelButtonText: '取消',
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
|
|||||||
@@ -487,6 +487,7 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
timeoutId: null,
|
||||||
isTimeData: false,
|
isTimeData: false,
|
||||||
articlePageList: [],
|
articlePageList: [],
|
||||||
caseTimeShow: true,
|
caseTimeShow: true,
|
||||||
@@ -1301,6 +1302,10 @@ export default {
|
|||||||
if(num == 'collect'){
|
if(num == 'collect'){
|
||||||
this.caseTimeShow = false
|
this.caseTimeShow = false
|
||||||
}
|
}
|
||||||
|
if (this.timeoutId) {
|
||||||
|
clearTimeout(this.timeoutId);
|
||||||
|
this.timeoutId = null;
|
||||||
|
}
|
||||||
this.search(true);
|
this.search(true);
|
||||||
// this.getCaseData();
|
// this.getCaseData();
|
||||||
},
|
},
|
||||||
@@ -1488,7 +1493,7 @@ export default {
|
|||||||
// 给所有的赋值
|
// 给所有的赋值
|
||||||
this.caseList.count = res.result.count;
|
this.caseList.count = res.result.count;
|
||||||
this.caseList.showPagCount = res.result.count;
|
this.caseList.showPagCount = res.result.count;
|
||||||
setTimeout(() => {
|
this.timeoutId = setTimeout(() => {
|
||||||
this.numIsFalse = false
|
this.numIsFalse = false
|
||||||
}, 3000);
|
}, 3000);
|
||||||
}
|
}
|
||||||
@@ -1539,7 +1544,7 @@ export default {
|
|||||||
this.getCaseUserData(res.result.list);
|
this.getCaseUserData(res.result.list);
|
||||||
this.caseList.count = res.result.count;
|
this.caseList.count = res.result.count;
|
||||||
this.caseList.showPagCount = res.result.count;
|
this.caseList.showPagCount = res.result.count;
|
||||||
setTimeout(() => {
|
this.timeoutId = setTimeout(() => {
|
||||||
this.numIsFalse = false
|
this.numIsFalse = false
|
||||||
}, 3000);
|
}, 3000);
|
||||||
}
|
}
|
||||||
@@ -1576,7 +1581,7 @@ export default {
|
|||||||
// 给所有的赋值
|
// 给所有的赋值
|
||||||
this.caseList.count = res.result.count;
|
this.caseList.count = res.result.count;
|
||||||
this.caseList.showPagCount = res.result.count;
|
this.caseList.showPagCount = res.result.count;
|
||||||
setTimeout(() => {
|
this.timeoutId = setTimeout(() => {
|
||||||
this.numIsFalse = false
|
this.numIsFalse = false
|
||||||
}, 3000);
|
}, 3000);
|
||||||
} else {
|
} else {
|
||||||
@@ -1584,7 +1589,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
// console.log(err);
|
// console.log(err);
|
||||||
setTimeout(() => {
|
this.timeoutId = setTimeout(() => {
|
||||||
this.numIsFalse = false
|
this.numIsFalse = false
|
||||||
}, 3000);
|
}, 3000);
|
||||||
});
|
});
|
||||||
@@ -1623,10 +1628,7 @@ export default {
|
|||||||
// });
|
// });
|
||||||
},
|
},
|
||||||
getCase(ids,list){
|
getCase(ids,list){
|
||||||
console.log(ids,list,'xixixi')
|
|
||||||
apiCase.ids(ids).then(res=>{
|
apiCase.ids(ids).then(res=>{
|
||||||
console.log(res,'ressss')
|
|
||||||
return
|
|
||||||
if(res.status == 200) {
|
if(res.status == 200) {
|
||||||
this.isSeach = false;
|
this.isSeach = false;
|
||||||
const listData = []
|
const listData = []
|
||||||
|
|||||||
Reference in New Issue
Block a user