|
@@ -1,10 +1,10 @@
|
1
|
1
|
package com.xhkjedu.suser.service.gradeclass;
|
2
|
2
|
|
3
|
3
|
import com.xhkjedu.suser.mapper.gradeclass.GradeMapper;
|
4
|
|
-//import com.xhkjedu.suser.mapper.gradeclass.SchoolMapper;
|
|
4
|
+import com.xhkjedu.suser.mapper.gradeclass.SchoolMapper;
|
5
|
5
|
import com.xhkjedu.suser.model.gradeclass.TGrade;
|
6
|
|
-import com.xhkjedu.utils.N_Utils;
|
7
|
6
|
import com.xhkjedu.suser.vo.gradeclass.GradeVo;
|
|
7
|
+import com.xhkjedu.utils.N_Utils;
|
8
|
8
|
import org.springframework.stereotype.Service;
|
9
|
9
|
|
10
|
10
|
import javax.annotation.Resource;
|
|
@@ -13,15 +13,15 @@ import java.util.List;
|
13
|
13
|
/**
|
14
|
14
|
* @author ywx
|
15
|
15
|
* @classname TGradeService
|
16
|
|
- * @description
|
|
16
|
+ * @description
|
17
|
17
|
* @date 2020/6/2 14:53
|
18
|
18
|
**/
|
19
|
19
|
@Service
|
20
|
20
|
public class GradeService {
|
21
|
21
|
@Resource
|
22
|
22
|
private GradeMapper gradeMapper;
|
23
|
|
- //@Resource
|
24
|
|
- //private SchoolMapper schoolMapper;
|
|
23
|
+ @Resource
|
|
24
|
+ private SchoolMapper schoolMapper;
|
25
|
25
|
|
26
|
26
|
//添加
|
27
|
27
|
public Integer save(TGrade model) {
|
|
@@ -46,42 +46,40 @@ public class GradeService {
|
46
|
46
|
}
|
47
|
47
|
|
48
|
48
|
//获取列表
|
49
|
|
- public List <TGrade> findAll(Integer schoolid) {
|
50
|
|
- //Integer year = schoolMapper.getYearById(schoolid);
|
51
|
|
- Integer year = 2021;
|
|
49
|
+ public List<TGrade> findAll(Integer schoolid) {
|
|
50
|
+ Integer year = schoolMapper.getYearById(schoolid);
|
52
|
51
|
return gradeMapper.findAll(schoolid, year);
|
53
|
52
|
}
|
54
|
53
|
|
55
|
54
|
/**
|
56
|
55
|
* 获取通知班级列表
|
|
56
|
+ *
|
|
57
|
+ * @return java.util.List<com.xhkjedu.suser.vo.gradeclass.GradeVo>
|
57
|
58
|
* @Param [schoolid, year]
|
58
|
59
|
* @Author ywx
|
59
|
60
|
* @Date 2020/6/13 15:41
|
60
|
|
- * @return java.util.List<com.xhkjedu.suser.vo.gradeclass.GradeVo>
|
61
|
61
|
**/
|
62
|
|
- public List<GradeVo> listClass(Integer schoolid,Integer classtype) {
|
63
|
|
- //Integer year = schoolMapper.getYearById(schoolid);
|
64
|
|
- Integer year = 2021;
|
65
|
|
- return gradeMapper.listClass(schoolid, year,classtype);
|
|
62
|
+ public List<GradeVo> listClass(Integer schoolid, Integer classtype) {
|
|
63
|
+ Integer year = schoolMapper.getYearById(schoolid);
|
|
64
|
+ return gradeMapper.listClass(schoolid, year, classtype);
|
66
|
65
|
}
|
67
|
66
|
|
68
|
67
|
/**
|
69
|
68
|
* 获取通知教师列表
|
|
69
|
+ *
|
|
70
|
+ * @return java.util.List<com.xhkjedu.suser.vo.gradeclass.GradeVo>
|
70
|
71
|
* @Param [schoolid, year]
|
71
|
72
|
* @Author ywx
|
72
|
73
|
* @Date 2020/6/13 15:42
|
73
|
|
- * @return java.util.List<com.xhkjedu.suser.vo.gradeclass.GradeVo>
|
74
|
74
|
**/
|
75
|
75
|
public List<GradeVo> listTeacher(Integer schoolid) {
|
76
|
|
- //Integer year = schoolMapper.getYearById(schoolid);
|
77
|
|
- Integer year = 2021;
|
|
76
|
+ Integer year = schoolMapper.getYearById(schoolid);
|
78
|
77
|
return gradeMapper.listTeacher(schoolid, year);
|
79
|
78
|
}
|
80
|
79
|
|
81
|
80
|
//获取行政班和提高班
|
82
|
81
|
public List<GradeVo> listClassForTeacher(Integer schoolid) {
|
83
|
|
- //Integer year = schoolMapper.getYearById(schoolid);
|
84
|
|
- Integer year = 2021;
|
85
|
|
- return gradeMapper.listClassForTeacher(schoolid,year);
|
|
82
|
+ Integer year = schoolMapper.getYearById(schoolid);
|
|
83
|
+ return gradeMapper.listClassForTeacher(schoolid, year);
|
86
|
84
|
}
|
87
|
85
|
}
|