Ver código fonte

新学有义方增加选择平台功能

sunzhilei 2 semanas atrás
pai
commit
6ef22484f3
1 arquivos alterados com 22 adições e 1 exclusões
  1. 22 1
      src/pages/school/tv/index.vue

+ 22 - 1
src/pages/school/tv/index.vue

@@ -6,6 +6,22 @@
           <el-form-item
             class="pruductForm-skill"
             prop="channel"
+            label="选择平台"
+            :rules="[{ required: true, message: '请选择平台', trigger: 'blur' }]"
+          >
+            <el-select v-model="skillParams.platformType" placeholder="请选择技能" @change="platformTypeChange" style="width:160px">
+              <el-option key="0" label="电视" value="0" ></el-option>
+              <el-option key="1" label="手机" value="1" ></el-option>
+              <el-option key="2" label="平板" value="2" ></el-option>
+              <el-option key="3" label="电脑" value="3" ></el-option>
+              <el-option key="4" label="音箱" value="4" ></el-option>
+              <el-option key="5" label="创维桌面" value="5" ></el-option>
+              <el-option key="6" label="小程序" value="6" ></el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item
+            class="pruductForm-skill"
+            prop="channel"
             label="渠道选择"
             :rules="[{ required: true, message: '请选择渠道', trigger: 'blur' }]"
           >
@@ -269,9 +285,12 @@ export default {
       tableHeight: 500,
       dateValue: "",
       skillParams: {
+        pageNum: 1,
+        pageSize: 1000,
         startDay: "",
         endDay: "",
         channel: "",
+        platformType: "",
       },
     };
   },
@@ -291,7 +310,6 @@ export default {
     this.tableHeight = document.documentElement.clientHeight * 0.75;
   },
   mounted() {
-    this.$store.dispatch("getSchoolChannelData", {platformType:0});
   },
   methods: {
     // 搜索
@@ -342,6 +360,9 @@ export default {
       // 清空数据
       this.$store.dispatch("clearList");
     },
+    platformTypeChange(platformType) {
+    this.$store.dispatch("getSchoolChannelData", {platformType});
+    },
     skillChange(val) {
       console.log(val)
     },