diff --git a/public/react/src/App.js b/public/react/src/App.js index f59f76010..15105f749 100644 --- a/public/react/src/App.js +++ b/public/react/src/App.js @@ -331,7 +331,7 @@ class App extends Component { {/* */} {/* 兴趣页面*/} - + {/**/} diff --git a/public/react/src/modules/courses/poll/PollNew.js b/public/react/src/modules/courses/poll/PollNew.js index 060b8b482..be6b7e5eb 100644 --- a/public/react/src/modules/courses/poll/PollNew.js +++ b/public/react/src/modules/courses/poll/PollNew.js @@ -95,6 +95,12 @@ class PollNew extends Component { // 初始化数据 componentDidMount = () => { // console.log("componentDidMount 50") + if( this.props.isStudent() === true){ + + this.props.history.push("/403") + + return + } if (this.props.match.params.news !== undefined) { if (this.props.match.params.news === "new") { this.state.Newedit === true; @@ -780,19 +786,21 @@ class PollNew extends Component { } } - if (maxtie < 3) { - if (object.question.question_type === 1) { - this.props.showNotification(`选项不能少于3个!`); + if (object.question.question_type === 1) { + if (maxtie < 2) { + this.props.showNotification(`选项不能少于2个!`); return + } } else if (object.question.question_type === 2) { + if (maxtie < 3) { this.props.showNotification(`选项不能少于3个!`); - return + } } - } + if (object.question.question_type === 2) { if (object.question.max_choices > 0) { @@ -1260,17 +1268,19 @@ class PollNew extends Component { } } - if (maxtie < 3) { if (object.question.question_type === 1) { - this.props.showNotification('选项不能少于3个!'); + if (maxtie < 2) { + this.props.showNotification('选项不能少于2个!'); return + } } else if (object.question.question_type === 2) { + if (maxtie < 3) { this.props.showNotification('选项不能少于3个!'); return + } } - } if (object.question.question_type === 2) { if (object.question.max_choices > 0) { @@ -2496,7 +2506,7 @@ class PollNew extends Component { ( {item.question.answers === undefined ? "" : item.question.answers.map((items, i) => { return ( -
+
{/*
{items.answer_text}
*/} @@ -2511,7 +2521,7 @@ class PollNew extends Component { ( {item.question.answers === undefined ? "" : item.question.answers.map((items, i) => { return ( -
+
{items.answer_text} diff --git a/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js b/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js index 8b7bbb544..2cb40241d 100644 --- a/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js +++ b/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js @@ -32,6 +32,7 @@ class ShixunWorkModal extends Component{ newgroup_list.push(item) }) if( response.data.ungroup_list!== undefined || response.data.ungroup_list !== null){ + console.log() newgroup_list.push(response.data.ungroup_list) } this.setState({ diff --git a/public/react/src/modules/login/EducoderLogin.js b/public/react/src/modules/login/EducoderLogin.js index f084dec66..7c6dcbe9e 100644 --- a/public/react/src/modules/login/EducoderLogin.js +++ b/public/react/src/modules/login/EducoderLogin.js @@ -25,6 +25,7 @@ import '../courses/css/Courses.css'; import beijintulogontwo from '../../../src/images/login/beijintulogontwo.png'; import educodernet from '../../../src/images/login/educodernet.png'; import LoginRegisterComponent from '../user/LoginRegisterComponent'; +import InterestpageComponent from '../user/Interestpage' import FindPasswordComponent from '../user/FindPasswordComponent'; import passopen from "../../images/login/passopen.png"; //educoder登入页面 @@ -59,26 +60,26 @@ class EducoderLogin extends Component { super(props); if( props.match.url === "/changepassword" ){ this.state = { - showbool: false, + showbool: 3, logini:3, } }else { if(props.match.url === "/login"){ this.state = { - showbool: true, + showbool: 1, loginstatus:true, logini:1, } }else if(props.match.url === "/register"){ this.state = { - showbool: true, + showbool: 1, loginstatus:false, logini:2, } }else{ this.state = { - showbool: true, + showbool: 1, logini:1, } @@ -100,16 +101,18 @@ class EducoderLogin extends Component { }) } - Setshowbool = () => { - - if (this.state.showbool === true) { + Setshowbool = (e) => { + if (e===1) { this.setState({ - showbool: false + showbool: 1 }) - - } else { + } else if(e===2) { + this.setState({ + showbool: 2 + }) + }else if(e===3){ this.setState({ - showbool: true + showbool: 3 }) } } @@ -135,43 +138,53 @@ class EducoderLogin extends Component { "align-items": "center", "width": "100%" }}> -
+
{ - showbool === true ? + showbool === 1 ?
-
+
+ + Setshowbool={(e)=>this.Setshowbool(e)} >
- : -
-
- - -
-
- + :showbool === 2 ? +
+ + +
+ : +
+
+ this.Setshowbool(e)}> + +
+
} -
© 2019 EduCoder湘ICP备17009477号Trustie   &   IntelliDE inside.
+
) diff --git a/public/react/src/modules/tpm/NewHeader.js b/public/react/src/modules/tpm/NewHeader.js index 7af055314..600f6c803 100644 --- a/public/react/src/modules/tpm/NewHeader.js +++ b/public/react/src/modules/tpm/NewHeader.js @@ -756,7 +756,7 @@ submittojoinclass=(value)=>{
  • 账号管理
  • {/*
  • this.educoderlogin()} >登入测试接口
  • */} {/*
  • this.trialapplications()} >试用申请
  • */} -
  • 兴趣页
  • + {/*
  • 兴趣页
  • */}
  • {/*退出*/} diff --git a/public/react/src/modules/user/FindPasswordComponent.js b/public/react/src/modules/user/FindPasswordComponent.js index e7380c12f..393dbc023 100644 --- a/public/react/src/modules/user/FindPasswordComponent.js +++ b/public/react/src/modules/user/FindPasswordComponent.js @@ -44,7 +44,7 @@ class LoginRegisterComponent extends Component { }); }; StudyMakeMoney = () => { // 调用父组件方法 - this.props.Setshowbool(); + this.props.Setshowbool(1); } diff --git a/public/react/src/modules/user/Interestpage.js b/public/react/src/modules/user/Interestpage.js index 5ac180242..0d01ab563 100644 --- a/public/react/src/modules/user/Interestpage.js +++ b/public/react/src/modules/user/Interestpage.js @@ -1,51 +1,110 @@ import React, {Component} from 'react'; -import {BrowserRouter as Router, Route, Link, Switch} from "react-router-dom"; -import {getImageUrl, DragValidator} from 'educoder'; -import {Tabs, Input, Checkbox, Button, notification} from 'antd'; +import {Button} from 'antd'; import axios from 'axios'; import './common.css' - - +import mytc from './img/mytc.png'; +import skzbdx from './img/skzbdx.png'; +import zyrs1 from './img/zyrs1.png'; +import gouxuan from './img/gouxuan.png'; +import meigouxuan from './img/meigouxuan.png'; +import qdkf from './img/qdkf.png'; +import hdkf from './img/hdkf.png'; +import ydkf from './img/ydkf.png'; +import sjk from './img/sjk.png'; +import ysj from './img/ysj.png'; +import yunwei from './img/yunwei.png'; +import rgzn from './img/rgzn.png'; +import qita from './img/qita.png'; //父组件 EducoderLogin.js class InterestpageComponent extends Component { constructor(props) { super(props) this.state = { - login: "", - password: "", - passwords: "", - seconds: 60, - codes: "", - getverificationcodes: true, - Phonenumberisnotco: undefined, - Phonenumberisnotcobool: false, - s: 'text', - classpass: "text", - readonlyInput: true, + gouxuans: 0, + gouxuans2:0, + gouxuans3:[{id:1,name:"前端开发",bool:false,url:qdkf},{id:2,name:"后端开发",bool:false,url:hdkf},{id:3,name:"移动开发",bool:false,url:ydkf},{id:4,name:"数据库",bool:false,url:sjk},{id:5,name:"云计算和大数据",bool:false,url:ysj},{id:6,name:"运维与测试",bool:false,url:yunwei},{id:7,name:"人工智能",bool:false,url:rgzn},{id:8,name:"其他",bool:false,url:qita}], } } + Clickteacher=(e)=>{ + console.log(e); + if(e === 1){ + this.setState({ + gouxuans:1, + }) + }else if(e === 2){ + this.setState({ + gouxuans:2, + }) + }else if(e === 3){ + this.setState({ + gouxuans:3, + }) + } + } + Clickteacher2=(e)=>{ + console.log(e); + let {gouxuans3} =this.state; + for (var i=0;i +
    + +
    +
    请选择你的职业
    +
    +
    +
    this.Clickteacher(1)}>{gouxuans ===1? :}老师
    +
    +
    +
    +
    this.Clickteacher(2)}>{gouxuans===2? :}学生
    +
    +
    +
    +
    this.Clickteacher(3)}>{gouxuans===3?:}专业人士
    +
    +
    +
    +
    选择你可能感兴趣的内容
    + +
    基于你关注的内容推荐
    +
    -
    -
    -
    1
    -
    2
    -
    3
    + {gouxuans3&&gouxuans3.map((item,key)=>{ + return( +
    this.Clickteacher2(item.id)}> + {item.bool===true?:
    } + + {item.name} +
    + ) + })}
    - +
    diff --git a/public/react/src/modules/user/LoginRegisterComponent.js b/public/react/src/modules/user/LoginRegisterComponent.js index c5a2175a9..9d7790ee1 100644 --- a/public/react/src/modules/user/LoginRegisterComponent.js +++ b/public/react/src/modules/user/LoginRegisterComponent.js @@ -138,7 +138,7 @@ class LoginRegisterComponent extends Component { ; StudyMakeMoney = () => { // 调用父组件方法 - this.props.Setshowbool(); + this.props.Setshowbool(3); // this.props.Setlogins(3); this.setState({ login: "", @@ -344,7 +344,8 @@ class LoginRegisterComponent extends Component { passwords: "", Agreetotheterms: "", }) - this.props.history.push(result.data.redirect_uri) + // this.props.history.push(result.data.redirect_uri) + this.props.Setshowbool(2); } catch (e) { diff --git a/public/react/src/modules/user/common.css b/public/react/src/modules/user/common.css index e9f1d0818..d60f59ef0 100644 --- a/public/react/src/modules/user/common.css +++ b/public/react/src/modules/user/common.css @@ -47,6 +47,119 @@ .dragValidator { margin-bottom: 16px; } - .ysldivhome{ - flex-direction: column; - } \ No newline at end of file + .ysldivhome1{ + display: flex; + flex-direction: row; + margin-left: 100px; + margin-right: 129px; + margin-top: 10px; + } + .ysldivhome2{ + display: flex; + flex-flow: row wrap; + align-content:stretch; + margin-top: 10px; + } + .ysldivhomediv{ + width: 101px; + height: 147px; + + } + .ysldivhomediv1{ + width: 110px; + height: 110px; + border-radius:50%; + box-shadow:3px 10px 21px 0px rgba(76,76,76,0.15); + background: #fff; + display: flex; + flex-direction:column; + margin-left: 73px; + margin-top: 15px; + } +.ysldivhomediv2{ + width: 110px; + height: 110px; + border-radius:50%; + box-shadow:3px 10px 21px 0px rgba(76,76,76,0.15); + background: #fff; + display: flex; + flex-direction:column; + margin-left: 73px; + margin-top: 20px; +} + .ysldivhomedivtxt{ + width:101px; + height:27px; + margin-bottom: 10px; + font-size: 14px; + text-align: center; + + } + .ysldivhomedivimg{ + width: 101px; + height: 101px; + } + .ysllogin_register_contents{ + display: flex; + margin-top: 30px; + justify-content: center; + box-shadow:3px 10px 21px 0px rgba(76,76,76,0.15); + border-radius:6px; + background: #fff; + } + .ysllogin_section { + width:800px; + height: 620px; + display: flex; + align-items: center; + flex-direction: column; + } + .yslspans1{ + text-align: center; + font-size: 16px; + color: #111C24; + } + .yslspans2{ + text-align: center; + font-size: 15px; + color: #05101A; + } + .yslspans3{ + text-align: center; + font-size: 13px; + color: #656565; + } + .yslbutton{ + width:255px; + height: 36px; + margin-top:30px; + margin-bottom: 19px; + } + .mt22{ + margin-top: 22px; + } + .gouxuanimg{ + margin-right: 10px; + margin-bottom: 2px; + } + .textall{ + text-align: center; + font-size: 13px; + color: #4B4B4B; + } + .div1img{ + display: flex; + justify-content:center; + width: 60px; + margin-left: 27px; + + } +.yslgouxuanimg{ + width: 20px; + height: 20px; + margin-left: 75px; + +} +.yslgouxuanimg2{ + height: 20px; +} \ No newline at end of file diff --git a/public/react/src/modules/user/img/gouxuan.png b/public/react/src/modules/user/img/gouxuan.png new file mode 100644 index 000000000..7d8b0ab65 Binary files /dev/null and b/public/react/src/modules/user/img/gouxuan.png differ diff --git a/public/react/src/modules/user/img/hdkf.png b/public/react/src/modules/user/img/hdkf.png new file mode 100755 index 000000000..a1dd25d53 Binary files /dev/null and b/public/react/src/modules/user/img/hdkf.png differ diff --git a/public/react/src/modules/user/img/meigouxuan.png b/public/react/src/modules/user/img/meigouxuan.png new file mode 100644 index 000000000..631b3675f Binary files /dev/null and b/public/react/src/modules/user/img/meigouxuan.png differ diff --git a/public/react/src/modules/user/img/mytc.png b/public/react/src/modules/user/img/mytc.png new file mode 100755 index 000000000..28ab09698 Binary files /dev/null and b/public/react/src/modules/user/img/mytc.png differ diff --git a/public/react/src/modules/user/img/qdkf.png b/public/react/src/modules/user/img/qdkf.png new file mode 100755 index 000000000..ef214dcdd Binary files /dev/null and b/public/react/src/modules/user/img/qdkf.png differ diff --git a/public/react/src/modules/user/img/qita.png b/public/react/src/modules/user/img/qita.png new file mode 100755 index 000000000..c7edb4174 Binary files /dev/null and b/public/react/src/modules/user/img/qita.png differ diff --git a/public/react/src/modules/user/img/rgzn.png b/public/react/src/modules/user/img/rgzn.png new file mode 100755 index 000000000..7f1616f4a Binary files /dev/null and b/public/react/src/modules/user/img/rgzn.png differ diff --git a/public/react/src/modules/user/img/sjk.png b/public/react/src/modules/user/img/sjk.png new file mode 100755 index 000000000..ef9ccf959 Binary files /dev/null and b/public/react/src/modules/user/img/sjk.png differ diff --git a/public/react/src/modules/user/img/skzbdx.png b/public/react/src/modules/user/img/skzbdx.png new file mode 100755 index 000000000..7aadff97c Binary files /dev/null and b/public/react/src/modules/user/img/skzbdx.png differ diff --git a/public/react/src/modules/user/img/ydkf.png b/public/react/src/modules/user/img/ydkf.png new file mode 100755 index 000000000..f770ed940 Binary files /dev/null and b/public/react/src/modules/user/img/ydkf.png differ diff --git a/public/react/src/modules/user/img/ysj.png b/public/react/src/modules/user/img/ysj.png new file mode 100755 index 000000000..17c08446a Binary files /dev/null and b/public/react/src/modules/user/img/ysj.png differ diff --git a/public/react/src/modules/user/img/yunwei.png b/public/react/src/modules/user/img/yunwei.png new file mode 100755 index 000000000..4e0265efe Binary files /dev/null and b/public/react/src/modules/user/img/yunwei.png differ diff --git a/public/react/src/modules/user/img/zyrs1.png b/public/react/src/modules/user/img/zyrs1.png new file mode 100755 index 000000000..776e70637 Binary files /dev/null and b/public/react/src/modules/user/img/zyrs1.png differ