|
|
|
@ -23,12 +23,12 @@ class Signedinlist extends Component {
|
|
|
|
|
{id:undefined,name:"全部状态"},
|
|
|
|
|
{id:"NORMAL",name:"正常签到"},
|
|
|
|
|
{id:"LEAVE",name:"请 假"},
|
|
|
|
|
{id:"ABSENCE",name:"旷 课"},
|
|
|
|
|
{id:"ABSENCE",name:this.props.defaultActiveKey ==="2"?"旷 课":"未签到"},
|
|
|
|
|
],
|
|
|
|
|
newstate:[
|
|
|
|
|
{id:"NORMAL",name:"正常签到"},
|
|
|
|
|
{id:"LEAVE",name:"请 假"},
|
|
|
|
|
{id:"ABSENCE",name:"旷 课"},
|
|
|
|
|
{id:"ABSENCE",name:this.props.defaultActiveKey ==="2"?"旷 课":"未签到"},
|
|
|
|
|
],
|
|
|
|
|
course_members_count:'--',
|
|
|
|
|
attendance_count:'--',
|
|
|
|
@ -36,8 +36,6 @@ class Signedinlist extends Component {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidMount() {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.getdatas(this.props&&this.props.switattendance_id,1,[],undefined)
|
|
|
|
|
// this.getpath()
|
|
|
|
|
}
|
|
|
|
@ -161,7 +159,6 @@ class Signedinlist extends Component {
|
|
|
|
|
}
|
|
|
|
|
handleChangestate=(value)=>{
|
|
|
|
|
let neval
|
|
|
|
|
|
|
|
|
|
if(!value){
|
|
|
|
|
neval=undefined
|
|
|
|
|
this.setState({
|
|
|
|
@ -214,6 +211,7 @@ class Signedinlist extends Component {
|
|
|
|
|
this.setState({
|
|
|
|
|
member_attendances:newmember_attendances
|
|
|
|
|
})
|
|
|
|
|
this.props.mygetdatas()
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
.catch(function (error) {
|
|
|
|
@ -264,14 +262,14 @@ class Signedinlist extends Component {
|
|
|
|
|
<span>
|
|
|
|
|
<Select key={record.index} defaultValue={record.attendance_status}
|
|
|
|
|
// className={"Signedinlistbox"}
|
|
|
|
|
className={record.attendance_status==="NORMAL"?"color26C7C9 Signedinlistbox sginboxcolor26C7C9":record.attendance_status==="LEAVE"?"colorEAAE4E Signedinlistbox sginboxcolorEAAE4E":record.attendance_status==="ABSENCE"?"colorFF835C Signedinlistbox sginboxcolorFF835C":"Signedinlistbox"}
|
|
|
|
|
className={record.attendance_status==="NORMAL"?"color26C7C9 Signedinlistbox sginboxcolor26C7C9":record.attendance_status==="LEAVE"?"colorEAAE4E Signedinlistbox sginboxcolorEAAE4E":record.attendance_status==="ABSENCE"?this.props.defaultActiveKey==="2"?"colorFF835C Signedinlistbox sginboxcolorFF835C":"color909399 Signedinlistbox sginboxcolor909399":"Signedinlistbox"}
|
|
|
|
|
|
|
|
|
|
style={{ width: 167 }} onChange={(e)=>this.handleChange(e,record.user_id)}>
|
|
|
|
|
{
|
|
|
|
|
newstate&&newstate.map((item,key)=>{
|
|
|
|
|
return(
|
|
|
|
|
<Option value={item.id} key={key}
|
|
|
|
|
className={item.name==="正常签到"?"color26C7C9 sginbox":item.name==="请 假"?"colorEAAE4E sginbox":item.name==="旷 课"?"colorFF835C sginbox":""}>{item.name}</Option>
|
|
|
|
|
className={item.name==="正常签到"?"color26C7C9 sginbox":item.name==="请 假"?"colorEAAE4E sginbox":item.name==="旷 课"?"colorFF835C sginbox": item.name ==="未签到"?"color909399 sginbox":""}>{item.name}</Option>
|
|
|
|
|
)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|