PCqiandao
杨树明 5 years ago
parent 55b12f66f0
commit 0a854db375

@ -101,16 +101,16 @@ class Signinstatistics extends Component {
{ {
` `
.lishiqiandao{ .lishiqiandao{
background-image: url(${getImageUrl(`/images/qiandao/lishi.png`)}); background-image: url(${getImageUrl(`images/qiandao/lishi.png`)});
} }
.daokeqiandao{ .daokeqiandao{
background-image: url(${getImageUrl(`/images/qiandao/daoke.png`)}); background-image: url(${getImageUrl(`images/qiandao/daoke.png`)});
} }
.kuangkeqiandao{ .kuangkeqiandao{
background-image: url(${getImageUrl(`/images/qiandao/kuangke.png`)}); background-image: url(${getImageUrl(`images/qiandao/kuangke.png`)});
} }
.qingjiaqiandao{ .qingjiaqiandao{
background-image: url(${getImageUrl(`/images/qiandao/qingjia.png`)}); background-image: url(${getImageUrl(`images/qiandao/qingjia.png`)});
} }
` `
} }

@ -35,31 +35,36 @@ class Signedinlist extends Component {
} }
componentDidMount() { componentDidMount() {
let {attendanceslist}=this.state;
if(this.props.headdata){
let listattendanceslist=attendanceslist;
if(this.props.headdata.course_groups){
if(this.props.headdata.course_groups.length>0){
this.props.headdata.course_groups.map((item,key)=>{
listattendanceslist.push(item)
})
}
}
this.setState({
listattendanceslist:listattendanceslist,
data:this.props.headdata,
course_members_count:this.props.headdata.all_count,
attendance_count:this.props.headdata.normal_count
})
}
this.getdatas(this.props&&this.props.switattendance_id,1,[],undefined) this.getdatas(this.props&&this.props.switattendance_id,1,[],undefined)
// this.getpath() // this.getpath()
} }
componentDidUpdate(prevProps, prevState) {
if(prevProps.headdata!=this.props.headdata){
console.log(this.props.headdata)
let {attendanceslist}=this.state;
if(this.props.headdata){
let listattendanceslist=attendanceslist;
if(this.props.headdata.course_groups){
if(this.props.headdata.course_groups.length>0){
this.props.headdata.course_groups.map((item,key)=>{
listattendanceslist.push(item)
})
}
}
this.setState({
listattendanceslist:listattendanceslist,
data:this.props.headdata,
course_members_count:this.props.headdata.all_count,
attendance_count:this.props.headdata.normal_count
})
}
}
}
getdatas=(id,page,group_ids,attendance_status)=>{ getdatas=(id,page,group_ids,attendance_status)=>{
this.setState({ this.setState({
loading:true, loading:true,

Loading…
Cancel
Save