all.d40e7119.js 1.9 KB

1
  1. import{_ as k,d as P,cp as b,m as _,cl as w,cs as F,w as I,r as i,o as h,A as g,x as l,h as S,u as s,D as A,H as E,a as R,S as B}from"./index.56449854.js";import{s as u,c as N}from"./content.config.f5070ad9.js";import{u as T}from"./use-page-search.59eb5443.js";import{i as V}from"./isBeyondTime.b16fe52f.js";import{h as D}from"./export.a2ce61c0.js";import"./createRequset.56e9fc42.js";import"./xlsx.ed122d16.js";const m="goodPriceInfo",j=P({__name:"all",setup(H){const{hasPermissionWithCode:v}=b(m),p=_(null),r=w(!1),f=F(),d=_(u),x={pageSearchHook:()=>T(function(t){const{year_month:e,...n}=t;let o="",a="";if(e){o=e+"-01";const c=B(o).subtract(1,"month").endOf("month").date();a=e+"-"+c}return{result:{...n,start:o,end:a},deleteProp:[]}},void 0,u)},C={onSuccess:()=>r.value=!1,onStart:()=>r.value=!0,onFail:()=>r.value=!1};I(()=>f.level,t=>{const{formItems:e}=d.value,n=e.findIndex(({field:a})=>a==="depart_id"),{itemid:o=""}=f.info||{};Number(t)===2&&(d.value.formItems[n].defaultValue=o)},{immediate:!0});async function y(){const t=p.value.getBasicParams()||{},{start:e,end:n}=t;V({start:e,end:n,len:30})||await D({params:t,...C,isAdmin:!1,name:"\u5546\u54C1\u552E\u4EF7\u4FE1\u606F\u62A5\u8868.xlsx",fileType:"aplication/x-msexecl",url:"/purchease/purchase/goodPriceInfoExport"})}return(t,e)=>{const n=i("el-button"),o=i("page-container"),a=i("page-auth");return h(),g(a,{"page-name":m},{default:l(()=>[S(o,{hooks:x,"page-name":m,"get-content-ref":c=>p.value=c,"content-config":s(N),"search-config":s(u)},{content_header:l(()=>[s(v)("9")?(h(),g(n,{key:0,onClick:y,size:"small",icon:s(A)("arrow-up-line"),type:"primary"},{default:l(()=>[E("\u5BFC\u51FA")]),_:1},8,["icon"])):R("v-if",!0)]),_:1},8,["get-content-ref","content-config","search-config"])]),_:1})}}});var K=k(j,[["__file","C:/Users/89793/Desktop/projects/report-v3/src/views/time/goodPriceInfo/components/all.vue"]]);export{K as default};