From ae8535b861f9177508d9e5493e0fe9e47978c915 Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期一, 31 八月 2026 16:58:47 +0800
Subject: [PATCH] 测试完成
---
src/views/knowledge/education/index.vue | 44 +++++++++++++++++++++++++++++++-------------
1 files changed, 31 insertions(+), 13 deletions(-)
diff --git a/src/views/knowledge/education/index.vue b/src/views/knowledge/education/index.vue
index f5eafa0..51361a0 100644
--- a/src/views/knowledge/education/index.vue
+++ b/src/views/knowledge/education/index.vue
@@ -1,11 +1,10 @@
<template>
<div class="educationmanagement">
-
<!-- 宸︿晶鏍� -->
<div class="sidecolumn">
<div class="sidecolumn-top">
<div class="top-wj">瀹f暀绫诲瀷</div>
- <div class="top-tj" @click="dialogFormVisible = true">+娣诲姞绫诲埆</div>
+ <div class="top-tj" @click="Newcategory">+娣诲姞绫诲埆</div>
</div>
<div class="center-ss">
<el-input
@@ -88,7 +87,6 @@
>
<el-option
v-for="item in courtyardlist"
- :key="item.label"
:label="item.label"
:value="item.label"
>
@@ -112,7 +110,6 @@
>
<el-option
v-for="(item, index) in qyoptions"
- :key="item.value"
:label="item.label"
:value="item.value"
>
@@ -227,7 +224,7 @@
size="medium"
type="text"
@click="illnessUpdate(scope.row)"
- v-hasPermi="['system:user:edit']"
+
><span class="button-textxg"
><i class="el-icon-date"></i>璇︽儏</span
></el-button
@@ -317,7 +314,7 @@
size="medium"
type="text"
@click="goQRCode(scope.row)"
- v-hasPermi="['system:user:edit']"
+
>
<span class="button-text"
><i class="el-icon-edit"></i>浜岀淮鐮�</span
@@ -327,7 +324,6 @@
size="medium"
type="text"
@click="Vieweducation(scope.row)"
- v-hasPermi="['system:user:edit']"
><span class="button-textck"
><i class="el-icon-edit"></i>棰勮</span
></el-button
@@ -336,7 +332,6 @@
size="medium"
type="text"
@click="handleUpdate(scope.row)"
- v-hasPermi="['system:user:edit']"
><span class="button-textxg"
><i class="el-icon-edit"></i>淇敼</span
></el-button
@@ -345,7 +340,6 @@
size="medium"
type="text"
@click="handleDelete(scope.row)"
- v-hasPermi="['system:user:remove']"
><span class="button-textsc"
><i class="el-icon-edit"></i>鍒犻櫎</span
></el-button
@@ -598,6 +592,7 @@
queryParams: {
pageNum: 1,
pageSize: 10,
+ hetype: 1,
isavailable: "",
},
};
@@ -785,6 +780,13 @@
query: { id: row.id },
});
},
+ Newcategory() {
+ (this.classifyform = {}), //绫诲埆琛ㄥ崟
+ (this.radio = "涓诲垎绫�");
+ this.dialogFormVisible = true;
+ this.zifon = true;
+ this.zufon = true;
+ },
// 鏌ョ湅瀹f暀
Vieweducation(row) {
this.htmlRichText = null;
@@ -795,6 +797,7 @@
console.log(response.data, "鏁版嵁"); // 杈撳嚭鑾峰彇鍒扮殑鏂囦欢鍐呭
this.htmlRichText = response.data;
this.htmlRichText = this.addStyleToImages(this.htmlRichText);
+ // console.log(this.htmlRichText);
})
.catch((error) => {
this.$modal.msgError("鑾峰彇瀵屾枃鏈け璐�");
@@ -802,10 +805,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;
},
/** 鍒犻櫎鎸夐挳鎿嶄綔 */
@@ -824,8 +838,8 @@
},
// 鎵撳紑缁熻鍥捐〃
statistics() {
- this.Collarrname=[];
- this.Collarrvalue=[];
+ this.Collarrname = [];
+ this.Collarrvalue = [];
//鍙栨暟鎹�
let obj = { assortid: 13, isavailable: "", pageNum: 1, pageSize: 20 };
getlibrarylist(obj).then((response) => {
@@ -857,7 +871,7 @@
},
// 鏌ヨ鏍�
getDeptTree() {
- getheLibraryAssort({}).then((res) => {
+ getheLibraryAssort({ hetype: 1 }).then((res) => {
this.deptOptions = res.rows;
this.dialogFormVisible = false;
});
@@ -932,8 +946,12 @@
this.dialogFormVisible = true;
if (!b.pid) {
this.radio = "涓诲垎绫�";
+ this.title = "淇敼涓诲垎绫�";
+ this.zufon = false;
} else {
this.radio = "瀛愬垎绫�";
+ this.title = "淇敼瀛愬垎绫�";
+ this.zifon = false;
}
this.classifyform = b;
this.dialogFormVisible = true;
--
Gitblit v1.9.3