import{aT as r,ac as R,al as S,a$ as P,ae as k,_ as x,d as B,w as c,b0 as M,r as f,o as I,G as V,C as h,j as d,l as g}from"./index.js";import{R as Y,M as s}from"./role-modal.3559ab.js";import{r as L}from"./columnRenderHelper.fb4c031a.js";import{u as T}from"./use-page-search.f7bc460e.js";import{S as $}from"./super.f53b4198.js";import"./index.84fc395c.js";const{VITE_PROXY_DOMAIN_REAL:te,VITE_PROXY_USER_REAL:q}=R(),l=q+"/admin/",U=e=>r.request("post",`${l}user_role_list`,{data:{level:"3",...e}}),W=e=>r.request("post",`${l}usersave`,{data:e}),j=e=>r.request("post",`${l}menustatus`,{data:e}),H=e=>r.request("post",`${l}setrole`,{data:e}),O=[{type:"selection",width:40,align:"center",hide:({checkList:e})=>!e.includes("\u52FE\u9009\u5217")},{label:"\u5E8F\u53F7",type:"index",minWidth:60,align:"left",hide:({checkList:e})=>!e.includes("\u5E8F\u53F7\u5217")},{label:"\u624B\u673A\u53F7",prop:"mobile",width:120,align:"left"},{label:"\u771F\u5B9E\u59D3\u540D",prop:"nickname",minWidth:150},{label:"\u72B6\u6001",prop:"status",width:120,cellRenderer:({row:e})=>S(P,{type:String(e.status)==="1"?"success":"danger"},{default:()=>String(e.status)==="1"?"\u542F\u7528":"\u7981\u7528"})},{label:"\u89D2\u8272",prop:"role_name",minWidth:150,align:"left"},{label:"\u516C\u53F8\u540D\u79F0",prop:"companyName",minWidth:180,align:"left",...L("companyCode","companyName","\u516C\u53F8\u7F16\u7801:")},{label:"\u521B\u5EFA\u65F6\u95F4",width:140,prop:"addtime",formatter:({addtime:e})=>k(e).format("YYYY-MM-DD HH:mm:ss")},{label:"\u64CD\u4F5C",fixed:"right",width:80,slot:"operation"}],Q={title:"\u516C\u53F8\u8D26\u53F7\u89D2\u8272\u67E5\u8BE2",columns:O,deleteProp:"payNo",notNeedCompanyFilter:!0,statusRowProp:({companyCode:e})=>({companyNo:e}),apis:{httpAdd:!0,httpDelete:j,httpUpdate:W,httpList:U}},_={formItems:[{field:"nickname",type:"input",placeholder:"\u771F\u5B9E\u59D3\u540D"},{field:"username",type:"input",placeholder:"\u624B\u673A\u53F7"}]},X=B({__name:"index",setup(e){const y="supplierAccountQuery",a=c(null),m=c(null),n=c(""),F=()=>({result:{companyNo:n.value},deleteProps:[]}),v={pageSearchHook:()=>T(F,()=>n.value="",_,!0)},{run:C}=M({success:()=>m.value.onSearch()}),D={content:{create:()=>a.value.onDisplay(void 0,s.create),preview:t=>a.value.onDisplay(t,s.preview),update:t=>a.value.onDisplay(t,s.update)}};function E(t,u){const{roleid:p,nickname:i,relaComNo:o,id:A,companyNo:N,mobile:b}=t,w={id:A,mobile:b,roleid:p,nickname:i,relaComNo:o,companyNo:N};switch(u){case s.update:C(H(w));break}}return(t,u)=>{const p=f("PageContainer"),i=f("PageAuth");return I(),V(i,{pageName:y},{default:h(()=>[d(p,{hooks:v,events:D,contentConfig:g(Q),"search-config":g(_),"get-content-ref":o=>m.value=o},{search_field:h(()=>[d($,{style:{"margin-right":"20px",width:"100%"},modelValue:n.value,"onUpdate:modelValue":u[0]||(u[0]=o=>n.value=o),placeholder:"\u4F9B\u5E94\u5546\u516C\u53F8","no-all":"","no-set":"","is-supplier":""},null,8,["modelValue"])]),_:1},8,["contentConfig","search-config","get-content-ref"]),d(Y,{ref_key:"roleModalRef",ref:a,onFinanceSave:E},null,512)]),_:1})}}});var oe=x(X,[["__file","C:/Users/Administrator/Desktop/projects/purchase-vue3/src/views/supplierInterest/supplierAccountQuery/index.vue"]]);export{oe as default};