diff --git a/public/react/src/common/course/ActionBtn.js b/public/react/src/common/course/ActionBtn.js index f10a56910..484c85eb0 100644 --- a/public/react/src/common/course/ActionBtn.js +++ b/public/react/src/common/course/ActionBtn.js @@ -1,7 +1,7 @@ import React, { Component } from 'react'; import {Link} from 'react-router-dom' -const map={"blue":"blueFull","greyBack":"greyBack","grey":"greyWidthFixed","green":"greenBack",'greyLine':"greyLine", +const map={"blue":"blueFull","greyBack":"greyBack","grey":"greyWidthFixed","green":"greenBack",'greyLine':"greyLine",'orangeLine':"orangeLine", 'colorBlue': 'colorBlue', // 蓝字白底 } class ActionBtn extends Component { diff --git a/public/react/src/modules/courses/boards/BoardsNew.js b/public/react/src/modules/courses/boards/BoardsNew.js index 166bc6f57..58cd0c02b 100644 --- a/public/react/src/modules/courses/boards/BoardsNew.js +++ b/public/react/src/modules/courses/boards/BoardsNew.js @@ -278,7 +278,7 @@ class BoardsNew extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/busyWork/CommonWorkPost.js b/public/react/src/modules/courses/busyWork/CommonWorkPost.js index 796249bcd..5b43a8237 100644 --- a/public/react/src/modules/courses/busyWork/CommonWorkPost.js +++ b/public/react/src/modules/courses/busyWork/CommonWorkPost.js @@ -597,7 +597,7 @@ render(){ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/busyWork/NewWork.js b/public/react/src/modules/courses/busyWork/NewWork.js index 2aa8e4742..fb2d18de0 100644 --- a/public/react/src/modules/courses/busyWork/NewWork.js +++ b/public/react/src/modules/courses/busyWork/NewWork.js @@ -338,7 +338,7 @@ class NewWork extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, @@ -357,7 +357,7 @@ class NewWork extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/coursesPublic/AccessoryModal.js b/public/react/src/modules/courses/coursesPublic/AccessoryModal.js index 82cf1cea9..3b25ceb6d 100644 --- a/public/react/src/modules/courses/coursesPublic/AccessoryModal.js +++ b/public/react/src/modules/courses/coursesPublic/AccessoryModal.js @@ -257,7 +257,7 @@ class AccessoryModal extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/coursesPublic/AccessoryModal2.js b/public/react/src/modules/courses/coursesPublic/AccessoryModal2.js index efec92e0a..a9a627387 100644 --- a/public/react/src/modules/courses/coursesPublic/AccessoryModal2.js +++ b/public/react/src/modules/courses/coursesPublic/AccessoryModal2.js @@ -180,7 +180,7 @@ class AccessoryModal2 extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/coursesPublic/SelectSetting.js b/public/react/src/modules/courses/coursesPublic/SelectSetting.js index 3183c859f..d52b328e2 100644 --- a/public/react/src/modules/courses/coursesPublic/SelectSetting.js +++ b/public/react/src/modules/courses/coursesPublic/SelectSetting.js @@ -396,7 +396,7 @@ class Selectsetting extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/coursesPublic/sendResource.js b/public/react/src/modules/courses/coursesPublic/sendResource.js index 1a46d9cf9..56c85439c 100644 --- a/public/react/src/modules/courses/coursesPublic/sendResource.js +++ b/public/react/src/modules/courses/coursesPublic/sendResource.js @@ -344,7 +344,7 @@ class Sendresource extends Component{ // console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/css/Courses.css b/public/react/src/modules/courses/css/Courses.css index 4f37ac816..74637571f 100644 --- a/public/react/src/modules/courses/css/Courses.css +++ b/public/react/src/modules/courses/css/Courses.css @@ -708,7 +708,14 @@ a.white-btn.use_scope-btn:hover{ color: #999!important; padding:0px 10px; } - +.orangeLine{ + background: #fff; + border:1px solid #FE944B; + color: #FE944B!important; + padding:0px 10px; + line-height: 28px; + border-radius: 4px; +} .colorFF6800{ color:#FF6800; diff --git a/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitedit.js b/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitedit.js index 467fdce25..0d5a756de 100644 --- a/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitedit.js +++ b/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitedit.js @@ -523,7 +523,7 @@ class GraduationTasksSubmitedit extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitnew.js b/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitnew.js index 3dc1d699f..9ebefcaef 100644 --- a/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitnew.js +++ b/public/react/src/modules/courses/graduation/tasks/GraduationTasksSubmitnew.js @@ -540,7 +540,7 @@ render(){ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/graduation/tasks/GraduationTasksappraiseMainEditor.js b/public/react/src/modules/courses/graduation/tasks/GraduationTasksappraiseMainEditor.js index c5ef52e76..e8b076685 100644 --- a/public/react/src/modules/courses/graduation/tasks/GraduationTasksappraiseMainEditor.js +++ b/public/react/src/modules/courses/graduation/tasks/GraduationTasksappraiseMainEditor.js @@ -172,7 +172,7 @@ class GraduationTasksappraiseMainEditor extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/graduation/tasks/GraduationTasksedit.js b/public/react/src/modules/courses/graduation/tasks/GraduationTasksedit.js index 6e801251d..5e3e64841 100644 --- a/public/react/src/modules/courses/graduation/tasks/GraduationTasksedit.js +++ b/public/react/src/modules/courses/graduation/tasks/GraduationTasksedit.js @@ -297,7 +297,7 @@ class GraduationTasksedit extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/graduation/tasks/GraduationTasksnew.js b/public/react/src/modules/courses/graduation/tasks/GraduationTasksnew.js index f7914bf2a..3b6b60ac8 100644 --- a/public/react/src/modules/courses/graduation/tasks/GraduationTasksnew.js +++ b/public/react/src/modules/courses/graduation/tasks/GraduationTasksnew.js @@ -57,24 +57,22 @@ class GraduationTasksnew extends Component { } // if (GraduationTasksnewtype === true) { this.props.form.validateFields((err, values) => { + if (values.tasktype === undefined) { + this.ifHasAnchorJustScorll("tasktypes"); + return + } + if (values.name === undefined) { + this.ifHasAnchorJustScorll("nametypes"); + return + } + if (values.description === undefined) { + this.ifHasAnchorJustScorll("descriptiontypes"); + return + }else if (values.description.length > 5000) { + this.ifHasAnchorJustScorll("descriptiontypes"); + return + } if (!err) { - if (values.tasktype === undefined) { - this.scrollToAnchors("tasktypes"); - return - } - - if (values.name === undefined) { - this.scrollToAnchors("nametypes"); - return - } - - if (values.description === undefined) { - this.scrollToAnchors("descriptiontypes"); - return - } else if (values.description.length > 5000) { - this.scrollToAnchors("descriptiontypes"); - return - } // console.log('Received values of form: ', values); // console.log(fileList); const course_id = this.props.match.params.coursesId; @@ -129,14 +127,16 @@ class GraduationTasksnew extends Component { } // 附件相关 START handleChange = (info) => { - let fileList = info.fileList; - - // for(var list of fileList ){ - // console.log(list) - // } - this.setState({ - fileList: appendFileSizeToUploadFileAll(fileList), - }); + if(info.file.status == "done" || info.file.status == "uploading"){ + let fileList = info.fileList; + + // for(var list of fileList ){ + // console.log(list) + // } + this.setState({ + fileList: appendFileSizeToUploadFileAll(fileList), + }); + } } // onAttachmentRemove = (file) => { @@ -274,7 +274,7 @@ class GraduationTasksnew extends Component { console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js b/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js index 44df3011e..511deb511 100644 --- a/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js +++ b/public/react/src/modules/courses/graduation/topics/GraduateTopicNew.js @@ -314,7 +314,7 @@ class GraduateTopicNew extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/courses/graduation/topics/GraduateTopicPostWorksNew.js b/public/react/src/modules/courses/graduation/topics/GraduateTopicPostWorksNew.js index afa3b449f..3998669d7 100644 --- a/public/react/src/modules/courses/graduation/topics/GraduateTopicPostWorksNew.js +++ b/public/react/src/modules/courses/graduation/topics/GraduateTopicPostWorksNew.js @@ -253,7 +253,7 @@ class GraduateTopicPostWorksNew extends Component{ console.log('beforeUpload', file.name); const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - message.error('文件大小必须小于150MB!'); + this.props.showNotification('文件大小必须小于150MB!'); } return isLt150M; }, diff --git a/public/react/src/modules/moop_cases/CaseDetail.js b/public/react/src/modules/moop_cases/CaseDetail.js index 6e278307e..e99f6bab0 100644 --- a/public/react/src/modules/moop_cases/CaseDetail.js +++ b/public/react/src/modules/moop_cases/CaseDetail.js @@ -82,10 +82,10 @@ class CaseDetail extends Component{ 教学案例 > { CaseDetail.title}

- + { CaseDetail.title} - + { CaseDetail.status == "pending" && 草稿 diff --git a/public/react/src/modules/moop_cases/CaseNew.js b/public/react/src/modules/moop_cases/CaseNew.js index 156b0d772..8cd97dd44 100644 --- a/public/react/src/modules/moop_cases/CaseNew.js +++ b/public/react/src/modules/moop_cases/CaseNew.js @@ -47,19 +47,18 @@ class CaseNew extends Component{ // 上传附件-删除确认框 onAttachmentRemove = (file, stateName) => { - if(file.response!=undefined){ - this.props.confirm({ - content: '是否确认删除?', - onOk: () => { - this.deleteAttachment(file, stateName) - }, - onCancel() { - console.log('Cancel'); - }, - }); - return false; - } - + if(file.response!=undefined){ + this.props.confirm({ + content: '是否确认删除?', + onOk: () => { + this.deleteAttachment(file, stateName) + }, + onCancel() { + console.log('Cancel'); + }, + }); + return false; + } } // 上传附件-确认删除 @@ -276,7 +275,7 @@ class CaseNew extends Component{ beforeUpload: (file) => { const isLt150M = file.size / 1024 / 1024 < 150; if (!isLt150M) { - //message.error('文件大小必须小于150MB!'); + //this.props.showNotification('文件大小必须小于150MB!'); this.props.define({ title:'提示', content:"该文件无法上传。超过文件大小限制(150MB),建议上传到百度云等其它共享工具里,然后再txt文档里给出链接以及共享密码并上传" @@ -380,6 +379,7 @@ class CaseNew extends Component{

{ checkTag &&
请选择标签
diff --git a/public/react/src/modules/moop_cases/CaseTags.js b/public/react/src/modules/moop_cases/CaseTags.js index 4b4f0670c..3d0c93a20 100644 --- a/public/react/src/modules/moop_cases/CaseTags.js +++ b/public/react/src/modules/moop_cases/CaseTags.js @@ -14,7 +14,17 @@ class CaseTags extends Component{ { tags && tags.map((item,key)=>{ return( - {item.name} + + { + item.name == "获奖案例" ? + {item.name} + : + item.name == "入库案例" ? + {item.name} + : + {item.name} + } + ) }) } diff --git a/public/react/src/modules/moop_cases/css/moopCases.css b/public/react/src/modules/moop_cases/css/moopCases.css index 47c98a833..7a58cee61 100644 --- a/public/react/src/modules/moop_cases/css/moopCases.css +++ b/public/react/src/modules/moop_cases/css/moopCases.css @@ -62,6 +62,13 @@ border: 1px solid #4CACFF; line-height: 17px; } +.edu-activity-orange-sub { + background-color: #FF781B; + color: #fff!important; + cursor: pointer; + border: 1px solid #ff6800; + line-height: 17px; +} .pointsBtn { width: 70px; diff --git a/public/react/src/modules/tpm/newshixuns/Newshixuns.js b/public/react/src/modules/tpm/newshixuns/Newshixuns.js index 8d4191b44..9a22269f6 100644 --- a/public/react/src/modules/tpm/newshixuns/Newshixuns.js +++ b/public/react/src/modules/tpm/newshixuns/Newshixuns.js @@ -916,7 +916,7 @@ class Newshixuns extends Component { // // console.log('beforeUpload', file.name); // const isLt50M = file.size / 1024 / 1024 < 50; // if (!isLt50M) { - // message.error('文件大小必须小于150MB!'); + // this.props.showNotification('文件大小必须小于150MB!'); // } // return isLt50M; // }, diff --git a/public/react/src/modules/tpm/shixunchild/Repository/Repository.js b/public/react/src/modules/tpm/shixunchild/Repository/Repository.js index c888ba6d8..ea9e51694 100644 --- a/public/react/src/modules/tpm/shixunchild/Repository/Repository.js +++ b/public/react/src/modules/tpm/shixunchild/Repository/Repository.js @@ -13,6 +13,7 @@ import axios from 'axios'; import { trace, trace_collapse ,getImageUrl, toPath} from "educoder"; import RepositoryDirectories from './RepositoryDirectories' +import RepositoryAddFile from './RepositoryAddFile' const $ = window.$; // 点击按钮复制功能 @@ -82,10 +83,10 @@ class Repository extends Component { Git使用指南 - + {/* */}
- - 网址克隆: + { jsCopy() diff --git a/public/react/src/modules/tpm/shixunchild/Repository/RepositoryAddFile.js b/public/react/src/modules/tpm/shixunchild/Repository/RepositoryAddFile.js new file mode 100644 index 000000000..79133f34c --- /dev/null +++ b/public/react/src/modules/tpm/shixunchild/Repository/RepositoryAddFile.js @@ -0,0 +1,52 @@ +import React, { Component } from 'react'; +import { ActionBtn } from 'educoder' + +import { Form , Modal } from 'antd' + +class RepositoryAddFile extends Component { + constructor(props) { + super(props); + this.state={ + visible:false + } + } + + addFile = () =>{ + this.setState({ + visible:true + }) + } + cancelAdd = () =>{ + this.setState({ + visible:false + }) + } + render(){ + let { visible } = this.state + return( + + +添加文件 + +
+ +
+
+ 取消 + 提交 +
+ + + ) + } +} +const WrappedRepositoryAddFile = Form.create({name: 'taskRepositoryAddFile'})(RepositoryAddFile); +// RouteHOC() +export default (WrappedRepositoryAddFile); \ No newline at end of file