@tachybase/module-multi-app 1.3.21 → 1.3.23

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 +1 @@
1
- {"name":"qs","description":"A querystring parser that supports nesting and arrays, with a depth limit","homepage":"https://github.com/ljharb/qs","version":"6.14.0","repository":{"type":"git","url":"https://github.com/ljharb/qs.git"},"funding":{"url":"https://github.com/sponsors/ljharb"},"main":"lib/index.js","sideEffects":false,"contributors":[{"name":"Jordan Harband","email":"ljharb@gmail.com","url":"http://ljharb.codes"}],"keywords":["querystring","qs","query","url","parse","stringify"],"engines":{"node":">=0.6"},"dependencies":{"side-channel":"^1.1.0"},"devDependencies":{"@browserify/envify":"^6.0.0","@browserify/uglifyify":"^6.0.0","@ljharb/eslint-config":"^21.1.1","browserify":"^16.5.2","bundle-collapser":"^1.4.0","common-shakeify":"~1.0.0","eclint":"^2.8.1","es-value-fixtures":"^1.7.0","eslint":"=8.8.0","evalmd":"^0.0.19","for-each":"^0.3.3","glob":"=10.3.7","has-bigints":"^1.1.0","has-override-mistake":"^1.0.1","has-property-descriptors":"^1.0.2","has-proto":"^1.2.0","has-symbols":"^1.1.0","iconv-lite":"^0.5.1","in-publish":"^2.0.1","jackspeak":"=2.1.1","mkdirp":"^0.5.5","mock-property":"^1.1.0","module-deps":"^6.2.3","npmignore":"^0.3.1","nyc":"^10.3.2","object-inspect":"^1.13.3","qs-iconv":"^1.0.4","safe-publish-latest":"^2.0.0","safer-buffer":"^2.1.2","tape":"^5.9.0","unassertify":"^3.0.1"},"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated && npm run dist","prepublishOnly":"safe-publish-latest","prepublish":"not-in-publish || npm run prepublishOnly","pretest":"npm run --silent readme && npm run --silent lint","test":"npm run tests-only","tests-only":"nyc tape 'test/**/*.js'","posttest":"npx npm@'>=10.2' audit --production","readme":"evalmd README.md","postlint":"eclint check $(git ls-files | xargs find 2> /dev/null | grep -vE 'node_modules|\\.git' | grep -v dist/)","lint":"eslint --ext=js,mjs .","dist":"mkdirp dist && browserify --standalone Qs -g unassertify -g @browserify/envify -g [@browserify/uglifyify --mangle.keep_fnames --compress.keep_fnames --format.indent_level=1 --compress.arrows=false --compress.passes=4 --compress.typeofs=false] -p common-shakeify -p bundle-collapser/plugin lib/index.js > dist/qs.js"},"license":"BSD-3-Clause","publishConfig":{"ignore":["!dist/*","bower.json","component.json",".github/workflows","logos","tea.yaml"]},"_lastModified":"2025-07-25T05:48:51.562Z"}
1
+ {"name":"qs","description":"A querystring parser that supports nesting and arrays, with a depth limit","homepage":"https://github.com/ljharb/qs","version":"6.14.0","repository":{"type":"git","url":"https://github.com/ljharb/qs.git"},"funding":{"url":"https://github.com/sponsors/ljharb"},"main":"lib/index.js","sideEffects":false,"contributors":[{"name":"Jordan Harband","email":"ljharb@gmail.com","url":"http://ljharb.codes"}],"keywords":["querystring","qs","query","url","parse","stringify"],"engines":{"node":">=0.6"},"dependencies":{"side-channel":"^1.1.0"},"devDependencies":{"@browserify/envify":"^6.0.0","@browserify/uglifyify":"^6.0.0","@ljharb/eslint-config":"^21.1.1","browserify":"^16.5.2","bundle-collapser":"^1.4.0","common-shakeify":"~1.0.0","eclint":"^2.8.1","es-value-fixtures":"^1.7.0","eslint":"=8.8.0","evalmd":"^0.0.19","for-each":"^0.3.3","glob":"=10.3.7","has-bigints":"^1.1.0","has-override-mistake":"^1.0.1","has-property-descriptors":"^1.0.2","has-proto":"^1.2.0","has-symbols":"^1.1.0","iconv-lite":"^0.5.1","in-publish":"^2.0.1","jackspeak":"=2.1.1","mkdirp":"^0.5.5","mock-property":"^1.1.0","module-deps":"^6.2.3","npmignore":"^0.3.1","nyc":"^10.3.2","object-inspect":"^1.13.3","qs-iconv":"^1.0.4","safe-publish-latest":"^2.0.0","safer-buffer":"^2.1.2","tape":"^5.9.0","unassertify":"^3.0.1"},"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated && npm run dist","prepublishOnly":"safe-publish-latest","prepublish":"not-in-publish || npm run prepublishOnly","pretest":"npm run --silent readme && npm run --silent lint","test":"npm run tests-only","tests-only":"nyc tape 'test/**/*.js'","posttest":"npx npm@'>=10.2' audit --production","readme":"evalmd README.md","postlint":"eclint check $(git ls-files | xargs find 2> /dev/null | grep -vE 'node_modules|\\.git' | grep -v dist/)","lint":"eslint --ext=js,mjs .","dist":"mkdirp dist && browserify --standalone Qs -g unassertify -g @browserify/envify -g [@browserify/uglifyify --mangle.keep_fnames --compress.keep_fnames --format.indent_level=1 --compress.arrows=false --compress.passes=4 --compress.typeofs=false] -p common-shakeify -p bundle-collapser/plugin lib/index.js > dist/qs.js"},"license":"BSD-3-Clause","publishConfig":{"ignore":["!dist/*","bower.json","component.json",".github/workflows","logos","tea.yaml"]},"_lastModified":"2025-08-02T21:24:55.433Z"}
@@ -1,4 +1,4 @@
1
- import { Context, Next } from '@tachybase/actions';
1
+ import { Context, Next } from '@tego/server';
2
2
  export declare function start(ctx: Context, next: Next): Promise<void>;
3
3
  export declare function stop(ctx: Context, next: Next): Promise<void>;
4
4
  export declare function listPinned(ctx: Context, next: Next): Promise<void>;
@@ -26,7 +26,7 @@ __export(apps_exports, {
26
26
  stopAll: () => stopAll
27
27
  });
28
28
  module.exports = __toCommonJS(apps_exports);
29
- var import_server = require("@tachybase/server");
29
+ var import_server = require("@tego/server");
30
30
  var import_constants = require("../../constants");
31
31
  async function start(ctx, next) {
32
32
  const targetAppId = String(ctx.request.url.split("filterByTk=")[1]);
@@ -1,4 +1,4 @@
1
- import Application, { AppSupervisor } from '@tachybase/server';
1
+ import { Application, AppSupervisor } from '@tego/server';
2
2
  export type AppOptionsFactory = (appName: string, mainApp: Application, preset: string) => any;
3
3
  export declare function LazyLoadApplication(context: any): ({ appSupervisor, appName, options, }: {
4
4
  appSupervisor: AppSupervisor;
@@ -21,7 +21,7 @@ __export(app_lifecycle_exports, {
21
21
  onAfterStart: () => onAfterStart
22
22
  });
23
23
  module.exports = __toCommonJS(app_lifecycle_exports);
24
- var import_server = require("@tachybase/server");
24
+ var import_server = require("@tego/server");
25
25
  function LazyLoadApplication(context) {
26
26
  return async ({
27
27
  appSupervisor,
@@ -1,2 +1,2 @@
1
- import { Application } from '@tachybase/server';
2
- export default function mergeApplicationStartEnvs(appName: String, mainApp: Application, options: any, startEnvs: any): any;
1
+ import { Application } from '@tego/server';
2
+ export default function mergeApplicationStartEnvs(appName: string, mainApp: Application, options: any, startEnvs: any): any;
@@ -1,2 +1,2 @@
1
- declare const _default: import("@tachybase/database").CollectionOptions;
1
+ declare const _default: import("@tego/server").CollectionOptions;
2
2
  export default _default;
@@ -20,9 +20,8 @@ __export(applications_exports, {
20
20
  default: () => applications_default
21
21
  });
22
22
  module.exports = __toCommonJS(applications_exports);
23
- var import_database = require("@tachybase/database");
24
- var import_utils = require("@tachybase/utils");
25
- var applications_default = (0, import_database.defineCollection)({
23
+ var import_server = require("@tego/server");
24
+ var applications_default = (0, import_server.defineCollection)({
26
25
  dumpRules: {
27
26
  group: "third-party"
28
27
  },
@@ -90,7 +89,7 @@ var applications_default = (0, import_database.defineCollection)({
90
89
  // APPKEY的后缀,为了防止被推断出来
91
90
  name: "appKeySuffix",
92
91
  defaultValue: () => {
93
- return (0, import_utils.uid)(16);
92
+ return (0, import_server.uid)(16);
94
93
  }
95
94
  },
96
95
  {
@@ -1,2 +1,2 @@
1
- declare const _default: import("@tachybase/database").CollectionOptions;
1
+ declare const _default: import("@tego/server").CollectionOptions;
2
2
  export default _default;
@@ -20,8 +20,8 @@ __export(applicationsPartners_exports, {
20
20
  default: () => applicationsPartners_default
21
21
  });
22
22
  module.exports = __toCommonJS(applicationsPartners_exports);
23
- var import_database = require("@tachybase/database");
24
- var applicationsPartners_default = (0, import_database.defineCollection)({
23
+ var import_server = require("@tego/server");
24
+ var applicationsPartners_default = (0, import_server.defineCollection)({
25
25
  dumpRules: {
26
26
  group: "third-party"
27
27
  },
@@ -20,7 +20,7 @@ __export(inject_app_list_exports, {
20
20
  injectAppListMiddleware: () => injectAppListMiddleware
21
21
  });
22
22
  module.exports = __toCommonJS(inject_app_list_exports);
23
- var import_server = require("@tachybase/server");
23
+ var import_server = require("@tego/server");
24
24
  function injectAppListMiddleware() {
25
25
  return async (ctx, next) => {
26
26
  await next();
@@ -1,4 +1,4 @@
1
- import { Migration } from '@tachybase/server';
1
+ import { Migration } from '@tego/server';
2
2
  export default class AddAppTmplMigration extends Migration {
3
3
  appVersion: string;
4
4
  up(): Promise<void>;
@@ -20,7 +20,7 @@ __export(add_apps_tmpl_exports, {
20
20
  default: () => AddAppTmplMigration
21
21
  });
22
22
  module.exports = __toCommonJS(add_apps_tmpl_exports);
23
- var import_server = require("@tachybase/server");
23
+ var import_server = require("@tego/server");
24
24
  class AddAppTmplMigration extends import_server.Migration {
25
25
  constructor() {
26
26
  super(...arguments);
@@ -1,4 +1,4 @@
1
- import { Migration } from '@tachybase/server';
1
+ import { Migration } from '@tego/server';
2
2
  export default class extends Migration {
3
3
  on: string;
4
4
  appVersion: string;
@@ -20,7 +20,7 @@ __export(add_createdBy_exports, {
20
20
  default: () => add_createdBy_default
21
21
  });
22
22
  module.exports = __toCommonJS(add_createdBy_exports);
23
- var import_server = require("@tachybase/server");
23
+ var import_server = require("@tego/server");
24
24
  class add_createdBy_default extends import_server.Migration {
25
25
  constructor() {
26
26
  super(...arguments);
@@ -1,4 +1,4 @@
1
- import { Migration } from '@tachybase/server';
1
+ import { Migration } from '@tego/server';
2
2
  export default class extends Migration {
3
3
  on: string;
4
4
  appVersion: string;
@@ -20,7 +20,7 @@ __export(fix_tmpl_exports, {
20
20
  default: () => fix_tmpl_default
21
21
  });
22
22
  module.exports = __toCommonJS(fix_tmpl_exports);
23
- var import_server = require("@tachybase/server");
23
+ var import_server = require("@tego/server");
24
24
  function extractInnermost(expression) {
25
25
  let trimmed = expression.trim();
26
26
  const regex = /^NOT\s+EXISTS\s*\(\s*(.+)\s*\)$/i;
@@ -1,10 +1,9 @@
1
- import { Model, Transactionable } from '@tachybase/database';
2
- import { Application } from '@tachybase/server';
1
+ import { Application, Model, Transactionable } from '@tego/server';
3
2
  import { AppOptionsFactory } from '../server';
4
3
  export interface registerAppOptions extends Transactionable {
5
4
  skipInstall?: boolean;
6
5
  appOptionsFactory: AppOptionsFactory;
7
6
  }
8
7
  export declare class ApplicationModel extends Model {
9
- registerToSupervisor(mainApp: Application, options: registerAppOptions): Application<import("@tachybase/server").DefaultState, import("@tachybase/server").DefaultContext>;
8
+ registerToSupervisor(mainApp: Application, options: registerAppOptions): Application<import("@tego/server").DefaultState, import("@tego/server").DefaultContext>;
10
9
  }
@@ -30,11 +30,9 @@ __export(application_exports, {
30
30
  ApplicationModel: () => ApplicationModel
31
31
  });
32
32
  module.exports = __toCommonJS(application_exports);
33
- var import_database = require("@tachybase/database");
34
- var import_server = require("@tachybase/server");
35
- var import_utils = require("@tachybase/utils");
33
+ var import_server = require("@tego/server");
36
34
  var import_app_start_env = __toESM(require("../app-start-env"));
37
- class ApplicationModel extends import_database.Model {
35
+ class ApplicationModel extends import_server.Model {
38
36
  registerToSupervisor(mainApp, options) {
39
37
  var _a, _b;
40
38
  const appName = this.get("name");
@@ -46,12 +44,12 @@ class ApplicationModel extends import_database.Model {
46
44
  let appOptions = options.appOptionsFactory(appName, mainApp, preset);
47
45
  appOptions = (0, import_app_start_env.default)(appName, mainApp, appOptions, startEnvs);
48
46
  const subAppOptions = {
49
- ...(0, import_utils.merge)(appOptions, appModelOptions),
47
+ ...(0, import_server.merge)(appOptions, appModelOptions),
50
48
  name: appName,
51
49
  tmpl
52
50
  };
53
51
  const suffix = appKeySuffix || appName;
54
- const subSecret = (0, import_database.md5)(process.env.APP_KEY) + "_" + suffix;
52
+ const subSecret = (0, import_server.md5)(process.env.APP_KEY) + "_" + suffix;
55
53
  if ((_b = (_a = subAppOptions.authManager) == null ? void 0 : _a.jwt) == null ? void 0 : _b.secret) {
56
54
  subAppOptions.authManager.jwt.secret = subSecret;
57
55
  } else {
@@ -1,5 +1,4 @@
1
- import { IDatabaseOptions, Transactionable } from '@tachybase/database';
2
- import Application, { Plugin } from '@tachybase/server';
1
+ import { Application, IDatabaseOptions, Plugin, Transactionable } from '@tego/server';
3
2
  import { AppOptionsFactory } from './app-lifecycle';
4
3
  export type AppDbCreator = (app: Application, options?: Transactionable & {
5
4
  context?: any;
@@ -31,8 +31,7 @@ __export(server_exports, {
31
31
  });
32
32
  module.exports = __toCommonJS(server_exports);
33
33
  var import_node_path = __toESM(require("node:path"));
34
- var import_database = require("@tachybase/database");
35
- var import_server = require("@tachybase/server");
34
+ var import_server = require("@tego/server");
36
35
  var import_lodash = __toESM(require("lodash"));
37
36
  var import_constants = require("../constants");
38
37
  var import_server2 = require("../server");
@@ -164,7 +163,7 @@ class PluginMultiAppManager extends import_server.Plugin {
164
163
  this.subAppUpgradeHandler = defaultSubAppUpgradeHandle;
165
164
  }
166
165
  static getDatabaseConfig(app) {
167
- let oldConfig = app.options.database instanceof import_database.Database ? app.options.database.options : app.options.database;
166
+ let oldConfig = app.options.database instanceof import_server.Database ? app.options.database.options : app.options.database;
168
167
  if (!oldConfig && app.db) {
169
168
  oldConfig = app.db.options;
170
169
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tachybase/module-multi-app",
3
3
  "displayName": "Multi-app manager",
4
- "version": "1.3.21",
4
+ "version": "1.3.23",
5
5
  "description": "Dynamically create multiple apps without separate deployments.",
6
6
  "keywords": [
7
7
  "System management"
@@ -9,30 +9,24 @@
9
9
  "license": "Apache-2.0",
10
10
  "main": "./dist/server/index.js",
11
11
  "devDependencies": {
12
- "@ant-design/icons": "^5.5.2",
13
- "@types/lodash": "4.17.20",
12
+ "@ant-design/icons": "^5.6.1",
13
+ "@tachybase/schema": "^1.3.43",
14
+ "@tachybase/test": "^1.3.43",
15
+ "@tego/client": "^1.3.43",
16
+ "@tego/server": "^1.3.43",
17
+ "@types/lodash": "^4.17.20",
14
18
  "antd": "5.22.5",
15
19
  "async-mutex": "^0.5.0",
16
20
  "lodash": "4.17.21",
17
- "mysql2": "^3.14.1",
21
+ "mysql2": "^3.14.3",
18
22
  "pg": "^8.16.3",
19
23
  "qs": "^6.14.0",
20
- "react": "~18.3.1",
21
- "react-i18next": "^15.2.0",
24
+ "react": "18.3.1",
25
+ "react-i18next": "15.2.0",
22
26
  "react-router-dom": "6.28.1",
23
- "@tachybase/schema": "1.3.21"
24
- },
25
- "peerDependencies": {
26
- "@tachybase/actions": "1.3.21",
27
- "@tachybase/client": "1.3.21",
28
- "@tachybase/database": "1.3.21",
29
- "@tachybase/server": "1.3.21",
30
- "@tachybase/test": "1.3.21",
31
- "@tachybase/utils": "1.3.21"
27
+ "@tachybase/client": "1.3.23"
32
28
  },
33
29
  "description.zh-CN": "无需单独部署即可动态创建多个应用。",
34
30
  "displayName.zh-CN": "多应用管理器",
35
- "scripts": {
36
- "build": "tachybase-build --no-dts @tachybase/module-multi-app"
37
- }
31
+ "scripts": {}
38
32
  }