@hcmai/sdk 0.21.10 → 0.21.12

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.
package/dist/index.d.ts CHANGED
@@ -2463,6 +2463,8 @@ interface WorkspaceFileItem {
2463
2463
  fileType?: string;
2464
2464
  fileSize?: number;
2465
2465
  lastModified?: number | string | null;
2466
+ /** Actual committed text, present on create/save-content responses only. */
2467
+ content?: string;
2466
2468
  }
2467
2469
  interface WorkspaceFileContent {
2468
2470
  workspaceKey: string;
@@ -3084,7 +3086,7 @@ interface SaveMetaResult {
3084
3086
  declare function saveTenantMeta(http: AxiosInstance, path: string, content: string): Promise<SaveMetaResult>;
3085
3087
  declare function deleteTenantMeta(http: AxiosInstance, path: string): Promise<SaveMetaResult>;
3086
3088
 
3087
- declare const META_SCHEMA_SOURCE_COMMIT = "9c205ad33da978414b101ce79b3f091a60779a34";
3089
+ declare const META_SCHEMA_SOURCE_COMMIT = "2d4b4a9ee24111c6ff425f88d109b2eddf811b51";
3088
3090
 
3089
3091
  type MetaIssueSeverity = 'error' | 'warn';
3090
3092
  interface MetaIssue {
package/dist/index.js CHANGED
@@ -225,6 +225,8 @@ var CliError = class extends Error {
225
225
  if (typeof serverCode === "string" && serverCode && serverCode !== this.code) {
226
226
  parts.push(`[\u670D\u52A1\u7AEF\u9519\u8BEF\u7801: ${serverCode}]`);
227
227
  }
228
+ const workspaceKey = this.context?.workspaceKey;
229
+ if (typeof workspaceKey === "string" && workspaceKey) parts.push(`[\u5DE5\u4F5C\u533A: ${workspaceKey}]`);
228
230
  const field = this.context?.field;
229
231
  if (typeof field === "string" && field) parts.push(`[\u5B57\u6BB5: ${field}]`);
230
232
  const reasonCode = this.context?.reasonCode;
@@ -280,9 +282,10 @@ function fromAxiosError(err, profile) {
280
282
  const respDetails = body?.details;
281
283
  const respReason = nonBlankString(body?.reason);
282
284
  const respNote = nonBlankString(body?.note);
283
- const respNextStep = body?.next_step ?? body?.nextStep;
285
+ const respNextStep = nonBlankString(body?.next_step) ?? nonBlankString(body?.nextStep);
284
286
  const respRetryable = body?.retryable;
285
- const localDiagnosis = respCode === REJECTED_BEFORE_ROUTING_CODE ? diagnoseRejectedBeforeRouting(err.config?.url, err.config?.baseURL) : void 0;
287
+ const conflictDiagnosis = status === 409 ? diagnoseWorkspaceConflict(respCode) : void 0;
288
+ const localDiagnosis = respCode === REJECTED_BEFORE_ROUTING_CODE ? diagnoseRejectedBeforeRouting(err.config?.url, err.config?.baseURL) : conflictDiagnosis;
286
289
  let code;
287
290
  if (status === 401) code = "AUTH_FAILED" /* AUTH_FAILED */;
288
291
  else if (status === 403) code = "SCOPE_FORBIDDEN" /* SCOPE_FORBIDDEN */;
@@ -304,7 +307,7 @@ function fromAxiosError(err, profile) {
304
307
  ...respDetails !== void 0 ? { details: respDetails } : {},
305
308
  ...respReason ? { reason: respReason } : {},
306
309
  ...respNote ? { note: respNote } : {},
307
- ...respNextStep ? { nextStep: respNextStep } : {},
310
+ ...respNextStep || conflictDiagnosis ? { nextStep: respNextStep ?? conflictRecovery } : {},
308
311
  ...respRetryable !== void 0 ? { retryable: respRetryable } : {},
309
312
  // 与后端的 nextStep 并存、不互相覆盖:一个是服务端的通用路标,一个是本地对症结论。
310
313
  ...localDiagnosis ? { localDiagnosis } : {}
@@ -314,6 +317,16 @@ function fromAxiosError(err, profile) {
314
317
  cause: err
315
318
  });
316
319
  }
320
+ var conflictRecovery = "\u5148\u6838\u5BF9\u670D\u52A1\u7AEF\u8BE6\u60C5\u3002\u4EC5\u5728\u786E\u8BA4\u662F\u5176\u4ED6\u5199\u5165\u6216\u90E8\u7F72\u5360\u7528\u65F6\u7B49\u5F85\u540E\u56DE\u8BFB\u72B6\u6001\uFF1B\u5BA2\u6237\u7AEF\u5EFA\u8BAE\u95F4\u9694 30\u201360 \u79D2\uFF0C\u4E0D\u80FD\u4FDD\u8BC1\u5C4A\u65F6\u9501\u5DF2\u91CA\u653E\uFF0C\u670D\u52A1\u7AEF\u672A\u63D0\u4F9B\u7684\u6301\u6709\u8005\u53CA\u5269\u4F59\u65F6\u95F4\u4E0D\u80FD\u63A8\u65AD\u3002\u771F\u5B9E\u4FEE\u8BA2\u51B2\u7A81\u6216\u6587\u4EF6\u89C4\u8303\u5316\u8981\u6C42\u5E94\u6309\u8BE6\u60C5\u5904\u7406\uFF0C\u4FDD\u7559\u672C\u5730\u6539\u52A8\u3001\u8BFB\u53D6\u6700\u65B0\u5185\u5BB9\u5E76\u6BD4\u5BF9\u540E\u518D\u51B3\u5B9A\u662F\u5426\u91CD\u8BD5\u3002";
321
+ function diagnoseWorkspaceConflict(responseCode) {
322
+ if (responseCode === "WORKSPACE_REVISION_CONFLICT") {
323
+ return "\u5DE5\u4F5C\u533A\u5199\u5165\u88AB\u62D2\u7EDD\uFF1A\u53EF\u80FD\u662F\u79DF\u6237\u5185\u5176\u4ED6\u5199\u5165\u6216\u90E8\u7F72\u6B63\u5728\u5360\u7528\uFF0C\u4E5F\u53EF\u80FD\u662F\u57FA\u7EBF\u4FEE\u8BA2\u51B2\u7A81\u6216\u6587\u4EF6\u89C4\u8303\u5316\u8981\u6C42\uFF1B\u4EC5\u51ED\u9519\u8BEF\u7801\u65E0\u6CD5\u5224\u65AD\u53EF\u5426\u91CD\u8BD5\uFF0C\u4EE5\u670D\u52A1\u7AEF\u8BE6\u60C5\u4E3A\u51C6\u3002";
324
+ }
325
+ if (responseCode === "DEPLOY_IN_PROGRESS") {
326
+ return "\u79DF\u6237\u6269\u5C55\u6B63\u5728\u90E8\u7F72\u6216\u5F52\u6863\uFF0C\u5F53\u524D\u64CD\u4F5C\u88AB\u5E76\u53D1\u4FDD\u62A4\u62D2\u7EDD\uFF1B\u8BF7\u5148\u786E\u8BA4\u73B0\u6709\u90E8\u7F72\u72B6\u6001\u3002";
327
+ }
328
+ return void 0;
329
+ }
317
330
  var CODE_LIKE = /^(?:[A-Z][A-Z0-9_]*|[a-z][a-z0-9]*(?:_[a-z0-9]+)+)$/;
318
331
  function isRecord(value) {
319
332
  return typeof value === "object" && value !== null && !Array.isArray(value);
@@ -4488,15 +4501,26 @@ function toWorkspaceFileItem(value) {
4488
4501
  relativePath: stringOr(obj.relativePath),
4489
4502
  fileType: stringOrUndefined(obj.fileType),
4490
4503
  fileSize: numberOr(obj.fileSize, 0),
4504
+ content: typeof obj.content === "string" ? obj.content : void 0,
4491
4505
  lastModified: primitiveOrNull(obj.lastModified)
4492
4506
  };
4493
4507
  }
4494
4508
  function toWorkspaceFileContent(value) {
4495
4509
  const obj = asRecord(value);
4510
+ if (typeof obj.content !== "string") {
4511
+ throw new CliError({
4512
+ code: "NETWORK_ERROR" /* NETWORK_ERROR */,
4513
+ message: "\u5DE5\u4F5C\u533A load-content \u54CD\u5E94\u7F3A\u5C11\u5B57\u7B26\u4E32 content\uFF0C\u65E0\u6CD5\u786E\u8BA4\u8FDC\u7AEF\u5185\u5BB9\u3002",
4514
+ context: {
4515
+ reason: "INVALID_WORKSPACE_FILE_CONTENT",
4516
+ nextStep: "\u68C0\u67E5\u670D\u52A1\u7AEF load-content \u56DE\u6267\u540E\u91CD\u65B0\u8BFB\u53D6\uFF1B\u4E0D\u80FD\u5C06\u7F3A\u5931\u6B63\u6587\u5F53\u4F5C\u7A7A\u6587\u4EF6\u7EE7\u7EED\u63A8\u9001\u3002"
4517
+ }
4518
+ });
4519
+ }
4496
4520
  return {
4497
4521
  workspaceKey: stringOr(obj.workspaceKey),
4498
4522
  relativePath: stringOr(obj.relativePath),
4499
- content: stringOr(obj.content),
4523
+ content: obj.content,
4500
4524
  fileType: stringOrUndefined(obj.fileType)
4501
4525
  };
4502
4526
  }
@@ -7144,7 +7168,7 @@ async function deleteTenantMeta(http, path24) {
7144
7168
  import yaml9 from "js-yaml";
7145
7169
 
7146
7170
  // src/meta/generated/meta-schemas.ts
7147
- var META_SCHEMA_SOURCE_COMMIT = "9c205ad33da978414b101ce79b3f091a60779a34";
7171
+ var META_SCHEMA_SOURCE_COMMIT = "2d4b4a9ee24111c6ff425f88d109b2eddf811b51";
7148
7172
  var META_SCHEMAS = {
7149
7173
  list: {
7150
7174
  "$schema": "https://json-schema.org/draft/2020-12/schema",
@@ -7160,6 +7184,19 @@ var META_SCHEMAS = {
7160
7184
  }
7161
7185
  }
7162
7186
  },
7187
+ "IconField": {
7188
+ "type": "object",
7189
+ "properties": {
7190
+ "field": {
7191
+ "type": "string",
7192
+ "description": "\u672C\u5217\u8868 fields[].key"
7193
+ },
7194
+ "icon": {
7195
+ "type": "string",
7196
+ "description": "\u56FE\u6807\u540D\uFF0C\u53D6\u503C\u89C1\u6240\u5728\u69FD\u4F4D\u8BF4\u660E"
7197
+ }
7198
+ }
7199
+ },
7163
7200
  "JsonNode": {
7164
7201
  "type": "object"
7165
7202
  },
@@ -8300,6 +8337,105 @@ var META_SCHEMAS = {
8300
8337
  },
8301
8338
  "description": "\u884C\u4E3A\u80FD\u529B\u5F00\u5173;\u524D\u7AEF ListView \u636E\u6B64\u51B3\u5B9A\u6E32\u67D3\u4EC0\u4E48(\u66FF\u4EE3\u6309 kind \u5206\u53C9)\u3002\u7F3A\u7701\u89C6\u4F5C\u5168\u5F00,\u5411\u540E\u517C\u5BB9\u3002\u8BE6\u89C1 CapabilitiesMeta"
8302
8339
  },
8340
+ "cardRow": {
8341
+ "type": "object",
8342
+ "properties": {
8343
+ "avatar": {
8344
+ "type": "string",
8345
+ "description": "\u5934\u50CF\u5B57\u6BB5 key\uFF1A\u56FE\u7247\u5730\u5740 / /api \u8DEF\u5F84 / \u6587\u6863 id\uFF1B\u7A7A\u3001\u65E0\u6743\u6216\u52A0\u8F7D\u5931\u8D25\u663E\u793A\u6807\u9898\u9996\u5B57",
8346
+ "minLength": 1
8347
+ },
8348
+ "badges": {
8349
+ "description": "\u6807\u9898\u53F3\u4FA7\u6807\u7B7E\u533A\u5B57\u6BB5 key \u5217\u8868\uFF1B\u6309\u5B57\u6BB5 mask \u7740\u8272\uFF0C\u7A7A\u503C\u6216 mask \u6807\u7B7E\u4E3A\u7A7A\u4E0D\u663E\u793A",
8350
+ "type": "array",
8351
+ "items": {
8352
+ "type": "string",
8353
+ "minLength": 1
8354
+ },
8355
+ "minItems": 1
8356
+ },
8357
+ "footer": {
8358
+ "description": "\u53F3\u4E0B\u89D2\u7070\u8272\u5C0F\u5B57\u5B57\u6BB5 key \u5217\u8868\uFF0C\u7A7A\u503C\u8DF3\u8FC7",
8359
+ "type": "array",
8360
+ "items": {
8361
+ "type": "string",
8362
+ "minLength": 1
8363
+ },
8364
+ "minItems": 1
8365
+ },
8366
+ "hints": {
8367
+ "description": "\u6807\u9898\u53F3\u4FA7\u56FE\u6807\uFF0C\u60AC\u505C\u663E\u793A\u503C\uFF1Bicon \u53D6 phone/email/location/time/info",
8368
+ "type": "array",
8369
+ "items": {
8370
+ "type": "object",
8371
+ "additionalProperties": false,
8372
+ "required": ["field"],
8373
+ "properties": {
8374
+ "field": {
8375
+ "type": "string",
8376
+ "minLength": 1
8377
+ },
8378
+ "icon": {
8379
+ "type": "string",
8380
+ "enum": ["phone", "email", "location", "time", "info"]
8381
+ }
8382
+ }
8383
+ },
8384
+ "minItems": 1
8385
+ },
8386
+ "lines": {
8387
+ "description": "\u591A\u884C\u4FE1\u606F\uFF1A\u6BCF\u884C\u4E00\u7EC4\u5B57\u6BB5 key\uFF0C\u7AD6\u7EBF\u5206\u9694\uFF0C\u7A7A\u503C\u8DF3\u8FC7",
8388
+ "type": "array",
8389
+ "items": {
8390
+ "type": "array",
8391
+ "items": {
8392
+ "type": "string",
8393
+ "minLength": 1
8394
+ },
8395
+ "minItems": 1
8396
+ },
8397
+ "minItems": 1
8398
+ },
8399
+ "marker": {
8400
+ "type": "string",
8401
+ "description": "\u6807\u9898\u524D\u63D0\u9192\u5706\u70B9\u7684\u5E03\u5C14\u5B57\u6BB5 key\uFF08\u5982\u672A\u8BFB\uFF09\uFF1B\u503C\u4E3A\u771F\u663E\u793A",
8402
+ "minLength": 1
8403
+ },
8404
+ "summary": {
8405
+ "description": "\u53F3\u4FA7\u6458\u8981\u533A\uFF0C\u6BCF\u6BB5\u4E00\u4E2A\u5B57\u6BB5\uFF08\u53EF\u591A\u884C\u6587\u5B57\uFF09\uFF1Bicon \u53D6 education/work/project/info",
8406
+ "type": "array",
8407
+ "items": {
8408
+ "type": "object",
8409
+ "additionalProperties": false,
8410
+ "required": ["field"],
8411
+ "properties": {
8412
+ "field": {
8413
+ "type": "string",
8414
+ "minLength": 1
8415
+ },
8416
+ "icon": {
8417
+ "type": "string",
8418
+ "enum": ["education", "work", "project", "info"]
8419
+ }
8420
+ }
8421
+ },
8422
+ "minItems": 1
8423
+ },
8424
+ "tags": {
8425
+ "type": "string",
8426
+ "description": "\u5C0F\u6807\u7B7E\u884C\uFF1A\u6570\u7EC4\u5B57\u6BB5 key\uFF0C\u6BCF\u4E2A\u5143\u7D20\u4E00\u4E2A\u6807\u7B7E",
8427
+ "minLength": 1
8428
+ },
8429
+ "title": {
8430
+ "type": "string",
8431
+ "description": "\u4E3B\u6807\u9898\u5B57\u6BB5 key\uFF08\u5FC5\u586B\uFF09\uFF1B\u5B57\u6BB5\u7684 clickActionKey \u7167\u5E38\u751F\u6548",
8432
+ "minLength": 1
8433
+ }
8434
+ },
8435
+ "description": "\u5361\u7247\u884C\u6A21\u677F;\u58F0\u660E\u540E card \u89C6\u56FE\u6539\u4E3A\u4E00\u884C\u4E00\u5F20\u5361,\u69FD\u4F4D\u503C\u4E3A\u672C\u5217\u8868 fields[].key\u3002\u9700 frontend capability 1.57.0",
8436
+ "required": ["title"],
8437
+ "additionalProperties": false
8438
+ },
8303
8439
  "defaultSort": {
8304
8440
  "description": "\u9ED8\u8BA4\u6392\u5E8F;\u5F62\u5982 [{field:'name',order:'asc'},...]\u3002\u5220\u9664\u8BF7\u7528 {__remove:true}",
8305
8441
  "type": "array",
@@ -8332,15 +8468,9 @@ var META_SCHEMAS = {
8332
8468
  "type": "string",
8333
8469
  "enum": ["left", "center", "right"]
8334
8470
  },
8335
- "autoGenerate": {
8336
- "type": "boolean"
8337
- },
8338
8471
  "clickActionKey": {
8339
8472
  "type": "string"
8340
8473
  },
8341
- "codeRuleConfigurable": {
8342
- "type": "boolean"
8343
- },
8344
8474
  "component": {
8345
8475
  "type": "string"
8346
8476
  },
@@ -8494,6 +8624,10 @@ var META_SCHEMAS = {
8494
8624
  },
8495
8625
  "description": "\u5217\u8868\u5916\u5C42\u5E03\u5C40,\u5982 tree-list(\u5DE6\u6811\u53F3\u5217\u8868)\u3002\u8BE6\u89C1 ListLayout \u7C7B\u578B"
8496
8626
  },
8627
+ "metaPluginRefreshFilters": {
8628
+ "type": "boolean",
8629
+ "description": "\u52A8\u6001\u5217\u63D2\u4EF6\u53C2\u6570\u53D8\u5316\u65F6\u662F\u5426\u8FDE\u540C\u7B5B\u9009\u914D\u7F6E\u4E00\u8D77\u91CD\u53D6;\u9ED8\u8BA4 false \u53EA\u91CD\u53D6\u5217"
8630
+ },
8497
8631
  "mobileCard": {
8498
8632
  "type": "object",
8499
8633
  "properties": {
@@ -8626,11 +8760,33 @@ var META_SCHEMAS = {
8626
8760
  "showEmptyGroups": {
8627
8761
  "type": "boolean",
8628
8762
  "description": "\u662F\u5426\u663E\u793A\u8BA1\u6570\u4E3A 0 \u7684\u5DF2\u77E5\u5206\u7EC4(\u9ED8\u8BA4 false)"
8763
+ },
8764
+ "source": {
8765
+ "type": "object",
8766
+ "properties": {
8767
+ "action": {
8768
+ "type": "string",
8769
+ "description": "\u7ED3\u6784\u751F\u6210\u5668\u7684\u952E;\u4E1A\u52A1\u53EF\u53E6\u4EE5\u540C\u540D\u7C7B\u52A8\u4F5C\u590D\u7528\u540C\u4E00\u751F\u6210\u5668",
8770
+ "minLength": 1
8771
+ },
8772
+ "model": {
8773
+ "type": "string",
8774
+ "description": "\u7ED3\u6784\u751F\u6210\u5668\u6240\u5C5E\u6A21\u578B",
8775
+ "minLength": 1
8776
+ }
8777
+ },
8778
+ "description": "\u9875\u7B7E\u7ED3\u6784\u7531\u4E1A\u52A1\u7ED3\u6784\u751F\u6210\u5668\u63D0\u4F9B(\u4E0E groupField \u4E8C\u9009\u4E00,capabilityVersion \u2265 1.56.0);\u524D\u7AEF\u8C03 POST /list/statBarTree,\u4EBA\u6570\u4ECD\u7531\u5E73\u53F0\u6309\u5217\u8868\u540C\u53E3\u5F84\u8BA1\u6570",
8779
+ "additionalProperties": false,
8780
+ "required": ["model", "action"]
8629
8781
  }
8630
8782
  },
8631
- "description": "\u5217\u8868\u9876\u90E8\u7EDF\u8BA1 Tab \u914D\u7F6E;\u6309 groupField \u805A\u5408\u8BA1\u6570,\u70B9\u51FB Tab \u9644\u52A0\u8FC7\u6EE4\u6761\u4EF6",
8783
+ "description": "\u5217\u8868\u9876\u90E8\u7EDF\u8BA1 Tab \u914D\u7F6E;\u6309 groupField \u805A\u5408\u8BA1\u6570(\u70B9\u51FB Tab \u9644\u52A0\u8FC7\u6EE4\u6761\u4EF6),\u6216\u58F0\u660E source \u7531\u4E1A\u52A1\u7ED3\u6784\u751F\u6210\u5668\u7ED9\u51FA\u9875\u7B7E\u6811(\u4EBA\u6570\u4ECD\u7531\u5E73\u53F0\u6309\u5217\u8868\u540C\u53E3\u5F84\u8BA1\u6570)",
8632
8784
  "additionalProperties": false,
8633
- "required": ["groupField"]
8785
+ "anyOf": [{
8786
+ "required": ["groupField"]
8787
+ }, {
8788
+ "required": ["source"]
8789
+ }]
8634
8790
  },
8635
8791
  "toolbar": {
8636
8792
  "type": "object",
@@ -9271,12 +9427,6 @@ var META_SCHEMAS = {
9271
9427
  "items": {
9272
9428
  "type": "object",
9273
9429
  "properties": {
9274
- "autoGenerate": {
9275
- "type": "boolean"
9276
- },
9277
- "codeRuleConfigurable": {
9278
- "type": "boolean"
9279
- },
9280
9430
  "component": {
9281
9431
  "type": "string"
9282
9432
  },
@@ -9998,12 +10148,6 @@ var META_SCHEMAS = {
9998
10148
  "items": {
9999
10149
  "type": "object",
10000
10150
  "properties": {
10001
- "autoGenerate": {
10002
- "type": "boolean"
10003
- },
10004
- "codeRuleConfigurable": {
10005
- "type": "boolean"
10006
- },
10007
10151
  "component": {
10008
10152
  "type": "string"
10009
10153
  },
@@ -10084,15 +10228,9 @@ var META_SCHEMAS = {
10084
10228
  "items": {
10085
10229
  "type": "object",
10086
10230
  "properties": {
10087
- "autoGenerate": {
10088
- "type": "boolean"
10089
- },
10090
10231
  "bindsEffectiveDate": {
10091
10232
  "type": "boolean"
10092
10233
  },
10093
- "codeRuleConfigurable": {
10094
- "type": "boolean"
10095
- },
10096
10234
  "component": {
10097
10235
  "type": "string"
10098
10236
  },
@@ -10497,16 +10635,10 @@ var META_SCHEMAS = {
10497
10635
  "items": {
10498
10636
  "type": "object",
10499
10637
  "properties": {
10500
- "autoGenerate": {
10501
- "type": "boolean"
10502
- },
10503
10638
  "bareTextOperator": {
10504
10639
  "type": ["string", "null"],
10505
10640
  "enum": ["contains", "eq", null]
10506
10641
  },
10507
- "codeRuleConfigurable": {
10508
- "type": "boolean"
10509
- },
10510
10642
  "columnDefinition": {
10511
10643
  "type": "string"
10512
10644
  },
@@ -11244,6 +11376,37 @@ var META_SCHEMAS = {
11244
11376
  "label": {
11245
11377
  "type": "string"
11246
11378
  },
11379
+ "menuFormFilters": {
11380
+ "type": "array",
11381
+ "items": {
11382
+ "type": "object",
11383
+ "additionalProperties": false,
11384
+ "required": ["param", "field"],
11385
+ "properties": {
11386
+ "param": {
11387
+ "type": "string",
11388
+ "minLength": 1,
11389
+ "description": "\u5DE6\u680F\u8868\u5355\u9879 key"
11390
+ },
11391
+ "field": {
11392
+ "type": "string",
11393
+ "minLength": 1,
11394
+ "description": "\u672C\u5217\u8868\u6A21\u578B\u4E0A\u53EF\u7B5B\u9009\u7684\u5B57\u6BB5"
11395
+ }
11396
+ }
11397
+ },
11398
+ "minItems": 1,
11399
+ "description": "\u5DE6\u680F\u7B5B\u9009\u8868\u5355(menu.source.form)\u7684\u503C\u5E76\u8FDB\u672C\u5217\u8868\u6761\u4EF6:\u5355\u503C eq\u3001\u6570\u7EC4 in\u3001\u7A7A\u4E0D\u52A0,\u4E0E\u5DE6\u680F\u9009\u4E2D\u6761\u4EF6\u5E73\u94FA\u5728\u540C\u4E00\u4E2A\u9876\u5C42\u300C\u5E76\u4E14\u300D\u7EC4\u3002\u9700 frontend capability 1.57.0"
11400
+ },
11401
+ "metaPlugin": {
11402
+ "type": "string"
11403
+ },
11404
+ "metaPluginFilterKeys": {
11405
+ "type": "array",
11406
+ "items": {
11407
+ "type": "string"
11408
+ }
11409
+ },
11247
11410
  "model": {
11248
11411
  "type": "string"
11249
11412
  },
@@ -11351,9 +11514,23 @@ var META_SCHEMAS = {
11351
11514
  }
11352
11515
  }
11353
11516
  },
11517
+ "Map(String,Object)": {
11518
+ "type": "object"
11519
+ },
11354
11520
  "Map(String,String)": {
11355
11521
  "type": "object"
11356
11522
  },
11523
+ "MenuFormFilter": {
11524
+ "type": "object",
11525
+ "properties": {
11526
+ "field": {
11527
+ "type": "string"
11528
+ },
11529
+ "param": {
11530
+ "type": "string"
11531
+ }
11532
+ }
11533
+ },
11357
11534
  "RelationConfig": {
11358
11535
  "type": "object",
11359
11536
  "properties": {
@@ -11591,9 +11768,6 @@ var META_SCHEMAS = {
11591
11768
  }
11592
11769
  }
11593
11770
  },
11594
- "Map(String,Object)": {
11595
- "type": "object"
11596
- },
11597
11771
  "MasterNavigationConfig": {
11598
11772
  "type": "object",
11599
11773
  "properties": {
@@ -11793,6 +11967,78 @@ var META_SCHEMAS = {
11793
11967
  "type": "boolean",
11794
11968
  "description": "style=list \u65F6\u662F\u5426\u5728\u52A8\u6001\u5206\u7C7B\u9876\u90E8\u5C55\u793A\u2018\u5168\u90E8\u2019\u9879"
11795
11969
  },
11970
+ "source": {
11971
+ "type": "object",
11972
+ "additionalProperties": false,
11973
+ "required": ["model", "action"],
11974
+ "description": "style=list \u65F6\u5DE6\u4FA7\u5217\u8868\u6539\u7531\u4E1A\u52A1\u7C7B\u52A8\u4F5C\u63D0\u4F9B;\u52A8\u4F5C\u8FD4\u56DE {items:[{key,label,count?}],allCount?,appliedParams?,notice?},count \u7F3A\u7701\u4E0D\u663E\u793A\u6570\u5B57;\u9009\u300C\u5168\u90E8\u300D\u65F6\u53F3\u4FA7\u6761\u4EF6\u4E3A targetField in [\u5168\u90E8 key]\u3002\u4E0D\u914D\u7F6E\u6CBF\u7528\u6309 master \u6A21\u578B\u53D6\u6570",
11975
+ "properties": {
11976
+ "model": {
11977
+ "type": "string",
11978
+ "minLength": 1,
11979
+ "description": "\u7C7B\u52A8\u4F5C\u6240\u5728\u6A21\u578B"
11980
+ },
11981
+ "action": {
11982
+ "type": "string",
11983
+ "minLength": 1,
11984
+ "description": "\u7C7B\u52A8\u4F5C\u540D"
11985
+ },
11986
+ "countLabel": {
11987
+ "type": "string",
11988
+ "minLength": 1,
11989
+ "description": "\u6570\u5B57\u7684\u542B\u4E49,\u60AC\u505C\u663E\u793A,\u5982\u300C\u5728\u9014\u300D"
11990
+ },
11991
+ "form": {
11992
+ "type": "object",
11993
+ "additionalProperties": false,
11994
+ "required": ["fields"],
11995
+ "description": "\u5DE6\u680F\u7B5B\u9009\u8868\u5355;fields \u5199\u6CD5\u540C\u52A8\u4F5C\u53C2\u6570\u8868\u5355 formSchema.fields,\u8868\u5355\u503C\u4F5C\u4E3A GET \u53C2\u6570\u4F20\u7ED9 source \u52A8\u4F5C;\u52A8\u4F5C\u53EF\u8FD4\u56DE appliedParams \u56DE\u586B\u3001notice \u8BF4\u660E\u3002\u9700 frontend capability 1.57.0",
11996
+ "properties": {
11997
+ "title": {
11998
+ "type": "string",
11999
+ "minLength": 1,
12000
+ "description": "\u8868\u5355\u6807\u9898;\u6709\u5219\u663E\u793A\u6807\u9898\u884C\u4E0E\u6536\u8D77/\u5C55\u5F00"
12001
+ },
12002
+ "fields": {
12003
+ "type": "array",
12004
+ "minItems": 1,
12005
+ "items": {
12006
+ "type": "object",
12007
+ "required": ["key", "label", "component"],
12008
+ "properties": {
12009
+ "key": {
12010
+ "type": "string",
12011
+ "minLength": 1
12012
+ },
12013
+ "label": {
12014
+ "type": "string",
12015
+ "minLength": 1
12016
+ },
12017
+ "component": {
12018
+ "type": "string",
12019
+ "minLength": 1
12020
+ },
12021
+ "visibleWhen": {
12022
+ "type": "object",
12023
+ "required": ["field", "operator"],
12024
+ "properties": {
12025
+ "field": {
12026
+ "type": "string",
12027
+ "minLength": 1
12028
+ },
12029
+ "operator": {
12030
+ "type": "string",
12031
+ "enum": ["eq", "ne", "in", "notIn"]
12032
+ }
12033
+ }
12034
+ }
12035
+ }
12036
+ }
12037
+ }
12038
+ }
12039
+ }
12040
+ }
12041
+ },
11796
12042
  "style": {
11797
12043
  "type": "string",
11798
12044
  "description": "\u83DC\u5355\u5C55\u793A\u98CE\u683C\uFF1Amenu=\u9759\u6001\u83DC\u5355\uFF0Ctabs=\u6807\u7B7E\u9875\uFF0Clist=\u52A8\u6001\u5206\u7C7B\u5217\u8868\uFF0Csteps=\u5411\u5BFC\u6B65\u9AA4\u6761\uFF08\u4E00\u4E2A menu.groups \u9879\u4E00\u4E2A\u9636\u6BB5\uFF0C\u9636\u6BB5\u5185\u591A\u5B50\u96C6\u964D\u4E3A\u4E8C\u7EA7\u9875\u7B7E\uFF0C\u6545 details \u6570\u53EF\u591A\u4E8E groups \u6570\uFF09\u3002enum \u662F\u624B\u5DE5\u6536\u7A84\uFF08generator \u53EA\u4EA7\u51FA type:string\uFF09\uFF0C\u52FF\u76F2\u8DD1 generateMetaSchema \u8986\u76D6\u3002",
@@ -13237,14 +13483,20 @@ function metaKindFromPath(metaPath2) {
13237
13483
  if (parts.length < 2) return "model";
13238
13484
  return parts[1];
13239
13485
  }
13486
+ var RETIRED_CODE_RULE_HINTS = {
13487
+ autoGenerate: "\u6B64\u7F16\u7801\u5143\u6570\u636E\u5C5E\u6027\u5DF2\u9000\u5F79\uFF1B\u8BF7\u6309\u79DF\u6237\u542F\u7528\u7684\u7F16\u7801\u89C4\u5219\u5904\u7406\uFF0C\u65E0\u89C4\u5219\u65F6\u624B\u5DE5\u6307\u5B9A\u7F16\u7801",
13488
+ codeRuleConfigurable: "\u6B64\u7F16\u7801\u5143\u6570\u636E\u5C5E\u6027\u5DF2\u9000\u5F79\uFF1B\u8BF7\u6309\u79DF\u6237\u542F\u7528\u7684\u7F16\u7801\u89C4\u5219\u5904\u7406\uFF0C\u65E0\u89C4\u5219\u65F6\u624B\u5DE5\u6307\u5B9A\u7F16\u7801"
13489
+ };
13240
13490
  var ALIAS_HINTS = {
13241
13491
  list: {
13492
+ ...RETIRED_CODE_RULE_HINTS,
13242
13493
  hide: "\u5217\u8868\u5C42\u7684\u663E\u9690\u952E\u662F `visible`\uFF08\u8BED\u4E49\u76F8\u53CD\uFF1A`hide: true` \u21D2 `visible: false`\uFF09",
13243
13494
  hidden: "\u5217\u8868\u5C42\u7684\u663E\u9690\u952E\u662F `visible`\uFF08\u8BED\u4E49\u76F8\u53CD\uFF09",
13244
13495
  title: "\u5217\u6807\u9898\u7528 `label`",
13245
13496
  displayName: "\u5217\u6807\u9898\u7528 `label`"
13246
13497
  },
13247
13498
  model: {
13499
+ ...RETIRED_CODE_RULE_HINTS,
13248
13500
  // 模型字段层的显示名键是 `name`:`ModelFieldMeta` 上根本没有 `label` 属性、也没有
13249
13501
  // `@JsonAlias("label")`,写上去 Jackson 静默丢弃(`FAIL_ON_UNKNOWN_PROPERTIES=false`)。
13250
13502
  // `label` 在 `enums[]` / `relations[]` 这类子对象里是合法的,所以只在字段项这一层提醒。
@@ -13253,11 +13505,14 @@ var ALIAS_HINTS = {
13253
13505
  displayName: "\u6A21\u578B\u5B57\u6BB5\u5C42\u7684\u663E\u793A\u540D\u952E\u662F `name`"
13254
13506
  },
13255
13507
  info: {
13508
+ ...RETIRED_CODE_RULE_HINTS,
13256
13509
  hide: "\u8BE6\u60C5/\u8868\u5355\u5C42\u7684\u663E\u9690\u952E\u662F `hidden`",
13257
13510
  visible: "\u8BE6\u60C5/\u8868\u5355\u5C42\u7684\u663E\u9690\u952E\u662F `hidden`\uFF08\u8BED\u4E49\u76F8\u53CD\uFF1A`visible: false` \u21D2 `hidden: true`\uFF09",
13258
13511
  title: "\u5B57\u6BB5\u6807\u9898\u7528 `label`",
13259
13512
  displayName: "\u5B57\u6BB5\u6807\u9898\u7528 `label`"
13260
- }
13513
+ },
13514
+ view: { ...RETIRED_CODE_RULE_HINTS },
13515
+ filter: { ...RETIRED_CODE_RULE_HINTS }
13261
13516
  };
13262
13517
  function resolveRef(root, schema) {
13263
13518
  let cur = schema;