소스 검색

添加参数

lex-xin 4 달 전
부모
커밋
e442fb0caa
3개의 변경된 파일10개의 추가작업 그리고 8개의 파일을 삭제
  1. 1 1
      src/components/TheVip/index.tsx
  2. 3 3
      src/components/o-empty/index.module.less
  3. 6 4
      src/views/choose-homework/classroom-detail/index.tsx

+ 1 - 1
src/components/TheVip/index.tsx

@@ -1,5 +1,5 @@
 import { Button, Popup } from 'vant';
-import { defineComponent, reactive } from 'vue';
+import { defineComponent } from 'vue';
 import styles from './index.module.less';
 import { state } from '@/state';
 import { gotoMemberCenter } from '@/views/hook/useFee';

+ 3 - 3
src/components/o-empty/index.module.less

@@ -23,7 +23,7 @@
   :global {
     .van-empty__image {
       width: 210px;
-      height: 160px;
+      height: 135px;
     }
 
     .van-empty {
@@ -35,7 +35,7 @@
     :global {
       .van-empty__image {
         width: 161px;
-        height: 101px;
+        height: 103px;
       }
     }
   }
@@ -44,7 +44,7 @@
     :global {
       .van-empty__image {
         width: 230px;
-        height: 160px;
+        height: 138px;
       }
 
       .van-empty__description {

+ 6 - 4
src/views/choose-homework/classroom-detail/index.tsx

@@ -30,6 +30,7 @@ export default defineComponent({
       catchItem: {} as any,
       loading: true,
       detail: {
+        id: null,
         cover: '',
         name: '',
         des: ''
@@ -49,6 +50,7 @@ export default defineComponent({
         `${state.platformApi}/lessonCourseware/getLessonCoursewareDetail/${route.query.id}`
       );
       if (res?.data) {
+        data.detail.id = res.data.id;
         data.detail.cover = res.data.coverImg;
         data.detail.name = res.data.name;
         data.detail.des = res.data.lessonTargetDesc;
@@ -73,13 +75,13 @@ export default defineComponent({
           });
 
           data.list = res.data;
-          console.log(data.list, 'data.list', data.disabledIds);
+          // console.log(data.list, 'data.list', data.disabledIds);
 
           const allIds = {} as any;
           data.disabledIds.forEach((item: any) => {
             allIds[item] = formatGetIds(item, data.list);
           });
-          console.log(allIds, 'allIds');
+          // console.log(allIds, 'allIds');
 
           for (const item in allIds) {
             const ids = allIds[item];
@@ -154,7 +156,6 @@ export default defineComponent({
       let tempI: any = {};
       for (const item of list) {
         if (item.id === id) {
-          console.log(item, id);
           tempI = item;
         }
         if (item.children && item.children.length > 0 && !tempI.id) {
@@ -172,7 +173,8 @@ export default defineComponent({
             if (item.status === 'checked') {
               tempList.push({
                 id: item.id,
-                name: item.name
+                name: item.name,
+                lessonCoursewareId: data.detail.id
               });
             }
           });