├── .mvn
└── wrapper
│ ├── maven-wrapper.jar
│ ├── maven-wrapper.properties
│ └── MavenWrapperDownloader.java
├── UI
└── my-app
│ ├── public
│ ├── favicon.ico
│ ├── manifest.json
│ └── index.html
│ ├── .idea
│ ├── misc.xml
│ ├── inspectionProfiles
│ │ └── Project_Default.xml
│ ├── modules.xml
│ └── my-app.iml
│ ├── src
│ ├── CollegeRole.css
│ ├── App.test.js
│ ├── index.css
│ ├── index.js
│ ├── server.js
│ ├── App.css
│ ├── router.js
│ ├── App.js
│ ├── ApplicationManage.js
│ ├── CollegeInfo.js
│ ├── ApplicationTeacher.js
│ ├── TeachBuildInfo.js
│ ├── logo.svg
│ ├── Teacher.js
│ ├── ClassPlan.js
│ ├── ArrangingPage.js
│ ├── Login.js
│ ├── AddClassTaskModal.js
│ └── serviceWorker.js
│ ├── .gitignore
│ ├── package.json
│ └── README.md
├── target
├── test-classes
│ ├── ClassSchedulingTest.class
│ └── com
│ │ └── xnxy
│ │ └── CourseSchedulingSystem
│ │ └── CourseSchedulingSystemApplicationTests.class
└── classes
│ ├── com
│ └── xnxy
│ │ └── CourseSchedulingSystem
│ │ ├── Util
│ │ ├── PageUtil.class
│ │ └── ClassSchedulUtil.class
│ │ ├── Bean
│ │ ├── po
│ │ │ ├── ClassInfo.class
│ │ │ ├── ClassTask.class
│ │ │ ├── TeachPlan.class
│ │ │ ├── UserInfo.class
│ │ │ ├── CollegeInfo.class
│ │ │ ├── CourseInfo.class
│ │ │ ├── CoursePlan.class
│ │ │ ├── TeacherInfo.class
│ │ │ ├── LocationInfo.class
│ │ │ ├── TeachBuildInfo.class
│ │ │ ├── TeacherCourse.class
│ │ │ └── ClassroomLocation.class
│ │ └── vo
│ │ │ ├── QueryVO.class
│ │ │ ├── ResultVO.class
│ │ │ ├── TeachPlanVO.class
│ │ │ ├── UserInfoVO.class
│ │ │ ├── ConstantInfo.class
│ │ │ └── CoursePlanVO.class
│ │ ├── Config
│ │ ├── CorsConfig.class
│ │ └── CorsConfig$1.class
│ │ ├── Dao
│ │ ├── ClassInfoDao.class
│ │ ├── ClassTaskDao.class
│ │ ├── CourseInfoDao.class
│ │ ├── CoursePlanDao.class
│ │ ├── TeachPlanDao.class
│ │ ├── UserInfoDao.class
│ │ ├── CollegeInfoDao.class
│ │ ├── LocationInfoDao.class
│ │ ├── TeacherInfoDao.class
│ │ ├── TeachBuildInfoDao.class
│ │ ├── TeacherCourseDao.class
│ │ └── ClassroomLocationDao.class
│ │ ├── Service
│ │ ├── IUserInfoService.class
│ │ ├── IClassTaskService.class
│ │ ├── ICollegeInfoService.class
│ │ ├── ICoursePlanService.class
│ │ ├── ITeachPlanService.class
│ │ ├── ITeacherInfoService.class
│ │ ├── ILocationInfoService.class
│ │ ├── ITeacherCourseService.class
│ │ ├── Impl
│ │ │ ├── ClassTaskService.class
│ │ │ ├── TeachPlanService.class
│ │ │ ├── UserInfoService.class
│ │ │ ├── CollegeInfoService.class
│ │ │ ├── CoursePlanService.class
│ │ │ ├── LocationInfoService.class
│ │ │ ├── TeacherInfoService.class
│ │ │ ├── TeachBuildInfoService.class
│ │ │ ├── TeacherCourseService.class
│ │ │ └── ClassSchedulingService.class
│ │ ├── IClassSchedulingService.class
│ │ └── ITeachBuildInfoService.class
│ │ ├── Controller
│ │ ├── SchoolController.class
│ │ ├── UserController.class
│ │ └── collegeController.class
│ │ └── CourseSchedulingSystemApplication.class
│ ├── Mapper
│ ├── ClassInfoMapper.xml
│ ├── UserInfoMapper.xml
│ ├── TeacherInfoMapper.xml
│ ├── CollegeInfoMapper.xml
│ ├── CourseInfoMapper.xml
│ ├── TeachBuildInfoMapper.xml
│ ├── ClassroomLocationMapper.xml
│ ├── TeachPlanMapper.xml
│ ├── LocationInfoMapper.xml
│ ├── TeacherCourseMapper.xml
│ └── CoursePlanMapper.xml
│ ├── application.properties
│ └── generatorConfig.xml
├── README.md
├── .idea
├── sqldialects.xml
├── inspectionProfiles
│ └── Project_Default.xml
├── encodings.xml
├── misc.xml
└── compiler.xml
├── src
├── main
│ ├── java
│ │ └── com
│ │ │ └── xnxy
│ │ │ └── CourseSchedulingSystem
│ │ │ ├── Service
│ │ │ ├── ITeacherCourseService.java
│ │ │ ├── ICollegeInfoService.java
│ │ │ ├── IUserInfoService.java
│ │ │ ├── ICoursePlanService.java
│ │ │ ├── ITeachPlanService.java
│ │ │ ├── ITeacherInfoService.java
│ │ │ ├── ITeachBuildInfoService.java
│ │ │ ├── ILocationInfoService.java
│ │ │ ├── IClassTaskService.java
│ │ │ ├── Impl
│ │ │ │ ├── TeacherCourseService.java
│ │ │ │ ├── TeacherInfoService.java
│ │ │ │ ├── UserInfoService.java
│ │ │ │ ├── TeachPlanService.java
│ │ │ │ ├── CollegeInfoService.java
│ │ │ │ ├── CoursePlanService.java
│ │ │ │ ├── TeachBuildInfoService.java
│ │ │ │ ├── LocationInfoService.java
│ │ │ │ └── ClassTaskService.java
│ │ │ └── IClassSchedulingService.java
│ │ │ ├── Dao
│ │ │ ├── ClassInfoDao.java
│ │ │ ├── CollegeInfoDao.java
│ │ │ ├── UserInfoDao.java
│ │ │ ├── TeacherInfoDao.java
│ │ │ ├── TeachPlanDao.java
│ │ │ ├── CourseInfoDao.java
│ │ │ ├── CoursePlanDao.java
│ │ │ ├── TeacherCourseDao.java
│ │ │ ├── TeachBuildInfoDao.java
│ │ │ ├── LocationInfoDao.java
│ │ │ ├── ClassroomLocationDao.java
│ │ │ └── ClassTaskDao.java
│ │ │ ├── Bean
│ │ │ ├── vo
│ │ │ │ ├── UserInfoVO.java
│ │ │ │ ├── QueryVO.java
│ │ │ │ ├── ConstantInfo.java
│ │ │ │ ├── CoursePlanVO.java
│ │ │ │ ├── ResultVO.java
│ │ │ │ └── TeachPlanVO.java
│ │ │ └── po
│ │ │ │ ├── CollegeInfo.java
│ │ │ │ ├── LocationInfo.java
│ │ │ │ ├── TeachBuildInfo.java
│ │ │ │ ├── UserInfo.java
│ │ │ │ ├── CourseInfo.java
│ │ │ │ ├── ClassInfo.java
│ │ │ │ ├── TeacherCourse.java
│ │ │ │ ├── ClassroomLocation.java
│ │ │ │ ├── TeacherInfo.java
│ │ │ │ ├── CoursePlan.java
│ │ │ │ ├── TeachPlan.java
│ │ │ │ └── ClassTask.java
│ │ │ ├── CourseSchedulingSystemApplication.java
│ │ │ ├── Config
│ │ │ └── CorsConfig.java
│ │ │ ├── Util
│ │ │ └── PageUtil.java
│ │ │ └── Controller
│ │ │ ├── UserController.java
│ │ │ ├── collegeController.java
│ │ │ └── SchoolController.java
│ └── resources
│ │ ├── Mapper
│ │ ├── ClassInfoMapper.xml
│ │ ├── UserInfoMapper.xml
│ │ ├── TeacherInfoMapper.xml
│ │ ├── CollegeInfoMapper.xml
│ │ ├── CourseInfoMapper.xml
│ │ ├── TeachBuildInfoMapper.xml
│ │ ├── ClassroomLocationMapper.xml
│ │ ├── TeachPlanMapper.xml
│ │ ├── LocationInfoMapper.xml
│ │ ├── TeacherCourseMapper.xml
│ │ └── CoursePlanMapper.xml
│ │ ├── application.properties
│ │ └── generatorConfig.xml
└── test
│ └── java
│ ├── com
│ └── xnxy
│ │ └── CourseSchedulingSystem
│ │ └── CourseSchedulingSystemApplicationTests.java
│ └── ClassSchedulingTest.java
└── pom.xml
/.mvn/wrapper/maven-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/.mvn/wrapper/maven-wrapper.jar
--------------------------------------------------------------------------------
/UI/my-app/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/UI/my-app/public/favicon.ico
--------------------------------------------------------------------------------
/.mvn/wrapper/maven-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.0/apache-maven-3.6.0-bin.zip
2 |
--------------------------------------------------------------------------------
/target/test-classes/ClassSchedulingTest.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/test-classes/ClassSchedulingTest.class
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # CourseSchedulingSystem
2 | 基于遗传算法的高校自动排课系统
3 | 基本描述:本系统是基于遗传算法的一个高校自动排课系统,同时也是一个前后端分离项目。
4 | 前端:React 开发工具:WebStorm
5 | 后端:SpringBoot+MyBatis+MySQL数据库 开发工具:IDEA JDK:10
6 | 管理工具:Maven
7 |
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Util/PageUtil.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Util/PageUtil.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/ClassInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/ClassInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/ClassTask.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/ClassTask.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeachPlan.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeachPlan.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/UserInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/UserInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/QueryVO.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/QueryVO.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/ResultVO.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/ResultVO.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Config/CorsConfig.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Config/CorsConfig.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/ClassInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/ClassInfoDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/ClassTaskDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/ClassTaskDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/CourseInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/CourseInfoDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/CoursePlanDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/CoursePlanDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeachPlanDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeachPlanDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/UserInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/UserInfoDao.class
--------------------------------------------------------------------------------
/.idea/sqldialects.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/CollegeInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/CollegeInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/CourseInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/CourseInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/CoursePlan.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/CoursePlan.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeacherInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeacherInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/TeachPlanVO.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/TeachPlanVO.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/UserInfoVO.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/UserInfoVO.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Config/CorsConfig$1.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Config/CorsConfig$1.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/CollegeInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/CollegeInfoDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/LocationInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/LocationInfoDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeacherInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeacherInfoDao.class
--------------------------------------------------------------------------------
/UI/my-app/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/UI/my-app/src/CollegeRole.css:
--------------------------------------------------------------------------------
1 |
2 | .ant-advanced-search-form {
3 | padding: 24px;
4 | border-radius: 6px;
5 | }
6 |
7 | .ant-advanced-search-form .ant-form-item {
8 | display: flex;
9 | }
10 |
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/LocationInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/LocationInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeachBuildInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeachBuildInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeacherCourse.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/TeacherCourse.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/ConstantInfo.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/ConstantInfo.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/CoursePlanVO.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/vo/CoursePlanVO.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeachBuildInfoDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeachBuildInfoDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeacherCourseDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/TeacherCourseDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Util/ClassSchedulUtil.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Util/ClassSchedulUtil.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Dao/ClassroomLocationDao.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Dao/ClassroomLocationDao.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/IUserInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/IUserInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/ClassroomLocation.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Bean/po/ClassroomLocation.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Controller/SchoolController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Controller/SchoolController.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Controller/UserController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Controller/UserController.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/IClassTaskService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/IClassTaskService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ICollegeInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ICollegeInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ICoursePlanService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ICoursePlanService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeachPlanService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeachPlanService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeacherInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeacherInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Controller/collegeController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Controller/collegeController.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ILocationInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ILocationInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeacherCourseService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeacherCourseService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/ClassTaskService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/ClassTaskService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeachPlanService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeachPlanService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/UserInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/UserInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/IClassSchedulingService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/IClassSchedulingService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeachBuildInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/ITeachBuildInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/CollegeInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/CollegeInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/CoursePlanService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/CoursePlanService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/LocationInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/LocationInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeacherInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeacherInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/CourseSchedulingSystemApplication.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/CourseSchedulingSystemApplication.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeachBuildInfoService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeachBuildInfoService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeacherCourseService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/TeacherCourseService.class
--------------------------------------------------------------------------------
/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/ClassSchedulingService.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/classes/com/xnxy/CourseSchedulingSystem/Service/Impl/ClassSchedulingService.class
--------------------------------------------------------------------------------
/target/test-classes/com/xnxy/CourseSchedulingSystem/CourseSchedulingSystemApplicationTests.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Code-Chen/CourseSchedulingSystem/HEAD/target/test-classes/com/xnxy/CourseSchedulingSystem/CourseSchedulingSystemApplicationTests.class
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ITeacherCourseService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherCourse;
4 |
5 | public interface ITeacherCourseService {
6 | int update(TeacherCourse teacherCourse);
7 | }
8 |
--------------------------------------------------------------------------------
/UI/my-app/.idea/inspectionProfiles/Project_Default.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/UI/my-app/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/UI/my-app/src/App.test.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import App from './App';
4 |
5 | it('renders without crashing', () => {
6 | const div = document.createElement('div');
7 | ReactDOM.render(, div);
8 | ReactDOM.unmountComponentAtNode(div);
9 | });
10 |
--------------------------------------------------------------------------------
/.idea/inspectionProfiles/Project_Default.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/ClassInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 |
4 | import org.apache.ibatis.annotations.Mapper;
5 | import org.apache.ibatis.annotations.Param;
6 |
7 | @Mapper
8 | public interface ClassInfoDao {
9 | int selectStudentNumber(@Param("classNo") String classNo);
10 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ICollegeInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CollegeInfo;
4 |
5 | import java.util.List;
6 | import java.util.Map;
7 |
8 | public interface ICollegeInfoService {
9 | List findCollegeInfo();
10 | }
11 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/IUserInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.vo.UserInfoVO;
4 | import org.springframework.stereotype.Service;
5 |
6 |
7 | public interface IUserInfoService {
8 | public Boolean login(UserInfoVO userInfoVO);
9 | }
10 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/CollegeInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CollegeInfo;
4 | import org.apache.ibatis.annotations.Mapper;
5 |
6 | import java.util.List;
7 |
8 | @Mapper
9 | public interface CollegeInfoDao {
10 |
11 |
12 | List selectAll();
13 |
14 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ICoursePlanService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CoursePlan;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 |
6 | import java.util.List;
7 |
8 | public interface ICoursePlanService {
9 | List selectAll(QueryVO queryVO);
10 | }
11 |
--------------------------------------------------------------------------------
/UI/my-app/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | }
10 | ],
11 | "start_url": ".",
12 | "display": "standalone",
13 | "theme_color": "#000000",
14 | "background_color": "#ffffff"
15 | }
16 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ITeachPlanService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.TeachPlanVO;
5 |
6 | import java.util.List;
7 |
8 | public interface ITeachPlanService {
9 | List queryTeachPlan(QueryVO queryVO);
10 | }
11 |
--------------------------------------------------------------------------------
/.idea/encodings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ITeacherInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 |
6 | import java.util.List;
7 |
8 | public interface ITeacherInfoService {
9 | List queryTeacherInfo(QueryVO queryVO);
10 | }
11 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ITeachBuildInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeachBuildInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 |
6 | import java.util.List;
7 |
8 | public interface ITeachBuildInfoService {
9 | List queryTeachBuildInfo(QueryVO queryVO);
10 | }
11 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/UserInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.UserInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.UserInfoVO;
5 | import org.apache.ibatis.annotations.Mapper;
6 |
7 | @Mapper
8 | public interface UserInfoDao {
9 |
10 |
11 | UserInfo selectUser(UserInfoVO userInfoVO);
12 |
13 |
14 | }
15 |
--------------------------------------------------------------------------------
/UI/my-app/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/TeacherInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import org.apache.ibatis.annotations.Mapper;
6 |
7 | import java.util.List;
8 |
9 | @Mapper
10 | public interface TeacherInfoDao {
11 |
12 | List selectAll(QueryVO queryVO);
13 | }
--------------------------------------------------------------------------------
/UI/my-app/src/index.css:
--------------------------------------------------------------------------------
1 | body {
2 | margin: 0;
3 | padding: 0;
4 | font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
5 | "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
6 | sans-serif;
7 | -webkit-font-smoothing: antialiased;
8 | -moz-osx-font-smoothing: grayscale;
9 | }
10 |
11 | code {
12 | font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
13 | monospace;
14 | }
15 |
16 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/TeachPlanDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeachPlan;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.TeachPlanVO;
6 | import org.apache.ibatis.annotations.Mapper;
7 |
8 | import java.util.List;
9 |
10 | @Mapper
11 | public interface TeachPlanDao {
12 |
13 | List selectAll(QueryVO queryVO);
14 |
15 |
16 | }
--------------------------------------------------------------------------------
/UI/my-app/src/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import './index.css';
4 | import App from './App';
5 | import * as serviceWorker from './serviceWorker';
6 |
7 | ReactDOM.render(, document.getElementById('root'));
8 |
9 | // If you want your app to work offline and load faster, you can change
10 | // unregister() to register() below. Note this comes with some pitfalls.
11 | // Learn more about service workers: https://bit.ly/CRA-PWA
12 | serviceWorker.unregister();
13 |
--------------------------------------------------------------------------------
/UI/my-app/.idea/my-app.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/ILocationInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 |
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.LocationInfo;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
6 |
7 | import java.util.List;
8 |
9 | public interface ILocationInfoService {
10 | List queryLocationInfo(QueryVO queryVO);
11 | Boolean saveLocationInfo(LocationInfo locationInfo);
12 | Boolean deleteLocationInfo(LocationInfo locationInfo);
13 | }
14 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/IClassTaskService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 |
6 | import java.util.List;
7 |
8 | public interface IClassTaskService {
9 | List queryClassTask(QueryVO queryVO);
10 | Boolean saveClassTask(ClassTask classTask);
11 | Boolean deleteClassTask(ClassTask classTask);
12 | List querySemester();
13 |
14 | }
15 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/CourseInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CourseInfo;
4 | import org.apache.ibatis.annotations.Mapper;
5 |
6 | import java.util.List;
7 |
8 | @Mapper
9 | public interface CourseInfoDao {
10 | int deleteByPrimaryKey(Long id);
11 |
12 | int insert(CourseInfo record);
13 |
14 | CourseInfo selectByPrimaryKey(Long id);
15 |
16 | List selectAll();
17 |
18 | int updateByPrimaryKey(CourseInfo record);
19 | }
--------------------------------------------------------------------------------
/src/test/java/com/xnxy/CourseSchedulingSystem/CourseSchedulingSystemApplicationTests.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem;
2 |
3 | import org.junit.Test;
4 | import org.junit.runner.RunWith;
5 | import org.mybatis.spring.annotation.MapperScan;
6 | import org.springframework.boot.test.context.SpringBootTest;
7 | import org.springframework.test.context.junit4.SpringRunner;
8 |
9 | @RunWith(SpringRunner.class)
10 | @SpringBootTest
11 | public class CourseSchedulingSystemApplicationTests {
12 |
13 | @Test
14 | public void contextLoads() {
15 | }
16 |
17 | }
18 |
--------------------------------------------------------------------------------
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/CoursePlanDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.CoursePlan;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
6 | import org.apache.ibatis.annotations.Mapper;
7 |
8 | import java.util.List;
9 |
10 | @Mapper
11 | public interface CoursePlanDao {
12 |
13 | List selectAll(QueryVO queryVO);
14 | int insertCoursePlan(CoursePlan coursePlan);
15 | int updateCoursePlan(ClassTask classTask);
16 |
17 | }
--------------------------------------------------------------------------------
/UI/my-app/src/server.js:
--------------------------------------------------------------------------------
1 | import axios from 'axios';
2 | import qs from 'qs';
3 |
4 | const $axios = axios.create({
5 | baseURL:'http://localhost:8080',
6 | responseType:'json',
7 | timeout:10000,
8 | headers:{
9 | 'Content-Type':'application/json;charset=utf-8'
10 | }
11 | });
12 | let http = {
13 | get: '',
14 | post: '',
15 | };
16 |
17 | http.post = function (api, data) {
18 | return new Promise((resolve, reject) => {
19 | $axios.post(api, data).then((res) => res.data).catch((error) => {
20 | reject(error)
21 | });
22 | })
23 | };
24 |
25 | export default http;
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/TeacherCourseDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CoursePlan;
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherCourse;
5 | import org.apache.ibatis.annotations.Mapper;
6 |
7 | import java.util.List;
8 |
9 | @Mapper
10 | public interface TeacherCourseDao {
11 | int deleteByPrimaryKey(Long id);
12 |
13 | int insert(TeacherCourse record);
14 |
15 | List selectAll();
16 |
17 | int updateByPrimaryKey(TeacherCourse record);
18 | int insertTeacherCourse(CoursePlan coursePlan);
19 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/TeachBuildInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeachBuildInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import org.apache.ibatis.annotations.Mapper;
6 |
7 | import java.util.List;
8 | @Mapper
9 | public interface TeachBuildInfoDao {
10 | int deleteByPrimaryKey(Long id);
11 |
12 | int insert(TeachBuildInfo record);
13 |
14 | TeachBuildInfo selectByPrimaryKey(Long id);
15 |
16 | List selectAll(QueryVO queryVO);
17 |
18 | int updateByPrimaryKey(TeachBuildInfo record);
19 | }
--------------------------------------------------------------------------------
/UI/my-app/src/App.css:
--------------------------------------------------------------------------------
1 | .App {
2 | text-align: center;
3 | }
4 |
5 | .App-logo {
6 | animation: App-logo-spin infinite 20s linear;
7 | height: 40vmin;
8 | pointer-events: none;
9 | }
10 |
11 | .App-header {
12 | background-color: #282c34;
13 | min-height: 100vh;
14 | display: flex;
15 | flex-direction: column;
16 | align-items: center;
17 | justify-content: center;
18 | font-size: calc(10px + 2vmin);
19 | color: white;
20 | }
21 |
22 | .App-link {
23 | color: #61dafb;
24 | }
25 |
26 | @keyframes App-logo-spin {
27 | from {
28 | transform: rotate(0deg);
29 | }
30 | to {
31 | transform: rotate(360deg);
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/LocationInfoDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.LocationInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import org.apache.ibatis.annotations.Mapper;
6 | import org.apache.ibatis.annotations.Param;
7 |
8 | import java.util.List;
9 |
10 | @Mapper
11 | public interface LocationInfoDao {
12 | int deleteByPrimaryKey(LocationInfo locationInfo);
13 |
14 | int insert(LocationInfo locationInfo);
15 |
16 | List selectAll(QueryVO queryVO);
17 |
18 | int updateByPrimaryKey(LocationInfo locationInfo);
19 |
20 | String selectBuildNo(@Param("collegeNo") String collegeNo);
21 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/ClassroomLocationDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassroomLocation;
4 | import org.apache.ibatis.annotations.Mapper;
5 | import org.apache.ibatis.annotations.Param;
6 |
7 | import java.util.List;
8 | @Mapper
9 |
10 | public interface ClassroomLocationDao {
11 | int deleteByPrimaryKey(Long id);
12 |
13 | int insert(ClassroomLocation record);
14 |
15 | ClassroomLocation selectByPrimaryKey(Long id);
16 |
17 | List selectAll();
18 |
19 | int updateByPrimaryKey(ClassroomLocation record);
20 |
21 | List selectByTeachBuildNo(@Param("teachBuildNo") String teachBuildNo);
22 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Dao/ClassTaskDao.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Dao;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import org.apache.ibatis.annotations.Mapper;
6 | import org.apache.ibatis.annotations.Param;
7 |
8 | import java.util.List;
9 |
10 | @Mapper
11 | public interface ClassTaskDao {
12 | int insert(ClassTask classTask);
13 | int updateByPrimaryKey(ClassTask classTask);
14 | List selectAll(QueryVO queryVO);
15 | int deleteByPrimaryKey(ClassTask classTask);
16 | List selectBySemester(ClassTask classTask);
17 | List selectByColumnName(@Param("columnName") String columnName);
18 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/TeacherCourseService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherCourse;
4 | import com.xnxy.CourseSchedulingSystem.Dao.TeacherCourseDao;
5 | import com.xnxy.CourseSchedulingSystem.Service.ITeacherCourseService;
6 | import org.springframework.beans.factory.annotation.Autowired;
7 | import org.springframework.stereotype.Service;
8 |
9 | @Service
10 | public class TeacherCourseService implements ITeacherCourseService {
11 | @Autowired
12 | TeacherCourseDao teacherCourseDao;
13 |
14 | @Override
15 | public int update(TeacherCourse teacherCourse) {
16 | return teacherCourseDao.updateByPrimaryKey(teacherCourse);
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/.idea/compiler.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/IClassSchedulingService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassroomLocation;
5 |
6 | import java.util.List;
7 | import java.util.Map;
8 |
9 | public interface IClassSchedulingService {
10 | Boolean classScheduling(ClassTask classTask);
11 | Map> transformIndividual(List resultGeneList);
12 | Map> geneticEvolution(Map> individualMap);
13 | List finalResult(Map> individualMap);
14 | String assignClassroom(String gene, List classroomLocationList, List resultList);
15 | }
16 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/vo/UserInfoVO.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.vo;
2 |
3 | public class UserInfoVO {
4 | private String username;
5 |
6 | private String password;
7 |
8 | private String role;
9 |
10 | public String getUsername() {
11 | return username;
12 | }
13 |
14 | public void setUsername(String username) {
15 | this.username = username;
16 | }
17 |
18 | public String getPassword() {
19 | return password;
20 | }
21 |
22 | public void setPassword(String password) {
23 | this.password = password;
24 | }
25 |
26 | public String getRole() {
27 | return role;
28 | }
29 |
30 | public void setRole(String role) {
31 | this.role = role;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/CollegeInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class CollegeInfo {
4 | private Long id;
5 |
6 | private String collegeno;
7 |
8 | private String collegename;
9 |
10 | public Long getId() {
11 | return id;
12 | }
13 |
14 | public void setId(Long id) {
15 | this.id = id;
16 | }
17 |
18 | public String getCollegeno() {
19 | return collegeno;
20 | }
21 |
22 | public void setCollegeno(String collegeno) {
23 | this.collegeno = collegeno;
24 | }
25 |
26 | public String getCollegename() {
27 | return collegename;
28 | }
29 |
30 | public void setCollegename(String collegename) {
31 | this.collegename = collegename;
32 | }
33 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/LocationInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class LocationInfo {
4 | private Long id;
5 |
6 | private String teachbuildno;
7 |
8 | private String collegeno;
9 |
10 | public Long getId() {
11 | return id;
12 | }
13 |
14 | public void setId(Long id) {
15 | this.id = id;
16 | }
17 |
18 | public String getTeachbuildno() {
19 | return teachbuildno;
20 | }
21 |
22 | public void setTeachbuildno(String teachbuildno) {
23 | this.teachbuildno = teachbuildno;
24 | }
25 |
26 | public String getCollegeno() {
27 | return collegeno;
28 | }
29 |
30 | public void setCollegeno(String collegeno) {
31 | this.collegeno = collegeno;
32 | }
33 | }
--------------------------------------------------------------------------------
/UI/my-app/src/router.js:
--------------------------------------------------------------------------------
1 | import React, {Component} from 'react';
2 | import {BrowserRouter as Router, Route} from 'react-router-dom';
3 | import Login from './Login';
4 | import CollegeRole from './CollegeRole';
5 | import ApplicationManage from './ApplicationManage';
6 | import App from './App';
7 |
8 | class RouterApp extends Component {
9 | render() {
10 | return (
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 | );
21 | }
22 | }
23 |
24 | export default RouterApp;
25 |
--------------------------------------------------------------------------------
/UI/my-app/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "my-app",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "react": "^16.8.6",
7 | "react-dom": "^16.8.6",
8 | "react-scripts": "2.1.8",
9 | "antd": "^3.16.3",
10 | "router": "^1.3.3",
11 | "react-router": "^2.0.0",
12 | "react-router-dom": "^5.0.0",
13 | "webpack": "^4.28.3",
14 | "axios": "^0.18.0",
15 | "qs":"^6.5.2"
16 | },
17 | "scripts": {
18 | "start": "react-scripts start",
19 | "build": "react-scripts build",
20 | "test": "react-scripts test",
21 | "eject": "react-scripts eject"
22 | },
23 | "eslintConfig": {
24 | "extends": "react-app"
25 | },
26 | "browserslist": [
27 | ">0.2%",
28 | "not dead",
29 | "not ie <= 11",
30 | "not op_mini all"
31 | ],
32 | "proxy":"http://localhost:8080"
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/TeachBuildInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class TeachBuildInfo {
4 | private Long id;
5 |
6 | private String teachbuildno;
7 |
8 | private String teachbuildname;
9 |
10 | public Long getId() {
11 | return id;
12 | }
13 |
14 | public void setId(Long id) {
15 | this.id = id;
16 | }
17 |
18 | public String getTeachbuildno() {
19 | return teachbuildno;
20 | }
21 |
22 | public void setTeachbuildno(String teachbuildno) {
23 | this.teachbuildno = teachbuildno;
24 | }
25 |
26 | public String getTeachbuildname() {
27 | return teachbuildname;
28 | }
29 |
30 | public void setTeachbuildname(String teachbuildname) {
31 | this.teachbuildname = teachbuildname;
32 | }
33 | }
--------------------------------------------------------------------------------
/target/classes/Mapper/ClassInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
14 |
15 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/ClassInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
14 |
15 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/TeacherInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import com.xnxy.CourseSchedulingSystem.Dao.TeacherInfoDao;
6 | import com.xnxy.CourseSchedulingSystem.Service.ITeacherInfoService;
7 | import org.springframework.beans.factory.annotation.Autowired;
8 | import org.springframework.stereotype.Service;
9 |
10 | import java.util.List;
11 |
12 | @Service
13 | public class TeacherInfoService implements ITeacherInfoService {
14 | @Autowired
15 | TeacherInfoDao teacherInfoDao;
16 | @Override
17 | public List queryTeacherInfo(QueryVO queryVO) {
18 | List teacherInfoList = teacherInfoDao.selectAll(queryVO);
19 | return teacherInfoList;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/UserInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.UserInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.UserInfoVO;
5 | import com.xnxy.CourseSchedulingSystem.Dao.UserInfoDao;
6 | import com.xnxy.CourseSchedulingSystem.Service.IUserInfoService;
7 | import org.springframework.beans.factory.annotation.Autowired;
8 | import org.springframework.stereotype.Service;
9 |
10 | @Service
11 | public class UserInfoService implements IUserInfoService {
12 |
13 | @Autowired
14 | UserInfoDao userInfoDao;
15 |
16 | @Override
17 | public Boolean login(UserInfoVO userInfoVO) {
18 | UserInfo userInfo = userInfoDao.selectUser(userInfoVO);
19 | if (userInfo != null) {
20 | return true;
21 | }
22 | return false;
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/TeachPlanService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeachPlan;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.TeachPlanVO;
6 | import com.xnxy.CourseSchedulingSystem.Dao.TeachPlanDao;
7 | import com.xnxy.CourseSchedulingSystem.Service.ITeachPlanService;
8 | import org.springframework.beans.factory.annotation.Autowired;
9 | import org.springframework.stereotype.Service;
10 |
11 | import java.util.List;
12 | @Service
13 | public class TeachPlanService implements ITeachPlanService {
14 | @Autowired
15 | TeachPlanDao teachPlanDao;
16 | @Override
17 | public List queryTeachPlan(QueryVO queryVO) {
18 | List teachPlanVOList = teachPlanDao.selectAll(queryVO);
19 | return teachPlanVOList;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/UserInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class UserInfo {
4 | private Long id;
5 |
6 | private String username;
7 |
8 | private String password;
9 |
10 | private String role;
11 |
12 | public Long getId() {
13 | return id;
14 | }
15 |
16 | public void setId(Long id) {
17 | this.id = id;
18 | }
19 |
20 | public String getUsername() {
21 | return username;
22 | }
23 |
24 | public void setUsername(String username) {
25 | this.username = username;
26 | }
27 |
28 | public String getPassword() {
29 | return password;
30 | }
31 |
32 | public void setPassword(String password) {
33 | this.password = password;
34 | }
35 |
36 | public String getRole() {
37 | return role;
38 | }
39 |
40 | public void setRole(String role) {
41 | this.role = role;
42 | }
43 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/CollegeInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CollegeInfo;
4 | import com.xnxy.CourseSchedulingSystem.Dao.CollegeInfoDao;
5 | import com.xnxy.CourseSchedulingSystem.Service.ICollegeInfoService;
6 | import org.springframework.beans.factory.annotation.Autowired;
7 | import org.springframework.stereotype.Service;
8 |
9 | import java.util.*;
10 |
11 | @Service
12 | public class CollegeInfoService implements ICollegeInfoService {
13 | @Autowired
14 | CollegeInfoDao collegeInfoDao;
15 | @Override
16 | public List findCollegeInfo() {
17 | try{
18 | List collegeInfoList = collegeInfoDao.selectAll();
19 | return collegeInfoList;
20 | }catch (Exception e){
21 | e.printStackTrace();
22 | return Collections.emptyList();
23 | }
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/CourseInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class CourseInfo {
4 | private Long id;
5 |
6 | private String courseno;
7 |
8 | private String coursename;
9 |
10 | private String courseattr;
11 |
12 | public Long getId() {
13 | return id;
14 | }
15 |
16 | public void setId(Long id) {
17 | this.id = id;
18 | }
19 |
20 | public String getCourseno() {
21 | return courseno;
22 | }
23 |
24 | public void setCourseno(String courseno) {
25 | this.courseno = courseno;
26 | }
27 |
28 | public String getCoursename() {
29 | return coursename;
30 | }
31 |
32 | public void setCoursename(String coursename) {
33 | this.coursename = coursename;
34 | }
35 |
36 | public String getCourseattr() {
37 | return courseattr;
38 | }
39 |
40 | public void setCourseattr(String courseattr) {
41 | this.courseattr = courseattr;
42 | }
43 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/CourseSchedulingSystemApplication.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem;
2 |
3 | import org.apache.catalina.filters.CorsFilter;
4 | import org.mybatis.spring.annotation.MapperScan;
5 | import org.springframework.boot.SpringApplication;
6 | import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
7 | import org.springframework.boot.autoconfigure.SpringBootApplication;
8 | import org.springframework.transaction.annotation.EnableTransactionManagement;
9 | import org.springframework.web.bind.annotation.CrossOrigin;
10 | import org.springframework.web.cors.CorsConfiguration;
11 | import org.springframework.web.cors.UrlBasedCorsConfigurationSource;
12 |
13 | @CrossOrigin
14 | @SpringBootApplication
15 | @MapperScan("com.xnxy.CourseSchedulingSystem.Dao")
16 | @EnableTransactionManagement
17 | public class CourseSchedulingSystemApplication {
18 |
19 | public static void main(String[] args) {
20 | SpringApplication.run(CourseSchedulingSystemApplication.class, args);
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/target/classes/Mapper/UserInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
18 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/UserInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
18 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/ClassInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class ClassInfo {
4 | private Long id;
5 |
6 | private String classno;
7 |
8 | private String classname;
9 |
10 | private Integer studentnumber;
11 |
12 | public Long getId() {
13 | return id;
14 | }
15 |
16 | public void setId(Long id) {
17 | this.id = id;
18 | }
19 |
20 | public String getClassno() {
21 | return classno;
22 | }
23 |
24 | public void setClassno(String classno) {
25 | this.classno = classno;
26 | }
27 |
28 | public String getClassname() {
29 | return classname;
30 | }
31 |
32 | public void setClassname(String classname) {
33 | this.classname = classname;
34 | }
35 |
36 | public Integer getStudentnumber() {
37 | return studentnumber;
38 | }
39 |
40 | public void setStudentnumber(Integer studentnumber) {
41 | this.studentnumber = studentnumber;
42 | }
43 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Config/CorsConfig.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Config;
2 |
3 | import org.springframework.context.annotation.Bean;
4 | import org.springframework.context.annotation.Configuration;
5 | import org.springframework.web.servlet.config.annotation.CorsRegistry;
6 | import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
7 | import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;
8 |
9 |
10 | @Configuration
11 | public class CorsConfig {
12 | @Bean
13 | public WebMvcConfigurer corsConfiger(){
14 | return new WebMvcConfigurerAdapter() {
15 | @Override
16 | public void addCorsMappings(CorsRegistry registry) {
17 | registry.addMapping("/**")
18 | .allowedOrigins("*")
19 | .allowedMethods("*")
20 | .allowedHeaders("*")
21 | .allowCredentials(true);
22 | super.addCorsMappings(registry);
23 | }
24 | };
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/CoursePlanService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CoursePlan;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import com.xnxy.CourseSchedulingSystem.Dao.CoursePlanDao;
6 | import com.xnxy.CourseSchedulingSystem.Service.ICoursePlanService;
7 | import org.springframework.beans.factory.annotation.Autowired;
8 | import org.springframework.stereotype.Service;
9 |
10 | import java.util.Collections;
11 | import java.util.List;
12 | @Service
13 |
14 | public class CoursePlanService implements ICoursePlanService {
15 | @Autowired
16 | CoursePlanDao coursePlanDao;
17 |
18 | @Override
19 | public List selectAll(QueryVO queryVO) {
20 | try{
21 | List coursePlanList = coursePlanDao.selectAll(queryVO);
22 | return coursePlanList;
23 | }catch (Exception e){
24 | e.printStackTrace();
25 | return Collections.emptyList();
26 | }
27 |
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/TeachBuildInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeachBuildInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import com.xnxy.CourseSchedulingSystem.Dao.TeachBuildInfoDao;
6 | import com.xnxy.CourseSchedulingSystem.Service.ITeachBuildInfoService;
7 | import org.springframework.beans.factory.annotation.Autowired;
8 | import org.springframework.stereotype.Service;
9 |
10 | import java.util.Collections;
11 | import java.util.List;
12 | @Service
13 | public class TeachBuildInfoService implements ITeachBuildInfoService {
14 | @Autowired
15 | TeachBuildInfoDao teachBuildInfoDao;
16 |
17 | @Override
18 | public List queryTeachBuildInfo(QueryVO queryVO) {
19 | try {
20 | List teachBuildInfoList = teachBuildInfoDao.selectAll(queryVO);
21 | return teachBuildInfoList;
22 | }catch (Exception e){
23 | e.printStackTrace();
24 | return Collections.emptyList();
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/TeacherCourse.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class TeacherCourse {
4 | private Long id;
5 |
6 | private String teacherno;
7 |
8 | private String courseno;
9 |
10 | private String classno;
11 |
12 | private String classroomno;
13 |
14 | public Long getId() {
15 | return id;
16 | }
17 |
18 | public void setId(Long id) {
19 | this.id = id;
20 | }
21 |
22 | public String getTeacherno() {
23 | return teacherno;
24 | }
25 |
26 | public void setTeacherno(String teacherno) {
27 | this.teacherno = teacherno;
28 | }
29 |
30 | public String getCourseno() {
31 | return courseno;
32 | }
33 |
34 | public void setCourseno(String courseno) {
35 | this.courseno = courseno;
36 | }
37 |
38 | public String getClassno() {
39 | return classno;
40 | }
41 |
42 | public void setClassno(String classno) {
43 | this.classno = classno;
44 | }
45 |
46 | public String getClassroomno() {
47 | return classroomno;
48 | }
49 |
50 | public void setClassroomno(String classroomno) {
51 | this.classroomno = classroomno;
52 | }
53 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/ClassroomLocation.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class ClassroomLocation {
4 | private Long id;
5 |
6 | private String teachbuildno;
7 |
8 | private String classroomno;
9 |
10 | private Integer capacity;
11 |
12 | private String classroomattr;
13 |
14 | public Long getId() {
15 | return id;
16 | }
17 |
18 | public void setId(Long id) {
19 | this.id = id;
20 | }
21 |
22 | public String getTeachbuildno() {
23 | return teachbuildno;
24 | }
25 |
26 | public void setTeachbuildno(String teachbuildno) {
27 | this.teachbuildno = teachbuildno;
28 | }
29 |
30 | public String getClassroomno() {
31 | return classroomno;
32 | }
33 |
34 | public void setClassroomno(String classroomno) {
35 | this.classroomno = classroomno;
36 | }
37 |
38 | public Integer getCapacity() {
39 | return capacity;
40 | }
41 |
42 | public void setCapacity(Integer capacity) {
43 | this.capacity = capacity;
44 | }
45 |
46 | public String getClassroomattr() {
47 | return classroomattr;
48 | }
49 |
50 | public void setClassroomattr(String classroomattr) {
51 | this.classroomattr = classroomattr;
52 | }
53 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/vo/QueryVO.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.vo;
2 | import java.util.Map;
3 |
4 | public class QueryVO {
5 | private Map param;
6 | private Map pageParam;
7 | private String condition;
8 | private String collegeno;
9 | private String semester;
10 |
11 |
12 | public Map getParam() {
13 | return param;
14 | }
15 |
16 | public void setParam(Map param) {
17 | this.param = param;
18 | }
19 |
20 | public String getCondition() {
21 | return condition;
22 | }
23 |
24 | public void setCondition(String condition) {
25 | this.condition = condition;
26 | }
27 |
28 | public String getCollegeno() {
29 | return collegeno;
30 | }
31 |
32 | public void setCollegeno(String collegeno) {
33 | this.collegeno = collegeno;
34 | }
35 |
36 | public Map getPageParam() {
37 | return pageParam;
38 | }
39 |
40 | public void setPageParam(Map pageParam) {
41 | this.pageParam = pageParam;
42 | }
43 |
44 | public String getSemester() {
45 | return semester;
46 | }
47 |
48 | public void setSemester(String semester) {
49 | this.semester = semester;
50 | }
51 | }
52 |
--------------------------------------------------------------------------------
/target/classes/Mapper/TeacherInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
21 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/TeacherInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
21 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Util/PageUtil.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Util;
2 |
3 | import com.github.pagehelper.PageHelper;
4 | import com.github.pagehelper.PageInfo;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
6 | import com.xnxy.CourseSchedulingSystem.Bean.vo.TeachPlanVO;
7 |
8 | import java.util.HashMap;
9 | import java.util.List;
10 | import java.util.Map;
11 |
12 | public class PageUtil {
13 | private final static int PAGE_NUM = 1;
14 | private final static int PAGE_SIZE = 10;
15 | //public static void pageHelper(QueryVO queryVO){
16 | // if(queryVO.getPageParam() == null){
17 | // Map pageParam = new HashMap<>();
18 | // pageParam.put("pageNum",PAGE_NUM);
19 | // pageParam.put("pageSize",PAGE_SIZE);
20 | // queryVO.setPageParam(pageParam);
21 | // }
22 | // int pageNum = queryVO.getPageParam().get("pageNum");
23 | // int pageSize = queryVO.getPageParam().get("pageSize");
24 | // PageHelper.startPage(pageNum,pageSize);
25 | //}
26 | //
27 | //public static MappageDataHelper(List list){
28 | // Map pageData = new HashMap<>();
29 | // PageInfo pageInfo = new PageInfo<>(list);
30 | // pageData.put("pages",(long)pageInfo.getPages());
31 | // pageData.put("pageTotal",pageInfo.getTotal());
32 | // return pageData;
33 | //}
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/TeacherInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class TeacherInfo {
4 | private Integer id;
5 |
6 | private String teacherno;
7 |
8 | private String teachername;
9 |
10 | private String collegeno;
11 |
12 | private Integer age;
13 |
14 | private String title;
15 |
16 | public Integer getId() {
17 | return id;
18 | }
19 |
20 | public void setId(Integer id) {
21 | this.id = id;
22 | }
23 |
24 | public String getTeacherno() {
25 | return teacherno;
26 | }
27 |
28 | public void setTeacherno(String teacherno) {
29 | this.teacherno = teacherno;
30 | }
31 |
32 | public String getTeachername() {
33 | return teachername;
34 | }
35 |
36 | public void setTeachername(String teachername) {
37 | this.teachername = teachername;
38 | }
39 |
40 | public String getCollegeno() {
41 | return collegeno;
42 | }
43 |
44 | public void setCollegeno(String collegeno) {
45 | this.collegeno = collegeno;
46 | }
47 |
48 | public Integer getAge() {
49 | return age;
50 | }
51 |
52 | public void setAge(Integer age) {
53 | this.age = age;
54 | }
55 |
56 | public String getTitle() {
57 | return title;
58 | }
59 |
60 | public void setTitle(String title) {
61 | this.title = title;
62 | }
63 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/vo/ConstantInfo.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.vo;
2 |
3 | public class ConstantInfo {
4 | public static final String IS_FIX = "isFix";//是否固定
5 | public static final String COLLEGE_NO = "collegeNo";//学院编号
6 | public static final String CLASS_NO = "classNo";//班级编号
7 | public static final String TEACHER_NO = "teacherNo";//教师编号
8 | public static final String COURSE_NO = "courseNo";//课程编号
9 | public static final String COURSE_ATTR = "courseAttr";//课程属性
10 | public static final String CLASS_TIME = "classTime";//上课时间
11 | public static final String CLASSROOM_NO = "classroomNo";
12 | public static final String DEFAULT_CLASS_TIME = "00";//默认课程编码
13 | public static final String SEMESTER = "semester";//开课学期
14 | public static final String PROFESSIONAL_CODE = "01";//专业课码值
15 | public static final String ELECTIVE_CODE = "02";//选修课码值
16 | public static final String PHYSICAL_CODE = "03";//体育课码值
17 | public static final String MEDICAL_CODE = "04";//医学实验课码值
18 | public static final String CHEMISTRY_CODE = "05";//化学实验课码值
19 | public static final String DANCE_CODE = "06";//舞蹈实践课码值
20 | public static final String BROADCAST_CODE = "07";//播音实践课码值
21 | public static final String ELECTRICITY_CODE = "08";//电子实验课码值
22 | public static final String ART_CODE = "09";//美术实践课码值
23 | public static final String COMPUTER_CODE = "10";//计算机实验课码值
24 | public static final String MUSIC_PERFOMANCE_CODE = "11";//音乐表演课码值
25 | public static final String PHYSICAL_EXPERIMENT_CODE = "12";//物理实验课码值
26 | public static final int GENERATION = 100;//遗传代数
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/target/classes/Mapper/CollegeInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | delete from college_info
11 | where id = #{id,jdbcType=BIGINT}
12 |
13 |
14 | insert into college_info (id, collegeNo, collegeName
15 | )
16 | values (#{id,jdbcType=BIGINT}, #{collegeno,jdbcType=VARCHAR}, #{collegename,jdbcType=VARCHAR}
17 | )
18 |
19 |
20 | update college_info
21 | set collegeNo = #{collegeno,jdbcType=VARCHAR},
22 | collegeName = #{collegename,jdbcType=VARCHAR}
23 | where id = #{id,jdbcType=BIGINT}
24 |
25 |
30 |
34 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/CollegeInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | delete from college_info
11 | where id = #{id,jdbcType=BIGINT}
12 |
13 |
14 | insert into college_info (id, collegeNo, collegeName
15 | )
16 | values (#{id,jdbcType=BIGINT}, #{collegeno,jdbcType=VARCHAR}, #{collegename,jdbcType=VARCHAR}
17 | )
18 |
19 |
20 | update college_info
21 | set collegeNo = #{collegeno,jdbcType=VARCHAR},
22 | collegeName = #{collegename,jdbcType=VARCHAR}
23 | where id = #{id,jdbcType=BIGINT}
24 |
25 |
30 |
34 |
--------------------------------------------------------------------------------
/UI/my-app/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
10 |
11 |
15 |
16 |
25 | React App
26 |
27 |
28 |
29 |
30 |
40 |
41 |
42 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/vo/CoursePlanVO.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.vo;
2 |
3 | public class CoursePlanVO {
4 |
5 | private String collegeno;
6 |
7 | private String classno;
8 |
9 | private String courseno;
10 |
11 | private String teacherno;
12 |
13 | private String classroomno;
14 |
15 | private String classtime;
16 |
17 | private Integer weekssum;
18 |
19 | public String getCollegeno() {
20 | return collegeno;
21 | }
22 |
23 | public void setCollegeno(String collegeno) {
24 | this.collegeno = collegeno;
25 | }
26 |
27 | public String getClassno() {
28 | return classno;
29 | }
30 |
31 | public void setClassno(String classno) {
32 | this.classno = classno;
33 | }
34 |
35 | public String getCourseno() {
36 | return courseno;
37 | }
38 |
39 | public void setCourseno(String courseno) {
40 | this.courseno = courseno;
41 | }
42 |
43 | public String getTeacherno() {
44 | return teacherno;
45 | }
46 |
47 | public void setTeacherno(String teacherno) {
48 | this.teacherno = teacherno;
49 | }
50 |
51 | public String getClassroomno() {
52 | return classroomno;
53 | }
54 |
55 | public void setClassroomno(String classroomno) {
56 | this.classroomno = classroomno;
57 | }
58 |
59 | public String getClasstime() {
60 | return classtime;
61 | }
62 |
63 | public void setClasstime(String classtime) {
64 | this.classtime = classtime;
65 | }
66 |
67 | public Integer getWeekssum() {
68 | return weekssum;
69 | }
70 |
71 | public void setWeekssum(Integer weekssum) {
72 | this.weekssum = weekssum;
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/UI/my-app/src/App.js:
--------------------------------------------------------------------------------
1 | import React, {Component} from 'react';
2 | import {BrowserRouter, Route, Switch} from 'react-router-dom';
3 | import Login from './Login';
4 | import CollegeRole from './CollegeRole';
5 | import ApplicationManage from './ApplicationManage';
6 | import ClassTask from './ClassTask';
7 | import ClassPlan from './ClassPlan';
8 | import Teacher from './Teacher';
9 | import ApplicationTeacher from './ApplicationTeacher';
10 | import ArrangeTeaching from './ArrangeTeaching';
11 | import AllCollegeRole from './AllCollegeRole';
12 | import TeachBuildInfo from './TeachBuildInfo';
13 | import ArrangingPage from './ArrangingPage';
14 |
15 | class App extends Component {
16 | render() {
17 | return (
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 | );
37 | }
38 | }
39 |
40 | export default App;
41 |
--------------------------------------------------------------------------------
/target/classes/Mapper/CourseInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | delete from course_info
12 | where id = #{id,jdbcType=BIGINT}
13 |
14 |
15 | insert into course_info (id, courseNo, courseName,
16 | courseAttr)
17 | values (#{id,jdbcType=BIGINT}, #{courseno,jdbcType=VARCHAR}, #{coursename,jdbcType=VARCHAR},
18 | #{courseattr,jdbcType=VARCHAR})
19 |
20 |
21 | update course_info
22 | set courseNo = #{courseno,jdbcType=VARCHAR},
23 | courseName = #{coursename,jdbcType=VARCHAR},
24 | courseAttr = #{courseattr,jdbcType=VARCHAR}
25 | where id = #{id,jdbcType=BIGINT}
26 |
27 |
32 |
36 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/CourseInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | delete from course_info
12 | where id = #{id,jdbcType=BIGINT}
13 |
14 |
15 | insert into course_info (id, courseNo, courseName,
16 | courseAttr)
17 | values (#{id,jdbcType=BIGINT}, #{courseno,jdbcType=VARCHAR}, #{coursename,jdbcType=VARCHAR},
18 | #{courseattr,jdbcType=VARCHAR})
19 |
20 |
21 | update course_info
22 | set courseNo = #{courseno,jdbcType=VARCHAR},
23 | courseName = #{coursename,jdbcType=VARCHAR},
24 | courseAttr = #{courseattr,jdbcType=VARCHAR}
25 | where id = #{id,jdbcType=BIGINT}
26 |
27 |
32 |
36 |
--------------------------------------------------------------------------------
/target/classes/Mapper/TeachBuildInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | delete from teach_build_info
11 | where id = #{id,jdbcType=BIGINT}
12 |
13 |
14 | insert into teach_build_info (id, teachBuildNo, teachBuildName
15 | )
16 | values (#{id,jdbcType=BIGINT}, #{teachbuildno,jdbcType=VARCHAR}, #{teachbuildname,jdbcType=VARCHAR}
17 | )
18 |
19 |
20 | update teach_build_info
21 | set teachBuildNo = #{teachbuildno,jdbcType=VARCHAR},
22 | teachBuildName = #{teachbuildname,jdbcType=VARCHAR}
23 | where id = #{id,jdbcType=BIGINT}
24 |
25 |
30 |
38 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/TeachBuildInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | delete from teach_build_info
11 | where id = #{id,jdbcType=BIGINT}
12 |
13 |
14 | insert into teach_build_info (id, teachBuildNo, teachBuildName
15 | )
16 | values (#{id,jdbcType=BIGINT}, #{teachbuildno,jdbcType=VARCHAR}, #{teachbuildname,jdbcType=VARCHAR}
17 | )
18 |
19 |
20 | update teach_build_info
21 | set teachBuildNo = #{teachbuildno,jdbcType=VARCHAR},
22 | teachBuildName = #{teachbuildname,jdbcType=VARCHAR}
23 | where id = #{id,jdbcType=BIGINT}
24 |
25 |
30 |
38 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/CoursePlan.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class CoursePlan {
4 | private Long id;
5 |
6 | private String collegeno;
7 |
8 | private String classno;
9 |
10 | private String courseno;
11 |
12 | private String teacherno;
13 |
14 | private String classroomno;
15 |
16 | private String classtime;
17 |
18 | private Integer weekssum;
19 |
20 | private String semester;
21 |
22 | public Long getId() {
23 | return id;
24 | }
25 |
26 | public void setId(Long id) {
27 | this.id = id;
28 | }
29 |
30 | public String getCollegeno() {
31 | return collegeno;
32 | }
33 |
34 | public void setCollegeno(String collegeno) {
35 | this.collegeno = collegeno;
36 | }
37 |
38 | public String getClassno() {
39 | return classno;
40 | }
41 |
42 | public void setClassno(String classno) {
43 | this.classno = classno;
44 | }
45 |
46 | public String getCourseno() {
47 | return courseno;
48 | }
49 |
50 | public void setCourseno(String courseno) {
51 | this.courseno = courseno;
52 | }
53 |
54 | public String getTeacherno() {
55 | return teacherno;
56 | }
57 |
58 | public void setTeacherno(String teacherno) {
59 | this.teacherno = teacherno;
60 | }
61 |
62 | public String getClassroomno() {
63 | return classroomno;
64 | }
65 |
66 | public void setClassroomno(String classroomno) {
67 | this.classroomno = classroomno;
68 | }
69 |
70 | public String getClasstime() {
71 | return classtime;
72 | }
73 |
74 | public void setClasstime(String classtime) {
75 | this.classtime = classtime;
76 | }
77 |
78 | public Integer getWeekssum() {
79 | return weekssum;
80 | }
81 |
82 | public void setWeekssum(Integer weekssum) {
83 | this.weekssum = weekssum;
84 | }
85 |
86 | public String getSemester() {
87 | return semester;
88 | }
89 |
90 | public void setSemester(String semester) {
91 | this.semester = semester;
92 | }
93 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/LocationInfoService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.LocationInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
5 | import com.xnxy.CourseSchedulingSystem.Dao.LocationInfoDao;
6 | import com.xnxy.CourseSchedulingSystem.Service.ILocationInfoService;
7 | import org.springframework.beans.factory.annotation.Autowired;
8 | import org.springframework.stereotype.Service;
9 |
10 | import java.util.Collections;
11 | import java.util.List;
12 | @Service
13 | public class LocationInfoService implements ILocationInfoService {
14 | @Autowired
15 | LocationInfoDao locationInfoDao;
16 | @Override
17 | public List queryLocationInfo(QueryVO queryVO) {
18 | try{
19 | List locationInfoList = locationInfoDao.selectAll(queryVO);
20 | return locationInfoList;
21 | }catch (Exception e){
22 | e.printStackTrace();
23 | return Collections.emptyList();
24 | }
25 | }
26 |
27 | @Override
28 | public Boolean saveLocationInfo(LocationInfo locationInfo) {
29 | try{
30 | Long id = locationInfo.getId();
31 | if(id != null){
32 | if(locationInfoDao.updateByPrimaryKey(locationInfo) > 0){
33 | return true;
34 | }
35 | return false;
36 | }else{
37 | if(locationInfoDao.insert(locationInfo) > 0){
38 | return true;
39 | }
40 | return false;
41 | }
42 | }catch (Exception e){
43 | e.printStackTrace();
44 | return false;
45 | }
46 |
47 | }
48 |
49 | @Override
50 | public Boolean deleteLocationInfo(LocationInfo locationInfo) {
51 | try{
52 | if(locationInfoDao.deleteByPrimaryKey(locationInfo) > 0 ){
53 | return true;
54 | }
55 | return false;
56 | }catch (Exception e){
57 | e.printStackTrace();
58 | return false;
59 | }
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/vo/ResultVO.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.vo;
2 |
3 | import java.util.Map;
4 |
5 | public class ResultVO {
6 | private String code;
7 | private String message;
8 | private Object data;
9 | private Map pageData;
10 | private static final String SUCCESS_CODE = "1";
11 | private static final String FAILED_CODE = "-1";
12 |
13 | public String getCode() {
14 | return code;
15 | }
16 |
17 | public void setCode(String code) {
18 | this.code = code;
19 | }
20 |
21 | public String getMessage() {
22 | return message;
23 | }
24 |
25 | public void setMessage(String message) {
26 | this.message = message;
27 | }
28 |
29 | public Object getData() {
30 | return data;
31 | }
32 |
33 | public void setData(Object data) {
34 | this.data = data;
35 | }
36 |
37 | public Map getPageData() {
38 | return pageData;
39 | }
40 |
41 | public void setPageData(Map pageData) {
42 | this.pageData = pageData;
43 | }
44 |
45 | public static ResultVO ok(String message){
46 | ResultVO resultVO = new ResultVO();
47 | resultVO.setMessage(message);
48 | resultVO.setCode(SUCCESS_CODE);
49 | return resultVO;
50 | }
51 |
52 | public static ResultVO ok(String message,Object data){
53 | ResultVO resultVO = new ResultVO();
54 | resultVO.setMessage(message);
55 | resultVO.setCode(SUCCESS_CODE);
56 | resultVO.setData(data);
57 | return resultVO;
58 | }
59 |
60 | public static ResultVO ok(String message,Object data,Map pageDate){
61 | ResultVO resultVO = new ResultVO();
62 | resultVO.setMessage(message);
63 | resultVO.setCode(SUCCESS_CODE);
64 | resultVO.setData(data);
65 | resultVO.setPageData(pageDate);
66 | return resultVO;
67 | }
68 |
69 | public static ResultVO faile(String message){
70 | ResultVO resultVO = new ResultVO();
71 | resultVO.setCode(FAILED_CODE);
72 | resultVO.setMessage(message);
73 | return resultVO;
74 | }
75 |
76 |
77 | }
78 |
--------------------------------------------------------------------------------
/target/classes/Mapper/ClassroomLocationMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 | delete from classroom_location
13 | where id = #{id,jdbcType=BIGINT}
14 |
15 |
16 | insert into classroom_location (id, teachBuildNo, classroomNo,
17 | capacity, classroomAttr)
18 | values (#{id,jdbcType=BIGINT}, #{teachbuildno,jdbcType=VARCHAR}, #{classroomno,jdbcType=VARCHAR},
19 | #{capacity,jdbcType=INTEGER}, #{classroomattr,jdbcType=VARCHAR})
20 |
21 |
22 | update classroom_location
23 | set teachBuildNo = #{teachbuildno,jdbcType=VARCHAR},
24 | classroomNo = #{classroomno,jdbcType=VARCHAR},
25 | capacity = #{capacity,jdbcType=INTEGER},
26 | classroomAttr = #{classroomattr,jdbcType=VARCHAR}
27 | where id = #{id,jdbcType=BIGINT}
28 |
29 |
34 |
38 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/ClassroomLocationMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 | delete from classroom_location
13 | where id = #{id,jdbcType=BIGINT}
14 |
15 |
16 | insert into classroom_location (id, teachBuildNo, classroomNo,
17 | capacity, classroomAttr)
18 | values (#{id,jdbcType=BIGINT}, #{teachbuildno,jdbcType=VARCHAR}, #{classroomno,jdbcType=VARCHAR},
19 | #{capacity,jdbcType=INTEGER}, #{classroomattr,jdbcType=VARCHAR})
20 |
21 |
22 | update classroom_location
23 | set teachBuildNo = #{teachbuildno,jdbcType=VARCHAR},
24 | classroomNo = #{classroomno,jdbcType=VARCHAR},
25 | capacity = #{capacity,jdbcType=INTEGER},
26 | classroomAttr = #{classroomattr,jdbcType=VARCHAR}
27 | where id = #{id,jdbcType=BIGINT}
28 |
29 |
34 |
38 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Service/Impl/ClassTaskService.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Service.Impl;
2 |
3 |
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.ConstantInfo;
6 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
7 | import com.xnxy.CourseSchedulingSystem.Dao.ClassTaskDao;
8 | import com.xnxy.CourseSchedulingSystem.Service.IClassTaskService;
9 | import org.springframework.beans.factory.annotation.Autowired;
10 | import org.springframework.stereotype.Service;
11 | import java.util.Collections;
12 | import java.util.List;
13 |
14 | @Service
15 | public class ClassTaskService implements IClassTaskService {
16 | @Autowired
17 | ClassTaskDao classTaskDao;
18 |
19 | @Override
20 | public List queryClassTask(QueryVO queryVO) {
21 | try{
22 | List classTaskList = classTaskDao.selectAll(queryVO);
23 | return classTaskList;
24 | }catch (Exception e){
25 | e.printStackTrace();
26 | return Collections.emptyList();
27 |
28 | }
29 | }
30 |
31 | @Override
32 | public Boolean saveClassTask(ClassTask classTask) {
33 | Long id = classTask.getId();
34 | try{
35 | //根据id是否为空来确定是插入操作还是更新操作
36 | if(id != null){
37 | if(classTaskDao.updateByPrimaryKey(classTask) > 0 ){
38 | return true;
39 | }
40 | return false;
41 | }else {
42 | if(classTaskDao.insert(classTask) > 0 ){
43 | return true;
44 | }
45 | return false;
46 | }
47 | }catch (Exception e){
48 | e.printStackTrace();
49 | return false;
50 | }
51 | }
52 |
53 | @Override
54 | public Boolean deleteClassTask(ClassTask classTask) {
55 | if(classTaskDao.deleteByPrimaryKey(classTask) > 0){
56 | return true;
57 | }else{
58 | return false;
59 | }
60 | }
61 |
62 | @Override
63 | public List querySemester() {
64 | List semesterList = classTaskDao.selectByColumnName(ConstantInfo.SEMESTER);
65 | return semesterList;
66 | }
67 |
68 | }
69 |
--------------------------------------------------------------------------------
/UI/my-app/src/ApplicationManage.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Layout, Menu,Button} from 'antd';
3 | import {Link} from 'react-router-dom';
4 |
5 | const {
6 | Header, Content, Footer, Sider,
7 | } = Layout;
8 |
9 | class ApplicationManage extends PureComponent {
10 | state = {
11 | collapsed: false,
12 | itemId: []
13 | };
14 |
15 | componentDidMount() {
16 | if (this.props.history) {
17 | sessionStorage.setItem('id',this.props.history.location.collegeno);
18 | this.props.history.push({pathname: '/collegeRole'});
19 | }
20 | };
21 |
22 | onCollapse = (collapsed) => {
23 | console.log(collapsed);
24 | this.setState({collapsed});
25 | };
26 |
27 | render() {
28 | const {itemId} = this.state;
29 |
30 | return (
31 |
32 |
37 |
38 |
44 |
45 |
46 |
47 |
48 | {this.props.children}
49 |
50 |
53 |
54 |
55 | );
56 | }
57 | }
58 |
59 | export default ApplicationManage;
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Controller/UserController.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Controller;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.CollegeInfo;
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.CoursePlan;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
6 | import com.xnxy.CourseSchedulingSystem.Bean.vo.ResultVO;
7 | import com.xnxy.CourseSchedulingSystem.Bean.vo.UserInfoVO;
8 | import com.xnxy.CourseSchedulingSystem.Service.ICollegeInfoService;
9 | import com.xnxy.CourseSchedulingSystem.Service.ICoursePlanService;
10 | import com.xnxy.CourseSchedulingSystem.Service.IUserInfoService;
11 | import com.xnxy.CourseSchedulingSystem.Util.PageUtil;
12 | import org.springframework.beans.factory.annotation.Autowired;
13 | import org.springframework.web.bind.annotation.RequestBody;
14 | import org.springframework.web.bind.annotation.RequestMapping;
15 | import org.springframework.web.bind.annotation.RestController;
16 |
17 | import java.util.List;
18 | import java.util.Map;
19 |
20 | @RestController
21 | public class UserController {
22 | @Autowired
23 | IUserInfoService userInfoService;
24 | @Autowired
25 | ICoursePlanService coursePlanService;
26 | @Autowired
27 | ICollegeInfoService collegeInfoService;
28 |
29 | @RequestMapping("/userLogin")
30 | public ResultVO login(@RequestBody UserInfoVO userInfoVO) {
31 | if (userInfoService.login(userInfoVO)) {
32 | return ResultVO.ok("登录成功", userInfoVO);
33 | }
34 | return ResultVO.faile("登录失败");
35 | }
36 |
37 | @RequestMapping("/queryCoursePlan")
38 | public ResultVO queryCoursePlan(@RequestBody QueryVO queryVO){
39 | List coursePlanList = coursePlanService.selectAll(queryVO);
40 | if(coursePlanList != null && coursePlanList.size() > 0){
41 | return ResultVO.ok("查询课表成功",coursePlanList);
42 | }
43 | return ResultVO.faile("课表查询失败");
44 | }
45 |
46 | @RequestMapping("/queryCollegeInfo")
47 | public ResultVO queryCollegeInfo(){
48 | List collegeInfoList = collegeInfoService.findCollegeInfo();
49 | if(collegeInfoList != null && collegeInfoList.size() > 0){
50 | return ResultVO.ok("查询学院信息成功",collegeInfoList);
51 | }
52 | return ResultVO.faile("查询学院失败");
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/target/classes/Mapper/TeachPlanMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 | delete from teach_plan
19 | where id = #{id,jdbcType=BIGINT}
20 |
21 |
22 |
36 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/TeachPlanMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 | delete from teach_plan
19 | where id = #{id,jdbcType=BIGINT}
20 |
21 |
22 |
36 |
--------------------------------------------------------------------------------
/UI/my-app/src/CollegeInfo.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Form, Table, Row, Col, Input, Button, Modal} from 'antd';
3 | import axios from "axios";
4 |
5 | import './CollegeRole.css'
6 |
7 | const FormItem = Form.Item;
8 |
9 | class CollegeInfo extends PureComponent {
10 | state = {tableData:[]};
11 |
12 | tableData=[];
13 |
14 | selectData={};
15 |
16 | columns = [
17 | {title: '序号', dataIndex: 'id',},
18 | {title: '学院编号', dataIndex: 'collegeno',},
19 | {title: '学院名称', dataIndex: 'collegename',},
20 | ];
21 |
22 | getTableData = () => {
23 |
24 | axios.post('/queryCollegeInfo', ).then((res) => {
25 | if (res.data.code === '1') {
26 | this.tableData = res.data.data;
27 | }
28 | });
29 | };
30 |
31 | selectDataHandle = (selectedRowKeys) => {
32 | this.selectData = selectedRowKeys;
33 | };
34 |
35 | render() {
36 | const {form, onCancel, visible, onOk } = this.props;
37 |
38 | if (Object.keys(this.tableData).length === 0 ) {
39 | this.getTableData()
40 | }
41 |
42 | const rowSelectProp = {
43 | type: 'radio',
44 | onSelect: this.selectDataHandle
45 | };
46 |
47 | return (
48 | onOk(this.selectData)} onCancel={onCancel}>
49 |
67 |
68 | )
69 | }
70 | }
71 |
72 | export default Form.create()(CollegeInfo);
--------------------------------------------------------------------------------
/UI/my-app/src/ApplicationTeacher.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Button, Layout, Menu} from 'antd';
3 | import {Link} from 'react-router-dom';
4 |
5 | const {
6 | Header, Content, Footer, Sider,
7 | } = Layout;
8 |
9 | class ApplicationTeacher extends PureComponent {
10 | state = {
11 | collapsed: false,
12 | itemId: []
13 | };
14 |
15 | componentDidMount() {
16 | if (this.props.history)
17 | this.props.history.push('arrangeTeaching')
18 | };
19 |
20 | onCollapse = (collapsed) => {
21 | console.log(collapsed);
22 | this.setState({collapsed});
23 | };
24 |
25 | render() {
26 | const {itemId} = this.state;
27 |
28 | return (
29 |
30 |
35 |
36 |
44 |
45 |
46 |
47 |
48 | {this.props.children}
49 |
50 |
53 |
54 |
55 | );
56 | }
57 | }
58 |
59 | export default ApplicationTeacher;
--------------------------------------------------------------------------------
/target/classes/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8080
2 | spring.datasource.url=jdbc:mysql://localhost:3306/course_scheduling_system?serverTimezone=Hongkong&useUnicode=true&characterEncoding=utf8&useSSL=false
3 | spring.datasource.username=root
4 | spring.datasource.password=root
5 | spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
6 | spring.datasource.type=com.alibaba.druid.pool.DruidDataSource
7 | # 初始化时建立物理连接的个数
8 | spring.datasource.druid.initialsize=5
9 | # 最大连接池数量
10 | spring.datasource.druid.max-active=30
11 | # 最小连接池数量
12 | spring.datasource.druid.min-idle=5
13 | # 获取连接时最大等待时间,单位毫秒
14 | spring.datasource.druid.max-wait=60000
15 | # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
16 | spring.datasource.druid.time-between-eviction-runs-millis=60000
17 | # 连接保持空闲而不被驱逐的最小时间
18 | spring.datasource.druid.min-evictable-idle-time-millis=300000
19 | # 用来检测连接是否有效的sql,要求是一个查询语句
20 | spring.datasource.druid.validation-query=SELECT 1 FROM DUAL
21 | # 建议配置为true,不影响性能,并且保证安全性。申请连接的时候检测,如果空闲时间大于timeBetweenEvictionRunsMillis,执行validationQuery检测连接是否有效。
22 | spring.datasource.druid.test-while-idle=true
23 | # 申请连接时执行validationQuery检测连接是否有效,做了这个配置会降低性能。
24 | spring.datasource.druid.test-on-borrow=false
25 | # 归还连接时执行validationQuery检测连接是否有效,做了这个配置会降低性能。
26 | spring.datasource.druid.test-on-return=false
27 | # 是否缓存preparedStatement,也就是PSCache。PSCache对支持游标的数据库性能提升巨大,比如说oracle。在mysql下建议关闭。
28 | spring.datasource.druid.pool-prepared-statements=false
29 | # 要启用PSCache,必须配置大于0,当大于0时,poolPreparedStatements自动触发修改为true。
30 | #spring.datasource.druid.max-pool-prepared-statement-per-connection-size=50
31 | # 配置监控统计拦截的filters,去掉后监控界面sql无法统计
32 | spring.datasource.druid.filters=stat,wall
33 | # 通过connectProperties属性来打开mergeSql功能;慢SQL记录
34 | spring.datasource.druid.connection-properties=druid.stat.mergeSql=true;druid.stat.slowSqlMillis=500
35 | # 合并多个DruidDataSource的监控数据
36 | spring.datasource.druid.use-global-data-source-stat=true
37 |
38 | # druid连接池监控
39 | #spring.datasource.druid.stat-view-servlet.login-username=admin
40 | #spring.datasource.druid.stat-view-servlet.login-password=admin
41 | #排除一些静态资源提高效率
42 | #spring.datasource.druid.web-stat-filter.exclusions=*.js,*.gif,*.jpg,*.png,*.css,*.ico,/druid/*
43 |
44 | #myBatis配置
45 | mybatis.mapper-locations=classpath*:/Mapper/*.xml
46 | mybatis.type-aliases-package=com.xnxy.CourseSchedulingSystem.Bean.po
47 | #pagehelper分页插件配置
48 | pagehelper.helperDialect=mysql
49 | pagehelper.reasonable=true
50 | pagehelper.supportMethodsArguments=true
51 | pagehelper.params=count=countSql
--------------------------------------------------------------------------------
/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8080
2 | spring.datasource.url=jdbc:mysql://localhost:3306/course_scheduling_system?serverTimezone=Hongkong&useUnicode=true&characterEncoding=utf8&useSSL=false
3 | spring.datasource.username=root
4 | spring.datasource.password=root
5 | spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
6 | spring.datasource.type=com.alibaba.druid.pool.DruidDataSource
7 | # 初始化时建立物理连接的个数
8 | spring.datasource.druid.initialsize=5
9 | # 最大连接池数量
10 | spring.datasource.druid.max-active=30
11 | # 最小连接池数量
12 | spring.datasource.druid.min-idle=5
13 | # 获取连接时最大等待时间,单位毫秒
14 | spring.datasource.druid.max-wait=60000
15 | # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
16 | spring.datasource.druid.time-between-eviction-runs-millis=60000
17 | # 连接保持空闲而不被驱逐的最小时间
18 | spring.datasource.druid.min-evictable-idle-time-millis=300000
19 | # 用来检测连接是否有效的sql,要求是一个查询语句
20 | spring.datasource.druid.validation-query=SELECT 1 FROM DUAL
21 | # 建议配置为true,不影响性能,并且保证安全性。申请连接的时候检测,如果空闲时间大于timeBetweenEvictionRunsMillis,执行validationQuery检测连接是否有效。
22 | spring.datasource.druid.test-while-idle=true
23 | # 申请连接时执行validationQuery检测连接是否有效,做了这个配置会降低性能。
24 | spring.datasource.druid.test-on-borrow=false
25 | # 归还连接时执行validationQuery检测连接是否有效,做了这个配置会降低性能。
26 | spring.datasource.druid.test-on-return=false
27 | # 是否缓存preparedStatement,也就是PSCache。PSCache对支持游标的数据库性能提升巨大,比如说oracle。在mysql下建议关闭。
28 | spring.datasource.druid.pool-prepared-statements=false
29 | # 要启用PSCache,必须配置大于0,当大于0时,poolPreparedStatements自动触发修改为true。
30 | #spring.datasource.druid.max-pool-prepared-statement-per-connection-size=50
31 | # 配置监控统计拦截的filters,去掉后监控界面sql无法统计
32 | spring.datasource.druid.filters=stat,wall
33 | # 通过connectProperties属性来打开mergeSql功能;慢SQL记录
34 | spring.datasource.druid.connection-properties=druid.stat.mergeSql=true;druid.stat.slowSqlMillis=500
35 | # 合并多个DruidDataSource的监控数据
36 | spring.datasource.druid.use-global-data-source-stat=true
37 |
38 | # druid连接池监控
39 | #spring.datasource.druid.stat-view-servlet.login-username=admin
40 | #spring.datasource.druid.stat-view-servlet.login-password=admin
41 | #排除一些静态资源提高效率
42 | #spring.datasource.druid.web-stat-filter.exclusions=*.js,*.gif,*.jpg,*.png,*.css,*.ico,/druid/*
43 |
44 | #myBatis配置
45 | mybatis.mapper-locations=classpath*:/Mapper/*.xml
46 | mybatis.type-aliases-package=com.xnxy.CourseSchedulingSystem.Bean.po
47 | #pagehelper分页插件配置
48 | pagehelper.helperDialect=mysql
49 | pagehelper.reasonable=true
50 | pagehelper.supportMethodsArguments=true
51 | pagehelper.params=count=countSql
--------------------------------------------------------------------------------
/UI/my-app/src/TeachBuildInfo.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Form, Table, Row, Col, Input, Button, Modal} from 'antd'
3 | import axios from "axios/index";
4 |
5 | import './CollegeRole.css'
6 |
7 | const FormItem = Form.Item;
8 |
9 | const columns = [
10 | {title: '序号', dataIndex: 'id',},
11 | {title: '教学楼编号', dataIndex: 'teachbuildno',},
12 | {title: '教学楼名称', dataIndex: 'teachbuildname',},
13 | ];
14 |
15 | class TeachBuildInfo extends PureComponent {
16 | state = {tableData:[]};
17 |
18 | tableData=[];
19 |
20 | selectData={};
21 |
22 | getTableData = () => {
23 |
24 | axios.post('/queryTeachBuildInfo',{}).then((res) => {
25 | if (res.data.code === '1') {
26 | this.tableData = res.data.data;
27 | }
28 | });
29 | };
30 |
31 | selectDataHandle = (selectedRowKeys) => {
32 | this.selectData = selectedRowKeys;
33 | };
34 |
35 | render() {
36 | const {form, onCancel, visible, onOk} = this.props;
37 |
38 | if (Object.keys(this.tableData).length === 0 ) {
39 | this.getTableData()
40 | }
41 |
42 | const rowSelectProp = {
43 | type: 'radio',
44 | onSelect: this.selectDataHandle
45 | };
46 |
47 | return (
48 | onOk(this.selectData)} onCancel={onCancel}>
49 |
72 |
73 | )
74 | }
75 | }
76 |
77 | export default Form.create()(TeachBuildInfo);
--------------------------------------------------------------------------------
/UI/my-app/src/logo.svg:
--------------------------------------------------------------------------------
1 |
8 |
--------------------------------------------------------------------------------
/UI/my-app/src/Teacher.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Form, Table, Row, Col, Input, Button, Modal} from 'antd';
3 | import axios from "axios";
4 |
5 | import './CollegeRole.css'
6 |
7 | const FormItem = Form.Item;
8 |
9 | class Teacher extends PureComponent {
10 |
11 | selectData = {};
12 |
13 | tableData = [];
14 |
15 | columns = [
16 | {title: '序号', dataIndex: 'id',},
17 | {title: '学院', dataIndex: 'collegeno',},
18 | {title: '教师编号', dataIndex: 'teacherno',},
19 | {title: '教师名', dataIndex: 'teachername',},
20 | {title: '年龄', dataIndex: 'age',},
21 | {title: '职称', dataIndex: 'title',},
22 | ];
23 |
24 | getTableData = () => {
25 | const {collegeno} = this.props;
26 |
27 | axios.post('/queryTeacherInfo', {collegeno}).then((res) => {
28 | if (res.data.code === '1') {
29 | this.tableData = res.data.data;
30 | }
31 | });
32 | };
33 |
34 | selectDataHandle = (selectedRowKeys) => {
35 | this.selectData = selectedRowKeys;
36 | };
37 |
38 | render() {
39 | const {form, onCancel, visible, onOk, collegeno} = this.props;
40 |
41 | if (Object.keys(this.tableData).length === 0 && collegeno) {
42 | this.getTableData()
43 | }
44 |
45 | const rowSelectProp = {
46 | type: 'radio',
47 | onSelect: this.selectDataHandle
48 | };
49 |
50 | return (
51 | onOk(this.selectData)} onCancel={onCancel}>
52 |
71 |
72 | )
73 | }
74 | }
75 |
76 | const TeacherPage = Form.create()(Teacher);
77 |
78 | export default TeacherPage;
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/TeachPlan.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class TeachPlan {
4 | private Long id;
5 |
6 | private String classno;
7 |
8 | private String classname;
9 |
10 | private String courseno;
11 |
12 | private String collegeno;
13 |
14 | private Integer studentnumber;
15 |
16 | private String courseattr;
17 |
18 | private Integer classhour;
19 |
20 | private Integer weeksnumber;
21 |
22 | private Integer weekssum;
23 |
24 | private String semester;
25 |
26 | public Long getId() {
27 | return id;
28 | }
29 |
30 | public void setId(Long id) {
31 | this.id = id;
32 | }
33 |
34 | public String getClassno() {
35 | return classno;
36 | }
37 |
38 | public void setClassno(String classno) {
39 | this.classno = classno;
40 | }
41 |
42 | public String getClassname() {
43 | return classname;
44 | }
45 |
46 | public void setClassname(String classname) {
47 | this.classname = classname;
48 | }
49 |
50 | public String getCourseno() {
51 | return courseno;
52 | }
53 |
54 | public void setCourseno(String courseno) {
55 | this.courseno = courseno;
56 | }
57 |
58 | public String getCollegeno() {
59 | return collegeno;
60 | }
61 |
62 | public void setCollegeno(String collegeno) {
63 | this.collegeno = collegeno;
64 | }
65 |
66 | public Integer getStudentnumber() {
67 | return studentnumber;
68 | }
69 |
70 | public void setStudentnumber(Integer studentnumber) {
71 | this.studentnumber = studentnumber;
72 | }
73 |
74 | public String getCourseattr() {
75 | return courseattr;
76 | }
77 |
78 | public void setCourseattr(String courseattr) {
79 | this.courseattr = courseattr;
80 | }
81 |
82 | public Integer getClasshour() {
83 | return classhour;
84 | }
85 |
86 | public void setClasshour(Integer classhour) {
87 | this.classhour = classhour;
88 | }
89 |
90 | public Integer getWeeksnumber() {
91 | return weeksnumber;
92 | }
93 |
94 | public void setWeeksnumber(Integer weeksnumber) {
95 | this.weeksnumber = weeksnumber;
96 | }
97 |
98 | public Integer getWeekssum() {
99 | return weekssum;
100 | }
101 |
102 | public void setWeekssum(Integer weekssum) {
103 | this.weekssum = weekssum;
104 | }
105 |
106 | public String getSemester() {
107 | return semester;
108 | }
109 |
110 | public void setSemester(String semester) {
111 | this.semester = semester;
112 | }
113 | }
--------------------------------------------------------------------------------
/UI/my-app/src/ClassPlan.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Form, Table, Row, Col, Input, Button, Modal} from 'antd';
3 |
4 | import './CollegeRole.css'
5 | import axios from "axios/index";
6 |
7 | const FormItem = Form.Item;
8 |
9 | class ClassPlan extends PureComponent {
10 |
11 |
12 | tableData=[];
13 | selectData = {};
14 |
15 | columns = [
16 | {title: '序号', dataIndex: 'id',},
17 | {title: '学期', dataIndex: 'semester',},
18 | {title: '班级', dataIndex: 'classno',render:(text,record)=>(record.classname)},
19 | {title: '课程', dataIndex: 'courseno',render:(text,record)=>(record.courseName)},
20 | {title: '课程属性', dataIndex: 'courseattr',},
21 | {title: '人数', dataIndex: 'studentnumber',},
22 | {title: '周学时', dataIndex: 'weeksnumber',},
23 | {title: '周数', dataIndex: 'weekssum',},
24 | ];
25 |
26 | getTableData = () => {
27 | const {collegeno} = this.props;
28 |
29 | axios.post('/queryTeachPlan', {collegeno}).then((res) => {
30 | if (res.data.code === '1') {
31 | this.tableData = res.data.data;
32 | }
33 | });
34 | };
35 |
36 | selectDataHandle = (selectedRowKeys) => {
37 | this.selectData = selectedRowKeys;
38 | };
39 |
40 | render() {
41 | const {form, onCancel, visible, onOk, collegeno} = this.props;
42 |
43 | if (collegeno) {
44 | this.getTableData()
45 | }
46 |
47 | const rowSelectProp = {
48 | type: 'radio',
49 | onSelect: this.selectDataHandle
50 | };
51 |
52 | return (
53 | onOk(this.selectData)} onCancel={onCancel}>
54 |
76 |
77 | )
78 | }
79 | }
80 |
81 | const ClassTaskPage = Form.create()(ClassPlan);
82 |
83 | export default ClassTaskPage;
--------------------------------------------------------------------------------
/target/classes/Mapper/LocationInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | delete from location_info
11 | where id = #{id,jdbcType=BIGINT}
12 |
13 |
14 | insert into location_info
15 |
16 |
17 | teachBuildNo,
18 |
19 |
20 | collegeNo
21 |
22 |
23 |
24 |
25 | #{teachbuildno,jdbcType=VARCHAR},
26 |
27 |
28 | #{collegeno,jdbcType=VARCHAR}
29 |
30 |
31 |
32 |
33 | update location_info
34 |
35 |
36 | teachBuildNo = #{teachbuildno,jdbcType=VARCHAR},
37 |
38 |
39 | collegeNo = #{collegeno,jdbcType=VARCHAR}
40 |
41 |
42 | where id = #{id,jdbcType=BIGINT}
43 |
44 |
45 |
54 |
55 |
59 |
60 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/LocationInfoMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | delete from location_info
11 | where id = #{id,jdbcType=BIGINT}
12 |
13 |
14 | insert into location_info
15 |
16 |
17 | teachBuildNo,
18 |
19 |
20 | collegeNo
21 |
22 |
23 |
24 |
25 | #{teachbuildno,jdbcType=VARCHAR},
26 |
27 |
28 | #{collegeno,jdbcType=VARCHAR}
29 |
30 |
31 |
32 |
33 | update location_info
34 |
35 |
36 | teachBuildNo = #{teachbuildno,jdbcType=VARCHAR},
37 |
38 |
39 | collegeNo = #{collegeno,jdbcType=VARCHAR}
40 |
41 |
42 | where id = #{id,jdbcType=BIGINT}
43 |
44 |
45 |
54 |
55 |
59 |
60 |
--------------------------------------------------------------------------------
/target/classes/Mapper/TeacherCourseMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 | delete from teacher_course
14 | where id = #{id,jdbcType=BIGINT}
15 |
16 |
17 | insert into teacher_course
18 |
19 |
20 | classNo,
21 |
22 |
23 | courseNo,
24 |
25 |
26 | teacherNo,
27 |
28 |
29 | classroomNo,
30 |
31 |
32 | classTime
33 |
34 |
35 |
36 |
37 | #{classno,jdbcType=VARCHAR},
38 |
39 |
40 | #{courseno,jdbcType=VARCHAR},
41 |
42 |
43 | #{teacherno,jdbcType=VARCHAR},
44 |
45 |
46 | #{classroomno,jdbcType=VARCHAR},
47 |
48 |
49 | #{classtime,jdbcType=VARCHAR}
50 |
51 |
52 |
53 |
54 | update teacher_course
55 | set teacherNo = #{teacherno,jdbcType=VARCHAR},
56 | courseNo = #{courseno,jdbcType=VARCHAR},
57 | classNo = #{classno,jdbcType=VARCHAR},
58 | classroomNo = #{classroomno,jdbcType=VARCHAR}
59 | where id = #{id,jdbcType=BIGINT}
60 |
61 |
66 |
70 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/TeacherCourseMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 | delete from teacher_course
14 | where id = #{id,jdbcType=BIGINT}
15 |
16 |
17 | insert into teacher_course
18 |
19 |
20 | classNo,
21 |
22 |
23 | courseNo,
24 |
25 |
26 | teacherNo,
27 |
28 |
29 | classroomNo,
30 |
31 |
32 | classTime
33 |
34 |
35 |
36 |
37 | #{classno,jdbcType=VARCHAR},
38 |
39 |
40 | #{courseno,jdbcType=VARCHAR},
41 |
42 |
43 | #{teacherno,jdbcType=VARCHAR},
44 |
45 |
46 | #{classroomno,jdbcType=VARCHAR},
47 |
48 |
49 | #{classtime,jdbcType=VARCHAR}
50 |
51 |
52 |
53 |
54 | update teacher_course
55 | set teacherNo = #{teacherno,jdbcType=VARCHAR},
56 | courseNo = #{courseno,jdbcType=VARCHAR},
57 | classNo = #{classno,jdbcType=VARCHAR},
58 | classroomNo = #{classroomno,jdbcType=VARCHAR}
59 | where id = #{id,jdbcType=BIGINT}
60 |
61 |
66 |
70 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/po/ClassTask.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.po;
2 |
3 | public class ClassTask {
4 | private Long id;
5 |
6 | private String semester;
7 |
8 | private String collegeno;
9 |
10 | private String classno;
11 |
12 | private String courseno;
13 |
14 | private String teacherno;
15 |
16 | private String courseattr;
17 |
18 | private Integer studentnumber;
19 |
20 | private Integer weekssum;
21 |
22 | private Integer weeksnumber;
23 |
24 | private String isfix;
25 |
26 | private String classtime;
27 |
28 | public Long getId() {
29 | return id;
30 | }
31 |
32 | public void setId(Long id) {
33 | this.id = id;
34 | }
35 |
36 | public String getSemester() {
37 | return semester;
38 | }
39 |
40 | public void setSemester(String semester) {
41 | this.semester = semester;
42 | }
43 |
44 | public String getCollegeno() {
45 | return collegeno;
46 | }
47 |
48 | public void setCollegeno(String collegeno) {
49 | this.collegeno = collegeno;
50 | }
51 |
52 | public String getClassno() {
53 | return classno;
54 | }
55 |
56 | public void setClassno(String classno) {
57 | this.classno = classno;
58 | }
59 |
60 | public String getCourseno() {
61 | return courseno;
62 | }
63 |
64 | public void setCourseno(String courseno) {
65 | this.courseno = courseno;
66 | }
67 |
68 | public String getTeacherno() {
69 | return teacherno;
70 | }
71 |
72 | public void setTeacherno(String teacherno) {
73 | this.teacherno = teacherno;
74 | }
75 |
76 | public String getCourseattr() {
77 | return courseattr;
78 | }
79 |
80 | public void setCourseattr(String courseattr) {
81 | this.courseattr = courseattr;
82 | }
83 |
84 | public Integer getStudentnumber() {
85 | return studentnumber;
86 | }
87 |
88 | public void setStudentnumber(Integer studentnumber) {
89 | this.studentnumber = studentnumber;
90 | }
91 |
92 | public Integer getWeekssum() {
93 | return weekssum;
94 | }
95 |
96 | public void setWeekssum(Integer weekssum) {
97 | this.weekssum = weekssum;
98 | }
99 |
100 | public Integer getWeeksnumber() {
101 | return weeksnumber;
102 | }
103 |
104 | public void setWeeksnumber(Integer weeksnumber) {
105 | this.weeksnumber = weeksnumber;
106 | }
107 |
108 | public String getIsfix() {
109 | return isfix;
110 | }
111 |
112 | public void setIsfix(String isfix) {
113 | this.isfix = isfix;
114 | }
115 |
116 | public String getClasstime() {
117 | return classtime;
118 | }
119 |
120 | public void setClasstime(String classtime) {
121 | this.classtime = classtime;
122 | }
123 | }
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Bean/vo/TeachPlanVO.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Bean.vo;
2 |
3 | public class TeachPlanVO {
4 | private Long id;
5 | private String classno;
6 |
7 | private String classname;
8 |
9 | private String courseno;
10 |
11 | private String courseName;
12 |
13 | private String collegeno;
14 |
15 | private Integer studentnumber;
16 |
17 | private String courseattr;
18 |
19 | private Integer classhour;
20 |
21 | private Integer weeksnumber;
22 |
23 | private Integer weekssum;
24 |
25 | private String semester;
26 |
27 | public Long getId() {
28 | return id;
29 | }
30 |
31 | public void setId(Long id) {
32 | this.id = id;
33 | }
34 |
35 | public String getClassno() {
36 | return classno;
37 | }
38 |
39 | public void setClassno(String classno) {
40 | this.classno = classno;
41 | }
42 |
43 | public String getClassname() {
44 | return classname;
45 | }
46 |
47 | public void setClassname(String classname) {
48 | this.classname = classname;
49 | }
50 |
51 | public String getCourseno() {
52 | return courseno;
53 | }
54 |
55 | public void setCourseno(String courseno) {
56 | this.courseno = courseno;
57 | }
58 |
59 | public String getCourseName() {
60 | return courseName;
61 | }
62 |
63 | public void setCourseName(String courseName) {
64 | this.courseName = courseName;
65 | }
66 |
67 | public String getCollegeno() {
68 | return collegeno;
69 | }
70 |
71 | public void setCollegeno(String collegeno) {
72 | this.collegeno = collegeno;
73 | }
74 |
75 | public Integer getStudentnumber() {
76 | return studentnumber;
77 | }
78 |
79 | public void setStudentnumber(Integer studentnumber) {
80 | this.studentnumber = studentnumber;
81 | }
82 |
83 | public String getCourseattr() {
84 | return courseattr;
85 | }
86 |
87 | public void setCourseattr(String courseattr) {
88 | this.courseattr = courseattr;
89 | }
90 |
91 | public Integer getClasshour() {
92 | return classhour;
93 | }
94 |
95 | public void setClasshour(Integer classhour) {
96 | this.classhour = classhour;
97 | }
98 |
99 | public Integer getWeeksnumber() {
100 | return weeksnumber;
101 | }
102 |
103 | public void setWeeksnumber(Integer weeksnumber) {
104 | this.weeksnumber = weeksnumber;
105 | }
106 |
107 | public Integer getWeekssum() {
108 | return weekssum;
109 | }
110 |
111 | public void setWeekssum(Integer weekssum) {
112 | this.weekssum = weekssum;
113 | }
114 |
115 | public String getSemester() {
116 | return semester;
117 | }
118 |
119 | public void setSemester(String semester) {
120 | this.semester = semester;
121 | }
122 | }
123 |
--------------------------------------------------------------------------------
/UI/my-app/README.md:
--------------------------------------------------------------------------------
1 | This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
2 |
3 | ## Available Scripts
4 |
5 | In the project directory, you can run:
6 |
7 | ### `npm start`
8 |
9 | Runs the app in the development mode.
10 | Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
11 |
12 | The page will reload if you make edits.
13 | You will also see any lint errors in the console.
14 |
15 | ### `npm test`
16 |
17 | Launches the test runner in the interactive watch mode.
18 | See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
19 |
20 | ### `npm run build`
21 |
22 | Builds the app for production to the `build` folder.
23 | It correctly bundles React in production mode and optimizes the build for the best performance.
24 |
25 | The build is minified and the filenames include the hashes.
26 | Your app is ready to be deployed!
27 |
28 | See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
29 |
30 | ### `npm run eject`
31 |
32 | **Note: this is a one-way operation. Once you `eject`, you can’t go back!**
33 |
34 | If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
35 |
36 | Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.
37 |
38 | You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.
39 |
40 | ## Learn More
41 |
42 | You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
43 |
44 | To learn React, check out the [React documentation](https://reactjs.org/).
45 |
46 | ### Code Splitting
47 |
48 | This section has moved here: https://facebook.github.io/create-react-app/docs/code-splitting
49 |
50 | ### Analyzing the Bundle Size
51 |
52 | This section has moved here: https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size
53 |
54 | ### Making a Progressive Web App
55 |
56 | This section has moved here: https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app
57 |
58 | ### Advanced Configuration
59 |
60 | This section has moved here: https://facebook.github.io/create-react-app/docs/advanced-configuration
61 |
62 | ### Deployment
63 |
64 | This section has moved here: https://facebook.github.io/create-react-app/docs/deployment
65 |
66 | ### `npm run build` fails to minify
67 |
68 | This section has moved here: https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify
69 |
--------------------------------------------------------------------------------
/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | org.springframework.boot
7 | spring-boot-starter-parent
8 | 2.1.3.RELEASE
9 |
10 |
11 | com.xnxy
12 | CourseSchedulingSystem
13 | 0.0.1-SNAPSHOT
14 | CourseSchedulingSystem
15 | Demo project for Spring Boot
16 |
17 |
18 | 1.8
19 |
20 |
21 |
22 |
23 | org.springframework.boot
24 | spring-boot-starter-web
25 |
26 |
27 | org.mybatis.spring.boot
28 | mybatis-spring-boot-starter
29 | 2.0.0
30 |
31 |
32 |
33 | org.springframework.boot
34 | spring-boot-devtools
35 | runtime
36 |
37 |
38 | mysql
39 | mysql-connector-java
40 | runtime
41 |
42 |
43 | org.springframework.boot
44 | spring-boot-starter-test
45 | test
46 |
47 |
48 | org.mybatis.generator
49 | mybatis-generator-core
50 | 1.3.5
51 |
52 |
53 | org.apache.commons
54 | commons-lang3
55 | 3.0
56 |
57 |
58 |
59 | com.alibaba
60 | druid-spring-boot-starter
61 | RELEASE
62 |
63 |
64 |
65 | com.github.pagehelper
66 | pagehelper-spring-boot-starter
67 | 1.2.5
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 | org.springframework.boot
76 | spring-boot-maven-plugin
77 |
78 |
79 | org.mybatis.generator
80 | mybatis-generator-maven-plugin
81 | 1.3.7
82 |
83 |
84 |
85 |
86 |
--------------------------------------------------------------------------------
/UI/my-app/src/ArrangingPage.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Form, Table, Row, Col, Input, Button, Switch, Select,message} from 'antd';
3 | import ApplicationTeacher from './ApplicationTeacher';
4 | import axios from "axios";
5 |
6 | import './CollegeRole.css'
7 |
8 | const FormItem = Form.Item;
9 |
10 | const columns = [
11 | {title: '序号', dataIndex: 'id',},
12 | {title: '学期', dataIndex: 'semester',},
13 | {title: '学院', dataIndex: 'collegeno',},
14 | {title: '班级', dataIndex: 'classno',},
15 | {title: '课程', dataIndex: 'courseno',},
16 | {title: '课程属性', dataIndex: 'courseattr',},
17 | {title: '人数', dataIndex: 'studentnumber',},
18 | {title: '周学时', dataIndex: 'weeksnumber',},
19 | {title: '周数', dataIndex: 'weekssum',},
20 | {title: '是否固定', dataIndex: 'isfix',},
21 | {title: '固定时间', dataIndex: 'classtime',},
22 | ];
23 |
24 | class ArrangingPage extends PureComponent {
25 | state = {tableData:[],semesterList:[]};
26 |
27 | componentWillMount() {
28 | axios.post('/querySemester').then((res) => {
29 | if (res.data.code === '1') {
30 | this.setState({semesterList:res.data.data})
31 | }
32 | });
33 | this.getTableData({})
34 | }
35 |
36 | getTableData=(data)=>{
37 | axios.post('/queryClassTask',data ).then((res) => {
38 | if (res.data.code === '1') {
39 | res.data.data.forEach(a=>{
40 | if (a.isfix === '1') {
41 | a.isfix = '否'
42 | } else {
43 | a.isfix = '是'
44 | }
45 | });
46 | this.setState({tableData:res.data.data});
47 | }
48 | });
49 | };
50 |
51 | arrangeClick=()=>{
52 | const {form} = this.props;
53 |
54 | axios.post('/classScheduling',{semester:form.getFieldsValue().semester}).then((res) => {
55 | if (res.data.code === '1') {
56 | message.success('排课成功');
57 | this.props.history.push({pathname: 'allCollegeRole'});
58 | }else{
59 | message.error('排课失败!')
60 | }
61 | });
62 | };
63 |
64 | render() {
65 | const {form} = this.props;
66 | const {tableData,semesterList}=this.state;
67 |
68 | const options=(
69 | semesterList.map(a=>{a})
70 | );
71 | return (
72 |
73 |
89 |
90 | )
91 | }
92 | }
93 |
94 | const ArrangPage = Form.create()(ArrangingPage);
95 |
96 | export default ArrangPage;
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Controller/collegeController.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Controller;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeacherInfo;
5 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
6 | import com.xnxy.CourseSchedulingSystem.Bean.vo.ResultVO;
7 | import com.xnxy.CourseSchedulingSystem.Bean.vo.TeachPlanVO;
8 | import com.xnxy.CourseSchedulingSystem.Util.PageUtil;
9 | import com.xnxy.CourseSchedulingSystem.Service.IClassTaskService;
10 | import com.xnxy.CourseSchedulingSystem.Service.ITeachPlanService;
11 | import com.xnxy.CourseSchedulingSystem.Service.ITeacherInfoService;
12 | import org.springframework.beans.factory.annotation.Autowired;
13 | import org.springframework.web.bind.annotation.RequestBody;
14 | import org.springframework.web.bind.annotation.RequestMapping;
15 | import org.springframework.web.bind.annotation.RestController;
16 |
17 | import java.util.List;
18 |
19 | @RestController
20 | public class collegeController {
21 | @Autowired
22 | ITeachPlanService teachPlanService;
23 | @Autowired
24 | ITeacherInfoService teacherInfoService;
25 | @Autowired
26 | IClassTaskService classTaskService;
27 |
28 | @RequestMapping("/queryTeachPlan")
29 | public ResultVO queryTeachPlan (@RequestBody QueryVO queryVO){
30 | //PageUtil.pageHelper(queryVO);
31 | List teachPlanVOList = teachPlanService.queryTeachPlan(queryVO);
32 | if(teachPlanVOList != null && teachPlanVOList.size() > 0){
33 | return ResultVO.ok("查询学院教学计划成功",teachPlanVOList);
34 | // return ResultVO.ok("查询学院教学计划成功",teachPlanVOList,PageUtil.pageDataHelper(teachPlanVOList));
35 | }
36 | return ResultVO.ok("暂无数据");
37 | }
38 |
39 | @RequestMapping("/queryTeacherInfo")
40 | public ResultVO queryTeacherInfo (@RequestBody QueryVO queryVO){
41 | //PageUtil.pageHelper(queryVO);
42 | List teacherInfoList = teacherInfoService.queryTeacherInfo(queryVO);
43 | return ResultVO.ok("查询教师信息成功",teacherInfoList);
44 | //return ResultVO.ok("查询教师信息成功",teacherInfoList,PageUtil.pageDataHelper(teacherInfoList));
45 | }
46 |
47 | @RequestMapping("/queryClassTask")
48 | public ResultVO queryClassTask(@RequestBody QueryVO queryVO){
49 | // PageUtil.pageHelper(queryVO);
50 | List classTaskList = classTaskService.queryClassTask(queryVO);
51 | if(classTaskList != null && classTaskList.size() > 0 ){
52 | return ResultVO.ok("查询学院开课任务书成功",classTaskList);
53 | //return ResultVO.ok("查询学院开课任务书成功",classTaskList,PageUtil.pageDataHelper(classTaskList));
54 | }
55 | return ResultVO.faile("查询开课任务书失败,没有数据");
56 | }
57 |
58 | @RequestMapping("/saveClassTask")
59 | public ResultVO saveClassTask(@RequestBody ClassTask classTask){
60 | if(classTaskService.saveClassTask(classTask)){
61 | QueryVO queryVO = new QueryVO();
62 | queryVO.setCollegeno(classTask.getCollegeno());
63 | List classTaskList = classTaskService.queryClassTask(queryVO);
64 | return ResultVO.ok("开课任务保存成功",classTaskList);
65 | }
66 | return ResultVO.faile("开课任务保存失败");
67 | }
68 |
69 | @RequestMapping("/deleteClassTask")
70 | public ResultVO deleteClassTask(@RequestBody ClassTask classTask){
71 | if(classTaskService.deleteClassTask(classTask)){
72 | QueryVO queryVO = new QueryVO();
73 | queryVO.setCollegeno(classTask.getCollegeno());
74 | List classTaskList = classTaskService.queryClassTask(queryVO);
75 | return ResultVO.ok("开课任务删除成功",classTaskList);
76 | }
77 | return ResultVO.faile("开课任务删除成功");
78 | }
79 | }
80 |
--------------------------------------------------------------------------------
/target/classes/generatorConfig.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
25 |
26 |
27 |
29 |
30 |
31 |
32 |
33 |
37 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
48 |
50 |
51 |
52 |
53 |
54 |
57 |
60 |
61 |
62 |
63 |
64 |
69 |
78 |
79 |
80 |
81 |
82 |
--------------------------------------------------------------------------------
/src/main/resources/generatorConfig.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
25 |
26 |
27 |
29 |
30 |
31 |
32 |
33 |
37 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
48 |
50 |
51 |
52 |
53 |
54 |
57 |
60 |
61 |
62 |
63 |
64 |
69 |
78 |
79 |
80 |
81 |
82 |
--------------------------------------------------------------------------------
/src/test/java/ClassSchedulingTest.java:
--------------------------------------------------------------------------------
1 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
2 | import com.xnxy.CourseSchedulingSystem.CourseSchedulingSystemApplication;
3 | import com.xnxy.CourseSchedulingSystem.Dao.ClassTaskDao;
4 | import com.xnxy.CourseSchedulingSystem.Service.IClassSchedulingService;
5 | import com.xnxy.CourseSchedulingSystem.Service.Impl.ClassSchedulingService;
6 | import com.xnxy.CourseSchedulingSystem.Service.Impl.ClassTaskService;
7 | import org.junit.Test;
8 | import org.junit.runner.RunWith;
9 | import org.springframework.beans.factory.annotation.Autowired;
10 | import org.springframework.boot.test.context.SpringBootTest;
11 | import org.springframework.test.context.junit4.SpringRunner;
12 |
13 | import java.util.*;
14 |
15 | @RunWith(SpringRunner.class)
16 | @SpringBootTest(classes = CourseSchedulingSystemApplication.class)
17 | public class ClassSchedulingTest {
18 | @Autowired
19 | ClassTaskDao classTaskDao;
20 | @Autowired
21 | ClassTaskService classTaskService;
22 | @Autowired
23 | IClassSchedulingService iclassSchedulingService;
24 |
25 |
26 | @Test
27 | public void codingTimeTest() {
28 | ClassTask classTask = new ClassTask();
29 | classTask.setSemester("2015-2016-1");
30 | if(iclassSchedulingService.classScheduling(classTask)){
31 | System.out.println("成功成功");
32 | }else{
33 | System.out.println("失败失败");
34 | }
35 |
36 |
37 | }
38 |
39 |
40 | @Test
41 | public void transformIndividualTest() {
42 | Map> individualMap = new HashMap<>();
43 | List individualList = new ArrayList<>();
44 | List individualList2 = new ArrayList<>();
45 | List individualList3 = new ArrayList<>();
46 | individualList.add("2012015010101011000021000010102");
47 | individualList.add("2012015010101011000021000010115");
48 | individualList.add("1182015010101011000011000010118");
49 | individualList.add("1172015010101011000011000010117");
50 | individualList.add("1062015010101011000011000010106");
51 | individualList.add("1042015010101011000011000010104");
52 | individualList.add("1132015010101011000011000010113");
53 | individualList.add("1212015010101011000011000010121");
54 |
55 | individualList2.add("2012015020101021000011000010102");
56 | individualList2.add("2012015020101021000011000010115");
57 | individualList2.add("1182015020101021000011000010118");
58 | individualList2.add("1172015020101021000011000010117");
59 | individualList2.add("1062015020101021000011000010106");
60 | individualList2.add("1042015020101021000011000010104");
61 | individualList2.add("1132015020101021000011000010113");
62 | individualList2.add("1212015020101011000011000010124");
63 |
64 | individualList3.add("2012015020301031000021000010102");
65 | individualList3.add("2012015020301031000021000010115");
66 | individualList3.add("1182015020301031000021000010118");
67 | individualList3.add("1172015020301031000021000010117");
68 | individualList3.add("1062015020301031000021000010106");
69 | individualList3.add("1042015020301031000021000010104");
70 | individualList3.add("1132015020301021000011000010111");
71 | individualList3.add("1212015020301011000011000010123");
72 |
73 | individualMap.put("2105010101", individualList);
74 | individualMap.put("2015020101", individualList2);
75 | individualMap.put("2015020301", individualList3);
76 |
77 | // ClassSchedulingService classSchedulingService = new ClassSchedulingService();
78 | individualMap = iclassSchedulingService.geneticEvolution(individualMap);
79 | List resultList = iclassSchedulingService.finalResult(individualMap);
80 | // for (String classNo : individualMap.keySet()) {
81 | // System.out.println("********************" + classNo);
82 | // List strings = individualMap.get(classNo);
83 | // for (String gene : strings) {
84 | // System.out.println(gene);
85 | // }
86 | // }
87 | for(String result:resultList){
88 | System.out.println(result);
89 | }
90 | }
91 |
92 | }
93 |
--------------------------------------------------------------------------------
/src/main/java/com/xnxy/CourseSchedulingSystem/Controller/SchoolController.java:
--------------------------------------------------------------------------------
1 | package com.xnxy.CourseSchedulingSystem.Controller;
2 |
3 | import com.xnxy.CourseSchedulingSystem.Bean.po.ClassTask;
4 | import com.xnxy.CourseSchedulingSystem.Bean.po.LocationInfo;
5 | import com.xnxy.CourseSchedulingSystem.Bean.po.TeachBuildInfo;
6 | import com.xnxy.CourseSchedulingSystem.Bean.vo.QueryVO;
7 | import com.xnxy.CourseSchedulingSystem.Bean.vo.ResultVO;
8 | import com.xnxy.CourseSchedulingSystem.Service.IClassSchedulingService;
9 | import com.xnxy.CourseSchedulingSystem.Service.IClassTaskService;
10 | import com.xnxy.CourseSchedulingSystem.Service.ILocationInfoService;
11 | import com.xnxy.CourseSchedulingSystem.Service.ITeachBuildInfoService;
12 | import com.xnxy.CourseSchedulingSystem.Service.Impl.LocationInfoService;
13 | import com.xnxy.CourseSchedulingSystem.Util.PageUtil;
14 | import org.springframework.beans.factory.annotation.Autowired;
15 | import org.springframework.web.bind.annotation.RequestBody;
16 | import org.springframework.web.bind.annotation.RequestMapping;
17 | import org.springframework.web.bind.annotation.RestController;
18 |
19 | import javax.xml.transform.Result;
20 | import java.util.List;
21 |
22 | @RestController
23 | public class SchoolController {
24 | @Autowired
25 | ITeachBuildInfoService teachBuildInfoService;
26 | @Autowired
27 | ILocationInfoService locationInfoService;
28 | @Autowired
29 | IClassTaskService classTaskService;
30 | @Autowired
31 | IClassSchedulingService classSchedulingService;
32 | @RequestMapping("/queryTeachBuildInfo")
33 | public ResultVO queryTeachBuildInfo(@RequestBody QueryVO queryVO){
34 | //PageUtil.pageHelper(queryVO);
35 | List teachBuildInfoList = teachBuildInfoService.queryTeachBuildInfo(queryVO);
36 | if(teachBuildInfoList != null && teachBuildInfoList.size() > 0 ){
37 | return ResultVO.ok("查询教学楼信息成功",teachBuildInfoList);
38 | //return ResultVO.ok("查询教学楼信息成功",teachBuildInfoList,PageUtil.pageDataHelper(teachBuildInfoList));
39 | }
40 | return ResultVO.faile("查询教学楼信息出现异常");
41 | }
42 |
43 | @RequestMapping("/queryLocationInfo")
44 | public ResultVO queryLocationInfo(@RequestBody QueryVO queryVO){
45 | //PageUtil.pageHelper(queryVO);
46 | List locationInfoList = locationInfoService.queryLocationInfo(queryVO);
47 | if(locationInfoList != null && locationInfoList.size() > 0){
48 | return ResultVO.ok("查询学院教学区域安排位置表成功",locationInfoList);
49 | // return ResultVO.ok("查询学院教学区域安排位置表成功",locationInfoList, PageUtil.pageDataHelper(locationInfoList));
50 | }
51 | return ResultVO.faile("查询学院教学区域安排位置表出现异常");
52 | }
53 |
54 | @RequestMapping("/saveLocationInfo")
55 | public ResultVO saveLocationInfo(@RequestBody LocationInfo locationInfo){
56 | if(locationInfoService.saveLocationInfo(locationInfo)){
57 | QueryVO queryVO = new QueryVO();
58 | //PageUtil.pageHelper(queryVO);
59 | List locationInfoList = locationInfoService.queryLocationInfo(queryVO);
60 | return ResultVO.ok("学院教学区域安排位置保存成功",locationInfoList);
61 | //return ResultVO.ok("学院教学区域安排位置保存成功",locationInfoList,PageUtil.pageDataHelper(locationInfoList));
62 | }
63 | return ResultVO.faile("教学区域安排位置保存失败");
64 | }
65 |
66 | @RequestMapping("/deleteLocationInfo")
67 | public ResultVO deleteLocationInfo(@RequestBody LocationInfo locationInfo){
68 | if(locationInfoService.deleteLocationInfo(locationInfo)){
69 | QueryVO queryVO = new QueryVO();
70 | //PageUtil.pageHelper(queryVO);
71 | List locationInfoList = locationInfoService.queryLocationInfo(queryVO);
72 | return ResultVO.ok("学院教学区域安排位置删除成功",locationInfoList);
73 | //return ResultVO.ok("学院教学区域安排位置删除成功",locationInfoList,PageUtil.pageDataHelper(locationInfoList));
74 | }
75 | return ResultVO.faile("学院教学区域安排位置删除失败");
76 |
77 | }
78 | @RequestMapping("/querySemester")
79 | public ResultVO querySemester(){
80 | List semesterList = classTaskService.querySemester();
81 | return ResultVO.ok("查询开课学期成功",semesterList);
82 | }
83 |
84 | @RequestMapping("/classScheduling")
85 | public ResultVO classScheduling(@RequestBody ClassTask classTask){
86 | if(classSchedulingService.classScheduling(classTask)){
87 | return ResultVO.ok("排课成功");
88 | }
89 | return ResultVO.faile("排课失败");
90 | }
91 | }
92 |
--------------------------------------------------------------------------------
/UI/my-app/src/Login.js:
--------------------------------------------------------------------------------
1 | import React, {Component} from 'react';
2 | import {Form, Input, Button, Card, Radio, Select, message} from 'antd';
3 | import axios from 'axios';
4 |
5 | import 'antd/dist/antd.css';
6 |
7 | const RadioGroup = Radio.Group;
8 | const {Option} = Select;
9 |
10 | class Login extends Component {
11 |
12 | componentDidMount() {
13 | axios.post('/queryCollegeInfo', null).then((res) => {
14 | if (res.data.code === '1') {
15 | this.college = res.data.data;
16 | }
17 | });
18 | sessionStorage.removeItem('id')
19 | };
20 |
21 | handleSubmit = () => {
22 | this.props.form.validateFields((err, values) => {
23 | if (!err) {
24 | axios.post('/userLogin', {
25 | username: values.username,
26 | password: values.password,
27 | role: values.role,
28 | }).then((res) => {
29 | if (res.data.code === '1') {
30 | if (values.role === "2") {
31 | this.props.history.push({pathname: 'app', collegeno: values.college});
32 | } else {
33 | this.props.history.push({ pathname: 'applicationTeacher' });
34 | }
35 | } else {
36 | message.info(res.data.message)
37 | }
38 | }).catch((err) => {
39 | message.info(err);
40 | });
41 | }
42 | });
43 | };
44 |
45 | handleCancel = () => {
46 | this.props.form.resetFields();
47 | };
48 |
49 | render() {
50 | const {form} = this.props;
51 |
52 | const college = this.college ? this.college.map(a => (
53 | {a.collegename}
54 | )) : null;
55 |
56 | return (
57 |
58 |
60 | {form.getFieldDecorator('username', {
61 | rules: [{
62 | required: true,
63 | message: '请填写账号!'
64 | }],
65 | })(
66 | )}
67 |
68 |
69 | {form.getFieldDecorator('password', {
70 | rules: [{
71 | required: true,
72 | message: '请填写密码!'
73 | }],
74 | })(
75 | )}
76 |
77 |
78 | {form.getFieldDecorator('role', {
79 | rules: [{
80 | required: true,
81 | message: '请选择身份类型!'
82 | }],
83 | })(
84 |
85 | 教务处
86 | 学院
87 | )}
88 |
89 |
90 | {form.getFieldDecorator('college', {
91 | rules:form.getFieldsValue().role==='2'? [{
92 | required: true,
93 | message: '请选择学院名!'
94 | }]:[],
95 | })()}
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 | );
104 | }
105 | }
106 |
107 | const LoginPage = Form.create()(Login);
108 |
109 | export default LoginPage;
110 |
--------------------------------------------------------------------------------
/UI/my-app/src/AddClassTaskModal.js:
--------------------------------------------------------------------------------
1 | import React, {PureComponent} from 'react';
2 | import {Form,Modal,Input,Switch,message} from 'antd';
3 | import axios from "axios/index";
4 |
5 | class AddClassTaskModal extends PureComponent{
6 | onOk=()=>{
7 | this.props.form.validateFields((err, values) => {
8 | let data={...values};
9 | if(values.isfix){
10 | data={...values,isfix:2}
11 | }else{
12 | data={...values,isfix:1}
13 | }
14 |
15 | axios.post('/saveClassTask', {...data}).then((res) => {
16 | if (res.data.code === '1') {message.success('添加成功!')}
17 | });
18 | })
19 | };
20 |
21 | render(){
22 | const {visible,onOk,onCancel,form}=this.props;
23 | return (
24 |
25 |
27 | {form.getFieldDecorator('semester', {
28 | rules: [{
29 | required: true,
30 | message: '请填写学期!'
31 | }],
32 | })(
33 | )}
34 |
35 |
36 | {form.getFieldDecorator('classno', {
37 | rules: [{
38 | required: true,
39 | message: '请填写班级!'
40 | }],
41 | })(
42 | )}
43 |
44 |
45 | {form.getFieldDecorator('courseno', {
46 | rules: [{
47 | required: true,
48 | message: '请填写课程!'
49 | }],
50 | })(
51 | )}
52 |
53 |
54 | {form.getFieldDecorator('courseattr', {
55 | rules: [{
56 | required: true,
57 | message: '请填写课程属性!'
58 | }],
59 | })(
60 | )}
61 |
62 |
63 | {form.getFieldDecorator('studentnumber', {
64 | rules: [{
65 | required: true,
66 | message: '请填写人数!'
67 | }],
68 | })(
69 | )}
70 |
71 |
72 | {form.getFieldDecorator('weekssum', {
73 | rules: [{
74 | required: true,
75 | message: '请填写周学时!'
76 | }],
77 | })(
78 | )}
79 |
80 |
81 | {form.getFieldDecorator('weeksnumber', {
82 | rules: [{
83 | required: true,
84 | message: '请填写周数!'
85 | }],
86 | })(
87 | )}
88 |
89 |
90 | {form.getFieldDecorator('isfix', {
91 | rules: [{
92 | required: true,
93 | message: '请选择是否固定!'
94 | }],
95 | })(
96 | )}
97 |
98 |
99 | {form.getFieldDecorator('classtime', {
100 | rules: [{
101 | required: true,
102 | message: '请填写固定时间!'
103 | }],
104 | })(
105 | )}
106 |
107 |
108 |
109 | )
110 | }
111 | }
112 |
113 | export default Form.create()(AddClassTaskModal);
--------------------------------------------------------------------------------
/.mvn/wrapper/MavenWrapperDownloader.java:
--------------------------------------------------------------------------------
1 | /*
2 | Licensed to the Apache Software Foundation (ASF) under one
3 | or more contributor license agreements. See the NOTICE file
4 | distributed with this work for additional information
5 | regarding copyright ownership. The ASF licenses this file
6 | to you under the Apache License, Version 2.0 (the
7 | "License"); you may not use this file except in compliance
8 | with the License. You may obtain a copy of the License at
9 |
10 | http://www.apache.org/licenses/LICENSE-2.0
11 |
12 | Unless required by applicable law or agreed to in writing,
13 | software distributed under the License is distributed on an
14 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 | KIND, either express or implied. See the License for the
16 | specific language governing permissions and limitations
17 | under the License.
18 | */
19 |
20 | import java.io.File;
21 | import java.io.FileInputStream;
22 | import java.io.FileOutputStream;
23 | import java.io.IOException;
24 | import java.net.URL;
25 | import java.nio.channels.Channels;
26 | import java.nio.channels.ReadableByteChannel;
27 | import java.util.Properties;
28 |
29 | public class MavenWrapperDownloader {
30 |
31 | /**
32 | * Default URL to download the maven-wrapper.jar from, if no 'downloadUrl' is provided.
33 | */
34 | private static final String DEFAULT_DOWNLOAD_URL =
35 | "https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.4.2/maven-wrapper-0.4.2.jar";
36 |
37 | /**
38 | * Path to the maven-wrapper.properties file, which might contain a downloadUrl property to
39 | * use instead of the default one.
40 | */
41 | private static final String MAVEN_WRAPPER_PROPERTIES_PATH =
42 | ".mvn/wrapper/maven-wrapper.properties";
43 |
44 | /**
45 | * Path where the maven-wrapper.jar will be saved to.
46 | */
47 | private static final String MAVEN_WRAPPER_JAR_PATH =
48 | ".mvn/wrapper/maven-wrapper.jar";
49 |
50 | /**
51 | * Name of the property which should be used to override the default download url for the wrapper.
52 | */
53 | private static final String PROPERTY_NAME_WRAPPER_URL = "wrapperUrl";
54 |
55 | public static void main(String args[]) {
56 | System.out.println("- Downloader started");
57 | File baseDirectory = new File(args[0]);
58 | System.out.println("- Using base directory: " + baseDirectory.getAbsolutePath());
59 |
60 | // If the maven-wrapper.properties exists, read it and check if it contains a custom
61 | // wrapperUrl parameter.
62 | File mavenWrapperPropertyFile = new File(baseDirectory, MAVEN_WRAPPER_PROPERTIES_PATH);
63 | String url = DEFAULT_DOWNLOAD_URL;
64 | if(mavenWrapperPropertyFile.exists()) {
65 | FileInputStream mavenWrapperPropertyFileInputStream = null;
66 | try {
67 | mavenWrapperPropertyFileInputStream = new FileInputStream(mavenWrapperPropertyFile);
68 | Properties mavenWrapperProperties = new Properties();
69 | mavenWrapperProperties.load(mavenWrapperPropertyFileInputStream);
70 | url = mavenWrapperProperties.getProperty(PROPERTY_NAME_WRAPPER_URL, url);
71 | } catch (IOException e) {
72 | System.out.println("- ERROR loading '" + MAVEN_WRAPPER_PROPERTIES_PATH + "'");
73 | } finally {
74 | try {
75 | if(mavenWrapperPropertyFileInputStream != null) {
76 | mavenWrapperPropertyFileInputStream.close();
77 | }
78 | } catch (IOException e) {
79 | // Ignore ...
80 | }
81 | }
82 | }
83 | System.out.println("- Downloading from: : " + url);
84 |
85 | File outputFile = new File(baseDirectory.getAbsolutePath(), MAVEN_WRAPPER_JAR_PATH);
86 | if(!outputFile.getParentFile().exists()) {
87 | if(!outputFile.getParentFile().mkdirs()) {
88 | System.out.println(
89 | "- ERROR creating output direcrory '" + outputFile.getParentFile().getAbsolutePath() + "'");
90 | }
91 | }
92 | System.out.println("- Downloading to: " + outputFile.getAbsolutePath());
93 | try {
94 | downloadFileFromURL(url, outputFile);
95 | System.out.println("Done");
96 | System.exit(0);
97 | } catch (Throwable e) {
98 | System.out.println("- Error downloading");
99 | e.printStackTrace();
100 | System.exit(1);
101 | }
102 | }
103 |
104 | private static void downloadFileFromURL(String urlString, File destination) throws Exception {
105 | URL website = new URL(urlString);
106 | ReadableByteChannel rbc;
107 | rbc = Channels.newChannel(website.openStream());
108 | FileOutputStream fos = new FileOutputStream(destination);
109 | fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
110 | fos.close();
111 | rbc.close();
112 | }
113 |
114 | }
115 |
--------------------------------------------------------------------------------
/target/classes/Mapper/CoursePlanMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 | delete
17 | from course_plan
18 | where id = #{id,jdbcType=BIGINT}
19 |
20 |
21 | insert into course_plan
22 |
23 |
24 | semester,
25 |
26 |
27 | collegeNo,
28 |
29 |
30 | classNo,
31 |
32 |
33 | courseNo,
34 |
35 |
36 | teacherNo,
37 |
38 |
39 | classroomNo,
40 |
41 |
42 | weeksSum,
43 |
44 |
45 |
46 | classTime
47 |
48 |
49 |
50 |
51 | #{semester,jdbcType=VARCHAR},
52 |
53 |
54 | #{collegeno,jdbcType=VARCHAR},
55 |
56 |
57 | #{classno,jdbcType=VARCHAR},
58 |
59 |
60 | #{courseno,jdbcType=VARCHAR},
61 |
62 |
63 | #{teacherno,jdbcType=VARCHAR},
64 |
65 |
66 | #{classroomno,jdbcType=VARCHAR},
67 |
68 |
69 | #{weekssum,jdbcType=INTEGER},
70 |
71 |
72 | #{classtime,jdbcType=VARCHAR}
73 |
74 |
75 |
76 |
77 | update course_plan
78 | set weeksSum = #{weekssum,jdbcType=INTEGER},
79 | semester = #{semester,jdbcType=VARCHAR}
80 | where collegeNo = #{collegeno,jdbcType=VARCHAR}
81 | and classNo = #{classno,jdbcType=VARCHAR}
82 | and courseNo = #{courseno,jdbcType=VARCHAR}
83 | and teacherNo = #{teacherno,jdbcType=VARCHAR}
84 |
85 |
86 |
87 |
125 |
--------------------------------------------------------------------------------
/src/main/resources/Mapper/CoursePlanMapper.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 | delete
17 | from course_plan
18 | where id = #{id,jdbcType=BIGINT}
19 |
20 |
21 | insert into course_plan
22 |
23 |
24 | semester,
25 |
26 |
27 | collegeNo,
28 |
29 |
30 | classNo,
31 |
32 |
33 | courseNo,
34 |
35 |
36 | teacherNo,
37 |
38 |
39 | classroomNo,
40 |
41 |
42 | weeksSum,
43 |
44 |
45 |
46 | classTime
47 |
48 |
49 |
50 |
51 | #{semester,jdbcType=VARCHAR},
52 |
53 |
54 | #{collegeno,jdbcType=VARCHAR},
55 |
56 |
57 | #{classno,jdbcType=VARCHAR},
58 |
59 |
60 | #{courseno,jdbcType=VARCHAR},
61 |
62 |
63 | #{teacherno,jdbcType=VARCHAR},
64 |
65 |
66 | #{classroomno,jdbcType=VARCHAR},
67 |
68 |
69 | #{weekssum,jdbcType=INTEGER},
70 |
71 |
72 | #{classtime,jdbcType=VARCHAR}
73 |
74 |
75 |
76 |
77 | update course_plan
78 | set weeksSum = #{weekssum,jdbcType=INTEGER},
79 | semester = #{semester,jdbcType=VARCHAR}
80 | where collegeNo = #{collegeno,jdbcType=VARCHAR}
81 | and classNo = #{classno,jdbcType=VARCHAR}
82 | and courseNo = #{courseno,jdbcType=VARCHAR}
83 | and teacherNo = #{teacherno,jdbcType=VARCHAR}
84 |
85 |
86 |
87 |
125 |
--------------------------------------------------------------------------------
/UI/my-app/src/serviceWorker.js:
--------------------------------------------------------------------------------
1 | // This optional code is used to register a service worker.
2 | // register() is not called by default.
3 |
4 | // This lets the app load faster on subsequent visits in production, and gives
5 | // it offline capabilities. However, it also means that developers (and users)
6 | // will only see deployed updates on subsequent visits to a page, after all the
7 | // existing tabs open on the page have been closed, since previously cached
8 | // resources are updated in the background.
9 |
10 | // To learn more about the benefits of this model and instructions on how to
11 | // opt-in, read https://bit.ly/CRA-PWA
12 |
13 | const isLocalhost = Boolean(
14 | window.location.hostname === 'localhost' ||
15 | // [::1] is the IPv6 localhost address.
16 | window.location.hostname === '[::1]' ||
17 | // 127.0.0.1/8 is considered localhost for IPv4.
18 | window.location.hostname.match(
19 | /^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/
20 | )
21 | );
22 |
23 | export function register(config) {
24 | if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {
25 | // The URL constructor is available in all browsers that support SW.
26 | const publicUrl = new URL(process.env.PUBLIC_URL, window.location.href);
27 | if (publicUrl.origin !== window.location.origin) {
28 | // Our service worker won't work if PUBLIC_URL is on a different origin
29 | // from what our page is served on. This might happen if a CDN is used to
30 | // serve assets; see https://github.com/facebook/create-react-app/issues/2374
31 | return;
32 | }
33 |
34 | window.addEventListener('load', () => {
35 | const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;
36 |
37 | if (isLocalhost) {
38 | // This is running on localhost. Let's check if a service worker still exists or not.
39 | checkValidServiceWorker(swUrl, config);
40 |
41 | // Add some additional logging to localhost, pointing developers to the
42 | // service worker/PWA documentation.
43 | navigator.serviceWorker.ready.then(() => {
44 | console.log(
45 | 'This web app is being served cache-first by a service ' +
46 | 'worker. To learn more, visit https://bit.ly/CRA-PWA'
47 | );
48 | });
49 | } else {
50 | // Is not localhost. Just register service worker
51 | registerValidSW(swUrl, config);
52 | }
53 | });
54 | }
55 | }
56 |
57 | function registerValidSW(swUrl, config) {
58 | navigator.serviceWorker
59 | .register(swUrl)
60 | .then(registration => {
61 | registration.onupdatefound = () => {
62 | const installingWorker = registration.installing;
63 | if (installingWorker == null) {
64 | return;
65 | }
66 | installingWorker.onstatechange = () => {
67 | if (installingWorker.state === 'installed') {
68 | if (navigator.serviceWorker.controller) {
69 | // At this point, the updated precached content has been fetched,
70 | // but the previous service worker will still serve the older
71 | // content until all client tabs are closed.
72 | console.log(
73 | 'New content is available and will be used when all ' +
74 | 'tabs for this page are closed. See https://bit.ly/CRA-PWA.'
75 | );
76 |
77 | // Execute callback
78 | if (config && config.onUpdate) {
79 | config.onUpdate(registration);
80 | }
81 | } else {
82 | // At this point, everything has been precached.
83 | // It's the perfect time to display a
84 | // "Content is cached for offline use." message.
85 | console.log('Content is cached for offline use.');
86 |
87 | // Execute callback
88 | if (config && config.onSuccess) {
89 | config.onSuccess(registration);
90 | }
91 | }
92 | }
93 | };
94 | };
95 | })
96 | .catch(error => {
97 | console.error('Error during service worker registration:', error);
98 | });
99 | }
100 |
101 | function checkValidServiceWorker(swUrl, config) {
102 | // Check if the service worker can be found. If it can't reload the page.
103 | fetch(swUrl)
104 | .then(response => {
105 | // Ensure service worker exists, and that we really are getting a JS file.
106 | const contentType = response.headers.get('content-type');
107 | if (
108 | response.status === 404 ||
109 | (contentType != null && contentType.indexOf('javascript') === -1)
110 | ) {
111 | // No service worker found. Probably a different app. Reload the page.
112 | navigator.serviceWorker.ready.then(registration => {
113 | registration.unregister().then(() => {
114 | window.location.reload();
115 | });
116 | });
117 | } else {
118 | // Service worker found. Proceed as normal.
119 | registerValidSW(swUrl, config);
120 | }
121 | })
122 | .catch(() => {
123 | console.log(
124 | 'No internet connection found. App is running in offline mode.'
125 | );
126 | });
127 | }
128 |
129 | export function unregister() {
130 | if ('serviceWorker' in navigator) {
131 | navigator.serviceWorker.ready.then(registration => {
132 | registration.unregister();
133 | });
134 | }
135 | }
136 |
--------------------------------------------------------------------------------