企微助手 ,仓库名 短剧

83.36ae136f23aee22a03ea.js 13KB

1
  1. webpackJsonp([83],{"3opI":function(e,t){},RSzr:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=r("Xxa5"),n=r.n(a),i=r("exGp"),o=r.n(i),s=r("gzej"),p=r("erru"),l=r("McOJ"),c=r("FsX6"),d=r("1zIV"),u=r("KnvP"),f=r("la//"),h={name:"orderData",components:{datePicker:s.a,selfChannel:p.a,selfInput:l.a,selfChannelV2:c.a,selfChannelMultiple:d.a,inputRange:u.a},data:function(){return{dataLoading:!1,loading:!1,summaryLoading:!1,page:1,pages:0,total:0,page_size:20,default_time:[this.$getDay(0,!1),this.$getDay(0,!1)],height:"",resetFlag:!1,dataInfo_stat:{},trendX:[],trendData:{key:1,dds:[],zfje:[]},desCol:[{prop:"id",label:"订单编号",fixed:"left"},{prop:"order_id",label:"订单ID",min_width:180},{prop:"payment_amount",label:"实际支付金额"},{prop:"predict_commission_fee",label:"预估佣金"},{prop:"payed_time",label:"支付时间",min_width:160},{prop:"predict_report_time",label:"预估回传时间",min_width:160},{prop:"order_status_desc",label:"订单状态"},{prop:"account_id",label:"投放账户"},{prop:"tx_cps_id",label:"自定义参数"},{prop:"ad_report_action_type",label:"回传类型"},{prop:"ad_report_order_status",label:"回传状态"},{prop:"adgroup_name",label:"回传广告名称"},{prop:"actionBtn",label:"操作",fixed:"right"}],summaryTableCol:[{prop:"adgroup_name",label:"广告"},{prop:"cost",label:"花费"},{prop:"predict_commission_fee",label:"预估收入"},{prop:"actual_roi",label:"实际roi"},{prop:"bid_amount",label:"出价"},{prop:"conversions_cost",label:"目标转化成本"},{prop:"click_count",label:"点击数"}],filter:{time:[],order_id:"",order_status:"",account_id:[],money:[],cps_id:"",report_status:[]}}},computed:{isCanExport:function(){return!!this.$store.state.dataBoardAuth.can_export}},created:function(){this.height=document.documentElement.clientHeight-280>400?document.documentElement.clientHeight-280:400,this.filter.time=this.default_time,this.init(1),this.handleGetSummaryList()},methods:{getIncomeSourceDesc:function(e){return(e||0===e)&&f.p[e]||"-"},getLaunchTypeDesc:function(e){return(e||0===e)&&f.u[e]||"-"},headerColor:function(e){e.row,e.column,e.rowIndex,e.columnIndex;return{backgroundColor:"#FFFFFF !important",border:"none!important"}},initCharts:function(){this.$echarts.init(this.$refs.chart).setOption({xAxis:{show:!1,boundaryGap:!1,data:this.trendX},yAxis:{show:!1},grid:{top:0,left:0,right:0,bottom:"1%"},series:[{name:"订单数",type:"line",data:this.trendData.dds,color:"#00B38A"},{name:"支付金额",type:"line",data:this.trendData.zfje,color:"#FF8704"}]})},init_predata:function(){var e=this;return o()(n.a.mark(function t(){var r,a,i,o,s;return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.URL.BASEURL+e.URL.charge_pre_data,a={start_date:e.filter.time[0],end_date:e.filter.time[1],account_id:e.filter.account_id.join(",")},t.prev=2,e.dataLoading=!0,t.next=6,e.$axios.post(r,a);case 6:i=t.sent,o=i.data,(s=void 0===o?{}:o)&&0==s.errno?(e.dataInfo_stat=s.rst.data.stat,e.trendX=[],e.trendData.dds=[],e.trendData.zfje=[],s.rst.data.trend.forEach(function(t){e.trendX.push(t.ref_date),e.trendData.dds.push(t.order_count),e.trendData.zfje.push(t.pay_money)}),e.trendData.key+=1):4002!=s.errno&&e.$message({message:s.err,type:"warning"}),t.next=15;break;case 12:t.prev=12,t.t0=t.catch(2),console.log("error => ",t.t0);case 15:return t.prev=15,e.dataLoading=!1,t.finish(15);case 18:case"end":return t.stop()}},t,e,[[2,12,15,18]])}))()},init:function(e,t){var r=this;return o()(n.a.mark(function t(){var a,i,o,s,p;return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r.page=e||r.page,r.loading=!0,a=""+r.URL.BASEURL+r.URL.dataBoard_orderData_yxOrderList,i={order_id:r.filter.order_id,start_date:r.filter.time[0],end_date:r.filter.time[1],account_id:r.filter.account_id.join(","),tx_cps_id:r.filter.cps_id,sys_group_id:1==r.$cookie.getCookie("isSuperManage")?sessionStorage.getItem("company_session_defaultCorp_level_1").toString():"",page:r.page,page_size:r.page_size},t.prev=4,t.next=7,r.$axios.get(a,{params:i});case 7:o=t.sent,s=o.data,(p=void 0===s?{}:s)&&0==p.errno?(r.datas=p.rst.data,r.$refs.plxTable.reloadData(r.datas),r.total=p.rst.pageInfo.total,r.pages=p.rst.pageInfo.pages):4002!=p.errno&&r.$message.warning(p.err),t.next=16;break;case 13:t.prev=13,t.t0=t.catch(4),console.log("error => ",t.t0);case 16:return t.prev=16,r.loading=!1,t.finish(16);case 19:case"end":return t.stop()}},t,r,[[4,13,16,19]])}))()},onChangeOrderStatus:function(e){this.filter.order_status=e,this.init(1)},onChangeTime:function(e){!e||e&&0==e.length?this.filter.time=[]:this.filter.time=e,this.init(1)},onInputOrderId:function(e){this.filter.order_id=e,this.init(1)},onChangeOrderId:function(e){this.filter.order_id=e},onInputCpsId:function(e){this.filter.cps_id=e,this.init(1),this.handleGetSummaryList()},onChangeCpsId:function(e){this.filter.cps_id=e},onChangeAccountId:function(e){this.filter.account_id=e,this.init(1),this.handleGetSummaryList()},onChangeReportStatus:function(e){this.filter.report_status=e,this.init(1)},handleCurrentChange:function(e){this.init(e)},handleSizeChange:function(e){this.page_size=e,this.init(1)},resetEvent:function(){this.resetFlag=!this.resetFlag,this.filter.time=[this.$getDay(-30,!1),this.$getDay(0,!1)],this.filter.order_id="",this.filter.account_id=[],this.filter.money=[],this.filter.order_status="",this.filter.report_status=[],this.init(1),this.handleGetSummaryList()},flushData:function(){var e=this;return o()(n.a.mark(function t(){return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:e.init(),e.handleGetSummaryList();case 2:case"end":return t.stop()}},t,e)}))()},onClickReport:function(e){var t=this;return o()(n.a.mark(function r(){return n.a.wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,t.$confirm("订单ID【"+e.order_id+"】,确定补单吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"});case 3:t.handleReport(e),r.next=9;break;case 6:r.prev=6,r.t0=r.catch(0),console.log(r.t0);case 9:case"end":return r.stop()}},r,t,[[0,6]])}))()},handleReport:function(e){var t=this,r=e.order_id,a=e.id;return o()(n.a.mark(function e(){var i,o,s,p,l;return n.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t.loading=!0,i=""+t.URL.BASEURL+t.URL.dataBoard_orderData_yxOrderActionReport,o={order_id:r,order_data_id:a},e.next=6,t.$axios.get(i,{params:o});case 6:s=e.sent,p=s.data,(l=void 0===p?{}:p)&&0==l.errno?(t.$message.success("操作成功"),t.init()):4002!=l.errno&&t.$message.warning(l.err||"操作失败"),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(0),console.log(e.t0);case 15:return e.prev=15,t.loading=!1,e.finish(15);case 18:case"end":return e.stop()}},e,t,[[0,12,15,18]])}))()},handleGetSummaryList:function(){var e=this;return o()(n.a.mark(function t(){var r,a,i,o,s,p;return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,e.summaryLoading=!0,r={start_date:e.filter.time[0],end_date:e.filter.time[1],account_id:e.filter.account_id.join(","),tx_cps_id:e.filter.cps_id,sys_group_id:1==e.$cookie.getCookie("isSuperManage")?sessionStorage.getItem("company_session_defaultCorp_level_1").toString():""},a=""+e.URL.BASEURL+e.URL.dataBoard_orderData_adgroupStatList,t.next=6,e.$axios.get(a,{params:r});case 6:if(i=t.sent,o=i.data,!(s=void 0===o?{}:o)||0!=s.errno){t.next=16;break}return t.next=12,e.$nextTick();case 12:p=s.rst,e.$refs.summaryTable.reloadData(p),t.next=17;break;case 16:4002!=s.errno&&(e.$message.warning(s.err),e.$refs.summaryTable.reloadData([]));case 17:t.next=23;break;case 19:t.prev=19,t.t0=t.catch(0),console.log(t.t0),e.$refs.summaryTable.reloadData([]);case 23:return t.prev=23,e.summaryLoading=!1,t.finish(23);case 26:case"end":return t.stop()}},t,e,[[0,19,23,26]])}))()},onClickExport:function(){var e=this;return o()(n.a.mark(function t(){return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,e.$confirm("确定根据当前筛选条件导出报表吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"});case 3:e.handleCreateOrderExport(),t.next=9;break;case 6:t.prev=6,t.t0=t.catch(0),console.log("error => ",t.t0);case 9:case"end":return t.stop()}},t,e,[[0,6]])}))()},handleCreateOrderExport:function(){var e=this;return o()(n.a.mark(function t(){var r,a,i,o,s;return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,e.loading=!0,r=""+e.URL.BASEURL+e.URL.dataBoard_orderData_orderExportOffline,a={sys_group_id:1==e.$cookie.getCookie("isSuperManage")?sessionStorage.getItem("company_session_defaultCorp_level_1").toString():"",start_date:e.filter.time[0],end_date:e.filter.time[1],order_id:e.filter.order_id,account_id:e.filter.account_id.join(",")},t.next=6,e.$axios.get(r,{params:a});case 6:i=t.sent,o=i.data,(s=void 0===o?{}:o)&&0==s.errno?e.$alert("导出预约成功,请稍候到【导出列表】下载文件!","提示",{confirmButtonText:"知道了",type:"success"}):4002!=s.errno&&e.$message.warning(s.err||"操作失败"),t.next=15;break;case 12:t.prev=12,t.t0=t.catch(0),console.log(t.t0);case 15:return t.prev=15,e.loading=!1,t.finish(15);case 18:case"end":return t.stop()}},t,e,[[0,12,15,18]])}))()}}},_={render:function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",[r("div",{staticClass:"screenBox"},[r("div",{staticClass:"flex-align-center",staticStyle:{"flex-wrap":"wrap","margin-right":"60px"}},[r("datePicker",{staticStyle:{"margin-right":"10px"},attrs:{title:"",quickFlag:!0,afferent_time:e.default_time,clearFlag:!1,reset:e.resetFlag},on:{changeTime:e.onChangeTime}}),e._v(" "),r("selfInput",{staticStyle:{"margin-right":"10px"},attrs:{width:"220px",hasLabel:!1,reset:e.resetFlag,label_name:"订单ID"},on:{inputChange:e.onInputOrderId,onChange:e.onChangeOrderId}}),e._v(" "),r("selfChannelMultiple",{staticStyle:{"margin-right":"10px"},attrs:{title:"",type:"adqAccount",reset:e.resetFlag,labelWidth:!0},on:{channelDefine:e.onChangeAccountId}}),e._v(" "),r("selfInput",{staticStyle:{"margin-right":"10px"},attrs:{width:"220px",hasLabel:!1,reset:e.resetFlag,label_name:"自定义参数"},on:{inputChange:e.onInputCpsId,onChange:e.onChangeCpsId}})],1),e._v(" "),r("div",{staticClass:"reset",on:{click:e.resetEvent}},[e._v("重置")])]),e._v(" "),r("div",{directives:[{name:"loading",rawName:"v-loading",value:e.summaryLoading,expression:"summaryLoading"}],staticStyle:{"margin-top":"10px"}},[r("ux-grid",{ref:"summaryTable",staticClass:"uxGridBox",attrs:{border:!1,"header-cell-style":e.headerColor,"max-height":e.height,"show-footer-overflow":"tooltip","show-overflow":"tooltip",size:"mini"},on:{"row-click":function(){}}},e._l(e.summaryTableCol,function(t,a){return r("ux-table-column",{key:t.prop,attrs:{resizable:!0,field:t.prop,title:t.label,"min-width":t.min_width?t.min_width:120,fixed:t.fixed?t.fixed:"",align:"center"},scopedSlots:e._u([{key:"header",fn:function(){return[r("div",{staticClass:"flex-align-jus-center"},[e._v(e._s(t.label)+"\n "),t.notes?r("el-tooltip",{attrs:{content:t.notes,placement:"top"}},[r("div",[r("i",{staticClass:"el-icon-question"})])]):e._e()],1)]},proxy:!0},{key:"default",fn:function(a){var n=a.row;return[r("span",[e._v(e._s(n[t.prop]||0==n[t.prop]?e.$formatNum(n[t.prop]):"-"))])]}}],null,!0)})}),1)],1),e._v(" "),r("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],staticStyle:{"margin-top":"10px"}},[r("ux-grid",{ref:"plxTable",staticClass:"uxGridBox",attrs:{border:!1,"header-cell-style":e.headerColor,height:e.height,"show-footer-overflow":"tooltip","show-overflow":"tooltip",size:"mini"},on:{"row-click":function(){}}},e._l(e.desCol,function(t){return r("ux-table-column",{key:t.prop,attrs:{resizable:!0,field:t.prop,title:t.label,"min-width":t.min_width?t.min_width:120,fixed:t.fixed?t.fixed:"",align:"center"},scopedSlots:e._u([{key:"header",fn:function(){return[r("div",{staticClass:"flex-align-jus-center"},[e._v(e._s(t.label)+"\n "),t.notes?r("el-tooltip",{attrs:{content:t.notes,placement:"top"}},[r("div",[r("i",{staticClass:"el-icon-question"})])]):e._e()],1)]},proxy:!0},{key:"default",fn:function(a){var n=a.row;return a.$index,["actionBtn"==t.prop?r("div",[["成功"==n.ad_report_order_status&&0==n.supplement_status?r("span",{staticClass:"c-A5A5A5 pointer fWeight600 disabled"},[e._v("已回传")]):"成功"==n.ad_report_order_status&&1==n.supplement_status?r("span",{staticClass:"c-A5A5A5 pointer fWeight600 disabled"},[e._v("已补单")]):4!=n.order_status&&n.predict_commission_fee>0?r("span",{staticClass:"c-00B38A pointer fWeight600",on:{click:function(t){return e.onClickReport(n)}}},[e._v("补单")]):e._e()]],2):"order_id"==t.prop?r("span",[e._v("\n "+e._s(n[t.prop]||0==n[t.prop]?n[t.prop]:"-")+"\n ")]):"account_id"==t.prop?r("span",[e._v("\n "+e._s(n[t.prop]||0==n[t.prop]?n[t.prop]:"-")+"\n ")]):"payment_amount"==t.prop?r("span",[e._v("\n "+e._s(n[t.prop]||0==n[t.prop]?n[t.prop]:0)+"\n ")]):"predict_commission_fee"==t.prop?r("span",[e._v("\n "+e._s(n[t.prop]||0==n[t.prop]?n[t.prop]:0)+"\n ")]):r("span",[e._v(e._s(!n[t.prop]&&0!=n[t.prop]||""==n[t.prop]?"-":e.$formatNum(n[t.prop])))])]}}],null,!0)})}),1),e._v(" "),r("div",{directives:[{name:"show",rawName:"v-show",value:e.total>0,expression:"total > 0"}],staticClass:"pagination"},[r("el-pagination",{attrs:{background:"","current-page":e.page,layout:"prev, pager, next, sizes, jumper","page-sizes":[20,50,100],"page-count":Number(e.pages)},on:{"current-change":e.handleCurrentChange,"size-change":e.handleSizeChange}})],1)],1)])},staticRenderFns:[]};var g=r("VU/8")(h,_,!1,function(e){r("3opI")},"data-v-891f48a8",null);t.default=g.exports}});