Browse Source

首页公告明细富文本字数限制提示取消

cyy 2 years ago
parent
commit
b28e14ff7e
2 changed files with 12 additions and 2 deletions
  1. 11 1
      src/components/ibps-ueditor/index.vue
  2. 1 1
      src/views/platform/system/news/detail.vue

+ 11 - 1
src/components/ibps-ueditor/index.vue

@@ -54,6 +54,10 @@ export default {
       type: Boolean,
       default: false
     },
+    wordLimit: {
+      type: Boolean,
+      default: true
+    },
     destroy: {
       type: Boolean,
       default: false
@@ -92,12 +96,18 @@ export default {
     }
   },
   data() {
+    const formatCurrentDate = ()=> {
+      let arr = defaultConfig()
+      let arr1 = defaultConfig()
+      arr.wordCount=false
+      return this.wordLimit==true?arr1:arr
+    }
     return {
       editor: null,
       id: null,
       status: 0,
       initValue: '',
-      defaultConfig: defaultConfig()
+      defaultConfig: formatCurrentDate()
     }
   },
   computed: {

+ 1 - 1
src/views/platform/system/news/detail.vue

@@ -64,7 +64,7 @@
                     <span v-else>/</span>
                 </el-form-item>
                 <el-form-item label="内容:" prop="content">
-                    <ibps-ueditor v-model="form.content" :readonly="readonly" destroy />
+                    <ibps-ueditor v-model="form.content" :readonly="readonly" :wordLimit="false" destroy />
                 </el-form-item>
             </el-form>
         </el-row>