Преглед на файлове

feat:完成基础部分功能

sakura преди 1 година
родител
ревизия
8f21379ded
променени са 77 файла, в които са добавени 6314 реда и са изтрити 293 реда
  1. 1 1
      school-in-out-admin/src/main/java/com/schoolinout/SchoolInOutApplication.java
  2. 93 0
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/AccessLogController.java
  3. 126 0
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/ClazzController.java
  4. 101 0
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/SchoolController.java
  5. 93 0
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/StudentController.java
  6. 1 1
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/SysConfigController.java
  7. 59 34
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/SysDictDataController.java
  8. 38 0
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/TeacherClassRelationController.java
  9. 100 0
      school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/TeacherController.java
  10. 46 43
      school-in-out-common/src/main/java/com/schoolinout/common/core/domain/BaseEntity.java
  11. 19 29
      school-in-out-framework/src/main/java/com/schoolinout/framework/web/exception/GlobalExceptionHandler.java
  12. 10 2
      school-in-out-system/pom.xml
  13. 115 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/AccessLog.java
  14. 138 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/Clazz.java
  15. 126 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/School.java
  16. 158 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/Student.java
  17. 125 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/Teacher.java
  18. 112 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/TeacherClassRelation.java
  19. 98 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/dto/AddClassDto.java
  20. 56 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/dto/AddTeacherClassRelationDto.java
  21. 48 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/dto/InsertTeacherClassRelationDto.java
  22. 22 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/ClazzInfoVo.java
  23. 40 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/ClazzOptionVo.java
  24. 40 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/OptionVo.java
  25. 149 0
      school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/TeacherClassInfoVo.java
  26. 64 0
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/AccessLogMapper.java
  27. 67 0
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/ClazzMapper.java
  28. 64 0
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/SchoolMapper.java
  29. 64 0
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/StudentMapper.java
  30. 25 16
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/SysDictDataMapper.java
  31. 74 0
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/TeacherClassRelationMapper.java
  32. 67 0
      school-in-out-system/src/main/java/com/schoolinout/system/mapper/TeacherMapper.java
  33. 61 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/IAccessLogService.java
  34. 67 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/IClazzService.java
  35. 61 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/ISchoolService.java
  36. 61 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/IStudentService.java
  37. 21 11
      school-in-out-system/src/main/java/com/schoolinout/system/service/ISysDictDataService.java
  38. 80 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/ITeacherClassRelationService.java
  39. 70 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/ITeacherService.java
  40. 96 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/AccessLogServiceImpl.java
  41. 142 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/ClazzServiceImpl.java
  42. 96 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/SchoolServiceImpl.java
  43. 90 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/StudentServiceImpl.java
  44. 27 31
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/SysDictDataServiceImpl.java
  45. 114 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/TeacherClassRelationServiceImpl.java
  46. 96 0
      school-in-out-system/src/main/java/com/schoolinout/system/service/impl/TeacherServiceImpl.java
  47. 86 0
      school-in-out-system/src/main/resources/mapper/system/AccessLogMapper.xml
  48. 124 0
      school-in-out-system/src/main/resources/mapper/system/ClazzMapper.xml
  49. 104 0
      school-in-out-system/src/main/resources/mapper/system/SchoolMapper.xml
  50. 100 0
      school-in-out-system/src/main/resources/mapper/system/StudentMapper.xml
  51. 144 118
      school-in-out-system/src/main/resources/mapper/system/SysDictDataMapper.xml
  52. 138 0
      school-in-out-system/src/main/resources/mapper/system/TeacherClassRelationMapper.xml
  53. 111 0
      school-in-out-system/src/main/resources/mapper/system/TeacherMapper.xml
  54. 1 0
      school-in-out-ui/src/App.vue
  55. 44 0
      school-in-out-ui/src/api/system/access_log.js
  56. 53 0
      school-in-out-ui/src/api/system/clazz.js
  57. 8 0
      school-in-out-ui/src/api/system/dict/data.js
  58. 44 0
      school-in-out-ui/src/api/system/school.js
  59. 44 0
      school-in-out-ui/src/api/system/student.js
  60. 52 0
      school-in-out-ui/src/api/system/teacher.js
  61. 0 0
      school-in-out-ui/src/assets/icons/svg/clazz.svg
  62. 0 0
      school-in-out-ui/src/assets/icons/svg/ic_student.svg
  63. 1 0
      school-in-out-ui/src/assets/icons/svg/ic_teacher.svg
  64. 1 0
      school-in-out-ui/src/assets/icons/svg/parent-fill.svg
  65. 1 0
      school-in-out-ui/src/assets/icons/svg/school.svg
  66. BIN
      school-in-out-ui/src/assets/images/bind.png
  67. 16 0
      school-in-out-ui/src/assets/styles/ruoyi.scss
  68. 7 4
      school-in-out-ui/src/components/DictTag/index.vue
  69. 24 0
      school-in-out-ui/src/mixin/Textyixia.js
  70. 7 3
      school-in-out-ui/src/utils/auth.js
  71. 291 0
      school-in-out-ui/src/views/system/access_log/index.vue
  72. 266 0
      school-in-out-ui/src/views/system/clazz/index.vue
  73. 153 0
      school-in-out-ui/src/views/system/clazz/module/ClazzForm.vue
  74. 312 0
      school-in-out-ui/src/views/system/school/index.vue
  75. 322 0
      school-in-out-ui/src/views/system/student/index.vue
  76. 328 0
      school-in-out-ui/src/views/system/teacher/index.vue
  77. 111 0
      sql/school_in_out_db.sql

+ 1 - 1
school-in-out-admin/src/main/java/com/schoolinout/SchoolInOutApplication.java

@@ -24,7 +24,7 @@ public class SchoolInOutApplication {
         String path = env.getProperty("server.servlet.context-path");
         log.info("\n----------------------------------------------------------\n\t" +
                 "Application School-in-out is running! Access URLs:\n\t" +
-                "Swagger文档: \thttp://localhost:{}{}/doc.html\n" +
+                "Swagger文档: \thttp://localhost:{}{}doc.html\n" +
                 "----------------------------------------------------------", port, path);
     }
 }

+ 93 - 0
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/AccessLogController.java

@@ -0,0 +1,93 @@
+package com.schoolinout.web.controller.system;
+
+import com.schoolinout.common.annotation.Log;
+import com.schoolinout.common.core.controller.BaseController;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.common.core.page.TableDataInfo;
+import com.schoolinout.common.enums.BusinessType;
+import com.schoolinout.common.utils.poi.ExcelUtil;
+import com.schoolinout.system.domain.AccessLog;
+import com.schoolinout.system.service.IAccessLogService;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 进出学校记录Controller
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Tag(name = "学生进出记录接口")
+@RestController
+@RequestMapping("/system/access_log")
+public class AccessLogController extends BaseController {
+    @Autowired
+    private IAccessLogService accessLogService;
+
+    /**
+     * 查询进出学校记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:access_log:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(AccessLog accessLog) {
+        startPage();
+        List<AccessLog> list = accessLogService.selectAccessLogList(accessLog);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出进出学校记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:access_log:export')")
+    @Log(title = "进出学校记录", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, AccessLog accessLog) {
+        List<AccessLog> list = accessLogService.selectAccessLogList(accessLog);
+        ExcelUtil<AccessLog> util = new ExcelUtil<AccessLog>(AccessLog.class);
+        util.exportExcel(response, list, "进出学校记录数据");
+    }
+
+    /**
+     * 获取进出学校记录详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:access_log:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id) {
+        return success(accessLogService.selectAccessLogById(id));
+    }
+
+    /**
+     * 新增进出学校记录
+     */
+    @PreAuthorize("@ss.hasPermi('system:access_log:add')")
+    @Log(title = "进出学校记录", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody AccessLog accessLog) {
+        return toAjax(accessLogService.insertAccessLog(accessLog));
+    }
+
+    /**
+     * 修改进出学校记录
+     */
+    @PreAuthorize("@ss.hasPermi('system:access_log:edit')")
+    @Log(title = "进出学校记录", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody AccessLog accessLog) {
+        return toAjax(accessLogService.updateAccessLog(accessLog));
+    }
+
+    /**
+     * 删除进出学校记录
+     */
+    @PreAuthorize("@ss.hasPermi('system:access_log:remove')")
+    @Log(title = "进出学校记录", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids) {
+        return toAjax(accessLogService.deleteAccessLogByIds(ids));
+    }
+}

+ 126 - 0
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/ClazzController.java

@@ -0,0 +1,126 @@
+package com.schoolinout.web.controller.system;
+
+import com.schoolinout.common.annotation.Log;
+import com.schoolinout.common.core.controller.BaseController;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.common.core.page.TableDataInfo;
+import com.schoolinout.common.enums.BusinessType;
+import com.schoolinout.common.utils.bean.BeanUtils;
+import com.schoolinout.common.utils.poi.ExcelUtil;
+import com.schoolinout.system.domain.Clazz;
+import com.schoolinout.system.domain.TeacherClassRelation;
+import com.schoolinout.system.domain.dto.AddClassDto;
+import com.schoolinout.system.domain.vo.ClazzInfoVo;
+import com.schoolinout.system.service.IClazzService;
+import com.schoolinout.system.service.ITeacherClassRelationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+import java.util.stream.Collectors;
+
+/**
+ * 班级管理Controller
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@RestController
+@RequestMapping("/system/clazz")
+public class ClazzController extends BaseController {
+    @Autowired
+    private IClazzService clazzService;
+
+    @Autowired
+    private ITeacherClassRelationService relationService;
+
+    @GetMapping("/option/{schoolId}")
+    public AjaxResult searchOption(@PathVariable Long schoolId) {
+        return success(clazzService.selectClazzOptionList(schoolId));
+    }
+
+    /**
+     * 查询班级管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:clazz:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(Clazz clazz) {
+        startPage();
+        List<Clazz> list = clazzService.selectClazzList(clazz);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出班级管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:clazz:export')")
+    @Log(title = "班级管理", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, Clazz clazz) {
+        List<Clazz> list = clazzService.selectClazzList(clazz);
+        ExcelUtil<Clazz> util = new ExcelUtil<Clazz>(Clazz.class);
+        util.exportExcel(response, list, "班级管理数据");
+    }
+
+    /**
+     * 获取班级管理详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:clazz:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id) {
+        Clazz clazz = clazzService.selectClazzById(id);
+
+        ClazzInfoVo infoVo = new ClazzInfoVo();
+        BeanUtils.copyBeanProp(infoVo, clazz);
+
+        TeacherClassRelation relation = new TeacherClassRelation();
+        relation.setClassId(clazz.getId());
+        relation.setSchoolId(clazz.getSchoolId());
+        List<Long> teacherIds = relationService.selectTeacherClassRelationList(relation).stream()
+                .map(TeacherClassRelation::getTeacherId)
+                .collect(Collectors.toList());
+        infoVo.setTeacherIds(teacherIds);
+
+        return success(infoVo);
+    }
+
+//    /**
+//     * 新增班级管理
+//     */
+//    @PreAuthorize("@ss.hasPermi('system:clazz:add')")
+//    @Log(title = "班级管理", businessType = BusinessType.INSERT)
+//    @PostMapping
+//    public AjaxResult add(@RequestBody Clazz clazz) {
+//        return toAjax(clazzService.insertClazz(clazz));
+//    }
+
+    @PreAuthorize("@ss.hasPermi('system:clazz:add')")
+    @Log(title = "班级管理", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult addClass(@Validated @RequestBody AddClassDto form) {
+        return toAjax(clazzService.saveClassAndRelation(form));
+    }
+
+    /**
+     * 修改班级管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:clazz:edit')")
+    @Log(title = "班级管理", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody Clazz clazz) {
+        return toAjax(clazzService.updateClazz(clazz));
+    }
+
+    /**
+     * 删除班级管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:clazz:remove')")
+    @Log(title = "班级管理", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids) {
+        return toAjax(clazzService.deleteClazzByIds(ids));
+    }
+}

+ 101 - 0
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/SchoolController.java

@@ -0,0 +1,101 @@
+package com.schoolinout.web.controller.system;
+
+import com.schoolinout.common.annotation.Log;
+import com.schoolinout.common.core.controller.BaseController;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.common.core.page.TableDataInfo;
+import com.schoolinout.common.enums.BusinessType;
+import com.schoolinout.common.utils.poi.ExcelUtil;
+import com.schoolinout.system.domain.School;
+import com.schoolinout.system.service.ISchoolService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 学校管理Controller
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Tag(name = "学校管理", description = "学校管理的CRUD接口")
+@RestController
+@RequestMapping("/system/school")
+public class SchoolController extends BaseController {
+
+    @Autowired
+    private ISchoolService schoolService;
+
+    /**
+     * 查询学校管理列表
+     */
+    @Operation(summary = "查询学校管理列表")
+    @PreAuthorize("@ss.hasPermi('system:school:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(School school) {
+        startPage();
+        List<School> list = schoolService.selectSchoolList(school);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出学校管理列表
+     */
+    @Operation(summary = "导出学校管理列表")
+    @PreAuthorize("@ss.hasPermi('system:school:export')")
+    @Log(title = "学校管理", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, School school) {
+        List<School> list = schoolService.selectSchoolList(school);
+        ExcelUtil<School> util = new ExcelUtil<School>(School.class);
+        util.exportExcel(response, list, "学校管理数据");
+    }
+
+    /**
+     * 获取学校管理详细信息
+     */
+    @Operation(summary = "获取学校管理详细信息")
+    @PreAuthorize("@ss.hasPermi('system:school:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id) {
+        return success(schoolService.selectSchoolById(id));
+    }
+
+    /**
+     * 新增学校管理
+     */
+    @Operation(summary = "新增学校信息")
+    @PreAuthorize("@ss.hasPermi('system:school:add')")
+    @Log(title = "学校管理", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody School school) {
+        return toAjax(schoolService.insertSchool(school));
+    }
+
+    /**
+     * 修改学校管理
+     */
+    @Operation(summary = "修改学校信息")
+    @PreAuthorize("@ss.hasPermi('system:school:edit')")
+    @Log(title = "学校管理", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody School school) {
+        return toAjax(schoolService.updateSchool(school));
+    }
+
+    /**
+     * 删除学校管理
+     */
+    @Operation(summary = "删除学校信息")
+    @PreAuthorize("@ss.hasPermi('system:school:remove')")
+    @Log(title = "学校管理", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids) {
+        return toAjax(schoolService.deleteSchoolByIds(ids));
+    }
+}

+ 93 - 0
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/StudentController.java

@@ -0,0 +1,93 @@
+package com.schoolinout.web.controller.system;
+
+import com.schoolinout.common.annotation.Log;
+import com.schoolinout.common.core.controller.BaseController;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.common.core.page.TableDataInfo;
+import com.schoolinout.common.enums.BusinessType;
+import com.schoolinout.common.utils.poi.ExcelUtil;
+import com.schoolinout.system.domain.Student;
+import com.schoolinout.system.service.IStudentService;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 学生管理Controller
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Tag(name = "学生管理接口")
+@RestController
+@RequestMapping("/system/student")
+public class StudentController extends BaseController {
+    @Autowired
+    private IStudentService studentService;
+
+    /**
+     * 查询学生管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:student:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(Student student) {
+        startPage();
+        List<Student> list = studentService.selectStudentList(student);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出学生管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:student:export')")
+    @Log(title = "学生管理", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, Student student) {
+        List<Student> list = studentService.selectStudentList(student);
+        ExcelUtil<Student> util = new ExcelUtil<Student>(Student.class);
+        util.exportExcel(response, list, "学生管理数据");
+    }
+
+    /**
+     * 获取学生管理详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:student:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id) {
+        return success(studentService.selectStudentById(id));
+    }
+
+    /**
+     * 新增学生管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:student:add')")
+    @Log(title = "学生管理", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody Student student) {
+        return toAjax(studentService.insertStudent(student));
+    }
+
+    /**
+     * 修改学生管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:student:edit')")
+    @Log(title = "学生管理", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody Student student) {
+        return toAjax(studentService.updateStudent(student));
+    }
+
+    /**
+     * 删除学生管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:student:remove')")
+    @Log(title = "学生管理", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids) {
+        return toAjax(studentService.deleteStudentByIds(ids));
+    }
+}

+ 1 - 1
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/SysConfigController.java

@@ -43,7 +43,7 @@ public class SysConfigController extends BaseController {
     @PostMapping("/export")
     public void export(HttpServletResponse response, SysConfig config) {
         List<SysConfig> list = configService.selectConfigList(config);
-        ExcelUtil<SysConfig> util = new ExcelUtil<SysConfig>(SysConfig.class);
+        ExcelUtil<SysConfig> util = new ExcelUtil<>(SysConfig.class);
         util.exportExcel(response, list, "参数数据");
     }
 

+ 59 - 34
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/SysDictDataController.java

@@ -1,49 +1,51 @@
 package com.schoolinout.web.controller.system;
 
-import java.util.ArrayList;
-import java.util.List;
-import javax.servlet.http.HttpServletResponse;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.security.access.prepost.PreAuthorize;
-import org.springframework.validation.annotation.Validated;
-import org.springframework.web.bind.annotation.DeleteMapping;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.PutMapping;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
 import com.schoolinout.common.annotation.Log;
 import com.schoolinout.common.core.controller.BaseController;
 import com.schoolinout.common.core.domain.AjaxResult;
 import com.schoolinout.common.core.domain.entity.SysDictData;
 import com.schoolinout.common.core.page.TableDataInfo;
 import com.schoolinout.common.enums.BusinessType;
+import com.schoolinout.common.exception.ServiceException;
 import com.schoolinout.common.utils.StringUtils;
 import com.schoolinout.common.utils.poi.ExcelUtil;
 import com.schoolinout.system.service.ISysDictDataService;
 import com.schoolinout.system.service.ISysDictTypeService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.enums.ParameterIn;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.ArrayList;
+import java.util.List;
 
 /**
  * 数据字典信息
- * 
+ *
  * @author ruoyi
  */
 @RestController
 @RequestMapping("/system/dict/data")
-public class SysDictDataController extends BaseController
-{
+public class SysDictDataController extends BaseController {
+
+    private static final Logger log = LoggerFactory.getLogger(SysDictDataController.class);
+
     @Autowired
     private ISysDictDataService dictDataService;
 
     @Autowired
     private ISysDictTypeService dictTypeService;
 
+
     @PreAuthorize("@ss.hasPermi('system:dict:list')")
     @GetMapping("/list")
-    public TableDataInfo list(SysDictData dictData)
-    {
+    public TableDataInfo list(SysDictData dictData) {
         startPage();
         List<SysDictData> list = dictDataService.selectDictDataList(dictData);
         return getDataTable(list);
@@ -52,8 +54,7 @@ public class SysDictDataController extends BaseController
     @Log(title = "字典数据", businessType = BusinessType.EXPORT)
     @PreAuthorize("@ss.hasPermi('system:dict:export')")
     @PostMapping("/export")
-    public void export(HttpServletResponse response, SysDictData dictData)
-    {
+    public void export(HttpServletResponse response, SysDictData dictData) {
         List<SysDictData> list = dictDataService.selectDictDataList(dictData);
         ExcelUtil<SysDictData> util = new ExcelUtil<SysDictData>(SysDictData.class);
         util.exportExcel(response, list, "字典数据");
@@ -64,21 +65,48 @@ public class SysDictDataController extends BaseController
      */
     @PreAuthorize("@ss.hasPermi('system:dict:query')")
     @GetMapping(value = "/{dictCode}")
-    public AjaxResult getInfo(@PathVariable Long dictCode)
-    {
+    public AjaxResult getInfo(@PathVariable Long dictCode) {
         return success(dictDataService.selectDictDataById(dictCode));
     }
 
     /**
+     * 根据获取对应的数据
+     */
+    @Operation(summary = "根据表结构获取数据")
+    @Parameter(name = "code", in = ParameterIn.PATH, description = "获取的数据写法: tb_school,school_name,id   第一个是表名,第二个是label,第三个是value")
+    @GetMapping("/table/{code}")
+    public AjaxResult getTableInfo(@PathVariable String code) {
+        // 拆分数据
+        String[] codes = code.split(",");
+        if (codes.length != 3) {
+            throw new ServiceException("传递的字典参数格式不对", 400);
+        }
+
+        // 0 位是 表名; 1 是 显示的label; 2是要获取的值
+        String tableName = codes[0];
+        String labelField = codes[1];
+        String valueField = codes[2];
+        
+        // 添加日志
+        log.info("以表作为字典获取数据 table: {}, label: {}, value: {}", tableName, labelField, valueField);
+
+
+        List<SysDictData> tableDictDataList = dictDataService.queryTableDict(tableName, labelField, valueField);
+        if (StringUtils.isNull(tableDictDataList)) {
+            tableDictDataList = new ArrayList<>();
+        }
+        return success(tableDictDataList);
+    }
+
+
+    /**
      * 根据字典类型查询字典数据信息
      */
     @GetMapping(value = "/type/{dictType}")
-    public AjaxResult dictType(@PathVariable String dictType)
-    {
+    public AjaxResult dictType(@PathVariable String dictType) {
         List<SysDictData> data = dictTypeService.selectDictDataByType(dictType);
-        if (StringUtils.isNull(data))
-        {
-            data = new ArrayList<SysDictData>();
+        if (StringUtils.isNull(data)) {
+            data = new ArrayList<>();
         }
         return success(data);
     }
@@ -89,8 +117,7 @@ public class SysDictDataController extends BaseController
     @PreAuthorize("@ss.hasPermi('system:dict:add')")
     @Log(title = "字典数据", businessType = BusinessType.INSERT)
     @PostMapping
-    public AjaxResult add(@Validated @RequestBody SysDictData dict)
-    {
+    public AjaxResult add(@Validated @RequestBody SysDictData dict) {
         dict.setCreateBy(getUsername());
         return toAjax(dictDataService.insertDictData(dict));
     }
@@ -101,8 +128,7 @@ public class SysDictDataController extends BaseController
     @PreAuthorize("@ss.hasPermi('system:dict:edit')")
     @Log(title = "字典数据", businessType = BusinessType.UPDATE)
     @PutMapping
-    public AjaxResult edit(@Validated @RequestBody SysDictData dict)
-    {
+    public AjaxResult edit(@Validated @RequestBody SysDictData dict) {
         dict.setUpdateBy(getUsername());
         return toAjax(dictDataService.updateDictData(dict));
     }
@@ -113,8 +139,7 @@ public class SysDictDataController extends BaseController
     @PreAuthorize("@ss.hasPermi('system:dict:remove')")
     @Log(title = "字典类型", businessType = BusinessType.DELETE)
     @DeleteMapping("/{dictCodes}")
-    public AjaxResult remove(@PathVariable Long[] dictCodes)
-    {
+    public AjaxResult remove(@PathVariable Long[] dictCodes) {
         dictDataService.deleteDictDataByIds(dictCodes);
         return success();
     }

+ 38 - 0
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/TeacherClassRelationController.java

@@ -0,0 +1,38 @@
+package com.schoolinout.web.controller.system;
+
+import com.schoolinout.common.core.controller.BaseController;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.system.domain.dto.AddTeacherClassRelationDto;
+import com.schoolinout.system.service.ITeacherClassRelationService;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 09:9:53 Thu
+ */
+@Tag(name = "教师和班级关系表")
+@RestController
+@RequestMapping("/system/relation")
+public class TeacherClassRelationController extends BaseController {
+
+    private final ITeacherClassRelationService teacherClassRelationService;
+
+    public TeacherClassRelationController(ITeacherClassRelationService teacherClassRelationService) {
+        this.teacherClassRelationService = teacherClassRelationService;
+    }
+
+    @GetMapping("/teacher/info/{schoolId}/{teacherId}")
+    public AjaxResult getTeacherClassInfo(@PathVariable Long schoolId, @PathVariable Long teacherId) {
+        return success(teacherClassRelationService.queryTeacherBindClassList(schoolId, teacherId));
+    }
+
+    /**
+     * 以老师为主,绑定多个班级的关系
+     */
+    @PostMapping("/bind/teacher")
+    public AjaxResult bindTeacherClass(@Validated @RequestBody AddTeacherClassRelationDto form) {
+        return toAjax(teacherClassRelationService.bindTeacherClass(form));
+    }
+}

+ 100 - 0
school-in-out-admin/src/main/java/com/schoolinout/web/controller/system/TeacherController.java

@@ -0,0 +1,100 @@
+package com.schoolinout.web.controller.system;
+
+import com.schoolinout.common.annotation.Log;
+import com.schoolinout.common.core.controller.BaseController;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.common.core.page.TableDataInfo;
+import com.schoolinout.common.enums.BusinessType;
+import com.schoolinout.common.utils.poi.ExcelUtil;
+import com.schoolinout.system.domain.Teacher;
+import com.schoolinout.system.service.ITeacherService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 教师管理Controller
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Tag(name = "教师管理接口")
+@RestController
+@RequestMapping("/system/teacher")
+public class TeacherController extends BaseController {
+    @Autowired
+    private ITeacherService teacherService;
+
+    @GetMapping("/option/{schoolId}")
+    public AjaxResult searchOption(@PathVariable Long schoolId) {
+        return success(teacherService.selectTeacherOptionList(schoolId));
+    }
+
+    /**
+     * 查询教师管理列表
+     */
+    @Operation(summary = "查询教师管理列表")
+    @PreAuthorize("@ss.hasPermi('system:teacher:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(Teacher teacher) {
+        startPage();
+        List<Teacher> list = teacherService.selectTeacherList(teacher);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出教师管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:teacher:export')")
+    @Log(title = "教师管理", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, Teacher teacher) {
+        List<Teacher> list = teacherService.selectTeacherList(teacher);
+        ExcelUtil<Teacher> util = new ExcelUtil<Teacher>(Teacher.class);
+        util.exportExcel(response, list, "教师管理数据");
+    }
+
+    /**
+     * 获取教师管理详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:teacher:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id) {
+        return success(teacherService.selectTeacherById(id));
+    }
+
+    /**
+     * 新增教师管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:teacher:add')")
+    @Log(title = "教师管理", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody Teacher teacher) {
+        return toAjax(teacherService.insertTeacher(teacher));
+    }
+
+    /**
+     * 修改教师管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:teacher:edit')")
+    @Log(title = "教师管理", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody Teacher teacher) {
+        return toAjax(teacherService.updateTeacher(teacher));
+    }
+
+    /**
+     * 删除教师管理
+     */
+    @PreAuthorize("@ss.hasPermi('system:teacher:remove')")
+    @Log(title = "教师管理", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids) {
+        return toAjax(teacherService.deleteTeacherByIds(ids));
+    }
+}

+ 46 - 43
school-in-out-common/src/main/java/com/schoolinout/common/core/domain/BaseEntity.java

@@ -1,118 +1,121 @@
 package com.schoolinout.common.core.domain;
 
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonInclude;
+
 import java.io.Serializable;
 import java.util.Date;
 import java.util.HashMap;
 import java.util.Map;
-import com.fasterxml.jackson.annotation.JsonFormat;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonInclude;
 
 /**
  * Entity基类
- * 
+ *
  * @author ruoyi
  */
-public class BaseEntity implements Serializable
-{
+public class BaseEntity implements Serializable {
     private static final long serialVersionUID = 1L;
 
-    /** 搜索值 */
+    /**
+     * 搜索值
+     */
     @JsonIgnore
+    @TableField(exist = false)
     private String searchValue;
 
-    /** 创建者 */
+    /**
+     * 创建者
+     */
     private String createBy;
 
-    /** 创建时间 */
+    /**
+     * 创建时间
+     */
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
     private Date createTime;
 
-    /** 更新者 */
+    /**
+     * 更新者
+     */
     private String updateBy;
 
-    /** 更新时间 */
+    /**
+     * 更新时间
+     */
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
     private Date updateTime;
 
-    /** 备注 */
+    /**
+     * 备注
+     */
+    @TableField(exist = false)
     private String remark;
 
-    /** 请求参数 */
+    /**
+     * 请求参数
+     */
     @JsonInclude(JsonInclude.Include.NON_EMPTY)
+    @TableField(exist = false)
     private Map<String, Object> params;
 
-    public String getSearchValue()
-    {
+    public String getSearchValue() {
         return searchValue;
     }
 
-    public void setSearchValue(String searchValue)
-    {
+    public void setSearchValue(String searchValue) {
         this.searchValue = searchValue;
     }
 
-    public String getCreateBy()
-    {
+    public String getCreateBy() {
         return createBy;
     }
 
-    public void setCreateBy(String createBy)
-    {
+    public void setCreateBy(String createBy) {
         this.createBy = createBy;
     }
 
-    public Date getCreateTime()
-    {
+    public Date getCreateTime() {
         return createTime;
     }
 
-    public void setCreateTime(Date createTime)
-    {
+    public void setCreateTime(Date createTime) {
         this.createTime = createTime;
     }
 
-    public String getUpdateBy()
-    {
+    public String getUpdateBy() {
         return updateBy;
     }
 
-    public void setUpdateBy(String updateBy)
-    {
+    public void setUpdateBy(String updateBy) {
         this.updateBy = updateBy;
     }
 
-    public Date getUpdateTime()
-    {
+    public Date getUpdateTime() {
         return updateTime;
     }
 
-    public void setUpdateTime(Date updateTime)
-    {
+    public void setUpdateTime(Date updateTime) {
         this.updateTime = updateTime;
     }
 
-    public String getRemark()
-    {
+    public String getRemark() {
         return remark;
     }
 
-    public void setRemark(String remark)
-    {
+    public void setRemark(String remark) {
         this.remark = remark;
     }
 
-    public Map<String, Object> getParams()
-    {
-        if (params == null)
-        {
+    public Map<String, Object> getParams() {
+        if (params == null) {
             params = new HashMap<>();
         }
         return params;
     }
 
-    public void setParams(Map<String, Object> params)
-    {
+    public void setParams(Map<String, Object> params) {
         this.params = params;
     }
 }

+ 19 - 29
school-in-out-framework/src/main/java/com/schoolinout/framework/web/exception/GlobalExceptionHandler.java

@@ -1,6 +1,10 @@
 package com.schoolinout.framework.web.exception;
 
-import javax.servlet.http.HttpServletRequest;
+import com.schoolinout.common.constant.HttpStatus;
+import com.schoolinout.common.core.domain.AjaxResult;
+import com.schoolinout.common.exception.DemoModeException;
+import com.schoolinout.common.exception.ServiceException;
+import com.schoolinout.common.utils.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.security.access.AccessDeniedException;
@@ -11,28 +15,23 @@ import org.springframework.web.bind.MissingPathVariableException;
 import org.springframework.web.bind.annotation.ExceptionHandler;
 import org.springframework.web.bind.annotation.RestControllerAdvice;
 import org.springframework.web.method.annotation.MethodArgumentTypeMismatchException;
-import com.schoolinout.common.constant.HttpStatus;
-import com.schoolinout.common.core.domain.AjaxResult;
-import com.schoolinout.common.exception.DemoModeException;
-import com.schoolinout.common.exception.ServiceException;
-import com.schoolinout.common.utils.StringUtils;
+
+import javax.servlet.http.HttpServletRequest;
 
 /**
  * 全局异常处理器
- * 
+ *
  * @author ruoyi
  */
 @RestControllerAdvice
-public class GlobalExceptionHandler
-{
+public class GlobalExceptionHandler {
     private static final Logger log = LoggerFactory.getLogger(GlobalExceptionHandler.class);
 
     /**
      * 权限校验异常
      */
     @ExceptionHandler(AccessDeniedException.class)
-    public AjaxResult handleAccessDeniedException(AccessDeniedException e, HttpServletRequest request)
-    {
+    public AjaxResult handleAccessDeniedException(AccessDeniedException e, HttpServletRequest request) {
         String requestURI = request.getRequestURI();
         log.error("请求地址'{}',权限校验失败'{}'", requestURI, e.getMessage());
         return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
@@ -43,8 +42,7 @@ public class GlobalExceptionHandler
      */
     @ExceptionHandler(HttpRequestMethodNotSupportedException.class)
     public AjaxResult handleHttpRequestMethodNotSupported(HttpRequestMethodNotSupportedException e,
-            HttpServletRequest request)
-    {
+                                                          HttpServletRequest request) {
         String requestURI = request.getRequestURI();
         log.error("请求地址'{}',不支持'{}'请求", requestURI, e.getMethod());
         return AjaxResult.error(e.getMessage());
@@ -54,8 +52,7 @@ public class GlobalExceptionHandler
      * 业务异常
      */
     @ExceptionHandler(ServiceException.class)
-    public AjaxResult handleServiceException(ServiceException e, HttpServletRequest request)
-    {
+    public AjaxResult handleServiceException(ServiceException e, HttpServletRequest request) {
         log.error(e.getMessage(), e);
         Integer code = e.getCode();
         return StringUtils.isNotNull(code) ? AjaxResult.error(code, e.getMessage()) : AjaxResult.error(e.getMessage());
@@ -65,8 +62,7 @@ public class GlobalExceptionHandler
      * 请求路径中缺少必需的路径变量
      */
     @ExceptionHandler(MissingPathVariableException.class)
-    public AjaxResult handleMissingPathVariableException(MissingPathVariableException e, HttpServletRequest request)
-    {
+    public AjaxResult handleMissingPathVariableException(MissingPathVariableException e, HttpServletRequest request) {
         String requestURI = request.getRequestURI();
         log.error("请求路径中缺少必需的路径变量'{}',发生系统异常.", requestURI, e);
         return AjaxResult.error(String.format("请求路径中缺少必需的路径变量[%s]", e.getVariableName()));
@@ -76,8 +72,7 @@ public class GlobalExceptionHandler
      * 请求参数类型不匹配
      */
     @ExceptionHandler(MethodArgumentTypeMismatchException.class)
-    public AjaxResult handleMethodArgumentTypeMismatchException(MethodArgumentTypeMismatchException e, HttpServletRequest request)
-    {
+    public AjaxResult handleMethodArgumentTypeMismatchException(MethodArgumentTypeMismatchException e, HttpServletRequest request) {
         String requestURI = request.getRequestURI();
         log.error("请求参数类型不匹配'{}',发生系统异常.", requestURI, e);
         return AjaxResult.error(String.format("请求参数类型不匹配,参数[%s]要求类型为:'%s',但输入值为:'%s'", e.getName(), e.getRequiredType().getName(), e.getValue()));
@@ -87,8 +82,7 @@ public class GlobalExceptionHandler
      * 拦截未知的运行时异常
      */
     @ExceptionHandler(RuntimeException.class)
-    public AjaxResult handleRuntimeException(RuntimeException e, HttpServletRequest request)
-    {
+    public AjaxResult handleRuntimeException(RuntimeException e, HttpServletRequest request) {
         String requestURI = request.getRequestURI();
         log.error("请求地址'{}',发生未知异常.", requestURI, e);
         return AjaxResult.error(e.getMessage());
@@ -98,8 +92,7 @@ public class GlobalExceptionHandler
      * 系统异常
      */
     @ExceptionHandler(Exception.class)
-    public AjaxResult handleException(Exception e, HttpServletRequest request)
-    {
+    public AjaxResult handleException(Exception e, HttpServletRequest request) {
         String requestURI = request.getRequestURI();
         log.error("请求地址'{}',发生系统异常.", requestURI, e);
         return AjaxResult.error(e.getMessage());
@@ -109,8 +102,7 @@ public class GlobalExceptionHandler
      * 自定义验证异常
      */
     @ExceptionHandler(BindException.class)
-    public AjaxResult handleBindException(BindException e)
-    {
+    public AjaxResult handleBindException(BindException e) {
         log.error(e.getMessage(), e);
         String message = e.getAllErrors().get(0).getDefaultMessage();
         return AjaxResult.error(message);
@@ -120,8 +112,7 @@ public class GlobalExceptionHandler
      * 自定义验证异常
      */
     @ExceptionHandler(MethodArgumentNotValidException.class)
-    public Object handleMethodArgumentNotValidException(MethodArgumentNotValidException e)
-    {
+    public Object handleMethodArgumentNotValidException(MethodArgumentNotValidException e) {
         log.error(e.getMessage(), e);
         String message = e.getBindingResult().getFieldError().getDefaultMessage();
         return AjaxResult.error(message);
@@ -131,8 +122,7 @@ public class GlobalExceptionHandler
      * 演示模式异常
      */
     @ExceptionHandler(DemoModeException.class)
-    public AjaxResult handleDemoModeException(DemoModeException e)
-    {
+    public AjaxResult handleDemoModeException(DemoModeException e) {
         return AjaxResult.error("演示模式,不允许操作");
     }
 }

+ 10 - 2
school-in-out-system/pom.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://maven.apache.org/POM/4.0.0"
-         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xmlns="http://maven.apache.org/POM/4.0.0"
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
     <parent>
         <artifactId>school-in-out</artifactId>
@@ -23,6 +23,14 @@
             <artifactId>school-in-out-common</artifactId>
         </dependency>
 
+        <!-- openapi3 注解依赖 -->
+        <dependency>
+            <groupId>org.springdoc</groupId>
+            <artifactId>springdoc-openapi-ui</artifactId>
+            <version>1.7.0</version>
+            <optional>true</optional>
+        </dependency>
+
     </dependencies>
 
 </project>

+ 115 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/AccessLog.java

@@ -0,0 +1,115 @@
+package com.schoolinout.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.schoolinout.common.annotation.Excel;
+import com.schoolinout.common.core.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import java.util.Date;
+
+/**
+ * 进出学校记录对象 tb_school_access_log
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@TableName("tb_school_access_log")
+@Schema(name = "进出学校记录对象")
+public class AccessLog extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @TableId(type = IdType.AUTO)
+    @Schema(description = "id")
+    private Long id;
+
+    /**
+     * 学生id
+     */
+    @Excel(name = "学生id")
+    @Schema(description = "学生id")
+    private Long studentId;
+
+    /**
+     * 到校时间
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Schema(description = "到校时间")
+    @Excel(name = "到校时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
+    private Date inTime;
+
+    /**
+     * 离校时间
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Schema(description = "离校时间")
+    @Excel(name = "离校时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
+    private Date outTime;
+
+    /**
+     * 删除标志(0代表存在 2代表删除)
+     */
+    private String delFlag;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getStudentId() {
+        return studentId;
+    }
+
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
+
+    public Date getInTime() {
+        return inTime;
+    }
+
+    public void setInTime(Date inTime) {
+        this.inTime = inTime;
+    }
+
+    public Date getOutTime() {
+        return outTime;
+    }
+
+    public void setOutTime(Date outTime) {
+        this.outTime = outTime;
+    }
+
+    public String getDelFlag() {
+        return delFlag;
+    }
+
+    public void setDelFlag(String delFlag) {
+        this.delFlag = delFlag;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("studentId", getStudentId())
+                .append("inTime", getInTime())
+                .append("outTime", getOutTime())
+                .append("delFlag", getDelFlag())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .toString();
+    }
+}

+ 138 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/Clazz.java

@@ -0,0 +1,138 @@
+package com.schoolinout.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.schoolinout.common.annotation.Excel;
+import com.schoolinout.common.core.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 班级管理对象 tb_school_class
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@TableName("tb_school_class")
+@Schema(name = "班级")
+public class Clazz extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @TableId(type = IdType.AUTO)
+    @Schema(description = "id")
+    private Long id;
+
+    /**
+     * 学校id
+     */
+    @Excel(name = "学校id")
+    @Schema(description = "学校id")
+    private Long schoolId;
+
+    /**
+     * 班级名称
+     */
+    @Excel(name = "班级名称")
+    @Schema(description = "班级名称")
+    private String className;
+
+    /**
+     * 班级人数
+     */
+    @Excel(name = "班级人数")
+    @Schema(description = "班级人数")
+    private Long classCount;
+
+    /**
+     * 班级电话
+     */
+    @Excel(name = "班级电话")
+    @Schema(description = "班级电话")
+    private String phone;
+
+    @TableField(exist = false)
+    private String teacherName;
+
+    /**
+     * 删除标志(0代表存在 2代表删除)
+     */
+    private String delFlag;
+
+    public String getTeacherName() {
+        return teacherName;
+    }
+
+    public void setTeacherName(String teacherName) {
+        this.teacherName = teacherName;
+    }
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public String getClassName() {
+        return className;
+    }
+
+    public void setClassName(String className) {
+        this.className = className;
+    }
+
+    public Long getClassCount() {
+        return classCount;
+    }
+
+    public void setClassCount(Long classCount) {
+        this.classCount = classCount;
+    }
+
+    public String getPhone() {
+        return phone;
+    }
+
+    public void setPhone(String phone) {
+        this.phone = phone;
+    }
+
+    public String getDelFlag() {
+        return delFlag;
+    }
+
+    public void setDelFlag(String delFlag) {
+        this.delFlag = delFlag;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("schoolId", getSchoolId())
+                .append("className", getClassName())
+                .append("classCount", getClassCount())
+                .append("phone", getPhone())
+                .append("delFlag", getDelFlag())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .toString();
+    }
+}

+ 126 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/School.java

@@ -0,0 +1,126 @@
+package com.schoolinout.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.schoolinout.common.annotation.Excel;
+import com.schoolinout.common.core.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 学校管理对象 tb_school
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@TableName("tb_school")
+@Schema(name = "学校实体")
+public class School extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @TableId(type = IdType.AUTO)
+    @Schema(description = "id")
+    private Long id;
+
+    /**
+     * 学校名称
+     */
+    @Excel(name = "学校名称")
+    @Schema(description = "学校名称")
+    private String schoolName;
+
+    /**
+     * 学校地址
+     */
+    @Excel(name = "学校地址")
+    @Schema(description = "学校地址")
+    private String schoolAddress;
+
+    /**
+     * 联系人
+     */
+    @Excel(name = "联系人")
+    @Schema(description = "联系人")
+    private String linkName;
+
+    /**
+     * 联系人电话
+     */
+    @Excel(name = "联系人电话")
+    @Schema(description = "联系人电话")
+    private String linkPhone;
+
+    /**
+     * 删除标志(0代表存在 2代表删除)
+     */
+    private String delFlag;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public String getSchoolName() {
+        return schoolName;
+    }
+
+    public void setSchoolName(String schoolName) {
+        this.schoolName = schoolName;
+    }
+
+    public String getSchoolAddress() {
+        return schoolAddress;
+    }
+
+    public void setSchoolAddress(String schoolAddress) {
+        this.schoolAddress = schoolAddress;
+    }
+
+    public String getLinkName() {
+        return linkName;
+    }
+
+    public void setLinkName(String linkName) {
+        this.linkName = linkName;
+    }
+
+    public String getLinkPhone() {
+        return linkPhone;
+    }
+
+    public void setLinkPhone(String linkPhone) {
+        this.linkPhone = linkPhone;
+    }
+
+    public String getDelFlag() {
+        return delFlag;
+    }
+
+    public void setDelFlag(String delFlag) {
+        this.delFlag = delFlag;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("schoolName", getSchoolName())
+                .append("schoolAddress", getSchoolAddress())
+                .append("linkName", getLinkName())
+                .append("linkPhone", getLinkPhone())
+                .append("delFlag", getDelFlag())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .toString();
+    }
+}

+ 158 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/Student.java

@@ -0,0 +1,158 @@
+package com.schoolinout.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.schoolinout.common.annotation.Excel;
+import com.schoolinout.common.core.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 学生管理对象 tb_school_student
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@TableName(value = "tb_school_student")
+@Schema(name = "学生实体")
+public class Student extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @TableId(type = IdType.AUTO)
+    @Schema(description = "id")
+    private Long id;
+
+    /**
+     * 学校id
+     */
+    @Excel(name = "学校id")
+    @Schema(description = "学校id")
+    private Long schoolId;
+
+    /**
+     * 班级id
+     */
+    @Excel(name = "班级id")
+    @Schema(description = "班级id")
+    private Long classId;
+
+    /**
+     * 学生名称
+     */
+    @Excel(name = "学生名称")
+    @Schema(description = "学生名称")
+    private String studentName;
+
+    /**
+     * 学生照片
+     */
+    @Excel(name = "学生照片")
+    @Schema(description = "学生照片")
+    private String studentPic;
+
+    /**
+     * 学生性别
+     */
+    @Excel(name = "学生性别")
+    @Schema(description = "学生性别")
+    private String studentGender;
+
+    /**
+     * 学号
+     */
+    @Excel(name = "学号")
+    @Schema(description = "学号")
+    private String studentNum;
+
+    /**
+     * 删除标志(0代表存在 2代表删除)
+     */
+    private String delFlag;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public Long getClassId() {
+        return classId;
+    }
+
+    public void setClassId(Long classId) {
+        this.classId = classId;
+    }
+
+    public String getStudentName() {
+        return studentName;
+    }
+
+    public void setStudentName(String studentName) {
+        this.studentName = studentName;
+    }
+
+    public String getStudentPic() {
+        return studentPic;
+    }
+
+    public void setStudentPic(String studentPic) {
+        this.studentPic = studentPic;
+    }
+
+    public String getStudentGender() {
+        return studentGender;
+    }
+
+    public void setStudentGender(String studentGender) {
+        this.studentGender = studentGender;
+    }
+
+    public String getStudentNum() {
+        return studentNum;
+    }
+
+    public void setStudentNum(String studentNum) {
+        this.studentNum = studentNum;
+    }
+
+    public String getDelFlag() {
+        return delFlag;
+    }
+
+    public void setDelFlag(String delFlag) {
+        this.delFlag = delFlag;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("schoolId", getSchoolId())
+                .append("classId", getClassId())
+                .append("studentName", getStudentName())
+                .append("studentPic", getStudentPic())
+                .append("studentGender", getStudentGender())
+                .append("studentNum", getStudentNum())
+                .append("delFlag", getDelFlag())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .toString();
+    }
+}

+ 125 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/Teacher.java

@@ -0,0 +1,125 @@
+package com.schoolinout.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.schoolinout.common.annotation.Excel;
+import com.schoolinout.common.core.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 教师管理对象 tb_school_teacher
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@TableName("tb_school_teacher")
+@Schema(name = "教师对象")
+public class Teacher extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @TableId(type = IdType.AUTO)
+    private Long id;
+
+    /**
+     * 学校id
+     */
+    @Excel(name = "学校id")
+    @Schema(description = "学校id")
+    private Long schoolId;
+
+    /**
+     * 老师姓名
+     */
+    @Excel(name = "老师姓名")
+    @Schema(description = "老师姓名")
+    private String teacherName;
+
+    /**
+     * 性别;0男   1女
+     */
+    @Excel(name = "性别")
+    @Schema(description = "性别;0男   1女")
+    private String gender;
+
+    /**
+     * 联系电话
+     */
+    @Excel(name = "联系电话")
+    @Schema(description = "联系电话")
+    private String phone;
+
+    /**
+     * 删除标志(0代表存在 2代表删除)
+     */
+    private String delFlag;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public String getTeacherName() {
+        return teacherName;
+    }
+
+    public void setTeacherName(String teacherName) {
+        this.teacherName = teacherName;
+    }
+
+    public String getGender() {
+        return gender;
+    }
+
+    public void setGender(String gender) {
+        this.gender = gender;
+    }
+
+    public String getPhone() {
+        return phone;
+    }
+
+    public void setPhone(String phone) {
+        this.phone = phone;
+    }
+
+    public String getDelFlag() {
+        return delFlag;
+    }
+
+    public void setDelFlag(String delFlag) {
+        this.delFlag = delFlag;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("schoolId", getSchoolId())
+                .append("teacherName", getTeacherName())
+                .append("gender", getGender())
+                .append("phone", getPhone())
+                .append("delFlag", getDelFlag())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .toString();
+    }
+}

+ 112 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/TeacherClassRelation.java

@@ -0,0 +1,112 @@
+package com.schoolinout.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.schoolinout.common.annotation.Excel;
+import com.schoolinout.common.core.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 老师-班级关系对象 tb_school_teacher_class_relation
+ *
+ * @author sakura
+ * @date 2024-01-04
+ */
+@TableName("tb_school_teacher_class_relation")
+@Schema(name = "教师和班级关联表")
+public class TeacherClassRelation extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @TableId(type = IdType.AUTO)
+    @Schema(description = "id")
+    private Long id;
+
+    /**
+     * 学校id
+     */
+    @Excel(name = "学校id")
+    @Schema(description = "学校id")
+    private Long schoolId;
+
+    /**
+     * 教师id
+     */
+    @Excel(name = "教师id")
+    @Schema(description = "教师id")
+    private Long teacherId;
+
+    /**
+     * 班级id
+     */
+    @Excel(name = "班级id")
+    @Schema(description = "班级id")
+    private Long classId;
+
+    /**
+     * 是否为班主任
+     */
+    @Excel(name = "是否为班主任")
+    @Schema(description = "是否为班主任")
+    private String teacherMain;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public Long getTeacherId() {
+        return teacherId;
+    }
+
+    public void setTeacherId(Long teacherId) {
+        this.teacherId = teacherId;
+    }
+
+    public Long getClassId() {
+        return classId;
+    }
+
+    public void setClassId(Long classId) {
+        this.classId = classId;
+    }
+
+    public String getTeacherMain() {
+        return teacherMain;
+    }
+
+    public void setTeacherMain(String teacherMain) {
+        this.teacherMain = teacherMain;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("schoolId", getSchoolId())
+                .append("teacherId", getTeacherId())
+                .append("classId", getClassId())
+                .append("teacherMain", getTeacherMain())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .toString();
+    }
+}

+ 98 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/dto/AddClassDto.java

@@ -0,0 +1,98 @@
+package com.schoolinout.system.domain.dto;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import javax.validation.constraints.NotBlank;
+import javax.validation.constraints.NotNull;
+import java.io.Serializable;
+import java.util.List;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 15:15:17 Thu
+ */
+@Schema(name = "添加班级实体")
+public class AddClassDto implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 学校id
+     */
+    @Schema(description = "学校id")
+    @NotNull(message = "请绑定学校")
+    private Long schoolId;
+
+
+    /**
+     * 班级名称
+     */
+    @Schema(description = "班级名称")
+    @NotBlank(message = "请输入当前班级名称")
+    private String className;
+
+    /**
+     * 班级人数
+     */
+    @Schema(description = "班级人数")
+    private Long classCount;
+
+    /**
+     * 班级电话
+     */
+    @Schema(description = "班级电话")
+    private String phone;
+
+    @Schema(description = "要绑定的教师")
+    private List<Long> teacherIds;
+
+    @Override
+    public String toString() {
+        return "AddClassDto{" +
+                "schoolId=" + schoolId +
+                ", className='" + className + '\'' +
+                ", classCount=" + classCount +
+                ", phone='" + phone + '\'' +
+                ", teacherIds=" + teacherIds +
+                '}';
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public String getClassName() {
+        return className;
+    }
+
+    public void setClassName(String className) {
+        this.className = className;
+    }
+
+    public Long getClassCount() {
+        return classCount;
+    }
+
+    public void setClassCount(Long classCount) {
+        this.classCount = classCount;
+    }
+
+    public String getPhone() {
+        return phone;
+    }
+
+    public void setPhone(String phone) {
+        this.phone = phone;
+    }
+
+    public List<Long> getTeacherIds() {
+        return teacherIds;
+    }
+
+    public void setTeacherIds(List<Long> teacherIds) {
+        this.teacherIds = teacherIds;
+    }
+}

+ 56 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/dto/AddTeacherClassRelationDto.java

@@ -0,0 +1,56 @@
+package com.schoolinout.system.domain.dto;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import javax.validation.constraints.NotEmpty;
+import javax.validation.constraints.NotNull;
+import java.util.List;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 10:10:31 Thu
+ */
+@Schema(name = "绑定教师和班级实体")
+public class AddTeacherClassRelationDto {
+
+    @NotNull(message = "所属学校不能为空")
+    private Long schoolId;
+
+    @NotNull(message = "教师不能为空")
+    private Long teacherId;
+    @NotEmpty(message = "绑定的班级不能为空")
+    private List<Long> classId;
+
+    @Override
+    public String toString() {
+        return "AddTeacherClassRelationDto{" +
+                "schoolId=" + schoolId +
+                ", teacherId=" + teacherId +
+                ", classId=" + classId +
+                '}';
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public Long getTeacherId() {
+        return teacherId;
+    }
+
+    public void setTeacherId(Long teacherId) {
+        this.teacherId = teacherId;
+    }
+
+    public List<Long> getClassId() {
+        return classId;
+    }
+
+    public void setClassId(List<Long> classId) {
+        this.classId = classId;
+    }
+}

+ 48 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/dto/InsertTeacherClassRelationDto.java

@@ -0,0 +1,48 @@
+package com.schoolinout.system.domain.dto;
+
+import java.io.Serializable;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 15:15:41 Thu
+ */
+public class InsertTeacherClassRelationDto implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+    private Long schoolId;
+    private Long teacherId;
+    private Long classId;
+
+    public InsertTeacherClassRelationDto() {
+    }
+
+    public InsertTeacherClassRelationDto(Long schoolId, Long teacherId, Long classId) {
+        this.schoolId = schoolId;
+        this.teacherId = teacherId;
+        this.classId = classId;
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public Long getTeacherId() {
+        return teacherId;
+    }
+
+    public void setTeacherId(Long teacherId) {
+        this.teacherId = teacherId;
+    }
+
+    public Long getClassId() {
+        return classId;
+    }
+
+    public void setClassId(Long classId) {
+        this.classId = classId;
+    }
+}

+ 22 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/ClazzInfoVo.java

@@ -0,0 +1,22 @@
+package com.schoolinout.system.domain.vo;
+
+import com.schoolinout.system.domain.Clazz;
+
+import java.util.List;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 16:16:49 Thu
+ */
+public class ClazzInfoVo extends Clazz {
+
+    private List<Long> teacherIds;
+
+    public List<Long> getTeacherIds() {
+        return teacherIds;
+    }
+
+    public void setTeacherIds(List<Long> teacherIds) {
+        this.teacherIds = teacherIds;
+    }
+}

+ 40 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/ClazzOptionVo.java

@@ -0,0 +1,40 @@
+package com.schoolinout.system.domain.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 10:10:10 Thu
+ */
+@Schema(name = "班级下拉框的实体")
+public class ClazzOptionVo {
+
+    @Schema(description = "显示值,class_name 字段")
+    private String label;
+    @Schema(description = "获取值 id 字段")
+    private Long value;
+
+    @Override
+    public String toString() {
+        return "ClazzOptionVo{" +
+                "label='" + label + '\'' +
+                ", value=" + value +
+                '}';
+    }
+
+    public String getLabel() {
+        return label;
+    }
+
+    public void setLabel(String label) {
+        this.label = label;
+    }
+
+    public Long getValue() {
+        return value;
+    }
+
+    public void setValue(Long value) {
+        this.value = value;
+    }
+}

+ 40 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/OptionVo.java

@@ -0,0 +1,40 @@
+package com.schoolinout.system.domain.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 14:14:55 Thu
+ */
+@Schema(name = "下拉框的实体")
+public class OptionVo {
+    @Schema(description = "显示值")
+    private String label;
+    @Schema(description = "获取值 id 字段")
+    private Long value;
+
+    @Override
+    public String toString() {
+        return "ClazzOptionVo{" +
+                "label='" + label + '\'' +
+                ", value=" + value +
+                '}';
+    }
+
+    public String getLabel() {
+        return label;
+    }
+
+    public void setLabel(String label) {
+        this.label = label;
+    }
+
+    public Long getValue() {
+        return value;
+    }
+
+    public void setValue(Long value) {
+        this.value = value;
+    }
+
+}

+ 149 - 0
school-in-out-system/src/main/java/com/schoolinout/system/domain/vo/TeacherClassInfoVo.java

@@ -0,0 +1,149 @@
+package com.schoolinout.system.domain.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import java.io.Serializable;
+
+/**
+ * @author sakura
+ * @date 2024/1/4 14:14:04 Thu
+ */
+@Schema(name = "教师和班级关系实体")
+public class TeacherClassInfoVo implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * id
+     */
+    @Schema(description = "id")
+    private Long id;
+
+    /**
+     * 教师id
+     */
+    @Schema(description = "教师id")
+    private Long teacherId;
+
+
+    /**
+     * 学校id
+     */
+    @Schema(description = "学校id")
+    private Long schoolId;
+
+    @Schema(description = "班级id")
+    private Long classId;
+
+    /**
+     * 老师姓名
+     */
+    @Schema(description = "老师姓名")
+    private String teacherName;
+
+    /**
+     * 性别;0男   1女
+     */
+    @Schema(description = "性别;0男   1女")
+    private String gender;
+
+    /**
+     * 联系电话
+     */
+    @Schema(description = "联系电话")
+    private String phone;
+
+    @Schema(description = "班级名称")
+    private String className;
+
+    @Schema(description = "是否为班主任")
+    private String teacherMain;
+
+    @Override
+    public String toString() {
+        return "TeacherClassInfoVo{" +
+                "id=" + id +
+                ", teacherId=" + teacherId +
+                ", schoolId=" + schoolId +
+                ", classId=" + classId +
+                ", teacherName='" + teacherName + '\'' +
+                ", gender='" + gender + '\'' +
+                ", phone='" + phone + '\'' +
+                ", className='" + className + '\'' +
+                ", teacherMain='" + teacherMain + '\'' +
+                '}';
+    }
+
+    public Long getTeacherId() {
+        return teacherId;
+    }
+
+    public void setTeacherId(Long teacherId) {
+        this.teacherId = teacherId;
+    }
+
+    public String getTeacherMain() {
+        return teacherMain;
+    }
+
+    public void setTeacherMain(String teacherMain) {
+        this.teacherMain = teacherMain;
+    }
+
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getSchoolId() {
+        return schoolId;
+    }
+
+    public void setSchoolId(Long schoolId) {
+        this.schoolId = schoolId;
+    }
+
+    public Long getClassId() {
+        return classId;
+    }
+
+    public void setClassId(Long classId) {
+        this.classId = classId;
+    }
+
+    public String getTeacherName() {
+        return teacherName;
+    }
+
+    public void setTeacherName(String teacherName) {
+        this.teacherName = teacherName;
+    }
+
+    public String getGender() {
+        return gender;
+    }
+
+    public void setGender(String gender) {
+        this.gender = gender;
+    }
+
+    public String getPhone() {
+        return phone;
+    }
+
+    public void setPhone(String phone) {
+        this.phone = phone;
+    }
+
+    public String getClassName() {
+        return className;
+    }
+
+    public void setClassName(String className) {
+        this.className = className;
+    }
+}

+ 64 - 0
school-in-out-system/src/main/java/com/schoolinout/system/mapper/AccessLogMapper.java

@@ -0,0 +1,64 @@
+package com.schoolinout.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.schoolinout.system.domain.AccessLog;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+/**
+ * 进出学校记录Mapper接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Mapper
+public interface AccessLogMapper extends BaseMapper<AccessLog> {
+    /**
+     * 查询进出学校记录
+     *
+     * @param id 进出学校记录主键
+     * @return 进出学校记录
+     */
+    public AccessLog selectAccessLogById(Long id);
+
+    /**
+     * 查询进出学校记录列表
+     *
+     * @param accessLog 进出学校记录
+     * @return 进出学校记录集合
+     */
+    public List<AccessLog> selectAccessLogList(AccessLog accessLog);
+
+    /**
+     * 新增进出学校记录
+     *
+     * @param accessLog 进出学校记录
+     * @return 结果
+     */
+    public int insertAccessLog(AccessLog accessLog);
+
+    /**
+     * 修改进出学校记录
+     *
+     * @param accessLog 进出学校记录
+     * @return 结果
+     */
+    public int updateAccessLog(AccessLog accessLog);
+
+    /**
+     * 删除进出学校记录
+     *
+     * @param id 进出学校记录主键
+     * @return 结果
+     */
+    public int deleteAccessLogById(Long id);
+
+    /**
+     * 批量删除进出学校记录
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteAccessLogByIds(Long[] ids);
+}

+ 67 - 0
school-in-out-system/src/main/java/com/schoolinout/system/mapper/ClazzMapper.java

@@ -0,0 +1,67 @@
+package com.schoolinout.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.schoolinout.system.domain.Clazz;
+import com.schoolinout.system.domain.vo.OptionVo;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+/**
+ * 班级管理Mapper接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Mapper
+public interface ClazzMapper extends BaseMapper<Clazz> {
+    /**
+     * 查询班级管理
+     *
+     * @param id 班级管理主键
+     * @return 班级管理
+     */
+    public Clazz selectClazzById(Long id);
+
+    /**
+     * 查询班级管理列表
+     *
+     * @param clazz 班级管理
+     * @return 班级管理集合
+     */
+    public List<Clazz> selectClazzList(Clazz clazz);
+
+    /**
+     * 新增班级管理
+     *
+     * @param clazz 班级管理
+     * @return 结果
+     */
+    public int insertClazz(Clazz clazz);
+
+    /**
+     * 修改班级管理
+     *
+     * @param clazz 班级管理
+     * @return 结果
+     */
+    public int updateClazz(Clazz clazz);
+
+    /**
+     * 删除班级管理
+     *
+     * @param id 班级管理主键
+     * @return 结果
+     */
+    public int deleteClazzById(Long id);
+
+    /**
+     * 批量删除班级管理
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteClazzByIds(Long[] ids);
+
+    List<OptionVo> selectClazzOptionBySchoolId(Long schoolId);
+}

+ 64 - 0
school-in-out-system/src/main/java/com/schoolinout/system/mapper/SchoolMapper.java

@@ -0,0 +1,64 @@
+package com.schoolinout.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.schoolinout.system.domain.School;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+/**
+ * 学校管理Mapper接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Mapper
+public interface SchoolMapper extends BaseMapper<School> {
+    /**
+     * 查询学校管理
+     *
+     * @param id 学校管理主键
+     * @return 学校管理
+     */
+    public School selectSchoolById(Long id);
+
+    /**
+     * 查询学校管理列表
+     *
+     * @param school 学校管理
+     * @return 学校管理集合
+     */
+    public List<School> selectSchoolList(School school);
+
+    /**
+     * 新增学校管理
+     *
+     * @param school 学校管理
+     * @return 结果
+     */
+    public int insertSchool(School school);
+
+    /**
+     * 修改学校管理
+     *
+     * @param school 学校管理
+     * @return 结果
+     */
+    public int updateSchool(School school);
+
+    /**
+     * 删除学校管理
+     *
+     * @param id 学校管理主键
+     * @return 结果
+     */
+    public int deleteSchoolById(Long id);
+
+    /**
+     * 批量删除学校管理
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteSchoolByIds(Long[] ids);
+}

+ 64 - 0
school-in-out-system/src/main/java/com/schoolinout/system/mapper/StudentMapper.java

@@ -0,0 +1,64 @@
+package com.schoolinout.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.schoolinout.system.domain.Student;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+/**
+ * 学生管理Mapper接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Mapper
+public interface StudentMapper extends BaseMapper<Student> {
+    /**
+     * 查询学生管理
+     *
+     * @param id 学生管理主键
+     * @return 学生管理
+     */
+    public Student selectStudentById(Long id);
+
+    /**
+     * 查询学生管理列表
+     *
+     * @param student 学生管理
+     * @return 学生管理集合
+     */
+    public List<Student> selectStudentList(Student student);
+
+    /**
+     * 新增学生管理
+     *
+     * @param student 学生管理
+     * @return 结果
+     */
+    public int insertStudent(Student student);
+
+    /**
+     * 修改学生管理
+     *
+     * @param student 学生管理
+     * @return 结果
+     */
+    public int updateStudent(Student student);
+
+    /**
+     * 删除学生管理
+     *
+     * @param id 学生管理主键
+     * @return 结果
+     */
+    public int deleteStudentById(Long id);
+
+    /**
+     * 批量删除学生管理
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteStudentByIds(Long[] ids);
+}

+ 25 - 16
school-in-out-system/src/main/java/com/schoolinout/system/mapper/SysDictDataMapper.java

@@ -1,19 +1,19 @@
 package com.schoolinout.system.mapper;
 
-import java.util.List;
-import org.apache.ibatis.annotations.Param;
 import com.schoolinout.common.core.domain.entity.SysDictData;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
 
 /**
  * 字典表 数据层
- * 
+ *
  * @author ruoyi
  */
-public interface SysDictDataMapper
-{
+public interface SysDictDataMapper {
     /**
      * 根据条件分页查询字典数据
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 字典数据集合信息
      */
@@ -21,7 +21,7 @@ public interface SysDictDataMapper
 
     /**
      * 根据字典类型查询字典数据
-     * 
+     *
      * @param dictType 字典类型
      * @return 字典数据集合信息
      */
@@ -29,8 +29,8 @@ public interface SysDictDataMapper
 
     /**
      * 根据字典类型和字典键值查询字典数据信息
-     * 
-     * @param dictType 字典类型
+     *
+     * @param dictType  字典类型
      * @param dictValue 字典键值
      * @return 字典标签
      */
@@ -38,7 +38,7 @@ public interface SysDictDataMapper
 
     /**
      * 根据字典数据ID查询信息
-     * 
+     *
      * @param dictCode 字典数据ID
      * @return 字典数据
      */
@@ -46,7 +46,7 @@ public interface SysDictDataMapper
 
     /**
      * 查询字典数据
-     * 
+     *
      * @param dictType 字典类型
      * @return 字典数据
      */
@@ -54,7 +54,7 @@ public interface SysDictDataMapper
 
     /**
      * 通过字典ID删除字典数据信息
-     * 
+     *
      * @param dictCode 字典数据ID
      * @return 结果
      */
@@ -62,7 +62,7 @@ public interface SysDictDataMapper
 
     /**
      * 批量删除字典数据信息
-     * 
+     *
      * @param dictCodes 需要删除的字典数据ID
      * @return 结果
      */
@@ -70,7 +70,7 @@ public interface SysDictDataMapper
 
     /**
      * 新增字典数据信息
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 结果
      */
@@ -78,7 +78,7 @@ public interface SysDictDataMapper
 
     /**
      * 修改字典数据信息
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 结果
      */
@@ -86,10 +86,19 @@ public interface SysDictDataMapper
 
     /**
      * 同步修改字典类型
-     * 
+     *
      * @param oldDictType 旧字典类型
      * @param newDictType 新旧字典类型
      * @return 结果
      */
     public int updateDictDataType(@Param("oldDictType") String oldDictType, @Param("newDictType") String newDictType);
+
+    /**
+     * 根据 表名获取对应的值
+     *
+     * @param tableName  表名
+     * @param labelField 显示值
+     * @param valueField 获取的字段
+     */
+    List<SysDictData> selectTableDictDataByTable(@Param("tableName") String tableName, @Param("labelField") String labelField, @Param("valueField") String valueField);
 }

+ 74 - 0
school-in-out-system/src/main/java/com/schoolinout/system/mapper/TeacherClassRelationMapper.java

@@ -0,0 +1,74 @@
+package com.schoolinout.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.schoolinout.system.domain.TeacherClassRelation;
+import com.schoolinout.system.domain.dto.InsertTeacherClassRelationDto;
+import com.schoolinout.system.domain.vo.TeacherClassInfoVo;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+/**
+ * 老师-班级关系Mapper接口
+ *
+ * @author sakura
+ * @date 2024-01-04
+ */
+@Mapper
+public interface TeacherClassRelationMapper extends BaseMapper<TeacherClassRelation> {
+    /**
+     * 查询老师-班级关系
+     *
+     * @param id 老师-班级关系主键
+     * @return 老师-班级关系
+     */
+    public TeacherClassRelation selectTeacherClassRelationById(Long id);
+
+    /**
+     * 查询老师-班级关系列表
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 老师-班级关系集合
+     */
+    public List<TeacherClassRelation> selectTeacherClassRelationList(TeacherClassRelation teacherClassRelation);
+
+    /**
+     * 新增老师-班级关系
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 结果
+     */
+    public int insertTeacherClassRelation(TeacherClassRelation teacherClassRelation);
+
+    /**
+     * 修改老师-班级关系
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 结果
+     */
+    public int updateTeacherClassRelation(TeacherClassRelation teacherClassRelation);
+
+    /**
+     * 删除老师-班级关系
+     *
+     * @param id 老师-班级关系主键
+     * @return 结果
+     */
+    public int deleteTeacherClassRelationById(Long id);
+
+    /**
+     * 批量删除老师-班级关系
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteTeacherClassRelationByIds(Long[] ids);
+
+
+    int deleteRelationBySchoolIdAndTeacherId(@Param("schoolId") Long schoolId, @Param("teacherId") Long teacherId);
+
+    int insertTeacherClassRelationBatch(@Param("list") List<InsertTeacherClassRelationDto> list);
+
+    List<TeacherClassInfoVo> selectTeacherClass(@Param("schoolId") Long schoolId, @Param("teacherId") Long teacherId, @Param("classId") Long classId);
+}

+ 67 - 0
school-in-out-system/src/main/java/com/schoolinout/system/mapper/TeacherMapper.java

@@ -0,0 +1,67 @@
+package com.schoolinout.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.schoolinout.system.domain.Teacher;
+import com.schoolinout.system.domain.vo.OptionVo;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+/**
+ * 教师管理Mapper接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Mapper
+public interface TeacherMapper extends BaseMapper<Teacher> {
+    /**
+     * 查询教师管理
+     *
+     * @param id 教师管理主键
+     * @return 教师管理
+     */
+    public Teacher selectTeacherById(Long id);
+
+    /**
+     * 查询教师管理列表
+     *
+     * @param teacher 教师管理
+     * @return 教师管理集合
+     */
+    public List<Teacher> selectTeacherList(Teacher teacher);
+
+    /**
+     * 新增教师管理
+     *
+     * @param teacher 教师管理
+     * @return 结果
+     */
+    public int insertTeacher(Teacher teacher);
+
+    /**
+     * 修改教师管理
+     *
+     * @param teacher 教师管理
+     * @return 结果
+     */
+    public int updateTeacher(Teacher teacher);
+
+    /**
+     * 删除教师管理
+     *
+     * @param id 教师管理主键
+     * @return 结果
+     */
+    public int deleteTeacherById(Long id);
+
+    /**
+     * 批量删除教师管理
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteTeacherByIds(Long[] ids);
+
+    List<OptionVo> selectTeacherOption(Long schoolId);
+}

+ 61 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/IAccessLogService.java

@@ -0,0 +1,61 @@
+package com.schoolinout.system.service;
+
+import java.util.List;
+import com.schoolinout.system.domain.AccessLog;
+
+/**
+ * 进出学校记录Service接口
+ * 
+ * @author sakura
+ * @date 2024-01-03
+ */
+public interface IAccessLogService 
+{
+    /**
+     * 查询进出学校记录
+     * 
+     * @param id 进出学校记录主键
+     * @return 进出学校记录
+     */
+    public AccessLog selectAccessLogById(Long id);
+
+    /**
+     * 查询进出学校记录列表
+     * 
+     * @param accessLog 进出学校记录
+     * @return 进出学校记录集合
+     */
+    public List<AccessLog> selectAccessLogList(AccessLog accessLog);
+
+    /**
+     * 新增进出学校记录
+     * 
+     * @param accessLog 进出学校记录
+     * @return 结果
+     */
+    public int insertAccessLog(AccessLog accessLog);
+
+    /**
+     * 修改进出学校记录
+     * 
+     * @param accessLog 进出学校记录
+     * @return 结果
+     */
+    public int updateAccessLog(AccessLog accessLog);
+
+    /**
+     * 批量删除进出学校记录
+     * 
+     * @param ids 需要删除的进出学校记录主键集合
+     * @return 结果
+     */
+    public int deleteAccessLogByIds(Long[] ids);
+
+    /**
+     * 删除进出学校记录信息
+     * 
+     * @param id 进出学校记录主键
+     * @return 结果
+     */
+    public int deleteAccessLogById(Long id);
+}

+ 67 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/IClazzService.java

@@ -0,0 +1,67 @@
+package com.schoolinout.system.service;
+
+import com.schoolinout.system.domain.Clazz;
+import com.schoolinout.system.domain.dto.AddClassDto;
+import com.schoolinout.system.domain.vo.OptionVo;
+
+import java.util.List;
+
+/**
+ * 班级管理Service接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+public interface IClazzService {
+    /**
+     * 查询班级管理
+     *
+     * @param id 班级管理主键
+     * @return 班级管理
+     */
+    public Clazz selectClazzById(Long id);
+
+    public List<OptionVo> selectClazzOptionList(Long schoolId);
+
+    /**
+     * 查询班级管理列表
+     *
+     * @param clazz 班级管理
+     * @return 班级管理集合
+     */
+    public List<Clazz> selectClazzList(Clazz clazz);
+
+    /**
+     * 新增班级管理
+     *
+     * @param clazz 班级管理
+     * @return 结果
+     */
+    public int insertClazz(Clazz clazz);
+
+    /**
+     * 修改班级管理
+     *
+     * @param clazz 班级管理
+     * @return 结果
+     */
+    public int updateClazz(Clazz clazz);
+
+    /**
+     * 批量删除班级管理
+     *
+     * @param ids 需要删除的班级管理主键集合
+     * @return 结果
+     */
+    public int deleteClazzByIds(Long[] ids);
+
+    /**
+     * 删除班级管理信息
+     *
+     * @param id 班级管理主键
+     * @return 结果
+     */
+    public int deleteClazzById(Long id);
+
+    public int saveClassAndRelation(AddClassDto form);
+}

+ 61 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/ISchoolService.java

@@ -0,0 +1,61 @@
+package com.schoolinout.system.service;
+
+import java.util.List;
+import com.schoolinout.system.domain.School;
+
+/**
+ * 学校管理Service接口
+ * 
+ * @author sakura
+ * @date 2024-01-03
+ */
+public interface ISchoolService 
+{
+    /**
+     * 查询学校管理
+     * 
+     * @param id 学校管理主键
+     * @return 学校管理
+     */
+    public School selectSchoolById(Long id);
+
+    /**
+     * 查询学校管理列表
+     * 
+     * @param school 学校管理
+     * @return 学校管理集合
+     */
+    public List<School> selectSchoolList(School school);
+
+    /**
+     * 新增学校管理
+     * 
+     * @param school 学校管理
+     * @return 结果
+     */
+    public int insertSchool(School school);
+
+    /**
+     * 修改学校管理
+     * 
+     * @param school 学校管理
+     * @return 结果
+     */
+    public int updateSchool(School school);
+
+    /**
+     * 批量删除学校管理
+     * 
+     * @param ids 需要删除的学校管理主键集合
+     * @return 结果
+     */
+    public int deleteSchoolByIds(Long[] ids);
+
+    /**
+     * 删除学校管理信息
+     * 
+     * @param id 学校管理主键
+     * @return 结果
+     */
+    public int deleteSchoolById(Long id);
+}

+ 61 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/IStudentService.java

@@ -0,0 +1,61 @@
+package com.schoolinout.system.service;
+
+import com.schoolinout.system.domain.Student;
+
+import java.util.List;
+
+/**
+ * 学生管理Service接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+public interface IStudentService {
+    /**
+     * 查询学生管理
+     *
+     * @param id 学生管理主键
+     * @return 学生管理
+     */
+    public Student selectStudentById(Long id);
+
+    /**
+     * 查询学生管理列表
+     *
+     * @param student 学生管理
+     * @return 学生管理集合
+     */
+    public List<Student> selectStudentList(Student student);
+
+    /**
+     * 新增学生管理
+     *
+     * @param student 学生管理
+     * @return 结果
+     */
+    public int insertStudent(Student student);
+
+    /**
+     * 修改学生管理
+     *
+     * @param student 学生管理
+     * @return 结果
+     */
+    public int updateStudent(Student student);
+
+    /**
+     * 批量删除学生管理
+     *
+     * @param ids 需要删除的学生管理主键集合
+     * @return 结果
+     */
+    public int deleteStudentByIds(Long[] ids);
+
+    /**
+     * 删除学生管理信息
+     *
+     * @param id 学生管理主键
+     * @return 结果
+     */
+    public int deleteStudentById(Long id);
+}

+ 21 - 11
school-in-out-system/src/main/java/com/schoolinout/system/service/ISysDictDataService.java

@@ -1,18 +1,18 @@
 package com.schoolinout.system.service;
 
-import java.util.List;
 import com.schoolinout.common.core.domain.entity.SysDictData;
 
+import java.util.List;
+
 /**
  * 字典 业务层
- * 
+ *
  * @author ruoyi
  */
-public interface ISysDictDataService
-{
+public interface ISysDictDataService {
     /**
      * 根据条件分页查询字典数据
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 字典数据集合信息
      */
@@ -20,8 +20,8 @@ public interface ISysDictDataService
 
     /**
      * 根据字典类型和字典键值查询字典数据信息
-     * 
-     * @param dictType 字典类型
+     *
+     * @param dictType  字典类型
      * @param dictValue 字典键值
      * @return 字典标签
      */
@@ -29,7 +29,7 @@ public interface ISysDictDataService
 
     /**
      * 根据字典数据ID查询信息
-     * 
+     *
      * @param dictCode 字典数据ID
      * @return 字典数据
      */
@@ -37,14 +37,14 @@ public interface ISysDictDataService
 
     /**
      * 批量删除字典数据信息
-     * 
+     *
      * @param dictCodes 需要删除的字典数据ID
      */
     public void deleteDictDataByIds(Long[] dictCodes);
 
     /**
      * 新增保存字典数据信息
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 结果
      */
@@ -52,9 +52,19 @@ public interface ISysDictDataService
 
     /**
      * 修改保存字典数据信息
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 结果
      */
     public int updateDictData(SysDictData dictData);
+
+    /**
+     * 表字典
+     *
+     * @param tableName  表名
+     * @param labelField 显示字段
+     * @param valueField 取值字段
+     * @return 返回字典数据
+     */
+    public List<SysDictData> queryTableDict(String tableName, String labelField, String valueField);
 }

+ 80 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/ITeacherClassRelationService.java

@@ -0,0 +1,80 @@
+package com.schoolinout.system.service;
+
+import com.schoolinout.system.domain.TeacherClassRelation;
+import com.schoolinout.system.domain.dto.AddTeacherClassRelationDto;
+import com.schoolinout.system.domain.vo.TeacherClassInfoVo;
+
+import java.util.List;
+
+/**
+ * 老师-班级关系Service接口
+ *
+ * @author sakura
+ * @date 2024-01-04
+ */
+public interface ITeacherClassRelationService {
+    /**
+     * 查询老师-班级关系
+     *
+     * @param id 老师-班级关系主键
+     * @return 老师-班级关系
+     */
+    public TeacherClassRelation selectTeacherClassRelationById(Long id);
+
+    /**
+     * 查询老师-班级关系列表
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 老师-班级关系集合
+     */
+    public List<TeacherClassRelation> selectTeacherClassRelationList(TeacherClassRelation teacherClassRelation);
+
+    /**
+     * 新增老师-班级关系
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 结果
+     */
+    public int insertTeacherClassRelation(TeacherClassRelation teacherClassRelation);
+
+    /**
+     * 修改老师-班级关系
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 结果
+     */
+    public int updateTeacherClassRelation(TeacherClassRelation teacherClassRelation);
+
+    /**
+     * 批量删除老师-班级关系
+     *
+     * @param ids 需要删除的老师-班级关系主键集合
+     * @return 结果
+     */
+    public int deleteTeacherClassRelationByIds(Long[] ids);
+
+    /**
+     * 删除老师-班级关系信息
+     *
+     * @param id 老师-班级关系主键
+     * @return 结果
+     */
+    public int deleteTeacherClassRelationById(Long id);
+
+    /**
+     * 以教师为主,绑定多个班级
+     *
+     * @param form 表单对象
+     * @return 结果
+     */
+    public int bindTeacherClass(AddTeacherClassRelationDto form);
+
+    /**
+     * 查询当前教师绑定的所有班级
+     *
+     * @param schoolId  学校id
+     * @param teacherId 教师id
+     * @return 结果
+     */
+    public List<TeacherClassInfoVo> queryTeacherBindClassList(Long schoolId, Long teacherId);
+}

+ 70 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/ITeacherService.java

@@ -0,0 +1,70 @@
+package com.schoolinout.system.service;
+
+import com.schoolinout.system.domain.Teacher;
+import com.schoolinout.system.domain.vo.OptionVo;
+
+import java.util.List;
+
+/**
+ * 教师管理Service接口
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+public interface ITeacherService {
+    /**
+     * 查询教师管理
+     *
+     * @param id 教师管理主键
+     * @return 教师管理
+     */
+    public Teacher selectTeacherById(Long id);
+
+    /**
+     * 查询教师管理列表
+     *
+     * @param teacher 教师管理
+     * @return 教师管理集合
+     */
+    public List<Teacher> selectTeacherList(Teacher teacher);
+
+    /**
+     * 新增教师管理
+     *
+     * @param teacher 教师管理
+     * @return 结果
+     */
+    public int insertTeacher(Teacher teacher);
+
+    /**
+     * 修改教师管理
+     *
+     * @param teacher 教师管理
+     * @return 结果
+     */
+    public int updateTeacher(Teacher teacher);
+
+    /**
+     * 批量删除教师管理
+     *
+     * @param ids 需要删除的教师管理主键集合
+     * @return 结果
+     */
+    public int deleteTeacherByIds(Long[] ids);
+
+    /**
+     * 删除教师管理信息
+     *
+     * @param id 教师管理主键
+     * @return 结果
+     */
+    public int deleteTeacherById(Long id);
+
+    /**
+     * 搜索当前学校的教师下拉框
+     *
+     * @param schoolId 学校id
+     * @return 教师下拉框结果
+     */
+    public List<OptionVo> selectTeacherOptionList(Long schoolId);
+}

+ 96 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/AccessLogServiceImpl.java

@@ -0,0 +1,96 @@
+package com.schoolinout.system.service.impl;
+
+import java.util.List;
+import com.schoolinout.common.utils.DateUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.schoolinout.system.mapper.AccessLogMapper;
+import com.schoolinout.system.domain.AccessLog;
+import com.schoolinout.system.service.IAccessLogService;
+
+/**
+ * 进出学校记录Service业务层处理
+ * 
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Service
+public class AccessLogServiceImpl implements IAccessLogService 
+{
+    @Autowired
+    private AccessLogMapper accessLogMapper;
+
+    /**
+     * 查询进出学校记录
+     * 
+     * @param id 进出学校记录主键
+     * @return 进出学校记录
+     */
+    @Override
+    public AccessLog selectAccessLogById(Long id)
+    {
+        return accessLogMapper.selectAccessLogById(id);
+    }
+
+    /**
+     * 查询进出学校记录列表
+     * 
+     * @param accessLog 进出学校记录
+     * @return 进出学校记录
+     */
+    @Override
+    public List<AccessLog> selectAccessLogList(AccessLog accessLog)
+    {
+        return accessLogMapper.selectAccessLogList(accessLog);
+    }
+
+    /**
+     * 新增进出学校记录
+     * 
+     * @param accessLog 进出学校记录
+     * @return 结果
+     */
+    @Override
+    public int insertAccessLog(AccessLog accessLog)
+    {
+        accessLog.setCreateTime(DateUtils.getNowDate());
+        return accessLogMapper.insertAccessLog(accessLog);
+    }
+
+    /**
+     * 修改进出学校记录
+     * 
+     * @param accessLog 进出学校记录
+     * @return 结果
+     */
+    @Override
+    public int updateAccessLog(AccessLog accessLog)
+    {
+        accessLog.setUpdateTime(DateUtils.getNowDate());
+        return accessLogMapper.updateAccessLog(accessLog);
+    }
+
+    /**
+     * 批量删除进出学校记录
+     * 
+     * @param ids 需要删除的进出学校记录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteAccessLogByIds(Long[] ids)
+    {
+        return accessLogMapper.deleteAccessLogByIds(ids);
+    }
+
+    /**
+     * 删除进出学校记录信息
+     * 
+     * @param id 进出学校记录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteAccessLogById(Long id)
+    {
+        return accessLogMapper.deleteAccessLogById(id);
+    }
+}

+ 142 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/ClazzServiceImpl.java

@@ -0,0 +1,142 @@
+package com.schoolinout.system.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.schoolinout.common.exception.ServiceException;
+import com.schoolinout.common.utils.DateUtils;
+import com.schoolinout.common.utils.SecurityUtils;
+import com.schoolinout.common.utils.bean.BeanUtils;
+import com.schoolinout.system.domain.Clazz;
+import com.schoolinout.system.domain.dto.AddClassDto;
+import com.schoolinout.system.domain.dto.InsertTeacherClassRelationDto;
+import com.schoolinout.system.domain.vo.OptionVo;
+import com.schoolinout.system.mapper.ClazzMapper;
+import com.schoolinout.system.mapper.TeacherClassRelationMapper;
+import com.schoolinout.system.service.IClazzService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.rmi.ServerException;
+import java.util.Date;
+import java.util.List;
+import java.util.stream.Collectors;
+
+/**
+ * 班级管理Service业务层处理
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Service
+public class ClazzServiceImpl implements IClazzService {
+    @Autowired
+    private ClazzMapper clazzMapper;
+    @Autowired
+    private TeacherClassRelationMapper relationMapper;
+
+    /**
+     * 查询班级管理
+     *
+     * @param id 班级管理主键
+     * @return 班级管理
+     */
+    @Override
+    public Clazz selectClazzById(Long id) {
+        return clazzMapper.selectClazzById(id);
+    }
+
+    @Override
+    public List<OptionVo> selectClazzOptionList(Long schoolId) {
+        return clazzMapper.selectClazzOptionBySchoolId(schoolId);
+    }
+
+    /**
+     * 查询班级管理列表
+     *
+     * @param clazz 班级管理
+     * @return 班级管理
+     */
+    @Override
+    public List<Clazz> selectClazzList(Clazz clazz) {
+        return clazzMapper.selectClazzList(clazz);
+    }
+
+    /**
+     * 新增班级管理
+     *
+     * @param clazz 班级管理
+     * @return 结果
+     */
+    @Override
+    public int insertClazz(Clazz clazz) {
+        clazz.setCreateTime(DateUtils.getNowDate());
+        return clazzMapper.insertClazz(clazz);
+    }
+
+    /**
+     * 修改班级管理
+     *
+     * @param clazz 班级管理
+     * @return 结果
+     */
+    @Override
+    public int updateClazz(Clazz clazz) {
+        clazz.setUpdateTime(DateUtils.getNowDate());
+        return clazzMapper.updateClazz(clazz);
+    }
+
+    /**
+     * 批量删除班级管理
+     *
+     * @param ids 需要删除的班级管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteClazzByIds(Long[] ids) {
+        return clazzMapper.deleteClazzByIds(ids);
+    }
+
+    /**
+     * 删除班级管理信息
+     *
+     * @param id 班级管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteClazzById(Long id) {
+        return clazzMapper.deleteClazzById(id);
+    }
+
+    @Override
+    @Transactional(rollbackFor = {RuntimeException.class, ServerException.class})
+    public int saveClassAndRelation(AddClassDto form) {
+        // step1:查询当前学校,是否出现同名的班级
+        LambdaQueryWrapper<Clazz> wrapper = new LambdaQueryWrapper<Clazz>()
+                .eq(Clazz::getSchoolId, form.getSchoolId())
+                .eq(Clazz::getClassName, form.getClassName());
+        Clazz clazz = clazzMapper.selectOne(wrapper);
+        if (clazz != null) {
+            throw new ServiceException("当前学校已有同名的班级");
+        }
+        // step2:新增对应的班级
+        clazz = new Clazz();
+        BeanUtils.copyBeanProp(clazz, form);
+        // 插入数据
+        clazz.setCreateTime(new Date());
+        clazz.setCreateBy(SecurityUtils.getLoginUser().getUsername());
+        clazzMapper.insertClazz(clazz);
+
+        // step3:如果存在绑定老师,则新增关系的绑定
+        List<Long> teacherIds = form.getTeacherIds();
+        if (!teacherIds.isEmpty()) {
+            // 插入数据
+            Clazz finalClazz = clazz;
+            List<InsertTeacherClassRelationDto> insertList = teacherIds.stream()
+                    .map(item -> new InsertTeacherClassRelationDto(form.getSchoolId(), item, finalClazz.getId()))
+                    .collect(Collectors.toList());
+            return relationMapper.insertTeacherClassRelationBatch(insertList);
+        }
+
+        return 0;
+    }
+}

+ 96 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/SchoolServiceImpl.java

@@ -0,0 +1,96 @@
+package com.schoolinout.system.service.impl;
+
+import java.util.List;
+import com.schoolinout.common.utils.DateUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.schoolinout.system.mapper.SchoolMapper;
+import com.schoolinout.system.domain.School;
+import com.schoolinout.system.service.ISchoolService;
+
+/**
+ * 学校管理Service业务层处理
+ * 
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Service
+public class SchoolServiceImpl implements ISchoolService 
+{
+    @Autowired
+    private SchoolMapper schoolMapper;
+
+    /**
+     * 查询学校管理
+     * 
+     * @param id 学校管理主键
+     * @return 学校管理
+     */
+    @Override
+    public School selectSchoolById(Long id)
+    {
+        return schoolMapper.selectSchoolById(id);
+    }
+
+    /**
+     * 查询学校管理列表
+     * 
+     * @param school 学校管理
+     * @return 学校管理
+     */
+    @Override
+    public List<School> selectSchoolList(School school)
+    {
+        return schoolMapper.selectSchoolList(school);
+    }
+
+    /**
+     * 新增学校管理
+     * 
+     * @param school 学校管理
+     * @return 结果
+     */
+    @Override
+    public int insertSchool(School school)
+    {
+        school.setCreateTime(DateUtils.getNowDate());
+        return schoolMapper.insertSchool(school);
+    }
+
+    /**
+     * 修改学校管理
+     * 
+     * @param school 学校管理
+     * @return 结果
+     */
+    @Override
+    public int updateSchool(School school)
+    {
+        school.setUpdateTime(DateUtils.getNowDate());
+        return schoolMapper.updateSchool(school);
+    }
+
+    /**
+     * 批量删除学校管理
+     * 
+     * @param ids 需要删除的学校管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteSchoolByIds(Long[] ids)
+    {
+        return schoolMapper.deleteSchoolByIds(ids);
+    }
+
+    /**
+     * 删除学校管理信息
+     * 
+     * @param id 学校管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteSchoolById(Long id)
+    {
+        return schoolMapper.deleteSchoolById(id);
+    }
+}

+ 90 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/StudentServiceImpl.java

@@ -0,0 +1,90 @@
+package com.schoolinout.system.service.impl;
+
+import com.schoolinout.common.utils.DateUtils;
+import com.schoolinout.system.domain.Student;
+import com.schoolinout.system.mapper.StudentMapper;
+import com.schoolinout.system.service.IStudentService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ * 学生管理Service业务层处理
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Service
+public class StudentServiceImpl implements IStudentService {
+    @Autowired
+    private StudentMapper studentMapper;
+
+    /**
+     * 查询学生管理
+     *
+     * @param id 学生管理主键
+     * @return 学生管理
+     */
+    @Override
+    public Student selectStudentById(Long id) {
+        return studentMapper.selectStudentById(id);
+    }
+
+    /**
+     * 查询学生管理列表
+     *
+     * @param student 学生管理
+     * @return 学生管理
+     */
+    @Override
+    public List<Student> selectStudentList(Student student) {
+        return studentMapper.selectStudentList(student);
+    }
+
+    /**
+     * 新增学生管理
+     *
+     * @param student 学生管理
+     * @return 结果
+     */
+    @Override
+    public int insertStudent(Student student) {
+        student.setCreateTime(DateUtils.getNowDate());
+        return studentMapper.insertStudent(student);
+    }
+
+    /**
+     * 修改学生管理
+     *
+     * @param student 学生管理
+     * @return 结果
+     */
+    @Override
+    public int updateStudent(Student student) {
+        student.setUpdateTime(DateUtils.getNowDate());
+        return studentMapper.updateStudent(student);
+    }
+
+    /**
+     * 批量删除学生管理
+     *
+     * @param ids 需要删除的学生管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteStudentByIds(Long[] ids) {
+        return studentMapper.deleteStudentByIds(ids);
+    }
+
+    /**
+     * 删除学生管理信息
+     *
+     * @param id 学生管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteStudentById(Long id) {
+        return studentMapper.deleteStudentById(id);
+    }
+}

+ 27 - 31
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/SysDictDataServiceImpl.java

@@ -1,71 +1,66 @@
 package com.schoolinout.system.service.impl;
 
-import java.util.List;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
 import com.schoolinout.common.core.domain.entity.SysDictData;
 import com.schoolinout.common.utils.DictUtils;
 import com.schoolinout.system.mapper.SysDictDataMapper;
 import com.schoolinout.system.service.ISysDictDataService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
 
 /**
  * 字典 业务层处理
- * 
+ *
  * @author ruoyi
  */
 @Service
-public class SysDictDataServiceImpl implements ISysDictDataService
-{
+public class SysDictDataServiceImpl implements ISysDictDataService {
     @Autowired
     private SysDictDataMapper dictDataMapper;
 
     /**
      * 根据条件分页查询字典数据
-     * 
+     *
      * @param dictData 字典数据信息
      * @return 字典数据集合信息
      */
     @Override
-    public List<SysDictData> selectDictDataList(SysDictData dictData)
-    {
+    public List<SysDictData> selectDictDataList(SysDictData dictData) {
         return dictDataMapper.selectDictDataList(dictData);
     }
 
     /**
      * 根据字典类型和字典键值查询字典数据信息
-     * 
-     * @param dictType 字典类型
+     *
+     * @param dictType  字典类型
      * @param dictValue 字典键值
      * @return 字典标签
      */
     @Override
-    public String selectDictLabel(String dictType, String dictValue)
-    {
+    public String selectDictLabel(String dictType, String dictValue) {
         return dictDataMapper.selectDictLabel(dictType, dictValue);
     }
 
     /**
      * 根据字典数据ID查询信息
-     * 
+     *
      * @param dictCode 字典数据ID
      * @return 字典数据
      */
     @Override
-    public SysDictData selectDictDataById(Long dictCode)
-    {
+    public SysDictData selectDictDataById(Long dictCode) {
         return dictDataMapper.selectDictDataById(dictCode);
     }
 
     /**
      * 批量删除字典数据信息
-     * 
+     *
      * @param dictCodes 需要删除的字典数据ID
      */
     @Override
-    public void deleteDictDataByIds(Long[] dictCodes)
-    {
-        for (Long dictCode : dictCodes)
-        {
+    public void deleteDictDataByIds(Long[] dictCodes) {
+        for (Long dictCode : dictCodes) {
             SysDictData data = selectDictDataById(dictCode);
             dictDataMapper.deleteDictDataById(dictCode);
             List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(data.getDictType());
@@ -75,16 +70,14 @@ public class SysDictDataServiceImpl implements ISysDictDataService
 
     /**
      * 新增保存字典数据信息
-     * 
+     *
      * @param data 字典数据信息
      * @return 结果
      */
     @Override
-    public int insertDictData(SysDictData data)
-    {
+    public int insertDictData(SysDictData data) {
         int row = dictDataMapper.insertDictData(data);
-        if (row > 0)
-        {
+        if (row > 0) {
             List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(data.getDictType());
             DictUtils.setDictCache(data.getDictType(), dictDatas);
         }
@@ -93,19 +86,22 @@ public class SysDictDataServiceImpl implements ISysDictDataService
 
     /**
      * 修改保存字典数据信息
-     * 
+     *
      * @param data 字典数据信息
      * @return 结果
      */
     @Override
-    public int updateDictData(SysDictData data)
-    {
+    public int updateDictData(SysDictData data) {
         int row = dictDataMapper.updateDictData(data);
-        if (row > 0)
-        {
+        if (row > 0) {
             List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(data.getDictType());
             DictUtils.setDictCache(data.getDictType(), dictDatas);
         }
         return row;
     }
+
+    @Override
+    public List<SysDictData> queryTableDict(String tableName, String labelField, String valueField) {
+        return dictDataMapper.selectTableDictDataByTable(tableName, labelField, valueField);
+    }
 }

+ 114 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/TeacherClassRelationServiceImpl.java

@@ -0,0 +1,114 @@
+package com.schoolinout.system.service.impl;
+
+import com.schoolinout.common.exception.ServiceException;
+import com.schoolinout.common.utils.DateUtils;
+import com.schoolinout.system.domain.TeacherClassRelation;
+import com.schoolinout.system.domain.dto.AddTeacherClassRelationDto;
+import com.schoolinout.system.domain.dto.InsertTeacherClassRelationDto;
+import com.schoolinout.system.domain.vo.TeacherClassInfoVo;
+import com.schoolinout.system.mapper.TeacherClassRelationMapper;
+import com.schoolinout.system.service.ITeacherClassRelationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.List;
+import java.util.stream.Collectors;
+
+/**
+ * 老师-班级关系Service业务层处理
+ *
+ * @author sakura
+ * @date 2024-01-04
+ */
+@Service
+public class TeacherClassRelationServiceImpl implements ITeacherClassRelationService {
+    @Autowired
+    private TeacherClassRelationMapper teacherClassRelationMapper;
+
+    /**
+     * 查询老师-班级关系
+     *
+     * @param id 老师-班级关系主键
+     * @return 老师-班级关系
+     */
+    @Override
+    public TeacherClassRelation selectTeacherClassRelationById(Long id) {
+        return teacherClassRelationMapper.selectTeacherClassRelationById(id);
+    }
+
+    /**
+     * 查询老师-班级关系列表
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 老师-班级关系
+     */
+    @Override
+    public List<TeacherClassRelation> selectTeacherClassRelationList(TeacherClassRelation teacherClassRelation) {
+        return teacherClassRelationMapper.selectTeacherClassRelationList(teacherClassRelation);
+    }
+
+    /**
+     * 新增老师-班级关系
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 结果
+     */
+    @Override
+    public int insertTeacherClassRelation(TeacherClassRelation teacherClassRelation) {
+        teacherClassRelation.setCreateTime(DateUtils.getNowDate());
+        return teacherClassRelationMapper.insertTeacherClassRelation(teacherClassRelation);
+    }
+
+    /**
+     * 修改老师-班级关系
+     *
+     * @param teacherClassRelation 老师-班级关系
+     * @return 结果
+     */
+    @Override
+    public int updateTeacherClassRelation(TeacherClassRelation teacherClassRelation) {
+        teacherClassRelation.setUpdateTime(DateUtils.getNowDate());
+        return teacherClassRelationMapper.updateTeacherClassRelation(teacherClassRelation);
+    }
+
+    /**
+     * 批量删除老师-班级关系
+     *
+     * @param ids 需要删除的老师-班级关系主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTeacherClassRelationByIds(Long[] ids) {
+        return teacherClassRelationMapper.deleteTeacherClassRelationByIds(ids);
+    }
+
+    /**
+     * 删除老师-班级关系信息
+     *
+     * @param id 老师-班级关系主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTeacherClassRelationById(Long id) {
+        return teacherClassRelationMapper.deleteTeacherClassRelationById(id);
+    }
+
+    @Override
+    @Transactional(rollbackFor = {RuntimeException.class, ServiceException.class})
+    public int bindTeacherClass(AddTeacherClassRelationDto form) {
+        // step1:删除旧关系
+        teacherClassRelationMapper.deleteRelationBySchoolIdAndTeacherId(form.getSchoolId(), form.getTeacherId());
+        // step2:绑定对应的数据
+        // step3:返回响应结果
+        List<InsertTeacherClassRelationDto> insertList = form.getClassId().stream()
+                .map(classId -> new InsertTeacherClassRelationDto(form.getSchoolId(), form.getTeacherId(), classId))
+                .collect(Collectors.toList());
+        return teacherClassRelationMapper.insertTeacherClassRelationBatch(insertList);
+    }
+
+    @Override
+    public List<TeacherClassInfoVo> queryTeacherBindClassList(Long schoolId, Long teacherId) {
+        return teacherClassRelationMapper.selectTeacherClass(schoolId, teacherId, null);
+    }
+}

+ 96 - 0
school-in-out-system/src/main/java/com/schoolinout/system/service/impl/TeacherServiceImpl.java

@@ -0,0 +1,96 @@
+package com.schoolinout.system.service.impl;
+
+import com.schoolinout.common.utils.DateUtils;
+import com.schoolinout.system.domain.Teacher;
+import com.schoolinout.system.domain.vo.OptionVo;
+import com.schoolinout.system.mapper.TeacherMapper;
+import com.schoolinout.system.service.ITeacherService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ * 教师管理Service业务层处理
+ *
+ * @author sakura
+ * @date 2024-01-03
+ */
+@Service
+public class TeacherServiceImpl implements ITeacherService {
+    @Autowired
+    private TeacherMapper teacherMapper;
+
+    /**
+     * 查询教师管理
+     *
+     * @param id 教师管理主键
+     * @return 教师管理
+     */
+    @Override
+    public Teacher selectTeacherById(Long id) {
+        return teacherMapper.selectTeacherById(id);
+    }
+
+    /**
+     * 查询教师管理列表
+     *
+     * @param teacher 教师管理
+     * @return 教师管理
+     */
+    @Override
+    public List<Teacher> selectTeacherList(Teacher teacher) {
+        return teacherMapper.selectTeacherList(teacher);
+    }
+
+    /**
+     * 新增教师管理
+     *
+     * @param teacher 教师管理
+     * @return 结果
+     */
+    @Override
+    public int insertTeacher(Teacher teacher) {
+        teacher.setCreateTime(DateUtils.getNowDate());
+        return teacherMapper.insertTeacher(teacher);
+    }
+
+    /**
+     * 修改教师管理
+     *
+     * @param teacher 教师管理
+     * @return 结果
+     */
+    @Override
+    public int updateTeacher(Teacher teacher) {
+        teacher.setUpdateTime(DateUtils.getNowDate());
+        return teacherMapper.updateTeacher(teacher);
+    }
+
+    /**
+     * 批量删除教师管理
+     *
+     * @param ids 需要删除的教师管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTeacherByIds(Long[] ids) {
+        return teacherMapper.deleteTeacherByIds(ids);
+    }
+
+    /**
+     * 删除教师管理信息
+     *
+     * @param id 教师管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTeacherById(Long id) {
+        return teacherMapper.deleteTeacherById(id);
+    }
+
+    @Override
+    public List<OptionVo> selectTeacherOptionList(Long schoolId) {
+        return teacherMapper.selectTeacherOption(schoolId);
+    }
+}

+ 86 - 0
school-in-out-system/src/main/resources/mapper/system/AccessLogMapper.xml

@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.schoolinout.system.mapper.AccessLogMapper">
+    
+    <resultMap type="AccessLog" id="AccessLogResult">
+        <result property="id"    column="id"    />
+        <result property="studentId"    column="student_id"    />
+        <result property="inTime"    column="in_time"    />
+        <result property="outTime"    column="out_time"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectAccessLogVo">
+        select id, student_id, in_time, out_time, del_flag, create_by, create_time, update_by, update_time from tb_school_access_log
+    </sql>
+
+    <select id="selectAccessLogList" parameterType="AccessLog" resultMap="AccessLogResult">
+        <include refid="selectAccessLogVo"/>
+        <where>  
+            <if test="studentId != null "> and student_id = #{studentId}</if>
+            <if test="inTime != null "> and in_time = #{inTime}</if>
+            <if test="outTime != null "> and out_time = #{outTime}</if>
+        </where>
+    </select>
+    
+    <select id="selectAccessLogById" parameterType="Long" resultMap="AccessLogResult">
+        <include refid="selectAccessLogVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertAccessLog" parameterType="AccessLog" useGeneratedKeys="true" keyProperty="id">
+        insert into tb_school_access_log
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="studentId != null">student_id,</if>
+            <if test="inTime != null">in_time,</if>
+            <if test="outTime != null">out_time,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="studentId != null">#{studentId},</if>
+            <if test="inTime != null">#{inTime},</if>
+            <if test="outTime != null">#{outTime},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updateAccessLog" parameterType="AccessLog">
+        update tb_school_access_log
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="studentId != null">student_id = #{studentId},</if>
+            <if test="inTime != null">in_time = #{inTime},</if>
+            <if test="outTime != null">out_time = #{outTime},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteAccessLogById" parameterType="Long">
+        delete from tb_school_access_log where id = #{id}
+    </delete>
+
+    <delete id="deleteAccessLogByIds" parameterType="String">
+        delete from tb_school_access_log where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 124 - 0
school-in-out-system/src/main/resources/mapper/system/ClazzMapper.xml

@@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.schoolinout.system.mapper.ClazzMapper">
+
+    <resultMap type="Clazz" id="ClazzResult">
+        <result property="id" column="id"/>
+        <result property="schoolId" column="school_id"/>
+        <result property="className" column="class_name"/>
+        <result property="classCount" column="class_count"/>
+        <result property="phone" column="phone"/>
+        <result property="teacherName" column="teacher_name"/>
+        <result property="delFlag" column="del_flag"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+    <sql id="selectClazzVo">
+        select id,
+               school_id,
+               class_name,
+               class_count,
+               phone,
+               del_flag,
+               create_by,
+               create_time,
+               update_by,
+               update_time
+        from tb_school_class
+    </sql>
+
+    <select id="selectClazzList" parameterType="Clazz" resultMap="ClazzResult">
+        select tb_school_class.id,
+        tb_school_class.school_id,
+        tb_school_class.class_name,
+        tb_school_class.class_count,
+        tb_school_class.phone,
+        teacher.teacher_name,
+        tb_school_class.del_flag,
+        tb_school_class.create_by,
+        tb_school_class.create_time,
+        tb_school_class.update_by,
+        tb_school_class.update_time
+        from tb_school_class
+        LEFT JOIN tb_school_teacher_class_relation relation on tb_school_class.school_id = relation.school_id AND
+        relation.teacher_main = 'Y'
+        LEFT JOIN tb_school_teacher teacher on relation.teacher_id = teacher.id
+        <where>
+            <if test="schoolId != null ">and school_id = #{schoolId}</if>
+            <if test="className != null  and className != ''">and class_name like concat('%', #{className}, '%')</if>
+            <if test="classCount != null ">and class_count = #{classCount}</if>
+            <if test="phone != null  and phone != ''">and phone = #{phone}</if>
+        </where>
+    </select>
+
+    <select id="selectClazzById" parameterType="Long" resultMap="ClazzResult">
+        <include refid="selectClazzVo"/>
+        where id = #{id}
+    </select>
+    <select id="selectClazzOptionBySchoolId" resultType="com.schoolinout.system.domain.vo.OptionVo">
+        SELECT id         as value,
+               class_name as label
+        FROM tb_school_class
+        where school_id = #{schoolId}
+    </select>
+
+    <insert id="insertClazz" parameterType="Clazz" useGeneratedKeys="true" keyProperty="id">
+        insert into tb_school_class
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">school_id,</if>
+            <if test="className != null and className != ''">class_name,</if>
+            <if test="classCount != null">class_count,</if>
+            <if test="phone != null">phone,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">#{schoolId},</if>
+            <if test="className != null and className != ''">#{className},</if>
+            <if test="classCount != null">#{classCount},</if>
+            <if test="phone != null">#{phone},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+        </trim>
+    </insert>
+
+    <update id="updateClazz" parameterType="Clazz">
+        update tb_school_class
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="schoolId != null">school_id = #{schoolId},</if>
+            <if test="className != null and className != ''">class_name = #{className},</if>
+            <if test="classCount != null">class_count = #{classCount},</if>
+            <if test="phone != null">phone = #{phone},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteClazzById" parameterType="Long">
+        delete
+        from tb_school_class
+        where id = #{id}
+    </delete>
+
+    <delete id="deleteClazzByIds" parameterType="String">
+        delete from tb_school_class where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 104 - 0
school-in-out-system/src/main/resources/mapper/system/SchoolMapper.xml

@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.schoolinout.system.mapper.SchoolMapper">
+
+    <resultMap type="School" id="SchoolResult">
+        <result property="id" column="id"/>
+        <result property="schoolName" column="school_name"/>
+        <result property="schoolAddress" column="school_address"/>
+        <result property="linkName" column="link_name"/>
+        <result property="linkPhone" column="link_phone"/>
+        <result property="delFlag" column="del_flag"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+    <sql id="selectSchoolVo">
+        select id,
+               school_name,
+               school_address,
+               link_name,
+               link_phone,
+               del_flag,
+               create_by,
+               create_time,
+               update_by,
+               update_time
+        from tb_school
+    </sql>
+
+    <select id="selectSchoolList" parameterType="School" resultMap="SchoolResult">
+        <include refid="selectSchoolVo"/>
+        <where>
+            <if test="schoolName != null  and schoolName != ''">and school_name like concat('%', #{schoolName}, '%')
+            </if>
+            <if test="schoolAddress != null  and schoolAddress != ''">and school_address = #{schoolAddress}</if>
+            <if test="linkName != null  and linkName != ''">and link_name like concat('%', #{linkName}, '%')</if>
+            <if test="linkPhone != null  and linkPhone != ''">and link_phone = #{linkPhone}</if>
+        </where>
+    </select>
+
+    <select id="selectSchoolById" parameterType="Long" resultMap="SchoolResult">
+        <include refid="selectSchoolVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertSchool" parameterType="School" useGeneratedKeys="true" keyProperty="id">
+        insert into tb_school
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="schoolName != null and schoolName != ''">school_name,</if>
+            <if test="schoolAddress != null and schoolAddress != ''">school_address,</if>
+            <if test="linkName != null and linkName != ''">link_name,</if>
+            <if test="linkPhone != null and linkPhone != ''">link_phone,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="schoolName != null and schoolName != ''">#{schoolName},</if>
+            <if test="schoolAddress != null and schoolAddress != ''">#{schoolAddress},</if>
+            <if test="linkName != null and linkName != ''">#{linkName},</if>
+            <if test="linkPhone != null and linkPhone != ''">#{linkPhone},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+        </trim>
+    </insert>
+
+    <update id="updateSchool" parameterType="School">
+        update tb_school
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="schoolName != null and schoolName != ''">school_name = #{schoolName},</if>
+            <if test="schoolAddress != null and schoolAddress != ''">school_address = #{schoolAddress},</if>
+            <if test="linkName != null and linkName != ''">link_name = #{linkName},</if>
+            <if test="linkPhone != null and linkPhone != ''">link_phone = #{linkPhone},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteSchoolById" parameterType="Long">
+        delete
+        from tb_school
+        where id = #{id}
+    </delete>
+
+    <delete id="deleteSchoolByIds" parameterType="String">
+        delete from tb_school where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 100 - 0
school-in-out-system/src/main/resources/mapper/system/StudentMapper.xml

@@ -0,0 +1,100 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.schoolinout.system.mapper.StudentMapper">
+    
+    <resultMap type="Student" id="StudentResult">
+        <result property="id"    column="id"    />
+        <result property="schoolId"    column="school_id"    />
+        <result property="classId"    column="class_id"    />
+        <result property="studentName"    column="student_name"    />
+        <result property="studentPic"    column="student_pic"    />
+        <result property="studentGender"    column="student_gender"    />
+        <result property="studentNum"    column="student_num"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectStudentVo">
+        select id, school_id, class_id, student_name, student_pic, student_gender, student_num, del_flag, create_by, create_time, update_by, update_time from tb_school_student
+    </sql>
+
+    <select id="selectStudentList" parameterType="Student" resultMap="StudentResult">
+        <include refid="selectStudentVo"/>
+        <where>  
+            <if test="schoolId != null "> and school_id = #{schoolId}</if>
+            <if test="classId != null "> and class_id = #{classId}</if>
+            <if test="studentName != null  and studentName != ''"> and student_name like concat('%', #{studentName}, '%')</if>
+            <if test="studentGender != null  and studentGender != ''"> and student_gender = #{studentGender}</if>
+            <if test="studentNum != null  and studentNum != ''"> and student_num like concat('%', #{studentNum}, '%')</if>
+        </where>
+    </select>
+    
+    <select id="selectStudentById" parameterType="Long" resultMap="StudentResult">
+        <include refid="selectStudentVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertStudent" parameterType="Student" useGeneratedKeys="true" keyProperty="id">
+        insert into tb_school_student
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">school_id,</if>
+            <if test="classId != null">class_id,</if>
+            <if test="studentName != null and studentName != ''">student_name,</if>
+            <if test="studentPic != null and studentPic != ''">student_pic,</if>
+            <if test="studentGender != null">student_gender,</if>
+            <if test="studentNum != null">student_num,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">#{schoolId},</if>
+            <if test="classId != null">#{classId},</if>
+            <if test="studentName != null and studentName != ''">#{studentName},</if>
+            <if test="studentPic != null and studentPic != ''">#{studentPic},</if>
+            <if test="studentGender != null">#{studentGender},</if>
+            <if test="studentNum != null">#{studentNum},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updateStudent" parameterType="Student">
+        update tb_school_student
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="schoolId != null">school_id = #{schoolId},</if>
+            <if test="classId != null">class_id = #{classId},</if>
+            <if test="studentName != null and studentName != ''">student_name = #{studentName},</if>
+            <if test="studentPic != null and studentPic != ''">student_pic = #{studentPic},</if>
+            <if test="studentGender != null">student_gender = #{studentGender},</if>
+            <if test="studentNum != null">student_num = #{studentNum},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteStudentById" parameterType="Long">
+        delete from tb_school_student where id = #{id}
+    </delete>
+
+    <delete id="deleteStudentByIds" parameterType="String">
+        delete from tb_school_student where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 144 - 118
school-in-out-system/src/main/resources/mapper/system/SysDictDataMapper.xml

@@ -1,124 +1,150 @@
 <?xml version="1.0" encoding="UTF-8" ?>
 <!DOCTYPE mapper
-PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
-"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.schoolinout.system.mapper.SysDictDataMapper">
-	
-	<resultMap type="SysDictData" id="SysDictDataResult">
-		<id     property="dictCode"   column="dict_code"   />
-		<result property="dictSort"   column="dict_sort"   />
-		<result property="dictLabel"  column="dict_label"  />
-		<result property="dictValue"  column="dict_value"  />
-		<result property="dictType"   column="dict_type"   />
-		<result property="cssClass"   column="css_class"   />
-		<result property="listClass"  column="list_class"  />
-		<result property="isDefault"  column="is_default"  />
-		<result property="status"     column="status"      />
-		<result property="createBy"   column="create_by"   />
-		<result property="createTime" column="create_time" />
-		<result property="updateBy"   column="update_by"   />
-		<result property="updateTime" column="update_time" />
-	</resultMap>
-	
-	<sql id="selectDictDataVo">
-        select dict_code, dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, remark 
-		from sys_dict_data
+
+    <resultMap type="SysDictData" id="SysDictDataResult">
+        <id property="dictCode" column="dict_code"/>
+        <result property="dictSort" column="dict_sort"/>
+        <result property="dictLabel" column="dict_label"/>
+        <result property="dictValue" column="dict_value"/>
+        <result property="dictType" column="dict_type"/>
+        <result property="cssClass" column="css_class"/>
+        <result property="listClass" column="list_class"/>
+        <result property="isDefault" column="is_default"/>
+        <result property="status" column="status"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+    <sql id="selectDictDataVo">
+        select dict_code,
+               dict_sort,
+               dict_label,
+               dict_value,
+               dict_type,
+               css_class,
+               list_class,
+               is_default,
+               status,
+               create_by,
+               create_time,
+               remark
+        from sys_dict_data
     </sql>
 
-	<select id="selectDictDataList" parameterType="SysDictData" resultMap="SysDictDataResult">
-	    <include refid="selectDictDataVo"/>
-		<where>
-		    <if test="dictType != null and dictType != ''">
-				AND dict_type = #{dictType}
-			</if>
-			<if test="dictLabel != null and dictLabel != ''">
-				AND dict_label like concat('%', #{dictLabel}, '%')
-			</if>
-			<if test="status != null and status != ''">
-				AND status = #{status}
-			</if>
-		</where>
-		order by dict_sort asc
-	</select>
-	
-	<select id="selectDictDataByType" parameterType="SysDictData" resultMap="SysDictDataResult">
-		<include refid="selectDictDataVo"/>
-		where status = '0' and dict_type = #{dictType} order by dict_sort asc
-	</select>
-	
-	<select id="selectDictLabel" resultType="String">
-		select dict_label from sys_dict_data
-		where dict_type = #{dictType} and dict_value = #{dictValue}
-	</select>
-	
-	<select id="selectDictDataById" parameterType="Long" resultMap="SysDictDataResult">
-		<include refid="selectDictDataVo"/>
-		where dict_code = #{dictCode}
-	</select>
-	
-	<select id="countDictDataByType" resultType="Integer">
-	    select count(1) from sys_dict_data where dict_type=#{dictType}  
-	</select>
-	
-	<delete id="deleteDictDataById" parameterType="Long">
- 		delete from sys_dict_data where dict_code = #{dictCode}
- 	</delete>
- 	
- 	<delete id="deleteDictDataByIds" parameterType="Long">
- 		delete from sys_dict_data where dict_code in
- 		<foreach collection="array" item="dictCode" open="(" separator="," close=")">
- 			#{dictCode}
-        </foreach> 
- 	</delete>
-	
-	<update id="updateDictData" parameterType="SysDictData">
- 		update sys_dict_data
- 		<set>
- 			<if test="dictSort != null">dict_sort = #{dictSort},</if>
- 			<if test="dictLabel != null and dictLabel != ''">dict_label = #{dictLabel},</if>
- 			<if test="dictValue != null and dictValue != ''">dict_value = #{dictValue},</if>
- 			<if test="dictType != null and dictType != ''">dict_type = #{dictType},</if>
- 			<if test="cssClass != null">css_class = #{cssClass},</if>
- 			<if test="listClass != null">list_class = #{listClass},</if>
- 			<if test="isDefault != null and isDefault != ''">is_default = #{isDefault},</if>
- 			<if test="status != null">status = #{status},</if>
- 			<if test="remark != null">remark = #{remark},</if>
- 			<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
- 			update_time = sysdate()
- 		</set>
- 		where dict_code = #{dictCode}
-	</update>
-	
-	<update id="updateDictDataType" parameterType="String">
- 		update sys_dict_data set dict_type = #{newDictType} where dict_type = #{oldDictType}
-	</update>
- 	
- 	<insert id="insertDictData" parameterType="SysDictData">
- 		insert into sys_dict_data(
- 			<if test="dictSort != null">dict_sort,</if>
- 			<if test="dictLabel != null and dictLabel != ''">dict_label,</if>
- 			<if test="dictValue != null and dictValue != ''">dict_value,</if>
- 			<if test="dictType != null and dictType != ''">dict_type,</if>
- 			<if test="cssClass != null and cssClass != ''">css_class,</if>
- 			<if test="listClass != null and listClass != ''">list_class,</if>
- 			<if test="isDefault != null and isDefault != ''">is_default,</if>
- 			<if test="status != null">status,</if>
- 			<if test="remark != null and remark != ''">remark,</if>
- 			<if test="createBy != null and createBy != ''">create_by,</if>
- 			create_time
- 		)values(
- 		    <if test="dictSort != null">#{dictSort},</if>
- 		    <if test="dictLabel != null and dictLabel != ''">#{dictLabel},</if>
- 			<if test="dictValue != null and dictValue != ''">#{dictValue},</if>
- 			<if test="dictType != null and dictType != ''">#{dictType},</if>
- 			<if test="cssClass != null and cssClass != ''">#{cssClass},</if>
- 			<if test="listClass != null and listClass != ''">#{listClass},</if>
- 			<if test="isDefault != null and isDefault != ''">#{isDefault},</if>
- 			<if test="status != null">#{status},</if>
- 			<if test="remark != null and remark != ''">#{remark},</if>
- 			<if test="createBy != null and createBy != ''">#{createBy},</if>
- 			sysdate()
- 		)
-	</insert>
-	
+    <select id="selectDictDataList" parameterType="SysDictData" resultMap="SysDictDataResult">
+        <include refid="selectDictDataVo"/>
+        <where>
+            <if test="dictType != null and dictType != ''">
+                AND dict_type = #{dictType}
+            </if>
+            <if test="dictLabel != null and dictLabel != ''">
+                AND dict_label like concat('%', #{dictLabel}, '%')
+            </if>
+            <if test="status != null and status != ''">
+                AND status = #{status}
+            </if>
+        </where>
+        order by dict_sort asc
+    </select>
+
+    <select id="selectDictDataByType" parameterType="SysDictData" resultMap="SysDictDataResult">
+        <include refid="selectDictDataVo"/>
+        where status = '0' and dict_type = #{dictType} order by dict_sort asc
+    </select>
+
+    <select id="selectDictLabel" resultType="String">
+        select dict_label
+        from sys_dict_data
+        where dict_type = #{dictType}
+          and dict_value = #{dictValue}
+    </select>
+
+    <select id="selectDictDataById" parameterType="Long" resultMap="SysDictDataResult">
+        <include refid="selectDictDataVo"/>
+        where dict_code = #{dictCode}
+    </select>
+
+    <select id="countDictDataByType" resultType="Integer">
+        select count(1)
+        from sys_dict_data
+        where dict_type = #{dictType}
+    </select>
+    <select id="selectTableDictDataByTable" resultType="com.schoolinout.common.core.domain.entity.SysDictData">
+        select ${labelField} as dict_label,
+               ${valueField} as dict_value,
+               'primary'     as list_class,
+               ''            as css_class
+        FROM ${tableName}
+    </select>
+
+    <delete id="deleteDictDataById" parameterType="Long">
+        delete
+        from sys_dict_data
+        where dict_code = #{dictCode}
+    </delete>
+
+    <delete id="deleteDictDataByIds" parameterType="Long">
+        delete from sys_dict_data where dict_code in
+        <foreach collection="array" item="dictCode" open="(" separator="," close=")">
+            #{dictCode}
+        </foreach>
+    </delete>
+
+    <update id="updateDictData" parameterType="SysDictData">
+        update sys_dict_data
+        <set>
+            <if test="dictSort != null">dict_sort = #{dictSort},</if>
+            <if test="dictLabel != null and dictLabel != ''">dict_label = #{dictLabel},</if>
+            <if test="dictValue != null and dictValue != ''">dict_value = #{dictValue},</if>
+            <if test="dictType != null and dictType != ''">dict_type = #{dictType},</if>
+            <if test="cssClass != null">css_class = #{cssClass},</if>
+            <if test="listClass != null">list_class = #{listClass},</if>
+            <if test="isDefault != null and isDefault != ''">is_default = #{isDefault},</if>
+            <if test="status != null">status = #{status},</if>
+            <if test="remark != null">remark = #{remark},</if>
+            <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
+            update_time = sysdate()
+        </set>
+        where dict_code = #{dictCode}
+    </update>
+
+    <update id="updateDictDataType" parameterType="String">
+        update sys_dict_data
+        set dict_type = #{newDictType}
+        where dict_type = #{oldDictType}
+    </update>
+
+    <insert id="insertDictData" parameterType="SysDictData">
+        insert into sys_dict_data(
+        <if test="dictSort != null">dict_sort,</if>
+        <if test="dictLabel != null and dictLabel != ''">dict_label,</if>
+        <if test="dictValue != null and dictValue != ''">dict_value,</if>
+        <if test="dictType != null and dictType != ''">dict_type,</if>
+        <if test="cssClass != null and cssClass != ''">css_class,</if>
+        <if test="listClass != null and listClass != ''">list_class,</if>
+        <if test="isDefault != null and isDefault != ''">is_default,</if>
+        <if test="status != null">status,</if>
+        <if test="remark != null and remark != ''">remark,</if>
+        <if test="createBy != null and createBy != ''">create_by,</if>
+        create_time
+        )values(
+        <if test="dictSort != null">#{dictSort},</if>
+        <if test="dictLabel != null and dictLabel != ''">#{dictLabel},</if>
+        <if test="dictValue != null and dictValue != ''">#{dictValue},</if>
+        <if test="dictType != null and dictType != ''">#{dictType},</if>
+        <if test="cssClass != null and cssClass != ''">#{cssClass},</if>
+        <if test="listClass != null and listClass != ''">#{listClass},</if>
+        <if test="isDefault != null and isDefault != ''">#{isDefault},</if>
+        <if test="status != null">#{status},</if>
+        <if test="remark != null and remark != ''">#{remark},</if>
+        <if test="createBy != null and createBy != ''">#{createBy},</if>
+        sysdate()
+        )
+    </insert>
+
 </mapper> 

+ 138 - 0
school-in-out-system/src/main/resources/mapper/system/TeacherClassRelationMapper.xml

@@ -0,0 +1,138 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.schoolinout.system.mapper.TeacherClassRelationMapper">
+
+    <resultMap type="TeacherClassRelation" id="TeacherClassRelationResult">
+        <result property="id" column="id"/>
+        <result property="schoolId" column="school_id"/>
+        <result property="teacherId" column="teacher_id"/>
+        <result property="classId" column="class_id"/>
+        <result property="teacherMain" column="teacher_main"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+    <sql id="selectTeacherClassRelationVo">
+        select id,
+               school_id,
+               teacher_id,
+               class_id,
+               teacher_main,
+               create_by,
+               create_time,
+               update_by,
+               update_time
+        from tb_school_teacher_class_relation
+    </sql>
+
+    <select id="selectTeacherClassRelationList" parameterType="TeacherClassRelation"
+            resultMap="TeacherClassRelationResult">
+        <include refid="selectTeacherClassRelationVo"/>
+        <where>
+            <if test="schoolId != null ">and school_id = #{schoolId}</if>
+            <if test="teacherId != null ">and teacher_id = #{teacherId}</if>
+            <if test="classId != null ">and class_id = #{classId}</if>
+            <if test="teacherMain != null  and teacherMain != ''">and teacher_main = #{teacherMain}</if>
+        </where>
+    </select>
+
+    <select id="selectTeacherClassRelationById" parameterType="Long" resultMap="TeacherClassRelationResult">
+        <include refid="selectTeacherClassRelationVo"/>
+        where id = #{id}
+    </select>
+    <select id="selectTeacherClass" resultType="com.schoolinout.system.domain.vo.TeacherClassInfoVo">
+        SELECT
+        id,
+        relation.teacher_id,
+        relation.class_id,
+        relation.school_id,
+        relation.teacher_main,
+        class.class_name,
+        teacher.teacher_name,
+        FROM tb_school_teacher_class_relation relation
+        JOIN tb_school_class class ON relation.class_id = class.id
+        JOIN tb_school_teacher teacher ON relation.school_id = teacher.school_id
+        <where>
+            <if test="schoolId != null">
+                AND relation.school_id = #{schoolId}
+            </if>
+            <if test="teacherId != null">
+                AND relation.teacher_id = #{teacherId}
+            </if>
+            <if test="schoolId != null">
+                AND relation.class_id = #{classId}
+            </if>
+        </where>
+    </select>
+
+
+    <insert id="insertTeacherClassRelation" parameterType="TeacherClassRelation" useGeneratedKeys="true"
+            keyProperty="id">
+        insert into tb_school_teacher_class_relation
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">school_id,</if>
+            <if test="teacherId != null">teacher_id,</if>
+            <if test="classId != null">class_id,</if>
+            <if test="teacherMain != null">teacher_main,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">#{schoolId},</if>
+            <if test="teacherId != null">#{teacherId},</if>
+            <if test="classId != null">#{classId},</if>
+            <if test="teacherMain != null">#{teacherMain},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+        </trim>
+    </insert>
+    <insert id="insertTeacherClassRelationBatch">
+        INSERT INTO tb_school_teacher_class_relation(school_id, teacher_id, class_id)
+        VALUES
+        <foreach collection="list" item="item" separator=",">
+            (#{item.schoolId}, #{item.teacherId}, #{item.classId})
+        </foreach>
+    </insert>
+
+    <update id="updateTeacherClassRelation" parameterType="TeacherClassRelation">
+        update tb_school_teacher_class_relation
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="schoolId != null">school_id = #{schoolId},</if>
+            <if test="teacherId != null">teacher_id = #{teacherId},</if>
+            <if test="classId != null">class_id = #{classId},</if>
+            <if test="teacherMain != null">teacher_main = #{teacherMain},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteTeacherClassRelationById" parameterType="Long">
+        delete
+        from tb_school_teacher_class_relation
+        where id = #{id}
+    </delete>
+
+    <delete id="deleteTeacherClassRelationByIds" parameterType="String">
+        delete from tb_school_teacher_class_relation where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+    <delete id="deleteRelationBySchoolIdAndTeacherId">
+        DELETE
+        FROM tb_school_teacher_class_relation
+        WHERE school_id = #{schoolId}
+          AND teacher_id = #{teacherId}
+    </delete>
+</mapper>

+ 111 - 0
school-in-out-system/src/main/resources/mapper/system/TeacherMapper.xml

@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.schoolinout.system.mapper.TeacherMapper">
+
+    <resultMap type="Teacher" id="TeacherResult">
+        <result property="id" column="id"/>
+        <result property="schoolId" column="school_id"/>
+        <result property="teacherName" column="teacher_name"/>
+        <result property="gender" column="gender"/>
+        <result property="phone" column="phone"/>
+        <result property="delFlag" column="del_flag"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+    </resultMap>
+
+    <sql id="selectTeacherVo">
+        select id,
+               school_id,
+               teacher_name,
+               gender,
+               phone,
+               del_flag,
+               create_by,
+               create_time,
+               update_by,
+               update_time
+        from tb_school_teacher
+    </sql>
+
+    <select id="selectTeacherList" parameterType="Teacher" resultMap="TeacherResult">
+        <include refid="selectTeacherVo"/>
+        <where>
+            <if test="schoolId != null ">and school_id = #{schoolId}</if>
+            <if test="teacherName != null  and teacherName != ''">and teacher_name like concat('%', #{teacherName},
+                '%')
+            </if>
+            <if test="gender != null  and gender != ''">and gender = #{gender}</if>
+            <if test="phone != null  and phone != ''">and phone like concat('%', #{phone}, '%')</if>
+        </where>
+    </select>
+
+    <select id="selectTeacherById" parameterType="Long" resultMap="TeacherResult">
+        <include refid="selectTeacherVo"/>
+        where id = #{id}
+    </select>
+    <select id="selectTeacherOption" resultType="com.schoolinout.system.domain.vo.OptionVo">
+        SELECT id           as value,
+               teacher_name as label
+        FROM tb_school_teacher
+        where school_id = #{schoolId}
+    </select>
+
+    <insert id="insertTeacher" parameterType="Teacher" useGeneratedKeys="true" keyProperty="id">
+        insert into tb_school_teacher
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">school_id,</if>
+            <if test="teacherName != null and teacherName != ''">teacher_name,</if>
+            <if test="gender != null and gender != ''">gender,</if>
+            <if test="phone != null and phone != ''">phone,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="schoolId != null">#{schoolId},</if>
+            <if test="teacherName != null and teacherName != ''">#{teacherName},</if>
+            <if test="gender != null and gender != ''">#{gender},</if>
+            <if test="phone != null and phone != ''">#{phone},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+        </trim>
+    </insert>
+
+    <update id="updateTeacher" parameterType="Teacher">
+        update tb_school_teacher
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="schoolId != null">school_id = #{schoolId},</if>
+            <if test="teacherName != null and teacherName != ''">teacher_name = #{teacherName},</if>
+            <if test="gender != null and gender != ''">gender = #{gender},</if>
+            <if test="phone != null and phone != ''">phone = #{phone},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteTeacherById" parameterType="Long">
+        delete
+        from tb_school_teacher
+        where id = #{id}
+    </delete>
+
+    <delete id="deleteTeacherByIds" parameterType="String">
+        delete from tb_school_teacher where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 1 - 0
school-in-out-ui/src/App.vue

@@ -25,4 +25,5 @@ export default {
 #app .theme-picker {
   display: none;
 }
+
 </style>

+ 44 - 0
school-in-out-ui/src/api/system/access_log.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询进出学校记录列表
+export function listAccess_log(query) {
+  return request({
+    url: '/system/access_log/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询进出学校记录详细
+export function getAccess_log(id) {
+  return request({
+    url: '/system/access_log/' + id,
+    method: 'get'
+  })
+}
+
+// 新增进出学校记录
+export function addAccess_log(data) {
+  return request({
+    url: '/system/access_log',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改进出学校记录
+export function updateAccess_log(data) {
+  return request({
+    url: '/system/access_log',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除进出学校记录
+export function delAccess_log(id) {
+  return request({
+    url: '/system/access_log/' + id,
+    method: 'delete'
+  })
+}

+ 53 - 0
school-in-out-ui/src/api/system/clazz.js

@@ -0,0 +1,53 @@
+import request from '@/utils/request'
+
+// 查询班级管理列表
+export function listClazz(query) {
+  return request({
+    url: '/system/clazz/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询班级下拉列表
+export function listClazzOption(schoolId) {
+  return request({
+    url: '/system/clazz/option/' + schoolId,
+    method: 'get',
+  })
+}
+
+
+// 查询班级管理详细
+export function getClazz(id) {
+  return request({
+    url: '/system/clazz/' + id,
+    method: 'get'
+  })
+}
+
+// 新增班级管理
+export function addClazz(data) {
+  return request({
+    url: '/system/clazz',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改班级管理
+export function updateClazz(data) {
+  return request({
+    url: '/system/clazz',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除班级管理
+export function delClazz(id) {
+  return request({
+    url: '/system/clazz/' + id,
+    method: 'delete'
+  })
+}

+ 8 - 0
school-in-out-ui/src/api/system/dict/data.js

@@ -25,6 +25,14 @@ export function getDicts(dictType) {
   })
 }
 
+// 根据table获取数据
+export function getTableDicts(code) {
+  return request({
+    url: '/system/dict/data/table/' + code,
+    method: 'get'
+  })
+}
+
 // 新增字典数据
 export function addData(data) {
   return request({

+ 44 - 0
school-in-out-ui/src/api/system/school.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询学校管理列表
+export function listSchool(query) {
+  return request({
+    url: '/system/school/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询学校管理详细
+export function getSchool(id) {
+  return request({
+    url: '/system/school/' + id,
+    method: 'get'
+  })
+}
+
+// 新增学校管理
+export function addSchool(data) {
+  return request({
+    url: '/system/school',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改学校管理
+export function updateSchool(data) {
+  return request({
+    url: '/system/school',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除学校管理
+export function delSchool(id) {
+  return request({
+    url: '/system/school/' + id,
+    method: 'delete'
+  })
+}

+ 44 - 0
school-in-out-ui/src/api/system/student.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询学生管理列表
+export function listStudent(query) {
+  return request({
+    url: '/system/student/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询学生管理详细
+export function getStudent(id) {
+  return request({
+    url: '/system/student/' + id,
+    method: 'get'
+  })
+}
+
+// 新增学生管理
+export function addStudent(data) {
+  return request({
+    url: '/system/student',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改学生管理
+export function updateStudent(data) {
+  return request({
+    url: '/system/student',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除学生管理
+export function delStudent(id) {
+  return request({
+    url: '/system/student/' + id,
+    method: 'delete'
+  })
+}

+ 52 - 0
school-in-out-ui/src/api/system/teacher.js

@@ -0,0 +1,52 @@
+import request from '@/utils/request'
+
+// 查询教师管理列表
+export function listTeacher(query) {
+  return request({
+    url: '/system/teacher/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询教师下拉列表
+export function listTeacherOption(schoolId) {
+  return request({
+    url: '/system/teacher/option/' + schoolId,
+    method: 'get',
+  })
+}
+
+// 查询教师管理详细
+export function getTeacher(id) {
+  return request({
+    url: '/system/teacher/' + id,
+    method: 'get'
+  })
+}
+
+// 新增教师管理
+export function addTeacher(data) {
+  return request({
+    url: '/system/teacher',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改教师管理
+export function updateTeacher(data) {
+  return request({
+    url: '/system/teacher',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除教师管理
+export function delTeacher(id) {
+  return request({
+    url: '/system/teacher/' + id,
+    method: 'delete'
+  })
+}

Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
school-in-out-ui/src/assets/icons/svg/clazz.svg


Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
school-in-out-ui/src/assets/icons/svg/ic_student.svg


+ 1 - 0
school-in-out-ui/src/assets/icons/svg/ic_teacher.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1704264664491" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4466" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M941.681778 221.724444h-233.216a25.230222 25.230222 0 0 1-25.400889-25.543111c0-14.279111 11.178667-25.514667 25.400889-25.514666h233.216c14.222222 0 25.400889 11.235556 25.400889 25.514666a25.230222 25.230222 0 0 1-25.400889 25.543111z m-21.333334 161.336889H740.977778a25.230222 25.230222 0 0 1-25.400889-25.543111c0-14.279111 11.178667-25.514667 25.400889-25.514666h179.370666c14.222222 0 25.400889 11.235556 25.400889 25.514666a25.230222 25.230222 0 0 1-25.400889 25.543111z m-150.414222 434.460445l124.501334-322.673778a25.6 25.6 0 0 1 33.024-14.791111c13.198222 5.091556 19.797333 19.911111 15.729777 33.678222L797.895111 890.026667a24.462222 24.462222 0 0 1-8.135111 10.723555c0 1.024 0.512 2.048 0.512 3.043556a59.904 59.904 0 0 1-14.734222 44.401778 56.120889 56.120889 0 0 1-42.183111 18.915555H114.033778a57.230222 57.230222 0 0 1-42.183111-18.915555c-11.178667-11.719111-16.241778-28.074667-14.734223-44.401778 14.734222-152.632889 117.873778-275.171556 254.549334-319.089778a215.04 215.04 0 0 1-100.096-182.243556c0-118.471111 94.520889-214.954667 211.370666-214.954666 116.337778 0 211.342222 96.483556 211.342223 214.954666a215.580444 215.580444 0 0 1-100.096 182.243556c109.738667 35.242667 197.660444 121.514667 235.747555 232.817778z" p-id="4467" fill="#e6e6e6"></path></svg>

+ 1 - 0
school-in-out-ui/src/assets/icons/svg/parent-fill.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1704252786493" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6911" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M298.666667 469.333333a192 192 0 1 1 0-384 192 192 0 0 1 0 384z m448 170.666667a170.666667 170.666667 0 1 1 0-341.333333 170.666667 170.666667 0 0 1 0 341.333333z m0 42.666667a192 192 0 0 1 192 192v21.333333h-384v-21.333333a192 192 0 0 1 192-192zM298.666667 512a213.333333 213.333333 0 0 1 213.333333 213.333333v170.666667H85.333333v-170.666667a213.333333 213.333333 0 0 1 213.333334-213.333333z" p-id="6912"></path></svg>

+ 1 - 0
school-in-out-ui/src/assets/icons/svg/school.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1704262866708" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4491" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M512 128l470.016 256 0 342.016-86.016 0 0-296.021333-384 210.005333-470.016-256zM214.016 562.005333l297.984 164.010667 297.984-164.010667 0 171.989333-297.984 162.005333-297.984-162.005333 0-171.989333z" fill="#ffffff" p-id="4492"></path></svg>

BIN
school-in-out-ui/src/assets/images/bind.png


+ 16 - 0
school-in-out-ui/src/assets/styles/ruoyi.scss

@@ -289,3 +289,19 @@
   position: relative;
   float: right;
 }
+.omit {
+  white-space: nowrap;
+  text-overflow: ellipsis;
+  overflow: hidden;
+}
+
+// bind icon
+.el-icon-bind{
+  background: url('../images/bind.png') center center no-repeat;
+  font-size: 12px;
+  background-size: cover;
+}
+.el-icon-bind:before{
+  content: "11";
+  visibility: hidden;
+}

+ 7 - 4
school-in-out-ui/src/components/DictTag/index.vue

@@ -1,13 +1,13 @@
 <template>
   <div>
     <template v-for="(item, index) in options">
-      <template v-if="values.includes(item.value)">
+      <template v-if="values.includes(item.value + '')">
         <span
           v-if="(item.raw.listClass == 'default' || item.raw.listClass == '') && (item.raw.cssClass == '' || item.raw.cssClass == null)"
           :key="item.value"
           :index="index"
           :class="item.raw.cssClass"
-          >{{ item.label + ' ' }}</span
+          >{{ item.label +''}}</span
         >
         <el-tag
           v-else
@@ -22,7 +22,7 @@
       </template>
     </template>
     <template v-if="unmatch && showValue">
-      {{ unmatchArray | handleArray }}
+      {{ unmatchArray | handleArray }} ajja
     </template>
   </div>
 </template>
@@ -51,9 +51,12 @@ export default {
       unmatchArray: [], // 记录未匹配的项
     }
   },
+  mounted() {
+  },
   computed: {
     values() {
       if (this.value === null || typeof this.value === 'undefined' || this.value === '') return []
+
       return Array.isArray(this.value) ? this.value.map(item => '' + item) : String(this.value).split(this.separator)
     },
     unmatch() {
@@ -63,7 +66,7 @@ export default {
       // 传入值为数组
       let unmatch = false // 添加一个标志来判断是否有未匹配项
       this.values.forEach(item => {
-        if (!this.options.some(v => v.value === item)) {
+        if (!this.options.some(v => v.value == item)) {
           this.unmatchArray.push(item)
           unmatch = true // 如果有未匹配项,将标志设置为true
         }

+ 24 - 0
school-in-out-ui/src/mixin/Textyixia.js

@@ -0,0 +1,24 @@
+import {
+    getTableDicts
+} from '@/api/system/dict/data'
+import dictConverter from '@/utils/dict/DictConverter'
+
+export default {
+    methods: {
+        dictTableData(param) {
+            
+            return getTableDicts(param).then(res => {
+                const dataArr = [];
+                res.data.map(item => {
+                    let a = dictConverter({
+                        value: parseInt(item.dictValue),
+                        label: item.dictLabel
+                    }, item)
+                    dataArr.push(a)
+                })
+
+                return dataArr;
+            })
+        }
+    },
+}

+ 7 - 3
school-in-out-ui/src/utils/auth.js

@@ -3,13 +3,17 @@ import Cookies from 'js-cookie'
 const TokenKey = 'Admin-Token'
 
 export function getToken() {
-  return Cookies.get(TokenKey)
+  return Cookies.get(TokenKey) || localStorage.getItem(TokenKey);
 }
 
 export function setToken(token) {
-  return Cookies.set(TokenKey, token)
+  Cookies.set(TokenKey, token)
+  localStorage.setItem(TokenKey, token)
+  return;
 }
 
 export function removeToken() {
-  return Cookies.remove(TokenKey)
+  Cookies.remove(TokenKey)
+  localStorage.removeItem(TokenKey)
+  return;
 }

+ 291 - 0
school-in-out-ui/src/views/system/access_log/index.vue

@@ -0,0 +1,291 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="到校时间" prop="inTime">
+        <el-date-picker clearable
+          v-model="queryParams.inTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="请选择到校时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="离校时间" prop="outTime">
+        <el-date-picker clearable
+          v-model="queryParams.outTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="请选择离校时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:access_log:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:access_log:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:access_log:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:access_log:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="access_logList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="id" align="center" prop="id" />
+      <el-table-column label="学生id" align="center" prop="studentId" />
+      <el-table-column label="到校时间" align="center" prop="inTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.inTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="离校时间" align="center" prop="outTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.outTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:access_log:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:access_log:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+    
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改进出学校记录对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="到校时间" prop="inTime">
+          <el-date-picker clearable
+            v-model="form.inTime"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="请选择到校时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="离校时间" prop="outTime">
+          <el-date-picker clearable
+            v-model="form.outTime"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="请选择离校时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="删除标志" prop="delFlag">
+          <el-input v-model="form.delFlag" placeholder="请输入删除标志" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listAccess_log, getAccess_log, delAccess_log, addAccess_log, updateAccess_log } from "@/api/system/access_log";
+
+export default {
+  name: "Access_log",
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 进出学校记录表格数据
+      access_logList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        studentId: null,
+        inTime: null,
+        outTime: null,
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        studentId: [
+          { required: true, message: "学生id不能为空", trigger: "change" }
+        ],
+      }
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    /** 查询进出学校记录列表 */
+    getList() {
+      this.loading = true;
+      listAccess_log(this.queryParams).then(response => {
+        this.access_logList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        studentId: null,
+        inTime: null,
+        outTime: null,
+        delFlag: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加进出学校记录";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getAccess_log(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改进出学校记录";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateAccess_log(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addAccess_log(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否确认删除进出学校记录编号为"' + ids + '"的数据项?').then(function() {
+        return delAccess_log(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('system/access_log/export', {
+        ...this.queryParams
+      }, `access_log_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 266 - 0
school-in-out-ui/src/views/system/clazz/index.vue

@@ -0,0 +1,266 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="所属学校" prop="schoolId">
+        <el-select v-model="queryParams.schoolId" placeholder="请选择学校" style="width: 100%;">
+            <el-option v-for="dict in dictTables.schoolDict" :key="dict.value" :label="dict.label"
+              :value="dict.value"></el-option>
+          </el-select>
+      </el-form-item>
+      <el-form-item label="班级名称" prop="className">
+        <el-input
+          v-model="queryParams.className"
+          placeholder="请输入班级名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="班级人数" prop="classCount">
+        <el-input
+          v-model="queryParams.classCount"
+          placeholder="请输入班级人数"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:clazz:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:clazz:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:clazz:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:clazz:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="clazzList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="序号" type="index" align="center"/>
+       <!-- todo 显示 学校名称 -->
+       <el-table-column label="所属学校" align="center">
+        <template slot-scope="scope">
+          <dict-tag :options="dictTables.schoolDict" :value="scope.row.schoolId" />
+        </template>
+      </el-table-column>
+      <el-table-column label="班级名称" align="center" prop="className" />
+      <el-table-column label="班主任" align="center" prop="teacherName" />
+      <el-table-column label="班级人数" align="center" prop="classCount" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:clazz:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:clazz:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+    
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <clazz-form
+      ref="clazzForm"
+      @submit="submitForm"
+      @cancel="cancel"
+    ></clazz-form>
+  </div>
+</template>
+
+<script>
+import { listClazz, getClazz, delClazz, addClazz, updateClazz } from "@/api/system/clazz";
+import ClazzForm from "./module/ClazzForm";
+import Textyixia from "@/mixin/Textyixia"
+export default {
+  name: "Clazz",
+  mixins: [Textyixia],
+  components: {
+    ClazzForm
+  },
+  data() {
+    return {
+      dictTables: {
+        schoolDict: []
+      },
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 班级管理表格数据
+      clazzList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        schoolId: null,
+        className: null,
+        classCount: null,
+        phone: null,
+      },
+      // 表单参数
+      form: {},
+     
+    };
+  },
+  created() {
+    this.getList();
+    this.dictTableData("tb_school,school_name,id").then(data => {
+      this.dictTables.schoolDict = data
+    })
+  },
+  methods: {
+    /** 查询班级管理列表 */
+    getList() {
+      this.loading = true;
+      listClazz(this.queryParams).then(response => {
+        this.clazzList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.$refs.clazzForm.open = false
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.$refs.clazzForm.reset()
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.$refs.clazzForm.open = true
+      this.$refs.clazzForm.title = "添加班级";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getClazz(id).then(response => {
+        this.$refs.clazzForm.form = response.data;
+        this.$refs.clazzForm.open = true
+        this.$refs.clazzForm.title = "修改班级信息";
+        this.$refs.clazzForm.searchTeacherOption(true);
+        this.$refs.clazzForm.schoolOptions = this.dictTables.schoolDict
+      });
+    },
+    /** 提交按钮 */
+    submitForm(data) {
+      if (data.id != null) {
+          updateClazz(data).then(response => {
+            this.$modal.msgSuccess("修改成功");
+            this.$refs.clazzForm.open = false
+            this.getList();
+          });
+        } else {
+          addClazz(data).then(response => {
+            this.$modal.msgSuccess("新增成功");
+            this.$refs.clazzForm.open = false
+            this.getList();
+          });
+        }
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否确认删除班级管理编号为"' + ids + '"的数据项?').then(function() {
+        return delClazz(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('system/clazz/export', {
+        ...this.queryParams
+      }, `clazz_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 153 - 0
school-in-out-ui/src/views/system/clazz/module/ClazzForm.vue

@@ -0,0 +1,153 @@
+<template>
+    <div class="box">
+        <!-- 添加或修改班级管理对话框 -->
+        <el-dialog :title="title" :close-on-click-modal="false" :visible.sync="open" width="500px" append-to-body>
+            <el-form ref="Cform" :model="form" :rules="rules" label-width="80px">
+                <el-form-item label="所属学校" prop="schoolId">
+                    <el-select 
+                        v-model="form.schoolId" 
+                        :loading="schoolLoading" 
+                        loading-text="正在加载中~~~"
+                        @visible-change="searchSchoolOption" 
+                        placeholder="请选择学校" style="width: 100%;">
+                        <el-option v-for="dict in schoolOptions" :key="dict.value" :label="dict.label"
+                        :value="dict.value"></el-option>
+                    </el-select>
+                </el-form-item>
+                <el-form-item label="绑定教师" prop="teacherIds">
+                    <el-select 
+                        v-model="form.teacherIds" 
+                        :disabled="!form.schoolId" 
+                        :loading="teacherLoaging" 
+                        loading-text="正在加载中~~~"
+                        :reserve-keyword="true" 
+                        multiple
+                        @visible-change="searchTeacherOption" 
+                        :placeholder="!form.schoolId ?'请先选择学校' : '请选择教师'"
+                        style="width: 100%;">
+                        <el-option 
+                            v-for="item in teacherOptions"
+                            :key="item.value"
+                            :label="item.label"
+                            :value="item.value">
+                        </el-option>
+                    </el-select>
+                </el-form-item>
+                <el-form-item label="班级名称" prop="className">
+                    <el-input v-model="form.className" placeholder="请输入班级名称" />
+                </el-form-item>
+                <el-form-item label="班级人数" prop="classCount">
+                    <el-input v-model.number="form.classCount" autocomplete="off" placeholder="请输入班级人数" />
+                </el-form-item>
+                <el-form-item label="班级电话" prop="phone">
+                    <el-input v-model="form.phone" placeholder="请输入班级电话" />
+                </el-form-item>
+                
+            </el-form>
+            <div slot="footer" class="dialog-footer">
+                <el-button type="primary" @click="submitForm">确 定</el-button>
+                <el-button @click="cancel">取 消</el-button>
+            </div>
+        </el-dialog>
+    </div>
+</template>
+
+<script>
+import Textyixia from "@/mixin/Textyixia"
+import { listTeacherOption } from '@/api/system/teacher'
+
+export default {
+    name: 'ClazzForm',
+    mixins: [Textyixia],
+    data() {
+        return {
+            open: false,
+            title: '',
+            // 教师下拉框数据
+            teacherOptions: [],
+            teacherLoaging: false,
+            // 学校下拉框数据
+            schoolOptions: [],
+            schoolLoading: false,
+            form: {},
+             // 表单校验
+            rules: {
+              schoolId: [
+                { required: true, message: "学校id不能为空", trigger: "change" }
+              ],
+              className: [
+                { required: true, message: "班级名称不能为空", trigger: "blur" }
+              ],
+              classCount: [
+                { required: true, message: "班级人数不能为空", trigger: "blur" }
+              ],
+            }
+        }
+    },  
+   
+    methods: {
+        /** 搜索当前学校教师的列表 */
+        searchTeacherOption(openSelect) {
+            if (openSelect) {
+                this.teacherLoaging = true;
+                // 根据id去查询对应的学校教师
+                listTeacherOption(this.form.schoolId).then(res => {
+                    this.teacherOptions = res.data
+                    this.teacherLoaging = false
+                })
+            }
+        },
+        /** 搜索当前平台拥有的学校 */
+        searchSchoolOption(openSelect) {
+            if (openSelect) {
+                this.schoolLoading = true
+                this.dictTableData("tb_school,school_name,id").then(data => {
+                    this.schoolOptions = data
+                    this.schoolLoading = false
+                })
+            }
+            
+        },
+        submitForm() {
+            this.$refs.Cform.validate(isOK=>{
+                if(isOK){
+                    console.log(this.form);
+            this.$emit('submit', this.form);
+                }else{
+                    console.log('====');
+                }
+               
+            })
+           
+        },
+        cancel() {
+            this.$emit('cancel');
+        },
+        // 重置表单
+        reset(){
+            this.form = {
+                id: null,
+                schoolId: null,
+                className: null,
+                classCount: null,
+                phone: null,
+                delFlag: null,
+                createBy: null,
+                createTime: null,
+                updateBy: null,
+                updateTime: null
+      };
+             this.resetForm("form");
+        }
+    }
+}
+</script>
+                
+}
+</script>
+
+<style lang="scss" scoped>
+.box {
+    margin-top: 10px;
+}
+</style>

+ 312 - 0
school-in-out-ui/src/views/system/school/index.vue

@@ -0,0 +1,312 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="学校名称" prop="schoolName">
+        <el-input
+          v-model="queryParams.schoolName"
+          placeholder="请输入学校名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="学校地址" prop="schoolAddress">
+        <el-input
+          v-model="queryParams.schoolAddress"
+          placeholder="请输入学校地址"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="联系人" prop="linkName">
+        <el-input
+          v-model="queryParams.linkName"
+          placeholder="请输入联系人"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="电话" prop="linkPhone">
+        <el-input
+          v-model="queryParams.linkPhone"
+          placeholder="请输入联系人电话"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:school:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:school:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:school:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:school:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="schoolList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column type="index" label="序号" align="center" />
+      <el-table-column label="学校名称" align="center" prop="schoolName" />
+      <el-table-column label="学校地址" align="center" prop="schoolAddress" >
+        <template v-slot="{row}">
+          <div class="omit" :title="row.schoolAddress">
+            {{ row.schoolAddress }}
+          </div>
+        </template>
+      </el-table-column>
+      <el-table-column label="联系人" align="center" prop="linkName" />
+      <el-table-column label="联系人电话" align="center" prop="linkPhone" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:school:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:school:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+    
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改学校管理对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="550px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" :label-width="labelWidth">
+        <el-form-item label="学校名称" prop="schoolName">
+          <el-input v-model="form.schoolName" placeholder="请输入学校名称" />
+        </el-form-item>
+        <el-form-item label="学校地址" prop="schoolAddress">
+          <el-input v-model="form.schoolAddress" placeholder="请输入学校地址"  />
+        </el-form-item>
+        <el-form-item label="联系人" prop="linkName">
+          <el-input v-model="form.linkName" placeholder="请输入联系人" />
+        </el-form-item>
+        <el-form-item label="联系人电话" prop="linkPhone">
+          <el-input v-model="form.linkPhone" placeholder="请输入联系人电话" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listSchool, getSchool, delSchool, addSchool, updateSchool } from "@/api/system/school";
+
+export default {
+  name: "School",
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 学校管理表格数据
+      schoolList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        schoolName: null,
+        schoolAddress: null,
+        linkName: null,
+        linkPhone: null,
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        schoolName: [
+          { required: true, message: "学校名称不能为空", trigger: "blur" }
+        ],
+        schoolAddress: [
+          { required: true, message: "学校地址不能为空", trigger: "blur" }
+        ],
+        linkName: [
+          { required: true, message: "联系人不能为空", trigger: "blur" }
+        ],
+        linkPhone: [
+          { required: true, message: "联系人电话不能为空", trigger: "blur" },
+          { pattern: /^1[34578]\d{9}$/, message: "请输入正确的联系人电话", trigger: "blur" }
+        ],
+      },
+      labelWidth: "100px",
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    /** 查询学校管理列表 */
+    getList() {
+      this.loading = true;
+      listSchool(this.queryParams).then(response => {
+        this.schoolList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        schoolName: null,
+        schoolAddress: null,
+        linkName: null,
+        linkPhone: null,
+        delFlag: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加学校管理";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getSchool(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改学校管理";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateSchool(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addSchool(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否确认删除学校管理编号为"' + ids + '"的数据项?').then(function() {
+        return delSchool(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('system/school/export', {
+        ...this.queryParams
+      }, `school_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 322 - 0
school-in-out-ui/src/views/system/student/index.vue

@@ -0,0 +1,322 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="学生名称" prop="studentName">
+        <el-input
+          v-model="queryParams.studentName"
+          placeholder="请输入学生名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="学生性别" prop="studentGender">
+        <el-select v-model="queryParams.studentGender" placeholder="请选择学生性别" clearable>
+          <el-option
+            v-for="dict in dict.type.sys_user_sex"
+            :key="dict.value"
+            :label="dict.label"
+            :value="dict.value"
+          />
+        </el-select>
+      </el-form-item>
+      <el-form-item label="学号" prop="studentNum">
+        <el-input
+          v-model="queryParams.studentNum"
+          placeholder="请输入学号"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:student:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:student:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:student:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:student:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="studentList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="id" align="center" prop="id" />
+      <el-table-column label="学校id" align="center" prop="schoolId" />
+      <el-table-column label="班级id" align="center" prop="classId" />
+      <el-table-column label="学生名称" align="center" prop="studentName" />
+      <el-table-column label="学生照片" align="center" prop="studentPic" width="100">
+        <template slot-scope="scope">
+          <image-preview :src="scope.row.studentPic" :width="50" :height="50"/>
+        </template>
+      </el-table-column>
+      <el-table-column label="学生性别" align="center" prop="studentGender">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.studentGender"/>
+        </template>
+      </el-table-column>
+      <el-table-column label="学号" align="center" prop="studentNum" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:student:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:student:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+    
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改学生管理对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="学生名称" prop="studentName">
+          <el-input v-model="form.studentName" placeholder="请输入学生名称" />
+        </el-form-item>
+        <el-form-item label="学生照片" prop="studentPic">
+          <image-upload v-model="form.studentPic"/>
+        </el-form-item>
+        <el-form-item label="学生性别" prop="studentGender">
+          <el-select v-model="form.studentGender" placeholder="请选择学生性别">
+            <el-option
+              v-for="dict in dict.type.sys_user_sex"
+              :key="dict.value"
+              :label="dict.label"
+              :value="dict.value"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="学号" prop="studentNum">
+          <el-input v-model="form.studentNum" placeholder="请输入学号" />
+        </el-form-item>
+        <el-form-item label="删除标志" prop="delFlag">
+          <el-input v-model="form.delFlag" placeholder="请输入删除标志" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listStudent, getStudent, delStudent, addStudent, updateStudent } from "@/api/system/student";
+
+export default {
+  name: "Student",
+  dicts: ['sys_user_sex'],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 学生管理表格数据
+      studentList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        schoolId: null,
+        classId: null,
+        studentName: null,
+        studentGender: null,
+        studentNum: null,
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        schoolId: [
+          { required: true, message: "学校id不能为空", trigger: "change" }
+        ],
+        classId: [
+          { required: true, message: "班级id不能为空", trigger: "change" }
+        ],
+        studentName: [
+          { required: true, message: "学生名称不能为空", trigger: "blur" }
+        ],
+        studentPic: [
+          { required: true, message: "学生照片不能为空", trigger: "blur" }
+        ],
+      }
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    /** 查询学生管理列表 */
+    getList() {
+      this.loading = true;
+      listStudent(this.queryParams).then(response => {
+        this.studentList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        schoolId: null,
+        classId: null,
+        studentName: null,
+        studentPic: null,
+        studentGender: null,
+        studentNum: null,
+        delFlag: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加学生管理";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getStudent(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改学生管理";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateStudent(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addStudent(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否确认删除学生管理编号为"' + ids + '"的数据项?').then(function() {
+        return delStudent(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('system/student/export', {
+        ...this.queryParams
+      }, `student_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 328 - 0
school-in-out-ui/src/views/system/teacher/index.vue

@@ -0,0 +1,328 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="老师姓名" prop="teacherName">
+        <el-input v-model="queryParams.teacherName" placeholder="请输入老师姓名" clearable @keyup.enter.native="handleQuery" />
+      </el-form-item>
+      <el-form-item label="性别" prop="gender">
+        <el-select v-model="queryParams.gender" placeholder="请选择性别" clearable>
+          <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label" :value="dict.value" />
+        </el-select>
+      </el-form-item>
+      <el-form-item label="联系电话" prop="phone">
+        <el-input v-model="queryParams.phone" placeholder="请输入联系电话" clearable @keyup.enter.native="handleQuery" />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
+          v-hasPermi="['system:teacher:add']">新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
+          v-hasPermi="['system:teacher:edit']">修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
+          v-hasPermi="['system:teacher:remove']">删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
+          v-hasPermi="['system:teacher:export']">导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="teacherList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="序号" align="center" type="index" />
+      <!-- todo 显示 学校名称 -->
+      <el-table-column label="所属学校" align="center">
+        <template slot-scope="scope">
+          <dict-tag :options="dictTables.schoolDict" :value="scope.row.schoolId" />
+        </template>
+      </el-table-column>
+
+      <el-table-column label="老师姓名" align="center" prop="teacherName" />
+      <el-table-column label="性别" align="center" prop="gender">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.gender" />
+        </template>
+      </el-table-column>
+      <el-table-column label="联系电话" align="center" prop="phone" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:teacher:edit']">修改</el-button>
+          <el-button size="mini" type="text" @click="handleBindClass(scope.row)">
+            <i class="el-icon-bind"></i>
+            绑定班级
+          </el-button>
+          <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
+            v-hasPermi="['system:teacher:remove']">删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
+      @pagination="getList" />
+
+    <!-- 添加或修改教师管理对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="所属学校" prop="schoolId">
+          <el-select v-model="form.schoolId" placeholder="请选择学校" style="width: 100%;">
+            <el-option v-for="dict in dictTables.schoolDict" :key="dict.value" :label="dict.label"
+              :value="dict.value"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="老师姓名" prop="teacherName">
+          <el-input v-model="form.teacherName" placeholder="请输入老师姓名" />
+        </el-form-item>
+        <el-form-item label="性别" prop="gender">
+          <el-select v-model="form.gender" placeholder="请选择性别" style="width: 100%;">
+            <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label"
+              :value="dict.value"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="联系电话" prop="phone">
+          <el-input v-model="form.phone" placeholder="请输入联系电话" />
+        </el-form-item>
+
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 绑定班级对话框 -->
+    <el-dialog title="绑定班级" :visible.sync="classVisible" width="30%" center>
+      <el-form label-position="right" label-width="80px" :model="bindClassTeacherForm">
+        <el-form-item label="老师姓名" prop="teacherName">
+          <el-input v-model="bindClassTeacherForm.teacherName" disabled placeholder="请输入老师姓名" />
+        </el-form-item>
+        <el-form-item label="所属学校" prop="schoolId">
+          <el-select v-model="bindClassTeacherForm.schoolId" disabled placeholder="请选择学校" style="width: 100%;">
+            <el-option v-for="dict in dictTables.schoolDict" :key="dict.value" :label="dict.label"
+              :value="dict.value"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="绑定班级" prop="classId">
+          <el-select v-model="bindClassTeacherForm.classId" :loading="bindOptionLoding" loading-text="正在加载中~~~"
+            reserve-keyword @visible-change="searchClassOption" placeholder="请选择班级" style="width: 100%;">
+            <el-option v-for="item in clazzOption" :key="item.value" :label="item.label" :value="item.value"></el-option>
+          </el-select>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="centerDialogVisible = false">取 消</el-button>
+        <el-button type="primary" @click="centerDialogVisible = false">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listTeacher, getTeacher, delTeacher, addTeacher, updateTeacher } from "@/api/system/teacher";
+import { listClazzOption } from '@/api/system/clazz'
+import Textyixia from "@/mixin/Textyixia"
+export default {
+  name: "Teacher",
+  mixins: [Textyixia],
+  dicts: ['sys_user_sex'],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 教师管理表格数据
+      teacherList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      classVisible: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        schoolId: null,
+        teacherName: null,
+        gender: null,
+        phone: null,
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        schoolId: [
+          { required: true, message: "学校id不能为空", trigger: "change" }
+        ],
+        teacherName: [
+          { required: true, message: "老师姓名不能为空", trigger: "blur" }
+        ],
+        gender: [
+          { required: true, message: "性别;0男   1女不能为空", trigger: "change" }
+        ],
+        phone: [
+          { required: true, message: "联系电话不能为空", trigger: "blur" }
+        ],
+      },
+      dictTables: {
+        schoolDict: [],
+        classDict: []
+      },
+      // 绑定班级和教师表单对象
+      bindClassTeacherForm: {},
+      // 班级下拉列表
+      clazzOption: [],
+      bindOptionLoding: false
+    };
+  },
+  created() {
+    this.getList();
+    this.dictTableData("tb_school,school_name,id").then(data => {
+      this.dictTables.schoolDict = data
+    })
+    // this.dictTableData("tb_school_class,class_name,id").then(data => {
+    //   this.dictTables.schoolDict = data
+    // })
+  },
+  methods: {
+    /** 查询教师管理列表 */
+    getList() {
+      this.loading = true;
+      listTeacher(this.queryParams).then(response => {
+        this.teacherList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        schoolId: null,
+        teacherName: null,
+        gender: null,
+        phone: null,
+        delFlag: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length !== 1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加教师管理";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getTeacher(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改教师管理";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateTeacher(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addTeacher(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否确认删除教师管理编号为"' + ids + '"的数据项?').then(function () {
+        return delTeacher(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => { });
+    },
+    /** 绑定班级按钮操作 */
+    handleBindClass(row) {
+      // this.reset();
+      this.classVisible = true
+      this.bindClassTeacherForm = row
+      // 先发请求去获取对应学校的班级 获取成功后,返回对应的班级列表
+      // listClazzOption().then(response => {
+      //   this.clazzOption = response.data
+      // })
+    },
+    /** 懒加载班级列表 */
+    searchClassOption(openSelect) {
+      if (openSelect) {
+        this.bindOptionLoding = true
+        listClazzOption(this.bindClassTeacherForm.schoolId).then(response => {
+          console.log(response);
+          this.clazzOption = response.data
+          this.bindOptionLoding = false
+        })
+      }
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('system/teacher/export', {
+        ...this.queryParams
+      }, `teacher_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 111 - 0
sql/school_in_out_db.sql

@@ -0,0 +1,111 @@
+CREATE TABLE tb_school
+(
+    id             BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    school_name    VARCHAR(255)    NOT NULL COMMENT '学校名称',
+    school_address VARCHAR(255)    NOT NULL COMMENT '学校地址',
+    link_name      VARCHAR(60)     NOT NULL COMMENT '联系人',
+    link_phone     VARCHAR(60)     NOT NULL COMMENT '联系人电话',
+    del_flag       CHAR(1)     DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
+    create_by      VARCHAR(64) DEFAULT '' COMMENT '创建者',
+    create_time    datetime COMMENT '创建时间',
+    update_by      VARCHAR(64) DEFAULT '' COMMENT '更新者',
+    update_time    datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '学校';
+
+CREATE TABLE tb_school_teacher
+(
+    id           BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    school_id    BIGINT UNSIGNED NOT NULL COMMENT '学校id',
+    teacher_name VARCHAR(255)    NOT NULL COMMENT '老师姓名',
+    gender       CHAR(1)         NOT NULL DEFAULT '0' COMMENT '性别;0男   1女',
+    phone        VARCHAR(60)     NOT NULL COMMENT '联系电话',
+    del_flag     CHAR(1)                  DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
+    create_by    VARCHAR(64)              DEFAULT '' COMMENT '创建者',
+    create_time  datetime COMMENT '创建时间',
+    update_by    VARCHAR(64)              DEFAULT '' COMMENT '更新者',
+    update_time  datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '教师';
+
+CREATE TABLE tb_school_class
+(
+    id          BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    school_id   BIGINT UNSIGNED NOT NULL COMMENT '学校id',
+    class_name  VARCHAR(255)    NOT NULL COMMENT '班级名称',
+    class_count INT             NOT NULL DEFAULT 0 COMMENT '班级人数',
+    phone       VARCHAR(60) COMMENT '班级电话',
+    del_flag    CHAR(1)                  DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
+    create_by   VARCHAR(64)              DEFAULT '' COMMENT '创建者',
+    create_time datetime COMMENT '创建时间',
+    update_by   VARCHAR(64)              DEFAULT '' COMMENT '更新者',
+    update_time datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '班级';
+
+CREATE TABLE tb_school_teacher_class_relation
+(
+    id           BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    school_id    BIGINT UNSIGNED NOT NULL COMMENT '学校id',
+    teacher_id   BIGINT UNSIGNED NOT NULL COMMENT '教师id',
+    class_id     BIGINT UNSIGNED NOT NULL COMMENT '班级id',
+    teacher_main CHAR(1)     DEFAULT 'N' COMMENT '是否为班主任',
+    create_by    VARCHAR(64) DEFAULT '' COMMENT '创建者',
+    create_time  datetime COMMENT '创建时间',
+    update_by    VARCHAR(64) DEFAULT '' COMMENT '更新者',
+    update_time  datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '老师-班级关系表';
+
+CREATE TABLE tb_school_student
+(
+    id             BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    school_id      BIGINT UNSIGNED NOT NULL COMMENT '学校id',
+    class_id       BIGINT UNSIGNED NOT NULL COMMENT '班级id',
+    student_name   VARCHAR(60)     NOT NULL COMMENT '学生名称',
+    student_pic    VARCHAR(60)     NOT NULL COMMENT '学生照片',
+    student_gender CHAR(1)     DEFAULT '0' COMMENT '学生性别',
+    student_num    VARCHAR(255) COMMENT '学号',
+    del_flag       CHAR(1)     DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
+    create_by      VARCHAR(64) DEFAULT '' COMMENT '创建者',
+    create_time    datetime COMMENT '创建时间',
+    update_by      VARCHAR(64) DEFAULT '' COMMENT '更新者',
+    update_time    datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '学生表';
+
+CREATE TABLE tb_school_parent
+(
+    id           BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    student_id   BIGINT UNSIGNED NOT NULL COMMENT '学生id',
+    parent_name  VARCHAR(60)     NOT NULL COMMENT '家长姓名',
+    parent_phone VARCHAR(60)     NOT NULL COMMENT '家长电话',
+    relation     CHAR(3)         NOT NULL DEFAULT '99' COMMENT '与学生的关系',
+    del_flag     CHAR(1)                  DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
+    create_by    VARCHAR(64)              DEFAULT '' COMMENT '创建者',
+    create_time  datetime COMMENT '创建时间',
+    update_by    VARCHAR(64)              DEFAULT '' COMMENT '更新者',
+    update_time  datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '家长表';
+
+CREATE TABLE tb_school_access_log
+(
+    id          BIGINT UNSIGNED NOT NULL auto_increment COMMENT 'id',
+    student_id  BIGINT UNSIGNED NOT NULL COMMENT '学生id',
+    in_time     datetime COMMENT '到校时间',
+    out_time    datetime COMMENT '离校时间',
+    del_flag    CHAR(1)     DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
+    create_by   VARCHAR(64) DEFAULT '' COMMENT '创建者',
+    create_time datetime COMMENT '创建时间',
+    update_by   VARCHAR(64) DEFAULT '' COMMENT '更新者',
+    update_time datetime COMMENT '更新时间',
+    PRIMARY KEY (id)
+) ENGINE = INNODB
+  auto_increment = 1 COMMENT = '进出学校记录表';

Някои файлове не бяха показани, защото твърде много файлове са промени