var M=Object.defineProperty,$=Object.defineProperties;var q=Object.getOwnPropertyDescriptors;var l=Object.getOwnPropertySymbols;var c=Object.prototype.hasOwnProperty,m=Object.prototype.propertyIsEnumerable;var p=(e,t,s)=>t in e?M(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,d=(e,t)=>{for(var s in t||(t={}))c.call(t,s)&&p(e,s,t[s]);if(l)for(var s of l(t))m.call(t,s)&&p(e,s,t[s]);return e},i=(e,t)=>$(e,q(t));var f=(e,t)=>{var s={};for(var a in e)c.call(e,a)&&t.indexOf(a)<0&&(s[a]=e[a]);if(e!=null&&l)for(var a of l(e))t.indexOf(a)<0&&m.call(e,a)&&(s[a]=e[a]);return s};import{am as r}from"./index.js";const u={xs:{span:24},sm:{span:24},lg:{span:8}},P={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,t)=>[e,t])),B=n.properties.filter(e=>g.includes(e.field)).map(a=>{var{field:e,label:t,form:v}=a,s=f(v,[]);return i(d({field:e,label:t,defaultValue:void 0},s),{required:!1,rules:[{required:!1}]})}).sort((e,t)=>{const s=I.get(e.field),a=I.get(t.field);return s-a}),h=new Map(b.map((e,t)=>[e,t])),C=n.properties.filter(e=>b.includes(e.field)).map(({field:e,label:t,defaultValue:s,form:a})=>i(d({field:e,label:t,defaultValue:s},a),{colProps:P})).sort((e,t)=>{const s=h.get(e.field),a=h.get(t.field);return s-a}),x=new Map(w.map((e,t)=>[e,t])),D=n.properties.filter(e=>w.includes(e.field)).map(({field:e,label:t,table:s})=>d({dataIndex:e,title:t},s)).sort((e,t)=>{const s=x.get(e.dataIndex),a=x.get(t.dataIndex);return s-a}),y=new Map(F.map((e,t)=>[e,t])),V=n.properties.filter(e=>F.includes(e.field)).map(({field:e,label:t,table:s})=>d({dataIndex:e,title:t},s)).sort((e,t)=>{const s=y.get(e.dataIndex),a=y.get(t.dataIndex);return s-a}),o="/v1/system/user-authority",N=e=>r.post({url:`${o}/`,data:e}),S=(e,t=!1)=>r.put({url:`${o}/`,data:e,params:{updateAllFields:t}}),H=e=>r.delete({url:`${o}/${e}`}),R=e=>r.get({url:`${o}/search`,params:e}),U=e=>r.get({url:`${o}/${e}`}),j=e=>r.post({url:`${o}/batch-delete`,data:e});export{N as a,B as b,D as c,V as d,j as e,C as f,U as g,H as r,R as s,S as u};
