Merge branch 'dev_aliyun' into dev_hs

dev_hs
SylorHuang 6 years ago
commit 620a00cc2a

@ -1,4 +1,5 @@
class ChangeExericse1936Scores < ActiveRecord::Migration[5.2] class ChangeExericse1936Scores < ActiveRecord::Migration[5.2]
include ExercisesHelper
def change def change
#1936的试卷成绩有问题。 #1936的试卷成绩有问题。
# #https://www.educoder.net/courses/2935/exercises/1936/users/pizfnr5ts # #https://www.educoder.net/courses/2935/exercises/1936/users/pizfnr5ts

@ -652,10 +652,10 @@ class CoursesBanner extends Component {
`} `}
</style> </style>
<Breadcrumb separator="|" className={"mt5"}> <Breadcrumb separator="|" className={"mt5"}>
<Breadcrumb.Item onClick={()=>this.setHistoryFun("/courses/"+this.props.match.params.coursesId+"/teachers")}> <Breadcrumb.Item onClick={()=>this.setHistoryFun("/courses/"+this.props.match.params.coursesId+"/teachers")} className={"pointer"}>
<span className="color-grey-c font-16"><span className={"mr10"}>教师</span> <span className={"mr10"}>{coursedata.teacher_count}</span></span> <span className="color-grey-c font-16"><span className={"mr10"}>教师</span> <span className={"mr10"}>{coursedata.teacher_count}</span></span>
</Breadcrumb.Item> </Breadcrumb.Item>
<Breadcrumb.Item onClick={()=>this.setHistoryFun("/courses/"+this.props.match.params.coursesId+"/students")}> <Breadcrumb.Item onClick={()=>this.setHistoryFun("/courses/"+this.props.match.params.coursesId+"/students")} className={"pointer"}>
<span className="color-grey-c font-16"><span className={"mr10 ml10"}>学生</span> <span className={"mr10"}>{coursedata.student_count}</span></span> <span className="color-grey-c font-16"><span className={"mr10 ml10"}>学生</span> <span className={"mr10"}>{coursedata.student_count}</span></span>
</Breadcrumb.Item> </Breadcrumb.Item>
<Breadcrumb.Item>{coursedata.credit===null?"": <Breadcrumb.Item>{coursedata.credit===null?"":

@ -60,11 +60,27 @@ class Elearning extends Component{
isSpin:false, isSpin:false,
}) })
}); });
try {
if(this.props.current_user!==undefined){
this.setState({
userlogin :this.props.current_user.login,
})
}
}catch (e) {
console.log("12312312312")
console.log(e);
}
} }
componentDidUpdate = (prevProps) => { componentDidUpdate = (prevProps) => {
console.log("componentDidUpdate");
console.log(prevProps);
console.log(this.props);
if(prevProps.current_user!=this.props.current_user){ if(prevProps.current_user!=this.props.current_user){
if(this.props.current_user!==undefined){ if(this.props.current_user!==undefined){
// console.log(this.props.current_user.login);
// console.log(prevProps.current_user.login);
this.setState({ this.setState({
userlogin :this.props.current_user.login, userlogin :this.props.current_user.login,
}) })
@ -76,6 +92,8 @@ class Elearning extends Component{
//开始学习 //开始学习
Startlearning=()=>{ Startlearning=()=>{
let {userlogin} = this.state; let {userlogin} = this.state;
console.log("userlogin");
console.log(userlogin);
if (userlogin === undefined) { if (userlogin === undefined) {
this.setState({ this.setState({
isRender: true isRender: true

@ -139,8 +139,8 @@ class ShixunPathSearch extends Component{
<div className="mt20 educontent mb20 clearfix"> <div className="mt20 educontent mb20 clearfix">
{/*<a href="javascript:void(0)" className={ order == "publish_time" ? "fl mr20 font-16 bestChoose active" : "fl mr20 font-16 bestChoose"} onClick={ () => this.changeStatus("publish_time")}>全部</a>*/} {/*<a href="javascript:void(0)" className={ order == "publish_time" ? "fl mr20 font-16 bestChoose active" : "fl mr20 font-16 bestChoose"} onClick={ () => this.changeStatus("publish_time")}>全部</a>*/}
{/*<a href="javascript:void(0)" className={ order == "mine" ? "fl mr20 font-16 bestChoose active" : "fl mr20 font-16 bestChoose"} onClick={ () => this.changeStatus("mine")}>我的</a>*/} {/*<a href="javascript:void(0)" className={ order == "mine" ? "fl mr20 font-16 bestChoose active" : "fl mr20 font-16 bestChoose"} onClick={ () => this.changeStatus("mine")}>我的</a>*/}
<span className={ order == "updated_at" ? "fl mr20 font-16 bestChoose active" : "fl mr20 font-16 bestChoose"} onClick={ () => this.changeStatus("updated_at")}>最新</span> <span className={ order == "updated_at" ? "fl mr20 font-16 bestChoose active pointer" : "fl mr20 font-16 bestChoose pointer"} onClick={ () => this.changeStatus("updated_at")}>最新</span>
<span className={ order == "myshixun_count" ? "fl mr20 font-16 bestChoose active" : "fl mr20 font-16 bestChoose"} onClick={ () => this.changeStatus("myshixun_count")}>最热</span> <span className={ order == "myshixun_count" ? "fl mr20 font-16 bestChoose active pointer" : "fl mr20 font-16 bestChoose pointer"} onClick={ () => this.changeStatus("myshixun_count")}>最热</span>
{/*<div className="fr mr5 search-new">*/} {/*<div className="fr mr5 search-new">*/}
{/*/!* <Search*/} {/*/!* <Search*/}
{/*placeholder="请输入路径名称进行搜索"*/} {/*placeholder="请输入路径名称进行搜索"*/}

@ -95,6 +95,10 @@ a:hover.link-color-grey03{color:#3498db!important;}
/*通用文字大小样式*/ /*通用文字大小样式*/
.font-8{ font-size: 8px!important;}
.font-9{ font-size: 9px!important;}
.font-10{ font-size: 10px!important;}
.font-11{ font-size: 11px!important;}
.font-12{ font-size: 12px!important;} .font-12{ font-size: 12px!important;}
.font-13{ font-size: 13px!important;} .font-13{ font-size: 13px!important;}
.font-14{ font-size: 14px!important;} .font-14{ font-size: 14px!important;}

@ -3744,3 +3744,11 @@ a.singlepublishtwo{
.square-main p{ .square-main p{
margin-bottom: 0em; margin-bottom: 0em;
} }
.bestChoose{
cursor: pointer;
}
.pointer{
cursor: pointer;
}
Loading…
Cancel
Save