SanHQin 1 день назад
Родитель
Сommit
14cef22fb7

+ 1 - 1
dist/index.html

@@ -32,7 +32,7 @@
       width: 100%;
       background: #e6eaf0;
       font-family: '黑体';
-    }</style><link href=./static/css/app.abdf3b127f860435a33b7512bf3e1a43.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.161e82026ac2ae03ab6f.js></script><script type=text/javascript src=./static/js/vendor.bb486323f0fa002ba2e7.js></script><script type=text/javascript src=./static/js/app.adc441610cd032a2719e.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.5f2c68255a7ef2422e265b3e3313c9f5.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.161e82026ac2ae03ab6f.js></script><script type=text/javascript src=./static/js/vendor.bb486323f0fa002ba2e7.js></script><script type=text/javascript src=./static/js/app.08cddc26d2c4926cfba0.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

Разница между файлами не показана из-за своего большого размера
+ 0 - 0
dist/static/css/app.5f2c68255a7ef2422e265b3e3313c9f5.css


Разница между файлами не показана из-за своего большого размера
+ 0 - 0
dist/static/css/app.5f2c68255a7ef2422e265b3e3313c9f5.css.map


Разница между файлами не показана из-за своего большого размера
+ 0 - 0
dist/static/js/app.08cddc26d2c4926cfba0.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 0
dist/static/js/app.08cddc26d2c4926cfba0.js.map


Разница между файлами не показана из-за своего большого размера
+ 0 - 0
dist/static/js/manifest.161e82026ac2ae03ab6f.js.map


BIN
src/assets/icon/secondToolList/ppt.png


+ 2 - 1
src/common/tools.js

@@ -41,4 +41,5 @@ export const tools = {
     71: { name: "AI智能体" },
     56: { name: "投票" },
     72: { name: "应用中心" },
-};
+    73: { name: "PPT" },
+};

+ 66 - 0
src/components/pages/easy/addCourse.vue

@@ -1387,7 +1387,56 @@
                                     />
                                   </div>
                                 </div>
+
+                                <!--start ppt工具-->
+                                <div
+                                  class="tool"
+                                  :class="{
+                                    isToolChoose: itemTool.tool.indexOf(73) != -1
+                                  }"
+                                  @click="addTools(73, itemTaskIndex, toolIndex)"
+                                  v-if="userid == '6c56ec0e-2c74-11ef-bee5-005056b86db5'"
+                                >
+                                  <div
+                                    class="whiteBIcon"
+                                    @click.stop="
+                                      openTools(itemTaskIndex, 73, toolIndex)
+                                    "
+                                  >
+                                    <img
+                                      src="../../../assets/icon/secondToolList/ppt.png"
+                                      alt
+                                    />
+                                    <div style="margin: 5px 0">PPT</div>
+                                  </div>
+                                  <div class="noCTool">
+                                    <img
+                                      src="../../../assets/icon/new/isToolC.png"
+                                      alt=""
+                                    />
+                                  </div>
+                                  <div
+                                    class="isCTool"
+                                    v-if="itemTool.tool.indexOf(73) != -1"
+                                  >
+                                    <img
+                                      src="../../../assets/icon/new/isToolC.png"
+                                      alt=""
+                                    />
+                                  </div>
+                                  <!-- <div class="check" @click="
+                                    addTools(3, itemTaskIndex, toolIndex)
+                                    ">
+                                    <img src="../../../assets/icon/checkNo.png" alt
+                                      v-if="itemTool.tool.indexOf(3) == -1" />
+                                    <div class="checkDiv" v-else>
+                                      <img src="../../../assets/icon/checkedIs.png" alt /><span>已选择</span>
+                                    </div>
+                                  </div> -->
+                                </div>
+                                <!--end PPT工具-->
                               </div>
+
                               <div
                                 class="toolSort"
                                 v-if="itemTool.toolType == 1"
@@ -11511,6 +11560,23 @@ export default {
           itemTaskIndex,
           toolIndex
         );
+      } else if (i == 73){
+        if (!this.cid) {
+          this.$message.error(
+            "极简模式添加时不能添加模板,请添加课程后再修改添加模板"
+          );
+          return;
+        }
+        window.topU.postMessage(
+          {
+            tools: "73y",
+            cid: this.cid,
+            stage: this.unitIndex,
+            task: itemTaskIndex,
+            tool: toolIndex
+          },
+          "*"
+        );
       }
 
       if (

+ 75 - 0
src/components/pages/workPage/index.vue

@@ -0,0 +1,75 @@
+<template>
+  <div class="workPage"></div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      role: this.$route.query.role,
+      type: "",
+      cid: this.$route.query.cid,
+      workId: this.$route.query.wid
+    };
+  },
+  computed: {
+    renderedFormula() {
+      return function(val) {
+        try {
+          // 判断是否含有HTML标签,<tag ...>...</tag>
+          const hasTag = /<([a-zA-Z][\w\-]*)([^>]*)>([\s\S]*?)<\/\1>/g.test(
+            val
+          );
+          if (!hasTag) {
+            val = val.trim().replace(/[\u200B-\u200D\uFEFF]/g, "");
+
+            // 纯文本,整体渲染
+            try {
+              return katex.renderToString(val.trim(), {
+                throwOnError: false,
+                strict: false,
+                output: "htmlAndMathml"
+              });
+            } catch (e) {
+              return val; // 渲染失败原样输出
+            }
+          } else {
+            // 有标签,对每个标签内容渲染
+            return val.replace(
+              /<([a-zA-Z][\w\-]*)([^>]*)>([\s\S]*?)<\/\1>/g,
+              (match, tag, attrs, inner) => {
+                let html;
+                val = val.trim().replace(/[\u200B-\u200D\uFEFF]/g, "");
+                try {
+                  html = katex.renderToString(inner.trim(), {
+                    throwOnError: false,
+                    strict: false,
+                    output: "htmlAndMathml"
+                  });
+                } catch (e) {
+                  html = inner;
+                }
+                return `<${tag}${attrs}>${html}</${tag}>`;
+              }
+            );
+          }
+        } catch (e) {
+          console.error("KaTeX渲染错误:", e);
+          return val;
+        }
+      };
+    }
+  }
+};
+</script>
+
+<style scoped>
+.workPage {
+  width: 100vw;
+  height: 100vh;
+  background-color: #fff;
+}
+</style>

+ 9 - 0
src/router/index.js

@@ -157,6 +157,7 @@ import portraitL from '@/components/pages/liyuan/page/portrait'
 import teadTest from '@/components/pages/liyuan/page/teadTest'
 import Listudent from '@/components/pages/liyuan/page/student'
 import safeTest from '@/components/pages/liyuan/page/safeTest'
+import workPage from '@/components/pages/workPage/index'
 
 // 全局修改默认配置,点击空白处不能关闭弹窗
 ElementUI.Dialog.props.closeOnClickModal.default = false
@@ -1364,5 +1365,13 @@ export default new Router({
           requireAuth: '' // 不需要鉴权
       }
   },
+  {
+    path: '/workPage',
+    name: 'workPage',
+    component: workPage,
+    meta: {
+      requireAuth: '' // 是否需要判断是否登录,这里是需要判断
+    }
+  },
   ]
 })

Некоторые файлы не были показаны из-за большого количества измененных файлов