@tachybase/module-user 0.23.20 → 0.23.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,3 @@
1
1
  import React from 'react';
2
+ export declare const RoleUsersTableBlockProvider: React.FunctionComponent<any>;
2
3
  export declare const RoleUsersManager: React.FC;
@@ -3,3 +3,14 @@ export declare const useFilterActionProps: () => {
3
3
  onSubmit(values: any): any;
4
4
  onReset(): any;
5
5
  };
6
+ export declare const useRemoveUser: () => {
7
+ onClick(): Promise<void>;
8
+ };
9
+ export declare const useBulkRemoveUsers: () => {
10
+ onClick(): Promise<void>;
11
+ };
12
+ export declare const useAddRoleUsers: () => {
13
+ onClick(): Promise<void>;
14
+ };
15
+ export declare const useRoleUsersProps: (props: any) => any;
16
+ export declare const useRoleUsersServiceProps: (props: any) => any;
@@ -1 +1 @@
1
- (function(r,e){typeof exports=="object"&&typeof module!="undefined"?e(exports,require("@tachybase/client"),require("@tachybase/module-acl/client"),require("react/jsx-runtime"),require("react"),require("antd"),require("react-i18next"),require("@tachybase/schema"),require("@tachybase/utils/client")):typeof define=="function"&&define.amd?define(["exports","@tachybase/client","@tachybase/module-acl/client","react/jsx-runtime","react","antd","react-i18next","@tachybase/schema","@tachybase/utils/client"],e):(r=typeof globalThis!="undefined"?globalThis:r||self,e(r["@tachybase/module-user"]={},r["@tachybase/client"],r["@tachybase/module-acl"],r.jsxRuntime,r.react,r.antd,r["react-i18next"],r["@tachybase/schema"],r["@tachybase/utils"]))})(this,function(r,e,i,c,p,d,g,x,y){"use strict";var H=Object.defineProperty,J=Object.defineProperties;var Q=Object.getOwnPropertyDescriptors;var S=Object.getOwnPropertySymbols;var W=Object.prototype.hasOwnProperty,X=Object.prototype.propertyIsEnumerable;var P=(r,e,i)=>e in r?H(r,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):r[e]=i,A=(r,e)=>{for(var i in e||(e={}))W.call(e,i)&&P(r,i,e[i]);if(S)for(var i of S(e))X.call(e,i)&&P(r,i,e[i]);return r},b=(r,e)=>J(r,Q(e));var v=(r,e,i)=>new Promise((c,p)=>{var d=y=>{try{x(i.next(y))}catch(h){p(h)}},g=y=>{try{x(i.throw(y))}catch(h){p(h)}},x=y=>y.done?c(y.value):Promise.resolve(y.value).then(d,g);x((i=i.apply(r,e)).next())});const h=()=>{var s,a;const o=p.useContext(e.CollectionContext),t=e.useFilterFieldOptions(o.fields),n=e.useResourceActionContext();return e.useFilterFieldProps({options:t,params:((a=(s=n.state)==null?void 0:s.params)==null?void 0:a[0])||n.params,service:n})};function f(){return g.useTranslation(["users","core"],{nsMode:"fallback"})}const w={name:"users",fields:[{name:"id",type:"bigInt",autoIncrement:!0,primaryKey:!0,allowNull:!1,uiSchema:{type:"number",title:'{{t("ID")}}',"x-component":"InputNumber","x-read-pretty":!0},interface:"id"},{interface:"input",type:"string",name:"nickname",uiSchema:{type:"string",title:'{{t("Nickname")}}',"x-component":"Input"}},{interface:"input",type:"string",name:"username",unique:!0,uiSchema:{type:"string",title:'{{t("Username")}}',"x-component":"Input","x-validator":{username:!0},required:!0}},{interface:"email",type:"string",name:"email",unique:!0,uiSchema:{type:"string",title:'{{t("Email")}}',"x-component":"Input","x-validator":"email",required:!0}},{interface:"phone",type:"string",name:"phone",unique:!0,uiSchema:{type:"string",title:'{{t("Phone")}}',"x-component":"Input","x-validator":"phone",required:!0}},{interface:"password",type:"password",name:"password",hidden:!0,uiSchema:{type:"string",title:'{{t("Password")}}',"x-component":"Password"}},{interface:"m2m",type:"belongsToMany",name:"roles",target:"roles",foreignKey:"userId",otherKey:"roleName",onDelete:"CASCADE",sourceKey:"id",targetKey:"name",through:"rolesUsers",uiSchema:{type:"array",title:'{{t("Roles")}}',"x-component":"AssociationField","x-component-props":{multiple:!0,fieldNames:{label:"title",value:"name"}}}}]},I={type:"object",properties:{block1:{type:"void","x-decorator":"ResourceActionProvider","x-decorator-props":{collection:w,resourceName:"users",request:{resource:"users",action:"list",params:{pageSize:50,appends:[]}}},properties:{actions:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:16}},properties:{filter:{type:"void",title:'{{ t("Filter") }}',"x-action":"filter","x-component":"Filter.Action","x-use-component-props":"useFilterActionProps","x-component-props":{icon:"FilterOutlined"},"x-align":"left"},delete:{type:"void",title:'{{ t("Delete") }}',"x-component":"Action","x-component-props":{useAction:"{{ cm.useBulkDestroyAction }}",confirm:{title:"{{t('Delete users')}}",content:"{{t('Are you sure you want to delete it?')}}"},icon:"DeleteOutlined"}},create:{type:"void",title:'{{t("Add new")}}',"x-component":"Action","x-component-props":{type:"primary",icon:"PlusOutlined"},properties:{drawer:{type:"void","x-component":"Action.Drawer","x-decorator":"Form",title:'{{t("Add user")}}',properties:{nickname:{"x-component":"CollectionField","x-decorator":"FormItem"},username:{"x-component":"CollectionField","x-decorator":"FormItem"},email:{title:'{{t("Email")}}',"x-component":"Input","x-validator":"email","x-decorator":"FormItem",required:!1},phone:{title:'{{t("Phone")}}',"x-component":"Input","x-validator":"phone","x-decorator":"FormItem",required:!1},password:{"x-component":"CollectionField","x-decorator":"FormItem",required:!0},roles:{"x-component":"CollectionField","x-collection-field":"users.roles","x-decorator":"FormItem"},footer:{type:"void","x-component":"Action.Drawer.Footer",properties:{cancel:{title:'{{t("Cancel")}}',"x-component":"Action","x-component-props":{useAction:"{{ cm.useCancelAction }}"}},submit:{title:'{{t("Submit")}}',"x-component":"Action","x-component-props":{type:"primary",useAction:"{{ cm.useCreateAction }}"}}}}}}}}}},table:{type:"void","x-uid":"input","x-component":"Table.Void","x-component-props":{rowKey:"id",rowSelection:{type:"checkbox"},useDataSource:"{{ cm.useDataSourceFromRAC }}"},properties:{column1:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{nickname:{type:"number","x-component":"CollectionField","x-read-pretty":!0}}},column2:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{username:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},column3:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{email:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},column4:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",title:'{{t("Roles")}}',properties:{roles:{type:"array","x-component":"UserRolesField"}}},column5:{type:"void",title:'{{t("Actions")}}',"x-component":"Table.Column",properties:{actions:{type:"void","x-component":"Space","x-component-props":{split:"|"},properties:{update:{type:"void",title:'{{t("Edit profile")}}',"x-decorator":"ACLActionProvider","x-acl-action":"users:update","x-component":"Action.Link","x-component-props":{type:"primary"},properties:{drawer:{type:"void","x-component":"Action.Drawer","x-decorator":"Form","x-decorator-props":{useValues:o=>{const t=e.useRecord(),n=e.useRequest(()=>Promise.resolve({data:t}),b(A({},o),{manual:!0})),s=e.useActionContext();return p.useEffect(()=>{s.visible&&n.run()},[s.visible]),n}},title:'{{t("Edit profile")}}',properties:{nickname:{"x-component":"CollectionField","x-decorator":"FormItem"},username:{"x-component":"CollectionField","x-decorator":"FormItem"},email:{title:'{{t("Email")}}',"x-component":"Input","x-validator":"email","x-decorator":"FormItem",required:!1},phone:{title:'{{t("Phone")}}',"x-component":"Input","x-validator":"phone","x-decorator":"FormItem",required:!1},roles:{"x-component":"CollectionField","x-decorator":"FormItem","x-collection-field":"users.roles"},footer:{type:"void","x-component":"Action.Drawer.Footer",properties:{cancel:{title:'{{t("Cancel")}}',"x-component":"Action","x-component-props":{useAction:"{{ cm.useCancelAction }}"}},submit:{title:'{{t("Submit")}}',"x-component":"Action","x-component-props":{type:"primary",useAction:"{{ cm.useUpdateAction }}"}}}}}}}},changePassword:{type:"void",title:'{{t("Change password")}}',"x-decorator":"ACLActionProvider","x-acl-action":"users:update","x-component":"Action.Link","x-component-props":{type:"primary"},properties:{drawer:{type:"void","x-component":"Action.Drawer","x-decorator":"Form",title:'{{t("Change password")}}',properties:{password:{"x-component":"CollectionField","x-component-props":{component:"PasswordField"},"x-decorator":"FormItem",required:!0},footer:{type:"void","x-component":"Action.Drawer.Footer",properties:{cancel:{title:'{{t("Cancel")}}',"x-component":"Action","x-component-props":{useAction:"{{ cm.useCancelAction }}"}},submit:{title:'{{t("Submit")}}',"x-component":"Action","x-component-props":{type:"primary",useAction:"{{ cm.useUpdateAction }}"}}}}}}}},delete:{type:"void",title:'{{ t("Delete") }}',"x-acl-action":"users:destroy","x-action":"destroy","x-decorator":"ACLActionProvider","x-component":"Action.Link","x-component-props":{confirm:{title:"{{t('Delete')}}",content:"{{t('Are you sure you want to delete it?')}}"},useAction:"{{cm.useDestroyAction}}"}}}}}}}}}}}},U=()=>({type:"void",properties:{actions:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:16}},properties:{[x.uid()]:{type:"void",title:'{{ t("Filter") }}',"x-action":"filter","x-component":"Filter.Action","x-use-component-props":"useFilterActionProps","x-component-props":{icon:"FilterOutlined"},"x-align":"left"},actions:{type:"void","x-component":"Space",properties:{remove:{type:"void",title:'{{t("Remove")}}',"x-component":"Action","x-component-props":{icon:"MinusOutlined",confirm:{title:"{{t('Remove')}}",content:"{{t('Are you sure you want to remove these users?')}}"},style:{marginRight:8},useAction:"{{ useBulkRemoveUsers }}"}},create:{type:"void",title:'{{t("Add users")}}',"x-component":"Action","x-component-props":{type:"primary",icon:"PlusOutlined"},properties:{drawer:{type:"void","x-component":"Action.Drawer","x-decorator":"FormV2",title:'{{t("Add users")}}',properties:{resource:{type:"void","x-decorator":"FormItem","x-component":"RoleUsersProvider",properties:{actions:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:16}},properties:{filter:{type:"void",title:'{{ t("Filter") }}',default:{$and:[{username:{$includes:""}},{nickname:{$includes:""}}]},"x-action":"filter","x-component":"Filter.Action","x-use-component-props":"useFilterActionProps","x-component-props":{icon:"FilterOutlined"},"x-align":"left"}}},table:{type:"void","x-component":"Table.Void","x-component-props":{rowKey:"id",rowSelection:{type:"checkbox",onChange:"{{ handleSelectRoleUsers }}"},useDataSource:"{{ cm.useDataSourceFromRAC }}"},properties:{username:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{username:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},nickname:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{nickname:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},phone:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{phone:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},email:{type:"void","x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{email:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}}}}}},footer:{type:"void","x-component":"Action.Drawer.Footer",properties:{cancel:{title:'{{t("Cancel")}}',"x-component":"Action","x-component-props":{useAction:"{{ cm.useCancelAction }}"}},submit:{title:'{{t("Submit")}}',"x-component":"Action","x-component-props":{type:"primary",useAction:"{{ useAddRoleUsers }}"}}}}}}}}}}}},table:{type:"void","x-component":"Table.Void","x-component-props":{rowKey:"id",rowSelection:{type:"checkbox"},useDataSource:"{{ cm.useDataSourceFromRAC }}"},properties:{username:{type:"void",title:'{{t("Username")}}',"x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{username:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},nickname:{type:"void",title:'{{t("Nickname")}}',"x-decorator":"Table.Column.Decorator","x-component":"Table.Column",properties:{nickname:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},actions:{type:"void",title:'{{t("Actions")}}',"x-component":"Table.Column",properties:{actions:{type:"void","x-component":"Space","x-component-props":{split:"|"},properties:{remove:{type:"void",title:'{{ t("Remove") }}',"x-component":"Action.Link","x-component-props":{confirm:{title:"{{t('Remove user')}}",content:"{{t('Are you sure you want to remove it?')}}"},useAction:"{{ useRemoveUser }}"}}}}}}}}}}),T=()=>{const o=e.useAPIClient(),{role:t}=p.useContext(i.RolesManagerContext),n=e.useRecord(),{refresh:s}=e.useResourceActionContext();return{run(){return v(this,null,function*(){yield o.resource("roles.users",t==null?void 0:t.name).remove({values:[n.id]}),s()})}}},D=()=>{const{t:o}=f(),{message:t}=d.App.useApp(),n=e.useAPIClient(),{state:s,setState:a,refresh:C}=e.useResourceActionContext(),{role:l}=p.useContext(i.RolesManagerContext);return{run(){return v(this,null,function*(){const m=s==null?void 0:s.selectedRowKeys;if(!(m!=null&&m.length)){t.warning(o("Please select users"));return}yield n.resource("roles.users",l==null?void 0:l.name).remove({values:m}),a==null||a({selectedRowKeys:[]}),C()})}}},k=o=>{const{role:t}=p.useContext(i.RolesManagerContext);return c.jsx(e.ResourceActionProvider,{collection:w,request:{resource:"users",action:"listExcludeRole",params:{roleName:t==null?void 0:t.name}},children:o.children})},q=()=>{const{t:o}=f(),{role:t}=p.useContext(i.RolesManagerContext),n=e.useRequest({resource:"roles.users",resourceOf:t==null?void 0:t.name,action:"list"},{ready:!!t});p.useEffect(()=>{n.run()},[t]);const s=p.useRef([]),a=(u,m)=>{s.current=m},C=()=>{const{role:u}=p.useContext(i.RolesManagerContext),m=e.useAPIClient(),{setVisible:F}=e.useActionContext(),{refresh:z}=e.useResourceActionContext();return{run(){return v(this,null,function*(){yield m.resource("roles.users",u==null?void 0:u.name).add({values:s.current.map(G=>G.id)}),s.current=[],F(!1),z()})}}},l=p.useMemo(()=>U(),[t]);return c.jsx(e.ResourceActionContext.Provider,{value:A({},n),children:c.jsx(e.CollectionProvider_deprecated,{collection:w,children:c.jsx(e.SchemaComponent,{schema:l,components:{RoleUsersProvider:k},scope:{useBulkRemoveUsers:D,useRemoveUser:T,handleSelectRoleUsers:a,useAddRoleUsers:C,useFilterActionProps:h,t:o}})})})},R=()=>c.jsx(e.SchemaComponent,{schema:M,scope:{useSaveCurrentUserValues:V}}),V=()=>{const o=x.useForm(),t=e.useAPIClient(),{message:n}=d.App.useApp(),{t:s}=e.useTranslation();return{run(){return v(this,null,function*(){yield o.submit(),(yield t.resource("auth").changePassword({values:o.values})).status===200&&n.success(s("Edited successfully")),yield o.reset()})}}},M={type:"object",properties:{[y.uid()]:{type:"void","x-component":"CardItem","x-decorator":"Form",title:'{{t("Change password")}}',properties:{action:{type:"void",properties:{submit:{title:'{{t("Submit")}}',"x-component":"Action","x-component-props":{type:"primary",style:{left:"96%"},useAction:"{{ useSaveCurrentUserValues }}"}}}},oldPassword:{type:"string",title:'{{t("Old password")}}',required:!0,"x-component":"Password","x-decorator":"FormItem"},newPassword:{type:"string",title:'{{t("New password")}}',required:!0,"x-component":"Password","x-decorator":"FormItem","x-component-props":{checkStrength:!0,style:{}},"x-reactions":[{dependencies:[".confirmPassword"],fulfill:{state:{selfErrors:'{{$deps[0] && $self.value && $self.value !== $deps[0] ? t("Password mismatch") : ""}}'}}}]},confirmPassword:{type:"string",required:!0,title:'{{t("Confirm password")}}',"x-component":"Password","x-decorator":"FormItem","x-component-props":{checkStrength:!0,style:{}},"x-reactions":[{dependencies:[".newPassword"],fulfill:{state:{selfErrors:'{{$deps[0] && $self.value && $self.value !== $deps[0] ? t("Password mismatch") : ""}}'}}}]}}}}},E=()=>c.jsx(e.SchemaComponent,{schema:B,scope:{useCurrentUserValues:O,useSaveCurrentUserValues:j}}),O=o=>{const t=e.useCurrentUserContext();return e.useRequest(()=>Promise.resolve(t.data),o)},j=()=>{const o=e.useCurrentUserContext(),t=x.useForm(),n=e.useAPIClient(),{message:s}=d.App.useApp(),{t:a}=e.useTranslation();return{run(){return v(this,null,function*(){var m;const l=yield t.submit();(yield n.resource("users").updateProfile({values:l})).status===200&&s.success(a("Edited successfully")),o.mutate({data:A(A({},(m=o==null?void 0:o.data)==null?void 0:m.data),l)})})}}},B={type:"object",properties:{[y.uid()]:{type:"void","x-component":"CardItem","x-decorator":"Form","x-decorator-props":{useValues:"{{useCurrentUserValues}}"},title:'{{t("Edit profile")}}',properties:{action:{type:"void",properties:{submit:{title:"Submit","x-component":"Action","x-component-props":{type:"primary",style:{left:"96%"},useAction:"{{ useSaveCurrentUserValues }}"}}}},nickname:{type:"string",title:"{{t('Nickname')}}","x-decorator":"FormItem","x-component":"Input"},username:{type:"string",title:'{{t("Username")}}',"x-decorator":"FormItem","x-component":"Input","x-validator":{username:!0},required:!0},email:{type:"string",title:'{{t("Email")}}',"x-decorator":"FormItem","x-component":"Input","x-validator":"email"},phone:{type:"string",title:'{{t("Phone")}}',"x-decorator":"FormItem","x-component":"Input","x-validator":"phone"}}}}},K=(o=10)=>{const t="ABCDEFGHIJKLMNOPQRSTUVWXYZ",n="abcdefghijklmnopqrstuvwxyz",s="0123456789",a="!#$%^&*-_+=",C=t+n+s+a,l=new Uint32Array(o);crypto.getRandomValues(l);let u="";u+=t.charAt(l[0]%t.length),u+=n.charAt(l[1]%n.length),u+=s.charAt(l[2]%s.length),u+=a.charAt(l[3]%a.length);for(let m=4;m<o;m++){const F=l[m]%C.length;u+=C.charAt(F)}return u=u[0]+u.slice(1).split("").sort(()=>Math.random()-.5).join(""),u},N=()=>{const{t:o}=f(),t=x.useField(),[n,s]=p.useState(!1),a=e.useActionContext();return p.useEffect(()=>{a.visible||t.reset()},[t,a.visible]),c.jsxs(d.Row,{gutter:10,children:[c.jsx(d.Col,{span:18,children:c.jsx(e.Password,{checkStrength:!0,visibilityToggle:{visible:n,onVisibleChange:s},value:t.value,onChange:C=>t.setValue(C.target.value),autoComplete:"off"})}),c.jsx(d.Col,{span:4,children:c.jsx(d.Button,{onClick:()=>{t.setValue(K()),s(!0)},children:o("Random password")})})]})},$=()=>{const{t:o}=f();return(x.useField().value||[]).map(n=>c.jsx(d.Tag,{children:x.Schema.compile(n.title,{t:o})},n.name))},L=()=>{const{t:o}=f(),t=e.useSchemaComponentContext();return c.jsx(e.SchemaComponentContext.Provider,{value:b(A({},t),{designable:!1}),children:c.jsx(d.Card,{children:c.jsx(e.SchemaComponent,{schema:I,scope:{t:o,useFilterActionProps:h},components:{UserRolesField:$,PasswordField:N}})})})};class _ extends e.Plugin{load(){return v(this,null,function*(){this.app.systemSettingsManager.add("id-auth.users",{title:e.tval("Users"),icon:"UserOutlined",Component:L,aclSnippet:"pm.users"}),this.userSettingsManager.add("user-change-password",{icon:"LockOutlined",title:e.tval("Change password"),Component:R}),this.userSettingsManager.add("user-profile",{icon:"UserOutlined",title:e.tval("Edit profile"),Component:E}),this.app.pm.get(i).rolesManager.add("users",{title:e.tval("Users"),Component:q})})}}r.default=_,Object.defineProperties(r,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
1
+ (function(r,e){typeof exports=="object"&&typeof module!="undefined"?e(exports,require("@tachybase/client"),require("@tachybase/module-acl/client"),require("react/jsx-runtime"),require("react"),require("@tachybase/schema"),require("antd"),require("react-i18next"),require("@tachybase/utils/client")):typeof define=="function"&&define.amd?define(["exports","@tachybase/client","@tachybase/module-acl/client","react/jsx-runtime","react","@tachybase/schema","antd","react-i18next","@tachybase/utils/client"],e):(r=typeof globalThis!="undefined"?globalThis:r||self,e(r["@tachybase/module-user"]={},r["@tachybase/client"],r["@tachybase/module-acl"],r.jsxRuntime,r.react,r["@tachybase/schema"],r.antd,r["react-i18next"],r["@tachybase/utils"]))})(this,function(r,e,p,s,l,x,y,w,C){"use strict";var ae=Object.defineProperty,ce=Object.defineProperties;var ie=Object.getOwnPropertyDescriptors;var P=Object.getOwnPropertySymbols;var q=Object.prototype.hasOwnProperty,D=Object.prototype.propertyIsEnumerable;var U=(r,e,p)=>e in r?ae(r,e,{enumerable:!0,configurable:!0,writable:!0,value:p}):r[e]=p,h=(r,e)=>{for(var p in e||(e={}))q.call(e,p)&&U(r,p,e[p]);if(P)for(var p of P(e))D.call(e,p)&&U(r,p,e[p]);return r},f=(r,e)=>ce(r,ie(e));var M=(r,e)=>{var p={};for(var s in r)q.call(r,s)&&e.indexOf(s)<0&&(p[s]=r[s]);if(r!=null&&P)for(var s of P(r))e.indexOf(s)<0&&D.call(r,s)&&(p[s]=r[s]);return p};var g=(r,e,p)=>new Promise((s,l)=>{var x=C=>{try{w(p.next(C))}catch(v){l(v)}},y=C=>{try{w(p.throw(C))}catch(v){l(v)}},w=C=>C.done?s(C.value):Promise.resolve(C.value).then(x,y);w((p=p.apply(r,e)).next())});function v(){return w.useTranslation(["user","core"],{nsMode:"fallback"})}const b={name:"users",fields:[{name:"id",type:"bigInt",autoIncrement:!0,primaryKey:!0,allowNull:!1,uiSchema:{type:"number",title:'{{t("ID")}}',"x-component":"InputNumber","x-read-pretty":!0},interface:"id"},{interface:"input",type:"string",name:"nickname",uiSchema:{type:"string",title:'{{t("Nickname")}}',"x-component":"Input"}},{interface:"input",type:"string",name:"username",unique:!0,uiSchema:{type:"string",title:'{{t("Username")}}',"x-component":"Input","x-validator":{username:!0},required:!0}},{interface:"email",type:"string",name:"email",unique:!0,uiSchema:{type:"string",title:'{{t("Email")}}',"x-component":"Input","x-validator":"email",required:!0}},{interface:"phone",type:"string",name:"phone",unique:!0,uiSchema:{type:"string",title:'{{t("Phone")}}',"x-component":"Input","x-validator":"phone",required:!0}},{interface:"password",type:"password",name:"password",hidden:!0,uiSchema:{type:"string",title:'{{t("Password")}}',"x-component":"Password"}},{interface:"m2m",type:"belongsToMany",name:"roles",target:"roles",foreignKey:"userId",otherKey:"roleName",onDelete:"CASCADE",sourceKey:"id",targetKey:"name",through:"rolesUsers",uiSchema:{type:"array",title:'{{t("Roles")}}',"x-component":"AssociationField","x-component-props":{multiple:!0,fieldNames:{label:"title",value:"name"}}}}]},E={type:"void",properties:{block1:{type:"void","x-decorator":"TableBlockProvider","x-component":"CardItem","x-decorator-props":{collection:b,action:"list",params:{pageSize:50,appends:["roles"]}},properties:{actions:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:16}},properties:{filter:{type:"void",title:'{{ t("Filter") }}',"x-action":"filter","x-component":"Filter.Action","x-use-component-props":"useFilterActionProps","x-component-props":{icon:"FilterOutlined"},"x-align":"left"},delete:{type:"void",title:'{{ t("Delete") }}',"x-component":"Action","x-use-component-props":"useBulkDestroyActionProps","x-component-props":{confirm:{title:"{{t('Delete users')}}",content:"{{t('Are you sure you want to delete it?')}}"},icon:"DeleteOutlined"}},create:{type:"void","x-action":"create","x-acl-action":"create",title:"{{t('Add new')}}","x-component":"Action","x-decorator":"ACLActionProvider","x-component-props":{openMode:"drawer",type:"primary",component:"CreateRecordAction",icon:"PlusOutlined"},"x-align":"right","x-acl-action-props":{skipScopeCheck:!0},properties:{drawer:{type:"void",title:'{{ t("Add user") }}',"x-component":"Action.Container","x-component-props":{className:"tb-action-popup"},properties:{body:{type:"void","x-acl-action-props":{skipScopeCheck:!0},"x-acl-action":"users:create","x-decorator":"FormBlockProvider","x-use-decorator-props":"useCreateFormBlockDecoratorProps","x-decorator-props":{dataSource:"main",collection:b},"x-component":"CardItem",properties:{form:{type:"void","x-component":"FormV2","x-use-component-props":"useCreateFormBlockProps",properties:{actionBar:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:24}},properties:{cancel:{title:'{{ t("Cancel") }}',"x-component":"Action","x-use-component-props":"useCancelActionProps"},submit:{title:'{{ t("Submit") }}',"x-component":"Action","x-use-component-props":"useCreateActionProps","x-component-props":{type:"primary",htmlType:"submit"},"x-action-settings":{assignedValues:{},triggerWorkflows:[],pageMode:!1}}}},nickname:{"x-component":"CollectionField","x-decorator":"FormItem"},username:{"x-component":"CollectionField","x-decorator":"FormItem"},email:{title:'{{t("Email")}}',"x-component":"Input","x-validator":"email","x-decorator":"FormItem",required:!1},phone:{title:'{{t("Phone")}}',"x-component":"Input","x-validator":"phone","x-decorator":"FormItem",required:!1},password:{"x-component":"CollectionField","x-decorator":"FormItem",required:!0},roles:{"x-component":"CollectionField","x-collection-field":"users.roles","x-decorator":"FormItem"}}}}}}}}}}},table:{type:"array","x-uid":"input","x-component":"TableV2","x-use-component-props":"useTableBlockProps","x-component-props":{rowKey:"id",rowSelection:{type:"checkbox"}},properties:{column1:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{nickname:{type:"number","x-component":"CollectionField","x-read-pretty":!0}}},column2:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{username:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},column3:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{email:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},column4:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",title:'{{t("Roles")}}',properties:{roles:{type:"array","x-component":"UserRolesField"}}},column5:{type:"void",title:'{{t("Actions")}}',"x-component":"TableV2.Column",properties:{actions:{type:"void","x-component":"Space","x-component-props":{split:"|"},properties:{update:{type:"void",title:'{{t("Edit profile")}}',"x-decorator":"ACLActionProvider","x-acl-action":"users:update","x-component":"Action.Link","x-component-props":{type:"primary"},properties:{drawer:{type:"void","x-component":"Action.Drawer","x-decorator":"Form","x-decorator-props":{useValues:t=>{const o=e.useCollectionRecordData(),n=e.useRequest(()=>Promise.resolve({data:o}),f(h({},t),{manual:!0})),a=e.useActionContext();return l.useEffect(()=>{a.visible&&n.run()},[a.visible]),n}},title:'{{t("Edit profile")}}',properties:{actionBar:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:24}},properties:{cancel:{title:'{{ t("Cancel") }}',"x-component":"Action","x-use-component-props":"useCancelActionProps"},submit:{title:'{{ t("Submit") }}',"x-component":"Action","x-use-component-props":"useUpdateActionProps","x-component-props":{type:"primary"}}}},nickname:{"x-component":"CollectionField","x-decorator":"FormItem"},username:{"x-component":"CollectionField","x-decorator":"FormItem"},email:{title:'{{t("Email")}}',"x-component":"Input","x-validator":"email","x-decorator":"FormItem",required:!1},phone:{title:'{{t("Phone")}}',"x-component":"Input","x-validator":"phone","x-decorator":"FormItem",required:!1},roles:{"x-component":"CollectionField","x-decorator":"FormItem","x-collection-field":"users.roles"}}}}},changePassword:{type:"void",title:'{{ t("Change password") }}',"x-action":"update","x-component":"Action.Link","x-component-props":{openMode:"drawer"},"x-decorator":"ACLActionProvider",properties:{drawer:{type:"void",title:'{{ t("Change password") }}',"x-component":"Action.Container","x-component-props":{className:"tb-action-popup"},properties:{card:{type:"void","x-acl-action-props":{skipScopeCheck:!1},"x-acl-action":"users:update","x-decorator":"FormBlockProvider","x-use-decorator-props":"useEditFormBlockDecoratorProps","x-decorator-props":{action:"get",dataSource:"main",collection:b,params:{append:["password"]}},"x-component":"CardItem",properties:{form:{type:"void","x-component":"FormV2","x-use-component-props":"useEditFormBlockProps",properties:{actionBar:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:24}},properties:{cancel:{title:'{{ t("Cancel") }}',"x-component":"Action","x-use-component-props":"useCancelActionProps"},submit:{title:'{{ t("Submit") }}',"x-component":"Action","x-use-component-props":"useUpdateActionProps","x-component-props":{type:"primary"}}}},password:{"x-component":"CollectionField","x-component-props":{component:"PasswordField"},"x-decorator":"FormItem",required:!0}}}}}}}}},delete:{type:"void",title:'{{ t("Delete") }}',"x-acl-action":"users:destroy","x-action":"destroy","x-decorator":"ACLActionProvider","x-component":"Action.Link","x-use-component-props":"useDestroyActionProps","x-component-props":{confirm:{title:"{{t('Delete')}}",content:"{{t('Are you sure you want to delete it?')}}"}}}}}}}}}}}}},R=()=>({type:"void",properties:{[x.uid()]:{type:"void","x-decorator":"RoleUsersTableBlockProvider","x-component":"CardItem","x-use-decorator-props":"useRoleUsersServiceProps",properties:{actions:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:16}},properties:{[x.uid()]:{type:"void",title:'{{ t("Filter") }}',"x-action":"filter","x-component":"Filter.Action","x-use-component-props":"useFilterActionProps","x-component-props":{icon:"FilterOutlined"},"x-align":"left"},actions:{type:"void","x-component":"Space",properties:{remove:{type:"void",title:'{{t("Remove")}}',"x-component":"Action","x-use-component-props":"useBulkRemoveUsers","x-component-props":{icon:"MinusOutlined",confirm:{title:"{{t('Remove')}}",content:"{{t('Are you sure you want to remove these users?')}}"},style:{marginRight:8}}},create:{type:"void",title:'{{t("Add users")}}',"x-component":"Action","x-component-props":{type:"primary",icon:"PlusOutlined"},properties:{drawer:{type:"void","x-component":"Action.Drawer","x-decorator":"FormV2",title:'{{t("Add users")}}',properties:{resource:{type:"void","x-decorator":"TableBlockProvider","x-component":"CardItem","x-use-decorator-props":"useRoleUsersProps",properties:{actions:{type:"void","x-component":"ActionBar","x-component-props":{style:{marginBottom:16}},properties:{filter:{type:"void",title:'{{ t("Filter") }}',default:{$and:[{username:{$includes:""}},{nickname:{$includes:""}}]},"x-action":"filter","x-component":"Filter.Action","x-use-component-props":"useFilterActionProps","x-component-props":{icon:"FilterOutlined"},"x-align":"left"},cancel:{title:'{{ t("Cancel") }}',"x-component":"Action","x-use-component-props":"useCancelActionProps"},submit:{title:'{{ t("Submit") }}',"x-component":"Action","x-use-component-props":"useAddRoleUsers","x-component-props":{type:"primary",htmlType:"submit"}}}},table:{type:"array","x-component":"TableV2","x-use-component-props":"useTableBlockProps","x-component-props":{rowKey:"id",rowSelection:{type:"checkbox"}},properties:{username:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{username:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},nickname:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{nickname:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},phone:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{phone:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},email:{type:"void","x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{email:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}}}}}}}}}}}}}},table:{type:"array","x-component":"TableV2","x-use-component-props":"useTableBlockProps","x-component-props":{rowKey:"id",rowSelection:{type:"checkbox"}},properties:{username:{type:"void",title:'{{t("Username")}}',"x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{username:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},nickname:{type:"void",title:'{{t("Nickname")}}',"x-decorator":"TableV2.Column.Decorator","x-component":"TableV2.Column",properties:{nickname:{type:"string","x-component":"CollectionField","x-read-pretty":!0}}},actions:{type:"void",title:'{{t("Actions")}}',"x-component":"Table.Column",properties:{actions:{type:"void","x-component":"Space","x-component-props":{split:"|"},properties:{remove:{type:"void",title:'{{ t("Remove") }}',"x-component":"Action.Link","x-use-component-props":"useRemoveUser","x-component-props":{confirm:{title:"{{t('Remove user')}}",content:"{{t('Are you sure you want to remove it?')}}"}}}}}}}}}}}}}),O=()=>{var a,c;const t=l.useContext(e.CollectionContext),o=e.useFilterFieldOptions(t.fields),{service:n}=e.useTableBlockContext();return e.useFilterFieldProps({options:o,params:((c=(a=n.state)==null?void 0:a.params)==null?void 0:c[0])||n.params,service:n})},K=()=>{const t=e.useAPIClient(),{role:o}=l.useContext(p.RolesManagerContext),n=e.useCollectionRecordData(),{service:a}=e.useTableBlockContext();return{onClick(){return g(this,null,function*(){yield t.resource("roles.users",o==null?void 0:o.name).remove({values:[n.id]}),a==null||a.refresh()})}}},N=()=>{const{t}=v(),{message:o}=y.App.useApp(),n=e.useAPIClient(),{service:a,field:c}=e.useTableBlockContext(),{role:i}=l.useContext(p.RolesManagerContext);return{onClick(){return g(this,null,function*(){var d;const u=(d=c==null?void 0:c.data)==null?void 0:d.selectedRowKeys;if(!(u!=null&&u.length)){o.warning(t("Please select users"));return}yield n.resource("roles.users",i==null?void 0:i.name).remove({values:u}),c.data.selectedRowKeys=[],a==null||a.refresh()})}}},j=()=>{const{t}=v(),{role:o}=l.useContext(p.RolesManagerContext),{message:n}=y.App.useApp(),a=e.useAPIClient(),{setVisible:c}=e.useActionContext(),{field:i}=e.useTableBlockContext(),{__parent:m}=e.useBlockRequestContext();return{onClick(){return g(this,null,function*(){var A,F;const d=(A=i==null?void 0:i.data)==null?void 0:A.selectedRowKeys;if(!(d!=null&&d.length)){n.warning(t("Please select users"));return}yield a.resource("roles.users",o==null?void 0:o.name).add({values:d}),i.data.selectedRowKeys=[],c(!1),(F=m==null?void 0:m.props)==null||F.service.refresh()})}}},L=t=>{const{role:o}=l.useContext(p.RolesManagerContext);return f(h({},t),{collection:b,action:"listExcludeRole",params:{roleName:o==null?void 0:o.name}})},W=t=>{const{role:o}=l.useContext(p.RolesManagerContext),n=e.useRequest({resource:"roles.users",resourceOf:o==null?void 0:o.name,action:"list"},{ready:!!o});return f(h({},t),{service:n,collection:b,params:{pageSize:50}})},z=e.withDynamicSchemaProps(t=>{const V=t,{showIndex:o,dragSort:n,rowKey:a,fieldNames:c,collection:i,service:m}=V,u=M(V,["showIndex","dragSort","rowKey","fieldNames","collection","service"]),d=x.useField(),{role:A}=l.useContext(p.RolesManagerContext),F=e.useTableBlockParams(t);l.useEffect(()=>{m.run()},[A]);const k=x.useFieldSchema(),{treeTable:S}=(k==null?void 0:k["x-decorator-props"])||{},[T,ne]=l.useState(!!c);let I="children";if(i!=null&&i.tree&&S!==!1){const B=i.fields.find(pe=>pe.treeChildren);B&&(I=B.name),F.tree=!0}const se=l.useMemo(()=>x.createForm(),[S]);return s.jsx(e.SchemaComponentOptions,{scope:{treeTable:S},children:s.jsx(x.FormContext.Provider,{value:se,children:s.jsx(e.BlockProvider,f(h({name:t.name||"table"},t),{params:F,runWhenParamsChanged:!0,children:s.jsx(e.FixedBlockWrapper,{children:s.jsx(e.TableBlockContext.Provider,{value:f(h({},u),{field:d,service:m,params:F,showIndex:o,dragSort:n,rowKey:a,expandFlag:T,childrenColumnName:I,setExpandFlag:()=>ne(!T)}),children:s.jsx(e.RenderChildrenWithAssociationFilter,h({},t))})})}))})})}),$=()=>{const{t}=v(),{role:o}=l.useContext(p.RolesManagerContext),n=l.useMemo(()=>R(),[o]);return s.jsx(e.ExtendCollectionsProvider,{collections:[b],children:s.jsx(e.SchemaComponent,{schema:n,components:{RoleUsersTableBlockProvider:z},scope:{useBulkRemoveUsers:N,useRemoveUser:K,useAddRoleUsers:j,useRoleUsersProps:L,useFilterActionProps:O,useRoleUsersServiceProps:W,t}})})},G=()=>s.jsx(e.SchemaComponent,{schema:J,scope:{useSaveCurrentUserValues:H}}),H=()=>{const t=x.useForm(),o=e.useAPIClient(),{message:n}=y.App.useApp(),{t:a}=e.useTranslation();return{run(){return g(this,null,function*(){yield t.submit(),(yield o.resource("auth").changePassword({values:t.values})).status===200&&n.success(a("Edited successfully")),yield t.reset()})}}},J={type:"object",properties:{[C.uid()]:{type:"void","x-component":"CardItem","x-decorator":"Form",title:'{{t("Change password")}}',properties:{action:{type:"void",properties:{submit:{title:'{{t("Submit")}}',"x-component":"Action","x-component-props":{type:"primary",style:{left:"96%"},useAction:"{{ useSaveCurrentUserValues }}"}}}},oldPassword:{type:"string",title:'{{t("Old password")}}',required:!0,"x-component":"Password","x-decorator":"FormItem"},newPassword:{type:"string",title:'{{t("New password")}}',required:!0,"x-component":"Password","x-decorator":"FormItem","x-component-props":{checkStrength:!0,style:{}},"x-reactions":[{dependencies:[".confirmPassword"],fulfill:{state:{selfErrors:'{{$deps[0] && $self.value && $self.value !== $deps[0] ? t("Password mismatch") : ""}}'}}}]},confirmPassword:{type:"string",required:!0,title:'{{t("Confirm password")}}',"x-component":"Password","x-decorator":"FormItem","x-component-props":{checkStrength:!0,style:{}},"x-reactions":[{dependencies:[".newPassword"],fulfill:{state:{selfErrors:'{{$deps[0] && $self.value && $self.value !== $deps[0] ? t("Password mismatch") : ""}}'}}}]}}}}},Q=()=>s.jsx(e.SchemaComponent,{schema:Z,scope:{useCurrentUserValues:X,useSaveCurrentUserValues:Y}}),X=t=>{const o=e.useCurrentUserContext();return e.useRequest(()=>Promise.resolve(o.data),t)},Y=()=>{const t=e.useCurrentUserContext(),o=x.useForm(),n=e.useAPIClient(),{message:a}=y.App.useApp(),{t:c}=e.useTranslation();return{run(){return g(this,null,function*(){var d;const m=yield o.submit();(yield n.resource("users").updateProfile({values:m})).status===200&&a.success(c("Edited successfully")),t.mutate({data:h(h({},(d=t==null?void 0:t.data)==null?void 0:d.data),m)})})}}},Z={type:"object",properties:{[C.uid()]:{type:"void","x-component":"CardItem","x-decorator":"Form","x-decorator-props":{useValues:"{{useCurrentUserValues}}"},title:'{{t("Edit profile")}}',properties:{action:{type:"void",properties:{submit:{title:"Submit","x-component":"Action","x-component-props":{type:"primary",style:{left:"96%"},useAction:"{{ useSaveCurrentUserValues }}"}}}},nickname:{type:"string",title:"{{t('Nickname')}}","x-decorator":"FormItem","x-component":"Input"},username:{type:"string",title:'{{t("Username")}}',"x-decorator":"FormItem","x-component":"Input","x-validator":{username:!0},required:!0},email:{type:"string",title:'{{t("Email")}}',"x-decorator":"FormItem","x-component":"Input","x-validator":"email"},phone:{type:"string",title:'{{t("Phone")}}',"x-decorator":"FormItem","x-component":"Input","x-validator":"phone"}}}}},_=(t=10)=>{const o="ABCDEFGHIJKLMNOPQRSTUVWXYZ",n="abcdefghijklmnopqrstuvwxyz",a="0123456789",c="!#$%^&*-_+=",i=o+n+a+c,m=new Uint32Array(t);crypto.getRandomValues(m);let u="";u+=o.charAt(m[0]%o.length),u+=n.charAt(m[1]%n.length),u+=a.charAt(m[2]%a.length),u+=c.charAt(m[3]%c.length);for(let d=4;d<t;d++){const A=m[d]%i.length;u+=i.charAt(A)}return u=u[0]+u.slice(1).split("").sort(()=>Math.random()-.5).join(""),u},ee=()=>{const{t}=v(),o=x.useField(),[n,a]=l.useState(!1),c=e.useActionContext();return l.useEffect(()=>{c.visible||o.reset()},[o,c.visible]),s.jsxs(y.Row,{gutter:10,children:[s.jsx(y.Col,{span:18,children:s.jsx(e.Password,{checkStrength:!0,visibilityToggle:{visible:n,onVisibleChange:a},value:o.value,onChange:i=>o.setValue(i.target.value),autoComplete:"off"})}),s.jsx(y.Col,{span:4,children:s.jsx(y.Button,{onClick:()=>{o.setValue(_()),a(!0)},children:t("Random password")})})]})},oe=()=>{const{t}=v();return(x.useField().value||[]).map(n=>s.jsx(y.Tag,{children:x.Schema.compile(n.title,{t})},n.name))},te=()=>{const{t}=v(),o=e.useSchemaComponentContext();return s.jsx(e.SchemaComponentContext.Provider,{value:f(h({},o),{designable:!1}),children:s.jsx(e.SchemaComponent,{schema:E,scope:{t},components:{UserRolesField:oe,PasswordField:ee}})})};class re extends e.Plugin{load(){return g(this,null,function*(){this.app.systemSettingsManager.add("id-auth.users",{title:e.tval("Users"),icon:"UserOutlined",Component:te,aclSnippet:"pm.users"}),this.userSettingsManager.add("user-change-password",{icon:"LockOutlined",title:e.tval("Change password"),Component:G}),this.userSettingsManager.add("user-profile",{icon:"UserOutlined",title:e.tval("Edit profile"),Component:Q}),this.app.pm.get(p).rolesManager.add("users",{title:e.tval("Users"),Component:$})})}}r.default=re,Object.defineProperties(r,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
@@ -161,5 +161,6 @@ export declare const userCollection: {
161
161
  hidden?: undefined;
162
162
  })[];
163
163
  };
164
+ export declare const changePassword: ISchema;
164
165
  export declare const usersSchema: ISchema;
165
166
  export declare const getRoleUsersSchema: () => ISchema;
@@ -1,13 +1,13 @@
1
1
  module.exports = {
2
2
  "react": "18.3.1",
3
- "@tachybase/client": "0.23.20",
4
- "@tachybase/schema": "0.23.20",
3
+ "@tachybase/client": "0.23.35",
4
+ "@tachybase/schema": "0.23.35",
5
5
  "antd": "5.22.5",
6
- "@tachybase/module-acl": "0.23.20",
7
- "@tachybase/utils": "0.23.20",
6
+ "@tachybase/module-acl": "0.23.35",
7
+ "@tachybase/utils": "0.23.35",
8
8
  "react-i18next": "15.2.0",
9
- "@tachybase/cache": "0.23.20",
10
- "@tachybase/database": "0.23.20",
11
- "@tachybase/server": "0.23.20",
12
- "@tachybase/actions": "0.23.20"
9
+ "@tachybase/cache": "0.23.35",
10
+ "@tachybase/database": "0.23.35",
11
+ "@tachybase/server": "0.23.35",
12
+ "@tachybase/actions": "0.23.35"
13
13
  };
@@ -151,7 +151,7 @@ class PluginUsersServer extends import_server.Plugin {
151
151
  plugin: this
152
152
  }
153
153
  });
154
- if (import_worker_threads.isMainThread) {
154
+ if (!import_worker_threads.isMainThread) {
155
155
  return;
156
156
  }
157
157
  this.app.resourcer.use(
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tachybase/module-user",
3
3
  "displayName": "Users",
4
- "version": "0.23.20",
4
+ "version": "0.23.35",
5
5
  "description": "Provides basic user model, as well as created by and updated by fields.",
6
6
  "keywords": [
7
7
  "Users & permissions"
@@ -14,19 +14,19 @@
14
14
  "antd": "5.22.5",
15
15
  "jsonwebtoken": "^8.5.1",
16
16
  "react-i18next": "^15.2.0",
17
- "@tachybase/schema": "0.23.20"
17
+ "@tachybase/schema": "0.23.35"
18
18
  },
19
19
  "peerDependencies": {
20
- "@tachybase/actions": "0.23.20",
21
- "@tachybase/cache": "0.23.20",
22
- "@tachybase/client": "0.23.20",
23
- "@tachybase/database": "0.23.20",
24
- "@tachybase/module-acl": "0.23.20",
25
- "@tachybase/module-auth": "0.23.20",
26
- "@tachybase/resourcer": "0.23.20",
27
- "@tachybase/server": "0.23.20",
28
- "@tachybase/test": "0.23.20",
29
- "@tachybase/utils": "0.23.20"
20
+ "@tachybase/actions": "0.23.35",
21
+ "@tachybase/cache": "0.23.35",
22
+ "@tachybase/client": "0.23.35",
23
+ "@tachybase/module-acl": "0.23.35",
24
+ "@tachybase/database": "0.23.35",
25
+ "@tachybase/module-auth": "0.23.35",
26
+ "@tachybase/server": "0.23.35",
27
+ "@tachybase/resourcer": "0.23.35",
28
+ "@tachybase/test": "0.23.35",
29
+ "@tachybase/utils": "0.23.35"
30
30
  },
31
31
  "description.zh-CN": "提供了基础的用户模型,以及创建人和最后更新人字段。",
32
32
  "displayName.zh-CN": "用户",