import{c as u,t as s,v as a,dy as i,dn as r,dz as c,dA as o,dB as l,dC as p,dD as y,dE as d,dF as m,dG as q,dH as f,dI as S,dJ as h,dK as F}from"./index-Ef5HIHwv.js";function Q(e,n={}){return u({queryKey:["supplier-balances",e,n.owner||"all",n.breakdownByOwner?"owner":"agg"],queryFn:()=>f(e,n),staleTime:60*1e3,refetchOnWindowFocus:!1})}function T(e,n={}){return u({queryKey:["supplier-transactions",e,n.currency,n.type,n.owner||"all",n.page,n.per_page],queryFn:()=>S(e,n),enabled:!!e,staleTime:30*1e3,refetchOnWindowFocus:!1,placeholderData:t=>t})}function v(e){const n=s();return a({mutationFn:t=>c(e,t),onSuccess:()=>{n.invalidateQueries({queryKey:["supplier-balances"]}),n.invalidateQueries({queryKey:["supplier-transactions",e]})}})}function g(e){const n=s();return a({mutationFn:t=>i(e,t),onSuccess:()=>{n.invalidateQueries({queryKey:["supplier-balances"]}),n.invalidateQueries({queryKey:["supplier-transactions",e]})}})}function B(){const e=s();return a({mutationFn:()=>r(),onSuccess:()=>{e.invalidateQueries({queryKey:["supplier-balances"]}),e.invalidateQueries({queryKey:["supplier-transactions"]})}})}function C(){return u({queryKey:["payment-methods"],queryFn:()=>h(),staleTime:5*60*1e3})}function b(){const e=s();return a({mutationFn:m,onSuccess:()=>e.invalidateQueries({queryKey:["payment-methods"]})})}function M(){const e=s();return a({mutationFn:({id:n,payload:t})=>q(n,t),onSuccess:()=>e.invalidateQueries({queryKey:["payment-methods"]})})}function P(){const e=s();return a({mutationFn:n=>p(n),onSuccess:()=>e.invalidateQueries({queryKey:["payment-methods"]})})}function w(e){const n=s();return a({mutationFn:t=>o(e,t),onSuccess:()=>{n.invalidateQueries({queryKey:["supplier-balances"]}),n.invalidateQueries({queryKey:["supplier-transactions",e]})}})}function E(e){const n=s();return a({mutationFn:()=>l(e),onSuccess:()=>{n.invalidateQueries({queryKey:["supplier-balances"]})}})}function k(){return a({mutationFn:()=>d()})}function D(){return u({queryKey:["finance-team-emails"],queryFn:()=>F(),staleTime:5*60*1e3})}function O(){const e=s();return a({mutationFn:n=>y(n),onSuccess:()=>e.invalidateQueries({queryKey:["finance-team-emails"]})})}export{E as a,Q as b,T as c,g as d,B as e,C as f,v as g,P as h,b as i,M as j,D as k,O as l,k as m,w as u};
