From 54e0b4ee48a281810bb910691b7d076f0c88204c Mon Sep 17 00:00:00 2001
From: long <515897141@qq.com>
Date: 星期五, 16 七月 2021 11:18:10 +0800
Subject: [PATCH] 功能展示页:优化列表高度计算

---
 src/components/WangEnduit/index.vue |   16 +++++++++++++++-
 1 files changed, 15 insertions(+), 1 deletions(-)

diff --git a/src/components/WangEnduit/index.vue b/src/components/WangEnduit/index.vue
index b5ed31b..3e0d96d 100644
--- a/src/components/WangEnduit/index.vue
+++ b/src/components/WangEnduit/index.vue
@@ -87,7 +87,7 @@
       formData.append('file', files[0])
       self.postFN(
         {
-          url: 'admin/image/upload',
+          url: 'admin/image/upload?folderCode=IMG',
           header: { 'Content-Type': 'multipart/form-data' },
           params: formData,
           mockData: {
@@ -108,6 +108,20 @@
       // info 鏄渶瑕佹彁绀虹殑鍐呭
       self.$messagewarn(info)
     }
+    // 杩囨护word澶嶅埗
+    this.editor.customConfig.pasteTextHandle = function(content) {
+      var html = content
+      html = html.replace(/<\/?SPANYES[^>]*>/gi, '')//  绉婚櫎span
+      html = html.replace(/<\!\-\-(.|[\r\n])*?\-\->/gi, '')//  绉婚櫎娉ㄩ噴
+      html = html.replace(/<(\w[^>]*) {2}lang=([^|>]*)([^>]*)/gi, '<$1$3')// 绉婚櫎lang灞炴��
+      html = html.replace(/<\\?\?xml[^>]*>/gi, '')//  绉婚櫎xml鍜岀浉鍏虫弿杩�
+      html = html.replace(/<\/?\w+:[^>]*>/gi, '')// 绉婚櫎xml鍛藉悕绌洪棿鐨勬爣绛�
+      html = html.replace(/&nbsp;/gi, '')//  绉婚櫎绌烘牸
+      html = html.replace(/^\s+|\s+$/g, '')
+      html = html.replace(/<o:p> <\/o:p>/g, '')// 绉婚櫎鏍囩
+      html = html.replace(/<br\/>/g, '')// 绉婚櫎br鏍囩
+      return html
+    }
     this.editor.create() // 鍒涘缓瀵屾枃鏈疄渚�
     // if (!this.content) {
     //     // this.editor.txt.html('璇风紪杈戝唴瀹�1')

--
Gitblit v1.8.0