Merge branch 'dev_aliyun' of http://bdgit.educoder.net/Hjqreturn/educoder into dev_aliyun

issues25489
cxt 5 years ago
commit 90c0f6ae2d

@ -10,8 +10,8 @@ json.students do
if @user_course_identity < Course::ASSISTANT_PROFESSOR && !params[:course_group_id].present? if @user_course_identity < Course::ASSISTANT_PROFESSOR && !params[:course_group_id].present?
json.member_roles student.user.course_role(@course) json.member_roles student.user.course_role(@course)
end end
json.user_phone student.user.hidden_phone json.user_phone @course.excellent ? "" : student.user.hidden_phone
json.user_mail student.user.hidden_mail json.user_mail @course.excellent ? "" : student.user.hidden_mail
end end
end end
json.students_count @students_count json.students_count @students_count

@ -91,6 +91,7 @@ class ListPageIndex extends Component{
this.state={ this.state={
yslGuideone:undefined, yslGuideone:undefined,
yslElearning:false, yslElearning:false,
isexcellent:false
} }
} }
comyslElearning(bool){ comyslElearning(bool){
@ -163,6 +164,11 @@ class ListPageIndex extends Component{
}); });
} }
} }
ispostexcellenttype=(excellent)=>{
this.setState({
isexcellent:excellent
})
}
render() { render() {
let {yslGuideone} =this.state; let {yslGuideone} =this.state;
// console.log("98"); // console.log("98");
@ -175,7 +181,7 @@ class ListPageIndex extends Component{
<div> <div>
<div className="newMain clearfix"> <div className="newMain clearfix">
{/*头部banner*/} {/*头部banner*/}
<CoursesBanner {...this.props}></CoursesBanner> <CoursesBanner {...this.props} ispostexcellenttype={(excellent)=>this.ispostexcellenttype(excellent)}></CoursesBanner>
{/*下面是指引哦*/} {/*下面是指引哦*/}
{/*{yslGuideone!==undefined?*/} {/*{yslGuideone!==undefined?*/}
{/*(*/} {/*(*/}

@ -136,6 +136,7 @@ class CoursesBanner extends Component {
coursedata: data, coursedata: data,
excellent:data.excellent, excellent:data.excellent,
}) })
this.props.ispostexcellenttype(data.excellent)
}else{ }else{
this.onloadupdatabanner() this.onloadupdatabanner()
} }

@ -697,6 +697,26 @@ class studentsList extends Component{
const isStudentPage = pageType == TYPE_STUDENTS const isStudentPage = pageType == TYPE_STUDENTS
this.isStudentPage = isStudentPage this.isStudentPage = isStudentPage
const isGroupChildPage = pageType == TYPE_COURSE_GOURP_CHILD const isGroupChildPage = pageType == TYPE_COURSE_GOURP_CHILD
let studentlist=buildColumns(this,isParent);
if(this.props.isexcellent===true){
studentlist.some((item,key)=> {
if (item.title === "手机号") {
studentlist.splice(key, 1)
return true
}
}
)
}
if(this.props.isexcellent===true){
studentlist.some((item,key)=> {
if (item.title === "邮箱") {
studentlist.splice(key, 1)
return true
}
}
)
}
return( return(
<React.Fragment > <React.Fragment >
@ -866,7 +886,7 @@ class studentsList extends Component{
<Spin size="large" spinning={this.state.isSpin}> <Spin size="large" spinning={this.state.isSpin}>
<div className="clearfix stu_table"> <div className="clearfix stu_table">
{students && !!students.length && <Checkbox.Group style={{ width: '100%' }} onChange={this.onCheckBoxChange} value={checkBoxValues}> {students && !!students.length && <Checkbox.Group style={{ width: '100%' }} onChange={this.onCheckBoxChange} value={checkBoxValues}>
<Table columns={buildColumns(this,isParent)} dataSource={students} onChange={this.onTableChange} pagination={false}></Table> <Table columns={studentlist} dataSource={students} onChange={this.onTableChange} pagination={false}></Table>
</Checkbox.Group> } </Checkbox.Group> }
</div> </div>
</Spin> </Spin>

@ -147,7 +147,7 @@ class ShixunsHome extends Component {
nextArrow={<CustomNextArrow />} nextArrow={<CustomNextArrow />}
prevArrow={<CustomPrevArrow />} prevArrow={<CustomPrevArrow />}
autoplay autoplay
autoplaySpeed={4500} autoplaySpeed={5000}
animation={false} animation={false}
pauseOnHover={true} pauseOnHover={true}
style={{width:"100%"}} style={{width:"100%"}}

Loading…
Cancel
Save