@nocobase/plugin-workflow 1.9.0-alpha.1 → 1.9.0-alpha.2

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.
@@ -11,8 +11,8 @@ module.exports = {
11
11
  "react": "18.2.0",
12
12
  "@formily/core": "2.3.0",
13
13
  "@formily/react": "2.3.0",
14
- "@nocobase/client": "1.9.0-alpha.1",
15
- "@nocobase/utils": "1.9.0-alpha.1",
14
+ "@nocobase/client": "1.9.0-alpha.2",
15
+ "@nocobase/utils": "1.9.0-alpha.2",
16
16
  "antd": "5.24.2",
17
17
  "@ant-design/icons": "5.6.1",
18
18
  "react-router-dom": "6.28.1",
@@ -20,17 +20,17 @@ module.exports = {
20
20
  "lodash": "4.17.21",
21
21
  "@dnd-kit/core": "6.1.0",
22
22
  "@formily/shared": "2.3.2",
23
- "@nocobase/plugin-mobile": "1.9.0-alpha.1",
23
+ "@nocobase/plugin-mobile": "1.9.0-alpha.2",
24
24
  "sequelize": "6.35.2",
25
- "@nocobase/database": "1.9.0-alpha.1",
26
- "@nocobase/server": "1.9.0-alpha.1",
27
- "@nocobase/data-source-manager": "1.9.0-alpha.1",
28
- "@nocobase/logger": "1.9.0-alpha.1",
29
- "@nocobase/evaluators": "1.9.0-alpha.1",
25
+ "@nocobase/database": "1.9.0-alpha.2",
26
+ "@nocobase/server": "1.9.0-alpha.2",
27
+ "@nocobase/data-source-manager": "1.9.0-alpha.2",
28
+ "@nocobase/logger": "1.9.0-alpha.2",
29
+ "@nocobase/evaluators": "1.9.0-alpha.2",
30
30
  "@formily/antd-v5": "1.2.3",
31
31
  "@formily/reactive": "2.3.0",
32
- "@nocobase/actions": "1.9.0-alpha.1",
32
+ "@nocobase/actions": "1.9.0-alpha.2",
33
33
  "dayjs": "1.11.13",
34
- "@nocobase/plugin-workflow-test": "1.9.0-alpha.1",
35
- "@nocobase/test": "1.9.0-alpha.1"
34
+ "@nocobase/plugin-workflow-test": "1.8.5",
35
+ "@nocobase/test": "1.9.0-alpha.2"
36
36
  };
@@ -1 +1 @@
1
- {"name":"cron-parser","version":"4.4.0","description":"Node.js library for parsing crontab instructions","main":"lib/parser.js","types":"index.d.ts","typesVersions":{"<4.1":{"*":["types/ts3/*"]}},"directories":{"test":"test"},"scripts":{"test:tsd":"tsd","test:unit":"TZ=UTC tap ./test/*.js","test:cover":"TZ=UTC tap --coverage-report=html ./test/*.js","lint":"eslint .","lint:fix":"eslint --fix .","test":"npm run lint && npm run test:unit && npm run test:tsd"},"repository":{"type":"git","url":"https://github.com/harrisiirak/cron-parser.git"},"keywords":["cron","crontab","parser"],"author":"Harri Siirak","contributors":["Nicholas Clawson","Daniel Prentis <daniel@salsitasoft.com>","Renault John Lecoultre","Richard Astbury <richard.astbury@gmail.com>","Meaglin Wasabi <Meaglin.wasabi@gmail.com>","Mike Kusold <hello@mikekusold.com>","Alex Kit <alex.kit@atmajs.com>","Santiago Gimeno <santiago.gimeno@gmail.com>","Daniel <darc.tec@gmail.com>","Christian Steininger <christian.steininger.cs@gmail.com>","Mykola Piskovyi <m.piskovyi@gmail.com>","Brian Vaughn <brian.david.vaughn@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Yasuhiroki <yasuhiroki.duck@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Brendan Warkentin <faazshift@gmail.com>","Charlie Fish <fishcharlie.code@gmail.com>","Ian Graves <ian+diskimage@iangrav.es>","Andy Thompson <me@andytson.com>","Regev Brody <regevbr@gmail.com>"],"license":"MIT","dependencies":{"luxon":"^1.28.0"},"devDependencies":{"eslint":"^8.2.0","sinon":"^10.0.0","tap":"^16.0.1","tsd":"^0.19.0"},"engines":{"node":">=0.8"},"browser":{"fs":false},"tap":{"check-coverage":false},"tsd":{"directory":"test","compilerOptions":{"lib":["es2017","dom"]}},"_lastModified":"2025-07-07T09:51:14.782Z"}
1
+ {"name":"cron-parser","version":"4.4.0","description":"Node.js library for parsing crontab instructions","main":"lib/parser.js","types":"index.d.ts","typesVersions":{"<4.1":{"*":["types/ts3/*"]}},"directories":{"test":"test"},"scripts":{"test:tsd":"tsd","test:unit":"TZ=UTC tap ./test/*.js","test:cover":"TZ=UTC tap --coverage-report=html ./test/*.js","lint":"eslint .","lint:fix":"eslint --fix .","test":"npm run lint && npm run test:unit && npm run test:tsd"},"repository":{"type":"git","url":"https://github.com/harrisiirak/cron-parser.git"},"keywords":["cron","crontab","parser"],"author":"Harri Siirak","contributors":["Nicholas Clawson","Daniel Prentis <daniel@salsitasoft.com>","Renault John Lecoultre","Richard Astbury <richard.astbury@gmail.com>","Meaglin Wasabi <Meaglin.wasabi@gmail.com>","Mike Kusold <hello@mikekusold.com>","Alex Kit <alex.kit@atmajs.com>","Santiago Gimeno <santiago.gimeno@gmail.com>","Daniel <darc.tec@gmail.com>","Christian Steininger <christian.steininger.cs@gmail.com>","Mykola Piskovyi <m.piskovyi@gmail.com>","Brian Vaughn <brian.david.vaughn@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Yasuhiroki <yasuhiroki.duck@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Brendan Warkentin <faazshift@gmail.com>","Charlie Fish <fishcharlie.code@gmail.com>","Ian Graves <ian+diskimage@iangrav.es>","Andy Thompson <me@andytson.com>","Regev Brody <regevbr@gmail.com>"],"license":"MIT","dependencies":{"luxon":"^1.28.0"},"devDependencies":{"eslint":"^8.2.0","sinon":"^10.0.0","tap":"^16.0.1","tsd":"^0.19.0"},"engines":{"node":">=0.8"},"browser":{"fs":false},"tap":{"check-coverage":false},"tsd":{"directory":"test","compilerOptions":{"lib":["es2017","dom"]}},"_lastModified":"2025-07-15T10:41:46.013Z"}
@@ -1 +1 @@
1
- {"name":"lru-cache","description":"A cache object that deletes the least-recently-used items.","version":"8.0.5","author":"Isaac Z. Schlueter <i@izs.me>","keywords":["mru","lru","cache"],"sideEffects":false,"scripts":{"build":"npm run prepare","preprepare":"rm -rf dist","prepare":"tsc -p tsconfig.json && tsc -p tsconfig-esm.json","postprepare":"bash fixup.sh","pretest":"npm run prepare","presnap":"npm run prepare","test":"c8 tap","snap":"c8 tap","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags","format":"prettier --write .","typedoc":"typedoc --tsconfig tsconfig-esm.json ./src/*.ts","benchmark-results-typedoc":"bash scripts/benchmark-results-typedoc.sh","prebenchmark":"npm run prepare","benchmark":"make -C benchmark","preprofile":"npm run prepare","profile":"make -C benchmark profile"},"main":"./dist/cjs/index-cjs.js","module":"./dist/mjs/index.js","types":"./dist/mjs/index.d.ts","exports":{"./min":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.min.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index.min.js"}},".":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index-cjs.js"}}},"repository":"git://github.com/isaacs/node-lru-cache.git","devDependencies":{"@size-limit/preset-small-lib":"^7.0.8","@types/node":"^17.0.31","@types/tap":"^15.0.6","benchmark":"^2.1.4","c8":"^7.11.2","clock-mock":"^1.0.6","esbuild":"^0.17.11","eslint-config-prettier":"^8.5.0","marked":"^4.2.12","mkdirp":"^2.1.5","prettier":"^2.6.2","size-limit":"^7.0.8","tap":"^16.3.4","ts-node":"^10.7.0","tslib":"^2.4.0","typedoc":"^0.23.24","typescript":"^4.6.4"},"license":"ISC","files":["dist"],"engines":{"node":">=16.14"},"prettier":{"semi":false,"printWidth":70,"tabWidth":2,"useTabs":false,"singleQuote":true,"jsxSingleQuote":false,"bracketSameLine":true,"arrowParens":"avoid","endOfLine":"lf"},"tap":{"coverage":false,"node-arg":["--expose-gc","--no-warnings","--loader","ts-node/esm"],"ts":false},"size-limit":[{"path":"./dist/mjs/index.js"}],"_lastModified":"2025-07-07T09:51:14.429Z"}
1
+ {"name":"lru-cache","description":"A cache object that deletes the least-recently-used items.","version":"8.0.5","author":"Isaac Z. Schlueter <i@izs.me>","keywords":["mru","lru","cache"],"sideEffects":false,"scripts":{"build":"npm run prepare","preprepare":"rm -rf dist","prepare":"tsc -p tsconfig.json && tsc -p tsconfig-esm.json","postprepare":"bash fixup.sh","pretest":"npm run prepare","presnap":"npm run prepare","test":"c8 tap","snap":"c8 tap","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags","format":"prettier --write .","typedoc":"typedoc --tsconfig tsconfig-esm.json ./src/*.ts","benchmark-results-typedoc":"bash scripts/benchmark-results-typedoc.sh","prebenchmark":"npm run prepare","benchmark":"make -C benchmark","preprofile":"npm run prepare","profile":"make -C benchmark profile"},"main":"./dist/cjs/index-cjs.js","module":"./dist/mjs/index.js","types":"./dist/mjs/index.d.ts","exports":{"./min":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.min.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index.min.js"}},".":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index-cjs.js"}}},"repository":"git://github.com/isaacs/node-lru-cache.git","devDependencies":{"@size-limit/preset-small-lib":"^7.0.8","@types/node":"^17.0.31","@types/tap":"^15.0.6","benchmark":"^2.1.4","c8":"^7.11.2","clock-mock":"^1.0.6","esbuild":"^0.17.11","eslint-config-prettier":"^8.5.0","marked":"^4.2.12","mkdirp":"^2.1.5","prettier":"^2.6.2","size-limit":"^7.0.8","tap":"^16.3.4","ts-node":"^10.7.0","tslib":"^2.4.0","typedoc":"^0.23.24","typescript":"^4.6.4"},"license":"ISC","files":["dist"],"engines":{"node":">=16.14"},"prettier":{"semi":false,"printWidth":70,"tabWidth":2,"useTabs":false,"singleQuote":true,"jsxSingleQuote":false,"bracketSameLine":true,"arrowParens":"avoid","endOfLine":"lf"},"tap":{"coverage":false,"node-arg":["--expose-gc","--no-warnings","--loader","ts-node/esm"],"ts":false},"size-limit":[{"path":"./dist/mjs/index.js"}],"_lastModified":"2025-07-15T10:41:45.664Z"}
@@ -1 +1 @@
1
- {"name":"nodejs-snowflake","collaborators":["Utkarsh Srivastava <utkarsh@sagacious.dev>"],"description":"Generate time sortable 64 bits unique ids for distributed systems (inspired from twitter snowflake)","version":"2.0.1","license":"Apache 2.0","repository":{"type":"git","url":"https://github.com/utkarsh-pro/nodejs-snowflake.git"},"files":["nodejs_snowflake_bg.wasm","nodejs_snowflake.js","nodejs_snowflake.d.ts"],"main":"nodejs_snowflake.js","types":"nodejs_snowflake.d.ts","_lastModified":"2025-07-07T09:51:14.236Z"}
1
+ {"name":"nodejs-snowflake","collaborators":["Utkarsh Srivastava <utkarsh@sagacious.dev>"],"description":"Generate time sortable 64 bits unique ids for distributed systems (inspired from twitter snowflake)","version":"2.0.1","license":"Apache 2.0","repository":{"type":"git","url":"https://github.com/utkarsh-pro/nodejs-snowflake.git"},"files":["nodejs_snowflake_bg.wasm","nodejs_snowflake.js","nodejs_snowflake.d.ts"],"main":"nodejs_snowflake.js","types":"nodejs_snowflake.d.ts","_lastModified":"2025-07-15T10:41:45.449Z"}
@@ -181,7 +181,7 @@ class PluginWorkflowServer extends import_server.Plugin {
181
181
  }
182
182
  }
183
183
  this.checker = setInterval(() => {
184
- this.getLogger("dispatcher").info(`(cycling) check for queueing executions`);
184
+ this.getLogger("dispatcher").debug(`(cycling) check for queueing executions`);
185
185
  this.dispatch();
186
186
  }, 3e5);
187
187
  this.app.on("workflow:dispatch", () => {
@@ -644,7 +644,7 @@ class PluginWorkflowServer extends import_server.Plugin {
644
644
  execution.workflow = this.enabledCache.get(execution.workflowId);
645
645
  next = [execution];
646
646
  } else {
647
- this.getLogger("dispatcher").info(`no execution in db queued to process`);
647
+ this.getLogger("dispatcher").debug(`no execution in db queued to process`);
648
648
  }
649
649
  }
650
650
  );
@@ -657,7 +657,7 @@ class PluginWorkflowServer extends import_server.Plugin {
657
657
  }
658
658
  this.executing = null;
659
659
  if (next || this.pending.length) {
660
- this.getLogger("dispatcher").info(`last process finished, will do another dispatch`);
660
+ this.getLogger("dispatcher").debug(`last process finished, will do another dispatch`);
661
661
  this.dispatch();
662
662
  }
663
663
  })();
@@ -130,7 +130,8 @@ class Processor {
130
130
  async start() {
131
131
  const { execution } = this;
132
132
  if (execution.status !== import_constants.EXECUTION_STATUS.STARTED) {
133
- throw new Error(`execution was ended with status ${execution.status} before, could not be started again`);
133
+ this.logger.warn(`execution was ended with status ${execution.status} before, could not be started again`);
134
+ return;
134
135
  }
135
136
  await this.prepare();
136
137
  if (this.nodes.length) {
@@ -143,7 +144,8 @@ class Processor {
143
144
  async resume(job) {
144
145
  const { execution } = this;
145
146
  if (execution.status !== import_constants.EXECUTION_STATUS.STARTED) {
146
- throw new Error(`execution was ended with status ${execution.status} before, could not be resumed`);
147
+ this.logger.warn(`execution was ended with status ${execution.status} before, could not be resumed`);
148
+ return;
147
149
  }
148
150
  await this.prepare();
149
151
  const node = this.nodesMap.get(job.nodeId);
@@ -19,6 +19,6 @@ type CalculationGroup = {
19
19
  calculations?: Calculation[];
20
20
  };
21
21
  };
22
- type Calculation = CalculationItem | CalculationGroup;
22
+ export type Calculation = CalculationItem | CalculationGroup;
23
23
  export declare function logicCalculate(calculation?: Calculation): any;
24
24
  export {};
@@ -69,16 +69,16 @@ function notIncludes(a, b) {
69
69
  return !a.includes(b);
70
70
  }
71
71
  function startsWith(a, b) {
72
- return a.startsWith(b);
72
+ return a.toString().startsWith(b.toString());
73
73
  }
74
74
  function notStartsWith(a, b) {
75
- return !a.startsWith(b);
75
+ return !a.toString().startsWith(b.toString());
76
76
  }
77
77
  function endsWith(a, b) {
78
- return a.endsWith(b);
78
+ return a.toString().endsWith(b.toString());
79
79
  }
80
80
  function notEndsWith(a, b) {
81
- return !a.endsWith(b);
81
+ return !a.toString().endsWith(b.toString());
82
82
  }
83
83
  calculators.register("includes", includes);
84
84
  calculators.register("notIncludes", notIncludes);
package/package.json CHANGED
@@ -4,19 +4,17 @@
4
4
  "displayName.zh-CN": "工作流",
5
5
  "description": "A powerful BPM tool that provides foundational support for business automation, with the capability to extend unlimited triggers and nodes.",
6
6
  "description.zh-CN": "一个强大的 BPM 工具,为业务自动化提供基础支持,并且可任意扩展更多的触发器和节点。",
7
- "version": "1.9.0-alpha.1",
7
+ "version": "1.9.0-alpha.2",
8
8
  "license": "AGPL-3.0",
9
9
  "main": "./dist/server/index.js",
10
10
  "homepage": "https://docs.nocobase.com/handbook/workflow",
11
11
  "homepage.zh-CN": "https://docs-cn.nocobase.com/handbook/workflow",
12
- "dependencies": {
13
- "@nocobase/plugin-workflow-test": "1.9.0-alpha.1"
14
- },
15
12
  "devDependencies": {
16
13
  "@ant-design/icons": "5.x",
17
14
  "@formily/antd-v5": "1.x",
18
15
  "@formily/core": "2.x",
19
16
  "@formily/react": "2.x",
17
+ "@nocobase/plugin-workflow-test": "1.8.5",
20
18
  "@types/ejs": "^3.1.1",
21
19
  "antd": "5.x",
22
20
  "classnames": "^2.3.1",
@@ -47,7 +45,7 @@
47
45
  "@nocobase/test": "1.x",
48
46
  "@nocobase/utils": "1.x"
49
47
  },
50
- "gitHead": "71ebde8a27da3c5c4d64194571804eeab6e95ce0",
48
+ "gitHead": "b6d8a2176e2b58bee3cf412aa66be6ee657507ee",
51
49
  "keywords": [
52
50
  "Workflow"
53
51
  ]