| 
														
															@@ -7,7 +7,7 @@ import { isNumber } from '@/utils/is' 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import { ElMessage } from 'element-plus' 
														 | 
														
														 | 
														
															 import { ElMessage } from 'element-plus' 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import { useLocaleStore } from '@/store/modules/locale' 
														 | 
														
														 | 
														
															 import { useLocaleStore } from '@/store/modules/locale' 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import { getAccessToken, getTenantId } from '@/utils/auth' 
														 | 
														
														 | 
														
															 import { getAccessToken, getTenantId } from '@/utils/auth' 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-import { updateFile } from '@/api/infra/file/index.ts' 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+// import { updateFile } from '@/api/infra/file/index.ts' 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															 defineOptions({ name: 'Editor' }) 
														 | 
														
														 | 
														
															 defineOptions({ name: 'Editor' }) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -62,7 +62,8 @@ const handleCreated = (editor: IDomEditor) => { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															 // 编辑器配置 
														 | 
														
														 | 
														
															 // 编辑器配置 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import { getExcludeKeys } from './util/toolbarConfig' 
														 | 
														
														 | 
														
															 import { getExcludeKeys } from './util/toolbarConfig' 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-const toolbarConfig = reactive({  insertKeys: {index: 0, keys: ['uploadAttachment']}, excludeKeys: getExcludeKeys() }) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+// const toolbarConfig = reactive({  insertKeys: {index: 0, keys: ['uploadAttachment']}, excludeKeys: getExcludeKeys() }) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+const toolbarConfig = reactive({  excludeKeys: getExcludeKeys() }) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															 // 编辑器配置 
														 | 
														
														 | 
														
															 // 编辑器配置 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 const editorConfig = computed((): IEditorConfig => { 
														 | 
														
														 | 
														
															 const editorConfig = computed((): IEditorConfig => { 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -149,25 +150,25 @@ const editorConfig = computed((): IEditorConfig => { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															           } 
														 | 
														
														 | 
														
															           } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         }, 
														 | 
														
														 | 
														
															         }, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         // 上传附件 
														 | 
														
														 | 
														
															         // 上传附件 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-        uploadAttachment: { 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-          allowedFileTypes: ['.doc', '.docx', '.xls', '.xlsx', '.ppt', '.pptx', '.pdf', '.txt'], 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-          customUpload(file: File, insertFn: Function) { 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            let formData = new FormData() 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            formData.append("file", file) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            const name = file.name.split('.')[0] 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            updateFile(formData).then(res => { 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-              if (res.code === 0) { 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                insertFn(name, res.data) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-              } 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            }) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-          } 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-        } 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-      }, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-      hoverbarKeys: { 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-        attachment: { 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-          menuKeys: ['downloadAttachment'] 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-        } 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        // uploadAttachment: { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //   allowedFileTypes: ['.doc', '.docx', '.xls', '.xlsx', '.ppt', '.pptx', '.pdf', '.txt'], 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //   customUpload(file: File, insertFn: Function) { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //     let formData = new FormData() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //     formData.append("file", file) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //     const name = file.name.split('.')[0] 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //     updateFile(formData).then(res => { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //       if (res.code === 0) { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //         insertFn(name, res.data) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //       } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //     }) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        //   } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        // } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															       }, 
														 | 
														
														 | 
														
															       }, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+      // hoverbarKeys: { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+      //   attachment: { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+      //     menuKeys: ['downloadAttachment'] 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+      //   } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+      // }, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															       uploadImgShowBase64: true 
														 | 
														
														 | 
														
															       uploadImgShowBase64: true 
														 | 
													
												
											
												
													
														| 
														 | 
														
															     }, 
														 | 
														
														 | 
														
															     }, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															     props.editorConfig || {} 
														 | 
														
														 | 
														
															     props.editorConfig || {} 
														 |