|
|
|
@ -1,17 +1,15 @@
|
|
|
|
|
import React,{ Component } from "react";
|
|
|
|
|
import React, {Component} from "react";
|
|
|
|
|
import '../css/signincdi.css';
|
|
|
|
|
import { Progress } from 'antd';
|
|
|
|
|
import {Progress} from 'antd';
|
|
|
|
|
import axios from 'axios';
|
|
|
|
|
|
|
|
|
|
//条目
|
|
|
|
|
class Teacherentry extends Component{
|
|
|
|
|
class Teacherentry extends Component {
|
|
|
|
|
//条目组件
|
|
|
|
|
constructor(props){
|
|
|
|
|
constructor(props) {
|
|
|
|
|
super(props);
|
|
|
|
|
|
|
|
|
|
this.state={
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
this.state = {}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidMount() {
|
|
|
|
@ -24,110 +22,126 @@ class Teacherentry extends Component{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
render(){
|
|
|
|
|
let isAdmin =this.props.isAdmin();
|
|
|
|
|
let item= this.props.item;
|
|
|
|
|
render() {
|
|
|
|
|
let isAdmin = this.props.isAdmin();
|
|
|
|
|
let item = this.props.item;
|
|
|
|
|
let index =this.props.index;
|
|
|
|
|
let jdt;
|
|
|
|
|
try {
|
|
|
|
|
jdt=item.normal_count/item.all_count * 100;
|
|
|
|
|
}catch (e) {
|
|
|
|
|
jdt=100;
|
|
|
|
|
jdt = item.normal_count / item.all_count * 100;
|
|
|
|
|
} catch (e) {
|
|
|
|
|
jdt = 100;
|
|
|
|
|
}
|
|
|
|
|
console.log(jdt);
|
|
|
|
|
return(
|
|
|
|
|
return (
|
|
|
|
|
<React.Fragment>
|
|
|
|
|
<div className="ws100s edu-back-white " >
|
|
|
|
|
<div className={index===0?"ws100s edu-back-white ": "ws100s edu-back-white mt20"}>
|
|
|
|
|
<div className="ws100s teacherentrydiv ">
|
|
|
|
|
<p className="ws100s teachedivp ymaxnamewidthdivp">
|
|
|
|
|
{
|
|
|
|
|
item.name
|
|
|
|
|
}
|
|
|
|
|
<p className="ws100s teachedivp ymaxnamewidthdivp">
|
|
|
|
|
{
|
|
|
|
|
item.name
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
</p>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<div className="ws100s sortinxdirection mt17">
|
|
|
|
|
<div className="teachedivps">
|
|
|
|
|
签到人数:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="ws100s sortinxdirection mt17">
|
|
|
|
|
<div className="teachedivps">
|
|
|
|
|
签到人数:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="progressivps">
|
|
|
|
|
<Progress percent={jdt} showInfo={false} strokeColor="#1890ff" />
|
|
|
|
|
<Progress percent={jdt} showInfo={false} strokeColor="#1890ff"/>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="progressivpss">
|
|
|
|
|
已签到{item.normal_count?item.normal_count:0} / 应签到 {item.all_count?item.all_count:0}
|
|
|
|
|
已签到{item.normal_count ? item.normal_count : 0} / 应签到 {item.all_count ? item.all_count : 0}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div className="ws100s sortinxdirection mt5">
|
|
|
|
|
<div className="ws100s sortinxdirection mt5">
|
|
|
|
|
<div className="ws80s sortinxdirection">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div className="teachedivps h40s">
|
|
|
|
|
签到发起人:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivpsy ymaxnamewidth60 h40s">
|
|
|
|
|
{item.author.user_name}
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivps h40s">
|
|
|
|
|
签到发起人:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivpsy ymaxnamewidth60 h40s">
|
|
|
|
|
{item.author.user_name}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="teachedivps ml20 h40s">
|
|
|
|
|
签到方式:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivpsy ymaxnamewidth80 h40s">
|
|
|
|
|
{item.mode?
|
|
|
|
|
item.mode==="QRCODE"?
|
|
|
|
|
<div className="teachedivps ml20 h40s">
|
|
|
|
|
签到方式:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivpsy ymaxnamewidth80 h40s">
|
|
|
|
|
{item.mode ?
|
|
|
|
|
item.mode === "QRCODE" ?
|
|
|
|
|
"二维码签到"
|
|
|
|
|
:item.mode==="NUMBER"?
|
|
|
|
|
"数字签到"
|
|
|
|
|
:item.mode==="QUICK"?
|
|
|
|
|
"快捷签到"
|
|
|
|
|
:""
|
|
|
|
|
:""}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="teachedivps ml20 h40s">
|
|
|
|
|
开始结束时间:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivpsy h40s">
|
|
|
|
|
{item.attendance_date} {item.start_time}-{item.end_time}
|
|
|
|
|
</div>
|
|
|
|
|
: item.mode === "NUMBER" ?
|
|
|
|
|
"数字签到"
|
|
|
|
|
: item.mode === "QUICK" ?
|
|
|
|
|
"快捷签到"
|
|
|
|
|
: ""
|
|
|
|
|
: ""}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="teachedivps ml20 h40s">
|
|
|
|
|
开始结束时间:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="teachedivpsy h40s">
|
|
|
|
|
{item.attendance_date} {item.start_time}-{item.end_time}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="ws20s sortinxdirection">
|
|
|
|
|
{
|
|
|
|
|
isAdmin===true?
|
|
|
|
|
this.props.defaultActiveKey==="1"?
|
|
|
|
|
<div className="ws100s xaxisreverseorder">
|
|
|
|
|
<div className="jiezhis h40s">截止</div>
|
|
|
|
|
<div className="shanchu h40s">删除</div>
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
isAdmin === true ?
|
|
|
|
|
this.props.defaultActiveKey === "1" ?
|
|
|
|
|
<div className="ws100s xaxisreverseorder">
|
|
|
|
|
<div className="jiezhis h40s">编辑</div>
|
|
|
|
|
<div className="shanchu h40s">删除</div>
|
|
|
|
|
<div className="jiezhis h40s xiaoshou" onClick={()=>this.props.thisEnd(item.id)}>截止</div>
|
|
|
|
|
<div className="shanchu h40s xiaoshou" onClick={()=>this.props.thisdelete(item.id)}>删除</div>
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
item.edit_auth === true ?
|
|
|
|
|
<div className="ws100s xaxisreverseorder">
|
|
|
|
|
<div className="jiezhis h40s xiaoshou">编辑</div>
|
|
|
|
|
<div className="shanchu h40s xiaoshou" onClick={()=>this.props.thisdelete(item.id)}>删除</div>
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
<div className="ws100s xaxisreverseorder">
|
|
|
|
|
<div className="jiezhis h40s color-reds xiaoshou" onClick={()=>this.props.thisdelete(item.id)}>删除</div>
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
(
|
|
|
|
|
this.props.defaultActiveKey==="1"?
|
|
|
|
|
this.props.defaultActiveKey === "1" ?
|
|
|
|
|
<div className="ws100s xaxisreverseorder">
|
|
|
|
|
|
|
|
|
|
<div className="qiandaobutton xiaoshou">
|
|
|
|
|
签到
|
|
|
|
|
</div>
|
|
|
|
|
<div className="qiandaobutton xiaoshou">
|
|
|
|
|
签到
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
<div className="ws100s xaxisreverseorder">
|
|
|
|
|
{/*<div className="zcqiandao xiaoshou">*/}
|
|
|
|
|
{/* 正常签到*/}
|
|
|
|
|
{/*</div>*/}
|
|
|
|
|
{
|
|
|
|
|
item.attendance_status?
|
|
|
|
|
item.attendance_status === "NORMAL" ?
|
|
|
|
|
<div className="zcqiandao xiaoshou">
|
|
|
|
|
正常签到
|
|
|
|
|
</div>
|
|
|
|
|
: item.attendance_status === "LEAVE" ?
|
|
|
|
|
<div className="qjqiandao xiaoshou">
|
|
|
|
|
请假
|
|
|
|
|
</div>
|
|
|
|
|
: item.attendance_status === "ABSENCE" ?
|
|
|
|
|
<div className="kkqiandao xiaoshou">
|
|
|
|
|
旷课
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
""
|
|
|
|
|
:
|
|
|
|
|
""
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{/*<div className="qjqiandao xiaoshou">*/}
|
|
|
|
|
{/* 请假*/}
|
|
|
|
|
{/*</div>*/}
|
|
|
|
|
|
|
|
|
|
<div className="kkqiandao xiaoshou">
|
|
|
|
|
旷课
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
@ -142,4 +156,5 @@ class Teacherentry extends Component{
|
|
|
|
|
)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default Teacherentry;
|
|
|
|
|