hjm 5 years ago
commit 3494b22615

@ -113,21 +113,21 @@ module.exports = {
// First, run the linter. // First, run the linter.
// It's important to do this before Babel processes the JS. // It's important to do this before Babel processes the JS.
{ // {
test: /\.(js|jsx|mjs)$/, // test: /\.(js|jsx|mjs)$/,
enforce: 'pre', // enforce: 'pre',
use: [ // use: [
{ // {
options: { // options: {
formatter: eslintFormatter, // formatter: eslintFormatter,
eslintPath: require.resolve('eslint'), // eslintPath: require.resolve('eslint'),
//
}, // },
loader: require.resolve('eslint-loader'), // loader: require.resolve('eslint-loader'),
}, // },
], // ],
include: paths.appSrc, // include: paths.appSrc,
}, // },
{ {
// "oneOf" will traverse all following loaders until one will // "oneOf" will traverse all following loaders until one will
// match the requirements. When no loader matches it will fall // match the requirements. When no loader matches it will fall

@ -40,7 +40,7 @@ class Fileslistitem extends Component{
let link = document.createElement('a'); let link = document.createElement('a');
// link.href = window.URL.createObjectURL(new Blob([result.data.url])); // link.href = window.URL.createObjectURL(new Blob([result.data.url]));
link.href = result.data.url; link.href = result.data.url;
link.download = encodeURI(result.data.title); // link.download = encodeURI(result.data.title);
//兼容火狐浏览器 //兼容火狐浏览器
document.body.appendChild(link); document.body.appendChild(link);
let evt = document.createEvent("MouseEvents"); let evt = document.createEvent("MouseEvents");
@ -288,7 +288,16 @@ class Fileslistitem extends Component{
{ discussMessage.publish_time===null?"":discussMessage.is_publish===true?moment(discussMessage.publish_time).fromNow():moment(discussMessage.publish_time).format('YYYY-MM-DD HH:mm')} { discussMessage.publish_time===null?"":discussMessage.is_publish===true?moment(discussMessage.publish_time).fromNow():moment(discussMessage.publish_time).format('YYYY-MM-DD HH:mm')}
</span> </span>
</span> </span>
{this.props.isAdmin ||this.props.current_user.login===discussMessage.author.login? {this.props.isAdmin?
<span className={"fr mrf2 mr10"}>
<WordsBtn style="blue" className="colorblue font-16 mr20 fr">
<a className="btn colorblue"
onClick={()=>this.settingList()}>设置</a>
</WordsBtn>
</span>:""}
{this.props.current_user.login===discussMessage.author.login?
<span className={"fr mrf2 mr10"}> <span className={"fr mrf2 mr10"}>
<WordsBtn style="blue" className="colorblue font-16 mr20 fr"> <WordsBtn style="blue" className="colorblue font-16 mr20 fr">

@ -41,7 +41,9 @@ class Fileslists extends Component{
} }
componentDidMount=()=>{ componentDidMount=()=>{
this.setState({ this.setState({
isSpin:true isSpin:true,
checkBoxValues:[],
checkAllValue:false
}) })
if(this.props.match.params.main_id){ if(this.props.match.params.main_id){
this.seactall(); this.seactall();
@ -65,17 +67,21 @@ class Fileslists extends Component{
} }
componentDidUpdate = (prevProps) => { componentDidUpdate = (prevProps) => {
if(prevProps.match.params.main_id != this.props.match.params.main_id){ if(prevProps.match.params.main_id != this.props.match.params.main_id){
this.setState({ this.setState({
isSpin:true isSpin:true,
}) checkBoxValues:[],
checkAllValue:false
})
if(this.props.match.params.main_id!=undefined){ if(this.props.match.params.main_id!=undefined){
this.seactall(); this.seactall();
} }
} }
if(prevProps.match.params.Id != this.props.match.params.Id){ if(prevProps.match.params.Id != this.props.match.params.Id){
this.setState({ this.setState({
isSpin:true isSpin:true,
}) checkBoxValues:[],
checkAllValue:false
})
if(this.props.match.params.Id!=undefined){ if(this.props.match.params.Id!=undefined){
this.seactall(parseInt(this.props.match.params.Id),1) this.seactall(parseInt(this.props.match.params.Id),1)
} }
@ -533,7 +539,7 @@ class Fileslists extends Component{
// ModalSave:this.cancelmodel, // ModalSave:this.cancelmodel,
// Loadtype:true, // Loadtype:true,
checkBoxValues:[], checkBoxValues:[],
// checkAllValue:false checkAllValue:false
}) })
this.props.showNotification('资源移动成功') this.props.showNotification('资源移动成功')
@ -681,6 +687,9 @@ class Fileslists extends Component{
<div className="studentList_operation_ul"> <div className="studentList_operation_ul">
{this.props.isAdmin()?<li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onDelete}>删除</a></li>:""} {this.props.isAdmin()?<li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onDelete}>删除</a></li>:""}
{this.props.isAdmin()?<li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onSend}>发送</a></li>:""} {this.props.isAdmin()?<li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onSend}>发送</a></li>:""}
{this.props.isAdmin()?
<li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onOpen}>立即发布</a></li>
:""}
{this.props.isAdmin()?course_is_public===true? {this.props.isAdmin()?course_is_public===true?
<li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onOpen}>设为公开</a></li> <li className="li_line"><a href="javascript:void(0)" className="color-grey-9" onClick={this.onOpen}>设为公开</a></li>
:"":""} :"":""}
@ -785,7 +794,7 @@ class Fileslists extends Component{
isAdmin={this.props.isAdmin()} isAdmin={this.props.isAdmin()}
isStudent={this.props.isStudent()} isStudent={this.props.isStudent()}
isNotMember={this.props.isNotMember()} isNotMember={this.props.isNotMember()}
checkBox={<Checkbox value={item.id}></Checkbox>} checkBox={this.props.isAdmin()?<Checkbox value={item.id}></Checkbox>:""}
Settingtypes={(id)=>this.Settingtypes(id)} Settingtypes={(id)=>this.Settingtypes(id)}
coursesId={this.props.match.params.coursesId} coursesId={this.props.match.params.coursesId}
updatafiledfun={()=>this.updatafiled()} updatafiledfun={()=>this.updatafiled()}
@ -830,7 +839,7 @@ class Fileslists extends Component{
<div className="alltask edu-back-white" <div className="alltask edu-back-white"
style={ style={
{ {
display: total_count===undefined?'block' :total_count===0? 'block' : 'none' display: files===undefined?'block' :files.length===0? 'block' : 'none'
} }
} }
> >

@ -153,14 +153,14 @@ class Addcourses extends Component{
this.setState({ this.setState({
invite_codetype:true, invite_codetype:true,
invite_codevalue:"邀请码不能为空", invite_codevalue:"邀请码不能为空",
spinning:false isSpin:false
}) })
return return
}else{ }else{
this.setState({ this.setState({
invite_codetype:false, invite_codetype:false,
invite_codevalue:" ", invite_codevalue:" ",
spinning:false isSpin:false
}) })
} }
@ -217,12 +217,12 @@ class Addcourses extends Component{
} }
this.setState({ this.setState({
spinning:false isSpin:false
}) })
}).catch((error) => { }).catch((error) => {
console.log(error) console.log(error)
this.setState({ this.setState({
spinning:false isSpin:false
}) })
}) })
@ -313,7 +313,7 @@ class Addcourses extends Component{
<li className="clearfix mb10"> <li className="clearfix mb10">
<label className="panel-form-label fl">课堂邀请码</label> <label className="panel-form-label fl">课堂邀请码</label>
<Input type="text" className="input-60-40 fl mt5" name="invite_code" <Input type="text" className="input-60-40 fl mt5" name="invite_code"
placeholder="请输入五位课堂邀请码" placeholder="请输入5位课堂邀请码或6位分班邀请码"
style={{ height: '30px'}} style={{ height: '30px'}}
value={invite_code} onInput={this.inputjoinclassvalue}/> value={invite_code} onInput={this.inputjoinclassvalue}/>
</li> </li>
@ -321,7 +321,7 @@ class Addcourses extends Component{
<p id="none_invite_code_notice" <p id="none_invite_code_notice"
className="color-orange none f12" className="color-orange none f12"
// style={{marginLeft: '90px',display:code_notice===true?'block':"none"}} // style={{marginLeft: '90px',display:code_notice===true?'block':"none"}}
>请输入五位课堂邀请码</p> >请输入5位课堂邀请码或6位分班邀请码</p>
<li className="clearfix "> <li className="clearfix ">

@ -1,253 +1,259 @@
import React, {Component} from "react"; import React, {Component} from "react";
import {WordsBtn} from 'educoder'; import {WordsBtn} from 'educoder';
import { Form, Select, Input, Button,Checkbox,Upload,Icon,message,Modal, Table, Divider,InputNumber, Tag,DatePicker,Radio,Tooltip} from "antd"; import { Form, Select, Input, Button,Checkbox,Upload,Icon,message,Modal, Table, Divider,InputNumber, Tag,DatePicker,Radio,Tooltip,Spin} from "antd";
import {Link,Switch,Route,Redirect} from 'react-router-dom'; import {Link,Switch,Route,Redirect} from 'react-router-dom';
import axios from 'axios'; import axios from 'axios';
import ShixunCustomsPass from "./Shixunworkdetails/ShixunCustomsPass"; import ShixunCustomsPass from "./Shixunworkdetails/ShixunCustomsPass";
import '../css/members.css'; import '../css/members.css';
import "../common/formCommon.css"; import "../common/formCommon.css";
import '../css/Courses.css'; import '../css/Courses.css';
import './style.css'; import './style.css';
class ShixunWorkDetails extends Component { class ShixunWorkDetails extends Component {
constructor(props) { constructor(props) {
super(props); super(props);
this.state = { this.state = {
data:undefined data:undefined,
} spinning:true
} }
}
componentDidMount() {
let homeworkid=this.props.match.params.homeworkid; componentDidMount() {
let userid=this.props.match.params.userid; this.setState({
let url = "/homework_commons/"+homeworkid+"/code_review_detail.json"; spinning:true
axios.get(url,{ })
params: { let homeworkid=this.props.match.params.homeworkid;
user_id:userid, let userid=this.props.match.params.userid;
} let url = "/homework_commons/"+homeworkid+"/code_review_detail.json";
}).then((result) => { axios.get(url,{
if (result.status === 200) { params: {
this.setState({ user_id:userid,
data:result.data }
}) }).then((result) => {
} if (result.status === 200) {
}).catch((error) => { this.setState({
console.log(error) data:result.data,
}) spinning:false
})
let query = this.props.location.pathname; }
const type = query.split('/'); }).catch((error) => {
this.setState({ console.log(error)
shixuntypes:type[3] })
})
} let query = this.props.location.pathname;
const type = query.split('/');
goback=()=>{ this.setState({
window.history.go(-1) shixuntypes:type[3]
} })
render() { }
let{data}=this.state; goback=()=>{
window.history.go(-1)
return ( }
data===undefined?"":<div className="newMain clearfix "> render() {
<div className={"educontent mb20"}>
let{data}=this.state;
<div className="educontent"> console.log(data)
<p className="clearfix mt20"> return (
<WordsBtn className="fl color-grey-9" style="btn colorgrey hovercolorblue"> <Spin size="large" spinning={this.state.spinning}>
<Link to={"/courses/"+data&&data.course_id+"/students"}> {data===undefined? "":<div className="newMain clearfix ">
<span className={"color-grey-9"}>{data&&data.course_name}</span> <div className={"educontent mb20"}>
</Link>
</WordsBtn> <div className="educontent">
<span className="color-grey-9 fl ml3 mr3">&gt;</span> <p className="clearfix mt20">
<WordsBtn style="grey" className="btn colorgrey fl hovercolorblue "> <WordsBtn className="fl color-grey-9" style="btn colorgrey hovercolorblue">
<Link to={"/courses/"+data&&data.course_id+"/"+this.state.shixuntypes+"/"+data&&data.homework_common_id}> <Link to={"/courses/"+data&&data.course_id+"/students"}>
<span className={"color-grey-9"}>实训作业</span> <span className={"color-grey-9"}>{data&&data.course_name}</span>
</Link> </Link>
</WordsBtn> </WordsBtn>
<span className="color-grey-9 fl ml3 mr3">&gt;</span> <span className="color-grey-9 fl ml3 mr3">&gt;</span>
<WordsBtn className="fl">{data&&data.username}</WordsBtn> <WordsBtn style="grey" className="btn colorgrey fl hovercolorblue ">
</p> <Link to={"/courses/"+data&&data.course_id+"/"+this.state.shixuntypes+"/"+data&&data.homework_common_id}>
</div> <span className={"color-grey-9"}>实训作业</span>
</Link>
<div className="padding10-30 clearfix"> </WordsBtn>
<span className="fl font-18">{data&&data.homework_common_name}</span> <span className="color-grey-9 fl ml3 mr3">&gt;</span>
<a className="fr color-grey-9 mt4" onClick={this.goback}>返回</a> <WordsBtn className="fl">{data&&data.username}</WordsBtn>
</div> </p>
</div>
<div className="padding10-30 edu-back-white clearfix">
<span className="fl color-orange font-14">非编程类型任务不参与查重</span> <div className="padding10-30 clearfix">
<span className="fr mt4"> <span className="fl font-18">{data&&data.homework_common_name}</span>
<span className={"color656565"}>被查作品</span> <a className="fr color-grey-9 mt4" onClick={this.goback}>返回</a>
<span className={"mr20"}>{data&&data.username}</span> </div>
<span className={"color-orange"}>{data&&data.final_score}</span>
</span> <div className="padding10-30 edu-back-white clearfix">
</div> <span className="fl color-orange font-14">非编程类型任务不参与查重</span>
<span className="fr mt4">
<div className="stud-class-set bor-bottom-greyE"> <span className={"color656565"}>被查作品</span>
<div className="clearfix edu-back-white poll_list"> <span className={"mr20"}>{data&&data.username}</span>
<ShixunCustomsPass <span className={"color-orange"}>{data&&data.final_score}</span>
data={data} </span>
/> </div>
</div>
</div> <div className="stud-class-set bor-bottom-greyE">
<div className="clearfix edu-back-white poll_list">
<ShixunCustomsPass
data={data}
</div> />
</div> </div>
</div>
)
}
}
</div>
export default ShixunWorkDetails; </div>}
</Spin>
)
}
}
// {/*<div className="stud-class-set bor-bottom-greyE">*/}
// {/*<div className="clearfix edu-back-white poll_list">*/} export default ShixunWorkDetails;
//
// {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">总体评价</div>*/}
//
// {/*<ConclusionEvaluation*/}
// {/*data={data}*/} // {/*<div className="stud-class-set bor-bottom-greyE">*/}
// {/*/>*/} // {/*<div className="clearfix edu-back-white poll_list">*/}
// //
// {/*</div>*/} // {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">总体评价</div>*/}
// {/*</div>*/} //
// // {/*<ConclusionEvaluation*/}
// {/*<div className="stud-class-set">*/} // {/*data={data}*/}
// {/*<div className="clearfix edu-back-white poll_list">*/} // {/*/>*/}
// //
// {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">阶段成绩</div>*/} // {/*</div>*/}
// // {/*</div>*/}
// {/*<OfficialAcademicTranscript*/} //
// {/*data={data}*/} // {/*<div className="stud-class-set">*/}
// {/*/>*/} // {/*<div className="clearfix edu-back-white poll_list">*/}
// //
// {/*</div>*/} // {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">阶段成绩</div>*/}
// {/*</div>*/} //
// // {/*<OfficialAcademicTranscript*/}
// {/*<div className="stud-class-set bor-bottom-greyE"*/} // {/*data={data}*/}
// {/*style={{display:data&&data.work_description===null?"none":""}}*/} // {/*/>*/}
// {/*>*/} //
// {/*<div className="clearfix edu-back-white poll_list">*/} // {/*</div>*/}
// {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">个人总结</div>*/} // {/*</div>*/}
// {/*<style>*/} //
// {/*{`*/} // {/*<div className="stud-class-set bor-bottom-greyE"*/}
// {/*.personalsummary{*/} // {/*style={{display:data&&data.work_description===null?"none":""}}*/}
// {/*height:115px;*/} // {/*>*/}
// {/*border:1px solid rgba(235,235,235,1);*/} // {/*<div className="clearfix edu-back-white poll_list">*/}
// {/*border-radius:2px;*/} // {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">个人总结</div>*/}
// {/*}*/} // {/*<style>*/}
// {/*.pad040{*/} // {/*{`*/}
// {/*padding: 0px 40px 40px;*/} // {/*.personalsummary{*/}
// {/*}*/} // {/*height:115px;*/}
// {/*.pad40px{*/} // {/*border:1px solid rgba(235,235,235,1);*/}
// {/*padding-bottom: 40px;*/} // {/*border-radius:2px;*/}
// {/*}*/} // {/*}*/}
// {/*.codebox{*/} // {/*.pad040{*/}
// {/*height: 40px;*/} // {/*padding: 0px 40px 40px;*/}
// {/*line-height: 30px;*/} // {/*}*/}
// {/*}*/} // {/*.pad40px{*/}
// {/*.codeboxright{*/} // {/*padding-bottom: 40px;*/}
// {/*color: #999999!important;*/} // {/*}*/}
// {/*font-size: 16px;*/} // {/*.codebox{*/}
// {/*}*/} // {/*height: 40px;*/}
// {/*`}*/} // {/*line-height: 30px;*/}
// {/*</style>*/} // {/*}*/}
// {/*<div className={"pad040"}>*/} // {/*.codeboxright{*/}
// {/*<div className={"personalsummary"}>*/} // {/*color: #999999!important;*/}
// {/*{data&&data.work_description}*/} // {/*font-size: 16px;*/}
// {/*</div>*/} // {/*}*/}
// {/*</div>*/} // {/*`}*/}
// {/*</div>*/} // {/*</style>*/}
// {/*</div>*/} // {/*<div className={"pad040"}>*/}
// // {/*<div className={"personalsummary"}>*/}
// {/*<div className="stud-class-set bor-bottom-greyE">*/} // {/*{data&&data.work_description}*/}
// {/*<div className="clearfix edu-back-white poll_list">*/} // {/*</div>*/}
// {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">图形统计</div>*/} // {/*</div>*/}
// {/*<Shixunechart*/} // {/*</div>*/}
// {/*data={data}*/} // {/*</div>*/}
// {/*/>*/} //
// {/*</div>*/} // {/*<div className="stud-class-set bor-bottom-greyE">*/}
// {/*</div>*/} // {/*<div className="clearfix edu-back-white poll_list">*/}
// // {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">图形统计</div>*/}
// {/*<div className="stud-class-set bor-bottom-greyE">*/} // {/*<Shixunechart*/}
// {/*<div className="clearfix edu-back-white poll_list pad40px">*/} // {/*data={data}*/}
// {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">实训详情</div>*/} // {/*/>*/}
// {/*<style>*/} // {/*</div>*/}
// {/*{`*/} // {/*</div>*/}
// {/*.poll_list a{*/} //
// {/*padding:0px !important;*/} // {/*<div className="stud-class-set bor-bottom-greyE">*/}
// {/*}*/} // {/*<div className="clearfix edu-back-white poll_list pad40px">*/}
// {/*.backgroud4CACFF{*/} // {/*<div className="font-16 color-dark-21 shixunreporttitle ml20">实训详情</div>*/}
// {/*background: #4CACFF;*/} // {/*<style>*/}
// {/*}*/} // {/*{`*/}
// {/*`}*/} // {/*.poll_list a{*/}
// {/*</style>*/} // {/*padding:0px !important;*/}
// {/*{*/} // {/*}*/}
// {/*data&&data.shixun_detail.map((item,key)=>{*/} // {/*.backgroud4CACFF{*/}
// {/*return(*/} // {/*background: #4CACFF;*/}
// {/*<div key={key} className={"mb20"}>*/} // {/*}*/}
// {/*<div className="font-16 color-dark-21 ml20 mr20">*/} // {/*`}*/}
// {/*<p className="clearfix mb20">*/} // {/*</style>*/}
// {/*<span className="panel-inner-icon mr15 fl mt3 backgroud4CACFF">*/} // {/*{*/}
// {/*<i className="fa fa-code font-16 color_white"></i>*/} // {/*data&&data.shixun_detail.map((item,key)=>{*/}
// {/*</span>*/} // {/*return(*/}
// {/*<span className="fl mt3 font-14">*/} // {/*<div key={key} className={"mb20"}>*/}
// {/*<span className="font-bd mr15">第{item.position}关</span>*/} // {/*<div className="font-16 color-dark-21 ml20 mr20">*/}
// {/*<Link to={/tasks/+item.game_identifier}>*/} // {/*<p className="clearfix mb20">*/}
// {/*<span className={"font-14"}>{item.subject}</span>*/} // {/*<span className="panel-inner-icon mr15 fl mt3 backgroud4CACFF">*/}
// {/*</Link>*/} // {/*<i className="fa fa-code font-16 color_white"></i>*/}
// {/*</span>*/} // {/*</span>*/}
// {/*</p>*/} // {/*<span className="fl mt3 font-14">*/}
// {/*<Coursesshixundetails*/} // {/*<span className="font-bd mr15">第{item.position}关</span>*/}
// {/*data={item.outputs}*/} // {/*<Link to={/tasks/+item.game_identifier}>*/}
// {/*/>*/} // {/*<span className={"font-14"}>{item.subject}</span>*/}
// {/*</div>*/} // {/*</Link>*/}
// // {/*</span>*/}
// {/*{item.st===0?<div className="font-16 color-dark-21 ml20 mr20">*/} // {/*</p>*/}
// {/*<div className="bor-grey-e mt15">*/} // {/*<Coursesshixundetails*/}
// {/*<p className="clearfix pt5 pb5 pl15 pr15 back-f6-grey codebox">*/} // {/*data={item.outputs}*/}
// {/*<span className="fl">最近通过的代码</span>*/} // {/*/>*/}
// {/*<span className="fr codeboxright">{item.path}</span>*/} // {/*</div>*/}
// {/*</p>*/} //
// // {/*{item.st===0?<div className="font-16 color-dark-21 ml20 mr20">*/}
// {/*<div className="test-code bor-top-greyE">*/} // {/*<div className="bor-grey-e mt15">*/}
// {/*<li className="clearfix" xmlns="http://www.w3.org/1999/html">*/} // {/*<p className="clearfix pt5 pb5 pl15 pr15 back-f6-grey codebox">*/}
// {/*<CodeMirror*/} // {/*<span className="fl">最近通过的代码</span>*/}
// {/*value={item.passed_code}*/} // {/*<span className="fr codeboxright">{item.path}</span>*/}
// {/*options={{*/} // {/*</p>*/}
// {/*// mode: 'xml',*/} //
// {/*theme: 'default',*/} // {/*<div className="test-code bor-top-greyE">*/}
// {/*lineNumbers: true,*/} // {/*<li className="clearfix" xmlns="http://www.w3.org/1999/html">*/}
// {/*// extraKeys: {"Ctrl-Q": "autocomplete"}, // 快捷键*/} // {/*<CodeMirror*/}
// {/*indentUnit: 4, //代码缩进为一个tab的距离*/} // {/*value={item.passed_code}*/}
// {/*matchBrackets: true,*/} // {/*options={{*/}
// {/*autoRefresh: true,*/} // {/*// mode: 'xml',*/}
// {/*smartIndent: true,//智能换行*/} // {/*theme: 'default',*/}
// {/*styleActiveLine: true,*/} // {/*lineNumbers: true,*/}
// {/*lint: true,*/} // {/*// extraKeys: {"Ctrl-Q": "autocomplete"}, // 快捷键*/}
// {/*readOnly: "nocursor"*/} // {/*indentUnit: 4, //代码缩进为一个tab的距离*/}
// {/*}}*/} // {/*matchBrackets: true,*/}
// {/*/>*/} // {/*autoRefresh: true,*/}
// {/*</li>*/} // {/*smartIndent: true,//智能换行*/}
// {/*</div>*/} // {/*styleActiveLine: true,*/}
// {/*</div>*/} // {/*lint: true,*/}
// {/*</div>:""}*/} // {/*readOnly: "nocursor"*/}
// {/*</div>*/} // {/*}}*/}
// {/*)*/} // {/*/>*/}
// {/*})*/} // {/*</li>*/}
// {/*}*/} // {/*</div>*/}
// {/*</div>*/} // {/*</div>*/}
// {/*</div>*/} // {/*</div>:""}*/}
// {/*</div>*/} // {/*</div>*/}
// // {/*)*/}
// {/*})*/}
// {/*}*/}
// {/*</div>*/}
// {/*</div>*/}
// {/*</div>*/}
//

@ -87,7 +87,7 @@ class ShixunWorkModal extends Component{
let {page,limit,group_list}=this.state; let {page,limit,group_list}=this.state;
let newpage=page+1; let newpage=page+1;
let newgroup_list=group_list; let newgroup_list=group_list;
debugger
let url="/homework_commons/"+this.props.match.params.homeworkid+"/group_list.json"; let url="/homework_commons/"+this.props.match.params.homeworkid+"/group_list.json";
axios.get(url,{params:{ axios.get(url,{params:{
@ -97,7 +97,7 @@ class ShixunWorkModal extends Component{
}).then((response) => { }).then((response) => {
if(response!==null || response!==undefined){ if(response!==null || response!==undefined){
if(response.data.group_list.length>0){ if(response.data.group_list.length>0){
console.log("84");
response.data.group_list.map((item,key)=>{ response.data.group_list.map((item,key)=>{
newgroup_list.push(item); newgroup_list.push(item);
this.setState({ this.setState({
@ -111,8 +111,7 @@ class ShixunWorkModal extends Component{
if(response.data.ungroup_list===undefined || response.data.ungroup_list === null) { if(response.data.ungroup_list===undefined || response.data.ungroup_list === null) {
}else { }else {
console.log("95");
console.log(response.data.ungroup_list);
newgroup_list.push(response.data.ungroup_list); newgroup_list.push(response.data.ungroup_list);
this.setState({ this.setState({
course_groups:response.data, course_groups:response.data,
@ -244,24 +243,23 @@ class ShixunWorkModal extends Component{
.fontlefts{text-align: left;} .fontlefts{text-align: left;}
`}</style> `}</style>
<ul className="clearfix edu-txt-center"> <ul className="clearfix edu-txt-center">
<li className="fl paddingleft22 fontlefts" style={{width:'150px'}}>分班名称</li> <li className="fl paddingleft22 fontlefts" style={{width:'260px'}}>分班名称</li>
<li className="fl edu-txt-left" style={{width:'150px'}}>有效作品数</li> <li className="fl edu-txt-left" style={{width:'117px'}}>有效作品数</li>
<li className="fl" style={{width:'100px'}}>上次查重时间</li> <li className="fl" style={{width:'100px'}}>上次查重时间</li>
</ul> </ul>
{course_groups===undefined?"": {course_groups===undefined?"":
<ul className="upload_select_box fl clearfix mt10 mb10" tyle={{"overflow-y":"auto"}}id="search_not_members_list" <ul className="upload_select_box fl clearfix mt10 mb10" tyle={{"overflow-y":"auto"}}id="search_not_members_list"
onScroll={this.contentViewScroll}
onScroll={this.contentViewScroll} >
>
<Checkbox.Group style={{ width: '100%' }} onChange={this.shixunhomeworkedit} value={group_ids}> <Checkbox.Group style={{ width: '100%' }} onChange={this.shixunhomeworkedit} value={group_ids}>
{ {
group_list===undefined? group_list===undefined?course_groups.ungroup_list.work_count===0?"":
<div className="clearfix edu-txt-center lineh-40 bor-bottom-greyE"> <div className="clearfix edu-txt-center lineh-40 bor-bottom-greyE">
<li className="fl" style={{width: '100px'}}> <li className="fl task-hide" style={{width: '240px'}}>
<Checkbox <Checkbox
className="fl task-hide edu-txt-left" className="fl task-hide edu-txt-left"
name="shixun_homework[]" name="shixun_homework[]"
@ -271,8 +269,8 @@ class ShixunWorkModal extends Component{
className="task-hide color-grey-name" title="frerere">{course_groups.ungroup_list.name}</label> className="task-hide color-grey-name" title="frerere">{course_groups.ungroup_list.name}</label>
</Checkbox> </Checkbox>
</li> </li>
<li className="fl" style={{width: '150px'}}> <li className="fl" style={{width: '100px'}}>
{course_groups.ungroup_list.works_count} {course_groups.ungroup_list.work_count}
</li> </li>
<li className="fl" style={{width: '160px'}}> <li className="fl" style={{width: '160px'}}>
{course_groups.ungroup_list.last_review_time} {course_groups.ungroup_list.last_review_time}
@ -282,8 +280,8 @@ class ShixunWorkModal extends Component{
: :
group_list&&group_list.map((item,key)=>{ group_list&&group_list.map((item,key)=>{
return( return(
<div className="clearfix edu-txt-center lineh-40 bor-bottom-greyE" key={key}> item.work_count===0?"":<div className="clearfix edu-txt-center lineh-40 bor-bottom-greyE" key={key}>
<li className="fl" style={{width: '100px'}}> <li className="fl task-hide" style={{width: '240px'}}>
<Checkbox <Checkbox
className="fl task-hide edu-txt-left" className="fl task-hide edu-txt-left"
name="shixun_homework[]" name="shixun_homework[]"
@ -293,8 +291,8 @@ class ShixunWorkModal extends Component{
className="task-hide color-grey-name" title="frerere">{item===undefined?"":item.name}</label> className="task-hide color-grey-name" title="frerere">{item===undefined?"":item.name}</label>
</Checkbox> </Checkbox>
</li> </li>
<li className="fl" style={{width: '150px'}}> <li className="fl" style={{width: '100px'}}>
{item===undefined?"":item.works_count} {item===undefined?"":item.works_count===undefined?item.work_count:item.works_count}
</li> </li>
<li className="fl" style={{width: '160px'}}> <li className="fl" style={{width: '160px'}}>
{item===undefined?"":item.last_review_time} {item===undefined?"":item.last_review_time}

@ -817,12 +817,12 @@ submittojoinclass=(value)=>{
<li className="clearfix mb10"> <li className="clearfix mb10">
<label className="panel-form-label fl">项目邀请码</label> <label className="panel-form-label fl">项目邀请码</label>
<Input type="text" className="input-60-40 fl" name="invite_code" <Input type="text" className="input-60-40 fl" name="invite_code"
placeholder="请输入六位课堂邀请码" value={tojoinclasstitle} onInput={this.inputjoinclassvalue}/> placeholder="请输入5位课堂邀请码或6位分班邀请码" value={tojoinclasstitle} onInput={this.inputjoinclassvalue}/>
</li> </li>
<p id="none_invite_code_notice" <p id="none_invite_code_notice"
className="color-orange none f12" className="color-orange none f12"
style={{marginLeft: '90px',display:code_notice===true?'block':"none"}}>请输入六位课堂邀请码</p> style={{marginLeft: '90px',display:code_notice===true?'block':"none"}}>请输入5位课堂邀请码或6位分班邀请码</p>
<li className="clearfix "> <li className="clearfix ">

Loading…
Cancel
Save