Quellcode durchsuchen

feat: 多频多台内容排序调整后自动保存,不需要点击提交按钮

Damon vor 11 Monaten
Ursprung
Commit
d084acd51d
1 geänderte Dateien mit 15 neuen und 14 gelöschten Zeilen
  1. 15 14
      src/views/operation/channels/detail.vue

+ 15 - 14
src/views/operation/channels/detail.vue

@@ -122,7 +122,6 @@
                 @click="getChangeSort(scope.$index, scope.$index + 1)"
                 :disabled="scope.$index > form.list.length - 2"
               />
-              
             </template>
           </el-table-column>
         </el-table>
@@ -181,20 +180,22 @@ export default {
       const sortBean = this.form.list[sort];
       this.form.list[row] = sortBean;
       this.form.list[sort] = rowBean;
+      this.form.list = this.form.list.filter((i) => i);
 
-      this.form.audioList = [];
-      this.form.list.map((i) => {
-        this.form.audioList.push({
-          audioId: i.audioId,
-          audioType: i.audioType,
-        });
-      });
-      channeledit(this.form).then((res) => {
-        if (res.code === 0) {
-          this.$message.success("修改成功!");
-          this.getDetail();
-        }
-      });
+      // this.form.audioList = [];
+      // this.form.list.map((i) => {
+      //   this.form.audioList.push({
+      //     audioId: i.audioId,
+      //     audioType: i.audioType,
+      //   });
+      // });
+
+      // channeledit(this.form).then((res) => {
+      //   if (res.code === 0) {
+      //     this.$message.success("修改成功!");
+      //     this.getDetail();
+      //   }
+      // });
     },
 
     // 频道详情