mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/per-boe/java-servers.git
synced 2025-12-07 01:46:47 +08:00
szx-1241 类型转换处理
This commit is contained in:
@@ -818,12 +818,13 @@ public class CourseServiceImpl implements ICourseService {
|
||||
String body = "courseId=" + id + " aid=" + aid + " name=" + name + " remark=" + remark;
|
||||
String location = "/xboe/m/course/manage/delete";
|
||||
List<CourseTeacher> teacherList = courseTeacherDao.findByCourseId(id);
|
||||
log.info("teacherList:{}", JSONUtil.toJsonStr(teacherList));
|
||||
String jsonStr = JSONUtil.toJsonStr(teacherList);
|
||||
log.info("teacherList:{}", jsonStr);
|
||||
try {
|
||||
List<List<CourseTeacher>> list = JSONUtil.toBean(JSONUtil.toJsonStr(teacherList), List.class);
|
||||
List<List> list = JSONUtil.toList(jsonStr, List.class);
|
||||
list.forEach(item -> {
|
||||
for (CourseTeacher teacher : item) {
|
||||
courseTeacherModifyRecordDao.insertRecord("DELETE", location, teacher, body);
|
||||
for (Object teacher : item) {
|
||||
courseTeacherModifyRecordDao.insertRecord("DELETE", location, (CourseTeacher) teacher, body);
|
||||
}
|
||||
});
|
||||
} catch (Exception e) {
|
||||
|
||||
Reference in New Issue
Block a user