From 15c90ad541d895a4e0ceab0dd430260535479341 Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期四, 07 五月 2026 10:20:44 +0800
Subject: [PATCH] 测试完成
---
src/views/knowledge/education/index.vue | 37 +++++++++++++++++++++++--------------
1 files changed, 23 insertions(+), 14 deletions(-)
diff --git a/src/views/knowledge/education/index.vue b/src/views/knowledge/education/index.vue
index 5a090ab..8b48504 100644
--- a/src/views/knowledge/education/index.vue
+++ b/src/views/knowledge/education/index.vue
@@ -1,6 +1,5 @@
<template>
<div class="educationmanagement">
-
<!-- 宸︿晶鏍� -->
<div class="sidecolumn">
<div class="sidecolumn-top">
@@ -596,7 +595,7 @@
queryParams: {
pageNum: 1,
pageSize: 10,
- hetype:1,
+ hetype: 1,
isavailable: "",
},
};
@@ -784,11 +783,11 @@
query: { id: row.id },
});
},
- Newcategory(){
- this.classifyform= {}, //绫诲埆琛ㄥ崟
- this.radio = "涓诲垎绫�";
- this.dialogFormVisible = true
- this.zifon = true;
+ Newcategory() {
+ (this.classifyform = {}), //绫诲埆琛ㄥ崟
+ (this.radio = "涓诲垎绫�");
+ this.dialogFormVisible = true;
+ this.zifon = true;
this.zufon = true;
},
// 鏌ョ湅瀹f暀
@@ -800,9 +799,8 @@
.then((response) => {
console.log(response.data, "鏁版嵁"); // 杈撳嚭鑾峰彇鍒扮殑鏂囦欢鍐呭
this.htmlRichText = response.data;
- // this.htmlRichText = this.addStyleToImages(this.htmlRichText);
- console.log(this.htmlRichText);
-
+ this.htmlRichText = this.addStyleToImages(this.htmlRichText);
+ // console.log(this.htmlRichText);
})
.catch((error) => {
this.$modal.msgError("鑾峰彇瀵屾枃鏈け璐�");
@@ -810,10 +808,21 @@
});
},
addStyleToImages(html) {
- return html.replace(
+ if (!html) return html;
+
+ // 1. 鍏堜慨澶嶈矾寰�
+ let processedHtml = html.replace(
+ /\/aifollowup\/aifollowup\//g,
+ "/aifollowup/"
+ );
+
+ // 2. 鍐嶄慨澶嶆牱寮�
+ processedHtml = processedHtml.replace(
/<img([^>]*)style=(['"])(?:(?!\2).)*\2([^>]*)>/g,
'<img$1style="width:100%;height:auto;"$3>'
);
+
+ return processedHtml;
},
/** 鍒犻櫎鎸夐挳鎿嶄綔 */
@@ -832,8 +841,8 @@
},
// 鎵撳紑缁熻鍥捐〃
statistics() {
- this.Collarrname=[];
- this.Collarrvalue=[];
+ this.Collarrname = [];
+ this.Collarrvalue = [];
//鍙栨暟鎹�
let obj = { assortid: 13, isavailable: "", pageNum: 1, pageSize: 20 };
getlibrarylist(obj).then((response) => {
@@ -865,7 +874,7 @@
},
// 鏌ヨ鏍�
getDeptTree() {
- getheLibraryAssort({ hetype: 2 }).then((res) => {
+ getheLibraryAssort({ hetype: 1 }).then((res) => {
this.deptOptions = res.rows;
this.dialogFormVisible = false;
});
--
Gitblit v1.9.3