WXL
2024-09-24 83898e6b7ff3996fcef889042442a25753b07dea
src/views/knowledge/education/index.vue
@@ -447,7 +447,7 @@
    <el-dialog title="模板预览" :visible.sync="previewtf" width="60%">
      <div class="preview-left">
        <!-- 单选 -->
        <div v-html="richText"></div>
        <div v-html="htmlRichText"></div>
      </div>
      <!-- <span slot="footer" class="dialog-footer">
        <el-button @click="previewGo">前往模板详情修改</el-button>
@@ -501,7 +501,7 @@
      haoeducation: "",
      indexid: null,
      inputValue: "",
      richText: "",
      htmlRichText: "",
      radio: "主分类",
      inputVisible: false,
      previewtf: false,
@@ -652,14 +652,14 @@
    },
    // 查看宣教
    Vieweducation(row) {
      this.richText = null;
      this.htmlRichText = null;
      this.previewtf = true;
      axios
        .get(row.richText)
        .get(row.htmlRichText)
        .then((response) => {
          console.log(response.data, "数据"); // 输出获取到的文件内容
          this.richText = response.data;
          this.richText = this.addStyleToImages(this.richText);
          this.htmlRichText = response.data;
          this.htmlRichText = this.addStyleToImages(this.htmlRichText);
        })
        .catch((error) => {
          this.$modal.msgError("获取富文本失败");