From 653b9a13e6e934845367895775e5090a469af6c3 Mon Sep 17 00:00:00 2001 From: hjm <63528605@qq.com> Date: Wed, 10 Jul 2019 16:11:32 +0800 Subject: [PATCH 1/3] none data --- public/react/src/modules/courses/members/teacherList.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/public/react/src/modules/courses/members/teacherList.js b/public/react/src/modules/courses/members/teacherList.js index 95d5148c9..72709b743 100644 --- a/public/react/src/modules/courses/members/teacherList.js +++ b/public/react/src/modules/courses/members/teacherList.js @@ -2,6 +2,7 @@ import React,{ Component } from "react"; import { Input,Checkbox,Table, Divider, Tooltip,Spin, Menu } from "antd"; import CourseLayoutcomponent from '../common/CourseLayoutComponent' +import NoneData from "../coursesPublic/NoneData" import Titlesearchsection from '../common/titleSearch/TitleSearchSection' import ColorCountText from '../common/titleSearch/ColorCountText' @@ -688,6 +689,7 @@ class studentsList extends Component{ }
+ {combineArray.length ? {/* pagination={{ current: page, total: total_count, pageSize:20, onChange: this.onPageChange }} */}
+ : + }
From fce86464cf8e005287a939a75a027a7071a83f55 Mon Sep 17 00:00:00 2001 From: hjm <63528605@qq.com> Date: Thu, 11 Jul 2019 11:28:50 +0800 Subject: [PATCH 2/3] chooser --- .../courses/members/CourseGroupChooser.js | 34 ++++-- .../members/modal/CourseGroupChooserModal.js | 108 ++++++++++++++++++ .../modules/courses/members/teacherList.js | 58 +++++++--- 3 files changed, 176 insertions(+), 24 deletions(-) create mode 100644 public/react/src/modules/courses/members/modal/CourseGroupChooserModal.js diff --git a/public/react/src/modules/courses/members/CourseGroupChooser.js b/public/react/src/modules/courses/members/CourseGroupChooser.js index 7974b70dd..1a03c978f 100644 --- a/public/react/src/modules/courses/members/CourseGroupChooser.js +++ b/public/react/src/modules/courses/members/CourseGroupChooser.js @@ -2,8 +2,16 @@ import React, { useState, useEffect } from 'react' import { trigger } from 'educoder' import { Input, Checkbox } from "antd"; -function CourseGroupChooser({ course_groups, isAdminOrCreator, item, index, arg_course_groups, checkAllValue - , coursesids, onCheckAllChange, joinCourseGroup }) { +/** + arg_course_groups 选中的id数组 + joinCourseGroup 选中时触发 joinCourseGroup(checkedValues, item, index) 传入item:数据对象,index: 数据对象index + checkAllValue 是否全选 + onCheckAllChange 全选 onCheckAllChange(e, item, index) + course_groups 所有的group + +*/ +function CourseGroupChooser({ course_groups, isAdminOrCreator = true, item, index, arg_course_groups, checkAllValue, alwaysShow + , onCheckAllChange, joinCourseGroup }) { const [state, setState] = useState({counter: 0}) const [search, setSearch] = useState('') // useEffect(() => { @@ -30,8 +38,15 @@ function CourseGroupChooser({ course_groups, isAdminOrCreator, item, index, arg_ that.state.checkAllArray[index] - checkAllValue */ + console.log('arg_course_groups', arg_course_groups) + + + const urlStyle = {"lef":"tunset", minWidth: '262px'}; + if (alwaysShow == true) { + urlStyle.display = 'block' + } return ( -