chao 1 سال پیش
والد
کامیت
315f06187b

+ 1 - 1
dist/assets/Details-5xfXjZAf.js → dist/assets/Details-wN4vK5dj.js

@@ -1 +1 @@
-import{u as m,r as i,o as p,a as l,b as a,c as b,d as t,w as s,F as f,H as h,e as n,t as k,f as v,g,h as r,i as y,C,j as x,P as B,k as N}from"./index-BT6Y5BD1.js";const V={class:"iframDiv"},P={__name:"Details",setup(D){const{query:u,params:o}=m();console.log(u,o);const e=i("");return p(()=>{e.value=o.title}),(w,F)=>{const c=l("el-breadcrumb-item"),_=l("el-breadcrumb"),d=l("el-page-header");return a(),b(f,null,[t(h),t(d,null,{breadcrumb:s(()=>[t(_,{separator:"/"},{default:s(()=>[t(c,{to:{path:"/"}},{default:s(()=>[n(" 首页 ")]),_:1}),t(c,null,{default:s(()=>[n(k(v(o).title),1)]),_:1})]),_:1})]),default:s(()=>[g("div",V,[e.value=="课程列表"?(a(),r(C,{key:0})):e.value=="资源中心"?(a(),r(x,{key:1})):e.value=="实践中心"?(a(),r(B,{key:2})):e.value=="其他课程资源"?(a(),r(N,{key:3})):y("",!0)])]),_:1})],64)}}};export{P as default};
+import{u as m,r as i,o as p,a as l,b as a,c as b,d as t,w as s,F as f,H as h,e as n,t as k,f as v,g,h as r,i as y,C,j as x,P as B,k as N}from"./index-vaqoWSCO.js";const V={class:"iframDiv"},P={__name:"Details",setup(D){const{query:u,params:o}=m();console.log(u,o);const e=i("");return p(()=>{e.value=o.title}),(w,F)=>{const c=l("el-breadcrumb-item"),_=l("el-breadcrumb"),d=l("el-page-header");return a(),b(f,null,[t(h),t(d,null,{breadcrumb:s(()=>[t(_,{separator:"/"},{default:s(()=>[t(c,{to:{path:"/"}},{default:s(()=>[n(" 首页 ")]),_:1}),t(c,null,{default:s(()=>[n(k(v(o).title),1)]),_:1})]),_:1})]),default:s(()=>[g("div",V,[e.value=="课程列表"?(a(),r(C,{key:0})):e.value=="资源中心"?(a(),r(x,{key:1})):e.value=="实践中心"?(a(),r(B,{key:2})):e.value=="其他课程资源"?(a(),r(N,{key:3})):y("",!0)])]),_:1})],64)}}};export{P as default};

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/assets/admin-1FckfxIc.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/assets/index-nZegvjYP.css


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/assets/index-vaqoWSCO.js


+ 2 - 2
dist/index.html

@@ -8,8 +8,8 @@
     <script>
       document.domain = "cocorobo.cn"
     </script>
-    <script type="module" crossorigin src="./assets/index-BT6Y5BD1.js"></script>
-    <link rel="stylesheet" crossorigin href="./assets/index-FOxq30u5.css">
+    <script type="module" crossorigin src="./assets/index-vaqoWSCO.js"></script>
+    <link rel="stylesheet" crossorigin href="./assets/index-nZegvjYP.css">
   </head>
   <body>
     <div id="app"></div>

+ 38 - 6
src/components/main/courseSelect.vue

@@ -281,17 +281,49 @@ const openCourseDetail = (id) => {
   // 会返回复制得课程
   top.U.A.Request("https://pbl.cocorobo.cn/api/pbl/getcopyCourseSz", [id], function (res) {
     console.log(res)
-  }, [], { "type": "POST", "withCredentials": true });   
-  top.U.MD.D.I.openInApplication("studyDetail", id, 2, user.user.type); //这个是打开指定的课程接口
+    if (res.value[0].length > 0) {
+      let isSave = res.value[0].filter(x => {
+        return x.courseId == id
+      })
+      if (isSave.length > 0) {
+        top.U.MD.D.I.openInApplication("studyDetail", id, 2, user.user.type); //这个是打开指定的课程接口
+      } else {
+        updateCourseId(id,"openCourseDetail")
+      }
+    }
+  }, [], { "type": "POST", "withCredentials": true });
+
 }
 const updateCourse = id => {
   // 会返回courseId和state 两个参数  然后打开
-  top.U.A.Request("https://pbl.cocorobo.cn/api/pbl/copyCourseSz", [id,user.user.userid], function (res) {
+  top.U.A.Request("https://pbl.cocorobo.cn/api/pbl/getcopyCourseSz", [id], function (res) {
+    console.log(res)
+    if (res.value[0].length > 0) {
+      let isSave = res.value[0].filter(x => {
+        return x.courseId == id
+      })
+      if (isSave.length > 0) {
+        top.U.MD.D.I.openInApplication('openCourseUpdate', id); //这个是打开指定的课程接口
+      } else {
+        updateCourseId(id,"updateCourse")
+      }
+    }
+  }, [], { "type": "POST", "withCredentials": true });
+  // top.U.A.Request("https://pbl.cocorobo.cn/api/pbl/copyCourseSz", [id, user.user.userid], function (res) {
+  //   console.log(res)
+  //   if (res.value[0][0].courseId != "") {
+  //     top.U.MD.D.I.openInApplication('openCourseUpdate', res.value[0][0].courseId)
+  //   }
+  // }, [], { "type": "POST", "withCredentials": true });
+}
+
+const updateCourseId = (id,type) => {
+  top.U.A.Request("https://pbl.cocorobo.cn/api/pbl/copyCourseSz", [id, user.user.userid], function (res) {
     console.log(res)
     if (res.value[0][0].courseId != "") {
-      top.U.MD.D.I.openInApplication('openCourseUpdate', res.value[0][0].courseId)
+      top.U.MD.D.I.openInApplication(type, res.value[0][0].courseId)
     }
-   }, [], { "type": "POST", "withCredentials": true });  
+  }, [], { "type": "POST", "withCredentials": true });
 }
 
 const ReductionCourse = id => {
@@ -301,7 +333,7 @@ const ReductionCourse = id => {
 
 const updateReduction = () => {
   top.U.A.Request("https://pbl.cocorobo.cn/api/pbl/revertCourseSz", [updateReductionId.value], function (res) {
-    console.log(res,"还原")
+    console.log(res, "还原")
     dialogVisible.value = false
   }, [], { "type": "POST", "withCredentials": true });
 

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است