Explorar el Código

添加已下架

lex hace 2 años
padre
commit
ab60626bce

+ 1 - 0
src/components/col-upload/index.tsx

@@ -168,6 +168,7 @@ export default defineComponent({
           onExceed={this.handleExceed}
           ref="uploadRef"
           class={this.uploadType === 'file' ? styles.fileUpload : ''}
+          style={{ lineHeight: '0' }}
         >
           <div
             ref="uploadDom"

+ 19 - 8
src/views/user-info/components/item/index.tsx

@@ -18,16 +18,27 @@ export default defineComponent({
         onClick={() => {
           console.log(item)
           if (item.type === 'video') {
-            this.$router.push({
-              path: '/videoDetail',
-              query: {
-                id: item.id
-              }
-            })
+            if (item.shelvesFlag === 0) {
+              this.$router.push({
+                path: '/userInfo/videoOperation',
+                query: {
+                  type: 'edit',
+                  groupId: item.id
+                }
+              })
+              return
+            } else {
+              this.$router.push({
+                path: '/videoDetail',
+                query: {
+                  id: item.id
+                }
+              })
+            }
           }
           if (
-            (item.type === 'live' && item.status === 'CANCEL') ||
-            item.status === 'OUT_SALE'
+            item.type === 'live' &&
+            (item.status === 'CANCEL' || item.status === 'OUT_SALE')
           ) {
             // 直播课
             this.$router.push({

+ 10 - 0
src/views/user-info/music-class/index.tsx

@@ -84,6 +84,16 @@ export default defineComponent({
               />
             )}
           </ElTabPane>
+          <ElTabPane label="已下架" name="OUT_SALE">
+            {this.activeName === 'OUT_SALE' && (
+              <List
+                auditStatus="OUT_SALE"
+                onNumber={(data: any) => {
+                  this.num = data
+                }}
+              />
+            )}
+          </ElTabPane>
         </ElTabs>
       </div>
     )

+ 8 - 3
src/views/user-info/music-class/list.tsx

@@ -112,9 +112,15 @@ export default defineComponent({
                   <MusicItem
                     onClick={(item: any) => {
                       if (['PASS', 'DOING'].includes(this.auditStatus)) {
-                        this.$router.push({ path: '/muiscDetial', query: { id: item.id } })
+                        this.$router.push({
+                          path: '/muiscDetial',
+                          query: { id: item.id }
+                        })
                       }
-                      if (this.auditStatus === 'UNPASS') {
+                      if (
+                        this.auditStatus === 'UNPASS' ||
+                        this.auditStatus === 'OUT_SALE'
+                      ) {
                         console.log(item)
                         this.$router.push({
                           path: '/userInfo/musicOperation',
@@ -124,7 +130,6 @@ export default defineComponent({
                           }
                         })
                       }
-                      
                     }}
                     item={{
                       id: item.id,

+ 3 - 0
src/views/user-info/video-class/index.tsx

@@ -43,6 +43,9 @@ export default defineComponent({
           <ElTabPane label="审核失败" name="UNPASS">
             {this.activeName === 'UNPASS' && <List auditStatus="UNPASS" />}
           </ElTabPane>
+          <ElTabPane label="已下架" name="OUT_SALE">
+            {this.activeName === 'OUT_SALE' && <List auditStatus="OUT_SALE" />}
+          </ElTabPane>
         </ElTabs>
       </div>
     )

+ 2 - 1
src/views/user-info/video-class/list.tsx

@@ -144,7 +144,8 @@ export default defineComponent({
                         avatar: item.avatar,
                         teacherName: item.username,
                         coursePrice: item.lessonPrice,
-                        courseNum: item.lessonCount
+                        courseNum: item.lessonCount,
+                        shelvesFlag: item.shelvesFlag
                       }}
                     />
                   </div>

+ 2 - 0
src/views/user-info/video-operation/course-content/index.module.less

@@ -13,6 +13,8 @@
     }
     .el-dialog {
       --el-dialog-width: 375px !important;
+      border-radius: 10px;
+      overflow: hidden;
     }
 
     .el-dialog__body {