|
|
|
@ -9,7 +9,7 @@ import '../css/Courses.css';
|
|
|
|
|
import Modals from "../../modals/Modals";
|
|
|
|
|
import AddStudentModal from '../members/modal/AddStudentModal'
|
|
|
|
|
import AddTeacherModal from '../members/modal/AddTeacherModal'
|
|
|
|
|
|
|
|
|
|
import Trialapplication from "../../login/Trialapplication";
|
|
|
|
|
|
|
|
|
|
// 点击按钮复制功能
|
|
|
|
|
// function jsCopy(){
|
|
|
|
@ -43,13 +43,20 @@ class CoursesBanner extends Component {
|
|
|
|
|
metype: 0,
|
|
|
|
|
modalsBottomval: "",
|
|
|
|
|
antIcon:false,
|
|
|
|
|
coursedata:undefined
|
|
|
|
|
coursedata:undefined,
|
|
|
|
|
user_phone_binded:false,
|
|
|
|
|
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,
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
updatabanner=()=>{
|
|
|
|
|
let courseId = this.props.match.params.coursesId;
|
|
|
|
@ -57,9 +64,19 @@ class CoursesBanner extends Component {
|
|
|
|
|
axios.get(url).then((result) => {
|
|
|
|
|
if( result!=undefined){
|
|
|
|
|
let data = result.data;
|
|
|
|
|
if(result.data.status === 407){
|
|
|
|
|
this.setState({
|
|
|
|
|
coursedata: data
|
|
|
|
|
isRenders:true,
|
|
|
|
|
coursedata: data,
|
|
|
|
|
showTrial:false,
|
|
|
|
|
})
|
|
|
|
|
}else{
|
|
|
|
|
this.setState({
|
|
|
|
|
coursedata: data,
|
|
|
|
|
showTrial:true,
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
@ -315,10 +332,13 @@ class CoursesBanner extends Component {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
|
let { Addcoursestypes, coursedata, modalsType, modalsTopval, loadtype,modalsBottomval,antIcon} = this.state;
|
|
|
|
|
let { Addcoursestypes, coursedata, modalsType, modalsTopval, loadtype,modalsBottomval,antIcon,user_phone_binded} = this.state;
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<Trialapplication {...this.state} user_phone_binded={user_phone_binded} ></Trialapplication>
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
coursedata === undefined || coursedata.status===401? <div id="course_info_1309" className="courseHead" style={{height: '206px'}}></div>:<div id="course_info_1309" className="courseHead" style={{height: '206px'}}>
|
|
|
|
|
|
|
|
|
|
{Addcoursestypes === true ? <Addcourses
|
|
|
|
@ -574,6 +594,9 @@ class CoursesBanner extends Component {
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|