@huanban/rulego-editor-core 1.3.1 → 1.3.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.
@@ -5,7 +5,7 @@
5
5
  * 功能:
6
6
  * - 列表查询(分页 + 搜索)
7
7
  * - CRUD(创建/读取/更新/删除)
8
- * - 上线/下线操作
8
+ * - 部署/下线操作
9
9
  * - 变量/秘钥管理
10
10
  * - 复制规则链
11
11
  *
@@ -115,10 +115,10 @@ export declare class RuleChainAPI implements WorkflowFetcher {
115
115
  */
116
116
  remove(id: string): Promise<ApiResult>;
117
117
  /**
118
- * 上线/下线规则链
118
+ * 部署/下线规则链
119
119
  *
120
120
  * @param id - 规则链 ID
121
- * @param type - 'start'(上线)| 'stop'(下线)
121
+ * @param type - 'start'(部署/启动)| 'stop'(下线)
122
122
  * @returns 操作结果
123
123
  */
124
124
  operate(id: string, type: 'start' | 'stop'): Promise<ApiResult>;
@@ -32,7 +32,7 @@ export interface WorkflowItem {
32
32
  createTime: string;
33
33
  /** 更新时间 */
34
34
  updateTime: string;
35
- /** 是否已部署 (disabled=false deployed=true) */
35
+ /** 是否运行中 (原版协议: disabled=false -> 运行, disabled=true -> 停用) */
36
36
  deployed: boolean;
37
37
  }
38
38
  /**
@@ -153,7 +153,7 @@ export interface WorkflowFetcher {
153
153
  create: (data: Record<string, unknown>) => Promise<ApiResult>;
154
154
  /** 删除规则链 */
155
155
  remove: (id: string) => Promise<ApiResult>;
156
- /** 上线/下线 */
156
+ /** 部署/下线 (原版接口动作: start=部署/启动, stop=下线) */
157
157
  operate: (id: string, type: 'start' | 'stop') => Promise<ApiResult>;
158
158
  /** 复制规则链 */
159
159
  copy: (id: string, newName?: string) => Promise<ApiResult>;
@@ -193,7 +193,7 @@ export interface WorkflowListIcons {
193
193
  design?: unknown;
194
194
  /** 信息按钮图标 */
195
195
  info?: unknown;
196
- /** 上线按钮图标 */
196
+ /** 部署按钮图标 */
197
197
  start?: unknown;
198
198
  /** 下线按钮图标 */
199
199
  stop?: unknown;
@@ -260,7 +260,7 @@ export interface RuleChainRoutes {
260
260
  create: string;
261
261
  /** 删除路径,接收 (id) => string,默认 '/rules/:id' */
262
262
  remove: (id: string) => string;
263
- /** 上线/下线路径,接收 (id, type) => string,默认 '/rules/:id/:type' */
263
+ /** 部署/下线路径,接收 (id, type) => string,默认 '/rules/:id/operate/:type' */
264
264
  operate: (id: string, type: string) => string;
265
265
  /** 获取内容路径,接收 (id) => string,默认 '/rules/:id' */
266
266
  getContent: (id: string) => string;
@@ -280,7 +280,7 @@ export interface RuleChainRoutes {
280
280
  /**
281
281
  * 默认路由映射
282
282
  *
283
- * @description 对应 RuleGo 原生 API 路径
283
+ * @description 对齐原版前端 rules.js: operateWorkflow(id, operateType)
284
284
  */
285
285
  export declare const DEFAULT_ROUTES: RuleChainRoutes;
286
286
  /**
@@ -12,6 +12,7 @@ export declare const RUNTIME_LIMITS: {
12
12
  readonly maxDebugItemChars: 20000;
13
13
  readonly maxExampleEventLogLines: 80;
14
14
  readonly maxJsonPrettyChars: 200000;
15
+ readonly runHistoryRequestTimeoutMs: 15000;
15
16
  readonly maxChatChains: 20;
16
17
  readonly maxChatMessagesPerChain: 50;
17
18
  readonly maxChatMessageChars: 2000;