@nocobase/server 2.0.0-alpha.62 → 2.0.0-alpha.64

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.
@@ -47,13 +47,13 @@ var import_fs = __toESM(require("fs"));
47
47
  var import_fs_extra = __toESM(require("fs-extra"));
48
48
  var import_path = __toESM(require("path"));
49
49
  const _PackageUrls = class _PackageUrls {
50
- static async get(packageName, version) {
50
+ static async get(packageName) {
51
51
  if (!this.items[packageName]) {
52
- this.items[packageName] = await this.fetch(packageName, version);
52
+ this.items[packageName] = await this.fetch(packageName);
53
53
  }
54
54
  return this.items[packageName];
55
55
  }
56
- static async fetch(packageName, version) {
56
+ static async fetch(packageName) {
57
57
  const PLUGIN_CLIENT_ENTRY_FILE = "dist/client/index.js";
58
58
  const pkgPath = import_path.default.resolve(process.env.NODE_MODULES_PATH, packageName);
59
59
  const r = await import_fs_extra.default.exists(pkgPath);
@@ -63,9 +63,9 @@ const _PackageUrls = class _PackageUrls {
63
63
  const distExists = await import_fs_extra.default.exists(dist);
64
64
  if (distExists) {
65
65
  const fsState = await import_fs_extra.default.stat(distExists ? dist : pkgPath);
66
- t = `&t=${fsState.mtime.getTime()}`;
66
+ t = `?t=${fsState.mtime.getTime()}`;
67
67
  }
68
- const url = `${process.env.APP_SERVER_BASE_URL}${process.env.PLUGIN_STATICS_PATH}${packageName}/${PLUGIN_CLIENT_ENTRY_FILE}?version=${version}${t}`;
68
+ const url = `${process.env.APP_SERVER_BASE_URL}${process.env.PLUGIN_STATICS_PATH}${packageName}/${PLUGIN_CLIENT_ENTRY_FILE}${t}`;
69
69
  return url;
70
70
  }
71
71
  }
@@ -191,10 +191,13 @@ var resource_default = {
191
191
  });
192
192
  const arr = [];
193
193
  for (const item of items) {
194
- const url = await PackageUrls.get(item.packageName, item.version);
194
+ const url = await PackageUrls.get(item.packageName);
195
+ const { name, packageName, options } = item.toJSON();
195
196
  if (url) {
196
197
  arr.push({
197
- ...item.toJSON(),
198
+ name,
199
+ packageName,
200
+ options,
198
201
  url
199
202
  });
200
203
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nocobase/server",
3
- "version": "2.0.0-alpha.62",
3
+ "version": "2.0.0-alpha.64",
4
4
  "main": "lib/index.js",
5
5
  "types": "./lib/index.d.ts",
6
6
  "license": "AGPL-3.0",
@@ -10,20 +10,20 @@
10
10
  "@koa/cors": "^5.0.0",
11
11
  "@koa/multer": "^3.1.0",
12
12
  "@koa/router": "^13.1.0",
13
- "@nocobase/acl": "2.0.0-alpha.62",
14
- "@nocobase/actions": "2.0.0-alpha.62",
15
- "@nocobase/auth": "2.0.0-alpha.62",
16
- "@nocobase/cache": "2.0.0-alpha.62",
17
- "@nocobase/data-source-manager": "2.0.0-alpha.62",
18
- "@nocobase/database": "2.0.0-alpha.62",
19
- "@nocobase/evaluators": "2.0.0-alpha.62",
20
- "@nocobase/lock-manager": "2.0.0-alpha.62",
21
- "@nocobase/logger": "2.0.0-alpha.62",
22
- "@nocobase/resourcer": "2.0.0-alpha.62",
23
- "@nocobase/sdk": "2.0.0-alpha.62",
24
- "@nocobase/snowflake-id": "2.0.0-alpha.62",
25
- "@nocobase/telemetry": "2.0.0-alpha.62",
26
- "@nocobase/utils": "2.0.0-alpha.62",
13
+ "@nocobase/acl": "2.0.0-alpha.64",
14
+ "@nocobase/actions": "2.0.0-alpha.64",
15
+ "@nocobase/auth": "2.0.0-alpha.64",
16
+ "@nocobase/cache": "2.0.0-alpha.64",
17
+ "@nocobase/data-source-manager": "2.0.0-alpha.64",
18
+ "@nocobase/database": "2.0.0-alpha.64",
19
+ "@nocobase/evaluators": "2.0.0-alpha.64",
20
+ "@nocobase/lock-manager": "2.0.0-alpha.64",
21
+ "@nocobase/logger": "2.0.0-alpha.64",
22
+ "@nocobase/resourcer": "2.0.0-alpha.64",
23
+ "@nocobase/sdk": "2.0.0-alpha.64",
24
+ "@nocobase/snowflake-id": "2.0.0-alpha.64",
25
+ "@nocobase/telemetry": "2.0.0-alpha.64",
26
+ "@nocobase/utils": "2.0.0-alpha.64",
27
27
  "@types/decompress": "4.2.7",
28
28
  "@types/ini": "^1.3.31",
29
29
  "@types/koa-send": "^4.1.3",
@@ -60,5 +60,5 @@
60
60
  "@types/serve-handler": "^6.1.1",
61
61
  "@types/ws": "^8.5.5"
62
62
  },
63
- "gitHead": "a6e543098afba0edc2189edc04f27c1726fff564"
63
+ "gitHead": "f6c2831b27608b53de6dc8b7aa6a48d12ec48a14"
64
64
  }