@epxing/business 5.3.0-beta.2 → 5.3.0-beta.3

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.
Files changed (98) hide show
  1. package/API.md +8 -4
  2. package/README.md +44 -44
  3. package/dist/src/base/AiSkillEditor.js +1 -1
  4. package/dist/src/base/AiSkillEditor.vue.js +2 -0
  5. package/dist/src/base/AppConfigFormItem.js +1 -3
  6. package/dist/src/base/AppConfigFormItem.vue.js +210 -85
  7. package/dist/src/base/CommonFieldList.js +1 -1
  8. package/dist/src/base/CommonFieldList.vue.js +2 -1
  9. package/dist/src/base/ConfigModuleIndex.js +38 -1
  10. package/dist/src/base/ManageAppNav.js +1 -1
  11. package/dist/src/base/ManageMenu.js +1 -1
  12. package/dist/src/base/RoleBindTrace.js +253 -0
  13. package/dist/src/base/RoleGroupManage.js +1037 -0
  14. package/dist/src/base/ServiceMenu.js +7 -6
  15. package/dist/src/components/AiList.js +1278 -3
  16. package/dist/src/components/EntityCheckboxFind.vue.js +14 -10
  17. package/dist/src/components/EntityRightFormItem.js +1 -5
  18. package/dist/src/components/EntityRightFormItem.vue.js +3 -1
  19. package/dist/src/components/EntitySystemEr.js +492 -0
  20. package/dist/src/components/HallNav.vue.js +7 -36
  21. package/dist/src/components/IconFontLibrary.js +22 -1
  22. package/dist/src/components/IconFontList.js +21 -1
  23. package/dist/src/components/PrintFormList.js +2 -1
  24. package/dist/src/components/PrintFormList.vue.js +3 -1
  25. package/dist/src/components/WikiWorkbench.js +153 -129
  26. package/dist/src/components/authorization/AuthorizationInterface.js +3 -1
  27. package/dist/src/components/custom-bpmn/PropertiesView.js +1991 -1942
  28. package/dist/src/components/icon-gallery/IconGallery.js +193 -0
  29. package/dist/src/components/icon-gallery/mixin.js +150 -0
  30. package/dist/src/components/wiki-workbench/WikiIntake.js +86 -93
  31. package/dist/src/components/wiki-workbench/WikiIntake.vue.js +153 -73
  32. package/dist/src/index.js +26 -20
  33. package/dist/src/public-components.js +16 -14
  34. package/dist/src/route-components.js +5 -5
  35. package/dist/src/system.component.index.js +1 -1
  36. package/dist/src/system.component.js +8 -3
  37. package/dist/src/system.component.lazy.js +1 -1
  38. package/dist/src/views/Add.js +1 -1
  39. package/dist/src/views/Add.vue.js +8 -3
  40. package/dist/src/views/AiToolManager.js +792 -317
  41. package/dist/src/views/App.js +3 -45
  42. package/dist/src/views/AppRoleSelect.js +3 -230
  43. package/dist/src/views/Error.js +3 -207
  44. package/dist/src/views/ExcelDesign.js +326 -316
  45. package/dist/src/views/JvmMemoryMonitor.js +463 -0
  46. package/dist/src/views/Module.js +3 -170
  47. package/dist/src/views/WikiBinding.js +88 -25
  48. package/dist/style.css +2867 -1487
  49. package/package.json +12 -6
  50. package/src/base/AiSkillEditor.vue +2 -0
  51. package/src/base/AppConfigFormItem.vue +211 -145
  52. package/src/base/CommonFieldList.vue +9 -6
  53. package/src/base/ConfigModuleIndex.vue +37 -1
  54. package/src/base/ManageAppNav.vue +1188 -1188
  55. package/src/base/ManageMenu.vue +933 -933
  56. package/src/base/RoleBindTrace.vue +364 -0
  57. package/src/base/RoleGroupManage.vue +1160 -0
  58. package/src/base/ServiceMenu.vue +6 -5
  59. package/src/components/AiList.vue +439 -113
  60. package/src/components/EntityCheckboxFind.vue +12 -8
  61. package/src/components/EntityRightFormItem.vue +9 -10
  62. package/src/components/EntitySystemEr.vue +517 -0
  63. package/src/components/HallNav.vue +6 -33
  64. package/src/components/IconFontLibrary.vue +27 -60
  65. package/src/components/IconFontList.vue +13 -64
  66. package/src/components/PrintFormList.vue +33 -27
  67. package/src/components/WikiWorkbench.vue +90 -60
  68. package/src/components/authorization/AuthorizationInterface.vue +2 -0
  69. package/src/components/custom-bpmn/CustomPalette.js +1 -1
  70. package/src/components/custom-bpmn/CustomRenderer.js +1 -1
  71. package/src/components/custom-bpmn/PropertiesView.vue +35 -4
  72. package/src/components/custom-bpmn/index.js +1 -1
  73. package/src/components/icon-gallery/IconGallery.vue +130 -0
  74. package/src/components/icon-gallery/mixin.jsx +109 -0
  75. package/src/components/wiki-workbench/WikiIntake.vue +178 -104
  76. package/src/index.js +24 -20
  77. package/src/public-components.js +1 -0
  78. package/src/route-components.js +4 -4
  79. package/src/system.component.index.js +1 -1
  80. package/src/views/Add.vue +8 -5
  81. package/src/views/AiToolManager.vue +326 -4
  82. package/src/views/App.vue +4 -53
  83. package/src/views/AppRoleSelect.vue +4 -334
  84. package/src/views/Error.vue +4 -63
  85. package/src/views/ExcelDesign.vue +24 -7
  86. package/src/views/JvmMemoryMonitor.vue +284 -0
  87. package/src/views/Module.vue +4 -210
  88. package/src/views/WikiBinding.vue +42 -0
  89. package/types/app.d.ts +1 -0
  90. package/types/dept-find.d.ts +1 -1
  91. package/types/index.d.ts +15 -14
  92. package/types/popup.d.ts +2 -2
  93. package/types/route-components.d.ts +1 -1
  94. package/types/user-find.d.ts +1 -1
  95. package/dist/assets/role_select-DTqRlFNz.webp +0 -0
  96. package/dist/src/components/AiList.vue.js +0 -93
  97. package/dist/src/components/IconFontLibrary.vue.js +0 -67
  98. package/dist/src/components/IconFontList.vue.js +0 -79
@@ -1,4 +1,5 @@
1
1
  import '../../style.css';
2
+ import { resolveComponent, resolveDirective, withDirectives, openBlock, createElementBlock, normalizeStyle, createElementVNode, Fragment, renderList, normalizeClass, toDisplayString, createBlock, withCtx, createTextVNode, createCommentVNode, createVNode, vShow, h } from "vue";
2
3
  import component from "@epxing/core/src/mixins/component";
3
4
  import { WikiDoc, WikiTree } from "@epxing/components/src/wiki-site";
4
5
  import WikiJobs from "./wiki-workbench/WikiJobs.js";
@@ -7,7 +8,6 @@ import WikiCites from "./wiki-workbench/WikiCites.js";
7
8
  import WikiIntake from "./wiki-workbench/WikiIntake.js";
8
9
  import WikiSpaceSettings from "./wiki-workbench/WikiSpaceSettings.js";
9
10
  import { resolvePath, pagePath } from "@epxing/components/src/wiki-site/wiki-path";
10
- import { resolveComponent, resolveDirective, withDirectives, openBlock, createElementBlock, normalizeStyle, createElementVNode, Fragment, renderList, normalizeClass, toDisplayString, createBlock, withCtx, createTextVNode, createCommentVNode, createVNode, vShow } from "vue";
11
11
  /* empty css */
12
12
  import _export_sfc from "../../_virtual/_plugin-vue_export-helper.js";
13
13
  const WIKI_META = "FM_AI_WIKI";
@@ -38,11 +38,11 @@ const _sfc_main = {
38
38
  boxHeight: "100%",
39
39
  tab: "content",
40
40
  editing: false,
41
+ managing: false,
41
42
  // 编辑器里的内容改过没有。由 WikiDoc 报上来——它才知道基准是草稿还是已发布正文
42
43
  dirty: false,
43
44
  syncing: false,
44
45
  inspecting: false,
45
- reindexing: false,
46
46
  tabs: [
47
47
  { key: "content", name: "内容" },
48
48
  { key: "intake", name: "原始文件" },
@@ -67,11 +67,6 @@ const _sfc_main = {
67
67
  initialPath() {
68
68
  return this.$query.path || this.$route.query.path || "";
69
69
  },
70
- /** 新建时放在当前页所在目录下——人多半是在「这一块」里继续加内容。 */
71
- currentDir() {
72
- const p = this.path || "";
73
- return p.includes("/") ? p.slice(0, p.lastIndexOf("/")) : "";
74
- },
75
70
  pageWithSpace() {
76
71
  return { ...this.doc, wikiId: this.wikiId };
77
72
  },
@@ -116,6 +111,11 @@ const _sfc_main = {
116
111
  }
117
112
  },
118
113
  methods: {
114
+ switchTab(key) {
115
+ if (key === this.tab) return;
116
+ this.tab = key;
117
+ if (key === "content") this.refreshContent();
118
+ },
119
119
  /**
120
120
  * 量出可用高度。
121
121
  *
@@ -137,8 +137,8 @@ const _sfc_main = {
137
137
  }
138
138
  this.measured = true;
139
139
  const marginBottom = parseFloat(window.getComputedStyle(el).marginBottom) || 0;
140
- const h = Math.max(320, Math.floor(this.availBottom() - rect.top - marginBottom));
141
- const next = h + "px";
140
+ const h2 = Math.max(320, Math.floor(this.availBottom() - rect.top - marginBottom));
141
+ const next = h2 + "px";
142
142
  if (next !== this.boxHeight) this.boxHeight = next;
143
143
  },
144
144
  /**
@@ -177,25 +177,25 @@ const _sfc_main = {
177
177
  return this.$http.get({ action: "space", entityId: WIKI_META, wikiId: this.wikiId }).then((d) => {
178
178
  this.space = d && d.space || {};
179
179
  this.nodes = d && d.nodes || [];
180
- if (!this.path && this.initialPath) {
181
- this.doOpen(this.initialPath);
180
+ if (!this.path && this.initialPath && this.nodes.some((n) => n.path === this.initialPath)) {
181
+ return this.doOpen(this.initialPath);
182
182
  } else if (!this.path) {
183
183
  const first = this.nodes.find((n) => n.type === "page");
184
- if (first) this.openPage(first.path);
184
+ if (first) return this.doOpen(first.path);
185
185
  }
186
186
  }).catch((e) => this.$message.error(e && e.message || "空间加载失败")).finally(() => {
187
187
  this.loading = false;
188
188
  });
189
189
  },
190
- /** 原始文件处理完成后,目录与当前正文都可能改变,两部分必须一起重取。 */
190
+ /** 页发生增删或生成后,目录与当前正文都重新读取。 */
191
191
  refreshContent() {
192
192
  const current = this.path;
193
193
  return this.load().then(() => {
194
194
  if (current) return this.doOpen(current);
195
195
  });
196
196
  },
197
- newPage() {
198
- this.$prompt("新页会先落成草稿,发布之后才写回源。", "新建页", {
197
+ newPage(dir) {
198
+ this.$prompt("位置:" + (dir || "根目录") + "。新页先保存为草稿,发布后写回源。", "新建页", {
199
199
  confirmButtonText: "创建",
200
200
  cancelButtonText: "取消",
201
201
  inputPlaceholder: "页标题"
@@ -206,17 +206,19 @@ const _sfc_main = {
206
206
  entityId: WIKI_META,
207
207
  wikiId: this.wikiId,
208
208
  title: value.trim(),
209
- dir: this.currentDir
209
+ dir
210
210
  }).then((d) => {
211
211
  this.$message.success(d && d.message || "已新建");
212
- this.load();
213
- if (d && d.path) this.doOpen(d.path);
212
+ return this.load().then(() => {
213
+ if (d && d.path) return this.doOpen(d.path);
214
+ });
214
215
  });
215
- }).catch(() => {
216
+ }).catch((e) => {
217
+ if (e !== "cancel" && e !== "close") this.$message.error(e && e.message || "新建页失败");
216
218
  });
217
219
  },
218
- newFolder() {
219
- this.$prompt("文件夹只是路径的一段,不会往源里写文件。", "新建文件夹", {
220
+ newFolder(dir) {
221
+ this.$prompt("位置:" + (dir || "根目录") + "。文件夹不会往源里写文件。", "新建文件夹", {
220
222
  confirmButtonText: "创建",
221
223
  cancelButtonText: "取消",
222
224
  inputPlaceholder: "文件夹名"
@@ -227,12 +229,13 @@ const _sfc_main = {
227
229
  entityId: WIKI_META,
228
230
  wikiId: this.wikiId,
229
231
  name: value.trim(),
230
- dir: this.currentDir
232
+ dir
231
233
  }).then((d) => {
232
234
  this.$message.success(d && d.message || "已新建");
233
235
  this.load();
234
236
  });
235
- }).catch(() => {
237
+ }).catch((e) => {
238
+ if (e !== "cancel" && e !== "close") this.$message.error(e && e.message || "新建文件夹失败");
236
239
  });
237
240
  },
238
241
  /**
@@ -241,12 +244,30 @@ const _sfc_main = {
241
244
  * 删除是一次真实的发布:已发布的页会从源里删掉文件并 push。所以确认框里
242
245
  * 把后果写清楚,而不是只问一句「确定删除吗」。
243
246
  */
244
- onRemove(node) {
247
+ async onRemove(node) {
245
248
  const isFolder = node.type === "folder";
246
- const tip = isFolder ? "文件夹只是路径的一段,删它不会往源里写东西;里面还有内容时删不掉。" : "已发布的页会从源里删除文件并推送,这是一次真实的 commit;指向它的链接会变成死链。";
247
- this.$confirm(tip, "删除「" + (node.title || node.path) + "」", {
249
+ if (isFolder && this.nodes.some((n) => n.up === node.path)) {
250
+ this.$message.warning("文件夹下还有内容,请先处理子节点");
251
+ return;
252
+ }
253
+ let links = [];
254
+ if (!isFolder) {
255
+ try {
256
+ const d = await this.$http.get({ action: "page", entityId: WIKI_META, wikiId: this.wikiId, pageId: node.id });
257
+ links = d && d.backlinks || [];
258
+ } catch (e) {
259
+ this.$message.error(e && e.message || "读取关联链接失败,无法确认删除影响");
260
+ return;
261
+ }
262
+ }
263
+ const affected = [...new Set(links.map((link) => link.path).filter(Boolean))];
264
+ const message = isFolder ? "将删除空文件夹;文件夹在源里不是文件。" : affected.length ? "将删除此页;若已发布,源文件也会删除并推送。以下 " + affected.length + " 个页面指向它,删除后这些链接会失效:\n" + affected.join("\n") : "将删除此页;若已发布,源文件也会删除并推送。当前没有指向它的页面链接。";
265
+ const body = h("div", {
266
+ style: { whiteSpace: "pre-line", maxHeight: "40vh", overflowY: "auto" }
267
+ }, message);
268
+ this.$confirm(body, "删除「" + (node.title || node.path) + "」", {
248
269
  type: "warning",
249
- confirmButtonText: "删除",
270
+ confirmButtonText: affected.length ? "仍要删除" : "删除",
250
271
  cancelButtonText: "取消",
251
272
  confirmButtonClass: "el-button--danger"
252
273
  }).then(() => {
@@ -257,7 +278,7 @@ const _sfc_main = {
257
278
  this.doc = {};
258
279
  this.backlinks = [];
259
280
  }
260
- this.load();
281
+ this.refreshContent();
261
282
  }).catch((e) => this.$message.error(e && e.message || "删除失败"));
262
283
  }).catch(() => {
263
284
  });
@@ -339,16 +360,6 @@ const _sfc_main = {
339
360
  this.syncing = false;
340
361
  });
341
362
  },
342
- /** 重建索引只重算投影,不碰源——所以它和同步是两个按钮,不是一个。 */
343
- doReindex() {
344
- this.reindexing = true;
345
- this.$http.update({ action: "reindex", entityId: WIKI_META, wikiId: this.wikiId }).then((d) => {
346
- this.$message.success(d && d.message || "索引已重建");
347
- this.loadDetail();
348
- }).catch((e) => this.$message.error(e && e.message || "重建索引失败")).finally(() => {
349
- this.reindexing = false;
350
- });
351
- },
352
363
  /** 从「引用与反馈」点开一页:切回内容页签,免得人以为点了没反应。 */
353
364
  openFromTab(path) {
354
365
  this.tab = "content";
@@ -356,7 +367,10 @@ const _sfc_main = {
356
367
  },
357
368
  doInspect() {
358
369
  this.inspecting = true;
359
- this.$http.update({ action: "inspect", entityId: WIKI_META, wikiId: this.wikiId }).then((d) => this.$message.success(d && d.message || "体检完成")).catch((e) => this.$message.error(e && e.message || "体检失败")).finally(() => {
370
+ this.$http.update({ action: "inspect", entityId: WIKI_META, wikiId: this.wikiId, maintain: "true" }).then((d) => {
371
+ this.$message.success(d && d.message || "体检与索引维护完成");
372
+ if (d && d.indexRebuilt) this.loadDetail();
373
+ }).catch((e) => this.$message.error(e && e.message || "体检与索引维护失败")).finally(() => {
360
374
  this.inspecting = false;
361
375
  });
362
376
  },
@@ -380,21 +394,22 @@ const _hoisted_3 = { class: "wiki-workbench__space" };
380
394
  const _hoisted_4 = { class: "wiki-workbench__body" };
381
395
  const _hoisted_5 = { class: "wiki-workbench__tree" };
382
396
  const _hoisted_6 = { class: "wiki-workbench__tree-top" };
383
- const _hoisted_7 = {
397
+ const _hoisted_7 = { class: "wiki-workbench__tree-ops" };
398
+ const _hoisted_8 = {
384
399
  key: 0,
385
400
  class: "wiki-workbench__tree-ops"
386
401
  };
387
- const _hoisted_8 = {
402
+ const _hoisted_9 = {
388
403
  key: 0,
389
404
  class: "wiki-workbench__tree-tip"
390
405
  };
391
- const _hoisted_9 = { class: "wiki-workbench__doc" };
392
- const _hoisted_10 = { class: "wiki-workbench__doc-top" };
393
- const _hoisted_11 = { class: "wiki-workbench__doc-nm" };
394
- const _hoisted_12 = { class: "nm" };
395
- const _hoisted_13 = { class: "pt" };
396
- const _hoisted_14 = { class: "wiki-workbench__doc-ops" };
397
- const _hoisted_15 = { class: "wiki-workbench__foot" };
406
+ const _hoisted_10 = { class: "wiki-workbench__doc" };
407
+ const _hoisted_11 = { class: "wiki-workbench__doc-top" };
408
+ const _hoisted_12 = { class: "wiki-workbench__doc-nm" };
409
+ const _hoisted_13 = { class: "nm" };
410
+ const _hoisted_14 = { class: "pt" };
411
+ const _hoisted_15 = { class: "wiki-workbench__doc-ops" };
412
+ const _hoisted_16 = { class: "wiki-workbench__foot" };
398
413
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
399
414
  const _component_el_tag = resolveComponent("el-tag");
400
415
  const _component_el_input = resolveComponent("el-input");
@@ -416,7 +431,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
416
431
  return openBlock(), createElementBlock("button", {
417
432
  key: t.key,
418
433
  class: normalizeClass({ "is-on": $data.tab === t.key }),
419
- onClick: ($event) => $data.tab = t.key
434
+ onClick: ($event) => $options.switchTab(t.key)
420
435
  }, toDisplayString(t.name), 11, _hoisted_2);
421
436
  }), 128)),
422
437
  createElementVNode("span", _hoisted_3, [
@@ -426,7 +441,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
426
441
  size: "small",
427
442
  type: "warning"
428
443
  }, {
429
- default: withCtx(() => [..._cache[9] || (_cache[9] = [
444
+ default: withCtx(() => [..._cache[12] || (_cache[12] = [
430
445
  createTextVNode("索引待重建", -1)
431
446
  ])]),
432
447
  _: 1
@@ -436,7 +451,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
436
451
  size: "small",
437
452
  type: "danger"
438
453
  }, {
439
- default: withCtx(() => [..._cache[10] || (_cache[10] = [
454
+ default: withCtx(() => [..._cache[13] || (_cache[13] = [
440
455
  createTextVNode("已停用", -1)
441
456
  ])]),
442
457
  _: 1
@@ -454,95 +469,107 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
454
469
  placeholder: "过滤页标题或路径",
455
470
  "prefix-icon": "el-icon-search"
456
471
  }, null, 8, ["modelValue"]),
457
- $data.editing ? (openBlock(), createElementBlock("div", _hoisted_7, [
472
+ createElementVNode("div", _hoisted_7, [
473
+ createVNode(_component_el_button, {
474
+ type: $data.managing ? "primary" : "default",
475
+ size: "small",
476
+ onClick: _cache[1] || (_cache[1] = ($event) => $data.managing = !$data.managing)
477
+ }, {
478
+ default: withCtx(() => [
479
+ createTextVNode(toDisplayString($data.managing ? "完成目录管理" : "目录管理"), 1)
480
+ ]),
481
+ _: 1
482
+ }, 8, ["type"])
483
+ ]),
484
+ $data.managing ? (openBlock(), createElementBlock("div", _hoisted_8, [
458
485
  createVNode(_component_el_button, {
459
- type: "primary",
460
486
  size: "small",
461
- onClick: $options.newPage
487
+ onClick: _cache[2] || (_cache[2] = ($event) => $options.newPage(""))
462
488
  }, {
463
- default: withCtx(() => [..._cache[11] || (_cache[11] = [
464
- createTextVNode("+ 新建页", -1)
489
+ default: withCtx(() => [..._cache[14] || (_cache[14] = [
490
+ createTextVNode("+ 根目录页", -1)
465
491
  ])]),
466
492
  _: 1
467
- }, 8, ["onClick"]),
493
+ }),
468
494
  createVNode(_component_el_button, {
469
495
  size: "small",
470
- onClick: $options.newFolder
496
+ onClick: _cache[3] || (_cache[3] = ($event) => $options.newFolder(""))
471
497
  }, {
472
- default: withCtx(() => [..._cache[12] || (_cache[12] = [
473
- createTextVNode("+ 文件夹", -1)
498
+ default: withCtx(() => [..._cache[15] || (_cache[15] = [
499
+ createTextVNode("+ 根文件夹", -1)
474
500
  ])]),
475
501
  _: 1
476
- }, 8, ["onClick"])
502
+ })
477
503
  ])) : createCommentVNode("", true)
478
504
  ]),
479
- $data.editing ? (openBlock(), createElementBlock("div", _hoisted_8, [..._cache[13] || (_cache[13] = [
480
- createTextVNode(" 同级拖动 = 只改顺序,", -1),
481
- createElementVNode("b", null, "不产生 commit", -1),
482
- createTextVNode(";改路径要走发布流程,暂未开放。 ", -1)
483
- ])])) : createCommentVNode("", true),
505
+ $data.managing ? (openBlock(), createElementBlock("div", _hoisted_9, " 节点右侧“操作”可新增下级或删除;同级拖动调整顺序。 ")) : createCommentVNode("", true),
484
506
  createVNode(_component_wiki_tree, {
485
507
  nodes: $data.nodes,
486
508
  current: $data.path,
487
509
  keyword: $data.filter,
488
- sortable: $data.editing,
489
- deletable: $data.editing,
510
+ sortable: $data.managing,
511
+ manageable: $data.managing,
490
512
  "empty-text": "这个空间还没有页。先同步远端把已有文档拉进来",
491
513
  onOpen: $options.openPage,
492
514
  onReorder: $options.onReorder,
493
- onRemove: $options.onRemove
494
- }, null, 8, ["nodes", "current", "keyword", "sortable", "deletable", "onOpen", "onReorder", "onRemove"])
515
+ onRemove: $options.onRemove,
516
+ onCreatePage: $options.newPage,
517
+ onCreateFolder: $options.newFolder
518
+ }, null, 8, ["nodes", "current", "keyword", "sortable", "manageable", "onOpen", "onReorder", "onRemove", "onCreatePage", "onCreateFolder"])
495
519
  ]),
496
- createElementVNode("div", _hoisted_9, [
497
- createElementVNode("div", _hoisted_10, [
498
- createElementVNode("div", _hoisted_11, [
499
- createElementVNode("span", _hoisted_12, toDisplayString($data.doc.title || $data.doc.path || "未选择"), 1),
500
- createElementVNode("span", _hoisted_13, [
520
+ createElementVNode("div", _hoisted_10, [
521
+ createElementVNode("div", _hoisted_11, [
522
+ createElementVNode("div", _hoisted_12, [
523
+ createElementVNode("span", _hoisted_13, toDisplayString($data.doc.title || $data.doc.path || "未选择"), 1),
524
+ createElementVNode("span", _hoisted_14, [
501
525
  createTextVNode(toDisplayString($data.doc.path) + " ", 1),
502
526
  $data.doc.cite ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
503
527
  createTextVNode(" · 被引用 " + toDisplayString($data.doc.cite) + " 次", 1)
504
528
  ], 64)) : createCommentVNode("", true)
505
529
  ])
506
530
  ]),
507
- createElementVNode("div", _hoisted_14, [
508
- $data.editing ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
509
- createVNode(_component_el_button, {
510
- size: "small",
511
- onClick: _cache[1] || (_cache[1] = ($event) => $options.callDoc("cancelEdit"))
512
- }, {
513
- default: withCtx(() => [..._cache[14] || (_cache[14] = [
514
- createTextVNode("退出编辑", -1)
515
- ])]),
516
- _: 1
517
- }),
518
- createVNode(_component_el_button, {
519
- size: "small",
520
- onClick: _cache[2] || (_cache[2] = ($event) => $options.callDoc("saveDraft"))
521
- }, {
522
- default: withCtx(() => [..._cache[15] || (_cache[15] = [
523
- createTextVNode("保存草稿", -1)
524
- ])]),
525
- _: 1
526
- })
527
- ], 64)) : (openBlock(), createBlock(_component_el_button, {
531
+ createElementVNode("div", _hoisted_15, [
532
+ $data.editing ? (openBlock(), createBlock(_component_el_button, {
533
+ key: 0,
534
+ size: "small",
535
+ onClick: _cache[4] || (_cache[4] = ($event) => $options.callDoc("saveDraft"))
536
+ }, {
537
+ default: withCtx(() => [..._cache[16] || (_cache[16] = [
538
+ createTextVNode("保存草稿", -1)
539
+ ])]),
540
+ _: 1
541
+ })) : (openBlock(), createBlock(_component_el_button, {
528
542
  key: 1,
529
543
  type: "primary",
530
544
  size: "small",
531
545
  disabled: !$data.doc.path,
532
- onClick: _cache[3] || (_cache[3] = ($event) => $options.callDoc("startEdit"))
546
+ onClick: _cache[5] || (_cache[5] = ($event) => $options.callDoc("startEdit"))
533
547
  }, {
534
- default: withCtx(() => [..._cache[16] || (_cache[16] = [
535
- createTextVNode(" ✎ 编辑 ", -1)
548
+ default: withCtx(() => [..._cache[17] || (_cache[17] = [
549
+ createTextVNode(" ✎ 人工编辑 ", -1)
536
550
  ])]),
537
551
  _: 1
538
552
  }, 8, ["disabled"])),
539
553
  createVNode(_component_el_button, {
540
- type: "primary",
554
+ type: "warning",
541
555
  size: "small",
556
+ icon: "el-icon-magic-stick",
557
+ disabled: !$data.doc.path,
558
+ onClick: _cache[6] || (_cache[6] = ($event) => $options.callDoc("aiEdit"))
559
+ }, {
560
+ default: withCtx(() => [..._cache[18] || (_cache[18] = [
561
+ createTextVNode("AI 编辑", -1)
562
+ ])]),
563
+ _: 1
564
+ }, 8, ["disabled"]),
565
+ createVNode(_component_el_button, {
566
+ type: "success",
567
+ size: "small",
568
+ icon: "el-icon-upload2",
542
569
  disabled: !$data.doc.path || !$data.editing && $data.doc.state !== "draft",
543
- onClick: _cache[4] || (_cache[4] = ($event) => $options.callDoc($data.editing ? "publish" : "publishSavedDraft"))
570
+ onClick: _cache[7] || (_cache[7] = ($event) => $options.callDoc($data.editing ? "publish" : "publishSavedDraft"))
544
571
  }, {
545
- default: withCtx(() => [..._cache[17] || (_cache[17] = [
572
+ default: withCtx(() => [..._cache[19] || (_cache[19] = [
546
573
  createTextVNode("发布", -1)
547
574
  ])]),
548
575
  _: 1
@@ -550,38 +577,33 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
550
577
  _cache[22] || (_cache[22] = createElementVNode("span", { class: "wiki-workbench__vsep" }, null, -1)),
551
578
  $data.detail.SOURCE_TYPE && $data.detail.SOURCE_TYPE !== "db" ? (openBlock(), createBlock(_component_el_button, {
552
579
  key: 2,
580
+ type: "success",
581
+ plain: "",
553
582
  size: "small",
583
+ icon: "el-icon-refresh",
554
584
  loading: $data.syncing,
555
585
  onClick: $options.doSync
556
586
  }, {
557
- default: withCtx(() => [..._cache[18] || (_cache[18] = [
587
+ default: withCtx(() => [..._cache[20] || (_cache[20] = [
558
588
  createTextVNode("同步远端", -1)
559
589
  ])]),
560
590
  _: 1
561
591
  }, 8, ["loading", "onClick"])) : createCommentVNode("", true),
562
592
  createVNode(_component_el_button, {
593
+ type: "primary",
563
594
  size: "small",
595
+ icon: "el-icon-s-tools",
564
596
  loading: $data.inspecting,
565
597
  onClick: $options.doInspect
566
598
  }, {
567
- default: withCtx(() => [..._cache[19] || (_cache[19] = [
568
- createTextVNode("体检", -1)
569
- ])]),
570
- _: 1
571
- }, 8, ["loading", "onClick"]),
572
- createVNode(_component_el_button, {
573
- size: "small",
574
- loading: $data.reindexing,
575
- onClick: $options.doReindex
576
- }, {
577
- default: withCtx(() => [..._cache[20] || (_cache[20] = [
578
- createTextVNode("重建索引", -1)
579
- ])]),
599
+ default: withCtx(() => [
600
+ createTextVNode(toDisplayString($data.inspecting ? "检查中…" : "体检与索引维护"), 1)
601
+ ]),
580
602
  _: 1
581
603
  }, 8, ["loading", "onClick"]),
582
604
  createVNode(_component_el_button, {
583
605
  size: "small",
584
- onClick: _cache[5] || (_cache[5] = ($event) => $data.tab = "intake")
606
+ onClick: _cache[8] || (_cache[8] = ($event) => $data.tab = "intake")
585
607
  }, {
586
608
  default: withCtx(() => [..._cache[21] || (_cache[21] = [
587
609
  createTextVNode("⬆ 上传原始文件", -1)
@@ -597,11 +619,12 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
597
619
  "show-bar": false,
598
620
  onOpen: $options.openRelative,
599
621
  onOpenPath: $options.openPage,
600
- onEditing: _cache[6] || (_cache[6] = ($event) => $data.editing = $event),
601
- onDirty: _cache[7] || (_cache[7] = ($event) => $data.dirty = $event),
602
- onPublished: $options.onPublished
603
- }, null, 8, ["page", "backlinks", "onOpen", "onOpenPath", "onPublished"]),
604
- createElementVNode("div", _hoisted_15, [
622
+ onEditing: _cache[9] || (_cache[9] = ($event) => $data.editing = $event),
623
+ onDirty: _cache[10] || (_cache[10] = ($event) => $data.dirty = $event),
624
+ onPublished: $options.onPublished,
625
+ onAiEdited: $options.load
626
+ }, null, 8, ["page", "backlinks", "onOpen", "onOpenPath", "onPublished", "onAiEdited"]),
627
+ createElementVNode("div", _hoisted_16, [
605
628
  createElementVNode("span", null, toDisplayString($options.publishHint), 1),
606
629
  _cache[23] || (_cache[23] = createElementVNode("span", { class: "wiki-workbench__foot-r" }, "发布后自动重建检索索引", -1))
607
630
  ])
@@ -614,25 +637,26 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
614
637
  "wiki-id": $options.wikiId,
615
638
  path: $data.path,
616
639
  title: $data.doc.title,
617
- onBack: _cache[8] || (_cache[8] = ($event) => $data.tab = "content")
640
+ onBack: _cache[11] || (_cache[11] = ($event) => $options.switchTab("content"))
618
641
  }, null, 8, ["wiki-id", "path", "title"])) : createCommentVNode("", true),
619
- $data.tab === "intake" ? (openBlock(), createBlock(_component_wiki_intake, {
620
- key: 1,
642
+ withDirectives(createVNode(_component_wiki_intake, {
621
643
  "wiki-id": $options.wikiId,
622
644
  onOpen: $options.openFromTab,
623
645
  onChanged: $options.refreshContent
624
- }, null, 8, ["wiki-id", "onOpen", "onChanged"])) : createCommentVNode("", true),
646
+ }, null, 8, ["wiki-id", "onOpen", "onChanged"]), [
647
+ [vShow, $data.tab === "intake"]
648
+ ]),
625
649
  $data.tab === "cites" ? (openBlock(), createBlock(_component_wiki_cites, {
626
- key: 2,
650
+ key: 1,
627
651
  "wiki-id": $options.wikiId,
628
652
  onOpen: $options.openFromTab
629
653
  }, null, 8, ["wiki-id", "onOpen"])) : createCommentVNode("", true),
630
654
  $data.tab === "jobs" ? (openBlock(), createBlock(_component_wiki_jobs, {
631
- key: 3,
655
+ key: 2,
632
656
  "wiki-id": $options.wikiId
633
657
  }, null, 8, ["wiki-id"])) : createCommentVNode("", true),
634
658
  $data.tab === "settings" ? (openBlock(), createBlock(_component_wiki_space_settings, {
635
- key: 4,
659
+ key: 3,
636
660
  detail: $data.detail,
637
661
  mounts: $data.mounts,
638
662
  onEdit: $options.goSettings
@@ -10,6 +10,8 @@ const _sfc_main = {
10
10
  name: "epx-authorization-interface",
11
11
  mixins: [component],
12
12
  props: {
13
+ // 接收父表单实例,避免被当作 DOM 属性透传。
14
+ form: Object,
13
15
  formData: {
14
16
  type: Object,
15
17
  default() {
@@ -616,7 +618,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
616
618
  }, 8, ["modelValue"])
617
619
  ]);
618
620
  }
619
- const AuthorizationInterface = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-00ee58f2"]]);
621
+ const AuthorizationInterface = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-ffe80e96"]]);
620
622
  export {
621
623
  AuthorizationInterface as default
622
624
  };