import{_ as g,d,aD as h,w as v,r as u,o as B,G as k,C as l,l as x,u as n,J as y,M as w,au as R}from"./index.1d5f2f42.js";import{s as b,c as A}from"./content.config.44a2811f.js";import{u as F}from"./use-page-search.5b2e253c.js";import{u as E,a as P}from"./useBusinessQuery.407c771e.js";import{c as S}from"./createRequset.a71f3020.js";import{h as T}from"./export.669edd93.js";import{i as N}from"./isBeyondTime.8b05db81.js";import"./lodash.f6259d7e.js";const z=d({__name:"business",setup(q){const s="relaComNo",o=h(!1),a=v(null),{searchConfig:r}=E({sourceConfig:b}),{contentConfig:p}=P({sourceConfig:A,apis:{httpList:S("r_saleexportlist")}}),f={pageSearchHook:()=>F(void 0,void 0,r,!1,s)},m={onSuccess:()=>o.value=!1,onStart:()=>o.value=!0,onFail:()=>o.value=!1};async function _(){const e=a.value.getBasicParams()||{},{start_date:c,end_date:t}=e;if(!e[s]){R.warning("\u8BF7\u9009\u62E9\u4E1A\u52A1\u516C\u53F8");return}N({start:c,end:t,len:10})||await T({fileType:"aplication/zip",url:"r_saleexport",name:"\u8BA2\u5355\u62A5\u8868.zip",isPurchase:!0,...m,params:e})}return(e,c)=>{const t=u("el-button"),i=u("PageContainer");return B(),k(i,{hooks:f,getContentRef:C=>a.value=C,"content-config":n(p),"search-config":n(r),lockKey:"relaComNo"},{content_header:l(()=>[x(t,{onClick:_,size:"small",icon:n(y)("arrow-up-line"),type:"primary"},{default:l(()=>[w("\u5BFC\u51FA")]),_:1},8,["icon"])]),_:1},8,["getContentRef","content-config","search-config"])}}});var L=g(z,[["__file","D:/work/rep-v3/report-v3/src/views/reportCollection/frontOrder/components/business.vue"]]);export{L as default};
