@nocobase/plugin-multi-portal 2.2.0-alpha.11 → 2.2.0-alpha.12

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.
@@ -10,6 +10,7 @@ import React from 'react';
10
10
  interface Role {
11
11
  name: string;
12
12
  title: string;
13
+ allowNewMenu?: boolean;
13
14
  allowNewMultiPortal?: boolean;
14
15
  }
15
16
  interface PermissionTabProps {
@@ -6,6 +6,9 @@
6
6
  * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
7
  * For more information, please refer to: https://www.nocobase.com/agreement.
8
8
  */
9
+ export type MultiPortalRouteScopeDescriptor = {
10
+ cacheKey: string;
11
+ portalUid: string;
12
+ };
9
13
  export declare function getMultiPortalRouteScopeCacheKey(portalUid: string): string;
10
- export declare function getMultiPortalUidFromRouteScopeCacheKey(cacheKey: string): string;
11
- export declare function installMultiPortalRouteRepositoryScope(routeRepository: unknown, portalUids: () => string[]): void;
14
+ export declare function installMultiPortalRouteRepositoryScope(routeRepository: unknown, portalScopes: () => MultiPortalRouteScopeDescriptor[]): void;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ export declare const DEFAULT_ADMIN_MULTI_PORTAL_UID = "__default_admin__";
10
+ export declare const DEFAULT_MOBILE_MULTI_PORTAL_UID = "__default_mobile__";
11
+ export declare function isDefaultLayoutMultiPortalUid(uid: unknown): uid is string;
@@ -0,0 +1,48 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+
10
+ var __defProp = Object.defineProperty;
11
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
12
+ var __getOwnPropNames = Object.getOwnPropertyNames;
13
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
14
+ var __export = (target, all) => {
15
+ for (var name in all)
16
+ __defProp(target, name, { get: all[name], enumerable: true });
17
+ };
18
+ var __copyProps = (to, from, except, desc) => {
19
+ if (from && typeof from === "object" || typeof from === "function") {
20
+ for (let key of __getOwnPropNames(from))
21
+ if (!__hasOwnProp.call(to, key) && key !== except)
22
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
23
+ }
24
+ return to;
25
+ };
26
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
27
+ var constants_exports = {};
28
+ __export(constants_exports, {
29
+ DEFAULT_ADMIN_MULTI_PORTAL_UID: () => DEFAULT_ADMIN_MULTI_PORTAL_UID,
30
+ DEFAULT_MOBILE_MULTI_PORTAL_UID: () => DEFAULT_MOBILE_MULTI_PORTAL_UID,
31
+ isDefaultLayoutMultiPortalUid: () => isDefaultLayoutMultiPortalUid
32
+ });
33
+ module.exports = __toCommonJS(constants_exports);
34
+ const DEFAULT_ADMIN_MULTI_PORTAL_UID = "__default_admin__";
35
+ const DEFAULT_MOBILE_MULTI_PORTAL_UID = "__default_mobile__";
36
+ const DEFAULT_LAYOUT_MULTI_PORTAL_UIDS = /* @__PURE__ */ new Set([
37
+ DEFAULT_ADMIN_MULTI_PORTAL_UID,
38
+ DEFAULT_MOBILE_MULTI_PORTAL_UID
39
+ ]);
40
+ function isDefaultLayoutMultiPortalUid(uid) {
41
+ return typeof uid === "string" && DEFAULT_LAYOUT_MULTI_PORTAL_UIDS.has(uid);
42
+ }
43
+ // Annotate the CommonJS export names for ESM import in node:
44
+ 0 && (module.exports = {
45
+ DEFAULT_ADMIN_MULTI_PORTAL_UID,
46
+ DEFAULT_MOBILE_MULTI_PORTAL_UID,
47
+ isDefaultLayoutMultiPortalUid
48
+ });
@@ -8,18 +8,19 @@
8
8
  */
9
9
 
10
10
  module.exports = {
11
- "@nocobase/flow-engine": "2.2.0-alpha.11",
12
- "@nocobase/client": "2.2.0-alpha.11",
13
- "@nocobase/client-v2": "2.2.0-alpha.11",
14
- "@nocobase/database": "2.2.0-alpha.11",
15
- "@nocobase/server": "2.2.0-alpha.11",
16
- "@nocobase/resourcer": "2.2.0-alpha.11",
17
- "@nocobase/utils": "2.2.0-alpha.11",
11
+ "@nocobase/flow-engine": "2.2.0-alpha.12",
12
+ "@nocobase/client": "2.2.0-alpha.12",
13
+ "@nocobase/client-v2": "2.2.0-alpha.12",
18
14
  "antd": "5.24.2",
15
+ "react": "18.2.0",
16
+ "react-router-dom": "6.30.1",
17
+ "@nocobase/database": "2.2.0-alpha.12",
18
+ "@nocobase/server": "2.2.0-alpha.12",
19
+ "@nocobase/resourcer": "2.2.0-alpha.12",
20
+ "@nocobase/utils": "2.2.0-alpha.12",
19
21
  "ahooks": "3.7.8",
20
22
  "antd-style": "3.7.1",
21
- "react": "18.2.0",
22
- "@nocobase/plugin-ui-layout": "2.2.0-alpha.11",
23
+ "@nocobase/plugin-ui-layout": "2.2.0-alpha.12",
23
24
  "@ant-design/icons": "5.6.1",
24
25
  "sequelize": "6.35.2"
25
26
  };
@@ -38,6 +38,7 @@
38
38
  "Must start with /. For example: /portal.": "Must start with /. For example: /portal.",
39
39
  "No matching routes": "No matching routes",
40
40
  "No portals": "No portals",
41
+ "No accessible portals": "No accessible portals",
41
42
  "No routes": "No routes",
42
43
  "Failed to load portals": "Failed to load portals",
43
44
  "Failed to save portal": "Failed to save portal",
@@ -78,5 +79,55 @@
78
79
  "UID": "UID",
79
80
  "Updated successfully": "Updated successfully",
80
81
  "View": "View",
81
- "When disabled, this portal will not be registered or accessible.": "When disabled, this portal will not be registered or accessible."
82
+ "When disabled, this portal will not be registered or accessible.": "When disabled, this portal will not be registered or accessible.",
83
+ "Add child": "Add child",
84
+ "Add child route": "Add child route",
85
+ "Add child {{route}}": "Add child {{route}}",
86
+ "Add new": "Add new",
87
+ "Add parameter": "Add parameter",
88
+ "Delete route": "Delete route",
89
+ "Delete routes": "Delete routes",
90
+ "Delete {{route}}": "Delete {{route}}",
91
+ "Deleted successfully": "Deleted successfully",
92
+ "Do not concatenate search params in the URL": "Do not concatenate search params in the URL",
93
+ "Edit route": "Edit route",
94
+ "Edit {{route}}": "Edit {{route}}",
95
+ "Enable page tabs": "Enable page tabs",
96
+ "Filter": "Filter",
97
+ "Group": "Group",
98
+ "Hidden": "Hidden",
99
+ "Hide in menu": "Hide in menu",
100
+ "Icon field is required": "Icon field is required",
101
+ "If selected, the page will display Tab pages.": "If selected, the page will display Tab pages.",
102
+ "If selected, the route will be displayed in the menu.": "If selected, the route will be displayed in the menu.",
103
+ "Link": "Link",
104
+ "Managed by layout permissions": "Managed by layout permissions",
105
+ "Name": "Name",
106
+ "Page": "Page",
107
+ "Path": "Path",
108
+ "Routes": "Routes",
109
+ "Search parameters": "Search parameters",
110
+ "Show in menu": "Show in menu",
111
+ "Shown": "Shown",
112
+ "Tab": "Tab",
113
+ "Type": "Type",
114
+ "URL": "URL",
115
+ "URL field is required": "URL field is required",
116
+ "Untitled": "Untitled",
117
+ "Value": "Value",
118
+ "View {{route}}": "View {{route}}",
119
+ "No-code": "No-code mode",
120
+ "AI": "AI mode",
121
+ "Default": "Default",
122
+ "No portals yet": "No portals yet",
123
+ "Each portal is a standalone front end with its own routes and menus.": "Each portal is a standalone front end with its own routes and menus.",
124
+ "Cover": "Cover",
125
+ "Upload cover": "Upload cover",
126
+ "Replace cover": "Replace cover",
127
+ "Used as the cover placeholder when no cover is uploaded.": "Used as the cover placeholder when no cover is uploaded.",
128
+ "Used in the access path.": "Used in the access path.",
129
+ "Shown on the portal card. A 16:9 image works best.": "Shown on the portal card. A 16:9 image works best.",
130
+ "Device": "Device",
131
+ "No-code portals render with the components of this device; AI portals use it for grouping.": "No-code portals render with the components of this device; AI portals use it for grouping.",
132
+ "The title and name below are filled in from the repository name.": "The title and name below are filled in from the repository name."
82
133
  }
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "Access path": "访问路径",
3
3
  "Actions": "操作",
4
- "Add Multi-portal": "新增 Portal",
5
- "Add portal": "新增 Portal",
4
+ "Add Multi-portal": "新增门户",
5
+ "Add portal": "新增门户",
6
6
  "Allow access": "允许访问",
7
7
  "Allow access to {{portal}}": "允许访问 {{portal}}",
8
8
  "Access path cannot be /": "访问路径不能是 /",
@@ -11,53 +11,54 @@
11
11
  "Access path cannot contain wildcard": "访问路径不能包含通配符",
12
12
  "Access path can only contain letters, numbers, hyphens, underscores, and slashes": "访问路径只能包含英文字母、数字、连字符、下划线和斜杠",
13
13
  "Access path must start with /": "访问路径必须以 / 开头",
14
- "AI portal": "AI Portal",
14
+ "AI portal": "AI 门户",
15
15
  "Are you sure you want to delete it?": "确定要删除吗?",
16
- "Are you sure you want to delete the selected Multi-portal records?": "确定要删除选中的 Portal 记录吗?",
16
+ "Are you sure you want to delete the selected Multi-portal records?": "确定要删除选中的门户记录吗?",
17
17
  "Cancel": "取消",
18
18
  "Delete": "删除",
19
- "Delete Multi-portal": "删除 Portal",
20
- "Delete portal": "删除 Portal",
19
+ "Delete Multi-portal": "删除门户",
20
+ "Delete portal": "删除门户",
21
21
  "Desktop": "桌面端",
22
- "Portal type": "Portal 类型",
22
+ "Portal type": "门户类型",
23
23
  "Edit": "编辑",
24
- "Edit Multi-portal": "编辑 Portal",
25
- "Edit portal": "编辑 Portal",
24
+ "Edit Multi-portal": "编辑门户",
25
+ "Edit portal": "编辑门户",
26
26
  "Enabled": "启用",
27
27
  "Configure": "配置",
28
28
  "Configure routes permissions for {{portal}}": "配置 {{portal}} 的路由权限",
29
- "Custom portals": "Portal",
29
+ "Custom portals": "门户",
30
30
  "Failed to load routes": "加载路由失败",
31
31
  "Layout": "布局",
32
32
  "Main application": "主应用",
33
33
  "Routes permissions": "路由权限",
34
- "Multi-portal": "Portal 管理",
34
+ "Multi-portal": "门户管理",
35
35
  "Mobile": "移动端",
36
- "New portals are allowed to be accessed by default": "新建 Portal 默认允许访问",
36
+ "New portals are allowed to be accessed by default": "新建门户默认允许访问",
37
37
  "New routes are allowed to be accessed by default": "新建路由默认允许访问",
38
- "Must start with /. For example: /portal.": "必须以 / 开头,例如 /portal。",
38
+ "Must start with /. For example: /portal.": "必须以 / 开头,例如 /门户。",
39
39
  "No matching routes": "无匹配路由",
40
- "No portals": "暂无 Portal",
40
+ "No portals": "暂无门户",
41
+ "No accessible portals": "暂无可访问的门户",
41
42
  "No routes": "暂无路由",
42
- "Failed to load portals": "加载 Portal 失败",
43
- "Failed to save portal": "保存 Portal 失败",
43
+ "Failed to load portals": "加载门户失败",
44
+ "Failed to save portal": "保存门户失败",
44
45
  "Create with AI Agent and code. Users can request changes in natural language. Path: /x/<name>": "通过 AI Agent 和代码创建,可用自然语言提出修改要求。访问路径:/x/<name>",
45
46
  "Create with visual configuration. AI can help adjust the configuration. Path: /v/<name>": "通过可视化配置创建,AI 可以协助调整配置。访问路径:/v/<name>",
46
- "Directory inside the Git repository for this portal. Leave empty for the root.": " Portal 在 Git 仓库内的目录,留空表示仓库根目录。",
47
+ "Directory inside the Git repository for this portal. Leave empty for the root.": "该门户在 Git 仓库内的目录,留空表示仓库根目录。",
47
48
  "Git": "Git",
48
49
  "Git branch": "Git 分支",
49
50
  "Git path": "Git 路径",
50
51
  "Git repository URL": "Git 仓库 URL",
51
52
  "Icon": "图标",
52
- "Manage portal source code in a Git repository.": "在 Git 仓库中管理 Portal 源码。",
53
- "Manage portal source code in NocoBase.": "在 NocoBase 中管理 Portal 源码。",
53
+ "Manage portal source code in a Git repository.": "在 Git 仓库中管理门户源码。",
54
+ "Manage portal source code in NocoBase.": "在 NocoBase 中管理门户源码。",
54
55
  "NocoBase": "NocoBase",
55
- "Portal": "Portal",
56
- "No-code portal": "无代码 Portal",
57
- "Portal manager": "Portal 管理",
58
- "Portal name": "Portal 名称",
59
- "Portal name can only contain lowercase letters, numbers, hyphens, and underscores": "Portal 名称只能包含小写英文字母、数字、连字符和下划线",
60
- "Portals": "Portal",
56
+ "Portal": "门户",
57
+ "No-code portal": "无代码门户",
58
+ "Portal manager": "门户管理",
59
+ "Portal name": "门户名称",
60
+ "Portal name can only contain lowercase letters, numbers, hyphens, and underscores": "门户名称只能包含小写英文字母、数字、连字符和下划线",
61
+ "Portals": "门户",
61
62
  "Refresh": "刷新",
62
63
  "Route name cannot contain dots": "路由名称不能包含点号",
63
64
  "Route name can only contain letters, numbers, hyphens, and underscores": "路由名称只能包含英文字母、数字、连字符和下划线",
@@ -68,8 +69,8 @@
68
69
  "Select a role to configure permissions": "请选择角色后配置权限",
69
70
  "Source storage": "源码存储",
70
71
  "Submit": "提交",
71
- "Target portal": "目标 Portal",
72
- "The corresponding portal directory will also be deleted.": "对应的 Portal 目录也会被删除。",
72
+ "Target portal": "目标门户",
73
+ "The corresponding portal directory will also be deleted.": "对应的门户目录也会被删除。",
73
74
  "This entry is currently unavailable. Please check the application status.": "当前不可用,请检查应用状态。",
74
75
  "This entry is no longer available. Please remove this button.": "该入口当前不可用,请移除此按钮。",
75
76
  "Title": "标题",
@@ -78,5 +79,55 @@
78
79
  "UID": "UID",
79
80
  "Updated successfully": "更新成功",
80
81
  "View": "查看",
81
- "When disabled, this portal will not be registered or accessible.": "关闭后,该 Portal 将不会注册,也无法访问。"
82
+ "When disabled, this portal will not be registered or accessible.": "关闭后,该门户将不会注册,也无法访问。",
83
+ "Add child": "新增子项",
84
+ "Add child route": "新增子路由",
85
+ "Add child {{route}}": "新增子路由 {{route}}",
86
+ "Add new": "新增",
87
+ "Add parameter": "新增参数",
88
+ "Delete route": "删除路由",
89
+ "Delete routes": "删除路由",
90
+ "Delete {{route}}": "删除 {{route}}",
91
+ "Deleted successfully": "删除成功",
92
+ "Do not concatenate search params in the URL": "不要在 URL 中拼接查询参数",
93
+ "Edit route": "编辑路由",
94
+ "Edit {{route}}": "编辑 {{route}}",
95
+ "Enable page tabs": "启用页面标签页",
96
+ "Filter": "筛选",
97
+ "Group": "分组",
98
+ "Hidden": "已隐藏",
99
+ "Hide in menu": "在菜单中隐藏",
100
+ "Icon field is required": "图标字段为必填项",
101
+ "If selected, the page will display Tab pages.": "勾选后,页面将显示标签页。",
102
+ "If selected, the route will be displayed in the menu.": "勾选后,路由会在菜单中显示。",
103
+ "Link": "链接",
104
+ "Managed by layout permissions": "沿用布局权限",
105
+ "Name": "名称",
106
+ "Page": "页面",
107
+ "Path": "路径",
108
+ "Routes": "路由",
109
+ "Search parameters": "查询参数",
110
+ "Show in menu": "在菜单中显示",
111
+ "Shown": "已显示",
112
+ "Tab": "标签页",
113
+ "Type": "类型",
114
+ "URL": "URL",
115
+ "URL field is required": "URL 字段为必填项",
116
+ "Untitled": "未设置标题",
117
+ "Value": "值",
118
+ "View {{route}}": "查看 {{route}}",
119
+ "No-code": "无代码模式",
120
+ "AI": "AI 模式",
121
+ "Default": "默认",
122
+ "No portals yet": "还没有门户",
123
+ "Each portal is a standalone front end with its own routes and menus.": "每个门户是一套独立的前台,有自己的路由和菜单。",
124
+ "Cover": "封面",
125
+ "Upload cover": "上传封面",
126
+ "Replace cover": "更换封面",
127
+ "Used as the cover placeholder when no cover is uploaded.": "没有上传封面时,用它作为封面占位。",
128
+ "Used in the access path.": "用于访问路径。",
129
+ "Shown on the portal card. A 16:9 image works best.": "显示在门户卡片上,建议使用 16:9 的图片。",
130
+ "Device": "设备",
131
+ "No-code portals render with the components of this device; AI portals use it for grouping.": "无代码门户按此选择组件形态;AI 门户用它做归类。",
132
+ "The title and name below are filled in from the repository name.": "下面的标题和名称会按仓库名自动填写。"
82
133
  }
@@ -1 +1 @@
1
- {"author":"Isaac Z. Schlueter","name":"tar","description":"tar for node","version":"7.5.15","repository":{"type":"git","url":"https://github.com/isaacs/node-tar.git"},"scripts":{"genparse":"node scripts/generate-parse-fixtures.js","snap":"tap","test":"tap","pretest":"npm run prepare","presnap":"npm run prepare","prepare":"tshy && bash scripts/build.sh","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags","format":"prettier --write . --log-level warn","typedoc":"typedoc --tsconfig .tshy/esm.json ./src/*.ts","lint":"oxlint --fix src test","postsnap":"npm run lint","postlint":"npm run format"},"dependencies":{"@isaacs/fs-minipass":"^4.0.0","chownr":"^3.0.0","minipass":"^7.1.2","minizlib":"^3.1.0","yallist":"^5.0.0"},"devDependencies":{"@types/node":"^25.5.0","chmodr":"^2.0.2","end-of-stream":"^1.4.3","esbuild":"^0.27.4","events-to-array":"^2.0.3","mutate-fs":"^2.1.1","nock":"^13.5.4","oxlint":"^1.57.0","oxlint-tsgolint":"^0.17.3","prettier":"^3.8.1","rimraf":"^6.1.2","tap":"^21.6.2","tshy":"^3.3.2","typedoc":"^0.28.18"},"license":"BlueOak-1.0.0","engines":{"node":">=18"},"files":["dist"],"tshy":{"exports":{"./package.json":"./package.json",".":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.min.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.min.js"}},"./raw":"./src/index.ts","./c":"./src/create.ts","./create":"./src/create.ts","./replace":"./src/create.ts","./r":"./src/create.ts","./list":"./src/list.ts","./t":"./src/list.ts","./update":"./src/update.ts","./u":"./src/update.ts","./extract":"./src/extract.ts","./x":"./src/extract.ts","./pack":"./src/pack.ts","./unpack":"./src/unpack.ts","./parse":"./src/parse.ts","./read-entry":"./src/read-entry.ts","./write-entry":"./src/write-entry.ts","./header":"./src/header.ts","./pax":"./src/pax.ts","./types":"./src/types.ts"}},"exports":{"./package.json":"./package.json",".":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.min.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.min.js"}},"./raw":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.js"}},"./c":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./create":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./replace":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./r":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./list":{"import":{"types":"./dist/esm/list.d.ts","default":"./dist/esm/list.js"},"require":{"types":"./dist/commonjs/list.d.ts","default":"./dist/commonjs/list.js"}},"./t":{"import":{"types":"./dist/esm/list.d.ts","default":"./dist/esm/list.js"},"require":{"types":"./dist/commonjs/list.d.ts","default":"./dist/commonjs/list.js"}},"./update":{"import":{"types":"./dist/esm/update.d.ts","default":"./dist/esm/update.js"},"require":{"types":"./dist/commonjs/update.d.ts","default":"./dist/commonjs/update.js"}},"./u":{"import":{"types":"./dist/esm/update.d.ts","default":"./dist/esm/update.js"},"require":{"types":"./dist/commonjs/update.d.ts","default":"./dist/commonjs/update.js"}},"./extract":{"import":{"types":"./dist/esm/extract.d.ts","default":"./dist/esm/extract.js"},"require":{"types":"./dist/commonjs/extract.d.ts","default":"./dist/commonjs/extract.js"}},"./x":{"import":{"types":"./dist/esm/extract.d.ts","default":"./dist/esm/extract.js"},"require":{"types":"./dist/commonjs/extract.d.ts","default":"./dist/commonjs/extract.js"}},"./pack":{"import":{"types":"./dist/esm/pack.d.ts","default":"./dist/esm/pack.js"},"require":{"types":"./dist/commonjs/pack.d.ts","default":"./dist/commonjs/pack.js"}},"./unpack":{"import":{"types":"./dist/esm/unpack.d.ts","default":"./dist/esm/unpack.js"},"require":{"types":"./dist/commonjs/unpack.d.ts","default":"./dist/commonjs/unpack.js"}},"./parse":{"import":{"types":"./dist/esm/parse.d.ts","default":"./dist/esm/parse.js"},"require":{"types":"./dist/commonjs/parse.d.ts","default":"./dist/commonjs/parse.js"}},"./read-entry":{"import":{"types":"./dist/esm/read-entry.d.ts","default":"./dist/esm/read-entry.js"},"require":{"types":"./dist/commonjs/read-entry.d.ts","default":"./dist/commonjs/read-entry.js"}},"./write-entry":{"import":{"types":"./dist/esm/write-entry.d.ts","default":"./dist/esm/write-entry.js"},"require":{"types":"./dist/commonjs/write-entry.d.ts","default":"./dist/commonjs/write-entry.js"}},"./header":{"import":{"types":"./dist/esm/header.d.ts","default":"./dist/esm/header.js"},"require":{"types":"./dist/commonjs/header.d.ts","default":"./dist/commonjs/header.js"}},"./pax":{"import":{"types":"./dist/esm/pax.d.ts","default":"./dist/esm/pax.js"},"require":{"types":"./dist/commonjs/pax.d.ts","default":"./dist/commonjs/pax.js"}},"./types":{"import":{"types":"./dist/esm/types.d.ts","default":"./dist/esm/types.js"},"require":{"types":"./dist/commonjs/types.d.ts","default":"./dist/commonjs/types.js"}}},"type":"module","main":"./dist/commonjs/index.min.js","types":"./dist/commonjs/index.d.ts","module":"./dist/esm/index.min.js","_lastModified":"2026-07-28T07:40:30.166Z"}
1
+ {"author":"Isaac Z. Schlueter","name":"tar","description":"tar for node","version":"7.5.15","repository":{"type":"git","url":"https://github.com/isaacs/node-tar.git"},"scripts":{"genparse":"node scripts/generate-parse-fixtures.js","snap":"tap","test":"tap","pretest":"npm run prepare","presnap":"npm run prepare","prepare":"tshy && bash scripts/build.sh","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags","format":"prettier --write . --log-level warn","typedoc":"typedoc --tsconfig .tshy/esm.json ./src/*.ts","lint":"oxlint --fix src test","postsnap":"npm run lint","postlint":"npm run format"},"dependencies":{"@isaacs/fs-minipass":"^4.0.0","chownr":"^3.0.0","minipass":"^7.1.2","minizlib":"^3.1.0","yallist":"^5.0.0"},"devDependencies":{"@types/node":"^25.5.0","chmodr":"^2.0.2","end-of-stream":"^1.4.3","esbuild":"^0.27.4","events-to-array":"^2.0.3","mutate-fs":"^2.1.1","nock":"^13.5.4","oxlint":"^1.57.0","oxlint-tsgolint":"^0.17.3","prettier":"^3.8.1","rimraf":"^6.1.2","tap":"^21.6.2","tshy":"^3.3.2","typedoc":"^0.28.18"},"license":"BlueOak-1.0.0","engines":{"node":">=18"},"files":["dist"],"tshy":{"exports":{"./package.json":"./package.json",".":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.min.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.min.js"}},"./raw":"./src/index.ts","./c":"./src/create.ts","./create":"./src/create.ts","./replace":"./src/create.ts","./r":"./src/create.ts","./list":"./src/list.ts","./t":"./src/list.ts","./update":"./src/update.ts","./u":"./src/update.ts","./extract":"./src/extract.ts","./x":"./src/extract.ts","./pack":"./src/pack.ts","./unpack":"./src/unpack.ts","./parse":"./src/parse.ts","./read-entry":"./src/read-entry.ts","./write-entry":"./src/write-entry.ts","./header":"./src/header.ts","./pax":"./src/pax.ts","./types":"./src/types.ts"}},"exports":{"./package.json":"./package.json",".":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.min.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.min.js"}},"./raw":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.js"}},"./c":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./create":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./replace":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./r":{"import":{"types":"./dist/esm/create.d.ts","default":"./dist/esm/create.js"},"require":{"types":"./dist/commonjs/create.d.ts","default":"./dist/commonjs/create.js"}},"./list":{"import":{"types":"./dist/esm/list.d.ts","default":"./dist/esm/list.js"},"require":{"types":"./dist/commonjs/list.d.ts","default":"./dist/commonjs/list.js"}},"./t":{"import":{"types":"./dist/esm/list.d.ts","default":"./dist/esm/list.js"},"require":{"types":"./dist/commonjs/list.d.ts","default":"./dist/commonjs/list.js"}},"./update":{"import":{"types":"./dist/esm/update.d.ts","default":"./dist/esm/update.js"},"require":{"types":"./dist/commonjs/update.d.ts","default":"./dist/commonjs/update.js"}},"./u":{"import":{"types":"./dist/esm/update.d.ts","default":"./dist/esm/update.js"},"require":{"types":"./dist/commonjs/update.d.ts","default":"./dist/commonjs/update.js"}},"./extract":{"import":{"types":"./dist/esm/extract.d.ts","default":"./dist/esm/extract.js"},"require":{"types":"./dist/commonjs/extract.d.ts","default":"./dist/commonjs/extract.js"}},"./x":{"import":{"types":"./dist/esm/extract.d.ts","default":"./dist/esm/extract.js"},"require":{"types":"./dist/commonjs/extract.d.ts","default":"./dist/commonjs/extract.js"}},"./pack":{"import":{"types":"./dist/esm/pack.d.ts","default":"./dist/esm/pack.js"},"require":{"types":"./dist/commonjs/pack.d.ts","default":"./dist/commonjs/pack.js"}},"./unpack":{"import":{"types":"./dist/esm/unpack.d.ts","default":"./dist/esm/unpack.js"},"require":{"types":"./dist/commonjs/unpack.d.ts","default":"./dist/commonjs/unpack.js"}},"./parse":{"import":{"types":"./dist/esm/parse.d.ts","default":"./dist/esm/parse.js"},"require":{"types":"./dist/commonjs/parse.d.ts","default":"./dist/commonjs/parse.js"}},"./read-entry":{"import":{"types":"./dist/esm/read-entry.d.ts","default":"./dist/esm/read-entry.js"},"require":{"types":"./dist/commonjs/read-entry.d.ts","default":"./dist/commonjs/read-entry.js"}},"./write-entry":{"import":{"types":"./dist/esm/write-entry.d.ts","default":"./dist/esm/write-entry.js"},"require":{"types":"./dist/commonjs/write-entry.d.ts","default":"./dist/commonjs/write-entry.js"}},"./header":{"import":{"types":"./dist/esm/header.d.ts","default":"./dist/esm/header.js"},"require":{"types":"./dist/commonjs/header.d.ts","default":"./dist/commonjs/header.js"}},"./pax":{"import":{"types":"./dist/esm/pax.d.ts","default":"./dist/esm/pax.js"},"require":{"types":"./dist/commonjs/pax.d.ts","default":"./dist/commonjs/pax.js"}},"./types":{"import":{"types":"./dist/esm/types.d.ts","default":"./dist/esm/types.js"},"require":{"types":"./dist/commonjs/types.d.ts","default":"./dist/commonjs/types.js"}}},"type":"module","main":"./dist/commonjs/index.min.js","types":"./dist/commonjs/index.d.ts","module":"./dist/esm/index.min.js","_lastModified":"2026-07-30T03:54:26.865Z"}
@@ -32,6 +32,7 @@ module.exports = __toCommonJS(desktopRoutes_exports);
32
32
  var import_database = require("@nocobase/database");
33
33
  var desktopRoutes_default = (0, import_database.extendCollection)({
34
34
  name: "desktopRoutes",
35
+ repository: "MultiPortalDesktopRouteRepository",
35
36
  fields: [
36
37
  {
37
38
  type: "belongsToMany",
@@ -0,0 +1,13 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import { Migration } from '@nocobase/server';
10
+ export default class extends Migration {
11
+ on: string;
12
+ up(): Promise<void>;
13
+ }
@@ -0,0 +1,73 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+
10
+ var __defProp = Object.defineProperty;
11
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
12
+ var __getOwnPropNames = Object.getOwnPropertyNames;
13
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
14
+ var __export = (target, all) => {
15
+ for (var name in all)
16
+ __defProp(target, name, { get: all[name], enumerable: true });
17
+ };
18
+ var __copyProps = (to, from, except, desc) => {
19
+ if (from && typeof from === "object" || typeof from === "function") {
20
+ for (let key of __getOwnPropNames(from))
21
+ if (!__hasOwnProp.call(to, key) && key !== except)
22
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
23
+ }
24
+ return to;
25
+ };
26
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
27
+ var fix_fixed_layout_portal_type_exports = {};
28
+ __export(fix_fixed_layout_portal_type_exports, {
29
+ default: () => fix_fixed_layout_portal_type_default
30
+ });
31
+ module.exports = __toCommonJS(fix_fixed_layout_portal_type_exports);
32
+ var import_server = require("@nocobase/server");
33
+ const FIXED_LAYOUT_PORTALS = [
34
+ {
35
+ uid: "__default_admin__",
36
+ portalType: "no-code",
37
+ portalName: "admin",
38
+ routePath: "/admin",
39
+ uiLayoutUid: "admin-layout-model"
40
+ },
41
+ {
42
+ uid: "__default_mobile__",
43
+ portalType: "no-code",
44
+ portalName: "mobile",
45
+ routePath: "/mobile",
46
+ uiLayoutUid: "mobile-layout-model"
47
+ }
48
+ ];
49
+ class fix_fixed_layout_portal_type_default extends import_server.Migration {
50
+ on = "afterLoad";
51
+ async up() {
52
+ const collection = this.db.getCollection("multiPortals");
53
+ if (!collection) {
54
+ return;
55
+ }
56
+ const repository = this.db.getRepository("multiPortals");
57
+ for (const portal of FIXED_LAYOUT_PORTALS) {
58
+ const existing = await repository.findOne({
59
+ filterByTk: portal.uid,
60
+ fields: ["uid", "portalType", "portalName", "routePath", "uiLayoutUid"]
61
+ });
62
+ if ((existing == null ? void 0 : existing.get("portalName")) !== portal.portalName || existing.get("routePath") !== portal.routePath || existing.get("uiLayoutUid") !== portal.uiLayoutUid || existing.get("portalType") === portal.portalType) {
63
+ continue;
64
+ }
65
+ await repository.update({
66
+ filterByTk: portal.uid,
67
+ values: {
68
+ portalType: portal.portalType
69
+ }
70
+ });
71
+ }
72
+ }
73
+ }
@@ -8,7 +8,7 @@
8
8
  */
9
9
  import { Plugin } from '@nocobase/server';
10
10
  import type { ResourcerContext } from '@nocobase/resourcer';
11
- import type { Transaction } from '@nocobase/database';
11
+ import { type Transaction } from '@nocobase/database';
12
12
  type DatabaseHookOptions = {
13
13
  transaction?: Transaction;
14
14
  context?: ResourcerContext;