var q=Object.defineProperty,v=Object.defineProperties;var P=Object.getOwnPropertyDescriptors;var l=Object.getOwnPropertySymbols;var c=Object.prototype.hasOwnProperty,m=Object.prototype.propertyIsEnumerable;var p=(e,s,t)=>s in e?q(e,s,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[s]=t,a=(e,s)=>{for(var t in s||(s={}))c.call(s,t)&&p(e,t,s[t]);if(l)for(var t of l(s))m.call(s,t)&&p(e,t,s[t]);return e},i=(e,s)=>v(e,P(s));var f=(e,s)=>{var t={};for(var r in e)c.call(e,r)&&s.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&l)for(var r of l(e))s.indexOf(r)<0&&m.call(e,r)&&(t[r]=e[r]);return t};import{n as d}from"./index.js";const u={xs:{span:24},sm:{span:24},lg:{span:8}},$={span:24},n={model:"UserAuthority",viewInPage:!1,properties:[{field:"id",label:"ID系统自动生成",defaultValue:void 0,form:{componentProps:{allowClear:!1,placeholder:"ID系统自动生成"},colProps:u,component:"InputNumber",rules:[{required:!0,message:"请输入ID系统自动生成！"}]},table:{}},{field:"userId",label:"sys_user.id",defaultValue:void 0,form:{componentProps:{allowClear:!1,placeholder:"sys_user.id"},colProps:u,component:"InputNumber",rules:[{required:!0,message:"请输入sys_user.id！"}]},table:{}},{field:"authorityId",label:"sys_authority.id",defaultValue:void 0,form:{componentProps:{allowClear:!1,placeholder:"sys_authority.id"},colProps:u,component:"InputNumber",rules:[{required:!0,message:"请输入sys_authority.id！"}]},table:{}}]},g=["id","userId","authorityId"],b=["userId","authorityId"],w=["userId","authorityId"],F=["userId","authorityId"],I=new Map(g.map((e,s)=>[e,s])),B=n.properties.filter(e=>g.includes(e.field)).map(r=>{var{field:e,label:s,form:M}=r,t=f(M,[]);return i(a({field:e,label:s,defaultValue:void 0},t),{required:!1,rules:[{required:!1}]})}).sort((e,s)=>{const t=I.get(e.field),r=I.get(s.field);return t-r}),x=new Map(b.map((e,s)=>[e,s])),C=n.properties.filter(e=>b.includes(e.field)).map(({field:e,label:s,defaultValue:t,form:r})=>i(a({field:e,label:s,defaultValue:t},r),{colProps:$})).sort((e,s)=>{const t=x.get(e.field),r=x.get(s.field);return t-r}),y=new Map(w.map((e,s)=>[e,s])),D=n.properties.filter(e=>w.includes(e.field)).map(({field:e,label:s,table:t})=>a({dataIndex:e,title:s},t)).sort((e,s)=>{const t=y.get(e.dataIndex),r=y.get(s.dataIndex);return t-r}),h=new Map(F.map((e,s)=>[e,s])),V=n.properties.filter(e=>F.includes(e.field)).map(({field:e,label:s,table:t})=>a({dataIndex:e,title:s},t)).sort((e,s)=>{const t=h.get(e.dataIndex),r=h.get(s.dataIndex);return t-r}),o="/v1/system/user-authority",N=e=>d.post({url:`${o}/`,data:e}),S=(e,s=!1)=>d.put({url:`${o}/`,data:e,params:{updateAllFields:s}}),H=e=>d.delete({url:`${o}/${e}`}),U=e=>d.get({url:`${o}/search`,params:e}),j=e=>d.get({url:`${o}/${e}`});export{N as a,B as b,D as c,V as d,C as f,j as g,H as r,U as s,S as u};
