ソースを参照

Merge branch 'dev' of http://git.dayaedu.com/huangqiyong/classroom

黄琪勇 1 年間 前
コミット
de39c8350f
66 ファイル変更343 行追加133 行削除
  1. 4 3
      src/assets/elementTheme.scss
  2. 1 0
      src/assets/normalize.css
  3. 4 3
      src/components/dictionary/dictionary.vue
  4. 3 7
      src/components/ellipsisScroll/ellipsisScroll.vue
  5. 2 0
      src/global.d.ts
  6. 5 0
      src/hooks/useDialogConfirm/dialogConfirm.vue
  7. BIN
      src/img/cloudTextbooks/bf.png
  8. BIN
      src/img/cloudTextbooks/bg.png
  9. BIN
      src/img/cloudTextbooks/jy.png
  10. BIN
      src/img/cloudTextbooks/left.png
  11. BIN
      src/img/cloudTextbooks/right.png
  12. BIN
      src/img/cloudTextbooks/shu.png
  13. BIN
      src/img/cloudTextbooks/sj.png
  14. BIN
      src/img/cloudTextbooks/ss.png
  15. BIN
      src/img/cloudTextbooks/xm.png
  16. BIN
      src/img/homePage/back.png
  17. BIN
      src/img/homePage/bg.png
  18. BIN
      src/img/homePage/home.png
  19. BIN
      src/img/homePage/jdcp.png
  20. BIN
      src/img/homePage/jdzc.png
  21. BIN
      src/img/homePage/kb.png
  22. BIN
      src/img/homePage/ts.png
  23. BIN
      src/img/homePage/xl.png
  24. BIN
      src/img/homePage/xltj.png
  25. BIN
      src/img/homePage/yjc.png
  26. BIN
      src/img/homePage/yjl.png
  27. BIN
      src/img/layout/empty.png
  28. BIN
      src/img/layout/empty1.png
  29. BIN
      src/img/layout/horn.png
  30. BIN
      src/img/layout/logout.png
  31. BIN
      src/img/loginErr/404.png
  32. BIN
      src/img/loginErr/bStar.png
  33. BIN
      src/img/loginErr/bg.png
  34. BIN
      src/img/loginErr/border.png
  35. BIN
      src/img/loginErr/btn.png
  36. BIN
      src/img/loginErr/jiantou1.png
  37. BIN
      src/img/loginErr/jiantou2.png
  38. BIN
      src/img/loginErr/loginBox.png
  39. BIN
      src/img/loginErr/music.png
  40. BIN
      src/img/loginErr/scanned.png
  41. BIN
      src/img/loginErr/star.png
  42. BIN
      src/img/loginErr/xiaoren.png
  43. BIN
      src/img/loginErr/yun.png
  44. BIN
      src/img/useDialogConfirm/cancel.png
  45. BIN
      src/img/useDialogConfirm/close.png
  46. BIN
      src/img/useDialogConfirm/ok.png
  47. 2 2
      src/libs/axios.ts
  48. 9 0
      src/libs/rem.ts
  49. 1 0
      src/main.ts
  50. 3 0
      src/registerComponents.ts
  51. 7 0
      src/views/cloudTextbooks/chooseDialog.vue
  52. 57 21
      src/views/cloudTextbooks/cloudTextbooks.vue
  53. 2 0
      src/views/coursewarePlay/component/point.module.scss
  54. 16 5
      src/views/coursewarePlay/component/video-item/index.module.scss
  55. 17 11
      src/views/coursewarePlay/component/video-item/index.tsx
  56. BIN
      src/views/coursewarePlay/image/iconLoop.png
  57. BIN
      src/views/coursewarePlay/image/iconLoopActive.png
  58. BIN
      src/views/coursewarePlay/image/iconPause.png
  59. BIN
      src/views/coursewarePlay/image/iconPlay.png
  60. BIN
      src/views/coursewarePlay/image/iconSpeed.png
  61. 3 0
      src/views/homePage/components/navContainer/navContainer.vue
  62. 53 30
      src/views/homePage/homePage_gym.vue
  63. 53 29
      src/views/homePage/homePage_gyt.vue
  64. 54 9
      src/viewsframe/errorPage/errorPage.vue
  65. 15 5
      src/viewsframe/layout/layout.vue
  66. 32 8
      src/viewsframe/login/login.vue

+ 4 - 3
src/assets/elementTheme.scss

@@ -22,7 +22,7 @@
 
 .el-empty .el-empty__description p {
    font-weight: 400;
-   font-size: 22px;
+   font-size: 2.2rem;
    color: #aaaaaa;
 }
 
@@ -35,7 +35,9 @@
       background-color: transparent;
    }
    .el-cascader-menu:last-child .el-cascader-node {
-      padding: 0 8px;
+      padding: 0 12px;
+      line-height: 40px;
+      height: 40px;
    }
    .el-cascader-node__prefix {
       display: none;
@@ -45,7 +47,6 @@
    }
    .el-cascader-node__label {
       font-size: 16px;
-      line-height: 40px;
       border-radius: 8px;
       &:hover {
          color: #994d1c;

+ 1 - 0
src/assets/normalize.css

@@ -15,6 +15,7 @@ body {
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    font-family: PingFang SC, Helvetica Neue, Helvetica, Hiragino Sans GB, Microsoft YaHei, Arial, sans-serif;
+   font-size: 16px;
 }
 
 a:focus,

+ 4 - 3
src/components/dictionary/dictionary.vue

@@ -10,11 +10,11 @@
       :disabled="props.disabled"
       :size="props.size"
       :show-all-levels="false"
-      filterable
       :options="props.options"
       :props="propsOpt"
       :clearable="props.clearable"
       :placeholder="placeholder"
+      :popperClass="popperClass"
    />
 </template>
 
@@ -34,6 +34,7 @@ const props = withDefaults(
       disabled?: boolean
       size?: "default" | "small" | "large"
       placeholder?: string
+      popperClass?: string
    }>(),
    {
       clearable: true,
@@ -43,8 +44,8 @@ const props = withDefaults(
    }
 )
 const emits = defineEmits<{
-   (e: "update:modelValue", value: CascaderValue): void
-   (e: "change", value: CascaderValue): void
+   (e: "update:modelValue", value?: CascaderValue): void
+   (e: "change", value?: CascaderValue): void
 }>()
 
 const propsOpt: CascaderProps = {

+ 3 - 7
src/components/ellipsisScroll/ellipsisScroll.vue

@@ -4,10 +4,8 @@
 * @Date:2024-03-25 11:50:36
 -->
 <template>
-   <div class="xx">
-      <div ref="ellipsisScrollDom" :class="{ isScroll: isScroll }" class="ellipsisScroll">
-         {{ props.title }}
-      </div>
+   <div ref="ellipsisScrollDom" :class="{ isScroll: isScroll }" class="ellipsisScroll">
+      {{ props.title }}
    </div>
 </template>
 
@@ -31,7 +29,6 @@ onUnmounted(() => {
 })
 
 let widthCalc = 0
-
 function handleIsScroll(e: MouseEvent) {
    const target = e.target as HTMLElement
    widthCalc = target.scrollWidth - target.clientWidth
@@ -56,7 +53,6 @@ function handleLeaveScroll() {
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
-   line-height: 16px;
    &.isScroll {
       &:hover {
          width: auto;
@@ -68,7 +64,7 @@ function handleLeaveScroll() {
             transform: translateX(0);
          }
          100% {
-            transform: translateX(-clac(100% - v-bind(widthCalc + "px")));
+            transform: translateX(-100%);
          }
       }
    }

+ 2 - 0
src/global.d.ts

@@ -4,6 +4,7 @@ import dictionary from "@/components/dictionary"
 import tooltipAutoShow from "@/components/tooltipAutoShow"
 import split from "@/components/split"
 import ellipsis from "@/components/ellipsis"
+import ellipsisScroll from "@/components/ellipsisScroll"
 
 /** 全局组件 */
 declare module "vue" {
@@ -14,5 +15,6 @@ declare module "vue" {
       tooltipAutoShow: typeof tooltipAutoShow
       split: typeof split
       ellipsis: typeof ellipsis
+      ellipsisScroll: typeof ellipsisScroll
    }
 }

+ 5 - 0
src/hooks/useDialogConfirm/dialogConfirm.vue

@@ -65,12 +65,15 @@ function ok() {
       height: 44px;
       cursor: pointer;
       background: url("@/img/useDialogConfirm/close.png") no-repeat;
+      background-size: cover;
       &:hover {
          background: url("@/img/useDialogConfirm/closeHover.png") no-repeat;
          background-size: cover;
       }
    }
    .headImg {
+      width: 163px;
+      height: 51px;
       position: absolute;
       left: 50%;
       top: -13px;
@@ -95,6 +98,8 @@ function ok() {
       justify-content: center;
       margin-top: 6px;
       > img {
+         width: 170px;
+         height: 51px;
          cursor: pointer;
          margin-left: 12px;
          &:hover {

BIN
src/img/cloudTextbooks/bf.png


BIN
src/img/cloudTextbooks/bg.png


BIN
src/img/cloudTextbooks/jy.png


BIN
src/img/cloudTextbooks/left.png


BIN
src/img/cloudTextbooks/right.png


BIN
src/img/cloudTextbooks/shu.png


BIN
src/img/cloudTextbooks/sj.png


BIN
src/img/cloudTextbooks/ss.png


BIN
src/img/cloudTextbooks/xm.png


BIN
src/img/homePage/back.png


BIN
src/img/homePage/bg.png


BIN
src/img/homePage/home.png


BIN
src/img/homePage/jdcp.png


BIN
src/img/homePage/jdzc.png


BIN
src/img/homePage/kb.png


BIN
src/img/homePage/ts.png


BIN
src/img/homePage/xl.png


BIN
src/img/homePage/xltj.png


BIN
src/img/homePage/yjc.png


BIN
src/img/homePage/yjl.png


BIN
src/img/layout/empty.png


BIN
src/img/layout/empty1.png


BIN
src/img/layout/horn.png


BIN
src/img/layout/logout.png


BIN
src/img/loginErr/404.png


BIN
src/img/loginErr/bStar.png


BIN
src/img/loginErr/bg.png


BIN
src/img/loginErr/border.png


BIN
src/img/loginErr/btn.png


BIN
src/img/loginErr/jiantou1.png


BIN
src/img/loginErr/jiantou2.png


BIN
src/img/loginErr/loginBox.png


BIN
src/img/loginErr/music.png


BIN
src/img/loginErr/scanned.png


BIN
src/img/loginErr/star.png


BIN
src/img/loginErr/xiaoren.png


BIN
src/img/loginErr/yun.png


BIN
src/img/useDialogConfirm/cancel.png


BIN
src/img/useDialogConfirm/close.png


BIN
src/img/useDialogConfirm/ok.png


+ 2 - 2
src/libs/axios.ts

@@ -41,7 +41,7 @@ class HttpAsynAxios {
             Nprogress.done()
             const rejectData: apiResDataType = {
                code: 500,
-               message: "系统运行异常,请联系管理员处理",
+               message: "系统运行异常,请刷新页面",
                data: null
             }
             return Promise.reject(rejectData)
@@ -76,7 +76,7 @@ class HttpAsynAxios {
             // }
             const rejectData: apiResDataType = {
                code: 500,
-               message: "系统运行异常,请联系管理员处理",
+               message: "系统运行异常,请刷新页面",
                data: null
             }
             return Promise.reject(rejectData) // 返回接口返回的错误信息

+ 9 - 0
src/libs/rem.ts

@@ -0,0 +1,9 @@
+const baseWidth = 1920 // 设计图宽度
+const baseSize = 10 //  rem 比例
+const doc = document.documentElement
+function refreshRem() {
+   const width = doc.getBoundingClientRect().width
+   doc.style.fontSize = baseSize * Math.min(width / baseWidth, 1) + "px"
+}
+refreshRem()
+window.addEventListener("resize", refreshRem)

+ 1 - 0
src/main.ts

@@ -1,5 +1,6 @@
 import { createApp } from "vue"
 import App from "./App.vue"
+import "@/libs/rem"
 
 import "./assets/normalize.css" //初始化css
 import "./assets/index.scss" //全局样式

+ 3 - 0
src/registerComponents.ts

@@ -7,6 +7,7 @@ import dictionary from "@/components/dictionary"
 import tooltipAutoShow from "@/components/tooltipAutoShow"
 import split from "@/components/split"
 import ellipsis from "@/components/ellipsis"
+import ellipsisScroll from "@/components/ellipsisScroll"
 
 export default (app: App<Element>) => {
    //element
@@ -21,4 +22,6 @@ export default (app: App<Element>) => {
    app.component("split", split)
    //ellipsis
    app.component("ellipsis", ellipsis)
+   //ellipsisScroll
+   app.component("ellipsisScroll", ellipsisScroll)
 }

+ 7 - 0
src/views/cloudTextbooks/chooseDialog.vue

@@ -81,6 +81,7 @@ function handlePaly(id: string) {
       height: 44px;
       cursor: pointer;
       background: url("@/img/useDialogConfirm/close.png") no-repeat;
+      background-size: cover;
       &:hover {
          background: url("@/img/useDialogConfirm/closeHover.png") no-repeat;
          background-size: cover;
@@ -92,6 +93,8 @@ function handlePaly(id: string) {
       display: flex;
       position: relative;
       .imgMid {
+         width: 68px;
+         height: 518px;
          position: absolute;
          left: 50%;
          top: 50%;
@@ -141,6 +144,10 @@ function handlePaly(id: string) {
             &:hover {
                background-color: #edeff0;
             }
+            > img {
+               width: 13px;
+               height: 21px;
+            }
          }
          .chooseList {
             width: 100%;

+ 57 - 21
src/views/cloudTextbooks/cloudTextbooks.vue

@@ -8,7 +8,14 @@
       <div class="cloudTextbooks">
          <div class="headCon">
             <div class="operate">
-               <dictionary class="classTypes" v-model="classType" :options="classTypeOpt" placeholder="课程类型" @change="handleQuery" />
+               <dictionary
+                  class="classTypes"
+                  :popperClass="'classTypeOpt'"
+                  v-model="classType"
+                  :options="classTypeOpt"
+                  placeholder="课程类型"
+                  @change="handleQuery"
+               />
                <el-input
                   @keyup.enter="handleQuery"
                   @input="handleInputQuery"
@@ -22,7 +29,7 @@
                   :class="{ isInputFocus: isInputFocus }"
                >
                   <template #prepend>
-                     <img src="@/img/cloudTextbooks/ss.png" />
+                     <img class="imgSs" src="@/img/cloudTextbooks/ss.png" />
                   </template>
                   <template #append>
                      <div class="btnSelect" @click="handleQuery">搜索</div>
@@ -121,21 +128,33 @@ function handleGetClassTypeOpt() {
    if (userStoreHook.roles === "GYM") {
       httpAjax(getLessonCoursewareSubjectList_gym).then(res => {
          if (res.code === 200) {
-            classTypeOpt.value = res.data.map((item: any) => {
-               return {
-                  value: item.id,
-                  label: item.name
-               }
-            })
+            classTypeOpt.value = [
+               {
+                  value: "",
+                  label: "全部"
+               },
+               ...res.data.map((item: any) => {
+                  return {
+                     value: item.id,
+                     label: item.name
+                  }
+               })
+            ]
          }
       })
    } else {
-      classTypeOpt.value = Object.keys(courseEmnu).map(type => {
-         return {
-            value: type,
-            label: courseEmnu[type as keyof typeof courseEmnu]
-         }
-      })
+      classTypeOpt.value = [
+         {
+            value: "",
+            label: "全部"
+         },
+         ...Object.keys(courseEmnu).map(type => {
+            return {
+               value: type,
+               label: courseEmnu[type as keyof typeof courseEmnu]
+            }
+         })
+      ]
    }
 }
 
@@ -167,7 +186,7 @@ function handleClick(id: string) {
    height: 100%;
    position: relative;
    .headCon {
-      padding: 40px 26px;
+      padding: 30px 26px;
       display: flex;
       flex-direction: row-reverse;
       .operate {
@@ -226,6 +245,10 @@ function handleClick(id: string) {
                   --el-input-inner-height: 40px;
                }
             }
+            .imgSs {
+               width: 20px;
+               height: 20px;
+            }
             .btnSelect {
                width: 70px;
                height: 36px;
@@ -259,8 +282,8 @@ function handleClick(id: string) {
          display: flex;
          flex-direction: column;
          align-items: center;
-         min-width: 1500px;
          padding-top: 10px;
+         min-width: 1240px;
          .bookshelf {
             width: 1500px;
             padding: 0 116px;
@@ -337,6 +360,21 @@ function handleClick(id: string) {
                }
             }
          }
+         @media screen and (max-width: 1600px) {
+            .bookshelf {
+               width: 1400px;
+            }
+         }
+         @media screen and (max-width: 1500px) {
+            .bookshelf {
+               width: 1300px;
+            }
+         }
+         @media screen and (max-width: 1400px) {
+            .bookshelf {
+               width: 1200px;
+            }
+         }
       }
    }
    .empty {
@@ -346,10 +384,8 @@ function handleClick(id: string) {
       transform: translate(-50%, -50%);
    }
 }
-:global(.headDropdown.el-dropdown__popper.el-popper) {
-   box-shadow: 0px 2px 17px 0px rgba(0, 0, 0, 0.08);
-   background: #ffffff;
-   border-radius: 16px;
-   inset: 84px 54px auto auto !important;
+:global(.classTypeOpt.el-popper .el-cascader-menu) {
+   width: 150px;
+   min-width: auto;
 }
 </style>

+ 2 - 0
src/views/coursewarePlay/component/point.module.scss

@@ -46,6 +46,7 @@
    }
    :global {
       .van-cell {
+         cursor: pointer;
          background: transparent;
          font-size: 16px;
          color: rgba(255, 255, 255, 0.5);
@@ -80,6 +81,7 @@
       border-top: 0;
       :global {
          .van-cell {
+            cursor: pointer;
             padding-left: 0;
             font-size: 16px;
          }

+ 16 - 5
src/views/coursewarePlay/component/video-item/index.module.scss

@@ -74,9 +74,10 @@
       }
 
       .actionBtn {
+         cursor: pointer;
          display: flex;
-         width: 36px;
-         height: 36px;
+         width: 44px;
+         height: 44px;
          padding: 0 0;
          background: transparent;
          margin-right: 30px;
@@ -169,12 +170,12 @@
 .sliderPopup {
    position: absolute;
    z-index: 9999;
-   left: 149px;
+   left: 168px;
    bottom: 48px;
    display: flex;
    align-items: center;
    flex-direction: column;
-   height: 165px;
+   height: 172px;
    width: 45px;
    padding: 10px 0 15px;
    background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFoAAAGaCAMAAAC46aQwAAAAOVBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAC8dlA9AAAAE3RSTlNaAAxUVwdPRSc7MzYsEEoXGgshjXaABwAAAZBJREFUeNrt1GtO40AQReF77X46tvPY/2IHhiCDA0Ez7pb4cb4FHLVaVSU/isM/i360S5+nnIL+Q0h5On+fXuqoQ8a6fJm+VjVQr4/pEtREKPt0VTP1UzpmNZTjh3RWU3lLn9TY6T1d1Fx5S8eg5kL8m57UwfSaHoI6CIPlSV1MlpO6SNaiThbN6mRWVSdVWZ1kJXWSFNRJEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADg9wnqJGhVJ6uyOsmq6qSqqJOiqzq5yqu6WC3P6mK2HEd1MEbLfZ49+zXtpOaS39IXNXe5p13UWPF72ic1dfKW9ql1eUu7tP2NLf3inNREOnuXflFGHTaWrSdvYsk6JJfoXXoTb1PNabwL+kEY71Ku023r7tOPYv5pFJ6Rn5qfj8KRtC+jvjGefSztYdWX1sFH0k82tUY3SPsWtDfZTdJekj4JN7dKO1Z9kBY3ST+er3x10/R2vqrdOO04BUnp4nbpTVwug30g3cwf1jMLKix6VfsAAAAASUVORK5CYII=")
@@ -199,7 +200,17 @@
       background: url("../../image/jian.png") no-repeat center;
       background-size: contain;
    }
-
+   .el_slider {
+      --el-slider-main-bg-color: #ff8057;
+      --el-slider-button-size: 16px;
+      :global {
+         .el-slider__button:hover,
+         .el-slider__button.hover,
+         .el-slider__button.dragging {
+            transform: scale(1.1);
+         }
+      }
+   }
    .sliderPoint {
       background: #ffffff;
       box-shadow: 0px 2px 4px 0px rgba(102, 102, 102, 0.77);

+ 17 - 11
src/views/coursewarePlay/component/video-item/index.tsx

@@ -5,12 +5,18 @@ import styles from "./index.module.scss"
 
 import icons from "../../image/icons.json"
 
-const { iconVideoBg, iconPlay, iconPause, iconSpeed } = icons
+const { iconVideoBg } = icons
 // eslint-disable-next-line @typescript-eslint/no-var-requires
 const iconLoopActive = require("../../image/iconLoopActive.png")
 // eslint-disable-next-line @typescript-eslint/no-var-requires
 const iconLoop = require("../../image/iconLoop.png")
-import { Slider } from "vant"
+// eslint-disable-next-line @typescript-eslint/no-var-requires
+const iconPause = require("../../image/iconPause.png")
+// eslint-disable-next-line @typescript-eslint/no-var-requires
+const iconPlay = require("../../image/iconPlay.png")
+// eslint-disable-next-line @typescript-eslint/no-var-requires
+const iconSpeed = require("../../image/iconSpeed.png")
+import { ElSlider } from "element-plus"
 
 export default defineComponent({
    name: "video-play",
@@ -121,14 +127,14 @@ export default defineComponent({
                 </div>
                 <div class="${styles.actions}">
                     <div class="${styles.actionWrap}">
-                        <div id="${playBtnId}" class="${styles.actionBtn}" style="margin-right: 24px;">
+                        <div id="${playBtnId}" class="${styles.actionBtn}">
                             <div class="van-loading van-loading--circular" aria-live="polite" aria-busy="true"><span class="van-loading__spinner van-loading__spinner--circular" style="color: rgb(255, 255, 255);"><svg class="van-loading__circular" viewBox="25 25 50 50"><circle cx="50" cy="50" r="20" fill="none"></circle></svg></span></div>
                             <img class="${styles.playIcon}" src="${iconPlay}" />
                             <img class="${styles.playIcon}" src="${iconPause}" />
                         </div>
-                        <div id="${loopBtnId}" style="margin-top:-6px;" class="${styles.actionBtn} ${styles.loopBtn}">
-                            <img class="loop" style="width:48px;height:48px;" src="${iconLoop}" />
-                            <img class="loopActive" style="width:48px;height:48px;" src="${iconLoopActive}" />
+                        <div id="${loopBtnId}" class="${styles.actionBtn} ${styles.loopBtn}">
+                            <img class="loop" style="width:54px;height:44px;" src="${iconLoop}" />
+                            <img class="loopActive" style="width:58px;height:44px;" src="${iconLoopActive}" />
                         </div>
                         <div style="position: relative">
                           <div id="${speedBtnId}" class="${styles.actionBtn} ${styles.speedBtn}">
@@ -292,15 +298,15 @@ export default defineComponent({
                         }
                      }}
                   ></i>
-                  <Slider
+                  <ElSlider
+                     class={styles.el_slider}
+                     style={{ padding: "12px 0" }}
                      min={0.5}
                      max={1.5}
                      step={0.1}
                      v-model={data.defaultSpeed}
-                     active-color="#FF8057"
                      vertical
-                     barHeight={5}
-                     reverse
+                     height={"82px"}
                      onChange={() => {
                         if (data.videoItem) {
                            data.videoItem.speed = data.defaultSpeed
@@ -315,7 +321,7 @@ export default defineComponent({
                            </div>
                         )
                      }}
-                  </Slider>
+                  </ElSlider>
                   <i
                      class={[styles.iconCut]}
                      onClick={() => {

BIN
src/views/coursewarePlay/image/iconLoop.png


BIN
src/views/coursewarePlay/image/iconLoopActive.png


BIN
src/views/coursewarePlay/image/iconPause.png


BIN
src/views/coursewarePlay/image/iconPlay.png


BIN
src/views/coursewarePlay/image/iconSpeed.png


+ 3 - 0
src/views/homePage/components/navContainer/navContainer.vue

@@ -60,6 +60,7 @@ function handleRouter(url?: string) {
       border-radius: 20px 0 0 0;
       display: flex;
       align-items: center;
+      padding-top: 6px;
       .cursor {
          cursor: pointer;
          &:hover {
@@ -73,6 +74,8 @@ function handleRouter(url?: string) {
          height: 42px;
          position: relative;
          & > img {
+            width: 42px;
+            height: 42px;
             position: absolute;
             top: 50%;
             left: 50%;

+ 53 - 30
src/views/homePage/homePage_gym.vue

@@ -6,17 +6,19 @@
 <template>
    <navContainer class="navContainer" :headImg="headImg" :navs="navs">
       <div class="homePage">
-         <div class="classTypes">
-            <div class="classType" v-for="item in classTypes" :key="item.name" @click="handleRouter(item.url)">
-               <img :src="item.img" />
-               <div>{{ item.name }}</div>
+         <ElScrollbar class="elScrollbar">
+            <div class="classTypes">
+               <div class="classType" v-for="item in classTypes" :key="item.name" @click="handleRouter(item.url)">
+                  <img :src="item.img" />
+                  <div>{{ item.name }}</div>
+               </div>
             </div>
-         </div>
-         <div class="courseBoard">
-            <div class="details">
-               <el-empty style="margin-top: 50px" :image-size="360" :image="require('@/img/layout/empty1.png')" description="您还没有待上课程哦~" />
+            <div class="courseBoard">
+               <div class="details">
+                  <el-empty class="empty" :image="require('@/img/layout/empty1.png')" description="您还没有待上课程哦~" />
+               </div>
             </div>
-         </div>
+         </ElScrollbar>
       </div>
    </navContainer>
 </template>
@@ -79,11 +81,15 @@ function handleRouter(url?: string) {
         })
 }
 </script>
-
 <style lang="scss" scoped>
 .navContainer :deep(.navCon) {
-   .navImg > img {
-      top: 72% !important;
+   .navImg {
+      margin-left: 5rem;
+      > img {
+         width: 91px;
+         height: 92px;
+         top: 70% !important;
+      }
    }
    .nav {
       font-size: 28px;
@@ -96,49 +102,61 @@ function handleRouter(url?: string) {
 .homePage {
    width: 100%;
    height: 100%;
-   padding: 50px;
-   display: flex;
+   & > :deep(.elScrollbar) {
+      .el-scrollbar__view {
+         width: 100%;
+         display: flex;
+         padding: 5rem 5rem 0;
+      }
+      .el-scrollbar__wrap {
+         overflow-x: hidden;
+      }
+      .el-scrollbar__bar.is-vertical {
+         width: 4px;
+         right: 0;
+      }
+   }
    .classTypes {
       flex-grow: 1;
       display: flex;
       flex-wrap: wrap;
-      margin-bottom: -30px;
-      margin-left: -30px;
+      justify-content: space-between;
+      height: 72.9rem;
+      align-content: space-between;
       .classType {
          background: #feffff;
-         box-shadow: 0px 2px 14px 0px #f1e3cc;
-         border-radius: 34px;
-         margin-left: 30px;
-         margin-bottom: 30px;
-         width: calc(33.33% - 30px);
+         box-shadow: 0px 0.2rem 1.4rem 0 #f1e3cc;
+         border-radius: 3.4rem;
+         width: 36rem;
+         height: 35rem;
          display: flex;
          justify-content: center;
          align-items: center;
          flex-direction: column;
          cursor: pointer;
+         padding: 4.4rem 5.3rem;
          &:hover {
             transform: scale(1.02);
-            box-shadow: 0px 2px 14px 0px #e4d7c2;
+            box-shadow: 0px 0.2rem 1.4rem 0px #e4d7c2;
          }
          > div {
-            margin-top: 10px;
+            margin-top: 1rem;
             font-family: AlimamaFangYuanTiVF, AlimamaFangYuanTiVF;
             font-weight: bold;
-            font-size: 28px;
+            font-size: 2.8rem;
             color: #393939;
          }
          > img {
             width: 100%;
-            max-width: 254px;
          }
       }
    }
    .courseBoard {
       flex-shrink: 0;
-      margin-left: 50px;
-      margin-top: -35px;
-      width: 572px;
-      height: calc(100% + 35px);
+      margin-left: 5rem;
+      margin-top: -3.5rem;
+      width: 57.2rem;
+      height: 76.4rem;
       background: url("@/img/homePage/bg.png") no-repeat;
       background-size: 100% 100%;
       position: relative;
@@ -148,7 +166,12 @@ function handleRouter(url?: string) {
          display: flex;
          justify-content: center;
          align-items: center;
-         top: 168px;
+         top: 24.8rem;
+         :deep(.empty) {
+            .el-empty__image {
+               width: 36rem;
+            }
+         }
       }
    }
 }

+ 53 - 29
src/views/homePage/homePage_gyt.vue

@@ -6,17 +6,19 @@
 <template>
    <navContainer class="navContainer" :headImg="headImg" :navs="navs">
       <div class="homePage">
-         <div class="classTypes">
-            <div class="classType" v-for="item in classTypes" :key="item.name" @click="handleRouter(item.url)">
-               <img :src="item.img" />
-               <div>{{ item.name }}</div>
+         <ElScrollbar class="elScrollbar">
+            <div class="classTypes">
+               <div class="classType" v-for="item in classTypes" :key="item.name" @click="handleRouter(item.url)">
+                  <img :src="item.img" />
+                  <div>{{ item.name }}</div>
+               </div>
             </div>
-         </div>
-         <div class="courseBoard">
-            <div class="details">
-               <el-empty style="margin-top: 50px" :image-size="360" :image="require('@/img/layout/empty1.png')" description="您还没有待上课程哦~" />
+            <div class="courseBoard">
+               <div class="details">
+                  <el-empty class="empty" :image="require('@/img/layout/empty1.png')" description="您还没有待上课程哦~" />
+               </div>
             </div>
-         </div>
+         </ElScrollbar>
       </div>
    </navContainer>
 </template>
@@ -82,8 +84,13 @@ function handleRouter(url?: string) {
 
 <style lang="scss" scoped>
 .navContainer :deep(.navCon) {
-   .navImg > img {
-      top: 72% !important;
+   .navImg {
+      margin-left: 5rem;
+      > img {
+         width: 91px;
+         height: 92px;
+         top: 70% !important;
+      }
    }
    .nav {
       font-size: 28px;
@@ -96,49 +103,61 @@ function handleRouter(url?: string) {
 .homePage {
    width: 100%;
    height: 100%;
-   padding: 50px;
-   display: flex;
+   & > :deep(.elScrollbar) {
+      .el-scrollbar__view {
+         width: 100%;
+         display: flex;
+         padding: 5rem 5rem 0;
+      }
+      .el-scrollbar__wrap {
+         overflow-x: hidden;
+      }
+      .el-scrollbar__bar.is-vertical {
+         width: 4px;
+         right: 0;
+      }
+   }
    .classTypes {
       flex-grow: 1;
       display: flex;
       flex-wrap: wrap;
-      margin-bottom: -30px;
-      margin-left: -30px;
+      justify-content: space-between;
+      height: 72.9rem;
+      align-content: space-between;
       .classType {
          background: #feffff;
-         box-shadow: 0px 2px 14px 0px #f1e3cc;
-         border-radius: 34px;
-         margin-left: 30px;
-         margin-bottom: 30px;
-         width: calc(33.33% - 30px);
+         box-shadow: 0px 0.2rem 1.4rem 0 #f1e3cc;
+         border-radius: 3.4rem;
+         width: 36rem;
+         height: 35rem;
          display: flex;
          justify-content: center;
          align-items: center;
          flex-direction: column;
          cursor: pointer;
+         padding: 4.4rem 5.3rem;
          &:hover {
             transform: scale(1.02);
-            box-shadow: 0px 2px 14px 0px #e4d7c2;
+            box-shadow: 0px 0.2rem 1.4rem 0px #e4d7c2;
          }
          > div {
-            margin-top: 10px;
+            margin-top: 1rem;
             font-family: AlimamaFangYuanTiVF, AlimamaFangYuanTiVF;
             font-weight: bold;
-            font-size: 28px;
+            font-size: 2.8rem;
             color: #393939;
          }
          > img {
             width: 100%;
-            max-width: 254px;
          }
       }
    }
    .courseBoard {
       flex-shrink: 0;
-      margin-left: 50px;
-      margin-top: -35px;
-      width: 572px;
-      height: calc(100% + 35px);
+      margin-left: 5rem;
+      margin-top: -3.5rem;
+      width: 57.2rem;
+      height: 76.4rem;
       background: url("@/img/homePage/bg.png") no-repeat;
       background-size: 100% 100%;
       position: relative;
@@ -148,7 +167,12 @@ function handleRouter(url?: string) {
          display: flex;
          justify-content: center;
          align-items: center;
-         top: 168px;
+         top: 24.8rem;
+         :deep(.empty) {
+            .el-empty__image {
+               width: 36rem;
+            }
+         }
       }
    }
 }

+ 54 - 9
src/viewsframe/errorPage/errorPage.vue

@@ -6,14 +6,21 @@
 <template>
    <div class="errorPage">
       <div class="error">
-         <div>您访问的页面不存在!</div>
-         <ElButton type="primary" @click="handleGoHome">返回首页</ElButton>
+         <img class="img" src="@/img/loginErr/404.png" />
+         <div class="errName">糟糕,页面找不到了</div>
+         <div class="title">您可以通过以下方式继续访问</div>
+         <div class="btnCon">
+            <div class="btn" @click="handleGoHome">跳转到首页</div>
+            <div class="btn" @click="handleGoBack">返回上一步</div>
+         </div>
       </div>
    </div>
 </template>
 
 <script setup lang="ts">
+import "vant/lib/index.css"
 import { useRouter } from "vue-router"
+
 const router = useRouter()
 
 function handleGoHome() {
@@ -21,6 +28,9 @@ function handleGoHome() {
       path: "/"
    })
 }
+function handleGoBack() {
+   router.back()
+}
 </script>
 
 <style lang="scss" scoped>
@@ -31,17 +41,52 @@ function handleGoHome() {
    justify-content: center;
    align-items: center;
    .error {
-      width: 600px;
-      height: 160px;
-      background-color: $bg-color-page;
       display: flex;
       flex-direction: column;
       justify-content: center;
       align-items: center;
-      & > div:first-child {
-         font-size: $font-size-medium;
-         color: $text-color-regular;
-         margin-bottom: 10px;
+      .img {
+         width: 630px;
+         height: 514px;
+      }
+      .errName {
+         margin-top: -100px;
+         font-weight: 500;
+         font-size: 29px;
+         color: #333333;
+         line-height: 41px;
+      }
+      .title {
+         margin-top: 10px;
+         font-weight: 400;
+         font-size: 22px;
+         color: #aaaaaa;
+         line-height: 30px;
+      }
+      .btnCon {
+         margin-top: 50px;
+         display: flex;
+         justify-content: center;
+         .btn {
+            background: url("@/img/loginErr/btn.png") no-repeat;
+            width: 170px;
+            height: 52px;
+            background-size: 100% 100%;
+            font-weight: bold;
+            font-size: 22px;
+            color: #ffffff;
+            line-height: 52px;
+            text-align: center;
+            letter-spacing: 1px;
+            margin-right: 25px;
+            cursor: pointer;
+            &:hover {
+               opacity: $opacity-hover;
+            }
+            &:last-child {
+               margin-right: 0;
+            }
+         }
       }
    }
 }

+ 15 - 5
src/viewsframe/layout/layout.vue

@@ -10,7 +10,7 @@
             <div class="avatar">
                <div class="imgCon"><el-image class="avatarImg" :src="userInfo.avatar || require('@/img/layout/userImg.png')" /></div>
                <div class="name">
-                  {{ userInfo.username }}
+                  <ellipsisScroll :title="userInfo.username || ''" />
                </div>
                <img class="horn" :class="{ isVisible: visible }" src="@/img/layout/horn.png" />
             </div>
@@ -19,7 +19,7 @@
                   <div class="avatar-item">
                      <el-image class="avatarImg" :src="userInfo.avatar || require('@/img/layout/userImg.png')" />
                      <div class="userInfo">
-                        <div class="realName">{{ userInfo.username }}</div>
+                        <div class="realName"><ellipsisScroll :title="userInfo.username || ''" /></div>
                         <div class="phone">{{ userInfo.phone }}</div>
                      </div>
                   </div>
@@ -67,8 +67,6 @@ function handleLogout() {
 .layout {
    width: 100%;
    height: 100%;
-   min-width: 1200px;
-   min-height: 880px;
    background: linear-gradient(180deg, #ffd884 0%, #ffa943 100%);
    box-shadow: 0px 11px 15px 0px #63bd73, inset 0px 1px 14px 0px rgba(255, 255, 255, 0.5);
    .head {
@@ -107,12 +105,17 @@ function handleLogout() {
          .name {
             margin-left: 6px;
             font-size: 18px;
+            height: 18px;
+            line-height: 18px;
             color: #244b55;
             font-weight: 500;
-            min-width: 56px;
+            width: 56px;
             text-align: center;
+            overflow: hidden;
          }
          .horn {
+            width: 10px;
+            height: 6px;
             margin-left: 8px;
             &.isVisible {
                transform: rotate(180deg);
@@ -147,10 +150,13 @@ function handleLogout() {
       }
       .userInfo {
          margin-left: 16px;
+         flex-grow: 1;
+         overflow: hidden;
          .realName {
             font-weight: 600;
             font-size: 20px;
             line-height: 28px;
+            height: 28px;
             color: #333333;
          }
          .phone {
@@ -174,6 +180,10 @@ function handleLogout() {
          &:hover {
             background: #f5f6fa;
          }
+         > img {
+            width: 22px;
+            height: 23px;
+         }
          .text {
             margin-left: 20px;
             font-weight: 500;

+ 32 - 8
src/viewsframe/login/login.vue

@@ -7,9 +7,11 @@
    <div class="login">
       <div class="loginCon">
          <div class="decoration">
+            <img class="xiaoren" src="@/img/loginErr/xiaoren.png" />
             <img class="star" src="@/img/loginErr/star.png" />
             <img class="bStar" src="@/img/loginErr/bStar.png" />
             <img class="music" src="@/img/loginErr/music.png" />
+            <img class="yun" src="@/img/loginErr/yun.png" />
          </div>
          <div class="loginBox">
             <img v-show="qrcodeStatus === 2" class="scanned" src="@/img/loginErr/scanned.png" />
@@ -101,17 +103,18 @@ function handleRefresh() {
 <style lang="scss" scoped>
 .login {
    width: 100%;
-   min-height: 100%;
+   height: 100%;
+   min-height: 640px;
+   min-width: 1280px;
    background: url("@/img/loginErr/bg.png") no-repeat;
    background-size: cover;
    display: flex;
-   justify-content: center;
    align-items: center;
-   min-width: 1280px;
+   justify-content: center;
    .loginCon {
+      width: 74%;
       display: flex;
       justify-content: space-between;
-      width: 80%;
    }
    .loginBox {
       width: 440px;
@@ -124,6 +127,8 @@ function handleRefresh() {
       align-items: center;
       .scanned {
          margin-top: 132px;
+         width: 114px;
+         height: 189px;
       }
       .qrcodeBox {
          margin-top: 154px;
@@ -167,6 +172,10 @@ function handleRefresh() {
             color: #777;
             margin: 0 14px;
          }
+         > img {
+            width: 33px;
+            height: 18px;
+         }
       }
       .refreshBtn {
          margin-top: 14px;
@@ -182,12 +191,19 @@ function handleRefresh() {
       }
    }
    .decoration {
+      margin-top: -8px;
       position: relative;
-      width: 522px;
-      height: 626px;
-      background: url("@/img/loginErr/xiaoren.png") no-repeat;
-      background-size: cover;
       z-index: 1;
+      width: 523px;
+      height: 412px;
+      .xiaoren {
+         position: absolute;
+         top: 0;
+         left: 0;
+         width: 100%;
+         height: 100%;
+         z-index: 1;
+      }
       .star {
          position: absolute;
          right: 0;
@@ -209,6 +225,14 @@ function handleRefresh() {
          width: 28px;
          height: 56px;
       }
+      .yun {
+         position: absolute;
+         width: 346px;
+         height: 240px;
+         bottom: -160px;
+         left: 40px;
+         z-index: 0;
+      }
    }
 }
 </style>