chunk-4e5203d0.1dacc6e6.js 4.5 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-4e5203d0"],{"0d15":function(t,e,a){"use strict";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("div",{directives:[{name:"loading",rawName:"v-loading.fullscreen.lock",value:t.loadingFull,expression:"loadingFull",modifiers:{fullscreen:!0,lock:!0}}]}),t._v(" "),a("div",{staticStyle:{"margin-bottom":"20px"}},[a("el-date-picker",{attrs:{type:"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期","value-format":"yyyy-MM-dd HH:mm:ss",clearable:!1},model:{value:t.rangeTime,callback:function(e){t.rangeTime=e},expression:"rangeTime"}}),t._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:t.search}},[t._v("\n 查询\n ")])],1),t._v(" "),a("div",{staticClass:"title"},[t._v("库存出入库统计")]),t._v(" "),a("div",{ref:"style_num_echart",style:{height:t.height,width:t.width}})])},r=[],i=(a("96cf"),a("1da1")),s=(a("ac6a"),a("28a5"),a("a481"),a("313e")),o=a.n(s),c=a("2cc9"),l={props:{width:{type:String,default:"600px"},height:{type:String,default:"600px"}},data:function(){return{chart:null,timeLineMap:[],dataMap:{},lengedMap:["出库","入库"],cycle:"3",dateYf:[],dataYs:[],rangeTime:"",startTime:"",endTime:"",chukuList:"",rukuList:"",proTime:"",search_content:"",time:"",loadingFull:!1}},created:function(){console.log("999999");var t=new Date,e=t.toLocaleDateString(),a=e.replace(/\//g,"-"),n=t.toLocaleTimeString(),r=n.split("午"),i=r[1],s=a+" "+i;this.time=s,this.startTime=s,this.endTime=s,this.rangeTime=s+"至"+s,console.log(this.startTime,"this.startTime"),this.stockeStatistical()},beforeDestroy:function(){this.chart&&(this.chart.dispose(),this.chart=null)},methods:{search:function(){this.startTime=this.rangeTime[0],this.endTime=this.rangeTime[1],console.log(this.startTime,"rangeTime"),console.log(this.endTime,"rangeTime"),this.stockeStatistical()},createObjectByArray:function(t,e){var a={};return t.forEach((function(t){a[t]=e?[]:{}})),a},stockeStatistical:function(){var t=Object(i["a"])(regeneratorRuntime.mark((function t(){var e,a=this;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:this.loadingFull=!0,e={start_time:this.startTime,end_time:this.endTime},Object(c["f"])(e).then((function(t){if(console.log(t,"res,data"),a.statisticalList=t.data,200===t.code){for(var e=[],n=[],r=[],i=0,s=t.data.length;i<s;i++)e.push(t.data[i].date),n.push(t.data[i].out_num),r.push(t.data[i].put_num);a.dateYf=n,a.dateYs=r,a.timeLineMap=e,console.log(a.timeLineMap,"xAxis"),a.initChart()}else alert(t.message);a.loadingFull=!1})).catch((function(t){console.log(t,"error"),a.loadingFull=!1}));case 3:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}(),getOrderAccount:function(){var t=Object(i["a"])(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:case"end":return t.stop()}}),t)})));function e(){return t.apply(this,arguments)}return e}(),initChart:function(){var t=this;this.$nextTick((function(){t.chart=o.a.init(t.$refs.style_num_echart),t.chart.clear(),t.chart.setOption({title:{},tooltip:{trigger:"axis"},legend:{data:t.lengedMap},xAxis:{type:"category",data:t.timeLineMap},yAxis:{type:"value"},dataZoom:[{type:"slider"},{type:"inside"}],color:["#63b2ee","#f19272 ","#76da91"],series:[{name:"出库",type:"line",data:t.dateYf},{name:"入库",type:"line",data:t.dateYs}]}),window.onresize=t.chart.resize}))}}},u=l,d=(a("b6df"),a("2877")),h=Object(d["a"])(u,n,r,!1,null,"42956f57",null);e["default"]=h.exports},"2cc9":function(t,e,a){"use strict";a.d(e,"e",(function(){return r})),a.d(e,"d",(function(){return i})),a.d(e,"b",(function(){return s})),a.d(e,"c",(function(){return o})),a.d(e,"a",(function(){return c})),a.d(e,"f",(function(){return l}));var n=a("b775");function r(t){return Object(n["a"])({url:"/storage/GetStorageDetailDate",method:"Get",params:t})}function i(t){return Object(n["a"])({url:"/storage/GetUserStorageDateDetail",method:"Get",params:t})}function s(t){return Object(n["a"])({url:"/storage/StorageOutStatistical",method:"Get",params:t})}function o(t){return Object(n["a"])({url:"/storage/StoragePutStatistical",method:"Get",params:t})}function c(t){return Object(n["a"])({url:"/storage/ExportOutPutRecord",method:"Get",params:t})}function l(t){return Object(n["a"])({url:"/storage/StorageStatistical",method:"Get",params:t})}},b6df:function(t,e,a){"use strict";var n=a("d0d7"),r=a.n(n);r.a},d0d7:function(t,e,a){}}]);