|
@@ -473,7 +473,8 @@ public class DataUtil {
|
|
|
+ " and time_period = " + tmePeriod.get(asJsonObject.get("timeOption").getAsInt())
|
|
+ " and time_period = " + tmePeriod.get(asJsonObject.get("timeOption").getAsInt())
|
|
|
+ " and time_number = " + timeNumber
|
|
+ " and time_number = " + timeNumber
|
|
|
+ " and weeks = " + asJsonObject.get("dayOfWeek").getAsInt()
|
|
+ " and weeks = " + asJsonObject.get("dayOfWeek").getAsInt()
|
|
|
- + " and course_id = " + coureseMap.get(asJsonObject.get("courseClassId").getAsString());
|
|
|
|
|
|
|
+ + " and course_id = " + coureseMap.get(asJsonObject.get("courseClassId").getAsString())
|
|
|
|
|
+ + " and create_date = '" + asJsonObject.get("scheduleDate").getAsString() + "'";
|
|
|
|
|
|
|
|
String sql = "INSERT INTO course_table(id,base_semester_id,teacher_id,teacher_name,course_id,course_name," +
|
|
String sql = "INSERT INTO course_table(id,base_semester_id,teacher_id,teacher_name,course_id,course_name," +
|
|
|
"class_id, class_name,weeks,weeks_cn,time_period,time_number,site_id,site_name,status," +
|
|
"class_id, class_name,weeks,weeks_cn,time_period,time_number,site_id,site_name,status," +
|
|
@@ -496,7 +497,8 @@ public class DataUtil {
|
|
|
+ tmePeriod.get(asJsonObject.get("timeOption").getAsInt()) + ","
|
|
+ tmePeriod.get(asJsonObject.get("timeOption").getAsInt()) + ","
|
|
|
+ timeNumber + ","
|
|
+ timeNumber + ","
|
|
|
+ (classroomMap.get(asJsonObject.get("classRoomSerialNo").getAsString()) == null ? 0 : classroomMap.get(asJsonObject.get("classRoomSerialNo").getAsString())) + ","
|
|
+ (classroomMap.get(asJsonObject.get("classRoomSerialNo").getAsString()) == null ? 0 : classroomMap.get(asJsonObject.get("classRoomSerialNo").getAsString())) + ","
|
|
|
- + "'" + asJsonObject.get("classRoomName").getAsString() + "',1,now(),"
|
|
|
|
|
|
|
+ + "'" + asJsonObject.get("classRoomName").getAsString() + "',1,"
|
|
|
|
|
+ + "'" + asJsonObject.get("scheduleDate").getAsString() + "',"
|
|
|
+ "'" + asJsonObject.get("id").getAsString() + "' FROM DUAL"
|
|
+ "'" + asJsonObject.get("id").getAsString() + "' FROM DUAL"
|
|
|
+ " WHERE NOT EXISTS(SELECT * FROM course_table WHERE jianyue_id = '" + asJsonObject.get("id").getAsString() +"' and status = 1)";
|
|
+ " WHERE NOT EXISTS(SELECT * FROM course_table WHERE jianyue_id = '" + asJsonObject.get("id").getAsString() +"' and status = 1)";
|
|
|
sqls.add(updateSql);
|
|
sqls.add(updateSql);
|
|
@@ -512,7 +514,7 @@ public class DataUtil {
|
|
|
* @param data 数据
|
|
* @param data 数据
|
|
|
*
|
|
*
|
|
|
*/
|
|
*/
|
|
|
- public void insertClassTime(Db db, JsonArray data, BaseSemester baseSemester) throws SQLException {
|
|
|
|
|
|
|
+ public void insertClassTime(Db db, JsonArray data) throws SQLException {
|
|
|
|
|
|
|
|
Map<String, JsonObject> infoMap = new HashMap<>();
|
|
Map<String, JsonObject> infoMap = new HashMap<>();
|
|
|
Map<Integer, Integer> tmePeriod = ScheduleUtil.getTmePeriod();
|
|
Map<Integer, Integer> tmePeriod = ScheduleUtil.getTmePeriod();
|