|
|
|
@ -109,7 +109,7 @@ export class MyFriend extends React.Component< |
|
|
|
|
/** |
|
|
|
|
* 查找用户 |
|
|
|
|
*/ |
|
|
|
|
queryUser(name:string){ |
|
|
|
|
queryUser(name:string,page:number){ |
|
|
|
|
|
|
|
|
|
if(!name){ |
|
|
|
|
this.setState({ |
|
|
|
@ -122,7 +122,9 @@ export class MyFriend extends React.Component< |
|
|
|
|
switch (res.customResult) { |
|
|
|
|
case PageDataMessage.ok: |
|
|
|
|
that.setState({ |
|
|
|
|
userList: res.dataList |
|
|
|
|
userList: page===1?res.dataList||[]:(that.state.userList||[]).concat(res.dataList||[]), |
|
|
|
|
page: res.page, |
|
|
|
|
scrollTip: page > 1 ? '成功加载第' + page + '页数据' : null, |
|
|
|
|
}) |
|
|
|
|
break |
|
|
|
|
} |
|
|
|
@ -187,7 +189,7 @@ export class MyFriend extends React.Component< |
|
|
|
|
this.setState({ |
|
|
|
|
queryUser:e.target.value |
|
|
|
|
}) |
|
|
|
|
this.queryUser(e.target.value) |
|
|
|
|
this.queryUser(e.target.value,1) |
|
|
|
|
}}/> |
|
|
|
|
</ListGroup.Item> |
|
|
|
|
|
|
|
|
|