PCqiandao
杨树林 5 years ago
parent ed3ba7a174
commit 2f0ea73e66

@ -3,6 +3,7 @@ import React,{ Component } from "react";
import { Row, Col,Select,Table,Pagination } from 'antd'; import { Row, Col,Select,Table,Pagination } from 'antd';
import axios from 'axios'; import axios from 'axios';
import LoadingSpin from "../../../../common/LoadingSpin"; import LoadingSpin from "../../../../common/LoadingSpin";
import NoneDatas from "../component/NoneDatas";
const { Option } = Select; const { Option } = Select;
class Signedinlist extends Component { class Signedinlist extends Component {
@ -80,10 +81,13 @@ class Signedinlist extends Component {
this.setState({ this.setState({
member_attendances:response.data.member_attendances, member_attendances:response.data.member_attendances,
members_count:response.data.members_count, members_count:response.data.members_count,
loading:false
}) })
} }
this.setState({
loading:false
})
}).catch((error) => { }).catch((error) => {
that.setState({ that.setState({
loading:false loading:false
@ -295,12 +299,21 @@ class Signedinlist extends Component {
</Row> </Row>
<div className={"backfff mt10"}> <div className={"backfff mt10"}>
{ {
this.state.loading===true?
<div style={{
minHeight:"400px",
}}>
<LoadingSpin></LoadingSpin>
</div>
:
member_attendances&&member_attendances.length===0? member_attendances&&member_attendances.length===0?
<div style={{ <div style={{
minHeight:"400px", minHeight:"400px",
}}> }}>
<LoadingSpin></LoadingSpin> {/*<LoadingSpin></LoadingSpin>*/}
<NoneDatas></NoneDatas>
</div> </div>
: :
// loading={this.state.loading} // loading={this.state.loading}
<Table columns={columns} dataSource={member_attendances} pagination={false} /> <Table columns={columns} dataSource={member_attendances} pagination={false} />
@ -310,9 +323,14 @@ class Signedinlist extends Component {
</div> </div>
<div className="mb30 clearfix educontent mt40 intermediatecenter"> <div className="mb30 clearfix educontent mt40 intermediatecenter">
<Pagination showQuickJumper current={this.state.page} onChange={this.paginationonChange} {
pageSize={this.state.limit} member_attendances&&member_attendances.length>0?
total={this.state.members_count}></Pagination> <Pagination showQuickJumper current={this.state.page} onChange={this.paginationonChange}
pageSize={this.state.limit}
total={this.state.members_count}></Pagination>
:""
}
</div> </div>
</React.Fragment> </React.Fragment>

Loading…
Cancel
Save