From 9985fd128b46f43d02f8ca6313a1862ea6bf26f5 Mon Sep 17 00:00:00 2001
From: yiming <m13691596795@163.com>
Date: 星期二, 30 七月 2024 17:34:15 +0800
Subject: [PATCH] 五单元完成

---
 src/books/mathBook/view/components/index.vue |   12 ++++++++++--
 1 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/src/books/mathBook/view/components/index.vue b/src/books/mathBook/view/components/index.vue
index 87f357e..65ba975 100644
--- a/src/books/mathBook/view/components/index.vue
+++ b/src/books/mathBook/view/components/index.vue
@@ -163,7 +163,7 @@
 
     // 娴嬭瘯椤甸潰璺宠浆
     // setTimeout(() => {
-    //   this.gotoPage(2, 10);
+    //   this.gotoPage(1, 9);
     //   setTimeout(() => {
     //     this.renderSign("Highlight", {
     //       id: "2ACA9359",
@@ -866,8 +866,16 @@
           if (!res.data.data) return [];
           for (let index = 0; index < res.data.data.length; index++) {
             const item = res.data.data[index];
+            // 鏁板鍏紡鍔犵被鍚嶅幓淇敼鏍峰紡
+            if(item.type && item.type == 'material') {
+              if(!item.infoList.length) return false
+              item.infoList.forEach(citem => {
+                if(citem.answer) citem.answer = citem.answer.replace(/\<math/gi, '<math class="examination-math"')
+              })
+            } else {
+              if(item.answer) item.answer = item.answer.replace(/\<math/gi, '<math class="examination-math"')
+            }
               item.isCollect = this.collectId.indexOf(item.id) > -1 ? true :false
-            console.log(item.id ,this.collectId.indexOf(item.id));
             if (this.questionId[num][page].indexOf(item.id) > -1) {
               if (item.type && item.type == "material") {
                 cardList.push(item);

--
Gitblit v1.9.1