"use strict";(self["webpackChunkninepage"]=self["webpackChunkninepage"]||[]).push([[280],{3575:function(t,i,s){s.d(i,{Z:function(){return o}});var e=function(){var t=this,i=t._self._c;return i("div",t._l(t.list,(function(e,a){return i("div",{key:a},["ad"==e.type?[i("a",{attrs:{href:e.url}},[i("img",{staticClass:"banner-box",attrs:{src:e.image}})])]:i("div",{staticClass:"card-box",on:{click:function(i){return i.stopPropagation(),t.toDetail(e.tid)}}},[i("div",{staticClass:"top moreEllipsis"},[e.typename?i("div",{staticClass:"top-label"},[t._v(t._s(e.typename))]):t._e(),i("div",{staticClass:"top-title"},[t._v(t._s(e.subject))])]),i("div",{staticClass:"center"},[i("div",{staticClass:"center-text moreEllipsis"},[t._v(t._s(e.message))])]),i("div",{staticClass:"bottom"},[i("div",{staticClass:"bottom-box"},[i("img",{staticClass:"icon-head",attrs:{src:e.avatar}}),i("div",{staticClass:"bottom-name"},[t._v(t._s(e.author))])]),i("div",{staticClass:"bottom-box"},[i("div",{staticClass:"bottom-right"},[i("svg-icon",{attrs:{"icon-class":"look","class-name":"icon-look"}}),i("div",[t._v(t._s(e.views))])],1),i("div",{staticClass:"bottom-right"},[i("svg-icon",{attrs:{"icon-class":"msg","class-name":"icon-msg"}}),i("div",[t._v(t._s(e.replies))])],1)])]),e.digest>0?i("div",{staticClass:"rightTop"},[i("img",{staticClass:"rightTop-img",attrs:{src:s(2722)}}),i("span",[t._v("精华")])]):t._e()])],2)})),0)},a=[],n=(s(7658),{name:"IndexList",data(){return{}},props:["list"],mounted(){},methods:{toDetail(t){this.$router.push(`/detail?tid=${t}`)}}}),l=n,r=s(1001),c=(0,r.Z)(l,e,a,!1,null,"0176c134",null),o=c.exports},3438:function(t,i,s){s.d(i,{Z:function(){return o}});var e=function(){var t=this,i=t._self._c;return i("router-link",{staticClass:"path-box",attrs:{to:`/allSections?fid=${t.fid}`}},[i("div",[t._v("论坛")]),i("span",{staticClass:"path-slash"},[t._v("/")]),i("div",{staticClass:"oneEllipsis"},[t._v(t._s(t.stairname))]),i("span",{staticClass:"path-slash"},[t._v("/")]),i("div",{staticClass:"oneEllipsis"},[t._v(t._s(t.subsectionsname))])])},a=[],n={name:"PlateNavigation",data(){return{path:"/allSections"}},props:["stairname","subsectionsname","fid"],mounted(){},methods:{}},l=n,r=s(1001),c=(0,r.Z)(l,e,a,!1,null,"07dc0a79",null),o=c.exports},280:function(t,i,s){s.r(i),s.d(i,{default:function(){return d}});var e=function(){var t=this,i=t._self._c;return i("div",{staticClass:"recommend"},[i("div",{staticClass:"hot-box"},t._l(t.hotList,(function(s,e){return i("div",{key:e,staticClass:"hot-label",class:{active:s.fid==t.fid},on:{click:function(i){return t.hotLabelClick(s.fid)}}},[t._v(t._s(s.name))])})),0),0!=t.fid?i("plate-navigation",{attrs:{fid:t.plate.fid,stairname:t.plate.stairname,subsectionsname:t.plate.subsectionsname}}):t._e(),i("section",[0!=t.list.length||t.loading?[i("index-list",{attrs:{list:t.list}}),t.loading?t._e():i("div",{staticClass:"paging flexcenter"},[i("el-pagination",{attrs:{small:"",background:"",layout:"prev, pager, next","current-page":t.page,"page-size":t.limit,total:t.count},on:{"current-change":t.currentChange,"update:currentPage":function(i){t.page=i},"update:current-page":function(i){t.page=i}}})],1)]:i("div",{staticClass:"result-empty-box flexcenter shadow"},[i("img",{staticClass:"result-empty-icon",attrs:{src:s(8564)}})])],2)],1)},a=[],n=(s(7658),s(3438)),l=s(3575),r={name:"Recommend",data(){return{hotList:[],list:[],count:0,limit:20,page:1,fid:0,plate:{stairname:"",subsectionsname:"",fid:0},loading:null,allForumList:this.$store.state.allForumList||[]}},watch:{"$parent.recommend":{handler(t,i){this.hotList=t},immediate:!0},"$store.state.allForumList":{handler(t,i){this.allForumList=t,this.handleForumFid()},immediate:!0}},mounted(){let t={},{page:i,fid:s}=this.$route.query;i&&(this.page=Number(i),t["page"]=Number(i)),s&&(this.fid=s,this.handleForumFid(),t["fid"]=Number(s)),this.$parent["query"]=t,this.init()},methods:{init(){this.$startupUnderLoading(this),this.$http.get("/api/home/threadList",{limit:this.limit,type:"recommend",page:this.page,fid:this.fid}).then((t=>{if(200!=t.code)return;let i=t.data;this.list=i.data,this.limit=i.limit,this.page=i.page,this.count=i.count})).finally((()=>{this.$closeUnderLoading(this)}))},handleForumFid(){let t=this.allForumList;!Array.isArray(t)||t.length<=1||t.forEach(((t,i)=>{Array.isArray(t["data"])&&t.data.forEach((i=>{i["fid"]==this.fid&&(this.plate.subsectionsname=i.name,this.plate.stairname=t.name,this.plate.fid=t.fid)}))}))},currentChange(){let t={page:this.page};this.fid&&(t["fid"]=this.fid),this.$router.push({path:"/recommend",query:t})},hotLabelClick(t){let i={page:1,fid:t};this.$router.push({path:"/recommend",query:i})}},components:{plateNavigation:n.Z,indexList:l.Z}},c=r,o=s(1001),m=(0,o.Z)(c,e,a,!1,null,"28440cd8",null),d=m.exports},8564:function(t,i,s){t.exports=s.p+"img/empty.698c52d4.png"},2722:function(t){t.exports="data:image/png;base64,[encoded data, 10692 characters]"}}]);