From 9e550a8bb6c848d7656669f687970b8e224e7057 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com>
Date: Thu, 28 Nov 2019 16:02:43 +0800
Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=B8=8A=E4=BC=A0=E6=96=87?=
=?UTF-8?q?=E4=BB=B6=E9=99=90=E5=88=B6=E5=92=8C=E6=90=9C=E7=B4=A2=E5=8A=9F?=
=?UTF-8?q?=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/modules/user/modal/RealNameCertificationModal.js | 9 ++++++++-
public/react/src/search/SearchPage.js | 5 +++--
2 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/public/react/src/modules/user/modal/RealNameCertificationModal.js b/public/react/src/modules/user/modal/RealNameCertificationModal.js
index 9b4d5e497..bb641af20 100644
--- a/public/react/src/modules/user/modal/RealNameCertificationModal.js
+++ b/public/react/src/modules/user/modal/RealNameCertificationModal.js
@@ -490,6 +490,13 @@ class RealNameCertificationModal extends Component{
action: this.props.current_user ? `${getUploadActionUrl()}` : '',
className: 'idPic-uploader',
onChange: this.handleChange2,
+ beforeUpload: (file) => {
+ const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png' || file.type === 'image/jpg' || file.type === 'image/bmp';
+ if (!isJpgOrPng) {
+ this.props.showNotification('请上传正确文件格式');
+ }
+ return isJpgOrPng;
+ },
};
// form合并了
@@ -740,7 +747,7 @@ class RealNameCertificationModal extends Component{
{imageUrl2 ?
//
diff --git a/public/react/src/search/SearchPage.js b/public/react/src/search/SearchPage.js
index c2afca884..1bf1d83d4 100644
--- a/public/react/src/search/SearchPage.js
+++ b/public/react/src/search/SearchPage.js
@@ -81,10 +81,11 @@ class SearchPage extends Component{
setdatafuns =(value)=>{
this.setState({
- keywords:value
+ keywords:value,
+ page:1
})
this.props.history.replace(`/search?value=${value}`)
- this.getdata(this.state.page,this.state.type,value);
+ this.getdata(1,this.state.type,value);
}
paginationonChanges = (pageNumber) => {
this.setState({