hjm 6 years ago
commit bac2d56ff1

@ -4,6 +4,7 @@ import axios from 'axios';
import { requestProxy } from "./indexEduplus2RequestProxy";
import { broadcastChannelOnmessage } from 'educoder'
import { notification } from 'antd';
import './index.css'
broadcastChannelOnmessage('refreshPage', () => {
window.location.reload()
})
@ -30,7 +31,7 @@ export function initAxiosInterceptors(props) {
// proxy = "http://testbdweb.trustie.net"
// proxy = "http://testbdweb.educoder.net"
proxy = "https://testeduplus2.educoder.net"
// proxy="http://47.96.87.25:48080"
// 在这里使用requestMap控制避免用户通过双击等操作发出重复的请求
// 如果需要支持重复的请求考虑config里面自定义一个allowRepeat参考来控制
@ -114,6 +115,9 @@ export function initAxiosInterceptors(props) {
notification.open({
message:"提示",
description: response.data.message || '服务器异常,请联系管理员。',
style: {
zIndex: 99999999
},
});
// notification['error']({
// message:"提示",

File diff suppressed because it is too large Load Diff

@ -33,4 +33,7 @@ body {
}
.anticon anticon-paper-clip{
color: #29bd8b !important;
}
.notificationmystyle{
z-index: 99999999;
}

@ -48,16 +48,25 @@ class CoursesBanner extends Component {
isRenders:false,
showTrial:false,
}
console.log("CoursesBanner");
console.log("48");
console.log(props);
}
componentDidMount() {
this.updatabanner()
this.setState({
user_phone_binded :this.props.user_phone_binded,
})
this.onloadupdatabanner()
try {
if(this.props.current_user!==undefined){
this.setState({
user_phone_binded :this.props.current_user.user_phone_binded,
})
}
}catch (e) {
console.log("CoursesBanner 60")
console.log(e)
}
}
onloadupdatabanner=()=>{
this.updatabanner()
}
updatabanner=()=>{
let courseId = this.props.match.params.coursesId;
let url = "/courses/" + courseId + "/top_banner.json"
@ -77,6 +86,8 @@ class CoursesBanner extends Component {
})
}
}else{
this.onloadupdatabanner()
}
})
}
@ -333,7 +344,16 @@ class CoursesBanner extends Component {
render() {
let { Addcoursestypes, coursedata, modalsType, modalsTopval, loadtype,modalsBottomval,antIcon,user_phone_binded} = this.state;
try {
if(this.props.current_user!==undefined){
this.setState({
user_phone_binded :this.props.current_user.user_phone_binded,
})
}
}catch (e) {
console.log("CoursesBanner 354")
console.log(e)
}
return (
<div>
<Trialapplication {...this.state} user_phone_binded={user_phone_binded} ></Trialapplication>

@ -1,163 +1,170 @@
import React,{ Component } from "react";
import { WordsBtn } from 'educoder';
import {Tooltip,message,Modal} from 'antd';
import {Link} from 'react-router-dom';
import axios from 'axios';
import Modals from '../../modals/Modals';
class Startshixuntask extends Component{
constructor(props){
super(props);
this.state = {
startbtn:false
}
}
componentDidMount() {
}
taskoperationId=(list)=>{
this.setState({
startbtn:true,
})
let url= list+".json";
axios.get(url).then((response) => {
if(response.status===200){
if(response.data.status===-2){
this.setState({
startbtn:false,
shixunsreplace:true,
hidestartshixunsreplacevalue:response.data.message+".json"
})
}else if(response.data.status===-1){
console.log(response)
}else if(response.data.status===-3){
this.setState({
shixunsmessage:response.data.message,
startshixunCombattype:true,
startbtn:false
})
}else{
if(response.data.status!=401&&response.data.status!=403){
window.location.href = "/tasks/"+response.data.game_identifier;
}
}
}
}).catch((error) => {
this.setState({
startbtn:false
})
});
}
hidestartshixunsreplace=(url)=>{
axios.get(url).then((response) => {
if(response.status===200){
this.setState({
shixunsreplace:false
})
message.success('重置成功,正在进入实训!');
let path="/shixuns/"+response.data.shixun_identifier+"/challenges";
this.props.history.push(path);
}}
).catch((error) => {
this.setState({
startbtn:false,
shixunsreplace:false
})
});
}
hidestartshixunCombattype=()=>{
this.setState({
startshixunCombattype:false
})
}
render(){
let {
Modalstype,
Modalstopval,
Modalsbottomval,
cardsModalcancel,
cardsModalsavetype,
loadtype,
shixunsreplace,
hidestartshixunsreplacevalue,
startshixunCombattype,
shixunsmessage,
startbtn
} = this.state;
return(
<a className="fr color-blue font-16" >
<Modals
modalsType={Modalstype}
modalsTopval={Modalstopval}
modalsBottomval={Modalsbottomval}
modalCancel={cardsModalcancel}
modalSave={cardsModalsavetype}
loadtype={loadtype}
/>
<Modal
title="提示"
visible={shixunsreplace}
closable={false}
footer={null}
keyboard={false}
>
<div className="task-popup-content">
<p className="task-popup-text-center font-16 pb20">实训已经更新了正在为您重置!</p>
</div>
<div className="task-popup-submit clearfix">
<a className="task-btn task-btn-orange fr mr51"
onClick={() => this.hidestartshixunsreplace(hidestartshixunsreplacevalue)}>知道了</a>
</div>
</Modal>
<Modal
title="提示"
visible={startshixunCombattype}
closable={false}
footer={null}
keyboard={false}
>
<div className="task-popup-content">
<p className="task-popup-text-center font-16 pb20">本实训的开启时间{shixunsmessage} <br/>开启时间之前不能挑战
</p>
</div>
<div className="task-popup-submit clearfix">
{/*<a onClick={this.hidestartshixunCombattype} className="task-btn fl">取消</a>*/}
<a className="task-btn task-btn-orange fr mr51" onClick={this.hidestartshixunCombattype}>知道啦</a>
</div>
{/*<p className="inviteTipbtn with100 fl">*/}
{/*<a onClick={this.hidestartshixunCombattype}>知道了</a>*/}
{/*</p>*/}
</Modal>
{this.props.isStudent?
<span>
{this.props.data.task_operation&&this.props.data.task_operation?startbtn===false?<span onClick={()=>this.taskoperationId( this.props.data.task_operation[1])}>
{this.props.data.task_operation[0]}
</span>:"":""}
</span>:""
}
</a>
)
}
}
import React,{ Component } from "react";
import { WordsBtn } from 'educoder';
import {Tooltip,message,Modal,Spin} from 'antd';
import {Link} from 'react-router-dom';
import axios from 'axios';
import Modals from '../../modals/Modals';
class Startshixuntask extends Component{
constructor(props){
super(props);
this.state = {
startbtn:false,
isSpin:false,
}
}
componentDidMount() {
}
taskoperationId=(list)=>{
this.setState({
startbtn:true,
})
let url= list+".json";
axios.get(url).then((response) => {
if(response.status===200){
if(response.data.status===-2){
this.setState({
startbtn:false,
shixunsreplace:true,
hidestartshixunsreplacevalue:response.data.message+".json"
})
}else if(response.data.status===-1){
console.log(response)
}else if(response.data.status===-3){
this.setState({
shixunsmessage:response.data.message,
startshixunCombattype:true,
startbtn:false
})
}else{
if(response.data.status!=401&&response.data.status!=403){
window.location.href = "/tasks/"+response.data.game_identifier;
}
}
}
}).catch((error) => {
this.setState({
startbtn:false
})
});
}
hidestartshixunsreplace=(url)=>{
this.setState({
isSpin:true
})
axios.get(url).then((response) => {
if(response.status===200){
this.setState({
shixunsreplace:false,
isSpin:false,
})
message.success('重置成功,正在进入实训!');
let path="/shixuns/"+response.data.shixun_identifier+"/challenges";
this.props.history.push(path);
}}
).catch((error) => {
this.setState({
startbtn:false,
shixunsreplace:false,
isSpin:false,
})
});
}
hidestartshixunCombattype=()=>{
this.setState({
startshixunCombattype:false
})
}
render(){
let {
Modalstype,
Modalstopval,
Modalsbottomval,
cardsModalcancel,
cardsModalsavetype,
loadtype,
shixunsreplace,
hidestartshixunsreplacevalue,
startshixunCombattype,
shixunsmessage,
startbtn
} = this.state;
return(
<a className="fr color-blue font-16" >
<Modals
modalsType={Modalstype}
modalsTopval={Modalstopval}
modalsBottomval={Modalsbottomval}
modalCancel={cardsModalcancel}
modalSave={cardsModalsavetype}
loadtype={loadtype}
/>
<Modal
title="提示"
visible={shixunsreplace}
closable={false}
footer={null}
keyboard={false}
>
<Spin size="large" spinning={isSpin}>
<div className="task-popup-content">
<p className="task-popup-text-center font-16 pb20">实训已经更新了正在为您重置!</p>
</div>
<div className="task-popup-submit clearfix">
<a className="task-btn task-btn-orange fr mr51"
onClick={() => this.hidestartshixunsreplace(hidestartshixunsreplacevalue)}>知道了</a>
</div>
</Spin>
</Modal>
<Modal
title="提示"
visible={startshixunCombattype}
closable={false}
footer={null}
keyboard={false}
>
<div className="task-popup-content">
<p className="task-popup-text-center font-16 pb20">本实训的开启时间{shixunsmessage} <br/>开启时间之前不能挑战
</p>
</div>
<div className="task-popup-submit clearfix">
{/*<a onClick={this.hidestartshixunCombattype} className="task-btn fl">取消</a>*/}
<a className="task-btn task-btn-orange fr mr51" onClick={this.hidestartshixunCombattype}>知道啦</a>
</div>
{/*<p className="inviteTipbtn with100 fl">*/}
{/*<a onClick={this.hidestartshixunCombattype}>知道了</a>*/}
{/*</p>*/}
</Modal>
{this.props.isStudent?
<span>
{this.props.data.task_operation&&this.props.data.task_operation?startbtn===false?<span onClick={()=>this.taskoperationId( this.props.data.task_operation[1])}>
{this.props.data.task_operation[0]}
</span>:"":""}
</span>:""
}
</a>
)
}
}
export default Startshixuntask;

@ -2030,7 +2030,7 @@ class Studentshavecompletedthelist extends Component {
//===0 不包括主观题
if (indexi === exercise_users.length) {
//都没评论 不显示评论
if (response.data.poll_types.groups_count > 0) {
if (response.data.exercise_types.groups_count > 0) {
// console.log("77771111111");
//分班大于0显示分班
//7ge
@ -2273,7 +2273,7 @@ class Studentshavecompletedthelist extends Component {
} else {
//已经评论
// response.data.course_groups.length
if (response.data.poll_types.groups_count > 0) {
if (response.data.exercise_types.groups_count > 0) {
//显示分班
//8ge
this.setState({
@ -2546,7 +2546,7 @@ class Studentshavecompletedthelist extends Component {
//包括主观题
if (indexi === exercise_users.length) {
console.log("2548包含主观题不包含分班");
if (response.data.poll_types.groups_count> 0){
if (response.data.exercise_types.groups_count> 0){
this.setState({
data: datalist,
teacherlist: teacherlist,
@ -2837,7 +2837,7 @@ class Studentshavecompletedthelist extends Component {
}
} else {
console.log("2699包含主观题包含分班");
if (response.data.poll_types.groups_count> 0) {
if (response.data.exercise_types.groups_count> 0) {
this.setState({
data: datalist,
teacherlist: teacherlist,

@ -1,5 +1,5 @@
import React,{Component} from "React";
import { Form, Select, Input, Button,Checkbox,Upload,Icon,message,Modal,Spin} from "antd";
import { Form, Select, Input, Button,Checkbox,Upload,Icon,message,Modal,Spin,Tooltip} from "antd";
import {Link} from 'react-router-dom';
import TPMMDEditor from '../../../tpm/challengesnew/TPMMDEditor';
import { WordsBtn,getUrl } from 'educoder';
@ -571,7 +571,7 @@ class GraduationTasksSubmitedit extends Component{
<div className={"fl ml20"}>成员要求25</div>
<Search
className={"fl mt5 ml20"}
style={{width:"20%"}}
style={{width:"270px"}}
placeholder="请输入姓名或学号搜索"
id="subject_search_input"
value={search}
@ -581,26 +581,54 @@ class GraduationTasksSubmitedit extends Component{
></Search>
</div>
<style>{`
.fonthidden{
overflow:hidden;
text-overflow:ellipsis;
white-space:nowrap
}
.width87{
width: 87px;
height: 24px;
}
img.edu-nodata-img {
width: 200px;
margin: 50px 90px 20px;
display: block;
}
`}</style>
</Form.Item>
<div className={"ml20"} style={{width:"100%"}}>
<div className={"ml20 mt10"} style={{width:"100%"}}>
<div className={"members fl"}
onScroll={this.contentViewScroll}>
<CheckboxGroup value={task_status} onChange={this.funtaskstatus} style={{ paddingTop: '4px'}}>
{memberslist&&memberslist.members.map((item,key)=>{
{memberslist===undefined?"":memberslist.members.length===0? <div className="square-list clearfix">
<div className="edu-tab-con-box clearfix edu-txt-center">
<img className="edu-nodata-img mb20" src={getImageUrl("images/educoder/nodata.png")}/>
<p className="edu-nodata-p mb20">未找到包含{search}的学生</p>
</div>
</div>:memberslist&&memberslist.members.map((item,key)=>{
return(
<div key={key} style={{
width: '375px',
height: '30px'
}}>
<Checkbox value={item.user_id} checked={parseInt(task_status[key])===item.user_id?true:false} disabled={item.commit_status===true?true:false} className="fl "></Checkbox>
<div className={"fl ml5"} style={{width: '70px'}}>{item.user_name}</div>
<div className={"fl ml40 color-grey-9"}>{item.group_name}</div>
<div className={"fl ml40 color-grey-9"}>{item.student_id}</div>
<div className={"fl ml40"}>{item.commit_status===true?<span className={"color-orange"}>已提交</span> :""}</div>
<Checkbox value={item.user_id}
checked={
task_status.map((item,key)=>{
return parseInt(task_status[key])===item.user_id?true:false
})
}
disabled={item.commit_status===true?true:false} className="fl "></Checkbox>
<Tooltip placement="bottom" title={item.user_name}>
<div className={"fl ml5 fonthidden width87"} style={{width: '70px'}}>{item.user_name}</div>
</Tooltip>
<div className={"fl ml5 fonthidden width87 color-grey-9"} style={{width: '70px'}}>{item.group_name}</div>
<div className={"fl ml5 color-grey-9 fonthidden width87"} style={{width: '70px'}}>{item.student_id}</div>
<div className={"fl ml20"}>{item.commit_status===false?<span className={"color-orange"}>已提交</span> :""}</div>
</div>
)
})}
@ -622,10 +650,12 @@ class GraduationTasksSubmitedit extends Component{
height: '30px',
display:item.user_name===undefined?"none":""
}}>
<div className={"fl ml5"} style={{width: '50px'}}>{item.user_name}</div>
<div className={"fl ml40 color-grey-9"}>{item.group_name}</div>
<div className={"fl ml40 color-grey-9"}>{item.student_id}</div>
{key>0?<div className={"fr"}><i className={"iconfont icon-shanchudiao fl "} style={{marginTop:'-4px'}} onClick={()=>this.delecttask_status(item.user_id)}></i></div>:""}
<Tooltip placement="bottom" title={item.user_name}>
<div className={"fl ml5 fonthidden width87"} style={{width: '50px'}}>{item.user_name}</div>
</Tooltip>
<div className={"fl ml5 fonthidden width87 color-grey-9"}>{item.group_name}</div>
<div className={"fl ml5 color-grey-9 fonthidden width87"}>{item.student_id}</div>
{key>0?<div className={"fl ml20"}><i className={"iconfont icon-shanchudiao fl "} style={{marginTop:'-4px'}} onClick={()=>this.delecttask_status(item.user_id)}></i></div>:""}
</div>
)
})}

@ -2,7 +2,7 @@ import React,{Component} from "React";
import { Form, Select, Input, Button,Checkbox,Upload,Icon,message,Modal,Tooltip,Spin} from "antd";
import {Link} from 'react-router-dom';
import TPMMDEditor from '../../../tpm/challengesnew/TPMMDEditor';
import { WordsBtn,getUrl } from 'educoder';
import { WordsBtn,getUrl,getImageUrl} from 'educoder';
import axios from 'axios';
import Modals from '../../../modals/Modals';
const Search = Input.Search;
@ -367,7 +367,6 @@ class GraduationTasksSubmitnew extends Component{
let newlist =memberslist.members;
let newcheckedValues=checkedValues;
let selects=[];
selects.push(selectobjct)
for(var i=0; i<newlist.length; i++){
for(var z=0; z<newcheckedValues.length; z++){
@ -392,6 +391,7 @@ class GraduationTasksSubmitnew extends Component{
let selects=selectmemberslist;
for(var i=0; i<newlist.length; i++){
if(newlist[i]===id){
newlist.splice(i,1)
}
@ -402,6 +402,7 @@ class GraduationTasksSubmitnew extends Component{
selects.splice(z,1)
}
}
this.setState({
task_status:newlist,
selectmemberslist:selects
@ -537,7 +538,7 @@ render(){
<div className={"fl ml20"}>成员要求25</div>
<Search
className={"fl mt5 ml20"}
style={{width:"20%"}}
style={{width:"270px"}}
placeholder="请输入姓名或学号搜索"
id="subject_search_input"
value={search}
@ -556,6 +557,15 @@ render(){
text-overflow:ellipsis;
white-space:nowrap
}
.width87{
width: 87px;
height: 24px;
}
img.edu-nodata-img {
width: 200px;
margin: 50px 90px 20px;
display: block;
}
`}</style>
<div className={"ml20"} style={{width:"100%"}}>
@ -563,17 +573,31 @@ render(){
<div className={"members fl"}
onScroll={this.contentViewScroll}>
<CheckboxGroup value={task_status} onChange={this.funtaskstatus} style={{ paddingTop: '4px'}}>
{memberslist&&memberslist.members.map((item,key)=>{
{memberslist===undefined?"":memberslist.members.length===0?
<div className="square-list clearfix">
<div className="edu-tab-con-box clearfix edu-txt-center">
<img className="edu-nodata-img mb20" src={getImageUrl("images/educoder/nodata.png")}/>
<p className="edu-nodata-p mb20">未找到包含{search}的学生</p>
</div>
</div>:memberslist&&memberslist.members.map((item,key)=>{
return(
<div key={key} style={{
width: '375px',
height: '30px'
}}>
<Checkbox value={item.user_id} checked={parseInt(task_status[key])===item.user_id?true:false} disabled={item.commit_status===true?true:false} className="fl "></Checkbox>
<Tooltip placement="bottom" title={item.user_nam}><div className={"fl ml5 fonthidden"} style={{width: '70px'}}>{item.user_name}</div></Tooltip>
<div className={"fl ml40 color-grey-9"}>{item.group_name}</div>
<div className={"fl ml40 color-grey-9"}>{item.student_id}</div>
<div className={"fl ml40"}>{item.commit_status===true?<span className={"color-orange"}>已提交</span> :""}</div>
<Checkbox value={item.user_id} checked={
task_status.map((item,key)=>{
return parseInt(task_status[key])===item.user_id?true:false
})
}
disabled={item.commit_status===true?true:false} className="fl "></Checkbox>
<Tooltip placement="bottom" title={item.user_name}>
<div className={"fl ml5 fonthidden width87"}>{item.user_name}</div>
</Tooltip>
<div className={"fl ml5 fonthidden width87 color-grey-9"} title={item.group_name}>{item.group_name}</div>
<div className={"fl ml5 color-grey-9 fonthidden width87"} title={item.student_id}>{item.student_id}</div>
<div className={"fl ml20"}>{item.commit_status===true?<span className={"color-orange"}>已提交</span> :""}</div>
</div>
)
})}
@ -599,12 +623,13 @@ render(){
height: '30px',
display:item.user_name===undefined?"none":""
}}>
<Tooltip placement="bottom" title={item.user_nam}>
<div className={"fl ml5 fonthidden"} style={{width: '50px'}}>{item.user_name}</div>
<Tooltip placement="bottom" title={item.user_name}>
<div className={"fl ml5 fonthidden width87"}>{item.user_name}</div>
</Tooltip>
<div className={"fl ml40 color-grey-9"}>{item.group_name}</div>
<div className={"fl ml40 color-grey-9"}>{item.student_id}</div>
{key>0?<div className={"fr"}><i className={"iconfont icon-shanchudiao fl "} style={{marginTop:'-4px'}} onClick={()=>this.delecttask_status(item.user_id)}></i></div>:""}
<div className={"fl ml5 fonthidden width87 color-grey-9"}>{item.group_name}</div>
<div className={"fl ml5 color-grey-9 fonthidden width87"}>{item.student_id}</div>
{key>0?<div className={"fl ml20"}><i className={"iconfont icon-shanchudiao fl "} style={{marginTop:'-4px'}} onClick={()=>this.delecttask_status(item.user_id)}></i></div>:""}
</div>
)
})}
@ -627,7 +652,7 @@ render(){
<Form.Item>
<div className="clearfix mt30 mb30">
<Button type="primary" htmlType="submit" className="defalutSubmitbtn fl mr20">提交</Button>
<Button type="primary" htmlType="submit" className="defalutSubmitbtn fl mr20">提交</Button>
<a onClick={this.gocannel} className="defalutCancelbtn fl">取消</a>
</div>
</Form.Item>

@ -94,7 +94,7 @@ class GraduationTaskssettinglist extends Component{
for (var i = 0; i < worklists.length; i++) {
datalist.push({
name: worklists[i].name,
number: (parseInt(page)-1)*parseInt(limit)+(i+1),
number: (parseInt(pages)-1)*parseInt(limit)+(i+1),
stduynumber: worklists[i].student_id,
classroom: worklists[i].class_grouping_name,
grouping: result.data.have_grouping === true ? worklists[i].grouping_name : null,
@ -1545,8 +1545,10 @@ class GraduationTaskssettinglist extends Component{
<div id="graduation_work_list" style={{padding:'0px 40px 10px 40px'}}>
<div className="clearfix">
{this.props.isAdmin()?<span className="fl color-grey-6 font-12"><span className="color-orange-tip">{taskslistdata&&taskslistdata.work_count}</span>{taskslistdata&&taskslistdata.work_count} </span>:""}
{this.props.isAdmin()?<div className="fr color-grey-6 edu-menu-panel">
{this.props.isAdmin()===true?<span className="fl color-grey-6 font-12">
<span className="color-orange-tip">{taskslistdata&&taskslistdata.work_count}</span>
个检索结果{taskslistdata&&taskslistdata.work_count} 学生 </span>:""}
{this.props.isAdmin()===true?<div className="fr color-grey-6 edu-menu-panel">
<p>
<a data-remote="true">
{order==="updated_at"?"更新时间":order==="work_score"?"最终成绩":order==="student_id"?"学生学号":""}排序</a>
@ -1562,6 +1564,24 @@ class GraduationTaskssettinglist extends Component{
</div>:""}
</div>
{this.props.isStudent()===true?
<div className="clearfix">
<span className="mr15 color-grey9">
<span className={"color-orange"}>{taskslistdata&&taskslistdata.commit_count}
</span> </span>
<span className="mr15 color-grey9">
<span className={"color-orange"}>{taskslistdata&&taskslistdata.uncommit_count}
</span> </span>
<Tooltip title={taskslistdata&&taskslistdata.left_time.status} placement="bottom">
<span className="mr15 color-grey9">
{taskslistdata&&taskslistdata.left_time.status} :
<span className={"ml10 color-orange"}>
{taskslistdata&&taskslistdata.left_time.time}</span>
</span>
</Tooltip>
</div>
:""}
</div>
{
@ -1781,24 +1801,49 @@ class GraduationTaskssettinglist extends Component{
<div id="graduation_work_list" style={{ padding: '18px 40px 10px',height: '56px'}}>
<div className="clearfix">
<span className="fl color-grey-6 font-12"><span className="color-orange-tip">{taskslistdata&&taskslistdata.work_count}</span>{taskslistdata&&taskslistdata.work_count} </span>
<div className="fr color-grey-6 edu-menu-panel">
<p><a data-remote="true">
{order==="updated_at"?"时间":order==="work_score"?"成绩":order==="student_id"?"学号":""}排序</a><i
className="iconfont icon-xiajiantou ml5 font-12 color-grey-6"></i></p>
<ul className="edu-menu-list">
<li onClick={(e)=>this.funorder("updated_at")} className={order==="updated_at"?"none":""}><a data-remote="true">时间</a>
</li>
<li onClick={(e)=>this.funorder("work_score" )} className={order==="work_score"?"none":""}><a data-remote="true">成绩</a>
</li>
<li onClick={(e)=>this.funorder("student_id" )} className={order==="student_id"?"none":""}><a data-remote="true">学号</a>
</li>
</ul>
</div>
</div>
{this.props.isAdmin()===true?
<div className="clearfix">
<span className="fl color-grey-6 font-12">
<span className="color-orange-tip">{taskslistdata&&taskslistdata.work_count}</span>
个检索结果{taskslistdata&&taskslistdata.work_count} 学生
</span>
<div className="fr color-grey-6 edu-menu-panel">
<p><a data-remote="true">
{order==="updated_at"?"时间":order==="work_score"?"成绩":order==="student_id"?"学号":""}排序</a><i
className="iconfont icon-xiajiantou ml5 font-12 color-grey-6"></i></p>
<ul className="edu-menu-list">
<li onClick={(e)=>this.funorder("updated_at")} className={order==="updated_at"?"none":""}><a data-remote="true">时间</a>
</li>
<li onClick={(e)=>this.funorder("work_score" )} className={order==="work_score"?"none":""}><a data-remote="true">成绩</a>
</li>
<li onClick={(e)=>this.funorder("student_id" )} className={order==="student_id"?"none":""}><a data-remote="true">学号</a>
</li>
</ul>
</div>
</div>
:""}
{this.props.isStudent()===true?
<div className="clearfix">
<span className="mr15 color-grey9">
<span className={"color-orange"}>{taskslistdata&&taskslistdata.commit_count}
</span> </span>
<span className="mr15 color-grey9">
<span className={"color-orange"}>{taskslistdata&&taskslistdata.uncommit_count}
</span> </span>
<Tooltip title={taskslistdata&&taskslistdata.left_time.status} placement="bottom">
<span className="mr15 color-grey9">
{taskslistdata&&taskslistdata.left_time.status} :
<span className={"ml10 color-orange"}>
{taskslistdata&&taskslistdata.left_time.time}</span>
</span>
</Tooltip>
</div>
:""}
</div>

@ -210,7 +210,7 @@ class ShixunhomeWorkItem extends Component{
</div>
<div className="task-popup-submit clearfix">
<a className="task-btn task-btn-orange fr mr51"
onClick={() => this.hidestartshixunsreplace(hidestartshixunsreplacevalue)}>知道了</a>
onClick={() => this.hidestartshixunsreplace(hidestartshixunsreplacevalue)}>知道了</a>
</div>
</Modal>
<Modal

@ -149,7 +149,7 @@ class EducoderLogin extends Component {
"align-items": "center",
"width": "100%",
}}>
<div style={{"margin-top": "40px","height":"500px"}}>
<div style={{"margin-top": "40px","height":"530px"}}>
<LoginRegisterComponent {...this.props} {...this.state}
Setshowbool={this.Setshowbool} ></LoginRegisterComponent>
@ -163,7 +163,7 @@ class EducoderLogin extends Component {
"align-items": "center",
"width": "100%",
}}>
<div style={{"margin-top": "40px","height":"500px"}}>
<div style={{"margin-top": "40px","height":"530px"}}>
<FindPasswordComponent {...this.props} {...this.state}
Setshowbool={this.Setshowbool}></FindPasswordComponent>
@ -171,13 +171,14 @@ class EducoderLogin extends Component {
</div>
}
<div style={{"height":"250px",
<div style={{"height":"180px",
"display": "flex",
"justify-content": "center",
"align-items": "center",
"width": "100%",
}}>
<div className="font-14 color-grey-9 " style={{marginTop:"15px"}}>© 2019 EduCoder湘ICP备17009477号Trustie & IntelliDE inside.</div>
<div className="font-14 color-grey-9 " style={{marginTop:"15px"}}>© 2019 EduCoder 湘ICP备17009477号 Trustie & IntelliDE inside</div>
</div>
</div>

File diff suppressed because it is too large Load Diff

@ -12,7 +12,7 @@ import {broadcastChannelPostMessage} from 'educoder'
import {Tabs, Input, Checkbox, Button, notification, Menu} from 'antd';
//试用申请页面
//试用申请
class Trialapplication extends Component {
// isRender控制弹出窗口显示
constructor(props) {

@ -1,375 +1,376 @@
.page--header {
z-index: 1399 !important;
}
/* 左右分隔条 */
.b-label {
background: #111c24;
}
.b-label>.resize-helper {
height: 30px;
position: relative;
margin-top: -20px;
margin-left: -17px;
left: 50%;
top: 50%;
z-index: 50;
}
.b-label>.resize-helper button{
width: 24px;
height: 24px;
min-height: 24px;
opacity: 0.7;
}
.b-label>.resize-helper button:hover {
opacity: 1;
}
.b-label>.resize-helper button path {
color: #666666;
fill: currentColor;
}
/* 所有i都加上动画 */
#game_right_contents i {
transition: transform .3s ease;
}
/* */
.h-center {
height: 3px;
background: rgb(17, 28, 36);
border-top: 1px solid rgb(25, 82, 123);
}
/* */
/* codemirror初始化的时候高度没100% */
#codetab_con_1 {
/*display: flex;*/
}
.CodeMirror{
/*height: -webkit-fill-available !important;*/
line-height: 1.2;
/*height: auto !important;
flex: 1 1 auto;*/
}
/* LeftView markdown */
#game_show_content #tab_con_1 .editormd-preview, #game_show_content #tab_con_2 .editormd-preview
,#game_show_content #tab_con_3 .editormd-preview
,#game_show_content #tab_con_5 .editormd-preview {
width: 100% !important;
height: 100% !important;
}
/* tab 样式覆盖 */
#blacktab_nav {
background-color: #111C24;
border-bottom: 1px solid #222C34;
}
.blacktab_hover {
}
.blacktab_hover a:after {
content: '';
position: absolute;
left: 50%;
margin-left: -10px;
top: auto;
bottom: 0;
right: auto;
height: 2px;
width: 20px;
background-color: #29BD8B;
}
button.buttonHoverColor:hover a {
color: #FF7500!important;
}
/*--------------------------------------------------- Header Start */
.leftNavDrawer {
z-index: 8000 !important;
}
.leftNavDrawer>div:nth-child(2) {
/*left:80px !important;*/
z-index: 8000 !important;
top: 54px;
overflow: hidden;
}
.leftNavDrawer .MuiDrawer-paper-2 {
width: 500px;
}
.leftNavDrawer .page--over {
left: 0px;
position: static;
}
.leftNavDrawer .col-width-3 {
position: static;
width: 400px;
border: none;
}
#myshixun_top {
display: flex;
height: 54px;
}
.headerLeft {
flex: 0 0 400px;
}
#user_grade a {
color: white;
}
.-header-right {
right: inherit;
margin-left: 24px;
display: inline-block;
top: 10px;
height: 32px;
padding: 3px 15px
}
.userInfo {
display: inline-block;
top: 4px;
position: relative;
margin-left: 10px;
}
.userInfo img {
border-radius: 18px;
vertical-align: bottom;
}
.userInfo .userInfoName {
margin-left: 12px;
color: #fff;
font-size: 16px;
}
#user_grade {
margin-top: -1px;
}
.headerCenter {
flex: 1 1 auto;
text-align: center;
flex-direction: column;
}
.headerCenter h2 {
max-width: none;
width: 100%;
font-size: 16px;
flex: 0 0 24px;
}
.headerCenter .timeRecord {
font-size: 13px;
color: #CCCCCC;
width: 100px;
margin: auto;
}
.headerRight {
flex: 0 0 400px;
}
.headerRight a {
color: #1A3F5F;
font-size: 16px;
}
.headerRight .exitBtn {
color: #1a3f5f !important;
}
.headerRight a:hover {
color: #4CACFF !important;
}
.headerRight i {
font-size: 24px !important;
margin-right: 8px;
margin-top: 12px;
vertical-align: -4px;
}
/*--------------------------------------------------- Header End */
/* picture_display 样式language_display处理*/
.photo_display {
padding-top: 54px;
padding-left: 0px;
}
.with33{ width: 33%;}
.with49{ width: 49%;}
.mr1precent{margin-right: 1%;}
.mr03precent{margin-right: 0.3%;}
/*TPI输出TXT文件显示*/
.output-txt{padding: 10px;box-shadow:1px 6px 24px rgba(17,28,36,0.2);min-height: 500px;width: 100%;box-sizing: border-box;outline: none;}
/* -------------------------------------- m design 控件样式修改*/
.rootSnackbar {
top: 60px !important;
z-index: 99999999 !important;
}
.rootSnackbar>div>div {
margin: 0 auto;
}
/* Dialog */
#alert-dialog-title>h2 {
text-align: center;
}
#alert-dialog-title {
border-bottom: 1px solid #eee;
margin-bottom: 18px;
}
body>div[role=dialog]>div[role=document]>div:nth-child(3) {
justify-content: center;
}
body>div[role=dialog]>div {
/* tpi dialog按钮改成平铺的大按钮 */
/* padding-bottom: 10px; */
}
/* tpi 窗口宽度*/
body>div[role=dialog] div[role=document] {
min-width: 400px;
}
#alert-dialog-title + div {
text-align: center;
}
body>div>div[role=tooltip] {
font-size: 12px;
}
/* -------------------------------------- m design 控件样式修改 END*/
/*rc-tree样式*/
.repoFilesDrawer .rc-tree li span.rc-tree-checkbox, .rc-tree li span.rc-tree-iconEle, .rc-tree li span.rc-tree-switcher {
background-image:url('../../images/component/rc-tree.png');
}
.rc-tree li span.rc-tree-node-selected .rc-tree-iconEle {
background-image:url('../../images/component/selectFile.png');
background-position: 0;
margin-bottom: 4px;
}
.repoFilesDrawer .rc-tree li span.rc-tree-icon_loading {
margin-right: 2px;
vertical-align: top;
background: url(data:image/gif;base64,R0lGODlhEAAQAKIGAMLY8YSx5HOm4Mjc88/g9Ofw+v///wAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQFCgAGACwAAAAAEAAQAAADMGi6RbUwGjKIXCAA016PgRBElAVlG/RdLOO0X9nK61W39qvqiwz5Ls/rRqrggsdkAgAh+QQFCgAGACwCAAAABwAFAAADD2hqELAmiFBIYY4MAutdCQAh+QQFCgAGACwGAAAABwAFAAADD1hU1kaDOKMYCGAGEeYFCQAh+QQFCgAGACwKAAIABQAHAAADEFhUZjSkKdZqBQG0IELDQAIAIfkEBQoABgAsCgAGAAUABwAAAxBoVlRKgyjmlAIBqCDCzUoCACH5BAUKAAYALAYACgAHAAUAAAMPaGpFtYYMAgJgLogA610JACH5BAUKAAYALAIACgAHAAUAAAMPCAHWFiI4o1ghZZJB5i0JACH5BAUKAAYALAAABgAFAAcAAAMQCAFmIaEp1motpDQySMNFAgA7) no-repeat scroll 0 0 transparent;
}
/*去除选中的颜色*/
.repoFilesDrawer .rc-tree-node-selected {
background-color: #4CACFF;
border: 1px solid #4CACFF;
opacity: 1;
height: 26px !important;
}
.repoFilesDrawer .rc-tree-node-selected span.rc-tree-title {
color: #fff;
}
/*
Name: Railscasts
Author: Ryan Bates (http://railscasts.com)
CodeMirror template by Jan T. Sott (https://github.com/idleberg/base16-codemirror)
Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16)
*/
.cm-s-railscasts.CodeMirror {background: #2b2b2b;color: #f4f1ed;line-height: 21px;}
.cm-s-railscasts div.CodeMirror-selected {background: #214283 !important;}
.cm-s-railscasts .CodeMirror-gutters {/*background: #2b2b2b; */border-right: 0px;}
.cm-s-railscasts .CodeMirror-linenumber {color: #5a647e;}
.cm-s-railscasts .CodeMirror-cursor {border-left: 1px solid #d4cfc9 !important;}
.cm-s-railscasts span.cm-comment {color: #bc9458;}
.cm-s-railscasts span.cm-atom {color: #b6b3eb;}
.cm-s-railscasts span.cm-number {color: #b6b3eb;}
.cm-s-railscasts span.cm-property, .cm-s-railscasts span.cm-attribute {color: #a5c261;}
.cm-s-railscasts span.cm-keyword {color: #da4939;}
.cm-s-railscasts span.cm-string {color: #ffc66d;}
.cm-s-railscasts span.cm-variable {color: #a5c261;}
.cm-s-railscasts span.cm-variable-2 {color: #6d9cbe;}
.cm-s-railscasts span.cm-def {color: #cc7833;}
/*.cm-s-railscasts span.cm-error {background: #da4939; color: #d4cfc9;}*/
.cm-s-railscasts span.cm-bracket {color: #f4f1ed;}
.cm-s-railscasts span.cm-tag {color: #da4939;}
.cm-s-railscasts span.cm-link {color: #b6b3eb;}
.cm-s-railscasts .CodeMirror-matchingbracket { text-decoration: underline; color: white !important;}
.cm-s-railscasts .CodeMirror-activeline-background { background: #303040; }
/* evaluateView*/
.CodeMirror-lines{padding: 0px!important;}
.cm-s-blackboard.CodeMirror {background: #0C1021; color: #F8F8F8; }
.cm-s-blackboard div.CodeMirror-selected { background: #253B76; }
.cm-s-blackboard .CodeMirror-line::selection, .cm-s-blackboard .CodeMirror-line > span::selection, .cm-s-blackboard .CodeMirror-line > span > span::selection { background: rgba(37, 59, 118, .99); }
.cm-s-blackboard .CodeMirror-line::-moz-selection, .cm-s-blackboard .CodeMirror-line > span::-moz-selection, .cm-s-blackboard .CodeMirror-line > span > span::-moz-selection { background: rgba(37, 59, 118, .99); }
.cm-s-blackboard .CodeMirror-gutters { background: #585858; border-right: 0; }
.cm-s-blackboard .CodeMirror-guttermarker { color: #FBDE2D; }
.cm-s-blackboard .CodeMirror-guttermarker-subtle { color: #888; }
.cm-s-blackboard .CodeMirror-linenumber { color: #888;/*background: #585858;*/ }
.cm-s-blackboard .CodeMirror-cursor { border-left: 1px solid #A7A7A7; }
.cm-s-blackboard .cm-keyword { color: #FBDE2D; }
.cm-s-blackboard .cm-atom { color: #D8FA3C; }
.cm-s-blackboard .cm-number { color: #D8FA3C; }
.cm-s-blackboard .cm-def { color: #8DA6CE; }
.cm-s-blackboard .cm-variable { color: #FF6400; }
.cm-s-blackboard .cm-operator { color: #FBDE2D; }
.cm-s-blackboard .cm-comment { color: #AEAEAE; }
.cm-s-blackboard .cm-string { color: #61CE3C; }
.cm-s-blackboard .cm-string-2 { color: #61CE3C; }
.cm-s-blackboard .cm-meta { color: #D8FA3C; }
.cm-s-blackboard .cm-builtin { color: #8DA6CE; }
.cm-s-blackboard .cm-tag { color: #8DA6CE; }
.cm-s-blackboard .cm-attribute { color: #8DA6CE; }
.cm-s-blackboard .cm-header { color: #FF6400; }
.cm-s-blackboard .cm-hr { color: #AEAEAE; }
.cm-s-blackboard .cm-link { color: #8DA6CE; }
.cm-s-blackboard .cm-error { background: #9D1E15; color: #F8F8F8; }
.cm-s-blackboard .CodeMirror-activeline-background { background: #3C3636; }
.cm-s-blackboard .CodeMirror-matchingbracket { outline:1px solid grey;color:white !important; }
.cm-s-railscasts span.cm-error {
color: #bc9458;
}
/* 弹框 */
.popupAll{width: 100%;height: 100%;position: fixed;z-index: 99998;background-color: rgba(5,16,26,0.6);left: 0;top:0;}
.task-popup{ width: 30%;background: #fff; border:1px solid #e8e8e8; border-radius:10px; -webkit-box-shadow:0 0 10px #ccc; -moz-box-shadow:0 0 10px #ccc; box-shadow:0 0 10px #ccc;}
.task-popup-text-center{ text-align: center; color: #333;}
.task-popup-title{ border-bottom: 1px solid #eee; padding:0px 15px;text-align: center;box-sizing: border-box;line-height: 70px;height: 70px; border-radius: 10px 10px 0px 0px;font-size: 16px; }
.task-popup-content{ padding:15px;}
/*注释这个地方是因为会影响到实训哪块合作者删除的样式*/
/*.task-popup-submit{ margin:0px auto 15px; width: 120px;}*/
.task-popup-sure{ margin:0px auto 15px; width: 54px;}
.task-popup-right-sure{margin:0px auto 15px;text-align: center}
.task-popup-OK{ margin:15px auto; text-align: center}
.task-popup-bggrey{ background:#fff; color:#333;}
a.task-btn-orange{background: #4CACFF; color:#fff!important;}
a:hover.task-btn-orange{background: #4CACFF; color:#fff!important;}
/* 代码区域样式 */
#games_repository_contents .readRepoFailed {
color: #fff;
width: 100%;
text-align: center;
margin-top: 120px;
}
#games_repository_contents .readRepoFailed .retry {
color:#4CACFF;
}
.page--header {
z-index: 1399 !important;
}
/* 左右分隔条 */
.b-label {
background: #111c24;
}
.b-label>.resize-helper {
height: 30px;
position: relative;
margin-top: -20px;
margin-left: -17px;
left: 50%;
top: 50%;
z-index: 50;
}
.b-label>.resize-helper button{
width: 24px;
height: 24px;
min-height: 24px;
opacity: 0.7;
}
.b-label>.resize-helper button:hover {
opacity: 1;
}
.b-label>.resize-helper button path {
color: #666666;
fill: currentColor;
}
/* 所有i都加上动画 */
#game_right_contents i {
transition: transform .3s ease;
}
/* */
.h-center {
height: 3px;
background: rgb(17, 28, 36);
border-top: 1px solid rgb(25, 82, 123);
}
/* */
/* codemirror初始化的时候高度没100% */
#codetab_con_1 {
/*display: flex;*/
}
.CodeMirror{
/*height: -webkit-fill-available !important;*/
line-height: 1.2;
/*height: auto !important;
flex: 1 1 auto;*/
}
/* LeftView markdown */
#game_show_content #tab_con_1 .editormd-preview, #game_show_content #tab_con_2 .editormd-preview
,#game_show_content #tab_con_3 .editormd-preview
,#game_show_content #tab_con_5 .editormd-preview {
width: 100% !important;
height: 100% !important;
}
/* tab 样式覆盖 */
#blacktab_nav {
background-color: #111C24;
border-bottom: 1px solid #222C34;
}
.blacktab_hover {
}
.blacktab_hover a:after {
content: '';
position: absolute;
left: 50%;
margin-left: -10px;
top: auto;
bottom: 0;
right: auto;
height: 2px;
width: 20px;
background-color: #29BD8B;
}
button.buttonHoverColor:hover a {
color: #FF7500!important;
}
/*--------------------------------------------------- Header Start */
.leftNavDrawer {
z-index: 8000 !important;
}
.leftNavDrawer>div:nth-child(2) {
/*left:80px !important;*/
z-index: 8000 !important;
top: 54px;
overflow: hidden;
}
.leftNavDrawer .MuiDrawer-paper-2 {
width: 500px;
}
.leftNavDrawer .page--over {
left: 0px;
position: static;
}
.leftNavDrawer .col-width-3 {
position: static;
width: 400px;
border: none;
}
#myshixun_top {
display: flex;
height: 54px;
}
.headerLeft {
flex: 0 0 400px;
}
#user_grade a {
color: white;
}
.-header-right {
right: inherit;
margin-left: 24px;
display: inline-block;
top: 10px;
height: 32px;
padding: 3px 15px
}
.userInfo {
display: inline-block;
top: 4px;
position: relative;
margin-left: 10px;
}
.userInfo img {
border-radius: 18px;
vertical-align: bottom;
}
.userInfo .userInfoName {
margin-left: 12px;
color: #fff;
font-size: 16px;
}
#user_grade {
margin-top: -1px;
}
.headerCenter {
flex: 1 1 auto;
text-align: center;
flex-direction: column;
}
.headerCenter h2 {
max-width: none;
width: 100%;
font-size: 16px;
flex: 0 0 24px;
}
.headerCenter .timeRecord {
font-size: 13px;
color: #CCCCCC;
width: 100px;
margin: auto;
}
.headerRight {
flex: 0 0 400px;
}
.headerRight a {
color: #1A3F5F;
font-size: 16px;
}
.headerRight .exitBtn {
color: #1a3f5f !important;
}
.headerRight a:hover {
color: #4CACFF !important;
}
.headerRight i {
font-size: 24px !important;
margin-right: 8px;
margin-top: 12px;
vertical-align: -4px;
}
/*--------------------------------------------------- Header End */
/* picture_display 样式language_display处理*/
.photo_display {
padding-top: 54px;
padding-left: 0px;
}
.with33{ width: 33%;}
.with49{ width: 49%;}
.mr1precent{margin-right: 1%;}
.mr03precent{margin-right: 0.3%;}
/*TPI输出TXT文件显示*/
.output-txt{padding: 10px;box-shadow:1px 6px 24px rgba(17,28,36,0.2);min-height: 500px;width: 100%;box-sizing: border-box;outline: none;}
/* -------------------------------------- m design 控件样式修改*/
.rootSnackbar {
top: 60px !important;
z-index: 99999999 !important;
}
.rootSnackbar>div>div {
margin: 0 auto;
}
/* Dialog */
#alert-dialog-title>h2 {
text-align: center;
}
#alert-dialog-title {
border-bottom: 1px solid #eee;
margin-bottom: 18px;
}
body>div[role=dialog]>div[role=document]>div:nth-child(3) {
justify-content: center;
}
body>div[role=dialog]>div {
/* tpi dialog按钮改成平铺的大按钮 */
/* padding-bottom: 10px; */
}
/* tpi 窗口宽度*/
body>div[role=dialog] div[role=document] {
min-width: 400px;
}
#alert-dialog-title + div {
text-align: center;
}
body>div>div[role=tooltip] {
font-size: 12px;
}
/* -------------------------------------- m design 控件样式修改 END*/
/*rc-tree样式*/
.repoFilesDrawer .rc-tree li span.rc-tree-checkbox, .rc-tree li span.rc-tree-iconEle, .rc-tree li span.rc-tree-switcher {
background-image:url('../../images/component/rc-tree.png');
}
.rc-tree li span.rc-tree-node-selected .rc-tree-iconEle {
background-image:url('../../images/component/selectFile.png');
background-position: 0;
margin-bottom: 4px;
}
.repoFilesDrawer .rc-tree li span.rc-tree-icon_loading {
margin-right: 2px;
vertical-align: top;
background: url(data:image/gif;base64,R0lGODlhEAAQAKIGAMLY8YSx5HOm4Mjc88/g9Ofw+v///wAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQFCgAGACwAAAAAEAAQAAADMGi6RbUwGjKIXCAA016PgRBElAVlG/RdLOO0X9nK61W39qvqiwz5Ls/rRqrggsdkAgAh+QQFCgAGACwCAAAABwAFAAADD2hqELAmiFBIYY4MAutdCQAh+QQFCgAGACwGAAAABwAFAAADD1hU1kaDOKMYCGAGEeYFCQAh+QQFCgAGACwKAAIABQAHAAADEFhUZjSkKdZqBQG0IELDQAIAIfkEBQoABgAsCgAGAAUABwAAAxBoVlRKgyjmlAIBqCDCzUoCACH5BAUKAAYALAYACgAHAAUAAAMPaGpFtYYMAgJgLogA610JACH5BAUKAAYALAIACgAHAAUAAAMPCAHWFiI4o1ghZZJB5i0JACH5BAUKAAYALAAABgAFAAcAAAMQCAFmIaEp1motpDQySMNFAgA7) no-repeat scroll 0 0 transparent;
}
/*去除选中的颜色*/
.repoFilesDrawer .rc-tree-node-selected {
background-color: #4CACFF;
border: 1px solid #4CACFF;
opacity: 1;
height: 26px !important;
}
.repoFilesDrawer .rc-tree-node-selected span.rc-tree-title {
color: #fff;
}
/*
Name: Railscasts
Author: Ryan Bates (http://railscasts.com)
CodeMirror template by Jan T. Sott (https://github.com/idleberg/base16-codemirror)
Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16)
*/
.cm-s-railscasts.CodeMirror {background: #2b2b2b;color: #f4f1ed;line-height: 21px;}
.cm-s-railscasts div.CodeMirror-selected {background: #214283 !important;}
.cm-s-railscasts .CodeMirror-gutters {/*background: #2b2b2b; */border-right: 0px;}
.cm-s-railscasts .CodeMirror-linenumber {color: #5a647e;}
.cm-s-railscasts .CodeMirror-cursor {border-left: 1px solid #d4cfc9 !important;}
.cm-s-railscasts span.cm-comment {color: #bc9458;}
.cm-s-railscasts span.cm-atom {color: #b6b3eb;}
.cm-s-railscasts span.cm-number {color: #b6b3eb;}
.cm-s-railscasts span.cm-property, .cm-s-railscasts span.cm-attribute {color: #a5c261;}
.cm-s-railscasts span.cm-keyword {color: #da4939;}
.cm-s-railscasts span.cm-string {color: #ffc66d;}
.cm-s-railscasts span.cm-variable {color: #a5c261;}
.cm-s-railscasts span.cm-variable-2 {color: #6d9cbe;}
.cm-s-railscasts span.cm-def {color: #cc7833;}
/*.cm-s-railscasts span.cm-error {background: #da4939; color: #d4cfc9;}*/
.cm-s-railscasts span.cm-bracket {color: #f4f1ed;}
.cm-s-railscasts span.cm-tag {color: #da4939;}
.cm-s-railscasts span.cm-link {color: #b6b3eb;}
.cm-s-railscasts .CodeMirror-matchingbracket { text-decoration: underline; color: white !important;}
.cm-s-railscasts .CodeMirror-activeline-background { background: #303040; }
/* evaluateView*/
.CodeMirror-lines{padding: 0px!important;}
.cm-s-blackboard.CodeMirror {background: #0C1021; color: #F8F8F8; }
.cm-s-blackboard div.CodeMirror-selected { background: #253B76; }
.cm-s-blackboard .CodeMirror-line::selection, .cm-s-blackboard .CodeMirror-line > span::selection, .cm-s-blackboard .CodeMirror-line > span > span::selection { background: rgba(37, 59, 118, .99); }
.cm-s-blackboard .CodeMirror-line::-moz-selection, .cm-s-blackboard .CodeMirror-line > span::-moz-selection, .cm-s-blackboard .CodeMirror-line > span > span::-moz-selection { background: rgba(37, 59, 118, .99); }
.cm-s-blackboard .CodeMirror-gutters { background: #585858; border-right: 0; }
.cm-s-blackboard .CodeMirror-guttermarker { color: #FBDE2D; }
.cm-s-blackboard .CodeMirror-guttermarker-subtle { color: #888; }
.cm-s-blackboard .CodeMirror-linenumber { color: #888;/*background: #585858;*/ }
.cm-s-blackboard .CodeMirror-cursor { border-left: 1px solid #A7A7A7; }
.cm-s-blackboard .cm-keyword { color: #FBDE2D; }
.cm-s-blackboard .cm-atom { color: #D8FA3C; }
.cm-s-blackboard .cm-number { color: #D8FA3C; }
.cm-s-blackboard .cm-def { color: #8DA6CE; }
.cm-s-blackboard .cm-variable { color: #FF6400; }
.cm-s-blackboard .cm-operator { color: #FBDE2D; }
.cm-s-blackboard .cm-comment { color: #AEAEAE; }
.cm-s-blackboard .cm-string { color: #61CE3C; }
.cm-s-blackboard .cm-string-2 { color: #61CE3C; }
.cm-s-blackboard .cm-meta { color: #D8FA3C; }
.cm-s-blackboard .cm-builtin { color: #8DA6CE; }
.cm-s-blackboard .cm-tag { color: #8DA6CE; }
.cm-s-blackboard .cm-attribute { color: #8DA6CE; }
.cm-s-blackboard .cm-header { color: #FF6400; }
.cm-s-blackboard .cm-hr { color: #AEAEAE; }
.cm-s-blackboard .cm-link { color: #8DA6CE; }
.cm-s-blackboard .cm-error { background: #9D1E15; color: #F8F8F8; }
.cm-s-blackboard .CodeMirror-activeline-background { background: #3C3636; }
.cm-s-blackboard .CodeMirror-matchingbracket { outline:1px solid grey;color:white !important; }
.cm-s-railscasts span.cm-error {
color: #bc9458;
}
/* 弹框 */
.popupAll{width: 100%;height: 100%;position: fixed;z-index: 99998;background-color: rgba(5,16,26,0.6);left: 0;top:0;}
.task-popup{ width: 30%;background: #fff; border:1px solid #e8e8e8; border-radius:10px; -webkit-box-shadow:0 0 10px #ccc; -moz-box-shadow:0 0 10px #ccc; box-shadow:0 0 10px #ccc;}
.task-popup-text-center{ text-align: center; color: #333;}
.task-popup-title{ border-bottom: 1px solid #eee; padding:0px 15px;text-align: center;box-sizing: border-box;line-height: 70px;height: 70px; border-radius: 10px 10px 0px 0px;font-size: 16px; }
.task-popup-content{ padding:15px;}
/*注释这个地方是因为会影响到实训哪块合作者删除的样式*/
/*.task-popup-submit{ margin:0px auto 15px; width: 120px;}*/
.task-popup-sure{ margin:0px auto 15px; width: 54px;}
.task-popup-right-sure{margin:0px auto 15px;text-align: center}
.task-popup-OK{ margin:15px auto; text-align: center}
.task-popup-bggrey{ background:#fff; color:#333;}
a.task-btn-orange{background: #4CACFF; color:#fff!important;}
a:hover.task-btn-orange{background: #4CACFF; color:#fff!important;}
/* 代码区域样式 */
#games_repository_contents .readRepoFailed {
color: #fff;
width: 100%;
text-align: center;
margin-top: 120px;
}
#games_repository_contents .readRepoFailed .retry {
color:#4CACFF;
}

@ -330,20 +330,41 @@ class NewHeader extends Component {
})
}
educoderlogin=()=>{
//登出账号
//退出账号
this.setState({
isRender:true
})
// var url = `/accounts/logout.json`;
//
// axios.get((url)).then((result) => {
// if(result!==undefined){
// // this.setState({
// // isRender:true
// // })
// window.location.href = "/";
// }
// }).catch((error) => {
// console.log(error);
// })
}
educoderloginysl=()=>{
//退出账号
// this.setState({
// isRender:true
// })
var url = `/accounts/logout.json`;
axios.get((url)).then((result) => {
if(result!==undefined){
this.setState({
isRender:true
})
}
if(result!==undefined){
// this.setState({
// isRender:true
// })
window.location.href = "/";
}
}).catch((error) => {
console.log(error);
console.log(error);
})
}
onKeywordSearch = () => {
header_search(this)
}
@ -725,7 +746,7 @@ submittojoinclass=(value)=>{
<li className="bor-top-greyE">
{/*<a href={this.props.Headertop===undefined?"":this.props.Headertop.logout_url}>退出</a>*/}
{/*<a onClick={()=>this.educoderlogin()}>退出</a>*/}
<a onClick={()=>this.educoderlogin()}>退出</a>
<a onClick={()=>this.educoderloginysl()}>退出</a>
</li>
</ul>

File diff suppressed because it is too large Load Diff

@ -529,7 +529,7 @@ class Challenges extends Component {
<p className="task-popup-text-center font-16 pb20">实训已经更新了正在为您重置!</p>
</div>
<div className="task-popup-submit clearfix">
<a className="task-btn task-btn-orange fr mr51" onClick={()=>this.hidestartshixunsreplace(hidestartshixunsreplacevalue)}>知道了</a>
<a className="task-btn task-btn-orange fr mr51" onClick={()=>this.hidestartshixunsreplace(hidestartshixunsreplacevalue)}>知道了</a>
</div>
</Modal>
</div>

@ -9,315 +9,315 @@ import './common.css'
const TabPane = Tabs.TabPane
const loginInputsyl = {
"width": " 100%",
"height": "40px",
"width": " 100%",
"height": "40px",
}
//父组件 EducoderLogin.js
class LoginRegisterComponent extends Component {
constructor(props) {
super(props)
this.state = {
login: "",
password: "",
passwords: "",
seconds: 60,
codes: "",
getverificationcodes: true,
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: false,
s: 'text',
classpass: "text",
readonlyInput: true,
}
}
openNotification = (messge) => {
notification.open({
message: "提示",
description:
messge,
onClick: () => {
console.log('Notification Clicked!');
},
});
};
StudyMakeMoney = () => { // 调用父组件方法
this.props.Setshowbool();
}
// 点击表单后改变type
changeType = () => {
this.setState({classpass: 'password'});
}
changeTypey = () => {
}
//倒计时
getverificationcode = () => {
if (this.state.Phonenumberisnotcobool === false ||this.state.Phonenumberisnotcobool === undefined) {
if (this.state.login&&this.state.login.length === 0) {
this.openNotification("请输入手机号或邮箱");
return
} else {
this.openNotification("请输入正确的手机号或邮箱");
}
return;
}
if (this.state.getverificationcodes === true) {
this.setState({
getverificationcodes: undefined,
})
let timer = setInterval(() => {
this.setState((preState) => ({
seconds: preState.seconds - 1,
}), () => {
if (this.state.seconds == 0) {
clearInterval(timer);
this.setState({
getverificationcodes: false,
seconds: 60,
})
}
});
}, 1000)
this.SMSverification();
} else {
this.setState({
getverificationcodes: undefined,
})
let timer = setInterval(() => {
this.setState((preState) => ({
seconds: preState.seconds - 1,
}), () => {
if (this.state.seconds == 0) {
clearInterval(timer);
this.setState({
getverificationcodes: false,
seconds: 60,
})
}
});
}, 1000)
this.SMSverification();
}
}
//短信验证
SMSverification = () => {
var url = `/accounts/get_verification_code.json`;
axios.get((url), {
params: {
login: this.state.login,
type: 2,
}
}).then((result) => {
//验证有问题{"status":1,"message":"success"}
console.log(result);
}).catch((error) => {
console.log(error);
})
}
cancelReadOnly = () => {
this.setState({
readonlyInput: false,
})
}
//找回密码
Retrievepassword = () => {
if (this.state.Phonenumberisnotcobool === false) {
if (this.state.login.length === 0) {
this.openNotification("请输入手机号或邮箱");
return
}
this.openNotification("请输入正确的手机号或邮箱");
return;
}
if (this.state.login === undefined || this.state.login == "") {
this.openNotification(`请输入登录手机号码或邮箱`);
return
} else if (this.state.password === undefined || this.state.password == "") {
this.openNotification(`请输入密码`);
return
} else if (this.state.passwords === undefined || this.state.passwords == "") {
this.openNotification(`请输入密码`);
return
} else if (this.state.password !== this.state.passwords) {
this.openNotification(`两次密码不相同`);
return
} else if (this.state.codes === undefined || this.state.codes == "") {
this.openNotification(`请输入验证码`);
return
}
var url = "/accounts/reset_password.json";
axios.post(url, {
login: this.state.login,
code: this.state.codes,
new_password: this.state.password,
new_password_confirmation: this.state.passwords,
}).then((result) => {
// console.log(result);
//登录成功会生成session
this.openNotification("找回密码成功,请重新登入。");
window.location.href = "/login"
}).catch((error) => {
})
}
openNotification = (messge) => {
notification.open({
message: "提示",
description:
messge,
onClick: () => {
console.log('Notification Clicked!');
},
});
};
loginInputonChange = (e) => {
// console.log(e.target.value);
this.setState({
login: e.target.value,
})
}
loginInputonChanges = (e) => {
// console.log(e.target.value);
this.setState({
password: e.target.value,
})
}
loginInputonChangess = (e) => {
// console.log(e.target.value);
this.setState({
passwords: e.target.value,
})
}
//获取code
codesonChange = (e) => {
this.setState({
codes: e.target.value
})
}
inputOnBlur = (e) => {
this.isCorrectname(e.target.value);
// this.Emailphonenumberverification(e.target.value, id);
}
isCorrectname = (value) => {
console.log(value.length);
if (value.length === 0) {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: false,
})
return;
}
// var telephone = $("#telephoneAdd.tianjia_phone").val();
var regph = /^[1][3,4,5,6,7,8][0-9]{9}$/;
// var email = $("#add_email.tianjia_email").val();
var regemail = /^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/;
// [1]手机号开头必须是1 [3,4,5,6,7,8] 第二位是3-8中的一个 [0-9]{9} 后边9位可以是0-9的任意数字。
var stringdata = undefined;
if (!regph.test(value)) {
stringdata = "手机号格式不正确";
this.setState({
Phonenumberisnotco: stringdata,
Phonenumberisnotcobool: false,
})
} else {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: true,
})
return
}
if (!regemail.test(value)) {
if ((value.indexOf("@") != -1) === true) {
stringdata = "邮箱格式不正确";
} else {
stringdata = "手机号格式不正确";
}
this.setState({
Phonenumberisnotco: stringdata,
Phonenumberisnotcobool: false,
})
this.Emailphonenumberverification(value)
return
} else {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: true,
})
return
}
}
//邮箱手机号验证
Emailphonenumberverification = (value) => {
var url = `/accounts/valid_email_and_phone.json`;
axios.get((url), {
params: {
login: value,
type: 2,
}
}).then((result) => {
//验证有问题{"status":1,"message":"success"}
// console.log(result);
this.openNotification("验证码已发送,请注意查收!",2);
}).catch((error) => {
console.log(error);
// this.setState({
// login:"",
// logins:"",
// })
})
}
render() {
const {
activeKey,
// 登录
autoLogin,
// 注册
readAgreement, dragOk,
login,
password,
passwords,
classpass,
seconds,
getverificationcodes,
Phonenumberisnotco,
readonlyInput,
codes,
} = this.state
// height: 346px;
return (
<div className="login_register_content" style={{height: "482px"}}>
<Input type="text" name="username" value={"namename"}
style={{height: '0', width: '0', border: 'none', display: "none"}}/>
<Input type="password" name="password" id="password" value={"123123123"}
style={{height: '0', width: '0', border: 'none', display: "none"}}/>
<style>{`
constructor(props) {
super(props)
this.state = {
login: "",
password: "",
passwords: "",
seconds: 60,
codes: "",
getverificationcodes: true,
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: false,
s: 'text',
classpass: "text",
readonlyInput: true,
}
}
openNotification = (messge) => {
notification.open({
message: "提示",
description:
messge,
onClick: () => {
console.log('Notification Clicked!');
},
});
};
StudyMakeMoney = () => { // 调用父组件方法
this.props.Setshowbool();
}
// 点击表单后改变type
changeType = () => {
this.setState({classpass: 'password'});
}
changeTypey = () => {
}
//倒计时
getverificationcode = () => {
if (this.state.Phonenumberisnotcobool === false || this.state.Phonenumberisnotcobool === undefined) {
if (this.state.login && this.state.login.length === 0) {
this.openNotification("请输入手机号或邮箱");
return
} else {
this.openNotification("请输入正确的手机号或邮箱");
}
return;
}
if (this.state.getverificationcodes === true) {
this.setState({
getverificationcodes: undefined,
})
let timer = setInterval(() => {
this.setState((preState) => ({
seconds: preState.seconds - 1,
}), () => {
if (this.state.seconds == 0) {
clearInterval(timer);
this.setState({
getverificationcodes: false,
seconds: 60,
})
}
});
}, 1000)
this.SMSverification();
} else {
this.setState({
getverificationcodes: undefined,
})
let timer = setInterval(() => {
this.setState((preState) => ({
seconds: preState.seconds - 1,
}), () => {
if (this.state.seconds == 0) {
clearInterval(timer);
this.setState({
getverificationcodes: false,
seconds: 60,
})
}
});
}, 1000)
this.SMSverification();
}
}
//短信验证
SMSverification = () => {
var url = `/accounts/get_verification_code.json`;
axios.get((url), {
params: {
login: this.state.login,
type: 2,
}
}).then((result) => {
//验证有问题{"status":1,"message":"success"}
console.log(result);
}).catch((error) => {
console.log(error);
})
}
cancelReadOnly = () => {
this.setState({
readonlyInput: false,
})
}
//找回密码
Retrievepassword = () => {
if (this.state.Phonenumberisnotcobool === false) {
if (this.state.login.length === 0) {
this.openNotification("请输入手机号或邮箱");
return
}
this.openNotification("请输入正确的手机号或邮箱");
return;
}
if (this.state.login === undefined || this.state.login == "") {
this.openNotification(`请输入登录手机号码或邮箱`);
return
} else if (this.state.password === undefined || this.state.password == "") {
this.openNotification(`请输入密码`);
return
} else if (this.state.passwords === undefined || this.state.passwords == "") {
this.openNotification(`请输入密码`);
return
} else if (this.state.password !== this.state.passwords) {
this.openNotification(`两次密码不相同`);
return
} else if (this.state.codes === undefined || this.state.codes == "") {
this.openNotification(`请输入验证码`);
return
}
var url = "/accounts/reset_password.json";
axios.post(url, {
login: this.state.login,
code: this.state.codes,
new_password: this.state.password,
new_password_confirmation: this.state.passwords,
}).then((result) => {
// console.log(result);
//登录成功会生成session
this.openNotification("找回密码成功,请重新登入。");
window.location.href = "/login"
}).catch((error) => {
})
}
openNotification = (messge) => {
notification.open({
message: "提示",
description:
messge,
onClick: () => {
console.log('Notification Clicked!');
},
});
};
loginInputonChange = (e) => {
// console.log(e.target.value);
this.setState({
login: e.target.value,
})
}
loginInputonChanges = (e) => {
// console.log(e.target.value);
this.setState({
password: e.target.value,
})
}
loginInputonChangess = (e) => {
// console.log(e.target.value);
this.setState({
passwords: e.target.value,
})
}
//获取code
codesonChange = (e) => {
this.setState({
codes: e.target.value
})
}
inputOnBlur = (e) => {
this.isCorrectname(e.target.value);
// this.Emailphonenumberverification(e.target.value, id);
}
isCorrectname = (value) => {
console.log(value.length);
if (value.length === 0) {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: false,
})
return;
}
// var telephone = $("#telephoneAdd.tianjia_phone").val();
var regph = /^[1][3,4,5,6,7,8][0-9]{9}$/;
// var email = $("#add_email.tianjia_email").val();
var regemail = /^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/;
// [1]手机号开头必须是1 [3,4,5,6,7,8] 第二位是3-8中的一个 [0-9]{9} 后边9位可以是0-9的任意数字。
var stringdata = undefined;
if (!regph.test(value)) {
stringdata = "手机号格式不正确";
this.setState({
Phonenumberisnotco: stringdata,
Phonenumberisnotcobool: false,
})
} else {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: true,
})
return
}
if (!regemail.test(value)) {
if ((value.indexOf("@") != -1) === true) {
stringdata = "邮箱格式不正确";
} else {
stringdata = "手机号格式不正确";
}
this.setState({
Phonenumberisnotco: stringdata,
Phonenumberisnotcobool: false,
})
this.Emailphonenumberverification(value)
return
} else {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: true,
})
return
}
}
//邮箱手机号验证
Emailphonenumberverification = (value) => {
var url = `/accounts/valid_email_and_phone.json`;
axios.get((url), {
params: {
login: value,
type: 2,
}
}).then((result) => {
//验证有问题{"status":1,"message":"success"}
// console.log(result);
this.openNotification("验证码已发送,请注意查收!", 2);
}).catch((error) => {
console.log(error);
// this.setState({
// login:"",
// logins:"",
// })
})
}
render() {
const {
activeKey,
// 登录
autoLogin,
// 注册
readAgreement, dragOk,
login,
password,
passwords,
classpass,
seconds,
getverificationcodes,
Phonenumberisnotco,
readonlyInput,
codes,
} = this.state
// height: 346px;
return (
<div className="login_register_content" style={{height: "520px"}}>
<Input type="text" name="username" value={"namename"}
style={{height: '0', width: '0', border: 'none', display: "none"}}/>
<Input type="password" name="password" id="password" value={"123123123"}
style={{height: '0', width: '0', border: 'none', display: "none"}}/>
<style>{`
.login_section .section_header {
margin-bottom: 16px;
@ -329,104 +329,116 @@ class LoginRegisterComponent extends Component {
color: #05101A;
line-height: 69px;
}
.loginInputzhuche{
width: 100%;
background-color: #fff!important;
height: 45px !important;
padding: 5px;
}
`}</style>
<div className="login_section">
<div className="section_header">
找回密码
</div>
<div style={{width: '340px'}}>
<style>
{
`
<div className="login_section">
<div className="section_header font-18" style={{color:"#05101A"}}>
找回密码
</div>
<div style={{width: '340px'}}>
<style>
{
`
.ant-input {
font-family: "Monospaced Number", "Chinese Quote", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
-webkit-box-sizing: border-box;
box-sizing: border-box;
margin: 0;
padding: 0;
list-style: none;
position: relative;
display: inline-block;
padding: 4px 11px;
width: 100%;
height: 38px;
font-size: 14px;
line-height: 1.5;
color: rgba(0, 0, 0, 0.65);
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 4px;
-webkit-transition: all .3s;
-o-transition: all .3s;
transition: all .3s;
}
`
}
</style>
<Input style={loginInputsyl} type="text" autoComplete="off" onClick={this.changeTypey}
placeholder="输入注册手机号或邮箱" value={this.state.login} onBlur={(e) => this.inputOnBlur(e)}
onChange={this.loginInputonChange} style={{marginTop: '10px',height: "38px"}}></Input>
{
Phonenumberisnotco && Phonenumberisnotco != "" ?
<p className="color-red mt5 mb5" style={{width: " 100%", height: "20px"}}>
<span className="fl" style={{textAlign:"center",width: " 100%"}}>{Phonenumberisnotco}</span>
</p>
: <div style={{height: "25px"}}></div>
}
<DragValidator
height={38} successGreenColor="#45E15F"
style={{height:"38px",width:"100%"}}
dragOkCallback={this.dragOkCallback}
></DragValidator>
<Input type={classpass}
onClick={this.changeType} autoComplete="new-password" onChange={this.loginInputonChanges}
value={this.state.password} style={{width:"100%",height:"38px",marginTop:'25px'}} placeholder="输入8~16位密码区分大小写"></Input>
<Input type={classpass}
onClick={this.changeType} autoComplete="new-password"
onChange={this.loginInputonChangess} value={this.state.passwords}
style={{height:"38px",marginTop:'25px',width:"100%"}}
placeholder="再次输入新密码"></Input>
<div className={"mt25"}>
<Input className="fl mr5" type="text" autoComplete="off" style={{
width: "210px",
height: "38px",
}} placeholder="请输入验证码"
onChange={this.codesonChange}
value={codes}
>
</Input>
{
getverificationcodes === undefined ?
<Button className="fl ml5 " disabled
style={{"width": "120px", "text-align": "center", "height": "38px",}}
size={"large"}>重新发送{seconds}s</Button>
: getverificationcodes === true ?
<Button className="fl ml5 "
style={{"width": "120px", "text-align": "center", "height": "38px"}}
type="primary"
onClick={() => this.getverificationcode()} size={"large"}>获取验证码</Button>
:
<Button className="fl ml5 "
style={{"width": "120px", "text-align": "center", "height": "38px"}}
type="primary"
onClick={() => this.getverificationcode()} size={"large"}>重新发送</Button>
}
</div>
<Button className="login_btn" size={"large"} type="primary"
style={{height:"46px"}}
onClick={this.Retrievepassword}>完成</Button>
</div>
</div>
</div>
);
}
font-family: "Monospaced Number", "Chinese Quote", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
-webkit-box-sizing: border-box;
box-sizing: border-box;
margin: 0;
padding: 0;
list-style: none;
position: relative;
display: inline-block;
padding: 4px 11px;
width: 100%;
height: 38px;
font-size: 14px;
line-height: 1.5;
color: rgba(0, 0, 0, 0.65);
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 4px;
-webkit-transition: all .3s;
-o-transition: all .3s;
transition: all .3s;
}
`
}
</style>
<Input style={loginInputsyl} type="text" autoComplete="off" onClick={this.changeTypey}
className={"loginInputzhuche"}
placeholder="输入注册手机号或邮箱" value={this.state.login} onBlur={(e) => this.inputOnBlur(e)}
onChange={this.loginInputonChange} style={{marginTop: '10px', height: "38px"}}></Input>
{
Phonenumberisnotco && Phonenumberisnotco != "" ?
<p className="color-red mt5 mb5" style={{width: " 100%", height: "20px"}}>
<span className="fl" style={{textAlign: "center", width: " 100%"}}>{Phonenumberisnotco}</span>
</p>
: <div style={{height: "25px"}}></div>
}
<DragValidator
height={38} successGreenColor="#45E15F"
style={{height: "38px", width: "100%"}}
dragOkCallback={this.dragOkCallback}
></DragValidator>
<Input type={classpass}
className={"loginInputzhuche"}
onClick={this.changeType} autoComplete="new-password" onChange={this.loginInputonChanges}
value={this.state.password} style={{width: "100%", height: "38px", marginTop: '25px'}}
placeholder="输入8~16位密码区分大小写"></Input>
<Input type={classpass}
className={"loginInputzhuche"}
onClick={this.changeType} autoComplete="new-password"
onChange={this.loginInputonChangess} value={this.state.passwords}
style={{height: "38px", marginTop: '25px', width: "100%"}}
placeholder="再次输入新密码"></Input>
<div className={"mt25"}>
<Input className="fl mr5 loginInputzhuche" type="text" autoComplete="off" style={{
width: "210px",
height: "38px",
}} placeholder="请输入验证码"
onChange={this.codesonChange}
value={codes}
>
</Input>
{
getverificationcodes === undefined ?
<Button className="fl ml5 " disabled
style={{"width": "120px", "text-align": "center", "height": "45px",}}
size={"large"}>重新发送{seconds}s</Button>
: getverificationcodes === true ?
<Button className="fl ml5 "
style={{"width": "120px", "text-align": "center", "height": "45px"}}
type="primary"
onClick={() => this.getverificationcode()} size={"large"}>获取验证码</Button>
:
<Button className="fl ml5 "
style={{"width": "120px", "text-align": "center", "height": "45px"}}
type="primary"
onClick={() => this.getverificationcode()} size={"large"}>重新发送</Button>
}
</div>
<Button className="login_btn" size={"large"} type="primary"
style={{height: "46px"}}
onClick={this.Retrievepassword}>完成</Button>
</div>
</div>
</div>
);
}
}
export default (LoginRegisterComponent);

@ -212,8 +212,8 @@ class LoginRegisterComponent extends Component {
Phonenumberisnotcos: undefined,
Phonenumberisnotcobool: true,
})
this.Emailphonenumberverification(value, id)
}
this.Emailphonenumberverification(value, id)
return
}
@ -222,8 +222,11 @@ class LoginRegisterComponent extends Component {
stringdata = "邮箱格式不正确";
} else {
stringdata = "手机号格式不正确";
}
// if (!regph.test(value)) {
// // 这里先判断是不是手机号然后在判断是不是邮箱然后又判断是不是手机号,如果不是手机号就是账号
// stringdata=undefined;
// }
}
if (id === 1) {
this.setState({
Phonenumberisnotco: stringdata,
@ -234,8 +237,8 @@ class LoginRegisterComponent extends Component {
Phonenumberisnotcos: stringdata,
Phonenumberisnotcobool: false,
})
this.Emailphonenumberverification(value, id)
}
this.Emailphonenumberverification(value, id)
return
} else {
if (id === 1) {
@ -248,8 +251,8 @@ class LoginRegisterComponent extends Component {
Phonenumberisnotcos: undefined,
Phonenumberisnotcobool: true,
})
this.Emailphonenumberverification(value, id)
}
this.Emailphonenumberverification(value, id)
return
}
}
@ -548,13 +551,13 @@ class LoginRegisterComponent extends Component {
// console.log(activeKey);
return (
<div className="login_register_content" style={ parseInt(tab[0])==0?{height: "346px"} :{height: "462px"}}>
<div className="login_register_content" style={ parseInt(tab[0])==0?{height: "346px"} :{height: "490px"}}>
<div>
<Menu mode="horizontal" selectedKeys={tab} onClick={this.changeTab}>
<Menu.Item key="0">登录</Menu.Item>
<Menu.Item key="1">注册</Menu.Item>
<Menu.Item key="0" className="font-18" style={{color:"#05101A"}}> 登录</Menu.Item>
<Menu.Item key="1" className="font-18" style={{color:"#05101A"}}>注册</Menu.Item>
</Menu>
{
@ -563,36 +566,45 @@ class LoginRegisterComponent extends Component {
<style>
{
`
.ant-input {
font-family: "Monospaced Number", "Chinese Quote", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
-webkit-box-sizing: border-box;
box-sizing: border-box;
margin: 0;
padding: 0;
list-style: none;
position: relative;
display: inline-block;
padding: 4px 11px;
width: 100%;
height: 38px;
font-size: 14px;
line-height: 1.5;
color: rgba(0, 0, 0, 0.65);
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 4px;
-webkit-transition: all .3s;
-o-transition: all .3s;
transition: all .3s;
}
.ant-input {
font-family: "Monospaced Number", "Chinese Quote", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
-webkit-box-sizing: border-box;
box-sizing: border-box;
margin: 0;
padding: 0;
list-style: none;
position: relative;
display: inline-block;
padding: 4px 11px;
width: 100%;
height: 38px;
font-size: 14px;
line-height: 1.5;
color: rgba(0, 0, 0, 0.65);
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 4px;
-webkit-transition: all .3s;
-o-transition: all .3s;
transition: all .3s;
}
.loginInputzhuche{
width: 100%;
background-color: #fff!important;
height: 45px !important;
padding: 5px;
}
`
}
</style>
<Input placeholder="请输入登录手机号码或邮箱" value={this.state.login}
onChange={this.loginInputonChange}
name="username"
className="font-14 color-grey-9"
className="font-14 color-grey-9 loginInputzhuche"
onBlur={(e) => this.inputOnBlur(e, 1)}
style={{marginTop: '30px', height: '38px'}}></Input>
@ -606,7 +618,7 @@ class LoginRegisterComponent extends Component {
<Input type="password" name="password" id="password" value={this.state.password}
onChange={this.passwordonChange}
className="font-14 color-grey-9 loginInput"
className="font-14 color-grey-9 loginInputzhuche"
placeholder="密码"></Input>
@ -621,10 +633,33 @@ class LoginRegisterComponent extends Component {
size={"large"}>登录</Button>
</div>
}
<style>
{
`
.loginInputzhuche{
width: 100%;
background-color: #fff!important;
height: 45px !important;
padding: 5px;
}
.loginInputzhuche .ant-input{
width: 100%;
background-color: #fff!important;
height: 45px !important;
padding: 5px;
position: relative;
right: 5px;
width: 103%;
}
`
}
</style>
{
parseInt(tab[0])==1 &&
<div style={{width: '340px'}}>
<Input className="loginInputsyl color-grey-9" placeholder="请使用手机号/邮箱账号进行注册"
<Input className="loginInputsyl color-grey-9 loginInputzhuche" placeholder="请使用手机号/邮箱账号进行注册"
value={this.state.logins}
type="text" autoComplete="off"
onChange={this.loginInputonChanges}
@ -646,7 +681,7 @@ class LoginRegisterComponent extends Component {
></DragValidator>
<div className="mt25">
<Input className="fl mr5 font-14 color-grey-9" name="codes" type="text" autoComplete="off" readonly
<Input className="fl mr5 font-14 color-grey-9 loginInputzhuche" name="codes" type="text" autoComplete="off" readonly
onfocus="this.removeAttribute('readonly')" style={{
width:'210px',
height:'38px',
@ -657,13 +692,13 @@ class LoginRegisterComponent extends Component {
</Input>
{
getverificationcodes === undefined ?
<Button className="fl ml5 font-14" disabled style={{"width": "120px","text-align":"center", "height": "38px",}}
<Button className="fl ml5 font-14" disabled style={{"width": "120px","text-align":"center", "height": "45px",}}
size={"large"}>重新发送{seconds}s</Button>
: getverificationcodes === true ?
<Button className="fl ml5 font-14" type="primary" style={{"width": "120px","text-align":"center", "height": "38px",}}
<Button className="fl ml5 font-14" type="primary" style={{"width": "120px","text-align":"center", "height": "45px",}}
onClick={() => this.getverificationcode()} size={"large"}>获取验证码</Button>
:
<Button className="fl ml5 font-14 " type="primary" style={{"width": "120px","text-align":"center", "height": "38px",}}
<Button className="fl ml5 font-14 " type="primary" style={{"width": "120px","text-align":"center", "height": "45px",}}
onClick={() => this.getverificationcode()} size={"large"}>重新发送</Button>
}
@ -673,13 +708,13 @@ class LoginRegisterComponent extends Component {
{/* style={{height: '0', width: '0', border: 'none', display: "none"}}/>*/}
{/*<Input type="password" name="password" id="password" autoComplete="new-password"*/}
{/* style={{height: '0', width: '0', border: 'none', display: "none"}}/>*/}
<Input className="loginInput font-14 mt25 color-grey-9" placeholder="输入8~16位密码区分大小写"
<Input className="loginInput font-14 mt25 color-grey-9 loginInputzhuche" placeholder="输入8~16位密码区分大小写"
type={classpass}
autoComplete="new-password"
onClick={this.changeType}
value={this.state.passwords} onChange={this.passwordonChanges} suffix={
<img src={passopens} onClick={(key) => this.Showandhide(key)}>
<img className={"mt5"} src={passopens} onClick={(key) => this.Showandhide(key)}>
</img>
}></Input>
<Checkbox onChange={this.onChange}

@ -1,47 +1,49 @@
.login_register_content, .login_register_content .ant-tabs-tabpane {
display: flex;
justify-content: center;
}
.login_register_content .ant-input {
background:rgb(244,244,244);
}
.login_register_content {
width: 434px;
box-shadow:3px 10px 21px 0px rgba(76,76,76,0.15);
border-radius:6px;
background: #fff;
}
.login_register_content .ant-tabs-ink-bar {
width: 21px !important;
left: 19px;
}
.login_register_content .ant-tabs {
width: 354px;
}
.login_section {
width: 100%;
display:flex;
justify-content: center;
align-items: center;
flex-direction: column;
}
.loginInput {
width: 100%;
margin-bottom: 16px;
height: 38px;
}
.left_right {
width: 100%;
display: flex;
justify-content: space-between;
}
.login_btn {
width: 100%;
margin-top: 26px;
margin-bottom: 26px;
}
.dragValidator {
margin-bottom: 16px;
.login_register_content, .login_register_content .ant-tabs-tabpane {
display: flex;
justify-content: center;
}
.login_register_content .ant-input {
background:rgb(244,244,244);
}
.login_register_content {
width: 434px;
box-shadow:3px 10px 21px 0px rgba(76,76,76,0.15);
border-radius:6px;
background: #fff;
}
.login_register_content .ant-tabs-ink-bar {
width: 21px !important;
left: 19px;
}
.login_register_content .ant-tabs {
width: 354px;
}
.login_section {
width: 100%;
display:flex;
justify-content: center;
align-items: center;
flex-direction: column;
}
.loginInput {
width: 100%;
margin-bottom: 16px;
height: 45px;
}
.left_right {
width: 100%;
display: flex;
justify-content: space-between;
}
.login_btn {
width: 100%;
margin-top: 26px;
margin-bottom: 26px;
}
.dragValidator {
margin-bottom: 16px;
}

@ -247,9 +247,8 @@ class Infos extends Component{
<div className="educontent mt10 clearfix edu-txt-center">
<div className="inline">
{
data && is_current == false && data.identity =="学生" ?"" : <span className="mypost fl mr10">{data && data.identity}</span>
data && is_current == false && data.identity =="学生" ? "" : <span className="mypost fl mr10">{data && data.identity}</span>
}
<span className="mypost fl mr10">{data && data.identity}</span>
<a href={is_current ? `${this.props.Headertop && this.props.Headertop.old_url}/account/authentication` :"javascript:void(0)"} target="_blank" className={is_current ? "ringauto fl" :"ringauto fl cdefault"}>
<Tooltip placement='bottom' title={ data && data.authentication ?"已实名认证":"未实名认证"}>
<i className={ data && data.authentication ? "iconfont icon-shenfenrenzheng font-13 color-blue":"iconfont icon-shenfenrenzheng font-13 color-grey-9"}></i>
@ -300,8 +299,8 @@ class Infos extends Component{
data && data.can_apply_trial == false ?
data.attendance_signed ?
<React.Fragment>
<span className="user_default_btn user_grey_btn mb5 fl">已签到</span>
<span id="attendance_notice" className="none font-12 color-grey-6" style={{"display":"block"}}>明日签到&nbsp;<font className="color-orange">+{next_gold}</font>&nbsp;</span>
<span className="user_default_btn user_grey_btn mb5">已签到</span>
<p id="attendance_notice" className="none font-12 color-grey-6" style={{"display":"block"}}>明日签到&nbsp;<font className="color-orange">+{next_gold}</font>&nbsp;</p>
</React.Fragment>
:
<a herf="javascript:void(0);" onClick={this.signFor} id="attendance" className="user_default_btn user_orange_btn fl mb15">签到</a>

@ -171,7 +171,7 @@ class InfosShixun extends Component{
item.tag && <div className="tag-green"><span className="tag-name">{item.tag}</span><img src={getImageUrl("/images/educoder/tag2.png")}/></div>
}
<a href="javascript:void(0)" className="square-img">
<img alt="Shixun6" src={getImageUrl(`${item.image_url}`)}/>
<img alt="Shixun6" src={`${item.image_url}`}/>
</a>
<div className="square-main">
<p className="task-hide">

Loading…
Cancel
Save