From 1f5f5721e556ce1ede1be293313d7af88ef60677 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期二, 10 一月 2023 18:35:50 +0800 Subject: [PATCH] 2023-01-10 --- src/tabviews/zshare/topSearch/index.jsx | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/src/tabviews/zshare/topSearch/index.jsx b/src/tabviews/zshare/topSearch/index.jsx index 0b4ad56..9c98c03 100644 --- a/src/tabviews/zshare/topSearch/index.jsx +++ b/src/tabviews/zshare/topSearch/index.jsx @@ -4,6 +4,7 @@ import { Form, Row, Col, Button, notification, Modal, Drawer } from 'antd' import { CloseOutlined, DownOutlined } from '@ant-design/icons' import moment from 'moment' +import md5 from 'md5' import Api from '@/api' import options from '@/store/options.js' @@ -37,6 +38,7 @@ } record = {} + sign = '' UNSAFE_componentWillMount () { const { config, searchlist, setting } = this.props @@ -636,6 +638,15 @@ } } + let sign = md5(JSON.stringify(searches)) + + if (sign === this.sign) return + + this.sign = sign + setTimeout(() => { + this.sign = '' + }, 2000) + this.props.refreshdata(searches) }) }) -- Gitblit v1.8.0