@tachybase/module-user 1.6.25 → 1.6.26

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,9 +1,9 @@
1
1
  module.exports = {
2
2
  "react": "18.3.1",
3
- "@tachybase/client": "1.6.25",
3
+ "@tachybase/client": "1.6.26",
4
4
  "@tachybase/schema": "1.6.16",
5
5
  "antd": "5.22.5",
6
- "@tachybase/module-acl": "1.6.25",
6
+ "@tachybase/module-acl": "1.6.26",
7
7
  "@tego/client": "1.6.16",
8
8
  "react-i18next": "16.2.1",
9
9
  "@tego/server": "1.6.16"
@@ -115,6 +115,17 @@ class PluginUsersServer extends import_server.Plugin {
115
115
  targetKey: "id"
116
116
  });
117
117
  }
118
+ const tenantPlugin = this.app.pm.get("tenant");
119
+ if ((tenantPlugin == null ? void 0 : tenantPlugin.enabled) && (collection.options.tenancy === "tenantScoped" || collection.options.tenancy === "tenantInherited")) {
120
+ collection.setField("tenantId", {
121
+ type: "context",
122
+ dataIndex: "state.currentTenant.id",
123
+ dataType: "string",
124
+ createOnly: true,
125
+ visible: true,
126
+ index: true
127
+ });
128
+ }
118
129
  });
119
130
  for (const [key, action] of Object.entries(actions)) {
120
131
  this.app.resourcer.registerActionHandler(`users:${key}`, action);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tachybase/module-user",
3
3
  "displayName": "Users",
4
- "version": "1.6.25",
4
+ "version": "1.6.26",
5
5
  "description": "Provides basic user model, as well as created by and updated by fields.",
6
6
  "keywords": [
7
7
  "Users & permissions"
@@ -27,9 +27,9 @@
27
27
  "antd": "5.22.5",
28
28
  "jsonwebtoken": "^8.5.1",
29
29
  "react-i18next": "16.2.1",
30
- "@tachybase/client": "1.6.25",
31
- "@tachybase/module-acl": "1.6.25",
32
- "@tachybase/module-auth": "1.6.25"
30
+ "@tachybase/client": "1.6.26",
31
+ "@tachybase/module-acl": "1.6.26",
32
+ "@tachybase/module-auth": "1.6.26"
33
33
  },
34
34
  "description.zh-CN": "提供了基础的用户模型,以及创建人和最后更新人字段。",
35
35
  "displayName.zh-CN": "用户",