content.config.80983a28.js 2.2 KB

1
  1. import{S as n}from"./index.56449854.js";import{a as u,s as l}from"./calc.f00124e1.js";import{c as p}from"./createRequset.56e9fc42.js";const s="admin/Everyday/";var m={list:p(`${s}EveryDz`),businessList:p("/purchease/sale/consultInfoListExport")};const h=n(new Date).subtract(0,"month").format("YYYY-MM"),E={formItems:[{field:"month",type:"date_picker",defaultValue:h,placeholder:"\u660E\u7EC6\u6708\u4EFD",trigger:"change",otherOptions:{editable:!1,clearable:!1,type:"month",format:"YYYY-MM",valueFormat:"YYYY-MM"}}]},_=[{type:"index",width:"60",label:"\u5E8F\u53F7"},{label:"\u6708\u4EFD",prop:"month",width:"80px"},{prop:"companyName",label:"\u4E1A\u52A1\u516C\u53F8",minWidth:"155px"},{prop:"supplierName",label:"\u4F9B\u5E94\u5546\u540D\u79F0",minWidth:"155px"},{prop:"hp_total",label:"\u4E70\u5165\u56DE\u7968\u91D1\u989D\u5408\u8BA1",minWidth:"155px"},{prop:"pay_total",label:"\u4E70\u5165\u4ED8\u6B3E\u91D1\u989D\u5408\u8BA1",minWidth:"155px"},{prop:"rehp_total",label:"\u89E3\u9664\u56DE\u7968\u91D1\u989D\u5408\u8BA1",minWidth:"155px"},{prop:"repay_total",label:"\u89E3\u9664\u4ED8\u6B3E\u91D1\u989D\u5408\u8BA1",minWidth:"155px"},{prop:"winv_total",label:"\u5F85\u5F00\u7968\u91D1\u989D",minWidth:"155px"},{prop:"wpay_total",label:"\u5F85\u4ED8\u6B3E\u91D1\u989D",minWidth:"155px"},{label:"\u56DE\u7968\u91D1\u989D\u5408\u8BA1",minWidth:"155px",cellRenderer({row:t}){return l(t.hp_total,t.rehp_total)}},{label:"\u4ED8\u6B3E\u91D1\u989D\u5408\u8BA1",minWidth:"155px",cellRenderer({row:t}){return l(t.pay_total,t.repay_total)}}],b={columns:_,showTitle:!1,responseCode:0,superUserNoAction:!1,apis:{httpList:m.list},handleData(t=[]){return new Promise(i=>{var o;const r=t.reduce((a,e)=>({hp_total:Number(u(a.hp_total,e.hp_total)).toFixed(2),pay_total:Number(u(a.pay_total,e.pay_total)).toFixed(2),rehp_total:Number(u(a.pay_total,e.pay_total)).toFixed(2),repay_total:Number(u(a.repay_total,e.repay_total)).toFixed(2),winv_total:Number(u(a.winv_total,e.winv_total)).toFixed(2),wpay_total:Number(u(a.wpay_total,e.wpay_total)).toFixed(2)}),{hp_total:0,pay_total:0,rehp_total:0,repay_total:0,winv_total:0,wpay_total:0});i([{...r,month:((o=t[0])==null?void 0:o.month)||"--",companyName:"\u5408\u8BA1",supplierName:"\u5408\u8BA1"},...t])})}};export{m as a,b as c,E as s};