agilebuilder-ui 1.1.65-tmp16 → 1.1.65-tmp17

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 (441) hide show
  1. package/lib/IntervalSelection/index.js +5 -7
  2. package/lib/IntervalSelection/src/sectionDate.vue.js +17 -21
  3. package/lib/IntervalSelection/src/sectionDate.vue2.js +2 -4
  4. package/lib/_virtual/__vite-browser-external.js +2 -4
  5. package/lib/_virtual/_plugin-vue_export-helper.js +6 -8
  6. package/lib/breadcrumb/index.js +3 -5
  7. package/lib/breadcrumb/src/breadcrumb.vue.js +28 -19
  8. package/lib/breadcrumb/src/breadcrumb.vue2.js +2 -4
  9. package/lib/chat-embed/index.js +3 -5
  10. package/lib/chat-embed/src/chat-addition-data.vue.js +5 -7
  11. package/lib/chat-embed/src/chat-addition-data.vue2.js +11 -13
  12. package/lib/chat-embed/src/chat-addition-data.vue3.js +2 -4
  13. package/lib/chat-embed/src/chat-ai-answer-tip.vue.js +5 -7
  14. package/lib/chat-embed/src/chat-ai-answer-tip.vue2.js +17 -20
  15. package/lib/chat-embed/src/chat-ai-answer-tip.vue3.js +2 -4
  16. package/lib/chat-embed/src/chat-bubble-footer.vue.js +5 -7
  17. package/lib/chat-embed/src/chat-bubble-footer.vue2.js +17 -22
  18. package/lib/chat-embed/src/chat-bubble-footer.vue3.js +2 -4
  19. package/lib/chat-embed/src/chat-embed-message.js +14 -20
  20. package/lib/chat-embed/src/chat-sender.vue.js +5 -7
  21. package/lib/chat-embed/src/chat-sender.vue2.js +110 -123
  22. package/lib/chat-embed/src/chat-sender.vue3.js +2 -4
  23. package/lib/chat-embed/src/components/answer-auto-chart.vue.js +5 -7
  24. package/lib/chat-embed/src/components/answer-auto-chart.vue2.js +42 -50
  25. package/lib/chat-embed/src/components/answer-auto-chart.vue3.js +2 -4
  26. package/lib/chat-embed/src/components/answer-home-chart.vue.js +5 -7
  27. package/lib/chat-embed/src/components/answer-home-chart.vue2.js +3 -6
  28. package/lib/chat-embed/src/components/answer-home-chart.vue3.js +2 -4
  29. package/lib/chat-embed/src/components/answer-interaction-data.vue.js +5 -7
  30. package/lib/chat-embed/src/components/answer-interaction-data.vue2.js +74 -84
  31. package/lib/chat-embed/src/components/answer-interaction-data.vue3.js +2 -4
  32. package/lib/chat-embed/src/components/history-detail.vue.js +5 -7
  33. package/lib/chat-embed/src/components/history-detail.vue2.js +27 -32
  34. package/lib/chat-embed/src/components/history-detail.vue3.js +2 -4
  35. package/lib/chat-embed/src/header.vue.js +5 -7
  36. package/lib/chat-embed/src/header.vue2.js +25 -32
  37. package/lib/chat-embed/src/header.vue3.js +2 -4
  38. package/lib/chat-embed/src/index.vue.js +5 -7
  39. package/lib/chat-embed/src/index.vue2.js +185 -211
  40. package/lib/chat-embed/src/index.vue3.js +2 -4
  41. package/lib/chat-embed/src/recommendation-message.vue.js +5 -7
  42. package/lib/chat-embed/src/recommendation-message.vue2.js +5 -8
  43. package/lib/chat-embed/src/recommendation-message.vue3.js +2 -4
  44. package/lib/chat-embed/src/sidebar-item.vue.js +5 -7
  45. package/lib/chat-embed/src/sidebar-item.vue2.js +84 -93
  46. package/lib/chat-embed/src/sidebar-item.vue3.js +2 -4
  47. package/lib/chat-embed/src/type.js +3 -5
  48. package/lib/chat-embed/src/util/chat-embed-util.js +35 -41
  49. package/lib/chat-embed/src/util/history-message-util.js +63 -85
  50. package/lib/chat-embed/src/util/mcp-utils.js +5 -8
  51. package/lib/chat-embed/src/util/text-file-util.js +7 -11
  52. package/lib/chat-embed/src/voice/index.js +5 -7
  53. package/lib/chat-embed/src/voice/js/crypto-js.js +987 -995
  54. package/lib/chat-embed/src/voice/js/processor/index.umd.js +161 -169
  55. package/lib/chat-embed/src/voice/js/timer.js +7 -10
  56. package/lib/chat-embed/src/voice/voice.vue.js +61 -70
  57. package/lib/date-picker-range/index.js +5 -7
  58. package/lib/date-picker-range/index.vue.js +5 -7
  59. package/lib/date-picker-range/index.vue2.js +59 -63
  60. package/lib/date-picker-range/index.vue3.js +2 -4
  61. package/lib/department-tree/index.js +3 -5
  62. package/lib/department-tree/src/department-tree.vue.js +11 -17
  63. package/lib/department-tree-inline/index.js +3 -5
  64. package/lib/department-tree-inline/src/department-multi-tree-inline.vue.js +17 -27
  65. package/lib/department-tree-inline/src/department-multi-tree-inline.vue2.js +2 -4
  66. package/lib/department-tree-inline/src/department-single-tree-inline.vue.js +17 -27
  67. package/lib/department-tree-inline/src/department-single-tree-inline.vue2.js +2 -4
  68. package/lib/department-tree-inline/src/department-tree-inline.vue.js +8 -13
  69. package/lib/department-tree-inline/src/department-tree-service.js +8 -10
  70. package/lib/department-tree-inline/src/search-result.vue.js +19 -23
  71. package/lib/department-tree-inline/src/search-result.vue2.js +2 -4
  72. package/lib/department-tree-mobile/index.js +4 -7
  73. package/lib/department-tree-mobile/src/department-tree-app.vue.js +9 -12
  74. package/lib/department-tree-mobile/src/department-tree-app.vue2.js +2 -4
  75. package/lib/department-tree-mobile/src/department-tree-app.vue3.js +3 -5
  76. package/lib/department-tree-mobile/src/department-tree-inline-app.vue.js +80 -91
  77. package/lib/department-tree-mobile/src/department-tree-inline-app.vue2.js +3 -4
  78. package/lib/department-tree-mobile/src/department-tree-service.js +32 -42
  79. package/lib/department-tree-mobile/src/dept-path.vue.js +10 -11
  80. package/lib/department-tree-mobile/src/dept-path.vue2.js +3 -4
  81. package/lib/department-tree-mobile/src/dept-result.vue.js +11 -14
  82. package/lib/department-tree-mobile/src/dept-result.vue2.js +3 -4
  83. package/lib/department-user-tree/index.js +3 -5
  84. package/lib/department-user-tree/src/department-user-multiple-tree.vue.js +10 -14
  85. package/lib/department-user-tree/src/department-user-multiple-tree.vue2.js +2 -4
  86. package/lib/department-user-tree/src/department-user-single-tree.vue.js +9 -14
  87. package/lib/department-user-tree/src/department-user-tree.vue.js +14 -20
  88. package/lib/department-user-tree-inline/index.js +3 -5
  89. package/lib/department-user-tree-inline/src/department-user-multiple-tree-inline.vue.js +17 -28
  90. package/lib/department-user-tree-inline/src/department-user-multiple-tree-inline.vue2.js +2 -4
  91. package/lib/department-user-tree-inline/src/department-user-single-tree-inline.vue.js +21 -33
  92. package/lib/department-user-tree-inline/src/department-user-single-tree-inline.vue2.js +2 -4
  93. package/lib/department-user-tree-inline/src/department-user-tree-inline.vue.js +8 -13
  94. package/lib/department-user-tree-inline/src/department-user-tree-multi-service.js +6 -9
  95. package/lib/department-user-tree-inline/src/department-user-tree-single-service.js +8 -11
  96. package/lib/department-user-tree-inline/src/group-user/group-input.vue.js +7 -12
  97. package/lib/department-user-tree-inline/src/group-user/group-list.vue.js +7 -12
  98. package/lib/department-user-tree-inline/src/group-user/group-user.vue.js +8 -14
  99. package/lib/department-user-tree-inline/src/group-user-multiple-tree.vue.js +14 -20
  100. package/lib/department-user-tree-inline/src/group-user-single-tree.vue.js +17 -23
  101. package/lib/department-user-tree-inline/src/group-user-tree-service.js +2 -3
  102. package/lib/department-user-tree-inline/src/search-result.vue.js +12 -15
  103. package/lib/department-user-tree-inline/src/search-result.vue2.js +2 -4
  104. package/lib/department-user-tree-mobile/index.js +4 -7
  105. package/lib/department-user-tree-mobile/src/department-user-tree-app.vue.js +9 -12
  106. package/lib/department-user-tree-mobile/src/department-user-tree-app.vue2.js +2 -4
  107. package/lib/department-user-tree-mobile/src/department-user-tree-app.vue3.js +3 -5
  108. package/lib/department-user-tree-mobile/src/department-user-tree-inline-app.vue.js +93 -104
  109. package/lib/department-user-tree-mobile/src/department-user-tree-inline-app.vue2.js +3 -4
  110. package/lib/department-user-tree-mobile/src/department-user-tree-service.js +20 -30
  111. package/lib/department-user-tree-mobile/src/dept-path.vue.js +10 -11
  112. package/lib/department-user-tree-mobile/src/dept-path.vue2.js +3 -4
  113. package/lib/department-user-tree-mobile/src/dept-result.vue.js +11 -15
  114. package/lib/department-user-tree-mobile/src/dept-result.vue2.js +3 -4
  115. package/lib/directives/prevent-reclick.js +2 -3
  116. package/lib/dynamic-source-select/index.js +5 -7
  117. package/lib/dynamic-source-select/src/dynamic-source-select-service.js +13 -15
  118. package/lib/dynamic-source-select/src/dynamic-source-select.vue.js +173 -183
  119. package/lib/dynamic-source-select/src/dynamic-source-select.vue2.js +2 -4
  120. package/lib/dynamic-source-select/src/dynamic-source-select.vue3.js +2 -4
  121. package/lib/dynamic-source-select/src/events.js +2 -3
  122. package/lib/empty-state/index.vue.js +5 -8
  123. package/lib/empty-state/index.vue2.js +3 -4
  124. package/lib/fs-preview/index.js +5 -7
  125. package/lib/fs-preview/src/fs-preview.vue.js +63 -72
  126. package/lib/fs-preview/src/fs-preview.vue2.js +2 -4
  127. package/lib/fs-upload/index.js +5 -7
  128. package/lib/fs-upload/src/fs-upload-multi.vue.js +24 -32
  129. package/lib/fs-upload/src/fs-upload-single.vue.js +30 -39
  130. package/lib/fs-upload/src/fs-upload.vue.js +10 -16
  131. package/lib/fs-upload/src/see-big-picture.vue.js +8 -11
  132. package/lib/fs-upload-list/index.js +5 -7
  133. package/lib/fs-upload-list/src/fs-upload-list.vue.js +33 -40
  134. package/lib/fs-upload-list/src/fs-upload-list.vue2.js +2 -4
  135. package/lib/fs-upload-new/index.js +5 -7
  136. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-app.vue.js +34 -38
  137. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-app.vue2.js +3 -4
  138. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-browser.vue.js +101 -109
  139. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-browser.vue2.js +3 -4
  140. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-component.vue.js +5 -7
  141. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-component.vue2.js +26 -33
  142. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-component.vue3.js +2 -4
  143. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-input.vue.js +27 -31
  144. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-input.vue2.js +3 -4
  145. package/lib/fs-upload-new/src/file-upload-mobile/file-upload.vue.js +18 -24
  146. package/lib/fs-upload-new/src/file-upload-mobile/file-upload.vue2.js +3 -4
  147. package/lib/fs-upload-new/src/fs-button-upload.vue.js +5 -7
  148. package/lib/fs-upload-new/src/fs-button-upload.vue2.js +36 -43
  149. package/lib/fs-upload-new/src/fs-button-upload.vue3.js +2 -4
  150. package/lib/fs-upload-new/src/fs-drag-upload.vue.js +5 -7
  151. package/lib/fs-upload-new/src/fs-drag-upload.vue2.js +37 -45
  152. package/lib/fs-upload-new/src/fs-drag-upload.vue3.js +2 -4
  153. package/lib/fs-upload-new/src/fs-preview-new.vue.js +5 -8
  154. package/lib/fs-upload-new/src/fs-preview-new.vue2.js +61 -70
  155. package/lib/fs-upload-new/src/fs-preview-new.vue3.js +2 -4
  156. package/lib/fs-upload-new/src/fs-preview-new.vue4.js +2 -4
  157. package/lib/fs-upload-new/src/fs-upload-new.vue.js +37 -47
  158. package/lib/fs-upload-new/src/fs-upload-new.vue2.js +3 -4
  159. package/lib/hamburger/index.js +3 -5
  160. package/lib/hamburger/src/hamburger.vue.js +10 -14
  161. package/lib/hamburger/src/hamburger.vue2.js +2 -4
  162. package/lib/index.js +40 -383
  163. package/lib/json-view/json-view-dialog.vue.js +12 -15
  164. package/lib/json-view/json-view-dialog.vue2.js +3 -4
  165. package/lib/json-view/json-view.vue.js +3 -4
  166. package/lib/json-view/json-view.vue2.js +27 -31
  167. package/lib/multipart-upload/index.js +5 -7
  168. package/lib/multipart-upload/src/index.vue.js +7 -11
  169. package/lib/multipart-upload/src/multipart-upload-form.vue.js +40 -49
  170. package/lib/multipart-upload/src/multipart-upload-list.vue.js +59 -67
  171. package/lib/organization-input/index.js +5 -7
  172. package/lib/organization-input/src/organization-input.vue.js +31 -37
  173. package/lib/organization-input/src/organization-input.vue2.js +2 -4
  174. package/lib/plugins/export-data-new.js +96 -104
  175. package/lib/plugins/export-data.js +45 -51
  176. package/lib/plugins/index.js +4 -8
  177. package/lib/plugins/public-method.js +2 -3
  178. package/lib/remove-department/index.js +3 -5
  179. package/lib/remove-department/src/remove-department.vue.js +13 -19
  180. package/lib/remove-department/src/remove-dept-service.js +9 -10
  181. package/lib/remove-user/index.js +5 -7
  182. package/lib/remove-user/src/remove-user-service.js +3 -4
  183. package/lib/remove-user/src/remove-user.vue.js +16 -22
  184. package/lib/remove-workgroup/index.js +5 -7
  185. package/lib/remove-workgroup/src/remove-workgroup-service.js +3 -4
  186. package/lib/remove-workgroup/src/remove-workgroup.vue.js +12 -18
  187. package/lib/rich-editor/index.js +5 -7
  188. package/lib/rich-editor/index.vue.js +28 -76
  189. package/lib/rich-editor/tinymce/zh_CN.js +2 -2
  190. package/lib/rich-editor/viewer.vue.js +7 -10
  191. package/lib/row-form/index.js +5 -7
  192. package/lib/row-form/index.vue.js +5 -7
  193. package/lib/row-form/index.vue2.js +41 -47
  194. package/lib/row-form/index.vue3.js +2 -4
  195. package/lib/row-form/operation.vue.js +22 -26
  196. package/lib/row-form/operation.vue2.js +3 -4
  197. package/lib/scan-code-input/index.js +5 -7
  198. package/lib/scan-code-input/src/events.js +11 -13
  199. package/lib/scan-code-input/src/scan-code-input.vue.js +9 -15
  200. package/lib/scan-code-input-browser/index.js +5 -7
  201. package/lib/scan-code-input-browser/src/scan-code-input.vue.js +16 -21
  202. package/lib/secret-info/index.js +5 -7
  203. package/lib/secret-info/index.vue.js +6 -9
  204. package/lib/src/api/sso-service.js +34 -36
  205. package/lib/src/api/tab.js +8 -9
  206. package/lib/src/assets/401/401.gif.js +2 -4
  207. package/lib/src/assets/404/404-cloud.png.js +2 -4
  208. package/lib/src/assets/404/404.png.js +2 -4
  209. package/lib/src/assets/chat-embed/robot.gif.js +2 -4
  210. package/lib/src/assets/chat-embed/robot.svg.js +2 -4
  211. package/lib/src/assets/nonemessage.png.js +2 -4
  212. package/lib/src/components/Affix/index.vue.js +5 -7
  213. package/lib/src/components/Affix/index.vue2.js +56 -58
  214. package/lib/src/components/Affix/index.vue3.js +2 -4
  215. package/lib/src/components/Card/index.js +33 -38
  216. package/lib/src/components/Scrollbar/index.vue.js +33 -37
  217. package/lib/src/components/Scrollbar/index.vue2.js +2 -4
  218. package/lib/src/directives/permission/index.js +3 -5
  219. package/lib/src/directives/permission/permission.js +7 -9
  220. package/lib/src/i18n/i18n.js +3 -7
  221. package/lib/src/i18n/langs/cn.js +2 -4
  222. package/lib/src/i18n/langs/en.js +2 -4
  223. package/lib/src/mixins/resizeMixin.js +2 -3
  224. package/lib/src/permission.js +43 -46
  225. package/lib/src/router/index.js +16 -10
  226. package/lib/src/store/getters.js +2 -4
  227. package/lib/src/store/index.js +16 -13
  228. package/lib/src/store/modules/app.js +3 -4
  229. package/lib/src/store/modules/chat-ai-store.js +19 -22
  230. package/lib/src/store/modules/permission.js +10 -11
  231. package/lib/src/store/modules/system.js +7 -9
  232. package/lib/src/store/modules/tab-content.js +13 -15
  233. package/lib/src/store/modules/table.js +2 -3
  234. package/lib/src/store/modules/user.js +89 -95
  235. package/lib/src/utils/auth-api.js +3 -5
  236. package/lib/src/utils/auth.js +69 -139
  237. package/lib/src/utils/calculator/calculator-factory-wf.js +48 -49
  238. package/lib/src/utils/calculator/calculator-factory.js +57 -58
  239. package/lib/src/utils/calculator/calculator-util.js +29 -32
  240. package/lib/src/utils/chat-ai-util.js +17 -25
  241. package/lib/src/utils/common-util.js +271 -356
  242. package/lib/src/utils/eventBus.js +3 -6
  243. package/lib/src/utils/file-util.js +15 -16
  244. package/lib/src/utils/global-prop.js +21 -37
  245. package/lib/src/utils/guid.js +5 -8
  246. package/lib/src/utils/i18n-util.js +16 -24
  247. package/lib/src/utils/iconUtils.js +16 -23
  248. package/lib/src/utils/index.js +26 -40
  249. package/lib/src/utils/insert_css.js +8 -7
  250. package/lib/src/utils/json-util.js +25 -27
  251. package/lib/src/utils/jump-page-utils.js +172 -180
  252. package/lib/src/utils/local-storage.js +2 -3
  253. package/lib/src/utils/menu.js +10 -11
  254. package/lib/src/utils/permission.js +22 -26
  255. package/lib/src/utils/permissionAuth.js +102 -136
  256. package/lib/src/utils/range-selector.js +41 -45
  257. package/lib/src/utils/request.js +77 -86
  258. package/lib/src/utils/resize.js +5 -5
  259. package/lib/src/utils/restful-interface-utils.js +12 -15
  260. package/lib/src/utils/util.js +6 -26
  261. package/lib/src/utils/validate.js +10 -20
  262. package/lib/src/utils/voice-setting-cache.js +140 -153
  263. package/lib/src/utils/watermark-cache.js +9 -14
  264. package/lib/src/utils/watermark.js +23 -30
  265. package/lib/src/utils/workflow-util.js +25 -26
  266. package/lib/src/views/dsc-component/Sidebar/Item.vue.js +5 -7
  267. package/lib/src/views/dsc-component/Sidebar/Item.vue2.js +8 -11
  268. package/lib/src/views/dsc-component/Sidebar/Item.vue3.js +2 -4
  269. package/lib/src/views/dsc-component/Sidebar/Link.vue.js +9 -12
  270. package/lib/src/views/dsc-component/Sidebar/SidebarItem.vue.js +19 -26
  271. package/lib/src/views/dsc-component/Sidebar/SidebarItem.vue2.js +2 -4
  272. package/lib/src/views/dsc-component/Sidebar/index.vue.js +12 -20
  273. package/lib/src/views/dsc-component/tabs/tab-content.vue.js +21 -26
  274. package/lib/src/views/dsc-component/tabs/tab-content.vue2.js +2 -4
  275. package/lib/src/views/dsc-component/tabs/tab-content.vue3.js +2 -4
  276. package/lib/src/views/error-page/401.vue.js +9 -13
  277. package/lib/src/views/error-page/401.vue2.js +2 -4
  278. package/lib/src/views/error-page/404.vue.js +7 -11
  279. package/lib/src/views/error-page/404.vue2.js +2 -4
  280. package/lib/src/views/layout/EmptyLayout.vue.js +6 -8
  281. package/lib/src/views/layout/Layout.vue.js +12 -19
  282. package/lib/src/views/layout/Layout.vue2.js +2 -4
  283. package/lib/src/views/layout/NewLayout.vue.js +6 -10
  284. package/lib/src/views/layout/components/AppMain.vue.js +9 -11
  285. package/lib/src/views/layout/components/AppMain.vue2.js +2 -4
  286. package/lib/src/views/layout/components/Breadcrumb/index.vue.js +44 -37
  287. package/lib/src/views/layout/components/Breadcrumb/index.vue2.js +2 -4
  288. package/lib/src/views/layout/components/Menubar/Item.vue.js +5 -7
  289. package/lib/src/views/layout/components/Menubar/Item.vue2.js +12 -14
  290. package/lib/src/views/layout/components/Menubar/Item.vue3.js +2 -4
  291. package/lib/src/views/layout/components/Menubar/Link.vue.js +9 -12
  292. package/lib/src/views/layout/components/Menubar/SidebarItem.vue.js +15 -24
  293. package/lib/src/views/layout/components/Menubar/SidebarItem.vue2.js +2 -4
  294. package/lib/src/views/layout/components/Menubar/index.vue.js +19 -30
  295. package/lib/src/views/layout/components/Sidebar/Item.vue.js +6 -8
  296. package/lib/src/views/layout/components/Sidebar/Item.vue2.js +3 -4
  297. package/lib/src/views/layout/components/Sidebar/Link.vue.js +8 -11
  298. package/lib/src/views/layout/components/Sidebar/SidebarItem.vue.js +11 -17
  299. package/lib/src/views/layout/components/Sidebar/SidebarItem.vue2.js +2 -4
  300. package/lib/src/views/layout/components/Sidebar/index.vue.js +18 -25
  301. package/lib/src/views/layout/components/iframe-page.vue.js +8 -10
  302. package/lib/src/views/layout/components/iframe-page.vue2.js +2 -4
  303. package/lib/src/views/layout/components/tabs/tab-content.vue.js +10 -14
  304. package/lib/src/views/layout/components/tabs/tab-content.vue2.js +2 -4
  305. package/lib/src/views/layout/components/tabs/tab-content.vue3.js +2 -4
  306. package/lib/src/views/layout/mixin/ResizeHandler.js +3 -5
  307. package/lib/src/views/layout/tab-content-iframe-index.vue.js +8 -10
  308. package/lib/src/views/layout/tab-content-iframe-index.vue2.js +2 -4
  309. package/lib/src/views/layout/tab-content-index.vue.js +12 -18
  310. package/lib/src/views/layout/tab-content-index.vue2.js +2 -4
  311. package/lib/src/views/login/authredirect.vue.js +2 -3
  312. package/lib/src/views/redirect/index.vue.js +17 -8
  313. package/lib/src/views/svg-icon/src/svg-icon.vue.js +2 -4
  314. package/lib/src/views/wf-history/tache-subprocess-history.vue.js +11 -13
  315. package/lib/src/views/wf-history/tache-subprocess-history.vue2.js +2 -4
  316. package/lib/style.css +685 -685
  317. package/lib/super-grid/index.js +5 -7
  318. package/lib/super-grid/src/apis.js +221 -231
  319. package/lib/super-grid/src/columns-config.vue.js +16 -22
  320. package/lib/super-grid/src/components/grid-icon.vue.js +26 -34
  321. package/lib/super-grid/src/components/grid-radio-input.vue.js +15 -18
  322. package/lib/super-grid/src/components/grid-radio-input.vue2.js +3 -4
  323. package/lib/super-grid/src/components/mobile-table-card.js +73 -83
  324. package/lib/super-grid/src/components/select-input.vue.js +98 -106
  325. package/lib/super-grid/src/components/select-input.vue2.js +3 -4
  326. package/lib/super-grid/src/custom-formatter.js +69 -74
  327. package/lib/super-grid/src/dynamic-input.vue.js +142 -159
  328. package/lib/super-grid/src/eventBus.js +3 -6
  329. package/lib/super-grid/src/events.js +34 -36
  330. package/lib/super-grid/src/formValidatorUtil.js +62 -65
  331. package/lib/super-grid/src/formatter.js +36 -41
  332. package/lib/super-grid/src/group-column.vue.js +8 -13
  333. package/lib/super-grid/src/header-context-menu.vue.js +10 -13
  334. package/lib/super-grid/src/header-context-menu.vue2.js +2 -4
  335. package/lib/super-grid/src/index-column.vue.js +7 -10
  336. package/lib/super-grid/src/normal-column-content.vue.js +186 -205
  337. package/lib/super-grid/src/normal-column-content.vue2.js +2 -4
  338. package/lib/super-grid/src/normal-column.vue.js +40 -55
  339. package/lib/super-grid/src/normal-column.vue2.js +2 -4
  340. package/lib/super-grid/src/public-methods.js +12 -14
  341. package/lib/super-grid/src/row-detail.vue.js +7 -10
  342. package/lib/super-grid/src/row-operation.vue.js +19 -26
  343. package/lib/super-grid/src/row-operation.vue2.js +2 -4
  344. package/lib/super-grid/src/scan-util.js +24 -26
  345. package/lib/super-grid/src/search-button.vue.js +12 -17
  346. package/lib/super-grid/src/search-condition-input.vue.js +8 -12
  347. package/lib/super-grid/src/search-condition-list.vue.js +10 -13
  348. package/lib/super-grid/src/search-form-advancedQuery.vue.js +13 -23
  349. package/lib/super-grid/src/search-form-advancedQuery.vue2.js +2 -4
  350. package/lib/super-grid/src/search-form-dialog.vue.js +9 -13
  351. package/lib/super-grid/src/search-form-item.vue.js +16 -24
  352. package/lib/super-grid/src/search-form-item.vue2.js +2 -4
  353. package/lib/super-grid/src/search-form-mobile.vue.js +13 -22
  354. package/lib/super-grid/src/search-form-mobile.vue2.js +2 -4
  355. package/lib/super-grid/src/search-form-number.vue.js +9 -14
  356. package/lib/super-grid/src/search-form-open.vue.js +7 -13
  357. package/lib/super-grid/src/search-form-ordinarySearch.vue.js +11 -19
  358. package/lib/super-grid/src/search-form-ordinarySearch.vue2.js +2 -4
  359. package/lib/super-grid/src/search-form.vue.js +65 -77
  360. package/lib/super-grid/src/search-form.vue2.js +2 -4
  361. package/lib/super-grid/src/search-methods.js +2 -3
  362. package/lib/super-grid/src/selection-column.vue.js +7 -9
  363. package/lib/super-grid/src/store.js +3 -4
  364. package/lib/super-grid/src/super-grid-service.js +121 -128
  365. package/lib/super-grid/src/super-grid.vue.js +186 -217
  366. package/lib/super-grid/src/super-grid.vue2.js +2 -4
  367. package/lib/super-grid/src/utils.js +265 -322
  368. package/lib/super-grid/src/view-image-dialog.vue.js +26 -33
  369. package/lib/super-icon/index.js +5 -7
  370. package/lib/super-icon/src/index.vue.js +5 -7
  371. package/lib/super-icon/src/index.vue2.js +8 -11
  372. package/lib/super-icon/src/index.vue3.js +2 -4
  373. package/lib/super-nine-grid/index.js +5 -7
  374. package/lib/super-nine-grid/src/apis.js +5 -8
  375. package/lib/super-nine-grid/src/custom-formatter.js +5 -7
  376. package/lib/super-nine-grid/src/formatter.js +28 -29
  377. package/lib/super-nine-grid/src/search-form-number.vue.js +8 -12
  378. package/lib/super-nine-grid/src/search-form.vue.js +33 -40
  379. package/lib/super-nine-grid/src/search-form.vue2.js +2 -4
  380. package/lib/super-nine-grid/src/search-methods.js +2 -3
  381. package/lib/super-nine-grid/src/store.js +3 -4
  382. package/lib/super-nine-grid/src/super-grid-service.js +5 -9
  383. package/lib/super-nine-grid/src/super-nine-grid.vue.js +95 -105
  384. package/lib/super-nine-grid/src/super-nine-grid.vue2.js +2 -4
  385. package/lib/super-nine-grid/src/utils.js +31 -27
  386. package/lib/svg-icon/index.js +5 -7
  387. package/lib/svg-icon/src/svg-icon.vue.js +8 -10
  388. package/lib/svg-icon/src/svg-icon.vue2.js +2 -4
  389. package/lib/utils/gogocodeTransfer.js +23 -28
  390. package/lib/utils/memory-cache-utils.js +3 -5
  391. package/lib/utils/organization.js +40 -53
  392. package/lib/utils/utils.js +27 -29
  393. package/lib/utils/value-set.js +68 -70
  394. package/lib/valid-code/index.js +5 -7
  395. package/lib/valid-code/src/valid-code.vue.js +10 -13
  396. package/lib/valid-code/src/valid-code.vue2.js +2 -4
  397. package/lib/workflow-button/index.js +3 -5
  398. package/lib/workflow-button/src/workflow-button.vue.js +34 -39
  399. package/lib/workflow-history-list/index.js +5 -7
  400. package/lib/workflow-history-list/src/api.js +2 -3
  401. package/lib/workflow-history-list/src/workflow-history-list.vue.js +59 -65
  402. package/lib/workflow-history-list/src/workflow-history-list.vue2.js +2 -4
  403. package/lib/workgroup-tree/index.js +5 -7
  404. package/lib/workgroup-tree/src/workgroup-tree.vue.js +11 -17
  405. package/lib/workgroup-tree-inline/index.js +3 -5
  406. package/lib/workgroup-tree-inline/src/search-result.vue.js +21 -25
  407. package/lib/workgroup-tree-inline/src/search-result.vue2.js +2 -4
  408. package/lib/workgroup-tree-inline/src/workgroup-tree-inline.vue.js +43 -52
  409. package/lib/workgroup-tree-inline/src/workgroup-tree-inline.vue2.js +2 -4
  410. package/lib/workgroup-tree-inline/src/workgroup-tree-service.js +5 -7
  411. package/lib/workgroup-tree-mobile/index.js +5 -8
  412. package/lib/workgroup-tree-mobile/src/dept-result.vue.js +11 -14
  413. package/lib/workgroup-tree-mobile/src/dept-result.vue2.js +3 -4
  414. package/lib/workgroup-tree-mobile/src/workgroup-tree-app.vue.js +9 -12
  415. package/lib/workgroup-tree-mobile/src/workgroup-tree-app.vue2.js +2 -4
  416. package/lib/workgroup-tree-mobile/src/workgroup-tree-app.vue3.js +3 -5
  417. package/lib/workgroup-tree-mobile/src/workgroup-tree-inline-app.vue.js +76 -86
  418. package/lib/workgroup-tree-mobile/src/workgroup-tree-inline-app.vue2.js +3 -4
  419. package/lib/workgroup-tree-mobile/src/workgroup-tree-service.js +20 -28
  420. package/lib/workgroup-user-tree/index.js +5 -7
  421. package/lib/workgroup-user-tree/src/workgroup-user-tree.vue.js +11 -17
  422. package/lib/workgroup-user-tree-inline/index.js +3 -5
  423. package/lib/workgroup-user-tree-inline/src/search-result.vue.js +21 -25
  424. package/lib/workgroup-user-tree-inline/src/search-result.vue2.js +2 -4
  425. package/lib/workgroup-user-tree-inline/src/workgroup-tree-inline-service.js +9 -11
  426. package/lib/workgroup-user-tree-inline/src/workgroup-user-tree-inline.vue.js +34 -43
  427. package/lib/workgroup-user-tree-inline/src/workgroup-user-tree-inline.vue2.js +2 -4
  428. package/lib/workgroup-user-tree-mobile/src/dept-path.vue.js +10 -11
  429. package/lib/workgroup-user-tree-mobile/src/dept-path.vue2.js +3 -4
  430. package/lib/workgroup-user-tree-mobile/src/dept-result.vue.js +11 -15
  431. package/lib/workgroup-user-tree-mobile/src/dept-result.vue2.js +3 -4
  432. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-app.vue.js +9 -12
  433. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-app.vue2.js +2 -4
  434. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-app.vue3.js +3 -5
  435. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-inline-app.vue.js +93 -104
  436. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-inline-app.vue2.js +3 -4
  437. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-service.js +16 -25
  438. package/lib/year-range-picker/index.js +3 -5
  439. package/lib/year-range-picker/src/year-range-picker.vue.js +9 -12
  440. package/package.json +1 -1
  441. package/vite.config.js +11 -11
@@ -1,118 +1,109 @@
1
- import { defineComponent as e, ref as a, watch as t, resolveComponent as l, openBlock as s, createElementBlock as i, Fragment as o, withDirectives as n, createElementVNode as u, createVNode as c, withCtx as d, unref as r, vShow as m, toDisplayString as f, createBlock as h, createCommentVNode as v, normalizeClass as y, renderList as p, createTextVNode as g, pushScopeId as b, popScopeId as k } from "vue";
2
- import { ArrowDown as w, ArrowRight as _, StarFilled as A, Star as E, MoreFilled as T } from "@element-plus/icons-vue";
3
- import { useI18n as D } from "vue-i18n";
4
- import { AI_MODELS as I } from "./type.js";
5
- import { formatAiPptHistoryMessage as C, formatBailianHistoryMessage as P, formatDatabaseHistoryMessage as M, formatRagflowHistoryMessage as $, collectById as N, usefuleById as S, deleteByIds as x, getBySessionId as R } from "./util/history-message-util.js";
6
- import j from "dayjs";
7
- import { ElMessage as O } from "element-plus";
8
- import V from "../../src/assets/chat-embed/robot.svg.js";
9
- const F = (e2) => (b("data-v-1e62eff8"), e2 = e2(), k(), e2), Y = { class: "flex-avatar" }, B = ["src"], G = { class: "flex-function-icon" }, z = { class: "chat-embed__sidebar" }, L = { class: "sidebar-header" }, W = ["src"], H = { class: "sidebar-menu" }, K = F(() => u("span", null, "我的收藏", -1)), q = F(() => u("span", null, "查看有用", -1)), J = F(() => u("span", null, "历史记录", -1)), Q = { key: 0, class: "date-group" }, U = { key: 0, class: "date-group-item" }, X = { key: 1, class: "date-group-item" }, Z = { key: 2, class: "date-group-item" }, ee = { key: 3, class: "date-group-item" }, ae = { key: 4, class: "date-group-item" }, te = ["onClick"], le = e({ __name: "sidebar-item", props: { aiModel: { type: String, default: null }, dialogFullScreen: { type: Boolean, default: null } }, emits: ["new-chat-session", "select-history-item", "update-ai-history"], setup(e2, { expose: b2, emit: k2 }) {
10
- const F2 = e2, { t: le2 } = D();
11
- let se = 1;
12
- const ie = a(/* @__PURE__ */ new Map()), oe = a("history"), ne = a(""), ue = a(false), ce = a(true);
13
- t(() => F2.aiModel, (e3, a2) => {
14
- se = 1, oe.value = "history", ne.value = "", fe();
1
+ "use strict";
2
+ const e = require("vue"), t = require("@element-plus/icons-vue"), o = require("vue-i18n"), a = require("./type.js"), l = require("./util/history-message-util.js"), c = require("dayjs"), n = require("element-plus"), r = require("../../src/assets/chat-embed/robot.svg.js"), s = (t2) => (e.pushScopeId("data-v-1e62eff8"), t2 = t2(), e.popScopeId(), t2), i = { class: "flex-avatar" }, d = ["src"], u = { class: "flex-function-icon" }, m = { class: "chat-embed__sidebar" }, h = { class: "sidebar-header" }, p = ["src"], f = { class: "sidebar-menu" }, v = s(() => e.createElementVNode("span", null, "我的收藏", -1)), k = s(() => e.createElementVNode("span", null, "查看有用", -1)), y = s(() => e.createElementVNode("span", null, "历史记录", -1)), g = { key: 0, class: "date-group" }, w = { key: 0, class: "date-group-item" }, N = { key: 1, class: "date-group-item" }, V = { key: 2, class: "date-group-item" }, C = { key: 3, class: "date-group-item" }, E = { key: 4, class: "date-group-item" }, B = ["onClick"], A = e.defineComponent({ __name: "sidebar-item", props: { aiModel: { type: String, default: null }, dialogFullScreen: { type: Boolean, default: null } }, emits: ["new-chat-session", "select-history-item", "update-ai-history"], setup(s2, { expose: A2, emit: _ }) {
3
+ const b = s2, { t: x } = o.useI18n();
4
+ let D = 1;
5
+ const I = e.ref(/* @__PURE__ */ new Map()), S = e.ref("history"), M = e.ref(""), T = e.ref(false), O = e.ref(true);
6
+ e.watch(() => b.aiModel, (e2, t2) => {
7
+ D = 1, S.value = "history", M.value = "", R();
15
8
  }, { immediate: true });
16
- const de = (e3) => {
17
- se++, ue.value || fe();
9
+ const L = (e2) => {
10
+ D++, T.value || R();
18
11
  };
19
- function re() {
20
- ne.value = "", k2("new-chat-session");
12
+ function P() {
13
+ M.value = "", _("new-chat-session");
21
14
  }
22
- function me(e3) {
23
- e3 !== oe.value && (se = 1, oe.value = e3, ue.value = false, fe());
15
+ function F(e2) {
16
+ e2 !== S.value && (D = 1, S.value = e2, T.value = false, R());
24
17
  }
25
- function fe() {
26
- let e3 = "";
27
- if (F2.aiModel === I.INTERACTION)
28
- return ie.value = /* @__PURE__ */ new Map(), void re();
29
- switch (F2.aiModel) {
30
- case I.RAGFLOW:
31
- e3 = "RAGFLOW";
18
+ function R() {
19
+ let e2 = "";
20
+ if (b.aiModel === a.AI_MODELS.INTERACTION)
21
+ return I.value = /* @__PURE__ */ new Map(), void P();
22
+ switch (b.aiModel) {
23
+ case a.AI_MODELS.RAGFLOW:
24
+ e2 = "RAGFLOW";
32
25
  break;
33
- case I.DATABASE:
34
- e3 = "DATABASE";
26
+ case a.AI_MODELS.DATABASE:
27
+ e2 = "DATABASE";
35
28
  break;
36
- case I.DEEPSEEK:
37
- e3 = "BAILIAN";
29
+ case a.AI_MODELS.DEEPSEEK:
30
+ e2 = "BAILIAN";
38
31
  break;
39
- case I.INTERACTION:
32
+ case a.AI_MODELS.INTERACTION:
40
33
  break;
41
- case I.PPT_GENERATION:
42
- e3 = "AIPPT";
34
+ case a.AI_MODELS.PPT_GENERATION:
35
+ e2 = "AIPPT";
43
36
  }
44
- let a2 = 0, t2 = 0;
45
- "useful" === oe.value ? a2 = 1 : "collected" === oe.value && (t2 = 1), window.$vueApp.config.globalProperties.$http.post(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/list/${e3}/${a2}/${t2}`, { pagination: { currentPage: se, pageSize: 30, isShowTotal: false } }).then((e4) => {
46
- if (0 === e4.data.length && se > 1)
47
- return O.info("没有更多历史记录了"), void (ue.value = true);
48
- const a3 = function(e5) {
49
- const a4 = /* @__PURE__ */ new Map(), t3 = /* @__PURE__ */ new Date(), l2 = new Date(t3.getFullYear(), t3.getMonth(), t3.getDate()).getTime(), s2 = l2 - 864e5, i2 = l2 - 6048e5, o2 = l2 - 2592e6;
50
- return e5.forEach((e6) => {
51
- const t4 = new Date(e6.modifiedTime).getTime();
52
- if (t4 >= l2)
53
- a4.has("today") || a4.set("today", []), a4.get("today").push(e6);
54
- else if (t4 >= s2)
55
- a4.has("yesterday") || a4.set("yesterday", []), a4.get("yesterday").push(e6);
56
- else if (t4 >= i2)
57
- a4.has("sevenDays") || a4.set("sevenDays", []), a4.get("sevenDays").push(e6);
58
- else if (t4 >= o2)
59
- a4.has("thirtyDays") || a4.set("thirtyDays", []), a4.get("thirtyDays").push(e6);
37
+ let t2 = 0, o2 = 0;
38
+ "useful" === S.value ? t2 = 1 : "collected" === S.value && (o2 = 1), window.$vueApp.config.globalProperties.$http.post(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/list/${e2}/${t2}/${o2}`, { pagination: { currentPage: D, pageSize: 30, isShowTotal: false } }).then((e3) => {
39
+ if (0 === e3.data.length && D > 1)
40
+ return n.ElMessage.info("没有更多历史记录了"), void (T.value = true);
41
+ const t3 = function(e4) {
42
+ const t4 = /* @__PURE__ */ new Map(), o3 = /* @__PURE__ */ new Date(), a2 = new Date(o3.getFullYear(), o3.getMonth(), o3.getDate()).getTime(), l2 = a2 - 864e5, n2 = a2 - 6048e5, r2 = a2 - 2592e6;
43
+ return e4.forEach((e5) => {
44
+ const o4 = new Date(e5.modifiedTime).getTime();
45
+ if (o4 >= a2)
46
+ t4.has("today") || t4.set("today", []), t4.get("today").push(e5);
47
+ else if (o4 >= l2)
48
+ t4.has("yesterday") || t4.set("yesterday", []), t4.get("yesterday").push(e5);
49
+ else if (o4 >= n2)
50
+ t4.has("sevenDays") || t4.set("sevenDays", []), t4.get("sevenDays").push(e5);
51
+ else if (o4 >= r2)
52
+ t4.has("thirtyDays") || t4.set("thirtyDays", []), t4.get("thirtyDays").push(e5);
60
53
  else {
61
- const l3 = new Date(t4), s3 = j(`${l3.getFullYear()}-${l3.getMonth() + 1}`).format("YYYY-MM");
62
- a4.has(s3) || a4.set(s3, []), a4.get(s3).push(e6);
54
+ const a3 = new Date(o4), l3 = c(`${a3.getFullYear()}-${a3.getMonth() + 1}`).format("YYYY-MM");
55
+ t4.has(l3) || t4.set(l3, []), t4.get(l3).push(e5);
63
56
  }
64
- }), a4;
65
- }(e4.data);
66
- 1 === se ? (e4.data.length < 30 && (ue.value = true), ie.value = a3) : a3.forEach((e5, a4) => {
67
- ie.value.has(a4) ? ie.value.get(a4).push(...e5) : ie.value.set(a4, e5);
57
+ }), t4;
58
+ }(e3.data);
59
+ 1 === D ? (e3.data.length < 30 && (T.value = true), I.value = t3) : t3.forEach((e4, t4) => {
60
+ I.value.has(t4) ? I.value.get(t4).push(...e4) : I.value.set(t4, e4);
68
61
  });
69
- }).catch((e4) => {
62
+ }).catch((e3) => {
70
63
  });
71
64
  }
72
- return b2({ getHistory: fe, addCurrentToSessionHistory: function(e3, a2 = []) {
73
- e3 && setTimeout(() => {
74
- R(e3).then((e4) => {
75
- e4 && (ne.value = e4.id, ie.value.has("today") || (ie.value = new Map([["today", []], ...ie.value])), ie.value.get("today").unshift(e4), a2.length > 0 ? k2("select-history-item", e4, a2) : k2("select-history-item", e4, []));
76
- }).catch((e4) => {
65
+ return A2({ getHistory: R, addCurrentToSessionHistory: function(e2, t2 = []) {
66
+ e2 && setTimeout(() => {
67
+ l.getBySessionId(e2).then((e3) => {
68
+ e3 && (M.value = e3.id, I.value.has("today") || (I.value = new Map([["today", []], ...I.value])), I.value.get("today").unshift(e3), t2.length > 0 ? _("select-history-item", e3, t2) : _("select-history-item", e3, []));
69
+ }).catch((e3) => {
77
70
  });
78
71
  }, 100);
79
- } }), (e3, a2) => {
80
- const t2 = l("el-avatar"), b3 = l("SuperIcon"), D2 = l("el-tooltip"), R2 = l("el-icon"), j2 = l("el-dropdown-item"), se2 = l("el-dropdown-menu"), ue2 = l("el-dropdown"), fe2 = l("el-scrollbar"), he = l("el-button");
81
- return s(), i(o, null, [n(u("div", Y, [c(t2, { size: 40, fit: "cover" }, { default: d(() => [u("img", { src: r(V), alt: "AI Avatar" }, null, 8, B)]), _: 1 }), u("div", G, [c(D2, { class: "box-item", effect: "dark", content: "打开侧边栏" }, { default: d(() => [c(b3, { class: "shousuo-icon", onClick: a2[0] || (a2[0] = (e4) => ce.value = true), iconValue: "amb-icon-zhankaibianlan" })]), _: 1 }), c(D2, { class: "box-item", effect: "dark", content: "新建会话" }, { default: d(() => [c(b3, { class: "shousuo-icon", iconValue: "amb-icon-xinjianhuihua", onClick: re })]), _: 1 })])], 512), [[m, !ce.value]]), n(u("div", z, [u("div", L, [c(t2, { class: "chat-embed__header_avatar", size: 40, fit: "cover" }, { default: d(() => [u("img", { src: r(V), alt: "AI Avatar" }, null, 8, W)]), _: 1 }), u("span", null, f(r(le2)("chatEmbed.name")), 1), c(D2, { class: "box-item", effect: "dark", content: "收起侧边栏" }, { default: d(() => [ce.value ? (s(), h(b3, { key: 0, onClick: a2[1] || (a2[1] = (e4) => ce.value = false), class: "right-icon", iconValue: "amb-icon-shouqibianlan" })) : v("", true)]), _: 1 })]), u("div", H, [u("div", { class: y(["menu-item", { "active-item": "collected" === oe.value }]), onClick: a2[2] || (a2[2] = (e4) => me("collected")) }, [c(b3, { iconValue: "amb-icon-shoucang" }), K, "collected" === oe.value ? (s(), h(R2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(w))]), _: 1 })) : (s(), h(R2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(_))]), _: 1 }))], 2), u("div", { class: y(["menu-item", { "active-item": "useful" === oe.value }]), onClick: a2[3] || (a2[3] = (e4) => me("useful")) }, [c(b3, { iconValue: "amb-icon-youyong" }), q, "useful" === oe.value ? (s(), h(R2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(w))]), _: 1 })) : (s(), h(R2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(_))]), _: 1 }))], 2), u("div", { class: y(["menu-item", { "active-item": "history" === oe.value }]), onClick: a2[4] || (a2[4] = (e4) => me("history")) }, [c(b3, { iconValue: "amb-icon-lishihuihua" }), J, "history" === oe.value ? (s(), h(R2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(w))]), _: 1 })) : (s(), h(R2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(_))]), _: 1 }))], 2)]), c(fe2, { class: "scrollbar-container", onEndReached: de }, { default: d(() => [(s(true), i(o, null, p(ie.value, ([e4, a3]) => (s(), i(o, { key: e4 }, [(a3 == null ? void 0 : a3.length) > 0 ? (s(), i("div", Q, ["today" === e4 ? (s(), i("div", U, "今天")) : "yesterday" === e4 ? (s(), i("div", X, "昨天")) : "sevenDays" === e4 ? (s(), i("div", Z, "七天内")) : "thirtyDays" === e4 ? (s(), i("div", ee, "三十天内")) : (s(), i("div", ae, f(e4), 1)), (s(true), i(o, null, p(a3, (e5) => (s(), i("div", { class: y(["history-item", { "active-item": ne.value === e5.id }]) }, [e5.useful ? (s(), h(b3, { key: 0, iconValue: "amb-icon-youyong" })) : v("", true), e5.collected ? (s(), h(R2, { key: 1 }, { default: d(() => [c(r(A))]), _: 1 })) : v("", true), u("div", { class: "history-subject", onClick: (a4) => function(e6) {
82
- ne.value !== e6.id && (ne.value = e6.id, window.$vueApp.config.globalProperties.$http.get(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/content/${e6.id}`).then((a5) => {
83
- let t3 = [];
84
- switch (F2.aiModel) {
85
- case I.RAGFLOW:
86
- t3 = $(a5);
72
+ } }), (o2, c2) => {
73
+ const s3 = e.resolveComponent("el-avatar"), A3 = e.resolveComponent("SuperIcon"), D2 = e.resolveComponent("el-tooltip"), T2 = e.resolveComponent("el-icon"), R2 = e.resolveComponent("el-dropdown-item"), $ = e.resolveComponent("el-dropdown-menu"), q = e.resolveComponent("el-dropdown"), j = e.resolveComponent("el-scrollbar"), z = e.resolveComponent("el-button");
74
+ return e.openBlock(), e.createElementBlock(e.Fragment, null, [e.withDirectives(e.createElementVNode("div", i, [e.createVNode(s3, { size: 40, fit: "cover" }, { default: e.withCtx(() => [e.createElementVNode("img", { src: e.unref(r), alt: "AI Avatar" }, null, 8, d)]), _: 1 }), e.createElementVNode("div", u, [e.createVNode(D2, { class: "box-item", effect: "dark", content: "打开侧边栏" }, { default: e.withCtx(() => [e.createVNode(A3, { class: "shousuo-icon", onClick: c2[0] || (c2[0] = (e2) => O.value = true), iconValue: "amb-icon-zhankaibianlan" })]), _: 1 }), e.createVNode(D2, { class: "box-item", effect: "dark", content: "新建会话" }, { default: e.withCtx(() => [e.createVNode(A3, { class: "shousuo-icon", iconValue: "amb-icon-xinjianhuihua", onClick: P })]), _: 1 })])], 512), [[e.vShow, !O.value]]), e.withDirectives(e.createElementVNode("div", m, [e.createElementVNode("div", h, [e.createVNode(s3, { class: "chat-embed__header_avatar", size: 40, fit: "cover" }, { default: e.withCtx(() => [e.createElementVNode("img", { src: e.unref(r), alt: "AI Avatar" }, null, 8, p)]), _: 1 }), e.createElementVNode("span", null, e.toDisplayString(e.unref(x)("chatEmbed.name")), 1), e.createVNode(D2, { class: "box-item", effect: "dark", content: "收起侧边栏" }, { default: e.withCtx(() => [O.value ? (e.openBlock(), e.createBlock(A3, { key: 0, onClick: c2[1] || (c2[1] = (e2) => O.value = false), class: "right-icon", iconValue: "amb-icon-shouqibianlan" })) : e.createCommentVNode("", true)]), _: 1 })]), e.createElementVNode("div", f, [e.createElementVNode("div", { class: e.normalizeClass(["menu-item", { "active-item": "collected" === S.value }]), onClick: c2[2] || (c2[2] = (e2) => F("collected")) }, [e.createVNode(A3, { iconValue: "amb-icon-shoucang" }), v, "collected" === S.value ? (e.openBlock(), e.createBlock(T2, { key: 0, class: "dropdown-right" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.ArrowDown))]), _: 1 })) : (e.openBlock(), e.createBlock(T2, { key: 1, class: "dropdown-right" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.ArrowRight))]), _: 1 }))], 2), e.createElementVNode("div", { class: e.normalizeClass(["menu-item", { "active-item": "useful" === S.value }]), onClick: c2[3] || (c2[3] = (e2) => F("useful")) }, [e.createVNode(A3, { iconValue: "amb-icon-youyong" }), k, "useful" === S.value ? (e.openBlock(), e.createBlock(T2, { key: 0, class: "dropdown-right" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.ArrowDown))]), _: 1 })) : (e.openBlock(), e.createBlock(T2, { key: 1, class: "dropdown-right" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.ArrowRight))]), _: 1 }))], 2), e.createElementVNode("div", { class: e.normalizeClass(["menu-item", { "active-item": "history" === S.value }]), onClick: c2[4] || (c2[4] = (e2) => F("history")) }, [e.createVNode(A3, { iconValue: "amb-icon-lishihuihua" }), y, "history" === S.value ? (e.openBlock(), e.createBlock(T2, { key: 0, class: "dropdown-right" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.ArrowDown))]), _: 1 })) : (e.openBlock(), e.createBlock(T2, { key: 1, class: "dropdown-right" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.ArrowRight))]), _: 1 }))], 2)]), e.createVNode(j, { class: "scrollbar-container", onEndReached: L }, { default: e.withCtx(() => [(e.openBlock(true), e.createElementBlock(e.Fragment, null, e.renderList(I.value, ([o3, c3]) => (e.openBlock(), e.createElementBlock(e.Fragment, { key: o3 }, [(c3 == null ? void 0 : c3.length) > 0 ? (e.openBlock(), e.createElementBlock("div", g, ["today" === o3 ? (e.openBlock(), e.createElementBlock("div", w, "今天")) : "yesterday" === o3 ? (e.openBlock(), e.createElementBlock("div", N, "昨天")) : "sevenDays" === o3 ? (e.openBlock(), e.createElementBlock("div", V, "七天内")) : "thirtyDays" === o3 ? (e.openBlock(), e.createElementBlock("div", C, "三十天内")) : (e.openBlock(), e.createElementBlock("div", E, e.toDisplayString(o3), 1)), (e.openBlock(true), e.createElementBlock(e.Fragment, null, e.renderList(c3, (o4) => (e.openBlock(), e.createElementBlock("div", { class: e.normalizeClass(["history-item", { "active-item": M.value === o4.id }]) }, [o4.useful ? (e.openBlock(), e.createBlock(A3, { key: 0, iconValue: "amb-icon-youyong" })) : e.createCommentVNode("", true), o4.collected ? (e.openBlock(), e.createBlock(T2, { key: 1 }, { default: e.withCtx(() => [e.createVNode(e.unref(t.StarFilled))]), _: 1 })) : e.createCommentVNode("", true), e.createElementVNode("div", { class: "history-subject", onClick: (e2) => function(e3) {
75
+ M.value !== e3.id && (M.value = e3.id, window.$vueApp.config.globalProperties.$http.get(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/content/${e3.id}`).then((t2) => {
76
+ let o5 = [];
77
+ switch (b.aiModel) {
78
+ case a.AI_MODELS.RAGFLOW:
79
+ o5 = l.formatRagflowHistoryMessage(t2);
87
80
  break;
88
- case I.DATABASE:
89
- t3 = M(a5);
81
+ case a.AI_MODELS.DATABASE:
82
+ o5 = l.formatDatabaseHistoryMessage(t2);
90
83
  break;
91
- case I.DEEPSEEK:
92
- t3 = P(a5);
84
+ case a.AI_MODELS.DEEPSEEK:
85
+ o5 = l.formatBailianHistoryMessage(t2);
93
86
  break;
94
- case I.INTERACTION:
87
+ case a.AI_MODELS.INTERACTION:
95
88
  break;
96
- case I.PPT_GENERATION:
97
- t3 = C(a5);
89
+ case a.AI_MODELS.PPT_GENERATION:
90
+ o5 = l.formatAiPptHistoryMessage(t2);
98
91
  }
99
- k2("select-history-item", e6, t3);
100
- }).catch((e7) => {
92
+ _("select-history-item", e3, o5);
93
+ }).catch((e4) => {
101
94
  }));
102
- }(e5) }, f(e5.subject), 9, te), c(ue2, { class: "dropdown-right", onCommand: (a4) => function(e6, a5) {
103
- "collect" === e6 || "uncollect" === e6 ? N(a5.id).then(() => {
104
- a5.collected = !a5.collected, k2("update-ai-history", a5);
105
- }) : "useful" === e6 || "unuseful" === e6 ? S(a5.id).then(() => {
106
- a5.useful = !a5.useful, k2("update-ai-history", a5);
107
- }) : "delete" === e6 && x([a5.id]).then(() => {
108
- O.success("已删除该会话"), ie.value.forEach((e7) => {
109
- const t3 = e7.findIndex((e8) => e8.id === a5.id);
110
- -1 !== t3 && e7.splice(t3, 1);
111
- }), ne.value === a5.id && re();
95
+ }(o4) }, e.toDisplayString(o4.subject), 9, B), e.createVNode(q, { class: "dropdown-right", onCommand: (e2) => function(e3, t2) {
96
+ "collect" === e3 || "uncollect" === e3 ? l.collectById(t2.id).then(() => {
97
+ t2.collected = !t2.collected, _("update-ai-history", t2);
98
+ }) : "useful" === e3 || "unuseful" === e3 ? l.usefuleById(t2.id).then(() => {
99
+ t2.useful = !t2.useful, _("update-ai-history", t2);
100
+ }) : "delete" === e3 && l.deleteByIds([t2.id]).then(() => {
101
+ n.ElMessage.success("已删除该会话"), I.value.forEach((e4) => {
102
+ const o5 = e4.findIndex((e5) => e5.id === t2.id);
103
+ -1 !== o5 && e4.splice(o5, 1);
104
+ }), M.value === t2.id && P();
112
105
  });
113
- }(a4, e5), trigger: "click" }, { dropdown: d(() => [c(se2, null, { default: d(() => [e5.collected ? v("", true) : (s(), h(j2, { key: 0, command: "collect" }, { default: d(() => [c(R2, null, { default: d(() => [c(r(A))]), _: 1 }), g("收藏 ")]), _: 1 })), e5.collected ? (s(), h(j2, { key: 1, command: "uncollect" }, { default: d(() => [c(R2, null, { default: d(() => [c(r(E))]), _: 1 }), g("取消收藏 ")]), _: 1 })) : v("", true), e5.useful ? v("", true) : (s(), h(j2, { key: 2, command: "useful" }, { default: d(() => [g("有用")]), _: 1 })), e5.useful ? (s(), h(j2, { key: 3, command: "unuseful" }, { default: d(() => [g("取消有用")]), _: 1 })) : v("", true), c(j2, { command: "delete" }, { default: d(() => [g("删除")]), _: 1 })]), _: 2 }, 1024)]), default: d(() => [c(R2, { class: "more-filled" }, { default: d(() => [c(r(T))]), _: 1 })]), _: 2 }, 1032, ["onCommand"])], 2))), 256))])) : v("", true)], 64))), 128))]), _: 1 }), c(he, { type: "primary", class: "new-session-button", onClick: re }, { icon: d(() => [c(b3, { iconValue: "amb-icon-xinjianhuihua" })]), default: d(() => [g(" 新建会话 ")]), _: 1 })], 512), [[m, ce.value]])], 64);
106
+ }(e2, o4), trigger: "click" }, { dropdown: e.withCtx(() => [e.createVNode($, null, { default: e.withCtx(() => [o4.collected ? e.createCommentVNode("", true) : (e.openBlock(), e.createBlock(R2, { key: 0, command: "collect" }, { default: e.withCtx(() => [e.createVNode(T2, null, { default: e.withCtx(() => [e.createVNode(e.unref(t.StarFilled))]), _: 1 }), e.createTextVNode("收藏 ")]), _: 1 })), o4.collected ? (e.openBlock(), e.createBlock(R2, { key: 1, command: "uncollect" }, { default: e.withCtx(() => [e.createVNode(T2, null, { default: e.withCtx(() => [e.createVNode(e.unref(t.Star))]), _: 1 }), e.createTextVNode("取消收藏 ")]), _: 1 })) : e.createCommentVNode("", true), o4.useful ? e.createCommentVNode("", true) : (e.openBlock(), e.createBlock(R2, { key: 2, command: "useful" }, { default: e.withCtx(() => [e.createTextVNode("有用")]), _: 1 })), o4.useful ? (e.openBlock(), e.createBlock(R2, { key: 3, command: "unuseful" }, { default: e.withCtx(() => [e.createTextVNode("取消有用")]), _: 1 })) : e.createCommentVNode("", true), e.createVNode(R2, { command: "delete" }, { default: e.withCtx(() => [e.createTextVNode("删除")]), _: 1 })]), _: 2 }, 1024)]), default: e.withCtx(() => [e.createVNode(T2, { class: "more-filled" }, { default: e.withCtx(() => [e.createVNode(e.unref(t.MoreFilled))]), _: 1 })]), _: 2 }, 1032, ["onCommand"])], 2))), 256))])) : e.createCommentVNode("", true)], 64))), 128))]), _: 1 }), e.createVNode(z, { type: "primary", class: "new-session-button", onClick: P }, { icon: e.withCtx(() => [e.createVNode(A3, { iconValue: "amb-icon-xinjianhuihua" })]), default: e.withCtx(() => [e.createTextVNode(" 新建会话 ")]), _: 1 })], 512), [[e.vShow, O.value]])], 64);
114
107
  };
115
108
  } });
116
- export {
117
- le as default
118
- };
109
+ module.exports = A;
@@ -1,4 +1,2 @@
1
- const t = "";
2
- export {
3
- t as default
4
- };
1
+ "use strict";
2
+ module.exports = "";
@@ -1,5 +1,3 @@
1
- const e = { DEEPSEEK: "deepseek", RAGFLOW: "ragflow", DATABASE: "database", INTERACTION: "interaction", PPT_GENERATION: "ppt_generation" }, E = { THINKING: "thinking", END: "end", ERROR: "error", FAILED: "failed", NONE: "none" };
2
- export {
3
- e as AI_MODELS,
4
- E as MESSAGE_STATUS
5
- };
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ exports.AI_MODELS = { DEEPSEEK: "deepseek", RAGFLOW: "ragflow", DATABASE: "database", INTERACTION: "interaction", PPT_GENERATION: "ppt_generation" }, exports.MESSAGE_STATUS = { THINKING: "thinking", END: "end", ERROR: "error", FAILED: "failed", NONE: "none" };
@@ -1,57 +1,51 @@
1
- function t(t2) {
2
- return t2.replace(/ID:(\d+)/g, '<amb-ai-tip tip-index="$1"></amb-ai-tip>').replace(/##(\d+)\$\$/g, '<amb-ai-tip tip-index="$1"></amb-ai-tip>');
3
- }
4
- function n(t2) {
5
- if (!t2)
6
- return { thinkingContent: "", mainContent: "" };
7
- if (t2.startsWith("<think>")) {
8
- const n2 = t2.indexOf("</think>");
9
- return { thinkingContent: t2.substring(7, n2), mainContent: t2.substring(n2 + 8) };
10
- }
11
- return { thinkingContent: "", mainContent: t2 };
12
- }
13
- function e(t2) {
14
- if (!t2)
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }), exports.extractFilenameFromUrl = function(t) {
3
+ if (!t)
15
4
  return null;
16
5
  try {
17
- const n2 = new URL(t2), e2 = n2.searchParams.get("response-content-disposition") || n2.searchParams.get("content-disposition") || "";
18
- if (!e2)
6
+ const n = new URL(t), e = n.searchParams.get("response-content-disposition") || n.searchParams.get("content-disposition") || "";
7
+ if (!e)
19
8
  return null;
20
- let i = e2;
9
+ let r = e;
21
10
  try {
22
- i = decodeURIComponent(i);
23
- } catch (t3) {
11
+ r = decodeURIComponent(r);
12
+ } catch (t2) {
24
13
  }
25
- const r = i.match(/filename\*\s*=\s*([^'']*)''([^;]+)/i);
26
- if (r && r[2])
14
+ const i = r.match(/filename\*\s*=\s*([^'']*)''([^;]+)/i);
15
+ if (i && i[2])
27
16
  try {
28
- return decodeURIComponent(r[2].trim()).replace(/^"|"$/g, "");
29
- } catch (t3) {
30
- return r[2].trim().replace(/^"|"$/g, "");
17
+ return decodeURIComponent(i[2].trim()).replace(/^"|"$/g, "");
18
+ } catch (t2) {
19
+ return i[2].trim().replace(/^"|"$/g, "");
31
20
  }
32
- const c = i.match(/filename\s*=\s*"([^"]+)"/i);
33
- if (c && c[1])
21
+ const o = r.match(/filename\s*=\s*"([^"]+)"/i);
22
+ if (o && o[1])
34
23
  try {
35
- return decodeURIComponent(c[1]);
36
- } catch (t3) {
37
- return c[1];
24
+ return decodeURIComponent(o[1]);
25
+ } catch (t2) {
26
+ return o[1];
38
27
  }
39
- const o = i.match(/filename\s*=\s*([^;]+)/i);
40
- if (o && o[1]) {
41
- const t3 = o[1].trim().replace(/^"|"$/g, "");
28
+ const a = r.match(/filename\s*=\s*([^;]+)/i);
29
+ if (a && a[1]) {
30
+ const t2 = a[1].trim().replace(/^"|"$/g, "");
42
31
  try {
43
- return decodeURIComponent(t3);
44
- } catch (n3) {
45
- return t3;
32
+ return decodeURIComponent(t2);
33
+ } catch (n2) {
34
+ return t2;
46
35
  }
47
36
  }
48
37
  return null;
49
- } catch (t3) {
38
+ } catch (t2) {
50
39
  return null;
51
40
  }
52
- }
53
- export {
54
- e as extractFilenameFromUrl,
55
- n as parseAnswerContent,
56
- t as replaceAiTipTags
41
+ }, exports.parseAnswerContent = function(t) {
42
+ if (!t)
43
+ return { thinkingContent: "", mainContent: "" };
44
+ if (t.startsWith("<think>")) {
45
+ const n = t.indexOf("</think>");
46
+ return { thinkingContent: t.substring(7, n), mainContent: t.substring(n + 8) };
47
+ }
48
+ return { thinkingContent: "", mainContent: t };
49
+ }, exports.replaceAiTipTags = function(t) {
50
+ return t.replace(/ID:(\d+)/g, '<amb-ai-tip tip-index="$1"></amb-ai-tip>').replace(/##(\d+)\$\$/g, '<amb-ai-tip tip-index="$1"></amb-ai-tip>');
57
51
  };
@@ -1,96 +1,74 @@
1
- import { getMessageTemplate as e, createAiMessage as t, createUserMessage as n } from "../chat-embed-message.js";
2
- import { MESSAGE_STATUS as o } from "../type.js";
3
- import { parseAnswerContent as i, replaceAiTipTags as s, extractFilenameFromUrl as r } from "./chat-embed-util.js";
4
- import { handleMcpMessage as u } from "./mcp-utils.js";
5
- function c(e2) {
6
- return window.$vueApp.config.globalProperties.$http.get(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/session/${e2}`);
7
- }
8
- function p(e2) {
9
- return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/collect/session/${e2}`);
10
- }
11
- function a(e2) {
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const e = require("../chat-embed-message.js"), t = require("../type.js"), s = require("./chat-embed-util.js"), o = require("./mcp-utils.js");
4
+ exports.collectById = function(e2) {
12
5
  return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/collect/${e2}`);
13
- }
14
- function l(e2) {
15
- return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/useful/session/${e2}`);
16
- }
17
- function f(e2) {
18
- return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/useful/${e2}`);
19
- }
20
- function g(e2) {
6
+ }, exports.collectBySessionId = function(e2) {
7
+ return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/collect/session/${e2}`);
8
+ }, exports.deleteByIds = function(e2) {
21
9
  return window.$vueApp.config.globalProperties.$http.delete(window.$vueApp.config.globalProperties.baseAPI + "/mc/ai-history", { data: e2 });
22
- }
23
- function h(n2) {
24
- const r2 = [];
25
- return n2 && n2.forEach((n3) => {
26
- var _a, _b;
27
- if ("USER" === n3.role) {
28
- if (n3.submitParam) {
29
- const t2 = JSON.parse(n3.submitParam);
30
- r2.push(e("user", t2.question, true, false));
10
+ }, exports.formatAiPptHistoryMessage = function(o2) {
11
+ const n = [];
12
+ return o2 && o2.forEach((o3) => {
13
+ if ("USER" === o3.role) {
14
+ if (o3.submitParam) {
15
+ const t2 = e.createUserMessage(o3.submitParam);
16
+ n.push(t2);
31
17
  }
32
- } else if ("ASSISTANT" === n3.role) {
33
- const e2 = JSON.parse(n3.result), u2 = t({ question: "" }, true), { thinkingContent: c2, mainContent: p2 } = i(e2.answer);
34
- e2.reference && (((_a = e2.reference.doc_aggs) == null ? void 0 : _a.length) && (u2.docAggs = e2.reference.doc_aggs), ((_b = e2.reference.chunks) == null ? void 0 : _b.length) && (u2.referenceChunks = e2.reference.chunks)), u2.content = p2, u2.thinkingContent = c2, u2.thinkingStatus = o.END, u2.showThinkingContent = true, u2.content = s(u2.content), u2.messageType = "history", r2.push(u2);
18
+ } else if ("ASSISTANT" === o3.role) {
19
+ const r = e.createAiMessage({ question: "" }, true);
20
+ if (o3.result.fileUrl) {
21
+ const e2 = s.extractFilenameFromUrl(o3.result.fileUrl) || "点击下载";
22
+ r.content = `PPT已生成:[${e2}](${o3.result.fileUrl})`;
23
+ } else
24
+ r.content = "PPT生成失败,请稍后重试";
25
+ r.thinkingContent = "", r.thinkingStatus = t.MESSAGE_STATUS.END, r.showThinkingContent = false, r.messageType = "history", n.push(r);
35
26
  }
36
- }), r2;
37
- }
38
- function m(e2) {
39
- const i2 = [];
40
- return e2 && e2.forEach((e3) => {
41
- if ("USER" === e3.role) {
42
- if (e3.submitParam) {
43
- const t2 = n(e3.submitParam);
44
- i2.push(t2);
27
+ }), n;
28
+ }, exports.formatBailianHistoryMessage = function(s2) {
29
+ const o2 = [];
30
+ return s2 && s2.forEach((s3) => {
31
+ if ("USER" === s3.role) {
32
+ if (s3.submitParam) {
33
+ const t2 = e.createUserMessage(s3.submitParam);
34
+ o2.push(t2);
45
35
  }
46
- } else if ("ASSISTANT" === e3.role) {
47
- const n2 = t({ question: "" }, true), { answerMessage: s2 } = u(e3.result);
48
- n2.content = s2, n2.thinkingStatus = o.END, n2.showThinkingContent = false, n2.messageType = "history", i2.push(n2);
36
+ } else if ("ASSISTANT" === s3.role) {
37
+ const n = e.createAiMessage({ question: "" }, true);
38
+ n.content = s3.result, n.thinkingContent = "", n.thinkingStatus = t.MESSAGE_STATUS.END, n.showThinkingContent = false, n.messageType = "history", o2.push(n);
49
39
  }
50
- }), i2;
51
- }
52
- function w(e2) {
53
- const i2 = [];
54
- return e2 && e2.forEach((e3) => {
55
- if ("USER" === e3.role) {
56
- if (e3.submitParam) {
57
- const t2 = n(e3.submitParam);
58
- i2.push(t2);
40
+ }), o2;
41
+ }, exports.formatDatabaseHistoryMessage = function(s2) {
42
+ const n = [];
43
+ return s2 && s2.forEach((s3) => {
44
+ if ("USER" === s3.role) {
45
+ if (s3.submitParam) {
46
+ const t2 = e.createUserMessage(s3.submitParam);
47
+ n.push(t2);
59
48
  }
60
- } else if ("ASSISTANT" === e3.role) {
61
- const n2 = t({ question: "" }, true);
62
- n2.content = e3.result, n2.thinkingContent = "", n2.thinkingStatus = o.END, n2.showThinkingContent = false, n2.messageType = "history", i2.push(n2);
49
+ } else if ("ASSISTANT" === s3.role) {
50
+ const r = e.createAiMessage({ question: "" }, true), { answerMessage: i } = o.handleMcpMessage(s3.result);
51
+ r.content = i, r.thinkingStatus = t.MESSAGE_STATUS.END, r.showThinkingContent = false, r.messageType = "history", n.push(r);
63
52
  }
64
- }), i2;
65
- }
66
- function P(e2) {
67
- const i2 = [];
68
- return e2 && e2.forEach((e3) => {
69
- if ("USER" === e3.role) {
70
- if (e3.submitParam) {
71
- const t2 = n(e3.submitParam);
72
- i2.push(t2);
53
+ }), n;
54
+ }, exports.formatRagflowHistoryMessage = function(o2) {
55
+ const n = [];
56
+ return o2 && o2.forEach((o3) => {
57
+ var _a, _b;
58
+ if ("USER" === o3.role) {
59
+ if (o3.submitParam) {
60
+ const t2 = JSON.parse(o3.submitParam);
61
+ n.push(e.getMessageTemplate("user", t2.question, true, false));
73
62
  }
74
- } else if ("ASSISTANT" === e3.role) {
75
- const n2 = t({ question: "" }, true);
76
- if (e3.result.fileUrl) {
77
- const t2 = r(e3.result.fileUrl) || "点击下载";
78
- n2.content = `PPT已生成:[${t2}](${e3.result.fileUrl})`;
79
- } else
80
- n2.content = "PPT生成失败,请稍后重试";
81
- n2.thinkingContent = "", n2.thinkingStatus = o.END, n2.showThinkingContent = false, n2.messageType = "history", i2.push(n2);
63
+ } else if ("ASSISTANT" === o3.role) {
64
+ const r = JSON.parse(o3.result), i = e.createAiMessage({ question: "" }, true), { thinkingContent: a, mainContent: u } = s.parseAnswerContent(r.answer);
65
+ r.reference && (((_a = r.reference.doc_aggs) == null ? void 0 : _a.length) && (i.docAggs = r.reference.doc_aggs), ((_b = r.reference.chunks) == null ? void 0 : _b.length) && (i.referenceChunks = r.reference.chunks)), i.content = u, i.thinkingContent = a, i.thinkingStatus = t.MESSAGE_STATUS.END, i.showThinkingContent = true, i.content = s.replaceAiTipTags(i.content), i.messageType = "history", n.push(i);
82
66
  }
83
- }), i2;
84
- }
85
- export {
86
- a as collectById,
87
- p as collectBySessionId,
88
- g as deleteByIds,
89
- P as formatAiPptHistoryMessage,
90
- w as formatBailianHistoryMessage,
91
- m as formatDatabaseHistoryMessage,
92
- h as formatRagflowHistoryMessage,
93
- c as getBySessionId,
94
- f as usefuleById,
95
- l as usefuleBySessionId
67
+ }), n;
68
+ }, exports.getBySessionId = function(e2) {
69
+ return window.$vueApp.config.globalProperties.$http.get(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/session/${e2}`);
70
+ }, exports.usefuleById = function(e2) {
71
+ return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/useful/${e2}`);
72
+ }, exports.usefuleBySessionId = function(e2) {
73
+ return window.$vueApp.config.globalProperties.$http.put(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/useful/session/${e2}`);
96
74
  };
@@ -1,8 +1,8 @@
1
- import e from "axios";
2
- import { getToken as s } from "../../../src/utils/auth.js";
3
- const a = { sendMessageToMcp: (a2, t) => new Promise((o, n) => {
1
+ "use strict";
2
+ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
+ const e = require("axios"), s = require("../../../src/utils/auth.js"), a = { sendMessageToMcp: (a2, t) => new Promise((o, n) => {
4
4
  const i = { question: a2.question, messageId: t, systemCode: a2.systemCode };
5
- e.defaults.headers.common.Authorization = s(), e.post(window.$vueApp.config.globalProperties.baseAPI + "/component/ai/mcp/chart", i).then((e2) => {
5
+ e.defaults.headers.common.Authorization = s.getToken(), e.post(window.$vueApp.config.globalProperties.baseAPI + "/component/ai/mcp/chart", i).then((e2) => {
6
6
  var _a, _b;
7
7
  if (e2) {
8
8
  const s2 = e2.data;
@@ -47,7 +47,4 @@ function r(e2) {
47
47
  }
48
48
  return "sourceData" === e2.type ? { answerMessage: `<amb-interaction-data dataList='${JSON.stringify(e2.answer.dataList)}' dataTables='${JSON.stringify((_b = e2.answer.sqlInfo) == null ? void 0 : _b.dataTables)}' childTables='${JSON.stringify((_c = e2.answer.sqlInfo) == null ? void 0 : _c.childTables)}'/>` } : "chartData" === e2.type ? { answerMessage: `<amb-auto-chart params='${JSON.stringify(e2.bailianToolParams)}' answer='${JSON.stringify(e2.answer)}' />` } : void 0;
49
49
  }
50
- export {
51
- a as default,
52
- r as handleMcpMessage
53
- };
50
+ exports.default = a, exports.handleMcpMessage = r;
@@ -1,12 +1,8 @@
1
- function e(e2) {
2
- const t2 = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-").slice(0, 19);
3
- return `${e2.replace(/[^a-zA-Z0-9\u4e00-\u9fa5]/g, "_")}_${t2}.json`;
4
- }
5
- function t(e2, t2) {
6
- const n = JSON.stringify(e2, null, 2), o = new Blob([n], { type: "application/json;charset=utf-8" }), c = URL.createObjectURL(o), a = document.createElement("a");
7
- a.href = c, a.download = t2, document.body.appendChild(a), a.click(), document.body.removeChild(a), URL.revokeObjectURL(c);
8
- }
9
- export {
10
- t as downloadJsonFile,
11
- e as generateFileName
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }), exports.downloadJsonFile = function(e, t) {
3
+ const o = JSON.stringify(e, null, 2), n = new Blob([o], { type: "application/json;charset=utf-8" }), c = URL.createObjectURL(n), r = document.createElement("a");
4
+ r.href = c, r.download = t, document.body.appendChild(r), r.click(), document.body.removeChild(r), URL.revokeObjectURL(c);
5
+ }, exports.generateFileName = function(e) {
6
+ const t = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-").slice(0, 19);
7
+ return `${e.replace(/[^a-zA-Z0-9\u4e00-\u9fa5]/g, "_")}_${t}.json`;
12
8
  };
@@ -1,7 +1,5 @@
1
- import o from "./voice.vue.js";
2
- o.install = function(t) {
3
- window.$vueApp.component("VoiceButton", o);
4
- };
5
- export {
6
- o as default
7
- };
1
+ "use strict";
2
+ const e = require("./voice.vue.js");
3
+ e.install = function(o) {
4
+ window.$vueApp.component("VoiceButton", e);
5
+ }, module.exports = e;