|
|
|
@ -30,8 +30,15 @@ public class SyncDataEase {
|
|
|
|
|
stageLessonSummary();
|
|
|
|
|
//年级课程数量
|
|
|
|
|
NianJiLessonSummary();
|
|
|
|
|
//学校数量
|
|
|
|
|
schoolCount();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 更新数据
|
|
|
|
|
* @param cnt
|
|
|
|
|
* @param type
|
|
|
|
|
*/
|
|
|
|
|
public static void updateLessonSummary(int cnt, String type) {
|
|
|
|
|
//更新数据
|
|
|
|
|
String sql = Db.getSql("DataEase.updateLessonSummary");
|
|
|
|
@ -47,6 +54,11 @@ public class SyncDataEase {
|
|
|
|
|
//更新数据
|
|
|
|
|
int cnt = record.getInt("cnt");
|
|
|
|
|
updateLessonSummary(cnt, "课程建设总量");
|
|
|
|
|
|
|
|
|
|
//一个数据,两处使用
|
|
|
|
|
String sql = Db.getSql("DataEase.updateSchoolCount");
|
|
|
|
|
Db.use(MYSQL_DB).update(sql, cnt, "直播课程");
|
|
|
|
|
|
|
|
|
|
print("课程建设总量(包括:直播课、点播课、专题题):" + cnt);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -183,4 +195,16 @@ public class SyncDataEase {
|
|
|
|
|
print("初中一年级至三年级:" + c1 + ",二年级:" + c2 + ",三年级:" + c3);
|
|
|
|
|
print("高中一年级至三年级:" + g1 + ",二年级:" + g2 + ",三年级:" + g3);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 学校数量
|
|
|
|
|
*/
|
|
|
|
|
public static void schoolCount() {
|
|
|
|
|
SqlPara sqlPara = Db.getSqlPara("DataEase.schoolCount");
|
|
|
|
|
Record record = Db.findFirst(sqlPara);
|
|
|
|
|
|
|
|
|
|
int cnt = record.getInt("cnt");
|
|
|
|
|
String sql = Db.getSql("DataEase.updateSchoolCount");
|
|
|
|
|
Db.use(MYSQL_DB).update(sql, cnt, "参与学校数量");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|