(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-0284b287","chunk-57097646"],{"0a93":function(t,a,e){"use strict";e("a781")},"365c":function(t,a,e){"use strict";e.d(a,"b",(function(){return n})),e.d(a,"a",(function(){return r}));var s=e("b775"),n=function(t){return Object(s["a"])({url:"/data/index",method:"get",params:t})},r=function(t){return Object(s["a"])({url:"/data/getCourseRead",method:"get",params:t})}},9406:function(t,a,e){"use strict";e.r(a);var s=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"home"},[e("div",{staticClass:"home_data"},[e("el-row",{attrs:{gutter:20,type:"flex",justify:"space-between"}},[e("el-col",{attrs:{span:8}},[e("div",{staticClass:"grid-content"},[e("div",[e("div",{staticClass:"name"},[t._v("课程数量")]),e("div",{staticClass:"num"},[t._v(t._s(t.homeData.course_count||0))])]),e("svg-icon",{attrs:{"icon-class":"goods","class-name":"custom-class"}})],1)]),e("el-col",{attrs:{span:8}},[e("div",{staticClass:"grid-content"},[e("div",[e("div",{staticClass:"name"},[t._v("总阅读量")]),e("div",{staticClass:"num"},[t._v(t._s(t.homeData.read_count||0))])]),e("svg-icon",{attrs:{"icon-class":"user","class-name":"custom-class"}})],1)]),e("el-col",{attrs:{span:8}},[e("div",{staticClass:"grid-content"},[e("div",[e("div",{staticClass:"name"},[t._v("总分享量")]),e("div",{staticClass:"num"},[t._v(t._s(t.homeData.share_count||0))])]),e("svg-icon",{attrs:{"icon-class":"store","class-name":"custom-class"}})],1)])],1)],1),e("div",{staticClass:"echarts"},[e("el-row",{staticClass:"table_con"},[e("el-col",{attrs:{span:24}},[e("div",{ref:"echart7"},[e("all-rank",{attrs:{width:"100%"}})],1)])],1)],1)])},n=[],r=(e("d3b7"),e("365c")),c=e("c553"),i={name:"Dashboard",components:{allRank:c["default"]},data:function(){return{homeData:""}},created:function(){this.getData()},methods:{getData:function(){var t=this;Object(r["b"])().then((function(a){200===a.code?t.homeData=a.data:t.$message.error(a.msg||"获取数据失败")})).catch((function(a){t.$message.error(a||"获取数据失败")})).finally((function(a){t.loading=!1}))}}},o=i,l=(e("0a93"),e("2877")),u=Object(l["a"])(o,s,n,!1,null,"dc6c7dc0",null);a["default"]=u.exports},a781:function(t,a,e){},c51a:function(t,a,e){"use strict";e("c952")},c553:function(t,a,e){"use strict";e.r(a);var s=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",[e("div",{staticClass:"rank"},[t._v("数据排名")]),e("el-table",{ref:"allTable",staticStyle:{width:"100%","max-height":"480px",overflow:"auto"},attrs:{border:"",data:t.list,height:"480"},on:{"sort-change":t.toSort}},[e("el-table-column",{attrs:{label:"排名",type:"index",align:"center",width:"60",index:function(a){return t.params.page_size*(t.params.page_index-1)+a+1}}}),e("el-table-column",{attrs:{label:"标题",prop:"title",align:"center","show-overflow-tooltip":""}}),e("el-table-column",{attrs:{label:"简介",prop:"perface",align:"center","show-overflow-tooltip":""}}),e("el-table-column",{attrs:{label:"时间",prop:"created_at",align:"center","show-overflow-tooltip":""}}),e("el-table-column",{attrs:{label:"分享量",prop:"share",align:"center",sortable:"custom",width:"120"}}),e("el-table-column",{attrs:{label:"阅读量",prop:"read",align:"center",sortable:"custom",width:"120"}})],1),e("div",{staticClass:"batch-container"},[e("el-pagination",{attrs:{total:t.totalPage,"current-page":t.params.page_index,"page-sizes":[10,15,20,30,100],"page-size":t.params.page_size,layout:"total, sizes, prev, pager, next, jumper"},on:{"size-change":t.handleSizeChange,"current-change":t.handleCurrentChange}})],1)],1)},n=[],r=e("1da1"),c=(e("96cf"),e("365c")),i={data:function(){return{list:[],params:{page_index:1,page_size:10,type:"read",sort:"desc"},totalPage:0}},created:function(){this.getList()},methods:{getList:function(){var t=this;return Object(r["a"])(regeneratorRuntime.mark((function a(){var e,s,n,r;return regeneratorRuntime.wrap((function(a){while(1)switch(a.prev=a.next){case 0:return a.next=2,Object(c["a"])(t.params);case 2:e=a.sent;try{s=e.msg,n=e.code,r=e.data,200===n?(t.list=r.list,t.totalPage=r.total):t.$message.error(s||"获取数据失败")}catch(i){t.$message.error(i||"获取数据失败")}case 4:case"end":return a.stop()}}),a)})))()},toSort:function(t){var a=t.prop,e=t.order;this.params.type=a,this.params.sort="ascending"===e?"asc":"desc",this.getList()},handleSizeChange:function(t){this.params.page_size=t,this.getList()},handleCurrentChange:function(t){this.params.page_index=t,this.getList()}}},o=i,l=(e("c51a"),e("2877")),u=Object(l["a"])(o,s,n,!1,null,"c0a1af52",null);a["default"]=u.exports},c952:function(t,a,e){}}]);