chunk-98923b8a.c3a29171.js 5.0 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-98923b8a"],{9340:function(e,t,a){},"9e56":function(e,t,a){"use strict";a.r(t);var i=function(){var e=this,t=e._self._c;return t("div",{staticClass:"app-list-content"},[t("x-crud",{staticClass:"liu-crud-wrap",on:{load:e.onLoad},scopedSlots:e._u([{key:"slot-tabs",fn:function(){return[t("el-tabs",{staticClass:"liu-tabs",attrs:{type:"border-card"},model:{value:e.tabIndex,callback:function(t){e.tabIndex=t},expression:"tabIndex"}},e._l(e.tabsData,(function(e,a){return t("el-tab-pane",{key:a,attrs:{label:""+e.text,name:e.key}})})),1)]},proxy:!0},{key:"table-column-amount",fn:function({scope:a}){return[t("span",[e._v(" "+e._s(1==a.row.io?"+":"-")+" "+e._s(a.row.amount)+" ")])]}},{key:"table-column-payTime",fn:function({scope:a}){return["0000-00-00 00:00:00"!=a.row.payTime&&a.row.payTime.substr(5,5)!=a.row.addTime.substr(5,5)?t("span",[e._v(" "+e._s(a.row.payTime)+" ")]):t("span",[e._v("-")])]}},{key:"table-column-capitalType",fn:function({scope:a}){return[20==a.row.capitalType?t("span",[e._v("结账")]):10==a.row.capitalType?t("span",[e._v("下单")]):40==a.row.capitalType?t("span",[e._v("售后")]):t("span",[e._v("其它")])]}},{key:"slot-search-list",fn:function({scope:a}){return[t("el-select",{staticStyle:{width:"200px","margin-right":"10px"},attrs:{filterable:"",remote:"","reserve-keyword":"",placeholder:"搜索客户",clearable:"","remote-method":e.searchCpInfo,loading:e.loading,size:"middle"},on:{change:e.getCurrentCp},model:{value:e.currentCustomName,callback:function(t){e.currentCustomName=t},expression:"currentCustomName"}},e._l(e.customInfoList,(function(e){return t("el-option",{key:e.id,attrs:{label:`${e.name}(${e.id})`,value:e.id}})})),1),t("span",{staticStyle:{"margin-left":"9px","font-size":"28px"}},[e._v("时间:")]),t("el-date-picker",{staticClass:"custom-date-picker",staticStyle:{"margin-right":"8px"},attrs:{type:"daterange",align:"right","unlink-panels":"","range-separator":"至","start-placeholder":"开始日期","value-format":"yyyy-MM-dd","end-placeholder":"结束日期","picker-options":e.pickerOptions,size:"middle"},on:{change:e.getSearchDate},model:{value:e.currentDateList,callback:function(t){e.currentDateList=t},expression:"currentDateList"}}),t("el-button",{staticStyle:{"margin-left":"10px"},attrs:{type:"primary",size:"middle"},on:{click:function(t){return e.exportData()}}},[e._v("导出数据")])]}}])})],1)},s=[],n=(a("5880"),{components:{},data(){return{app:null,tabIndex:"0",tabsData:[{text:"列表",key:"0",val:0}],customInfoList:[],loading:!1,currentCustomName:"",customId:0,pickerOptions:{shortcuts:[{text:"最近一周",onClick(e){const t=new Date,a=new Date;a.setTime(a.getTime()-6048e5),e.$emit("pick",[a,t])}},{text:"最近一个月",onClick(e){const t=new Date,a=new Date;a.setTime(a.getTime()-2592e6),e.$emit("pick",[a,t])}},{text:"最近三个月",onClick(e){const t=new Date,a=new Date;a.setTime(a.getTime()-7776e6),e.$emit("pick",[a,t])}}]},startTime:"",endTime:"",searchTime:"",currentDateList:[]}},methods:{onLoad({ctx:e,app:t}){this.app=t,this.$route.query.customId&&(this.customId=this.$route.query.customId,this.currentCustomName=this.$route.query.customName?this.$route.query.customName:""),e.service(this.$service.customDebtChange).set("table",{columns:[{prop:"id",label:"ID",align:"center",width:100},{prop:"addTime",label:"创建日期",align:"center",width:180},{prop:"payTime",label:"账单日期",align:"center",width:180},{prop:"customId",label:"客户ID",align:"center",width:100},{prop:"customName",label:"客户名称",align:"center",width:150},{prop:"capitalType",label:"类型",align:"center",width:120},{prop:"event",label:"事项",align:"center",width:260},{prop:"amount",label:"变动",align:"center",width:120},{prop:"balance",label:"剩余欠款",align:"center",width:120},{prop:"remark",label:"备注",align:"center",width:210}],op:{visible:!0,props:{width:100,align:"center",fixed:"right",label:"操作"},layout:["slot-column-option"]}}).set("dict",{search:{keyWord:"name"}}).set("search",{key:{placeholder:"..."}}).set("layout",[["slot-tabs"],["slot-search-list"],["data-table"],["flex1","pagination"]]).done(),this.refreshData()},getCurrentCp(e){this.customId=e,this.refreshData()},refreshData(){this.app.refresh({searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,customId:this.customId})},exportData(){this.$service.customDebtChange.getList({searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,customId:this.customId,pageSize:9999999,export:1}).then(e=>{e.file&&(window.location.href=e.file)})},searchCpInfo(e){let t=this;""!==e?(this.loading=!0,this.$service.custom.list({name:e,type:0}).then(e=>{t.loading=!1,t.customInfoList=e.list})):this.customInfoList=[]},getSearchDate(){this.$util.isEmpty(this.currentDateList)?(this.searchTime="",this.startTime="",this.endTime=""):(this.searchTime="custom",this.startTime=this.currentDateList[0],this.endTime=this.currentDateList[1]),this.refreshData()}}}),r=n,o=(a("e05a"),a("1805")),c=Object(o["a"])(r,i,s,!1,null,"2b879823",null);t["default"]=c.exports},e05a:function(e,t,a){"use strict";a("9340")}}]);