谢杰标 пре 3 година
родитељ
комит
47e8c7a01f

+ 43 - 134
src/components/rebuildModal/index.vue

@@ -1,17 +1,18 @@
 <template>
   <div id="rebuild-modal">
     <el-dialog
-      width="800px"
+      width="680px"
       class="rebuild"
       :visible.sync="showRebuildDetailModal"
       :close-on-click-modal="false"
       :close-on-press-escape="false"
+      append-to-body
       :show-close="false"
     >
       <div class="rebuild__content">
-        <div class="rebuild__close" @click="showRebuildDetailModal = false">
+        <!-- <div class="rebuild__close" @click="showRebuildDetailModal = false">
           X
-        </div>
+        </div> -->
         <div class="rebuild__header">审核详情</div>
         <div class="rebuild__body">
           <div class="content">
@@ -30,36 +31,12 @@
                   :key="index"
                 >
                   <div class="title">
-                    <span class="note" v-if="item.type == 0"> 测试 </span>
-                    <span class="note note--yellow" v-if="item.type == 1"
-                      >视频</span
-                    >
-                    <span class="note note--yellow" v-if="item.type == 2"
-                      >直播</span
-                    >
-                    <span class="note note--yellow" v-if="item.type == 3"
-                      >回放</span
-                    >
-                    {{ index + 1 }}、{{ item.name }}
-                  </div>
-                  <div class="desc">
-                    <!-- <div class="imgs">
-                      <div
-                        class="img"
-                        v-for="(items, indexs) in item.userStudyRecordPhoto"
-                        :key="indexs"
-                      >
-                        <img :src="$tools.splitImgHost(items.photo)" />
-                        <div class="note">
-                          {{ $tools.timestampToTime(items.createTime, false) }}
-                        </div>
-                      </div>
-                    </div> -->
-                  </div>
-                  <div class="desc">
-                    原因:
-                    <span class="note">{{ item.auditReason }}</span>
+                    <span class="note">{{
+                      ["测试", "视频", "直播", "回放"][item.type]
+                    }}</span>
+                    <span class="title-name">{{ item.name }}</span>
                   </div>
+                  <div class="desc">原因:{{ item.auditReason }}</div>
                 </div>
               </div>
             </div>
@@ -86,7 +63,7 @@ export default {
     return {
       showRebuildDetailModal: false,
       rebuildItem: {},
-      rebuildItems: {},
+      rebuildItems: [],
       rebuildShow: false,
     };
   },
@@ -107,17 +84,15 @@ export default {
           let sysTime = this.$tools.timest();
           //学习服务期没过
           if (item.serviceEndTime && item.serviceEndTime > +sysTime) {
-            console.log(1);
             this.rebuildShow = true;
           } else {
             //已过学习服务期
-            console.log(2);
+
             this.rebuildShow = false;
             this.showRebuildDetailModal = true;
             return;
           }
-          console.log(item.classEndTime, "item.classEndTime");
-          console.log(sysTime, "sysTime");
+
           //有班级有效期
           if (item.classEndTime) {
             //班级有效期没过
@@ -147,45 +122,7 @@ export default {
         .then((res) => {
           this.showRebuildDetailModal = false;
           this.$emit("rebuildSubmit", this.rebuildItem);
-          // this.$router.push({
-          //   path: `/my-course-detail/${this.rebuildItem.goodsId}`,
-          //   query: {
-          //     gradeId: this.rebuildItem.gradeId,
-          //     orderGoodsId: this.rebuildItem.orderGoodsId,
-          //   },
-          // });
         });
-      // this.$confirm(
-      //   "如对审核结果有异议,请勿点击确认重学。致电020-87085982咨询",
-      //   "注意",
-      //   {
-      //     confirmButtonText: "确认重学",
-      //     cancelButtonText: "取消",
-      //     closeOnClickModal: false,
-      //     closeOnPressEscape: false,
-      //     distinguishCancelAndClose: false,
-      //     showClose: false,
-      //   }
-      // )
-      //   .then((_) => {
-      //     this.$request
-      //       .courseperiodrebuild({
-      //         goodsId: this.rebuildItem.goodsId,
-      //         gradeId: this.rebuildItem.gradeId,
-      //       })
-      //       .then((res) => {
-      //         this.showRebuildDetailModal = false;
-      //         this.$emit("rebuildSubmit", this.rebuildItem);
-      //         // this.$router.push({
-      //         //   path: `/my-course-detail/${this.rebuildItem.goodsId}`,
-      //         //   query: {
-      //         //     gradeId: this.rebuildItem.gradeId,
-      //         //     orderGoodsId: this.rebuildItem.orderGoodsId,
-      //         //   },
-      //         // });
-      //       });
-      //   })
-      //   .catch((_) => {});
     },
   },
 };
@@ -217,18 +154,17 @@ export default {
   }
 
   &__header {
-    height: 40px;
-    border-bottom: 1px solid #eee;
-    line-height: 40px;
-    font-size: 16px;
+    line-height: 76px;
+    font-size: 20px;
     font-family: Microsoft YaHei;
     font-weight: bold;
-    color: #333333;
+    color: #222222;
     padding-left: 24px;
+    text-align: center;
   }
 
   &__body {
-    height: 400px;
+    height: 300px;
     padding: 0 24px;
 
     .content {
@@ -236,24 +172,21 @@ export default {
       overflow-y: auto;
 
       &__header {
-        padding: 16px 0;
-        border-bottom: 1px solid #eee;
-
+        background: #f8f8f8;
+        border-radius: 8px;
+        padding: 24px;
+        color: #eb445a;
+        margin-bottom: 26px;
         .title {
-          font-size: 16px;
+          font-size: 18px;
           font-family: Microsoft YaHei;
-          font-weight: bold;
-          color: #ff3b30;
-          line-height: 24px;
         }
 
         .desc {
-          margin-top: 10px;
+          margin-top: 6px;
           font-size: 16px;
           font-family: Microsoft YaHei;
           font-weight: 400;
-          color: #ff3b30;
-          line-height: 24px;
         }
       }
 
@@ -261,55 +194,32 @@ export default {
         .list {
           &__item {
             padding: 16px 0;
-            border-bottom: 1px solid #eee;
-
             .title {
-              font-size: 14px;
-              font-family: Microsoft YaHei;
-              font-weight: 400;
-              color: #333333;
-
+              display: flex;
+              align-items: center;
               .note {
-                display: inline-block;
                 text-align: center;
-                line-height: 18px;
                 width: 32px;
-                height: 20px;
+                height: 18px;
                 border: 1px solid #3f8dfd;
-                border-radius: 4px;
-                color: #3f8dfd;
+                background: #3f8dfd;
+                color: #ffffff;
                 font-size: 12px;
-
-                &--yellow {
-                  border: 1px solid #ff9500;
-                  color: #ff9500;
-                }
+                border-radius: 6px 3px 6px 3px;
+              }
+              .title-name {
+                padding-left: 8px;
+                color: #222222;
+                font-size: 18px;
               }
             }
 
             .desc {
-              margin-top: 10px;
+              margin-top: 6px;
               font-size: 14px;
               font-family: Microsoft YaHei;
               font-weight: 400;
-              color: #333333;
-
-              .note {
-                color: #ff3b30;
-                line-height: 20px;
-              }
-
-              .img {
-                width: 100px;
-                height: 100px;
-                display: inline-block;
-                text-align: center;
-
-                img {
-                  max-width: 100%;
-                  max-height: 100%;
-                }
-              }
+              color: #606266;
             }
           }
         }
@@ -318,18 +228,17 @@ export default {
   }
 
   &__footer {
-    height: 90px;
-    border-top: 1px solid #eee;
     text-align: center;
-    .confirm {
-      width: 200px;
-      height: 40px;
+    .el-button {
+      width: 260px;
+      height: 44px;
       padding: 0;
       border-radius: 20px;
       text-align: center;
-      line-height: 40px;
+      line-height: 44px;
       color: #fff;
-      margin: 24px auto;
+      margin: 34px auto;
+      font-size: 16px;
     }
   }
 }

+ 180 - 0
src/pages/person-center/learn-center/goodsList.vue

@@ -0,0 +1,180 @@
+<template>
+  <div class="learn-main">
+    <div class="course-classify">
+      <div class="course-classify__list">
+        <div class="left-item">教育类型:</div>
+        <div class="right-item">
+          <div class="list">
+            <div
+              class="item"
+              v-for="(item, index) in typeList"
+              :key="index"
+              :class="{ active: params.educationTypeId == item.id }"
+              @click="changeType(item)"
+            >
+              {{ item.educationName }}
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="course-classify__list" v-if="businessList.length > 0">
+        <div class="left-item">培训项目:</div>
+        <div class="right-item">
+          <div class="list">
+            <!-- <div class="item active">全部</div> -->
+            <div
+              class="item"
+              v-for="(item, index) in businessList"
+              :key="index"
+              :class="{ active: params.businessId == item.id }"
+              @click="changeBusiness(item)"
+            >
+              {{ item.aliasName }}
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+    <el-tabs v-model="params.type" @tab-click="handleClick">
+      <el-tab-pane
+        v-for="tab in tabList"
+        :key="tab.lable"
+        :label="tab.lable"
+        :name="tab.name"
+      >
+        <template v-if="tab.name == '888'">
+          <div
+            class="goods-box"
+            v-for="tab in tabList.slice(1)"
+            :key="tab.lable"
+          >
+            <h3>{{ tab.lable }}</h3>
+            <List-box :list="courseList"></List-box>
+          </div>
+        </template>
+        <List-box v-else></List-box>
+      </el-tab-pane>
+    </el-tabs>
+  </div>
+</template>
+
+<script>
+import ListBox from "./ListBox.vue";
+export default {
+  data() {
+    return {
+      typeList: [],
+      businessList: [],
+      params: { businessId: "", educationTypeId: "", type: "888" },
+      tabList: [
+        { lable: "全部", name: "888" },
+        { lable: "视频", name: "1" },
+        { lable: "直播", name: "2" },
+        { lable: "题库", name: "6" },
+      ],
+      dataList: [],
+      courseList: [],
+    };
+  },
+  methods: {
+    handleClick() {
+      console.log(this.params.type);
+    },
+    changeType(item) {
+      if (this.params.educationTypeId == item.id) {
+        return;
+      }
+      this.params.educationTypeId = item.id;
+      this.params.businessId = "";
+      this.businessList = [];
+      this.getBusinessList();
+    },
+    getEducationTypeList() {
+      this.$request.educationTypeList().then((res) => {
+        this.typeList = res.rows;
+        this.params.educationTypeId = res.rows[0].id;
+        this.getBusinessList();
+      });
+    },
+    getBusinessList() {
+      this.$request
+        .businessList({ educationId: this.params.educationTypeId })
+        .then((res) => {
+          this.businessList = res.rows.filter((item) => item.aliasName);
+          this.params.businessId = this.businessList[0].id;
+        });
+    },
+    changeBusiness(item) {
+      if (this.params.businessId == item.id) {
+        return;
+      }
+      this.params.businessId = item.id;
+    },
+    courseGoodsList() {
+      this.$request
+        .courseGoodsList({ pageNum: 1, pageSize: 10 })
+        .then((res) => {
+          this.courseList = res.rows;
+        });
+    },
+  },
+  created() {
+    this.getEducationTypeList();
+    this.courseGoodsList()
+  },
+  components: {
+    ListBox,
+  },
+};
+</script>
+
+<style scoped lang="scss">
+.learn-main {
+  .course-classify {
+    margin: 20px 0 16px;
+    padding: 20px 20px 0;
+    overflow: hidden;
+    background: #f8f8fc;
+    &__list {
+      padding-bottom: 20px;
+      display: flex;
+      .left-item {
+        padding-top: 4px;
+        width: 80px;
+        font-size: 13px;
+        color: #333333;
+      }
+
+      .right-item {
+        flex: 1;
+        .list {
+          display: flex;
+          flex-wrap: wrap;
+          .item {
+            cursor: pointer;
+            border-radius: 2px;
+            // margin: 10px;
+            padding: 4px 8px;
+            color: #666666;
+            font-size: 13px;
+            background: #f7f9fc;
+            color: #999;
+
+            &.active {
+              color: #3f8dfd;
+              background: #ebf2ff;
+            }
+          }
+        }
+      }
+    }
+  }
+  .goods-box {
+    h3 {
+      font-size: 14px;
+      color: #222222;
+      margin-bottom: 18px;
+    }
+  }
+}
+</style>

+ 9 - 172
src/pages/person-center/learn-center/index.vue

@@ -1,180 +1,17 @@
 <template>
-  <div class="learn-main">
-    <div class="course-classify">
-      <div class="course-classify__list">
-        <div class="left-item">教育类型:</div>
-        <div class="right-item">
-          <div class="list">
-            <div
-              class="item"
-              v-for="(item, index) in typeList"
-              :key="index"
-              :class="{ active: params.educationTypeId == item.id }"
-              @click="changeType(item)"
-            >
-              {{ item.educationName }}
-            </div>
-          </div>
-        </div>
-      </div>
-      <div class="course-classify__list" v-if="businessList.length > 0">
-        <div class="left-item">培训项目:</div>
-        <div class="right-item">
-          <div class="list">
-            <!-- <div class="item active">全部</div> -->
-            <div
-              class="item"
-              v-for="(item, index) in businessList"
-              :key="index"
-              :class="{ active: params.businessId == item.id }"
-              @click="changeBusiness(item)"
-            >
-              {{ item.aliasName }}
-            </div>
-          </div>
-        </div>
-      </div>
-    </div>
-    <el-tabs v-model="params.type" @tab-click="handleClick">
-      <el-tab-pane
-        v-for="tab in tabList"
-        :key="tab.lable"
-        :label="tab.lable"
-        :name="tab.name"
-      >
-        <template v-if="tab.name == '888'">
-          <div
-            class="goods-box"
-            v-for="tab in tabList.slice(1)"
-            :key="tab.lable"
-          >
-            <h3>{{ tab.lable }}</h3>
-            <List-box :list="courseList"></List-box>
-          </div>
-        </template>
-        <List-box v-else></List-box>
-      </el-tab-pane>
-    </el-tabs>
+  <div>
+    <router-link to="/person-center/my-bank">
+      <div class="item">开始做题</div>
+    </router-link>
+    <router-link to="/person-center/my-info">
+      <div class="item">个人信息</div> </router-link
+    ><router-view></router-view>
   </div>
 </template>
 
 <script>
-import ListBox from "./ListBox.vue";
-export default {
-  data() {
-    return {
-      typeList: [],
-      businessList: [],
-      params: { businessId: "", educationTypeId: "", type: "888" },
-      tabList: [
-        { lable: "全部", name: "888" },
-        { lable: "视频", name: "1" },
-        { lable: "直播", name: "2" },
-        { lable: "题库", name: "6" },
-      ],
-      dataList: [],
-      courseList: [],
-    };
-  },
-  methods: {
-    handleClick() {
-      console.log(this.params.type);
-    },
-    changeType(item) {
-      if (this.params.educationTypeId == item.id) {
-        return;
-      }
-      this.params.educationTypeId = item.id;
-      this.params.businessId = "";
-      this.businessList = [];
-      this.getBusinessList();
-    },
-    getEducationTypeList() {
-      this.$request.educationTypeList().then((res) => {
-        this.typeList = res.rows;
-        this.params.educationTypeId = res.rows[0].id;
-        this.getBusinessList();
-      });
-    },
-    getBusinessList() {
-      this.$request
-        .businessList({ educationId: this.params.educationTypeId })
-        .then((res) => {
-          this.businessList = res.rows.filter((item) => item.aliasName);
-          this.params.businessId = this.businessList[0].id;
-        });
-    },
-    changeBusiness(item) {
-      if (this.params.businessId == item.id) {
-        return;
-      }
-      this.params.businessId = item.id;
-    },
-    courseGoodsList() {
-      this.$request
-        .courseGoodsList({ pageNum: 1, pageSize: 10 })
-        .then((res) => {
-          this.courseList = res.rows;
-        });
-    },
-  },
-  created() {
-    this.getEducationTypeList();
-    this.courseGoodsList()
-  },
-  components: {
-    ListBox,
-  },
-};
+export default {};
 </script>
 
-<style scoped lang="scss">
-.learn-main {
-  .course-classify {
-    margin: 20px 0 16px;
-    padding: 20px 20px 0;
-    overflow: hidden;
-    background: #f8f8fc;
-    &__list {
-      padding-bottom: 20px;
-      display: flex;
-      .left-item {
-        padding-top: 4px;
-        width: 80px;
-        font-size: 13px;
-        color: #333333;
-      }
-
-      .right-item {
-        flex: 1;
-        .list {
-          display: flex;
-          flex-wrap: wrap;
-          .item {
-            cursor: pointer;
-            border-radius: 2px;
-            // margin: 10px;
-            padding: 4px 8px;
-            color: #666666;
-            font-size: 13px;
-            background: #f7f9fc;
-            color: #999;
-
-            &.active {
-              color: #3f8dfd;
-              background: #ebf2ff;
-            }
-          }
-        }
-      }
-    }
-  }
-  .goods-box {
-    h3 {
-      font-size: 14px;
-      color: #222222;
-      margin-bottom: 18px;
-    }
-  }
-}
+<style>
 </style>