@nocobase/server 1.9.19 → 1.9.20

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.
@@ -53,6 +53,7 @@ var import_start = __toESM(require("./start"));
53
53
  var import_stop = __toESM(require("./stop"));
54
54
  var import_upgrade = __toESM(require("./upgrade"));
55
55
  var import_console = __toESM(require("./console"));
56
+ var import_repair = __toESM(require("./repair"));
56
57
  /* istanbul ignore file -- @preserve */
57
58
  function registerCli(app) {
58
59
  (0, import_console.default)(app);
@@ -68,6 +69,7 @@ function registerCli(app) {
68
69
  (0, import_destroy.default)(app);
69
70
  (0, import_start.default)(app);
70
71
  (0, import_refresh.default)(app);
72
+ (0, import_repair.default)(app);
71
73
  app.command("build").argument("[packages...]");
72
74
  app.command("clean");
73
75
  app.command("dev").usage("[options]").option("-p, --port [port]").option("--client").option("--server");
@@ -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
+ import Application from '../application';
10
+ declare const _default: (app: Application) => void;
11
+ export default _default;
@@ -0,0 +1,43 @@
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 __name = (target, value) => __defProp(target, "name", { value, configurable: true });
15
+ var __export = (target, all) => {
16
+ for (var name in all)
17
+ __defProp(target, name, { get: all[name], enumerable: true });
18
+ };
19
+ var __copyProps = (to, from, except, desc) => {
20
+ if (from && typeof from === "object" || typeof from === "function") {
21
+ for (let key of __getOwnPropNames(from))
22
+ if (!__hasOwnProp.call(to, key) && key !== except)
23
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
24
+ }
25
+ return to;
26
+ };
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+ var repair_exports = {};
29
+ __export(repair_exports, {
30
+ default: () => repair_default
31
+ });
32
+ module.exports = __toCommonJS(repair_exports);
33
+ var repair_default = /* @__PURE__ */ __name((app) => {
34
+ app.command("repair").auth().preload().action(async (options) => {
35
+ app.log.info("start repair data...");
36
+ const Collection = app.db.getCollection("collections");
37
+ if (Collection) {
38
+ await Collection.repository.setApp(app);
39
+ await Collection.repository.load();
40
+ }
41
+ await app.emitAsync("repair", options);
42
+ });
43
+ }, "default");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nocobase/server",
3
- "version": "1.9.19",
3
+ "version": "1.9.20",
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": "1.9.19",
14
- "@nocobase/actions": "1.9.19",
15
- "@nocobase/auth": "1.9.19",
16
- "@nocobase/cache": "1.9.19",
17
- "@nocobase/data-source-manager": "1.9.19",
18
- "@nocobase/database": "1.9.19",
19
- "@nocobase/evaluators": "1.9.19",
20
- "@nocobase/lock-manager": "1.9.19",
21
- "@nocobase/logger": "1.9.19",
22
- "@nocobase/resourcer": "1.9.19",
23
- "@nocobase/sdk": "1.9.19",
24
- "@nocobase/snowflake-id": "1.9.19",
25
- "@nocobase/telemetry": "1.9.19",
26
- "@nocobase/utils": "1.9.19",
13
+ "@nocobase/acl": "1.9.20",
14
+ "@nocobase/actions": "1.9.20",
15
+ "@nocobase/auth": "1.9.20",
16
+ "@nocobase/cache": "1.9.20",
17
+ "@nocobase/data-source-manager": "1.9.20",
18
+ "@nocobase/database": "1.9.20",
19
+ "@nocobase/evaluators": "1.9.20",
20
+ "@nocobase/lock-manager": "1.9.20",
21
+ "@nocobase/logger": "1.9.20",
22
+ "@nocobase/resourcer": "1.9.20",
23
+ "@nocobase/sdk": "1.9.20",
24
+ "@nocobase/snowflake-id": "1.9.20",
25
+ "@nocobase/telemetry": "1.9.20",
26
+ "@nocobase/utils": "1.9.20",
27
27
  "@types/decompress": "4.2.7",
28
28
  "@types/ini": "^1.3.31",
29
29
  "@types/koa-send": "^4.1.3",
@@ -59,5 +59,5 @@
59
59
  "@types/serve-handler": "^6.1.1",
60
60
  "@types/ws": "^8.5.5"
61
61
  },
62
- "gitHead": "a6893165eddc9e1bd7cf9f5de9c2dce9a77571dd"
62
+ "gitHead": "21cd385ff885f28851e7e7c04c5f5a429b910c9f"
63
63
  }