1 line
5.7 KiB
JavaScript
1 line
5.7 KiB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-df888040"],{"10adf":function(t,e,n){"use strict";n.r(e);var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticStyle:{width:"100%",height:"100%"}},[n("el-card",{staticStyle:{width:"100%"},attrs:{shadow:"hover"}},[n("div",{staticStyle:{display:"flex","align-items":"center","justify-content":"space-between"},attrs:{slot:"header"},slot:"header"},[n("span",{staticClass:"echartBox_title",on:{click:t.toRtPage}},[t._v(t._s(t.name)+"(事件)")]),t._v(" "),n("div",[n("a-tooltip",{staticStyle:{cursor:"pointer"},attrs:{placement:"top"}},[n("template",{slot:"title"},[n("span",[t._v("拖移报表")])]),t._v(" "),n("el-button",{staticClass:"drageTag",attrs:{type:"warning",icon:"el-icon-rank",circle:""}})],2),t._v(" "),n("a-tooltip",{staticStyle:{cursor:"pointer"},attrs:{placement:"top"}},[n("template",{slot:"title"},[n("span",[t._v("刷新")])]),t._v(" "),n("el-button",{attrs:{icon:"el-icon-refresh",circle:""},on:{click:t.go}})],2),t._v(" "),n("a-tooltip",{staticStyle:{cursor:"pointer"},attrs:{placement:"top"}},[n("template",{slot:"title"},[n("span",[t._v("下载表数据")])]),t._v(" "),n("el-button",{attrs:{type:"success",icon:"el-icon-download",circle:""},on:{click:t.download}})],2)],1)]),t._v(" "),n("a-spin",{attrs:{tip:"计算中...",spinning:t.spinning}},[n("div",{staticClass:"spin-content"},[t.eventResShow?n("event-result",{ref:t.getRef,attrs:{"empty-text":"暂无结果,请调整查询条件","window-time-format":t.form.windowTimeFormat,"event-res":t.eventRes},on:{changeWindowTime:t.changeWindowTime,go:t.go},model:{value:t.form.date,callback:function(e){t.$set(t.form,"date",e)},expression:"form.date"}}):t._e()],1)])],1)],1)},r=[],a=n("c80c"),o=(n("96cf"),n("3b8d")),s=(n("7f7f"),n("94b0")),c=n("c1df"),u=n.n(c),h={name:"Event",components:{EventResult:function(){return Promise.all([n.e("chunk-2d3eea4a"),n.e("chunk-03f56cea")]).then(n.bind(null,"8a17"))}},props:{name:{type:String,default:""},data:{type:Object,default:{}},id:{type:String,default:""},filterDate:{type:Array,default:[]}},data:function(){return{eventRes:[],spinning:!1,form:JSON.parse(this.data),eventResShow:!0,tocharts:!0,totable:!1}},computed:{getRef:function(){return"eventRes"+this.id}},watch:{filterDate:{immediate:!0,handler:function(){this.filterDate.length>0&&(this.form.date=this.filterDate,Vue.set(this.form,"date",this.filterDate),this.go())}}},beforeMount:function(){0==this.filterDate.length&&(this.form.date=[u()().startOf("day").subtract(1,"days").format("YYYY-MM-DD"),u()().startOf("day").subtract(1,"days").format("YYYY-MM-DD")]),this.init()},methods:{changeWindowTime:function(t){this.form.windowTimeFormat=t,this.go()},download:function(){this.$refs[this.getRef].download(this.name)},init:function(){var t=Object(o["a"])(Object(a["a"])().mark((function t(){return Object(a["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,this.go();case 2:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}(),toRtPage:function(){this.$router.push({path:"/behavior-analysis/event/"+this.id})},changeViewType:function(){var t=this;this.tocharts=!this.tocharts,this.totable=!this.totable,this.eventResShow=!1,this.$nextTick((function(){t.eventResShow=!0}))},go:function(){var t=Object(o["a"])(Object(a["a"])().mark((function t(){var e,n,i,r=this;return Object(a["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:for(n in this.spinning=!0,this.eventResShow=!1,e=JSON.parse(JSON.stringify(this.form)),e.zhibiaoArr)1==e.zhibiaoArr[n].typ?e.zhibiaoArr[n].attrOptions&&delete e.zhibiaoArr[n].attrOptions:2==e.zhibiaoArr[n].typ&&(e.zhibiaoArr[n]["one"].attrOptions&&delete e.zhibiaoArr[n]["one"].attrOptions,e.zhibiaoArr[n]["two"].attrOptions&&delete e.zhibiaoArr[n]["two"].attrOptions);return e["appid"]=this.$store.state.baseData.EsConnectID,t.next=7,Object(s["a"])(e);case 7:if(i=t.sent,0==i.code){t.next=14;break}return this.$message({offset:60,type:"error",message:i.msg}),this.eventRes={},this.spinning=!1,this.$nextTick((function(){r.eventResShow=!0})),t.abrupt("return");case 14:this.eventRes=i.data,this.spinning=!1,this.$nextTick((function(){r.eventResShow=!0}));case 17:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()}},d=h,l=(n("c10f"),n("2877")),f=Object(l["a"])(d,i,r,!1,null,"1952bd7c",null);e["default"]=f.exports},9327:function(t,e,n){},"94b0":function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"e",(function(){return o})),n.d(e,"d",(function(){return s})),n.d(e,"b",(function(){return c})),n.d(e,"f",(function(){return u})),n.d(e,"g",(function(){return h})),n.d(e,"h",(function(){return d})),n.d(e,"a",(function(){return l})),n.d(e,"k",(function(){return f})),n.d(e,"j",(function(){return p})),n.d(e,"i",(function(){return m}));var i=n("b775"),r="/api/analysis/";function a(t){return Object(i["a"])({url:r+"GetConfigs",method:"post",data:t})}function o(t){return Object(i["a"])({url:r+"LoadPropQuotas",method:"post",data:t})}function s(t){return Object(i["a"])({url:r+"GetValues",method:"post",data:t})}function c(t){return Object(i["a"])({url:r+"FunnelList",method:"post",data:t})}function u(t){return Object(i["a"])({url:r+"RetentionList",method:"post",data:t})}function h(t){return Object(i["a"])({url:r+"TraceList",method:"post",data:t})}function d(t){return Object(i["a"])({url:r+"UserAttrList",method:"post",data:t})}function l(t){return Object(i["a"])({url:r+"EventList",method:"post",data:t})}function f(t){return Object(i["a"])({url:r+"UserList",method:"post",data:t})}function p(t){return Object(i["a"])({url:r+"UserEventDetailList",method:"post",data:t})}function m(t){return Object(i["a"])({url:r+"UserEventCountList",method:"post",data:t})}},c10f:function(t,e,n){"use strict";n("9327")}}]); |