|
|
|
@ -14,7 +14,9 @@ class Headplugselection extends Component {
|
|
|
|
|
super(props);
|
|
|
|
|
this.state = {
|
|
|
|
|
page:1,
|
|
|
|
|
titlestting:["全部","前端开发","后端开发","移动开发","数据库","云计算和大数据","运维与测试","人工测试","其他"],
|
|
|
|
|
titlestting:"全部",
|
|
|
|
|
titlesttings:null,
|
|
|
|
|
titlesttingss:null,
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
//初始化
|
|
|
|
@ -22,45 +24,130 @@ class Headplugselection extends Component {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
settitlestting=(name)=>{
|
|
|
|
|
//如果全部其他的选项重置
|
|
|
|
|
this.setState({
|
|
|
|
|
titlestting:name,
|
|
|
|
|
titlesttings:null,
|
|
|
|
|
titlesttingss:null
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
settitlesttings=(name)=>{
|
|
|
|
|
//课程选项
|
|
|
|
|
this.setState({
|
|
|
|
|
titlesttings:name,
|
|
|
|
|
titlesttingss:null,
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
settitlesttingss=(name)=>{
|
|
|
|
|
//知识点
|
|
|
|
|
this.setState({
|
|
|
|
|
titlesttingss:name
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
render() {
|
|
|
|
|
let {page,titlestting}=this.state;
|
|
|
|
|
let {page,titlestting,titlesttings,titlesttingss}=this.state;
|
|
|
|
|
// console.log("Headplugselection");
|
|
|
|
|
// console.log(this.props.disciplinesdata);
|
|
|
|
|
return (
|
|
|
|
|
<div className=" clearfix">
|
|
|
|
|
<div className="educontent mt10 mb20 w1200">
|
|
|
|
|
|
|
|
|
|
<div className="clearfix edu-back-white h177 mt21 tophom">
|
|
|
|
|
<div className="clearfix edu-back-white mt21 tophom">
|
|
|
|
|
{/*课程*/}
|
|
|
|
|
<div className="h40 sortinxdirection">
|
|
|
|
|
<div className="w70 tophomsembold">
|
|
|
|
|
<div className=" sortinxdirection">
|
|
|
|
|
<div className="w60 tophomsembolds">
|
|
|
|
|
方向:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="sortinxdirection minleng40">
|
|
|
|
|
<div className={titlestting==="全部"?" titlesttingcss xiaoshou":" titlesttingcssmy xiaoshou"} onClick={()=>this.settitlestting("全部")}>
|
|
|
|
|
全部
|
|
|
|
|
</div>
|
|
|
|
|
{this.props.disciplinesdata&&this.props.disciplinesdata.map((object, index) => {
|
|
|
|
|
return (
|
|
|
|
|
<div className={titlestting===object.name?" xiaoshou titlesttingcss":" titlesttingcssmy xiaoshou"} onClick={()=>this.settitlestting(object.name)}>
|
|
|
|
|
{object.name}
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
})}
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{/*课程*/}
|
|
|
|
|
<div className="mt30 sortinxdirection">
|
|
|
|
|
<div className="w60 tophomsembolds">
|
|
|
|
|
课程:
|
|
|
|
|
</div>
|
|
|
|
|
<div className="sortinxdirection minleng40">
|
|
|
|
|
|
|
|
|
|
{this.state.titlestting === undefined ? "" : this.state.titlestting.map((object, index) => {
|
|
|
|
|
{this.props.disciplinesdata&&this.props.disciplinesdata.map((objectn, index) => {
|
|
|
|
|
return (
|
|
|
|
|
objectn.sub_disciplines&&objectn.sub_disciplines.map((object, indexs) => {
|
|
|
|
|
return (
|
|
|
|
|
<div className="ml24">
|
|
|
|
|
{object}
|
|
|
|
|
<div className={index===0&&indexs===0&&titlesttings===object.name?"titlesttingcss xiaoshou":index===0&&indexs===0&&titlesttings!==object.name?"titlesttingcssmy xiaoshou"
|
|
|
|
|
|
|
|
|
|
:titlesttings===object.name?" titlesttingcss xiaoshou":"titlesttingcssmy xiaoshou"} onClick={()=>this.settitlesttings(object.name)}>
|
|
|
|
|
{object.name}
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
})
|
|
|
|
|
)
|
|
|
|
|
})}
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{/*知识点*/}
|
|
|
|
|
<div className="mt30">
|
|
|
|
|
<div className="w70 tophomsembold">
|
|
|
|
|
<div className="mt30 sortinxdirection">
|
|
|
|
|
<div className="w60 tophomsembolds">
|
|
|
|
|
知识点:
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div className="sortinxdirection minleng40">
|
|
|
|
|
|
|
|
|
|
{this.props.disciplinesdata&&this.props.disciplinesdata.map((object, index) => {
|
|
|
|
|
return (
|
|
|
|
|
object.sub_disciplines&&object.sub_disciplines.map((object, indexs) => {
|
|
|
|
|
return (
|
|
|
|
|
object.tag_disciplines&&object.tag_disciplines.map((object, indexss) => {
|
|
|
|
|
return (
|
|
|
|
|
<div className={index===0&&indexs===0&&indexss===0&&titlesttingss===object.name?"titlesttingcss xiaoshou":
|
|
|
|
|
index===0&&indexs===0&&indexss===0&&titlesttingss!==object.name?"titlesttingcssmy xiaoshou"
|
|
|
|
|
:titlesttingss===object.name?" titlesttingcss xiaoshou":" titlesttingcssmy xiaoshou"} onClick={()=>this.settitlesttingss(object.name)}>
|
|
|
|
|
{object.name}
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
})
|
|
|
|
|
)
|
|
|
|
|
})
|
|
|
|
|
)
|
|
|
|
|
})}
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|