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:
@@ -90,25 +90,32 @@
|
||||
<i class="el-icon-time"></i>
|
||||
<time-show :time="item.sysCreateTime"></time-show>
|
||||
</div>
|
||||
</div>
|
||||
</router-link>
|
||||
</div>
|
||||
</router-link>
|
||||
</div>
|
||||
<div style="height:35px">
|
||||
<author :avatar="item.authorInfo.avatar" :name="item.authorInfo.name" :info="item.authorInfo.orgInfo" :sex="item.authorInfo.sex"></author>
|
||||
</div>
|
||||
<router-link :to="'/case/detail?id='+item.id">
|
||||
<div class="case-info-summary" >
|
||||
{{item.summary}}
|
||||
<author :avatar="item.authorInfo.avatar" :name="item.authorInfo.name" :info="item.authorInfo.orgInfo" :sex="item.authorInfo.sex"></author>
|
||||
</div>
|
||||
<!-- <router-link :to="'/case/detail?id='+item.id"> -->
|
||||
<!-- class="case-info-summary" -->
|
||||
<div>
|
||||
<router-link :to="'/case/detail?id='+item.id">
|
||||
<!-- {{item.summary}} -->
|
||||
{{displayAll(item)}}
|
||||
</router-link>
|
||||
<span style="color:#588afc" v-if="item.summary.length>90" @click="changeIsAll(item)">
|
||||
{{item.isAll?'收起':'全文'}}
|
||||
</span>
|
||||
</div>
|
||||
</router-link>
|
||||
<div class="button-wrap" v-if="needShowExpande">
|
||||
<!-- </router-link> -->
|
||||
<!-- <div class="button-wrap" v-if="needShowExpande">
|
||||
<div class="exp-but" @click="expandeClick" v-if="!expande">展开
|
||||
</div>
|
||||
<div class="exp-but" @click="expandeClick" v-else>收起</div>
|
||||
</div>
|
||||
|
||||
</div> -->
|
||||
|
||||
<div style="display: flex;justify-content: space-between;">
|
||||
|
||||
|
||||
<div>
|
||||
<interactBar :type="0" :shares="false" :data="item" :readonly="false"></interactBar> </div>
|
||||
</div>
|
||||
@@ -331,17 +338,20 @@ export default {
|
||||
window.removeEventListener("scroll",this.handleScroll);
|
||||
},
|
||||
methods: {
|
||||
|
||||
tagsClose(tag, index){
|
||||
|
||||
},
|
||||
|
||||
|
||||
//展示全部
|
||||
displayAll(item) {
|
||||
if(!item.isAll && item.summary && item.summary.length > 90) {
|
||||
return item.summary.slice(0, 90) + "...";
|
||||
}
|
||||
return item.summary;
|
||||
},
|
||||
changeIsAll(item) {
|
||||
item.isAll=!item.isAll;
|
||||
},
|
||||
closeSearch() {
|
||||
this.showAll = !this.showAll;
|
||||
var searchBoxHeght = document.getElementById("searchBox");
|
||||
var searchBoxWidth = document.getElementById("searchBox");
|
||||
// console.log(searchBoxWidth.clientWidth);
|
||||
if(searchBoxWidth.clientWidth > 950){
|
||||
this.searchwd = false;
|
||||
}
|
||||
@@ -467,6 +477,7 @@ export default {
|
||||
if(res.status==200){
|
||||
if(res.result.list.length>0){
|
||||
res.result.list.forEach(item=>{
|
||||
item.isAll=false;
|
||||
item.authorInfo={aid:'',name:'',orgInfo:'',avatar:'',sex:null};
|
||||
if(item.isTop) {
|
||||
isTopList.push(item);
|
||||
@@ -765,7 +776,7 @@ export default {
|
||||
}
|
||||
.case-info-summary {
|
||||
height: 60px;
|
||||
|
||||
|
||||
line-height: 30px;
|
||||
font-size: 15px;
|
||||
color: #444444;
|
||||
|
||||
Reference in New Issue
Block a user