diff --git a/src/views/portal/case/Index.vue b/src/views/portal/case/Index.vue index b413dac1..189cc36d 100644 --- a/src/views/portal/case/Index.vue +++ b/src/views/portal/case/Index.vue @@ -90,25 +90,32 @@ - - + +
- -
- -
- {{item.summary}} + +
+ + +
+ + + {{displayAll(item)}} + + + {{item.isAll?'收起':'全文'}} +
-
-
+ + +
- +
@@ -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;