import{_ as y,d as b,m,cl as k,cU as B,d1 as R,w,r as p,o as f,A as d,x as C,u as n,D as S,H as N,a as P}from"./index.aedafc85.js";import{s as A,c as E,a as F}from"./content.config.34785a39.js";import{h as T}from"./export.443e72b5.js";import{i as I}from"./isBeyondTime.4a671960.js";import{u as L}from"./use-page-search.76f1460d.js";import{u as D,a as U}from"./useBusinessQuery.9e998cc7.js";import"./createRequset.72613757.js";import"./xlsx.ed122d16.js";import"./lodash.93a5b9b5.js";const V="supplierList",q=b({__name:"business",setup(H){const c=m(null),a=k(!1),{hasPermissionWithCode:g}=B(V),u=R(),{searchConfig:r}=D({sourceConfig:A,queryField:"companyNo"}),l=m(r),{contentConfig:h}=U({sourceConfig:E,apis:{httpList:F.list}}),_={pageSearchHook:()=>L(void 0,void 0,r)};w(()=>u.level,e=>{const{formItems:s}=l.value,o=s.findIndex(({field:i})=>i==="depart_id"),{itemid:t=""}=u.info||{};Number(e)===2&&(l.value.formItems[o].defaultValue=t)},{immediate:!0});const v={onSuccess:()=>a.value=!1,onStart:()=>a.value=!0,onFail:()=>a.value=!1};async function x(){const e=c.value.getBasicParams()||{},{start:s,end:o}=e;I({start:s,end:o,len:30})||await T({isAdmin:!1,name:"\u8BA2\u5355\u660E\u7EC6\u8868.xlsx",fileType:"aplication/x-msexecl",url:"/purchease/purchase/orderListDetailedExport",...v,params:e})}return(e,s)=>{const o=p("el-button"),t=p("PageContainer");return f(),d(t,{hooks:_,getContentRef:i=>c.value=i,"content-config":n(h),"search-config":n(r),lockKey:"companyNo"},{content_header:C(()=>[n(g)("18")?(f(),d(o,{key:0,icon:n(S)("arrow-up-line"),onClick:x,size:"small",type:"primary"},{default:C(()=>[N("\u5BFC\u51FA")]),_:1},8,["icon"])):P("v-if",!0)]),_:1},8,["getContentRef","content-config","search-config"])}}});var Q=y(q,[["__file","C:/Users/63107/Desktop/projects/report-v3/src/views/time/supplierList/components/business.vue"]]);export{Q as default};
