zx/public/mer/js/chunk-87811302.cf4b9929.js

1 line
16 KiB
JavaScript

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-87811302"],{"01ba":function(t,e,n){},"0b65":function(t,e,n){"use strict";e["a"]={shortcuts:[{text:"今天",onClick:function(t){var e=new Date,n=new Date;n.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate())),t.$emit("pick",[n,e])}},{text:"昨天",onClick:function(t){var e=new Date,n=new Date;n.setTime(n.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-1))),e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-1))),t.$emit("pick",[n,e])}},{text:"最近7天",onClick:function(t){var e=new Date,n=new Date;n.setTime(n.getTime()-6048e5),t.$emit("pick",[n,e])}},{text:"最近30天",onClick:function(t){var e=new Date,n=new Date;n.setTime(n.getTime()-2592e6),t.$emit("pick",[n,e])}},{text:"本月",onClick:function(t){var e=new Date,n=new Date;n.setTime(n.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),1))),t.$emit("pick",[n,e])}},{text:"本年",onClick:function(t){var e=new Date,n=new Date;n.setTime(n.setTime(new Date((new Date).getFullYear(),0,1))),t.$emit("pick",[n,e])}}]}},"2e83":function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));n("28a5");var r=n("8122"),o=n("e8ae"),a=n.n(o),i=n("21a6");function l(t,e,n,o,l,c){var u,s=["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"],d=1,m=new a.a.Workbook,g=t.length;function p(t){var e=Array.isArray(t)?t[0]:t,n=Array.isArray(t)?t[1]:{};u=m.addWorksheet(e,n)}function h(t,e){if(!Object(r["isEmpty"])(t)){t=Array.isArray(t)?t:t.split(",");for(var n=0;n<t.length;n++){var o=u.getRow(n+1);o.getCell(1).value=t[n],o.height=30,o.font={bold:!0,size:20,vertAlign:"subscript"},o.alignment={vertical:"bottom",horizontal:"center"},o.outlineLevel=1,u.mergeCells(n+1,1,n+1,e),o.commit(),d++}}}function v(t){if(!Object(r["isEmpty"])(t)){for(var e=u.getRow(d),n=1;n<=t.length;n++)e.getCell(n).value=t[n-1];e.height=25,e.width=50,e.font={bold:!0,size:18,vertAlign:"subscript"},e.alignment={vertical:"bottom",horizontal:"center"},e.outlineLevel=1,e.commit(),d++}}function b(t){if(!Object(r["isEmpty"])(t))for(var e=0;e<t.length;e++){for(var n=d,o=u.getRow(d),a=!1,i=0,l=0,c=0,s=0;s<t[e].length;s++)Array.isArray(t[e][s])?(i=c,a=!0,y(t[e][s],c),c+=t[e][s][0].length,l=c):(o.getCell(x(c)).value=t[e][s],o.getCell(x(c)).border={top:{style:"thin"},left:{style:"thin"},bottom:{style:"thin"},right:{style:"thin"}},o.alignment={vertical:"middle",horizontal:"center"},c++);a&&w(n,d,i,l),o.height=25,o.commit(),d++}}function y(t,e){for(var n=t.length,r=n-1,o=0;o<t.length;o++){for(var a=u.getRow(d),i=0;i<t[o].length;i++)a.getCell(x(e+i)).value=t[o][i],a.getCell(x(e+i)).border={top:{style:"thin"},left:{style:"thin"},bottom:{style:"thin"},right:{style:"thin"}},a.alignment={vertical:"middle",horizontal:"center"};a.height=25,a.commit(),o<r&&d++}}function w(t,e,n,r){for(var o=0;o<g;o++)(o<n||o>=r)&&u.mergeCells(x(o)+t+":"+x(o)+e)}function _(t){if(!Object(r["isEmpty"])(t))if(Array.isArray(t))for(var e=0;e<t.length;e++){var n=u.getRow(d);n.getCell(1).value=t[e],n.getCell(1).border={top:{style:"thin"},left:{style:"thin"},bottom:{style:"thin"},right:{style:"thin"}},n.alignment={vertical:"middle",horizontal:"left"},u.mergeCells("A"+d+":"+x(g-1)+d),d++}else{var o=u.getRow(d);o.getCell(1).value=t[f],o.getCell(1).border={top:{style:"thin"},left:{style:"thin"},bottom:{style:"thin"},right:{style:"thin"}},o.alignment={vertical:"middle",horizontal:"left"},u.mergeCells("A"+d+":"+x(g-1)+d)}}function x(t){if(t<26)return s[t];var e=t%26,n=Math.floor(t%26);return s[n]+s[e]}function k(t){t||(t=(new Date).getTime()),m.xlsx.writeBuffer().then((function(e){var n=new Blob([e],{type:"application/octet-stream"});i["saveAs"](n,t+".xlsx")}))}p(c),h(e,g),v(t),b(n),_(o),k(l)}},"5b8c":function(t,e,n){"use strict";n("01ba")},"831a":function(t,e,n){"use strict";n.r(e);var r=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"divBox"},[n("div",{staticClass:"selCard"},[n("el-form",{ref:"searchForm",attrs:{model:t.tableFrom,size:"small",inline:"","label-width":"85px"}},[n("el-form-item",{attrs:{label:"创建时间:"}},[n("el-date-picker",{staticStyle:{width:"280px"},attrs:{"value-format":"yyyy/MM/dd",format:"yyyy/MM/dd",size:"small",type:"daterange",placement:"bottom-end",placeholder:"自定义时间",clearable:"","picker-options":t.pickerOptions},on:{change:t.onchangeTime},model:{value:t.timeVal,callback:function(e){t.timeVal=e},expression:"timeVal"}})],1),t._v(" "),n("el-form-item",{attrs:{label:"分账时间:"}},[n("el-date-picker",{staticStyle:{width:"280px"},attrs:{"value-format":"yyyy/MM/dd",format:"yyyy/MM/dd",size:"small",type:"daterange",placement:"bottom-end",placeholder:"自定义时间",clearable:"","picker-options":t.pickerOptions},on:{change:t.onchangeTime2},model:{value:t.timeVal2,callback:function(e){t.timeVal2=e},expression:"timeVal2"}})],1),t._v(" "),n("el-form-item",{attrs:{label:"分账状态:",prop:"status"}},[n("el-select",{staticClass:"selWidth",attrs:{placeholder:"请选择",size:"small",clearable:""},on:{change:function(e){return t.getList(1)}},model:{value:t.tableFrom.status,callback:function(e){t.$set(t.tableFrom,"status",e)},expression:"tableFrom.status"}},t._l(t.applyStatus,(function(t){return n("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1)],1),t._v(" "),n("el-form-item",{attrs:{label:"账单类型:",prop:"type"}},[n("el-select",{staticClass:"selWidth",attrs:{placeholder:"请选择",size:"small",clearable:""},on:{change:function(e){return t.getList(1)}},model:{value:t.tableFrom.type,callback:function(e){t.$set(t.tableFrom,"type",e)},expression:"tableFrom.type"}},[n("el-option",{attrs:{label:"订单支付",value:"order"}}),t._v(" "),n("el-option",{attrs:{label:"尾款支付",value:"presell"}})],1)],1),t._v(" "),n("el-form-item",[n("el-button",{attrs:{type:"primary",size:"small"},on:{click:function(e){return t.getList(1)}}},[t._v("搜索")]),t._v(" "),n("el-button",{attrs:{size:"small"},on:{click:function(e){return t.searchReset()}}},[t._v("重置")])],1)],1)],1),t._v(" "),n("el-card",{staticClass:"mt14"},[n("el-button",{staticClass:"mb20",attrs:{size:"small",type:"primary"},on:{click:t.exports}},[t._v("列表导出")]),t._v(" "),n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.tableData.data,size:"small"}},[n("el-table-column",{attrs:{prop:"profitsharing_id",label:"分账ID","min-width":"50"}}),t._v(" "),n("el-table-column",{attrs:{prop:"order.order_sn",label:"订单编号","min-width":"60"}}),t._v(" "),n("el-table-column",{attrs:{label:"分账金额","min-width":"100"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("div",[t._v("订单金额: "+t._s(e.row.profitsharing_price))]),t._v(" "),e.row.profitsharing_refund>0?n("div",{staticStyle:{color:"#82e493"}},[t._v("退款金额: "+t._s(e.row.profitsharing_refund))]):t._e(),t._v(" "),n("div",[t._v("分账给商户金额: "+t._s(e.row.profitsharing_mer_price))])]}}])}),t._v(" "),n("el-table-column",{attrs:{label:"账单类型","min-width":"80"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("span",[t._v(t._s("order"==e.row.type?"订单支付":"尾款支付"))])]}}])}),t._v(" "),n("el-table-column",{attrs:{label:"状态","min-width":"100"},scopedSlots:t._u([{key:"default",fn:function(e){return[0==e.row.status?n("div",[t._v("未分账")]):1==e.row.status?n("div",[t._v("已分账"),n("br"),t._v("分账时间: "+t._s(e.row.profitsharing_time))]):-1==e.row.status?n("div",[t._v("已退款")]):-2==e.row.status?n("div",[t._v("分账失败"),n("br"),t._v(" "),n("span",{staticStyle:{color:"red","font-size":"12px"}},[t._v(" 失败原因: "+t._s(e.row.error_msg))])]):t._e()]}}])}),t._v(" "),n("el-table-column",{attrs:{prop:"create_time",label:"创建时间","min-width":"100"}})],1),t._v(" "),n("div",{staticClass:"block"},[n("el-pagination",{attrs:{background:"","page-size":t.tableFrom.limit,"current-page":t.tableFrom.page,layout:"total, prev, pager, next, jumper",total:t.tableData.total},on:{"size-change":t.handleSizeChange,"current-change":t.pageChange}})],1)],1),t._v(" "),n("file-list",{ref:"exportList"})],1)},o=[],a=n("c80c"),i=(n("96cf"),n("3b8d")),l=n("8593"),c=n("2e83"),u=n("30dc"),s=n("0b65"),f={components:{fileList:u["a"]},data:function(){return{pickerOptions:s["a"],tableData:{data:[],total:0},listLoading:!0,tableFrom:{type:"",keyword:"",status:"",date:"",profit_date:"",page:1,limit:20},timeVal:[],timeVal2:[],fromList:{title:"选择时间",custom:!0,fromTxt:[{text:"全部",val:""},{text:"今天",val:"today"},{text:"昨天",val:"yesterday"},{text:"最近7天",val:"lately7"},{text:"最近30天",val:"lately30"},{text:"本月",val:"month"},{text:"本年",val:"year"}]},selectionList:[],ids:"",LogLoading:!1,applyStatus:[{value:0,label:"待分账"},{value:1,label:"已分账"},{value:-1,label:"已退款"},{value:-2,label:"分账失败"}],orderDatalist:null}},mounted:function(){this.getList(1)},methods:{searchReset:function(){this.timeVal=[],this.timeVal2=[],this.tableFrom.date="",this.tableFrom.profit_date="",this.$refs.searchForm.resetFields(),this.getList(1)},selectChange:function(t){this.tableFrom.date=t,this.timeVal=[],this.getList(1)},selectChange2:function(t){this.tableFrom.profit_date=t,this.timeVal2=[],this.getList(1)},onchangeTime:function(t){this.timeVal=t,this.tableFrom.date=t?this.timeVal.join("-"):"",this.getList(1)},onchangeTime2:function(t){this.timeVal2=t,this.tableFrom.profit_date=t?this.timeVal2.join("-"):"",this.getList(1)},exports:function(){var t=Object(i["a"])(Object(a["a"])().mark((function t(e){var n,r,o,i,l;return Object(a["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:n=JSON.parse(JSON.stringify(this.tableFrom)),r=[],n.page=1,o=1,i={},l=0;case 5:if(!(l<o)){t.next=14;break}return t.next=8,this.downData(n);case 8:i=t.sent,o=Math.ceil(i.count/n.limit),i.export.length&&(r=r.concat(i.export),n.page++);case 11:l++,t.next=5;break;case 14:return Object(c["a"])(i.header,i.title,r,i.foot,i.filename),t.abrupt("return");case 16:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}(),downData:function(t){return new Promise((function(e,n){Object(l["w"])(t).then((function(t){return e(t.data)}))}))},exportRecord:function(){var t=this;Object(l["w"])(this.tableFrom).then((function(e){var n=t.$createElement;t.$msgbox({title:"提示",message:n("p",null,[n("span",null,'文件正在生成中,请稍后点击"'),n("span",{style:"color: teal"},"导出记录"),n("span",null,'"查看~ ')]),confirmButtonText:"我知道了"}).then((function(t){}))})).catch((function(e){t.$message.error(e.message)}))},getExportFileList:function(){this.$refs.exportList.exportFileList()},getList:function(t){var e=this;this.listLoading=!0,this.tableFrom.page=t||this.tableFrom.page,Object(l["f"])(this.tableFrom).then((function(t){e.tableData.data=t.data.list,e.tableData.total=t.data.count,e.listLoading=!1})).catch((function(t){e.$message.error(t.message),e.listLoading=!1}))},pageChange:function(t){this.tableFrom.page=t,this.getList("")},handleSizeChange:function(t){this.tableFrom.limit=t,this.getList("")}}},d=f,m=(n("5b8c"),n("2877")),g=Object(m["a"])(d,r,o,!1,null,"5022c0d9",null);e["default"]=g.exports},f8b7:function(t,e,n){"use strict";n.d(e,"I",(function(){return o})),n.d(e,"c",(function(){return a})),n.d(e,"b",(function(){return i})),n.d(e,"M",(function(){return l})),n.d(e,"F",(function(){return c})),n.d(e,"G",(function(){return u})),n.d(e,"q",(function(){return s})),n.d(e,"J",(function(){return f})),n.d(e,"L",(function(){return d})),n.d(e,"E",(function(){return m})),n.d(e,"K",(function(){return g})),n.d(e,"T",(function(){return p})),n.d(e,"R",(function(){return h})),n.d(e,"W",(function(){return v})),n.d(e,"V",(function(){return b})),n.d(e,"U",(function(){return y})),n.d(e,"Q",(function(){return w})),n.d(e,"e",(function(){return _})),n.d(e,"t",(function(){return x})),n.d(e,"S",(function(){return k})),n.d(e,"n",(function(){return D})),n.d(e,"m",(function(){return C})),n.d(e,"l",(function(){return F})),n.d(e,"k",(function(){return L})),n.d(e,"D",(function(){return z})),n.d(e,"x",(function(){return T})),n.d(e,"H",(function(){return O})),n.d(e,"Z",(function(){return V})),n.d(e,"ab",(function(){return A})),n.d(e,"Y",(function(){return j})),n.d(e,"B",(function(){return M})),n.d(e,"A",(function(){return S})),n.d(e,"y",(function(){return $})),n.d(e,"z",(function(){return R})),n.d(e,"C",(function(){return E})),n.d(e,"j",(function(){return Y})),n.d(e,"h",(function(){return B})),n.d(e,"i",(function(){return J})),n.d(e,"P",(function(){return W})),n.d(e,"p",(function(){return N})),n.d(e,"o",(function(){return I})),n.d(e,"a",(function(){return P})),n.d(e,"s",(function(){return G})),n.d(e,"w",(function(){return H})),n.d(e,"r",(function(){return K})),n.d(e,"g",(function(){return Q})),n.d(e,"f",(function(){return U})),n.d(e,"O",(function(){return X})),n.d(e,"N",(function(){return Z})),n.d(e,"v",(function(){return q})),n.d(e,"u",(function(){return tt})),n.d(e,"X",(function(){return et})),n.d(e,"d",(function(){return nt}));var r=n("0c6d");function o(t){return r["a"].get("store/order/lst",t)}function a(){return r["a"].get("store/order/chart")}function i(t){return r["a"].get("store/order/title",t)}function l(t,e){return r["a"].post("store/order/update/".concat(t),e)}function c(t,e){return r["a"].post("store/order/delivery/".concat(t),e)}function u(t){return r["a"].get("store/order/detail/".concat(t))}function s(t){return r["a"].get("store/order/children/".concat(t))}function f(t,e){return r["a"].get("store/order/log/".concat(t),e)}function d(t){return r["a"].get("store/order/remark/".concat(t,"/form"))}function m(t){return r["a"].post("store/order/delete/".concat(t))}function g(t){return r["a"].get("store/order/printer/".concat(t))}function p(t){return r["a"].get("store/refundorder/lst",t)}function h(t){return r["a"].get("store/refundorder/detail/".concat(t))}function v(t){return r["a"].get("store/refundorder/status/".concat(t,"/form"))}function b(t){return r["a"].get("store/refundorder/mark/".concat(t,"/form"))}function y(t){return r["a"].get("store/refundorder/log/".concat(t))}function w(t){return r["a"].get("store/refundorder/delete/".concat(t))}function _(t){return r["a"].post("store/refundorder/refund/".concat(t))}function x(t){return r["a"].get("store/order/express/".concat(t))}function k(t){return r["a"].get("store/refundorder/express/".concat(t))}function D(t){return r["a"].get("store/order/excel",t)}function C(t){return r["a"].get("store/order/delivery_export",t)}function F(t){return r["a"].get("excel/lst",t)}function L(t){return r["a"].get("excel/download/".concat(t))}function z(t){return r["a"].get("store/order/verify/".concat(t))}function T(t,e){return r["a"].post("store/order/verify/".concat(t),e)}function O(){return r["a"].get("store/order/filtter")}function V(){return r["a"].get("store/order/takechart")}function A(t){return r["a"].get("store/order/takelst",t)}function j(t){return r["a"].get("store/order/take_title",t)}function M(t){return r["a"].get("store/receipt/lst",t)}function S(t){return r["a"].get("store/receipt/set_recipt",t)}function $(t){return r["a"].post("store/receipt/save_recipt",t)}function R(t){return r["a"].get("store/receipt/detail/".concat(t))}function E(t,e){return r["a"].post("store/receipt/update/".concat(t),e)}function Y(t){return r["a"].get("store/import/lst",t)}function B(t,e){return r["a"].get("store/import/detail/".concat(t),e)}function J(t,e){return r["a"].get("store/import/excel/".concat(t),e)}function W(t){return r["a"].get("store/refundorder/excel",t)}function N(){return r["a"].get("expr/options")}function I(t){return r["a"].get("expr/temps",t)}function P(t){return r["a"].post("store/order/delivery_batch",t)}function G(){return r["a"].get("serve/config")}function H(){return r["a"].get("delivery/station/select")}function K(){return r["a"].get("delivery/station/options")}function Q(t){return r["a"].get("delivery/order/lst",t)}function U(t){return r["a"].get("delivery/order/cancel/".concat(t,"/form"))}function X(t){return r["a"].get("delivery/station/payLst",t)}function Z(t){return r["a"].get("delivery/station/code",t)}function q(t){return r["a"].get("store/refundorder/check/".concat(t))}function tt(){return r["a"].get("store/refundorder/refund_message")}function et(t){return r["a"].post("store/refundorder/create",t)}function nt(t){return r["a"].post("store/refundorder/compute",t)}}}]);