|
|
@@ -787,13 +787,39 @@ public class ClassTimeStatisticsServiceImpl extends MPJBaseServiceImpl<ClassTime
|
|
|
_classTime9 = classCourseTimeStatisticsRecord.getClassTime9(),
|
|
|
_classTime11 = classCourseTimeStatisticsRecord.getClassTime11();
|
|
|
|
|
|
+ Object cost="0";
|
|
|
+
|
|
|
+ //费用设置jsonArray
|
|
|
+ JsonArray _costSetArray = parser.parse(classCourseTimeStatisticsRecord.getCostSetJson()).getAsJsonArray();
|
|
|
+ Map<String, Double> _costSetMap = new LinkedHashMap<>();
|
|
|
+ for (JsonElement jsonElement : _costSetArray) {
|
|
|
+ JsonObject object = jsonElement.getAsJsonObject();
|
|
|
+ _costSetMap.put(object.get("field").getAsString(), object.get("value").getAsDouble());
|
|
|
+ }
|
|
|
+
|
|
|
if ("早自习".equals(courseListVo.getShortName())) {
|
|
|
_classTime7 += weightSetMap.get(courseListVo.getShortName()) == null ? 0d : weightSetMap.get(courseListVo.getShortName());
|
|
|
+ if ("FB1601".equals(classCourseTimeStatisticsRecord.getEmployType())) {
|
|
|
+ cost=_costSetMap.get("cost1");
|
|
|
+ } else {
|
|
|
+ cost=_costSetMap.get("cost2");
|
|
|
+ }
|
|
|
} else if (zkList.contains(courseListVo.getShortName())) {
|
|
|
_classTime8 += weightSetMap.get(courseListVo.getShortName()) == null ? 0d : weightSetMap.get(courseListVo.getShortName());
|
|
|
+ if ("FB1601".equals(classCourseTimeStatisticsRecord.getEmployType())) {
|
|
|
+ cost= _costSetMap.get("cost3");
|
|
|
+ } else {
|
|
|
+ cost= _costSetMap.get("cost4");
|
|
|
+ }
|
|
|
} else if (wzxList.contains(courseListVo.getShortName())) {
|
|
|
_classTime9 += weightSetMap.get(courseListVo.getShortName()) == null ? 0d : weightSetMap.get(courseListVo.getShortName());
|
|
|
+ if ("FB1601".equals(classCourseTimeStatisticsRecord.getEmployType())) {
|
|
|
+ cost= _costSetMap.get("cost5");
|
|
|
+ } else {
|
|
|
+ cost= _costSetMap.get("cost6");
|
|
|
+ }
|
|
|
}
|
|
|
+ courseJson.addProperty("content", courseListVo.getClassName() + "," + courseListVo.getCourseName()+","+cost);
|
|
|
|
|
|
if (courseListVo.getAdjustType() != null && !courseListVo.getAdjustType().isEmpty()) {
|
|
|
if (CourseAdjustTypeEnum.courseExchange.getCode().equals(courseListVo.getAdjustType())) {
|
|
|
@@ -1198,7 +1224,7 @@ public class ClassTimeStatisticsServiceImpl extends MPJBaseServiceImpl<ClassTime
|
|
|
// 检查数据
|
|
|
private ClassCourseTimeStatisticsRecord checkCourseSet(List<ClassCourseTimeStatisticsSet> classCourseTimeStatisticsSetList,List<ClassCourseTimeStatisticsRecord> insertCourseList,Long classId,Long courseId,TeacherListVo teacher) {
|
|
|
|
|
|
- if(classId==null|| courseId==null) {
|
|
|
+ if (classId == null || courseId == null) {
|
|
|
return null;
|
|
|
}
|
|
|
|
|
|
@@ -1242,11 +1268,8 @@ public class ClassTimeStatisticsServiceImpl extends MPJBaseServiceImpl<ClassTime
|
|
|
}};
|
|
|
|
|
|
insertCourseList.add(classCourseTimeStatisticsRecord);
|
|
|
-
|
|
|
- return classCourseTimeStatisticsRecord;
|
|
|
-
|
|
|
}
|
|
|
-
|
|
|
+ return classCourseTimeStatisticsRecord;
|
|
|
}
|
|
|
return null;
|
|
|
}
|