From 5fdd157034f9a1e4011bf822aae1b19f4ac5db2f Mon Sep 17 00:00:00 2001 From: caicai8 <1149225589@qq.com> Date: Fri, 23 Aug 2019 15:51:47 +0800 Subject: [PATCH] =?UTF-8?q?=E6=AF=95=E8=AE=BE=E9=80=89=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../graduation/topics/GraduateTopicDetail.js | 2 +- .../courses/graduation/topics/GraduateTopicNew.js | 15 +++++++++------ 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/public/react/src/modules/courses/graduation/topics/GraduateTopicDetail.js b/public/react/src/modules/courses/graduation/topics/GraduateTopicDetail.js index b24277a2c..b518c44f3 100644 --- a/public/react/src/modules/courses/graduation/topics/GraduateTopicDetail.js +++ b/public/react/src/modules/courses/graduation/topics/GraduateTopicDetail.js @@ -114,7 +114,7 @@ class GraduateTopicDetail extends Component{

{tableData && tableData.graduation_topic_name} - this.props.history.goBack()}>返回 + 返回

diff --git a/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js b/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js index 94c238a5e..3845721be 100644 --- a/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js +++ b/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js @@ -12,6 +12,8 @@ import "../../common/formCommon.css" import '../style.css' import '../../css/Courses.css' import { WordsBtn, City } from 'educoder' + +import {Link} from 'react-router-dom' // import City from './City' // import './board.css' @@ -20,6 +22,7 @@ import { WordsBtn, City } from 'educoder' const confirm = Modal.confirm; const $ = window.$ const { Option } = Select; +const NAME_COUNT=60; // 新建毕设选题 // https://lanhuapp.com/web/#/item/project/board/detail?pid=a3bcd4b1-99ce-4e43-8ead-5b8b0a410807&project_id=a3bcd4b1-99ce-4e43-8ead-5b8b0a410807&image_id=c6d9b36f-7701-4035-afdb-62404681108c class GraduateTopicNew extends Component{ @@ -38,7 +41,7 @@ class GraduateTopicNew extends Component{ topic_source:[], topic_type:[], attachments:undefined, - addonAfter:60, + addonAfter:0, left_banner_id:undefined, course_name:undefined } @@ -99,7 +102,7 @@ class GraduateTopicNew extends Component{ topic_source:result.data.topic_source, topic_type:result.data.topic_type, attachments:result.data.attachments, - addonAfter:20-parseInt(result.data.selected_data.name.length) + addonAfter:parseInt(result.data.selected_data.name.length) }) this.props.form.setFieldsValue({ tea_id:result.data.selected_data.tea_id, @@ -257,9 +260,9 @@ class GraduateTopicNew extends Component{ // 附件相关 ------------ END changeTopicName=(e)=>{ - let num= 60 - parseInt(e.target.value.length); + // let num= 60 - parseInt(e.target.value.length); this.setState({ - addonAfter:num < 0 ? 0 : num + addonAfter:e.target.value.length }) } render() { @@ -331,7 +334,7 @@ class GraduateTopicNew extends Component{

{topicId==undefined?"新建":"编辑"}毕设选题

- this.props.history.goBack()} className="color-grey-6 fr font-16">返回 + 返回
@@ -366,7 +369,7 @@ class GraduateTopicNew extends Component{ max: 60, message: '最大限制为60个字符', }], })( - + )}