瀏覽代碼

Merge branch 'product' of http://1.116.113.26:8088/zhuliu/xiaoshi_system into product

zhuliu 1 年之前
父節點
當前提交
c756cbe559
共有 1 個文件被更改,包括 11 次插入6 次删除
  1. 11 6
      src/views/event/components/index.vue

+ 11 - 6
src/views/event/components/index.vue

@@ -15,9 +15,9 @@
             </el-select>
           </div>
           <el-button-group style=" display: flex; justify-content: flex-start; margin-left: 10px;" v-if="[2].indexOf(isOperate) == -1">
-            <el-button size="small" :type="viewSelected === 'visual' ? 'primary' : ''" @click="onChange2('visual')">可视化</el-button>
-            <el-button :type="viewSelected === 'Table' ? 'primary' : ''" @click="onChange2('Table')" size="small">列表</el-button>
-            <el-button :type="viewSelected === 'Card' ? 'primary' : ''" @click="onChange2('Card')" size="small">卡片</el-button>
+            <el-button size="small" :type="viewSelectedBtn === 'visual' ? 'primary' : ''" @click="onChange2('visual')">可视化</el-button>
+            <el-button :type="viewSelectedBtn === 'Table' ? 'primary' : ''" @click="onChange2('Table')" size="small">列表</el-button>
+            <el-button :type="viewSelectedBtn === 'Card' ? 'primary' : ''" @click="onChange2('Card')" size="small">卡片</el-button>
           </el-button-group>
           <!-- <el-button type="primary" size="small" style="margin: 0 10px;" @click="handleCommand('1')">添加事件</el-button> -->
           <el-dropdown trigger="click" split-button type="primary" size="small" @command="handleCommand($event)">
@@ -102,8 +102,10 @@ export default {
       groupingValue: '',
       //分组
       groupingOption: [],
-      //选择的视图
+      // 当前显示的视图
       viewSelected: 'Table',
+      // 三种视图底色
+      viewSelectedBtn:'Table',
       //加载中
       loading: false,
       //事件的数据集合
@@ -128,7 +130,7 @@ export default {
       //表格全部栏位
       fieldList: [],
       //操作回馈
-      handleMessage:''
+      handleMessage:'',
     };
   },
   watch: {},
@@ -152,7 +154,8 @@ export default {
       this.handleMessage = val
       this.queryParams.current = 1
       this.searchOption.searchQuery=''
-      this.getList()
+      // this.getList()
+      this.isGrouping()
       this.clearMessage()
     },
     //清空信息
@@ -277,6 +280,8 @@ export default {
     //切换视图
     onChange2(type) {
       this.viewSelected = type
+      this.viewSelectedBtn = type
+      this.groupingValue=''
       this.queryParams.current=1
       this.getList()
     },