From 208a5071ebb7d6775322f183aa912aaa47de6f5b 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 15:22:27 +0800 Subject: [PATCH 1/3] =?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 --- public/react/config/webpack.config.dev.js | 30 ++++++------- .../shixunHomework/ShixunhomeWorkItem.js | 4 +- .../shixunreport/Shixunechart.js | 25 ++++++++--- public/react/src/modules/tpm/TPMBanner.js | 44 ++++++++++++++----- .../tpm/shixunchild/Challenges/Challenges.js | 6 +-- 5 files changed, 73 insertions(+), 36 deletions(-) diff --git a/public/react/config/webpack.config.dev.js b/public/react/config/webpack.config.dev.js index dfd54f38b..ceddbd81b 100644 --- a/public/react/config/webpack.config.dev.js +++ b/public/react/config/webpack.config.dev.js @@ -114,21 +114,21 @@ module.exports = { // First, run the linter. // It's important to do this before Babel processes the JS. // 上线然后要注释回来 - { - test: /\.(js|jsx|mjs)$/, - enforce: 'pre', - use: [ - { - options: { - formatter: eslintFormatter, - eslintPath: require.resolve('eslint'), - - }, - loader: require.resolve('eslint-loader'), - }, - ], - include: paths.appSrc, - }, + // { + // test: /\.(js|jsx|mjs)$/, + // enforce: 'pre', + // use: [ + // { + // options: { + // formatter: eslintFormatter, + // eslintPath: require.resolve('eslint'), + // + // }, + // loader: require.resolve('eslint-loader'), + // }, + // ], + // include: paths.appSrc, + // }, { // "oneOf" will traverse all following loaders until one will // match the requirements. When no loader matches it will fall diff --git a/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js b/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js index 013d6d5e4..b63e210ef 100644 --- a/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js +++ b/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js @@ -304,7 +304,7 @@ class ShixunhomeWorkItem extends Component{ } { - this.props.isNotMember?this.props.discussMessage.private_icon===false? + this.props.isNotMember?this.props.discussMessage.private_icon===true? {discussMessage.name} : diff --git a/public/react/src/modules/courses/shixunHomework/shixunreport/Shixunechart.js b/public/react/src/modules/courses/shixunHomework/shixunreport/Shixunechart.js index 9fe14dc02..99b9d5748 100644 --- a/public/react/src/modules/courses/shixunHomework/shixunreport/Shixunechart.js +++ b/public/react/src/modules/courses/shixunHomework/shixunreport/Shixunechart.js @@ -10,6 +10,9 @@ function startechart(data){ var effChart = echarts.init(document.getElementById('shixun_skill_chart')); var option = { + title: { + text: '工作效率', + }, grid:{ left: '3%', right: '9%', @@ -42,7 +45,7 @@ function startechart(data){ xAxis: [ { type : 'value', - name: '学生序号', + name: '学生排名', scale:true, axisLabel : { formatter: ' ', @@ -57,11 +60,16 @@ function startechart(data){ ], yAxis: [ { - type : 'value', - name : '工作效率 = log(实训总得分/实训总耗时)', + type : "value", + name : " 实训总得分/实训总耗时", + nameGap: 20, + nameTextStyle: { + color: '#000', + fontSize:12 + }, scale:true, axisLabel : { - formatter: '{value} ' + formatter: '{value}' }, splitLine: { show: false @@ -100,6 +108,7 @@ function startechart(data){ name: data.username, xAxis:data.echart_data.myself_eff[0], yAxis:data.echart_data.myself_eff[1], + value:data.echart_data.myself_eff[1], } ], itemStyle: { @@ -158,6 +167,9 @@ function startechart(data){ var option1 = { + title: { + text: '能力值', + }, backgroundColor: '#fff', color: [ '#dd4444', '#fec42c', '#80F1BE' @@ -200,7 +212,7 @@ function startechart(data){ }, yAxis: { type: 'value', - name: '能力值(实训获得经验值/实训评测次数)', + name: " 实训获得经验值/实训评测次数", nameLocation: 'end', nameGap: 20, nameTextStyle: { @@ -230,7 +242,8 @@ function startechart(data){ { name: data.username, xAxis: data.echart_data.myself_object[0], - yAxis:data.echart_data.myself_object[1] + yAxis:data.echart_data.myself_object[1], + value:data.echart_data.myself_object[1] } ], itemStyle: { diff --git a/public/react/src/modules/tpm/TPMBanner.js b/public/react/src/modules/tpm/TPMBanner.js index 25a6ab9c7..64c2b39dd 100644 --- a/public/react/src/modules/tpm/TPMBanner.js +++ b/public/react/src/modules/tpm/TPMBanner.js @@ -10,7 +10,9 @@ import {Modal,Input,Radio,Pagination,message,Spin,Icon,Tooltip} from 'antd'; import 'antd/lib/pagination/style/index.css'; -import axios from 'axios'; +import axios from 'axios' + +import Modals from '../modals/Modals'; // import { Rating,Progress } from '@icedesign/base'; @@ -264,16 +266,29 @@ class TPMBanner extends Component { /* * 撤销发布按钮 * */ - cancel_publish=()=>{ - let id = this.props.match.params.shixunId; - let url="/shixuns/" + id +"/cancel_publish.json"; - axios.get(url).then((response) => { - this.props.showSnackbar(response.data.message); - window.location.reload() - }).catch((error) => { - console.log(error) - }); + ModalCancel=()=>{ + this.setState({ + Modalstype:false + }) + } + ModalSave=()=>{ + let id = this.props.match.params.shixunId; + let url="/shixuns/" + id +"/cancel_publish.json"; + axios.get(url).then((response) => { + this.props.showSnackbar(response.data.message); + window.location.reload() + }).catch((error) => { + console.log(error) + }); + } + cancel_publish=()=>{ + this.setState({ + Modalstype:true, + Modalstopval:"是否确认撤销发布?", + ModalCancel:this.ModalCancel, + ModalSave:this.ModalSave, + }) } @@ -523,6 +538,15 @@ class TPMBanner extends Component {
+ {this.state.Modalstype===true?:""} +

this.startshixunCombat(this.props.identity, item.challenge_id, "/editquestion")} - className="font-16 color05101a">{item.name+1} + className="font-16 color05101a">{item.name} : this.startshixunCombat(this.props.identity, item.challenge_id, "/editcheckpoint")} - className="font-16 color05101a">{item.name+2}:{item.name}: this.startshixunCombat(this.props.identity, item.challenge_id, "/editcheckpoint")} - className="font-16 color05101a">{item.name+2} + className="font-16 color05101a">{item.name} } Date: Wed, 26 Jun 2019 15:25:46 +0800 Subject: [PATCH 2/3] =?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/Listofworksstudentone.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index 716a6f442..d0628930f 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -229,7 +229,7 @@ class Listofworksstudentone extends Component { efficiencyscore: this.state.teacherdata.eff_score, finalscore: this.state.teacherdata.work_score, operating: "查看", - late_penalty: this.state.teacherdata.late_penalty=== null?"0":this.state.teacherdata.student_works[i].late_penalty === undefined?"0":this.state.teacherdata.student_works[i].late_penalty, + late_penalty: this.state.teacherdata.late_penalty=== null?"0":this.state.teacherdata.late_penalty === undefined?"0":this.state.teacherdata.late_penalty, ultimate_score:this.state.teacherdata.ultimate_score, user_name: this.state.teacherdata.user_name, user_login: this.state.teacherdata.user_login, @@ -333,7 +333,7 @@ class Listofworksstudentone extends Component { efficiencyscore: this.state.teacherdata.eff_score, finalscore: this.state.teacherdata.work_score, operating: "查看", - late_penalty: this.state.teacherdata.late_penalty=== null?"0":this.state.teacherdata.student_works[i].late_penalty === undefined?"0":this.state.teacherdata.student_works[i].late_penalty, + late_penalty: this.state.teacherdata.late_penalty=== null?"0":this.state.teacherdata.late_penalty === undefined?"0":this.state.teacherdata.late_penalty, ultimate_score:this.state.teacherdata.ultimate_score, user_name: this.state.teacherdata.user_name, user_login: this.state.teacherdata.user_login, @@ -355,8 +355,8 @@ class Listofworksstudentone extends Component { var teacherlist = undefined; } - console.log("datalistdatalist文件"); - console.log(datalist); + // console.log("datalistdatalist文件"); + // console.log(datalist); this.setState({ data: datalist, teacherlist: teacherlist, From fc23ea5b9b202838f28fdcb5a56b6b6c97919a73 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 15:32:30 +0800 Subject: [PATCH 3/3] =?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 --- .../react/src/modules/paths/ShixunPaths.css | 256 +++++++++--------- .../src/modules/tpm/component/TPMright.css | 154 +++++------ 2 files changed, 205 insertions(+), 205 deletions(-) diff --git a/public/react/src/modules/paths/ShixunPaths.css b/public/react/src/modules/paths/ShixunPaths.css index b7bd7bba6..d1e0a2325 100644 --- a/public/react/src/modules/paths/ShixunPaths.css +++ b/public/react/src/modules/paths/ShixunPaths.css @@ -1,129 +1,129 @@ -.paragraph:hover .status_li a{ - display: block; -} - -.newedu-filter-btn{ - display: block; - float: left; - padding: 0 9px; - height: 28px; - line-height: 28px; - border-radius: 14px; - background-color: #F5F5F5; - color: #666; - margin-right: 10px; - margin-bottom: 9px; -} - -.edu-filter-btn29BD8B{ - display: block; - float: left; - padding: 0 9px; - height: 28px; - line-height: 28px; - border-radius: 14px; - background-color: #29BD8B; - color: #FFF; - margin-right: 10px; - margin-bottom: 9px; -} - -.lesson-saved-list-item{ - border-bottom: none!important; - margin-bottom: 10px; - background-color: #fff; -} - -.click_add{ - border-top: none!important; -} -.white-panel li{border:1px solid #fafafa!important;} -.white-panel li.active{border:1px solid #4CACFF!important;} - -/* 选择实训列表 */ -.greybackHead{height: 40px;line-height: 40px;padding: 0px 20px;box-sizing: border-box;color: #676767;background-color: #eaeaea;} - -.mtf3{ - margin-top:-3px; -} - -.mtf5{ - margin-top: -5px; -} - -.color204{ - color:rgba(204,204,204,1); -} - -.lesson-saved-list-itemdrop{ - height: 93px; - overflow: hidden; -} - -.lesson-saved-list{ - position: relative; -} - -.itempositionleft{ - position: absolute; -} - -.itempositionright{ - position: absolute; -} - -.ant-input{ - background-color: #fafafa!important; -} -.ant-input:focus{ - background-color:#ffffff!important; -} - -.pathNavLine{bottom: -11px;} - -#shixun_operation:hover{ - color:#fff !important; -} - -.cursor{ - cursor: pointer; -} -.paragraph_nameid:hover{ - color:#4cacff !important; -} -/* 学习统计 */ -.statisticsNav{height: 100px;} -.statisticsNav ul{margin-top: 35px;} -.statisticsNav ul li{float: left;font-size: 18px;color: #4D4D4D;height: 64px;line-height: 64px;margin:0px 30px;cursor: pointer;} -.statisticsNav ul li a{color: #4D4D4D!important;} -.statisticsNav ul li.active{color: #05101A;border-bottom: 2px solid #05101A;} -.statisticsNav ul li.active a{color: #05101A!important; text-decoration: none !important;} - - -.next-loading{ - width:100%; - } - -.paddingleft22{ - text-align: left; - padding-left: 22px; -} - -.paddingl5{ - padding-left: 5px; -} - -.paddingl10{ - padding-left: 10px; -} - -.red{ - color:red; -} - -.pl38{ - padding-left: 38px; -} -.ml37{ - margin-left: 37px; +.paragraph:hover .status_li a{ + display: block; +} + +.newedu-filter-btn{ + display: block; + float: left; + padding: 0 9px; + /*height: 28px;*/ + line-height: 28px; + border-radius: 14px; + background-color: #F5F5F5; + color: #666; + margin-right: 10px; + margin-bottom: 9px; +} + +.edu-filter-btn29BD8B{ + display: block; + float: left; + padding: 0 9px; + height: 28px; + line-height: 28px; + border-radius: 14px; + background-color: #29BD8B; + color: #FFF; + margin-right: 10px; + margin-bottom: 9px; +} + +.lesson-saved-list-item{ + border-bottom: none!important; + margin-bottom: 10px; + background-color: #fff; +} + +.click_add{ + border-top: none!important; +} +.white-panel li{border:1px solid #fafafa!important;} +.white-panel li.active{border:1px solid #4CACFF!important;} + +/* 选择实训列表 */ +.greybackHead{height: 40px;line-height: 40px;padding: 0px 20px;box-sizing: border-box;color: #676767;background-color: #eaeaea;} + +.mtf3{ + margin-top:-3px; +} + +.mtf5{ + margin-top: -5px; +} + +.color204{ + color:rgba(204,204,204,1); +} + +.lesson-saved-list-itemdrop{ + height: 93px; + overflow: hidden; +} + +.lesson-saved-list{ + position: relative; +} + +.itempositionleft{ + position: absolute; +} + +.itempositionright{ + position: absolute; +} + +.ant-input{ + background-color: #fafafa!important; +} +.ant-input:focus{ + background-color:#ffffff!important; +} + +.pathNavLine{bottom: -11px;} + +#shixun_operation:hover{ + color:#fff !important; +} + +.cursor{ + cursor: pointer; +} +.paragraph_nameid:hover{ + color:#4cacff !important; +} +/* 学习统计 */ +.statisticsNav{height: 100px;} +.statisticsNav ul{margin-top: 35px;} +.statisticsNav ul li{float: left;font-size: 18px;color: #4D4D4D;height: 64px;line-height: 64px;margin:0px 30px;cursor: pointer;} +.statisticsNav ul li a{color: #4D4D4D!important;} +.statisticsNav ul li.active{color: #05101A;border-bottom: 2px solid #05101A;} +.statisticsNav ul li.active a{color: #05101A!important; text-decoration: none !important;} + + +.next-loading{ + width:100%; + } + +.paddingleft22{ + text-align: left; + padding-left: 22px; +} + +.paddingl5{ + padding-left: 5px; +} + +.paddingl10{ + padding-left: 10px; +} + +.red{ + color:red; +} + +.pl38{ + padding-left: 38px; +} +.ml37{ + margin-left: 37px; } \ No newline at end of file diff --git a/public/react/src/modules/tpm/component/TPMright.css b/public/react/src/modules/tpm/component/TPMright.css index 92f290dba..63f718f26 100644 --- a/public/react/src/modules/tpm/component/TPMright.css +++ b/public/react/src/modules/tpm/component/TPMright.css @@ -1,78 +1,78 @@ -/*b新标签*/ -.newedu-filter-btn{ - display: block; - float: left; - padding: 0 9px; - height: 28px; - line-height: 28px; - border-radius: 14px; - background-color: #F5F5F5; - color: #666; - margin-right: 10px; - margin-bottom: 9px; -} -.newedbox{ - /*flex-wrap: wrap;*/ - /*display: -webkit-flex; !* Safari *!*/ - /*display: flex;*/ - width: 340px; - position:relative; - overflow: hidden; -} -.newsubscript{ - position: absolute; - right: 23px; - bottom: 38px; - cursor: pointer; -} -.newsubscript:hover{ - color:deepskyblue; -} -.edu-filter-btn29BD8B{ - display: block; - float: left; - padding: 0 9px; - height: 28px; - line-height: 28px; - border-radius: 14px; - background-color: #29BD8B; - color: #FFF; - margin-right: 10px; - margin-bottom: 9px; -} -.relative{ - position:relative; -} -.newedboxheight{ - max-height:181px; -} -.newminheight{ - /*max-height: 670px;*/ - max-height: 300px; - overflow: auto; -} - -.delSubentry{ - font-size:7px; - font-family:MicrosoftYaHei; - font-weight:400; - color:rgba(76,172,255,1); - line-height:9px; - cursor: pointer; -} -.operationalter .delSubentry{ - font-size:15px !important; - line-height: 25px; -} -/*临时的tpi关闭按钮样式*/ -.headerRight a { - color: #1a3f5f; -} -/*实训做成弹窗a标签样式调整*/ -.-task-list-title a:link, .-task-list-title a:visited {color: #bcc6cd;} -.-task-list-title a:hover{ - color: #459be5; -} -.headerLeft .-header-right{ - height: 32px; +/*b新标签*/ +.newedu-filter-btn{ + display: block; + float: left; + padding: 0 9px; + /*height: 28px;*/ + line-height: 28px; + border-radius: 14px; + background-color: #F5F5F5; + color: #666; + margin-right: 10px; + margin-bottom: 9px; +} +.newedbox{ + /*flex-wrap: wrap;*/ + /*display: -webkit-flex; !* Safari *!*/ + /*display: flex;*/ + width: 340px; + position:relative; + overflow: hidden; +} +.newsubscript{ + position: absolute; + right: 23px; + bottom: 38px; + cursor: pointer; +} +.newsubscript:hover{ + color:deepskyblue; +} +.edu-filter-btn29BD8B{ + display: block; + float: left; + padding: 0 9px; + height: 28px; + line-height: 28px; + border-radius: 14px; + background-color: #29BD8B; + color: #FFF; + margin-right: 10px; + margin-bottom: 9px; +} +.relative{ + position:relative; +} +.newedboxheight{ + max-height:181px; +} +.newminheight{ + /*max-height: 670px;*/ + max-height: 300px; + overflow: auto; +} + +.delSubentry{ + font-size:7px; + font-family:MicrosoftYaHei; + font-weight:400; + color:rgba(76,172,255,1); + line-height:9px; + cursor: pointer; +} +.operationalter .delSubentry{ + font-size:15px !important; + line-height: 25px; +} +/*临时的tpi关闭按钮样式*/ +.headerRight a { + color: #1a3f5f; +} +/*实训做成弹窗a标签样式调整*/ +.-task-list-title a:link, .-task-list-title a:visited {color: #bcc6cd;} +.-task-list-title a:hover{ + color: #459be5; +} +.headerLeft .-header-right{ + height: 32px; } \ No newline at end of file