From 4e4915a3faf3a6470bd6d8e71678ca216a830a2e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com>
Date: Thu, 25 Jul 2019 17:09:04 +0800
Subject: [PATCH 1/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/react/src/AppConfig.js | 4 +---
public/react/src/modules/paths/PathDetail/PathDetailIndex.js | 4 ++--
2 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js
index ddef777d6..12959fd9a 100644
--- a/public/react/src/AppConfig.js
+++ b/public/react/src/AppConfig.js
@@ -10,6 +10,7 @@ broadcastChannelOnmessage('refreshPage', () => {
})
function locationurl(list){
+ debugger
if (window.location.port === "3007") {
} else {
@@ -142,9 +143,6 @@ export function initAxiosInterceptors(props) {
// console.log("401401401")
// }
if (response.data.status === 403) {
- // props.history.replace('/403')
- // 这里会分2个情况,1、刚进入页面发请求返回的403;2、进入页面后,其他用户操作触发请求返回的403;
- // TODO 这里做一个403弹框比较好?
locationurl('/403');
}
diff --git a/public/react/src/modules/paths/PathDetail/PathDetailIndex.js b/public/react/src/modules/paths/PathDetail/PathDetailIndex.js
index a72771c39..8f5802c9e 100644
--- a/public/react/src/modules/paths/PathDetail/PathDetailIndex.js
+++ b/public/react/src/modules/paths/PathDetail/PathDetailIndex.js
@@ -146,7 +146,7 @@ class PathDetailIndex extends Component{
if (result.data.status === 403) {
debugger
- window.location.href = "/403";
+ // window.location.href = "/403";
return;
}
@@ -173,7 +173,7 @@ class PathDetailIndex extends Component{
}
if (result.data.status === 403 ) {
debugger
- window.location.href = "/403";
+ // window.location.href = "/403";
return;
}
From d7ed523e9db7246320615cd2c2903dfac9b15d1c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com>
Date: Thu, 25 Jul 2019 17:12:30 +0800
Subject: [PATCH 2/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/react/src/AppConfig.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js
index 12959fd9a..9c407c82c 100644
--- a/public/react/src/AppConfig.js
+++ b/public/react/src/AppConfig.js
@@ -142,7 +142,7 @@ export function initAxiosInterceptors(props) {
// if(response.data.status === 401){
// console.log("401401401")
// }
- if (response.data.status === 403) {
+ if (response.data.status === 403||response.data.status === "403") {
locationurl('/403');
}
From d4c7053c4cecec6042aabf9a022015442428cda0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Thu, 25 Jul 2019 17:18:43 +0800
Subject: [PATCH 3/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/react/src/modules/user/LoginRegisterComponent.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/public/react/src/modules/user/LoginRegisterComponent.js b/public/react/src/modules/user/LoginRegisterComponent.js
index 241fc2c6f..a54a5bb43 100644
--- a/public/react/src/modules/user/LoginRegisterComponent.js
+++ b/public/react/src/modules/user/LoginRegisterComponent.js
@@ -898,7 +898,7 @@ class LoginRegisterComponent extends Component {
{
From 388bcbfde012c0e934ef2748fb2e736204f9f154 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com>
Date: Thu, 25 Jul 2019 17:30:13 +0800
Subject: [PATCH 4/9] b
---
public/react/src/modules/paths/PathDetail/PathDetailIndex.js | 2 ++
1 file changed, 2 insertions(+)
diff --git a/public/react/src/modules/paths/PathDetail/PathDetailIndex.js b/public/react/src/modules/paths/PathDetail/PathDetailIndex.js
index 8f5802c9e..1ba1a3c13 100644
--- a/public/react/src/modules/paths/PathDetail/PathDetailIndex.js
+++ b/public/react/src/modules/paths/PathDetail/PathDetailIndex.js
@@ -343,9 +343,11 @@ class PathDetailIndex extends Component{
简介
{detailInfoList===undefined?"":detailInfoList.allow_statistics===true?
+
+
:""
}
From 2ed0c3c61f73c870b039e71667be1efcfae60fe3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Thu, 25 Jul 2019 17:43:29 +0800
Subject: [PATCH 5/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../shixunHomework/Listofworksstudentone.js | 39 +++++++++----------
1 file changed, 19 insertions(+), 20 deletions(-)
diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js
index 81e388d6f..462ec541f 100644
--- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js
+++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js
@@ -997,10 +997,10 @@ class Listofworksstudentone extends Component {
if(result === undefined){
return
}
- if(result.data.message!==undefined){
-
- return;
- }
+ // if(result.data.message!==undefined){
+ //
+ // return;
+ // }
this.setState({
teacherdata: result.data,
@@ -1059,9 +1059,6 @@ class Listofworksstudentone extends Component {
}
axios.post(urll, data).then((result) => {
if (result) {
- if(result.data.message!==undefined){
- return;
- }
// console.log("学生未截至未公开的作品列表")
// console.log(JSON.stringify(result))
this.setState({
@@ -1491,11 +1488,14 @@ class Listofworksstudentone extends Component {
let url = "/homework_commons/"+homeworkid+"/update_student_score.json?shixun_id="+teacherdata.shixun_id;
axios.get(url).then((response) => {
-
- this.props.showNotification(`${response.data.message}`);
- // var homeworkid = this.props.match.params.homeworkid;
- this.Getalistofworks(homeworkid);
- this.props.history.replace( matchurl );
+ if(response){
+ if(response.data.status===0) {
+ this.props.showNotification(`${response.data.message}`);
+ // var homeworkid = this.props.match.params.homeworkid;
+ this.Getalistofworks(homeworkid);
+ // this.props.history.replace(matchurl);
+ }
+ }
// this.Getalistofworkstwo("", "", "", "", 1, 20);
}).catch((error) => {
console.log(error)
@@ -2160,15 +2160,17 @@ class Listofworksstudentone extends Component {
axios.get(url).then((response) => {
if(response){
- if(response.data.message!==undefined){
- return;
- }
+ if(response.data.status===0){
+ // if(response.data.message!==undefined){
+ // return;
+ // }
this.setState({
loadingstate: true
})
- this.Startsortingt(this.state.orders, this.state.course_groupyslstwo, this.state.checkedValuesineinfo, this.state.searchtext, 1, this.state.limit);
+ this.Getalistofworks(homeworkid);
this.props.showNotification(`${response.data.message}`);
- this.props.history.replace( matchurl );
+ }
+ // this.props.history.replace( matchurl );
}
}).catch((error) => {
console.log(error)
@@ -2214,9 +2216,6 @@ class Listofworksstudentone extends Component {
if(response === undefined){
return
}
- if(response.data.message!==undefined){
- return;
- }
if(response.data.status&&response.data.status===-1){
}else if(response.data.status&&response.data.status===-2){
From 535030d30f54af6c0de076f7fcbac117278551f6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com>
Date: Thu, 25 Jul 2019 17:57:21 +0800
Subject: [PATCH 6/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/react/src/modules/courses/new/CoursesNew.js | 7 +++++--
.../modules/courses/shixunHomework/Trainingjobsetting.js | 4 ++--
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/public/react/src/modules/courses/new/CoursesNew.js b/public/react/src/modules/courses/new/CoursesNew.js
index 73c1dded9..d032737ea 100644
--- a/public/react/src/modules/courses/new/CoursesNew.js
+++ b/public/react/src/modules/courses/new/CoursesNew.js
@@ -309,11 +309,14 @@ class CoursesNew extends Component {
};
handleChange=(value)=>{
-
+ debugger
this.props.form.setFieldsValue({
- // course:value,
+ course:value,
classroom:value
})
+ this.setState({
+ course:value,
+ })
};
handleSearchschool=(value)=>{
diff --git a/public/react/src/modules/courses/shixunHomework/Trainingjobsetting.js b/public/react/src/modules/courses/shixunHomework/Trainingjobsetting.js
index ec45b081c..3d1aecf5b 100644
--- a/public/react/src/modules/courses/shixunHomework/Trainingjobsetting.js
+++ b/public/react/src/modules/courses/shixunHomework/Trainingjobsetting.js
@@ -479,8 +479,8 @@ class Trainingjobsetting extends Component {
return;
}
- if (this.state.latededuction <= 0) {
- this.props.showNotification(`迟交扣分数不能小于等于零`);
+ if (this.state.latededuction <0) {
+ this.props.showNotification(`迟交扣分数不能小于零`);
return;
}
From 734ae79d2cd491238f4b114778051b5f856da919 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com>
Date: Thu, 25 Jul 2019 17:58:48 +0800
Subject: [PATCH 7/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/react/src/modules/courses/new/CoursesNew.js | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/public/react/src/modules/courses/new/CoursesNew.js b/public/react/src/modules/courses/new/CoursesNew.js
index d032737ea..73c1dded9 100644
--- a/public/react/src/modules/courses/new/CoursesNew.js
+++ b/public/react/src/modules/courses/new/CoursesNew.js
@@ -309,14 +309,11 @@ class CoursesNew extends Component {
};
handleChange=(value)=>{
- debugger
+
this.props.form.setFieldsValue({
- course:value,
+ // course:value,
classroom:value
})
- this.setState({
- course:value,
- })
};
handleSearchschool=(value)=>{
From 463dd5841c48740a9e53dfbdf2158eca88339af2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Thu, 25 Jul 2019 17:58:59 +0800
Subject: [PATCH 8/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/modules/user/FindPasswordComponent.js | 12 +++++++-
.../modules/user/LoginRegisterComponent.js | 30 ++++++++++++-------
2 files changed, 31 insertions(+), 11 deletions(-)
diff --git a/public/react/src/modules/user/FindPasswordComponent.js b/public/react/src/modules/user/FindPasswordComponent.js
index 6317c5134..814fed4d3 100644
--- a/public/react/src/modules/user/FindPasswordComponent.js
+++ b/public/react/src/modules/user/FindPasswordComponent.js
@@ -189,6 +189,9 @@ class LoginRegisterComponent extends Component {
if (this.state.login === undefined|| this.state.login.length ===0 || this.state.login === "") {
this.setState({
Phonenumberisnotco:"账号不能为空",
+ Phonenumberisnotcobool: false,
+ dragOk: false,
+ Whethertoverify: this.state.Whethertoverify === true ? false : true,
})
return
}
@@ -197,6 +200,8 @@ class LoginRegisterComponent extends Component {
// this.openNotification(`请拖动滑块完成验证`,2);
this.setState({
Phonenumberisnotcosytdhk:"请拖动滑块完成验证",
+ dragOk: false,
+ Whethertoverify: this.state.Whethertoverify === true ? false : true,
})
return
}
@@ -479,12 +484,15 @@ class LoginRegisterComponent extends Component {
//是否验证通过
dragOkCallback = () => {
console.log(this.state.login);
-
+ this.setState({
+ Phonenumberisnotcosytdhk:undefined,
+ })
if (this.state.login === "" || this.state.login.length === 0) {
this.setState({
Phonenumberisnotco: "账号不能为空",
Phonenumberisnotcobool: false,
+ Phonenumberisnotcosytdhk:undefined,
dragOk: false,
Whethertoverify: this.state.Whethertoverify === true ? false : true,
})
@@ -502,6 +510,7 @@ class LoginRegisterComponent extends Component {
this.setState({
Phonenumberisnotco: stringdata,
Phonenumberisnotcobool: false,
+ Phonenumberisnotcosytdhk:undefined,
dragOk:false,
Whethertoverify: this.state.Whethertoverify === true ? false : true,
})
@@ -509,6 +518,7 @@ class LoginRegisterComponent extends Component {
this.setState({
Phonenumberisnotco: undefined,
Phonenumberisnotcobool: true,
+ Phonenumberisnotcosytdhk:undefined,
dragOk: true,
});
diff --git a/public/react/src/modules/user/LoginRegisterComponent.js b/public/react/src/modules/user/LoginRegisterComponent.js
index a54a5bb43..8da41e0e9 100644
--- a/public/react/src/modules/user/LoginRegisterComponent.js
+++ b/public/react/src/modules/user/LoginRegisterComponent.js
@@ -207,12 +207,15 @@ class LoginRegisterComponent extends Component {
//是否验证通过
dragOkCallback = () => {
debugger
+ this.setState({
+ Phonenumberisnotcosytdhk:undefined,
+ })
if (this.state.logins.length === 0) {
this.setState({
- Phonenumberisnotcos: undefined,
- Phonenumberisnotcobool: false,
- dragOk:true,
-
+ Phonenumberisnotcos:"账号不能为空",
+ Phonenumberisnotcobool: true,
+ dragOk:false,
+ Whethertoverify:this.state.Whethertoverify===true?false:true,
})
return;
}
@@ -373,21 +376,28 @@ class LoginRegisterComponent extends Component {
// this.openNotification(`请同意服务协议条款`,2);
// return;
// }
+ if (this.state.logins === undefined || this.state.logins === ""||this.state.logins.length===0) {
+ this.setState({
+ Phonenumberisnotcos:"账号不能为空",
+ Phonenumberisnotcobool: true,
+ dragOk:false,
+ Whethertoverify:this.state.Whethertoverify===true?false:true,
+ })
+ return
+ }
if(this.state.pciphone===true){
if (this.state.dragOk === false) {
// this.openNotification(`请拖动滑块完成验证`,2);
this.setState({
Phonenumberisnotcosytdhk:"请拖动滑块完成验证",
+ dragOk:false,
+ Whethertoverify:this.state.Whethertoverify===true?false:true,
})
return
}
}
- if (this.state.logins === undefined || this.state.logins === ""||this.state.logins.length===0) {
- this.setState({
- Phonenumberisnotcos:"账号不能为空",
- })
- return
- } else if (this.state.codes === undefined || this.state.codes == ""||this.state.codes.length===0) {
+
+ if (this.state.codes === undefined || this.state.codes == ""||this.state.codes.length===0) {
// this.openNotification(`请输入验证码`,2);
this.setState({
Phonenumberisnotcosyzm:"验证码不能为空",
From 3ca4437ad657f83be16af30f65e6212845eb556e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Thu, 25 Jul 2019 18:01:44 +0800
Subject: [PATCH 9/9] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/react/src/modules/user/FindPasswordComponent.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/public/react/src/modules/user/FindPasswordComponent.js b/public/react/src/modules/user/FindPasswordComponent.js
index 814fed4d3..6ee2a1de1 100644
--- a/public/react/src/modules/user/FindPasswordComponent.js
+++ b/public/react/src/modules/user/FindPasswordComponent.js
@@ -179,7 +179,7 @@ class LoginRegisterComponent extends Component {
}
//找回密码
Retrievepassword = () => {
- if (this.state.Phonenumberisnotcobool === false) {
+ if (this.state.Phonenumberisnotcobool === false&&this.state.Phonenumberisnotco!==undefined) {
this.openNotification(this.state.Phonenumberisnotco);
this.setState({
Whethertoverify:this.state.Whethertoverify===true?false:true,