chenxiong 3 жил өмнө
parent
commit
e309463f1e

+ 1 - 0
src/apis/login.js

@@ -82,6 +82,7 @@ export default {
       headers:{
       headers:{
         AuthorizationToken:"WX "+data.token
         AuthorizationToken:"WX "+data.token
       },
       },
+      noToken:true,
 			url: '/app/user/bind_idcard',
 			url: '/app/user/bind_idcard',
 			method: 'post',
 			method: 'post',
 			data: data
 			data: data

+ 2 - 2
src/axios.js

@@ -1,9 +1,9 @@
 import axios from 'axios'
 import axios from 'axios'
 import store from './store'
 import store from './store'
 // export const BASE_URL = 'https://api.xyyxt.net'   //release
 // export const BASE_URL = 'https://api.xyyxt.net'   //release
-// export const BASE_URL = 'http://42.192.164.187:19005'    //test
+export const BASE_URL = 'http://42.192.164.187:19005'    //test
 // export const BASE_URL = 'http://api.xyyxt.net:19009'   //预发布
 // export const BASE_URL = 'http://api.xyyxt.net:19009'   //预发布
-export const BASE_URL = 'http://192.168.1.222:5055'    //dev
+// export const BASE_URL = 'http://192.168.1.222:5055'    //dev
 export const tenantId = '867735392558919680'
 export const tenantId = '867735392558919680'
 
 
 
 

+ 120 - 48
src/pages/course-detail/index.vue

@@ -22,7 +22,7 @@
                   :style="{
                   :style="{
                     backgroundImage: `url(${$tools.splitImgHost(
                     backgroundImage: `url(${$tools.splitImgHost(
                       goodsData.coverUrl,
                       goodsData.coverUrl,
-                      true
+                      false
                     )})`,
                     )})`,
                   }"
                   }"
                 >
                 >
@@ -2225,6 +2225,40 @@
       </span>
       </span>
     </el-dialog>
     </el-dialog>
 
 
+    <el-dialog
+      width="996px"
+      height="600px"
+      class="info"
+      :visible.sync="showAgreementModal"
+      :close-on-click-modal="false"
+      :close-on-press-escape="false"
+      :show-close="false"
+      title="提示"
+    >
+      <div class="">
+        <div>
+          本产品(或服务)提供【{{
+            goodsData.goodsName
+          }}】课程的在线学习功能,为使用这些功能,我们需要使用您设备上的摄像头,并收集以下个人信息:
+          <span v-for="(item, listIndex) in listData" :key="listIndex"
+            >{{ item.fieldName }}、</span
+          >
+          <!-- 姓名、性别、身份证号码、移动电话号码、身份证照片、一寸照、证书名称/岗位、证书编号、有效期、人脸照片(每节课随机拍摄三张)、 -->
+          学习详细记录。
+        </div>
+        <div>
+          我们会将上述信息提供至广东省建设执业注册管理中心等第三方组织使用,用于继续教育备案等。如果您拒绝,将导致这些功能无法实现,但不影响您使用本产品(或服务)的其他业务功能。
+        </div>
+      </div>
+
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="$router.back(-1)">取 消</el-button>
+        <el-button type="primary" @click="showInfoDetailModal = true"
+          >同意并继续</el-button
+        >
+      </span>
+    </el-dialog>
+
     <div id="printTable"></div>
     <div id="printTable"></div>
     <!-- <ToolBar></ToolBar> -->
     <!-- <ToolBar></ToolBar> -->
     <Footer></Footer>
     <Footer></Footer>
@@ -2272,6 +2306,7 @@ export default {
       bgColor: "#ccc",
       bgColor: "#ccc",
       answerTimer: null,
       answerTimer: null,
       recordObj: {},
       recordObj: {},
+      showAgreementModal: false,
       showInfoDetailModal: false,
       showInfoDetailModal: false,
       showStampDetailModail: false,
       showStampDetailModail: false,
       isTaking: true, //是否正在拍照
       isTaking: true, //是否正在拍照
@@ -2594,7 +2629,7 @@ export default {
       };
       };
     },
     },
   },
   },
-  mounted() {
+  async mounted() {
     this.courseId = +this.$route.query.courseId || "";
     this.courseId = +this.$route.query.courseId || "";
     this.nowTime = Number(new Date().getTime() / 1000).toFixed(0);
     this.nowTime = Number(new Date().getTime() / 1000).toFixed(0);
     this.goodsId = this.$route.params.goodsId;
     this.goodsId = this.$route.params.goodsId;
@@ -2602,10 +2637,44 @@ export default {
     this.gradeId = this.$route.query.gradeId;
     this.gradeId = this.$route.query.gradeId;
     this.sectionItem = this.$route.query;
     this.sectionItem = this.$route.query;
 
 
+    let isOther = this.$route.query.isOther || "";
+
+    if (isOther) {
+      const confirmText = [
+        "您的学习账号已经开通,请按照步骤操作,进行学习。",
+        "1.点击【跳转学习网址】按钮",
+        "2.打开学习网址后,选择【个人用户】进行登录",
+        "(1)账号:您个人的身份证号码",
+        "(2)密码:身份证号码,再加111111",
+      ];
+      const newDatas = [];
+      const h = this.$createElement;
+      for (const i in confirmText) {
+        newDatas.push(h("p", null, confirmText[i]));
+      }
+      this.$confirm(h("div", null, newDatas), "温馨提示", {
+        beforeClose: (type) => {
+          if (type == "confirm") {
+            window.open("http://admin.zhujianpeixun.com/", "_blank");
+          } else if (type == "cancel") {
+            this.$router.back(-1);
+          }
+        },
+        confirmButtonText: "跳转学习网址",
+        cancelButtonText: "关闭",
+        closeOnClickModal: false,
+        closeOnPressEscape: false,
+        distinguishCancelAndClose: false,
+        showClose: false,
+      });
+      return;
+    }
+
     if (this.$route.query.rebuild) {
     if (this.$route.query.rebuild) {
       this.courseTabIndex = "2";
       this.courseTabIndex = "2";
     }
     }
 
 
+    await this.getGoodsDetail(); //商品详情
     this.dictList();
     this.dictList();
 
 
     // this.userConfirmInfoDetail().then((res) => {
     // this.userConfirmInfoDetail().then((res) => {
@@ -3696,7 +3765,7 @@ export default {
                                     showClose: false,
                                     showClose: false,
                                   })
                                   })
                                     .then((_) => {
                                     .then((_) => {
-                                      this.showInfoDetailModal = true;
+                                      this.showAgreementModal = true;
                                       this.getInfo();
                                       this.getInfo();
                                     })
                                     })
                                     .catch((_) => {
                                     .catch((_) => {
@@ -4333,7 +4402,6 @@ export default {
         this.historyChatMsgList = [];
         this.historyChatMsgList = [];
         this.nowTime = Number(new Date().getTime() / 1000).toFixed(0);
         this.nowTime = Number(new Date().getTime() / 1000).toFixed(0);
         this.courseDetail(); //课程详情
         this.courseDetail(); //课程详情
-        this.getGoodsDetail(); //商品详情
         this.getAnswerList(); //答疑列表
         this.getAnswerList(); //答疑列表
         this.answerTimer = setInterval(() => {
         this.answerTimer = setInterval(() => {
           this.getAnswerList();
           this.getAnswerList();
@@ -4520,56 +4588,60 @@ export default {
         });
         });
     },
     },
     getGoodsDetail() {
     getGoodsDetail() {
-      let self = this;
-      this.$request.goodsDetail(this.goodsId).then((res) => {
-        self.goodsData = res.data;
-        self.gradeId = self.goodsData.gradeId;
-        if (this.goodsData.categoryName) {
-          this.infoForm.apply_post = this.goodsData.categoryName;
+      return new Promise((resolve) => {
+        let self = this;
+        this.$request.goodsDetail(this.goodsId).then((res) => {
+          self.goodsData = res.data;
+          self.gradeId = self.goodsData.gradeId;
           if (this.goodsData.categoryName) {
           if (this.goodsData.categoryName) {
-            this.apply_post_disabled = true;
-          }
+            this.infoForm.apply_post = this.goodsData.categoryName;
+            if (this.goodsData.categoryName) {
+              this.apply_post_disabled = true;
+            }
 
 
-          if (this.userInfo.companyName) {
-            this.infoForm.work_unit = this.userInfo.companyName;
-          }
-        }
-        if (this.goodsData.buyNote) {
-          this.tabList = [
-            { name: "1", label: "学员须知" },
-            { name: "2", label: "课程答疑" },
-            { name: "3", label: "笔记讲义" },
-          ];
-          console.log(res, "res111");
-          this.getRecommend();
-        } else {
-          this.tabList = [
-            { name: "1", label: "课程答疑" },
-            { name: "2", label: "笔记讲义" },
-          ];
-        }
-        this.courseBusiness();
-        this.courseHandouts();
-        if (self.goodsData.goodsPlayConfig) {
-          self.goodsPlayConfig = JSON.parse(self.goodsData.goodsPlayConfig);
-          if (self.goodsPlayConfig.autoPlay > 0) {
-            self.autoplay = true;
+            if (this.userInfo.companyName) {
+              this.infoForm.work_unit = this.userInfo.companyName;
+            }
           }
           }
-          if (self.goodsPlayConfig.drag > 0) {
-            self.isAllowSeek = "off";
+          if (this.goodsData.buyNote) {
+            this.tabList = [
+              { name: "1", label: "学员须知" },
+              { name: "2", label: "课程答疑" },
+              { name: "3", label: "笔记讲义" },
+            ];
+            console.log(res, "res111");
+            this.getRecommend();
+          } else {
+            this.tabList = [
+              { name: "1", label: "课程答疑" },
+              { name: "2", label: "笔记讲义" },
+            ];
           }
           }
-          if (self.goodsPlayConfig.speed > 0) {
-            self.playbackRate = true;
+          this.courseBusiness();
+          this.courseHandouts();
+          if (self.goodsData.goodsPlayConfig) {
+            self.goodsPlayConfig = JSON.parse(self.goodsData.goodsPlayConfig);
+            if (self.goodsPlayConfig.autoPlay > 0) {
+              self.autoplay = true;
+            }
+            if (self.goodsPlayConfig.drag > 0) {
+              self.isAllowSeek = "off";
+            }
+            if (self.goodsPlayConfig.speed > 0) {
+              self.playbackRate = true;
+            }
           }
           }
-        }
-        if (self.goodsData.goodsPhotographConfig) {
-          self.goodsPhotographConfig = JSON.parse(
-            self.goodsData.goodsPhotographConfig
-          );
-          if (self.goodsPhotographConfig.photoNum > 0) {
-            self.photoNum = self.goodsPhotographConfig.photoNum;
+          if (self.goodsData.goodsPhotographConfig) {
+            self.goodsPhotographConfig = JSON.parse(
+              self.goodsData.goodsPhotographConfig
+            );
+            if (self.goodsPhotographConfig.photoNum > 0) {
+              self.photoNum = self.goodsPhotographConfig.photoNum;
+            }
           }
           }
-        }
+        });
+
+        resolve();
       });
       });
     },
     },
     /**
     /**

+ 1 - 1
src/pages/goods-detail/bank-detail.vue

@@ -19,7 +19,7 @@
               <div class="goods-info__header">
               <div class="goods-info__header">
                 <div class="img">
                 <div class="img">
                   <img
                   <img
-                    :src="$tools.splitImgHost(goodsDetail.coverUrl, true)"
+                    :src="$tools.splitImgHost(goodsDetail.coverUrl, false)"
                     alt=""
                     alt=""
                   />
                   />
                 </div>
                 </div>

+ 9 - 2
src/pages/goods-detail/course-detail.vue

@@ -19,7 +19,7 @@
               <div class="goods-info__header">
               <div class="goods-info__header">
                 <div class="img">
                 <div class="img">
                   <img
                   <img
-                    :src="$tools.splitImgHost(goodsDetail.coverUrl, true)"
+                    :src="$tools.splitImgHost(goodsDetail.coverUrl, false)"
                     alt=""
                     alt=""
                   />
                   />
                 </div>
                 </div>
@@ -380,7 +380,7 @@
       :show-close="false"
       :show-close="false"
     >
     >
       <div class="video-modal__content">
       <div class="video-modal__content">
-        <a class="video-modal__close" @click="videoModalShow = false">X</a>
+        <a class="video-modal__close" @click="videoModalClose()">X</a>
 
 
         <div class="video-modal__header">课程试看</div>
         <div class="video-modal__header">课程试看</div>
         <div class="video-modal__body">
         <div class="video-modal__body">
@@ -570,6 +570,9 @@ export default {
       freeMenuList: [], //赠送题卷列表
       freeMenuList: [], //赠送题卷列表
     };
     };
   },
   },
+  beforeDestroy() {
+    this.player.destroy();
+  },
   mounted() {
   mounted() {
     this.goodsId = this.$route.params.goodsId;
     this.goodsId = this.$route.params.goodsId;
     this.getGoodsDetail();
     this.getGoodsDetail();
@@ -598,6 +601,10 @@ export default {
   },
   },
   methods: {
   methods: {
     ...mapMutations(["setCurrentRouter", "getCartCount"]),
     ...mapMutations(["setCurrentRouter", "getCartCount"]),
+    videoModalClose() {
+      this.videoModalShow = false;
+      this.player.destroy();
+    },
     appCommonGoodsCourseModuleFreeExamList() {
     appCommonGoodsCourseModuleFreeExamList() {
       this.$request
       this.$request
         .appCommonGoodsCourseModuleFreeExamList(this.goodsId)
         .appCommonGoodsCourseModuleFreeExamList(this.goodsId)

+ 1 - 1
src/pages/goods-detail/live-detail.vue

@@ -19,7 +19,7 @@
               <div class="goods-info__header">
               <div class="goods-info__header">
                 <div class="img">
                 <div class="img">
                   <img
                   <img
-                    :src="$tools.splitImgHost(goodsDetail.coverUrl, true)"
+                    :src="$tools.splitImgHost(goodsDetail.coverUrl, false)"
                     alt=""
                     alt=""
                   />
                   />
                 </div>
                 </div>

+ 15 - 11
src/pages/live-detail/index.vue

@@ -22,7 +22,7 @@
                   :style="{
                   :style="{
                     backgroundImage: `url(${$tools.splitImgHost(
                     backgroundImage: `url(${$tools.splitImgHost(
                       goodsData.coverUrl,
                       goodsData.coverUrl,
-                      true
+                      false
                     )})`,
                     )})`,
                   }"
                   }"
                 >
                 >
@@ -223,9 +223,7 @@
                                                   </div>
                                                   </div>
                                                   <div
                                                   <div
                                                     v-if="
                                                     v-if="
-                                                      section.sectionType ==
-                                                        3 &&
-                                                      !section.recordingUrl
+                                                      section.sectionType == 3
                                                     "
                                                     "
                                                     style="
                                                     style="
                                                       font-size: 12px;
                                                       font-size: 12px;
@@ -233,8 +231,12 @@
                                                     "
                                                     "
                                                   >
                                                   >
                                                     <span
                                                     <span
+                                                      v-if="
+                                                        !section.recordingUrl
+                                                      "
                                                       >当前直播回放视频请稍后再查看</span
                                                       >当前直播回放视频请稍后再查看</span
                                                     >
                                                     >
+                                                    <span v-else> 回放中 </span>
                                                   </div>
                                                   </div>
                                                 </div>
                                                 </div>
                                               </template>
                                               </template>
@@ -482,8 +484,7 @@
                                                 </div>
                                                 </div>
                                                 <div
                                                 <div
                                                   v-if="
                                                   v-if="
-                                                    section.sectionType == 3 &&
-                                                    !section.recordingUrl
+                                                    section.sectionType == 3
                                                   "
                                                   "
                                                   style="
                                                   style="
                                                     font-size: 12px;
                                                     font-size: 12px;
@@ -491,8 +492,10 @@
                                                   "
                                                   "
                                                 >
                                                 >
                                                   <span
                                                   <span
+                                                    v-if="!section.recordingUrl"
                                                     >当前直播回放视频请稍后再查看</span
                                                     >当前直播回放视频请稍后再查看</span
                                                   >
                                                   >
+                                                  <span v-else>回放中</span>
                                                 </div>
                                                 </div>
                                               </div>
                                               </div>
 
 
@@ -701,18 +704,16 @@
                                               </div>
                                               </div>
                                             </div>
                                             </div>
                                             <div
                                             <div
-                                              v-if="
-                                                menu.sectionType == 3 &&
-                                                !menu.recordingUrl
-                                              "
+                                              v-if="menu.sectionType == 3"
                                               style="
                                               style="
                                                 font-size: 12px;
                                                 font-size: 12px;
                                                 color: red;
                                                 color: red;
                                               "
                                               "
                                             >
                                             >
-                                              <span
+                                              <span v-if="!menu.recordingUrl"
                                                 >当前直播回放视频请稍后再查看</span
                                                 >当前直播回放视频请稍后再查看</span
                                               >
                                               >
+                                              <span v-else>回放中</span>
                                             </div>
                                             </div>
                                           </div>
                                           </div>
                                         </template>
                                         </template>
@@ -2799,6 +2800,9 @@ export default {
       };
       };
     },
     },
   },
   },
+  beforeDestroy() {
+    this.player.destroy();
+  },
   async mounted() {
   async mounted() {
     this.courseId = +this.$route.query.courseId || "";
     this.courseId = +this.$route.query.courseId || "";
     this.nowTime = Number(new Date().getTime() / 1000).toFixed(0);
     this.nowTime = Number(new Date().getTime() / 1000).toFixed(0);

+ 1 - 1
src/pages/person-center/my-classhour/index/index.vue

@@ -343,7 +343,7 @@ export default {
     this.getcourseperiodlistGoods();
     this.getcourseperiodlistGoods();
   },
   },
   methods: {
   methods: {
-    ...mapActions(["setSystemTime", "setSystemTime"]),
+    ...mapActions(["setSystemTime"]),
     appBeforeAddress(item) {
     appBeforeAddress(item) {
       console.log(this.$refs.exercisesModal);
       console.log(this.$refs.exercisesModal);
       this.$refs.exercisesModal.showModal(item);
       this.$refs.exercisesModal.showModal(item);

+ 8 - 25
src/pages/person-center/my-course/index.vue

@@ -617,31 +617,14 @@ export default {
         if (item.learnStatus == 1) {
         if (item.learnStatus == 1) {
           //跳转第三方h5
           //跳转第三方h5
 
 
-          const confirmText = [
-            "您的学习账号已经开通,请按照步骤操作,进行学习。",
-            "1.点击【跳转学习网址】按钮",
-            "2.打开学习网址后,选择【个人用户】进行登录",
-            "(1)账号:您个人的身份证号码",
-            "(2)密码:身份证号码,再加111111",
-          ];
-          const newDatas = [];
-          const h = this.$createElement;
-          for (const i in confirmText) {
-            newDatas.push(h("p", null, confirmText[i]));
-          }
-          this.$confirm(h("div", null, newDatas), "温馨提示", {
-            confirmButtonText: "跳转学习网址",
-            cancelButtonText: "关闭",
-            closeOnClickModal: false,
-            closeOnPressEscape: false,
-            distinguishCancelAndClose: false,
-            showClose: false,
-          })
-            .then((_) => {
-              window.open("http://admin.zhujianpeixun.com/", "_blank");
-            })
-            .catch((_) => {});
-
+          this.$router.push({
+            path: `/my-course-detail/${item.goodsId}`,
+            query: {
+              gradeId: item.gradeId,
+              orderGoodsId: item.orderGoodsId,
+              isOther: 1,
+            },
+          });
           return;
           return;
         } else {
         } else {
           this.$message({
           this.$message({

+ 4 - 1
src/pages/person-center/my-order/index.vue

@@ -65,7 +65,10 @@
                       (item.orderStatus === 1 ||
                       (item.orderStatus === 1 ||
                         item.orderStatus === 2 ||
                         item.orderStatus === 2 ||
                         item.orderStatus === 3) &&
                         item.orderStatus === 3) &&
-                      (items.goodsType == '1' || items.goodsType == '2')
+                      (items.goodsType == '1' ||
+                        items.goodsType == '2' ||
+                        items.goodsType == '6') &&
+                      items.goodsPrice > 0
                     "
                     "
                   >
                   >
                     申请退款
                     申请退款