@tachybase/plugin-sub-accounts 1.6.0 → 1.6.3

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,5 +1,5 @@
1
1
  module.exports = {
2
- "@tachybase/client": "1.6.0",
3
- "@tego/server": "1.3.52",
4
- "@tachybase/module-acl": "1.6.0"
2
+ "@tachybase/client": "1.6.3",
3
+ "@tego/server": "1.6.1",
4
+ "@tachybase/module-acl": "1.6.3"
5
5
  };
@@ -1 +1 @@
1
- {"author":"Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me)","name":"minimatch","description":"a glob matcher in javascript","publishConfig":{"tag":"legacy-v5"},"version":"5.1.6","repository":{"type":"git","url":"git://github.com/isaacs/minimatch.git"},"main":"minimatch.js","scripts":{"test":"tap","snap":"tap","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags"},"engines":{"node":">=10"},"dependencies":{"brace-expansion":"^2.0.1"},"devDependencies":{"tap":"^16.3.2"},"license":"ISC","files":["minimatch.js","lib"],"_lastModified":"2025-11-20T08:15:34.660Z"}
1
+ {"author":"Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me)","name":"minimatch","description":"a glob matcher in javascript","publishConfig":{"tag":"legacy-v5"},"version":"5.1.6","repository":{"type":"git","url":"git://github.com/isaacs/minimatch.git"},"main":"minimatch.js","scripts":{"test":"tap","snap":"tap","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags"},"engines":{"node":">=10"},"dependencies":{"brace-expansion":"^2.0.1"},"devDependencies":{"tap":"^16.3.2"},"license":"ISC","files":["minimatch.js","lib"],"_lastModified":"2025-12-26T04:47:16.373Z"}
@@ -42,7 +42,7 @@ async function changeUserRolesMiddleware(ctx, next) {
42
42
  if (!selfRole) {
43
43
  continue;
44
44
  }
45
- await selfRole.resetAcl({ acl: ctx.app.acl });
45
+ await selfRole.resetAcl({ acl: ctx.tego.acl });
46
46
  }
47
47
  } else if (associatedName === "roles" && resourceName === "menuUiSchemas" && ["add", "remove", "set"].includes(actionName)) {
48
48
  const affectedUsers = await ctx.db.getRepository("users").find({
@@ -56,7 +56,7 @@ async function changeUserRolesMiddleware(ctx, next) {
56
56
  }
57
57
  const affectedRoles = affectedUsers.map((u) => u.selfRole);
58
58
  for (const affectedRole of affectedRoles) {
59
- await affectedRole.resetAcl({ acl: ctx.app.acl, changedFields: ["menuUiSchemas"] });
59
+ await affectedRole.resetAcl({ acl: ctx.tego.acl, changedFields: ["menuUiSchemas"] });
60
60
  }
61
61
  }
62
62
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tachybase/plugin-sub-accounts",
3
3
  "displayName": "sub-accounts",
4
- "version": "1.6.0",
4
+ "version": "1.6.3",
5
5
  "description": "Generates synthetic roles, each user can create their own sub-accounts (unfinished)",
6
6
  "keywords": [
7
7
  "Users & permissions"
@@ -9,12 +9,12 @@
9
9
  "main": "dist/server/index.js",
10
10
  "dependencies": {},
11
11
  "devDependencies": {
12
- "@tachybase/test": "1.3.52",
13
- "@tego/client": "1.3.52",
14
- "@tego/server": "1.3.52",
12
+ "@tachybase/test": "1.6.1",
13
+ "@tego/client": "1.6.1",
14
+ "@tego/server": "1.6.1",
15
15
  "minimatch": "^5.1.6",
16
- "@tachybase/client": "1.6.0",
17
- "@tachybase/module-acl": "1.6.0"
16
+ "@tachybase/client": "1.6.3",
17
+ "@tachybase/module-acl": "1.6.3"
18
18
  },
19
19
  "description.zh-CN": "生成合成角色,每个用户可以生成自己的子账户(未完成)",
20
20
  "displayName.zh-CN": "子账户和合成角色",