From f6a922004ca573747e43b6fc5c9995185e86f3ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Wed, 26 Jun 2019 11:34:51 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=20=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/modules/courses/Resource/index.js | 6 +- .../courses/coursesDetail/CoursesBanner.js | 7 +- .../courses/coursesHome/coursesHomeCard.js | 3 +- .../modules/courses/graduation/tasks/index.js | 8 +- .../shixunHomework/Homeworddescription.js | 226 +++++------ .../shixunHomework/ShixunhomeWorkItem.js | 4 +- .../shixunHomework/Workquestionandanswer.js | 41 +- .../courses/shixunHomework/shixunHomework.js | 5 +- .../react/src/modules/paths/ShixunPathCard.js | 156 ++++---- public/react/src/modules/tpm/TPMIndexHOC.js | 9 +- .../modules/tpm/TPMsettings/TPMsettings.js | 16 +- .../src/modules/tpm/shixuns/ShixunCard.js | 351 +++++++++--------- 12 files changed, 428 insertions(+), 404 deletions(-) diff --git a/public/react/src/modules/courses/Resource/index.js b/public/react/src/modules/courses/Resource/index.js index 6476ef2bb..96338818f 100644 --- a/public/react/src/modules/courses/Resource/index.js +++ b/public/react/src/modules/courses/Resource/index.js @@ -315,14 +315,14 @@ class Fileslists extends Component{ this.setState({ Modalstype:true, - Modalstopval:"公开后非课堂成员也可以访问查看", - ModalsBottomval:"是否确认公开?", + Modalstopval:"设为公开后,非课堂成员也可以访问查看", + ModalsBottomval:"是否确认设为公开?", ModalCancel:this.cancelmodel, ModalSave:this.saveonOpen, }) } - saveonOpen=()=>{ + saveonOpen=()=>{ this.setState({ Modalstype:false, }) diff --git a/public/react/src/modules/courses/coursesDetail/CoursesBanner.js b/public/react/src/modules/courses/coursesDetail/CoursesBanner.js index 363a83187..f4f097a33 100644 --- a/public/react/src/modules/courses/coursesDetail/CoursesBanner.js +++ b/public/react/src/modules/courses/coursesDetail/CoursesBanner.js @@ -122,11 +122,12 @@ class CoursesBanner extends Component { this.showActionPoll(i,s) } if (i === 3) { - s = "您确定要设置为公开?"; - this.showActionPoll(i,s) + s = "设为公开后,非课堂成员也可以访问查看"; + ss = "是否确认设为公开?"; + this.showActionPoll(i,s,ss) } - if(i===4){ + if(i===4){ if(coursedata.code_halt === true){ var url = `/courses/${this.props.match.params.coursesId}/set_invite_code_halt.json` axios.post(url, {}).then((result) => { diff --git a/public/react/src/modules/courses/coursesHome/coursesHomeCard.js b/public/react/src/modules/courses/coursesHome/coursesHomeCard.js index c5f6aeca7..c0a1a93f0 100644 --- a/public/react/src/modules/courses/coursesHome/coursesHomeCard.js +++ b/public/react/src/modules/courses/coursesHome/coursesHomeCard.js @@ -40,7 +40,8 @@ class coursesHomeCard extends Component{ className="mt80 mb25"/>

非成员不能访问

- + + {/*target="_blank"*/} { item.is_public===1&&item.id===1309?
diff --git a/public/react/src/modules/courses/graduation/tasks/index.js b/public/react/src/modules/courses/graduation/tasks/index.js index c044c1711..10d71afe4 100644 --- a/public/react/src/modules/courses/graduation/tasks/index.js +++ b/public/react/src/modules/courses/graduation/tasks/index.js @@ -235,15 +235,17 @@ class GraduationTasks extends Component{ this.setState({ Modalstype:true, - Modalstopval:"公开后非课堂成员也可以访问查看", - ModalsBottomval:"是否确认公开?", + Modalstopval:"设为公开后,非课堂成员也可以访问查看", + ModalsBottomval:"是否确认设为公开?", ModalCancel:this.cancelmodel, ModalSave:this.saveonOpen, }) } - // onSticky = (message) => { + + + // onSticky = (message) => { // const cid = this.props.match.params.coursesId // const url = `/messages/${message.id}/sticky_top.json` // axios.put(url, { diff --git a/public/react/src/modules/courses/shixunHomework/Homeworddescription.js b/public/react/src/modules/courses/shixunHomework/Homeworddescription.js index a6e1351e0..405490f38 100644 --- a/public/react/src/modules/courses/shixunHomework/Homeworddescription.js +++ b/public/react/src/modules/courses/shixunHomework/Homeworddescription.js @@ -1,114 +1,114 @@ -import React, {Component} from "react"; -import { - Form, - Select, - Input, - Button, - Checkbox, - Upload, - Icon, - message, - Modal, - Table, - Divider, - InputNumber, - Tag, - DatePicker, - Radio, - Tooltip, - notification -} from "antd"; -import TPMMDEditor from '../../tpm/challengesnew/TPMMDEditor'; -import {Link, Switch, Route, Redirect} from 'react-router-dom'; -import axios from 'axios'; -import '../css/members.css' -import "../common/formCommon.css" -import '../css/Courses.css' -import '../css/members.css' -import "../common/formCommon.css" -import '../css/Courses.css' -import moment from 'moment'; -import '../css/members.css' -import "../common/formCommon.css" -import './style.css' -import Workquestionandanswer from "./Workquestionandanswer"; -const { TextArea } = Input; - - -class Homeworddescription extends Component { - - constructor(props) { - super(props); - this.state = { - props: props, - description:undefined, - } - - - } - - componentDidMount() { - - - } - //取消操作 - clickcancel =()=>{ - this.props.NOReleaseNotes(); - } - //确认操作 - onSaveExercise=()=>{ - if(this.state.description === "" || this.state.description===undefined || this.state.description === null){ - this.props.showNotification("请输入作业说明"); - return - } - this.props.ReleaseNotes(this.state.description); - } - //获取输入框 - settextarea=(e)=>{ - this.setState({ - description:e - }) - } - render() { - return ( -
-
- - - {/**/} - - -
- - -
- - -
-
- ) - } - - - - - - -} -const Homeworddescriptions = Form.create({name: 'taskPollNew'})(Homeworddescription); +import React, {Component} from "react"; +import { + Form, + Select, + Input, + Button, + Checkbox, + Upload, + Icon, + message, + Modal, + Table, + Divider, + InputNumber, + Tag, + DatePicker, + Radio, + Tooltip, + notification +} from "antd"; +import TPMMDEditor from '../../tpm/challengesnew/TPMMDEditor'; +import {Link, Switch, Route, Redirect} from 'react-router-dom'; +import axios from 'axios'; +import '../css/members.css' +import "../common/formCommon.css" +import '../css/Courses.css' +import '../css/members.css' +import "../common/formCommon.css" +import '../css/Courses.css' +import moment from 'moment'; +import '../css/members.css' +import "../common/formCommon.css" +import './style.css' +import Workquestionandanswer from "./Workquestionandanswer"; +const { TextArea } = Input; + + +class Homeworddescription extends Component { + + constructor(props) { + super(props); + this.state = { + props: props, + description:undefined, + } + + + } + + componentDidMount() { + + + } + //取消操作 + clickcancel =()=>{ + this.props.NOReleaseNotes(); + } + //确认操作 + onSaveExercise=()=>{ + if(this.state.description === "" || this.state.description===undefined || this.state.description === null){ + this.props.showNotification("请输入作业说明"); + return + } + this.props.ReleaseNotes(this.state.description); + } + //获取输入框 + settextarea=(e)=>{ + this.setState({ + description:e + }) + } + render() { + return ( +
+
+ + + {/**/} + + +
+ + +
+ + +
+
+ ) + } + + + + + + +} +const Homeworddescriptions = Form.create({name: 'taskPollNew'})(Homeworddescription); export default Homeworddescriptions; \ No newline at end of file diff --git a/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js b/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js index 272ac6418..a21d6f977 100644 --- a/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js +++ b/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js @@ -334,7 +334,7 @@ class ShixunhomeWorkItem extends Component{ {discussMessage.commit_count===undefined?"":{discussMessage.commit_count} 已交} {discussMessage.uncommit_count===undefined?"":{discussMessage.uncommit_count} 未交} {/*{discussMessage.replies_count} 3 未评*/} - 0?"剩余时间":""} placement="bottom"> + {discussMessage.status_time} @@ -349,7 +349,7 @@ class ShixunhomeWorkItem extends Component{ {this.props.isAdmin?
实训详情 - this.editname(discussMessage.name,discussMessage.homework_id)} className={"btn colorblue ml20 font-16"}>重命名 + {this.props.isClassManagement()?this.editname(discussMessage.name,discussMessage.homework_id)} className={"btn colorblue ml20 font-16"}>重命名:""} 设置
:""} diff --git a/public/react/src/modules/courses/shixunHomework/Workquestionandanswer.js b/public/react/src/modules/courses/shixunHomework/Workquestionandanswer.js index 7ebbeb473..438babfea 100644 --- a/public/react/src/modules/courses/shixunHomework/Workquestionandanswer.js +++ b/public/react/src/modules/courses/shixunHomework/Workquestionandanswer.js @@ -429,27 +429,36 @@ class Workquestionandanswer extends Component { {jobsettingsdata === undefined|| jobsettingsdata.data.description===null? "无" :
+
{/* /!*{}}>
{/* /!*{jobsettingsdata.data.description}*!/*/} - {/* */} + {/* */}
- {/*
*/} - {/*

*/} - {/* /!*{ChallengesDataList === undefined ? "" :ChallengesDataList.description===null?""*!/*/} - {/* */} - {/* /!*}*!/*/} - {/*

*/} - - {/*
*/} + {/*
*/} + {/*

*/} + {/* /!*{ChallengesDataList === undefined ? "" :ChallengesDataList.description===null?""*!/*/} + {/* */} + {/* /!*}*!/*/} + {/*

*/} + + {/*
*/}
} diff --git a/public/react/src/modules/courses/shixunHomework/shixunHomework.js b/public/react/src/modules/courses/shixunHomework/shixunHomework.js index 70acf0f80..c3be53486 100644 --- a/public/react/src/modules/courses/shixunHomework/shixunHomework.js +++ b/public/react/src/modules/courses/shixunHomework/shixunHomework.js @@ -827,8 +827,8 @@ class ShixunHomework extends Component{ this.setState({ Modalstype:true, - Modalstopval:"公开后非课堂成员也可以访问查看", - ModalsBottomval:"是否确认公开?", + Modalstopval:"设为公开后,非课堂成员也可以访问查看", + ModalsBottomval:"是否确认设为公开?", ModalCancel:this.cancelmodel, ModalSave:this.saveonOpen, }) @@ -1190,6 +1190,7 @@ class ShixunHomework extends Component{ isAdmin={this.props.isAdmin()} isStudent={this.props.isStudent()} isNotMember={this.props.isNotMember()} + isClassManagement={this.props.isClassManagement()} checkBox={this.props.isAdmin()?:""} match={this.props.match} coursedata={this.props.coursedata} diff --git a/public/react/src/modules/paths/ShixunPathCard.js b/public/react/src/modules/paths/ShixunPathCard.js index e2c529aea..2d1090820 100644 --- a/public/react/src/modules/paths/ShixunPathCard.js +++ b/public/react/src/modules/paths/ShixunPathCard.js @@ -1,78 +1,80 @@ -import React, { Component } from 'react'; -import {getImageUrl} from 'educoder'; -import { BrowserRouter as Router, Route, Link } from "react-router-dom"; -import { Tooltip } from 'antd'; -import axios from 'axios'; - - -class ShixunPathCard extends Component{ - constructor(props) { - super(props) - } - render(){ - let {pathList}=this.props; - return( -
- { - pathList && pathList.length > 0 ? - ( -
- { - pathList && pathList.map((item,key)=>{ - - return( -
- { - item.tag_name === null ? "" : -
- {item.tag_name} - -
- } - - -
- -

非试用内容,需要授权

-
- - 13?1543211263 - -
-

- {item.name} -

-

- - - {item.stages_count} - - - {/**/} - {/*{item.shixuns_count}*/} - {/**/} - - - {item.members_count} - -

-
-
- ) - }) - } -
- ):( -
- -

暂无数据哦~

-
- ) - } - -
- ) - } -} +import React, { Component } from 'react'; +import {getImageUrl} from 'educoder'; +import { BrowserRouter as Router, Route, Link } from "react-router-dom"; +import { Tooltip } from 'antd'; +import axios from 'axios'; + + +class ShixunPathCard extends Component{ + constructor(props) { + super(props) + } + render(){ + let {pathList}=this.props; + return( +
+ { + pathList && pathList.length > 0 ? + ( +
+ { + pathList && pathList.map((item,key)=>{ + + return( +
+ { + item.tag_name === null ? "" : +
+ {item.tag_name} + +
+ } + + +
+ +

非试用内容,需要授权

+
+ + {/*target="_blank"*/} + 13?1543211263 + +
+

+ {item.name} + {/*target="_blank"*/} +

+

+ + + {item.stages_count} + + + {/**/} + {/*{item.shixuns_count}*/} + {/**/} + + + {item.members_count} + +

+
+
+ ) + }) + } +
+ ):( +
+ +

暂无数据哦~

+
+ ) + } + +
+ ) + } +} export default ShixunPathCard; \ No newline at end of file diff --git a/public/react/src/modules/tpm/TPMIndexHOC.js b/public/react/src/modules/tpm/TPMIndexHOC.js index 66d3d9273..1bdc505c3 100644 --- a/public/react/src/modules/tpm/TPMIndexHOC.js +++ b/public/react/src/modules/tpm/TPMIndexHOC.js @@ -183,7 +183,12 @@ export function TPMIndexHOC(WrappedComponent) { // return false return this.state.coursedata&&this.state.coursedata.course_identity === 0 } - // 管理员等 + // 课堂管理等 + isClassManagement = () => { + // return this.state.coursedata&&this.state.coursedata.course_identity >= 0 && + return this.state.coursedata&&this.state.coursedata.course_identity < 2 + } + //老师等 isAdminOrCreator = () => { // return this.state.coursedata&&this.state.coursedata.course_identity >= 0 && return this.state.coursedata&&this.state.coursedata.course_identity < 3 @@ -279,7 +284,7 @@ export function TPMIndexHOC(WrappedComponent) { const common = { isSuperAdmin:this.isSuperAdmin, isAdminOrCreator:this.isAdminOrCreator, - + isClassManagement:this.isClassManagement, isAdmin: this.isAdmin, isAdminOrTeacher: this.isAdminOrTeacher, isStudent: this.isStudent, diff --git a/public/react/src/modules/tpm/TPMsettings/TPMsettings.js b/public/react/src/modules/tpm/TPMsettings/TPMsettings.js index 85275e620..b60b641e0 100644 --- a/public/react/src/modules/tpm/TPMsettings/TPMsettings.js +++ b/public/react/src/modules/tpm/TPMsettings/TPMsettings.js @@ -324,7 +324,7 @@ export default class TPMsettings extends Component { opening_time:response.data.shixun.opening_time, newuse_scope:response.data.shixun.use_scope, scope_partments: response.data.shixun.scope_partment.length, - shixunmemoMDvalue:response.data.shixun.evaluate_script + shixunmemoMDvalue:response.data.shixun.evaluate_script, }) // if(response.data.status===403){ @@ -598,7 +598,7 @@ export default class TPMsettings extends Component { evaluate_script, exec_time, webssh, use_scope, trainee, can_copy, task_pass, test_set_permission, hide_code, code_hidden, forbid_copy, vnc,multi_webssh, opening_time, pod_exist_time,shixunmemoMDvalue } = this.state; - let operateauthority=this.props.identity<4&&this.props.status==0||this.props.identity===1&&this.props.status==2||this.props.identity===1&&this.props.status==1; + let operateauthority=this.props.identity<4&&this.state.status==0||this.props.identity===1&&this.state.status==2||this.props.identity===1&&this.state.status==1; const description_editormd = this.description_editormd.getValue(); @@ -1084,7 +1084,7 @@ export default class TPMsettings extends Component { } const dateFormat = 'YYYY-MM-DD HH:mm:ss'; - let operateauthority=this.props.identity===1?true:this.props.identity<4&&this.props.status==0; + let operateauthority=this.props.identity===1?true:this.props.identity<4&&this.state.status==0?true:false; return (
@@ -1092,21 +1092,21 @@ export default class TPMsettings extends Component {
配置 { - this.props.identity===1&&this.props.status==2? + this.props.identity===1&&this.state.status==2? this.operateshixuns(2)}> 永久关闭 :"" } { - this.props.identity < 4 && this.props.status==0? + this.props.identity < 4 && this.state.status==0? this.operateshixuns(1)}> 删除实训 :"" } { - this.props.identity == 1 && this.props.status == 2 ? + this.props.identity == 1 && this.state.status == 2 ? this.operateshixuns(1)}> 删除实训 @@ -1510,7 +1510,7 @@ export default class TPMsettings extends Component {
-
+

公开程度

对所有公开 (选中则所有已被试用授权的用户可以学习) @@ -1556,7 +1556,7 @@ export default class TPMsettings extends Component { onClick={(key)=>this.deleteScopeInput(key)} // style={{display:this.props.status===2&&this.props.identity>1||this.props.status===1&&this.props.identity>1===true?"none":"block"}} > - {this.props.identity===1?"x":this.props.status===2&&scope_partment===scope_partments||this.props.status===1&&scope_partment===scope_partments?"":"×"} + {this.props.identity===1?"x":this.state.status===2&&scope_partment===scope_partments||this.state.status===1&&scope_partment===scope_partments?"":"×"}
) diff --git a/public/react/src/modules/tpm/shixuns/ShixunCard.js b/public/react/src/modules/tpm/shixuns/ShixunCard.js index 7237f9e35..e0850143c 100644 --- a/public/react/src/modules/tpm/shixuns/ShixunCard.js +++ b/public/react/src/modules/tpm/shixuns/ShixunCard.js @@ -1,174 +1,177 @@ -import React, { Component } from 'react'; -import { Redirect } from 'react-router'; - -import { BrowserRouter as Router, Route, Link, Switch } from "react-router-dom"; - -import PropTypes from 'prop-types'; - -import classNames from 'classnames'; - -// import { Rating,Loading} from '@icedesign/base'; - -import {getImageUrl,setImagesUrl, toPath} from 'educoder'; - -// import { Pagination,Row,Col } from 'antd'; - -import 'antd/lib/pagination/style/index.css'; - -import './shixunCss/shixunCard.css'; - -import Rating from '@icedesign/base/lib/rating'; - -import Pagination from '@icedesign/base/lib/pagination'; - -// import Loading from '@icedesign/base/lib/loading'; - -// 引入业务组件样式 -import '@icedesign/base/lib/pagination/style.js'; - -import '@icedesign/base/lib/rating/style.js'; - -import { Tooltip } from 'antd'; - -// import '@icedesign/base/lib/loading/style.js'; - -import axios from 'axios'; - -const $ = window.$; - -class ShixunCard extends Component { - constructor(props) { - super(props) - - this.state = { - startValue:[], - order_by:"", - page:1, - limit:16, - keyword:"", - status:0, - diff:0, - hideme:false, - tag_level:3, - tag_id:'' - } - - } - - PaginationonChange=(pageNumber)=> { - this.props.shixunsPage(pageNumber); - } - - render() { - let {middleshixundata, pagination, typepvisible, pages, totalcount} = this.props; - return ( -
- {/**/} - -
-
-
- -

暂无数据哦~

-
-
-
-
-
    - -
-
-
-
-
- -
-
-
- { middleshixundata===undefined?" ":middleshixundata.map((item,key)=>{ - return( -
- { - item.tag_name === null ? "": -
- {item.tag_name} - -
- } -
- -

非试用内容,需要授权

-
- - - {/**/} - - - -
-

- - {item.name} - -

- -

- - - - {item.score_info===null?"5分":item.score_info+"分"} -

- -

- - - {item.challenges_count} - - - - {/**/} - {/**/} - {/*{item.exp}*/} - {/**/} - {/**/} - - - - {item.stu_num} - - - - {item.level} -

- -
-
- ) - }) - } - -
- -
- {/*totalcount*/} -
- {/**/} - {/* 不加参数请求的时候,没返回总数了。加了个比较大的数字,让他可以翻页 */} - -
- -
- -
- {/*
*/} -
- ) - } -} - -export default ShixunCard; +import React, { Component } from 'react'; +import { Redirect } from 'react-router'; + +import { BrowserRouter as Router, Route, Link, Switch } from "react-router-dom"; + +import PropTypes from 'prop-types'; + +import classNames from 'classnames'; + +// import { Rating,Loading} from '@icedesign/base'; + +import {getImageUrl,setImagesUrl, toPath} from 'educoder'; + +// import { Pagination,Row,Col } from 'antd'; + +import 'antd/lib/pagination/style/index.css'; + +import './shixunCss/shixunCard.css'; + +import Rating from '@icedesign/base/lib/rating'; + +import Pagination from '@icedesign/base/lib/pagination'; + +// import Loading from '@icedesign/base/lib/loading'; + +// 引入业务组件样式 +import '@icedesign/base/lib/pagination/style.js'; + +import '@icedesign/base/lib/rating/style.js'; + +import { Tooltip } from 'antd'; + +// import '@icedesign/base/lib/loading/style.js'; + +import axios from 'axios'; + +const $ = window.$; + +class ShixunCard extends Component { + constructor(props) { + super(props) + + this.state = { + startValue:[], + order_by:"", + page:1, + limit:16, + keyword:"", + status:0, + diff:0, + hideme:false, + tag_level:3, + tag_id:'' + } + + } + + PaginationonChange=(pageNumber)=> { + this.props.shixunsPage(pageNumber); + } + + render() { + let {middleshixundata, pagination, typepvisible, pages, totalcount} = this.props; + return ( +
+ {/**/} + +
+
+
+ +

暂无数据哦~

+
+
+
+
+
    + +
+
+
+
+
+ +
+
+
+ { middleshixundata===undefined?" ":middleshixundata.map((item,key)=>{ + return( +
+ { + item.tag_name === null ? "": +
+ {item.tag_name} + +
+ } +
+ +

非试用内容,需要授权

+
+ + + {/**/} + + + {/*target="_blank"*/} + +
+

+ + {item.name} + +

+ + {/*target="_blank"*/} + +

+ + + + {item.score_info===null?"5分":item.score_info+"分"} +

+ +

+ + + {item.challenges_count} + + + + {/**/} + {/**/} + {/*{item.exp}*/} + {/**/} + {/**/} + + + + {item.stu_num} + + + + {item.level} +

+ +
+
+ ) + }) + } + +
+ +
+ {/*totalcount*/} +
+ {/**/} + {/* 不加参数请求的时候,没返回总数了。加了个比较大的数字,让他可以翻页 */} + +
+ +
+ +
+ {/*
*/} +
+ ) + } +} + +export default ShixunCard; From 2d8b2ef96f0fd45d519f9dce443a2723c919f910 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Wed, 26 Jun 2019 11:35:00 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../courses/shixunHomework/Listofworks.js | 16 ++++++---- .../src/modules/login/Trialapplication.js | 32 +++++++++---------- public/react/src/modules/tpm/NewHeader.js | 2 +- 3 files changed, 25 insertions(+), 25 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworks.js b/public/react/src/modules/courses/shixunHomework/Listofworks.js index 6d19b13ef..98ba43e55 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworks.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworks.js @@ -75,7 +75,7 @@ class Listofworks extends Component { teacherlist: undefined, searchtext: "", course_groupysls: undefined, - course_groupyslstwo: undefined, + course_groupyslstwo: [], visible: false, userid: 0, course_group: null, @@ -1164,7 +1164,7 @@ class Listofworks extends Component { // console.log(checkedValues); this.setState({ unlimited: 0, - course_groupyslstwo: undefined, + course_groupyslstwo: [], loadingstate: true, }) @@ -1172,7 +1172,7 @@ class Listofworks extends Component { } else if (checkedValues.length === data.length) { this.setState({ unlimited: 0, - course_groupyslstwo: undefined, + course_groupyslstwo: [], loadingstate: true, }) this.Startsorting(this.state.order, checkedValues, this.state.checkedValuesineinfo, this.state.searchtext, this.state.page, this.state.limit); @@ -1198,6 +1198,7 @@ class Listofworks extends Component { this.setState({ unlimitedtwo: 1, course_groupysls: undefined, + checkedValuesineinfo:[], loadingstate: true, }) @@ -1206,6 +1207,7 @@ class Listofworks extends Component { this.setState({ unlimitedtwo: 1, course_groupysls: undefined, + checkedValuesineinfo:[], loadingstate: true, }) this.Startsorting(this.state.order, this.state.checcourse_groupyslstwokedValuesine, checkedValues, this.state.searchtext, this.state.page, this.state.limit); @@ -1485,22 +1487,22 @@ class Listofworks extends Component { notlimiteds = () => { this.setState({ checkedValuesine: undefined, - course_groupyslstwo: undefined, + course_groupyslstwo: [], unlimited: 0, loadingstate: true, }) - this.Startsorting(this.state.order, null, this.state.checkedValuesineinfo, this.state.searchtext, this.state.page, this.state.limit); + this.Startsorting(this.state.order, [], this.state.checkedValuesineinfo, this.state.searchtext, this.state.page, this.state.limit); } notlimitedst = () => { // console.log(this.state.course_group_info); this.setState({ unlimitedtwo: 1, - checkedValuesineinfo: undefined, + checkedValuesineinfo: [], course_groupysls: undefined, loadingstate: true, }) - this.Startsorting(this.state.order, this.state.course_groupyslstwo, undefined, this.state.searchtext, this.state.page, this.state.limit); + this.Startsorting(this.state.order, this.state.course_groupyslstwo, [], this.state.searchtext, this.state.page, this.state.limit); } //立即截止确定按钮 coursetaskend = () => { diff --git a/public/react/src/modules/login/Trialapplication.js b/public/react/src/modules/login/Trialapplication.js index e5bc75466..846971e82 100644 --- a/public/react/src/modules/login/Trialapplication.js +++ b/public/react/src/modules/login/Trialapplication.js @@ -30,7 +30,7 @@ class Trialapplication extends Component { Phonenumberisnotco: undefined, Phonenumberisnotcobool: false, readonlyInput: true, - user_phone_binded: false, + user_phone_binded: props.user_phone_binded, showTrial: false, user: undefined, } @@ -383,7 +383,7 @@ class Trialapplication extends Component { { isRenders === false ? "" : -
+