You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

1 lines
7.5 KiB

(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-18cbc6da"],{1671:function(t,e,a){},"4abe":function(t,e,a){},"664d":function(t,e,a){"use strict";var i=a("1671");a.n(i).a},"734a":function(t,e,a){"use strict";var i=a("4abe");a.n(i).a},d178:function(t,e,a){"use strict";a.r(e);a("4160"),a("d81d"),a("13d5"),a("b0c0"),a("b64b"),a("d3b7"),a("3ca3"),a("159b"),a("ddb0"),a("e260"),a("e6cf");var i=a("313e"),n=a("284b"),o=function(t){return n.a.request({url:t,method:"GET"})},c=a("9394"),s=a("2da7"),r=a("ff32"),l=a("3094"),u=a("4b2a"),d=a("49bb"),f=a("3620"),m=a("f95e"),h={name:"useItem",props:["count1","count2","title","color","icon","headicon","headiconcolor"],data:function(){return{}}},p=(a("734a"),a("2877")),v=Object(p.a)(h,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"monthUse animation-left"},[a("div",{staticClass:"item-header"},[a("header",{staticClass:"w100 d-flex a-center j-center "},[a("div",{staticClass:"item-title"},[t._v(t._s(t.title))]),a("i",{staticClass:"iconfont ",class:t.headicon,style:{color:t.headiconcolor}})])]),a("div",{staticClass:"use-detail a-center"},[a("div",[a("div",{staticClass:"m-bottom-2"},[t._v("发票识别:"+t._s(t.count1||0))]),a("div",[t._v("发票验真:"+t._s(t.count2||0))])]),a("div",[a("i",{staticClass:"iconfont ",class:t.icon,style:{color:t.color}})])])])}),[],!1,null,"97089752",null).exports;i.b([c.a,s.a,r.a,d.a,f.a,l.a,u.a,m.a]);var g={components:{useItem:v},data:function(){return{pieOption:{title:{text:"票种识别占比",left:"center"},tooltip:{trigger:"item",formatter:function(t){return"发票类型:"+t.data.name+"<br>使用次数:"+t.data.value+"<br>发票占比:"+"<span style='color:red'>".concat(t.percent,"</span>")+"%"},color:function(t){}},legend:{left:"left",top:"8%"},series:[{type:"pie",radius:"40%",center:["50%","80%"],label:{show:!0,position:"outside",formatter:"{c}, {d}%"},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}}}]},lineOptions:{title:{text:"票量识别趋势",left:"center"},tooltip:{trigger:"axis",axisPointer:{type:"cross",label:{backgroundColor:"#64e1e3"}}},legend:{type:"plain",top:30,left:"center"},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",boundaryGap:!1,data:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"]},yAxis:{type:"value"},toolbox:{feature:{saveAsImage:{}}},series:[{color:"#fda07e",name:"2020年",type:"line",stack:"总量",areaStyle:{},label:{show:!0,position:"top"}},{color:"#64e1e3",name:"2021年",type:"line",stack:"总量",areaStyle:{},label:{show:!0,position:"top"}}]},currentMonth:{},currentYear:{},commonMonth:{},commonYear:{},loading:!1,loading1:!0,tips:"",rateTotal:0,obj:{a:1},str:"abc"}},mounted:function(){var t=this;this.getNotice(),this.$nextTick((function(){var e=document.getElementById("pieEchart"),a=i.a(e);t.myChart=a,t.pieOption&&a.setOption(t.pieOption);var n=document.getElementById("lineEchart"),o=i.a(n);t.mylineChart=o,t.lineOptions&&o.setOption(t.lineOptions),t.getInvocieRate(),t.getLineRate(),t.getUserData(),t.resizeEcharts(o,a)}))},methods:{getNotice:function(){var t,e=this;(t={limit:1},n.a.request({url:"manager/anly/notes",method:"GET",params:t})).then((function(t){e.tips=t.result[0].title}))},getUserData:function(){var t=this;Promise.all([o("manager/anly/corporateInvoiceMonthNum"),o("manager/anly/corporateInvoiceYearNum")].map((function(t){return t.catch((function(t){}))}))).then((function(e){t.currentMonth=e[0].result,t.currentYear=e[1].result}))},getLineRate:function(){var t=this;n.a.request({url:"manager/anly/getEveryInvoiceNum",method:"GET"}).then((function(e){if(200==e.status){var a=Object.keys(e.result),i=[],n=[];a.forEach((function(t,a){switch(a){case 0:i=e.result[t].map((function(t){return t.num}));break;case 1:n=e.result[t].map((function(t){return t.num}))}}));var o={series:[{data:i,name:a[0]},{data:n,name:a[1]}],legend:{data:a}};t.loading1=!1,t.mylineChart.setOption(o)}else t.loading1=!1})).catch((function(){t.loading1=!1}))},getInvocieRate:function(){var t=this;n.a.request({url:"manager/anly/getInvoiceTypeRate",method:"GET"}).then((function(e){if(200==e.status){var a=e.result.reduce((function(t,e){return t+parseFloat(e.invoiceRate)}),0);a;var i=e.result.map((function(t){return{name:t.invoiceType,value:t.invoiceRate}}));t.pieOption.series[0].data=i,t.loading=!1,t.myChart.setOption(t.pieOption)}else t.loading=!1})).catch((function(){t.loading=!1}))},resizeEcharts:function(t,e){window.onresize=function(){t.resize(),e.resize()}}},beforeDestroy:function(){window.onresize=null}},b=(a("664d"),Object(p.a)(g,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"Index"},[a("h1",{staticClass:"w100 d-flex a-center j-center bg-fff f-weight",staticStyle:{height:"3.75em","font-size":"24px !important","border-bottom":"1px solid #eee"}},[t._v(" 欢迎使用智能发票管家! ")]),a("div",{staticClass:"d-flex w100 m-top-2"},[a("div",{staticClass:"d-flex",staticStyle:{"flex-direction":"column",width:"40%","min-width":"260px"}},[t._m(0),a("div",{staticClass:"d-flex j-sb"},[a("use-item",{attrs:{title:"当月发票数",count1:t.commonMonth.invoiceMonthNum,count2:t.commonMonth.invoiceMonthTrustNum,color:"#fbc908",headiconcolor:"#389e0d",headicon:"icon-yue",icon:"icon-zhexiantu"}}),a("use-item",{attrs:{title:"当年发票数",count1:t.commonYear.invoiceYearNum,count2:t.commonYear.invoiceYearTruthNum,color:"#89c6f2",headicon:"icon-nian",headiconcolor:"#096dd9",icon:"icon-shujutongji"}})],1),a("div",{staticClass:"d-flex j-sb m-top-2"},[a("use-item",{attrs:{title:"对公当月发票数",count1:t.currentMonth.corporateMonthNum,count2:t.currentMonth.corporateMonthTruthNum,headicon:"icon-yue",headiconcolor:"#d46b08",color:"#ffa547",icon:"icon-24gf-chartScatter"}}),a("use-item",{attrs:{title:"对公当年发票数",count1:t.currentYear.corporateYearNum,count2:t.currentYear.corporateYearTruthNum,color:"#92EAEB",headicon:"icon-nian",headiconcolor:"#531dab",icon:"icon-tongji"}})],1),a("div",{staticClass:"m-top-2 bg-fff flex-1 p2",staticStyle:{"box-shadow":"4px 4px 40px rgba(0, 0, 0, 0.05)"}},[a("h1",{staticClass:"f20 d-flex a-center j-center m-bottom-2"},[t._v("公告!")]),a("div",[a("div",{staticClass:"noticeItem d-flex a-center f18"},[t._v(" "+t._s(t.tips)+" ")])])])]),a("div",{staticClass:"p-left-2",staticStyle:{width:"60%"}},[t._m(1),a("div",{staticClass:"d-flex w100"},[a("div",{staticClass:"useAnalay",staticStyle:{width:"40%"}},[a("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}]},[a("div",{staticClass:"p-top-2",staticStyle:{height:"500px"},attrs:{id:"pieEchart"}})])]),a("div",{staticClass:"flex-3 useAnalay m-left-2",staticStyle:{width:"60%"}},[a("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading1,expression:"loading1"}]},[a("div",{staticClass:"p-top-2",staticStyle:{height:"550px"},attrs:{id:"lineEchart"}})])])])])])])}),[function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"w100 d-flex a-center j-center f20 bg-fff m-bottom-2 h50",staticStyle:{"box-shadow":"4px 4px 40px rgba(0, 0, 0, 0.05)"}},[this._v(" 数据汇总 "),e("i",{staticClass:"iconfont icon-1801xiaoxi f20",staticStyle:{color:"#36a3f7"}})])},function(){var t=this.$createElement,e=this._self._c||t;return e("header",{staticClass:"w100 d-flex a-center j-center f20 bg-fff m-bottom-2 h50",staticStyle:{"box-shadow":"4px 4px 40px rgba(0, 0, 0, 0.05)"}},[this._v(" 使用分析"),e("i",{staticClass:"iconfont icon-qushi f20",staticStyle:{color:"#36a3f7"}})])}],!1,null,"382e5c71",null));e.default=b.exports}}]);