From f56e474c81bb25845b46cf99c85bd313dbfcd3b5 Mon Sep 17 00:00:00 2001
From: wwf <1971391498@qq.com>
Date: 星期六, 31 一月 2026 19:26:25 +0800
Subject: [PATCH] 项目初始化+首页+公告详情页面

---
 src/views/main/components/Filtrate.vue |   55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 55 insertions(+), 0 deletions(-)

diff --git a/src/views/main/components/Filtrate.vue b/src/views/main/components/Filtrate.vue
new file mode 100644
index 0000000..33023b0
--- /dev/null
+++ b/src/views/main/components/Filtrate.vue
@@ -0,0 +1,55 @@
+<template>
+  <el-row style="width: 100%;flex-wrap: nowrap;">
+    <div style="flex-grow: 0;">
+      <el-tooltip content="鍒锋柊鍒楄〃鏁版嵁" placement="top-start">
+        <el-button type="text" style="width: 30px;" :loading="loadingFlag" @click.stop="handlerRefresh()" class="mr-2">
+          <Icon v-show="!loadingFlag" icon="material-symbols:refresh-rounded" width="26" height="26" style="color: #4d4d4d" />
+          <template #loading>
+            <Icon icon="line-md:loading-loop" width="30" height="30" style="color: black" />
+          </template>
+        </el-button>
+      </el-tooltip>
+    </div>
+    <slot name="default"></slot>
+  </el-row>
+</template>
+
+<script>
+import { debounce } from '@/utils/tool.js'
+export default {
+  data() {
+    return {
+      loading: false
+    }
+  },
+  props: {
+    loadingFlag: {
+      type: Boolean,
+      default: false
+    },
+    refresh: {
+      type: Function,
+      default: () => {}
+    },
+    filter: {
+      type: Object,
+      default: () => { 
+        return {} 
+      }
+    }
+  },
+  watch: {
+    filter: {
+      handler: debounce(function() {
+        this.handlerRefresh()
+      }, 1000),
+      deep: true
+    }
+  },
+  methods: { 
+    handlerRefresh() {
+      this.refresh()
+    }
+  }
+}
+</script>
\ No newline at end of file

--
Gitblit v1.8.0