index.7fea11.js 3.1 KB

1
  1. import{aU as l,ac as w,am as S,aR as x,bb as P,ae as k,_ as B,d as M,x as i,bc as V,r as f,o as Y,G as I,D as h,l as d,m as g,bd as L}from"./index.js";import{R as U,M as s}from"./role-modal.689a3e.js";import{S as q}from"./super.711523e5.js";import"./index.04e98f94.js";const{VITE_PROXY_DOMAIN_REAL:Z,VITE_PROXY_USER_REAL:T}=w(),r=T+"/admin/",W=e=>l.request("post",`${r}userlist`,{data:{level:"3",...e}}),$=e=>l.request("post",`${r}usersave`,{data:e}),H=e=>l.request("post",`${r}menustatus`,{data:e}),O=e=>l.request("post",`${r}setrole`,{data:e}),j=[{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(x,{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",...P("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:j,deleteProp:"payNo",notNeedCompanyFilter:!0,statusRowProp:({companyCode:e})=>({companyNo:e}),apis:{httpAdd:!0,httpDelete:H,httpUpdate:$,httpList:W}},y={formItems:[{field:"nickname",type:"input",placeholder:"\u771F\u5B9E\u59D3\u540D"},{field:"username",type:"input",placeholder:"\u624B\u673A\u53F7"}]},X=M({__name:"index",setup(e){const F="supplierAccoutQuery",o=i(null),m=i(null),n=i(""),_=()=>({result:{companyNo:n.value},deleteProps:[]}),v={pageSearchHook:()=>L(_,()=>n.value="",y,!0)},{run:C}=V({success:()=>m.value.onSearch()}),D={content:{create:()=>o.value.onDisplay(void 0,s.create),preview:t=>o.value.onDisplay(t,s.preview),update:t=>o.value.onDisplay(t,s.update)}};function b(t,u){const{roleid:p,nickname:c,relaComNo:a,id:E,companyNo:N,mobile:A}=t,R={id:E,mobile:A,roleid:p,nickname:c,relaComNo:a,companyNo:N};switch(u){case s.update:C(O(R));break}}return(t,u)=>{const p=f("PageContainer"),c=f("PageAuth");return Y(),I(c,{pageName:F},{default:h(()=>[d(p,{hooks:v,events:D,contentConfig:g(Q),"search-config":g(y),"get-content-ref":a=>m.value=a},{search_field:h(()=>[d(q,{style:{"margin-right":"20px",width:"100%"},modelValue:n.value,"onUpdate:modelValue":u[0]||(u[0]=a=>n.value=a),placeholder:"\u4F9B\u5E94\u5546\u516C\u53F8","no-all":"","no-set":"","is-supplier":""},null,8,["modelValue"])]),_:1},8,["contentConfig","search-config","get-content-ref"]),d(U,{ref_key:"roleModalRef",ref:o,onFinanceSave:b},null,512)]),_:1})}}});var ee=B(X,[["__file","C:/Users/89793/Desktop/projects/settle-vue3/src/views/supplierManage/supplierAccoutQuery/index.vue"]]);export{ee as default};