mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/per-boe/java-servers.git
synced 2025-12-07 18:06:50 +08:00
Compare commits
61 Commits
20251029-1
...
20250722-w
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2607f3ba10 | ||
|
|
4542d67983 | ||
|
|
ce96b76c78 | ||
|
|
1369b5295d | ||
|
|
507aeadccf | ||
|
|
238dd6b7eb | ||
|
|
7b5ff86209 | ||
|
|
4136783586 | ||
|
|
5f946906be | ||
|
|
b234c6f571 | ||
|
|
ea02f4920b | ||
|
|
7ad6da6f53 | ||
|
|
2a1c04ccb5 | ||
|
|
bba3cde615 | ||
|
|
171ddfb89c | ||
|
|
f227af6da6 | ||
|
|
0d69078cd0 | ||
|
|
3b26209308 | ||
|
|
1a88a7442f | ||
|
|
65bd8d9110 | ||
|
|
549448aa69 | ||
|
|
a91238000d | ||
|
|
9dcdf31372 | ||
|
|
d723d9e74b | ||
|
|
13ee490bff | ||
|
|
77e2ca0b0b | ||
|
|
03c12f7bc9 | ||
|
|
e28e4523ab | ||
|
|
c8512a86df | ||
|
|
2e7b2ab085 | ||
|
|
6fa5d8bb0d | ||
|
|
14376b21b4 | ||
|
|
29221d8f25 | ||
|
|
672487e29d | ||
|
|
b7834eadf9 | ||
|
|
14bd304374 | ||
|
|
447a65ee6f | ||
|
|
d88b285729 | ||
|
|
d3e84feb48 | ||
|
|
318ba14fd3 | ||
|
|
5ad578454e | ||
|
|
052f673fc8 | ||
|
|
451156265e | ||
|
|
ff299b7697 | ||
|
|
66e4187be2 | ||
|
|
436f7647ce | ||
|
|
5c9237cb79 | ||
|
|
889f634c5e | ||
|
|
978e1a7bf2 | ||
|
|
5fe9019d87 | ||
|
|
be8c4464dc | ||
|
|
c7f1a1e810 | ||
|
|
87350c74f9 | ||
|
|
67f55c51b8 | ||
|
|
645c58e8c4 | ||
|
|
dd6e64d6ac | ||
|
|
754d41e087 | ||
|
|
fedf8ec527 | ||
|
|
e2ac6a5b96 | ||
|
|
66320dab97 | ||
|
|
5312d9f5f4 |
@@ -57,4 +57,8 @@ public class CourseTeacher extends IdBaseEntity {
|
|||||||
@Transient
|
@Transient
|
||||||
private Integer teacherType;
|
private Integer teacherType;
|
||||||
|
|
||||||
|
/**讲师头像*/
|
||||||
|
@Transient
|
||||||
|
private String photo;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -105,8 +105,11 @@ public class CourseContentServiceImpl implements ICourseContentService {
|
|||||||
if(homework!=null) {
|
if(homework!=null) {
|
||||||
homework.setCourseId(cc.getCourseId());
|
homework.setCourseId(cc.getCourseId());
|
||||||
homework.setContentId(cc.getId());
|
homework.setContentId(cc.getId());
|
||||||
homework=homeworkDao.saveOrUpdate(homework);
|
log.info("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
|
||||||
homework.setSysVersion(homeworkDao.getVersion(homework.getId()));
|
homework.setSysVersion(homeworkDao.getVersion(homework.getId()));
|
||||||
|
homeworkDao.saveOrUpdate(homework);
|
||||||
|
log.info("bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
|
||||||
|
log.info("ccccccccccccccccccccccccccccccccccccccccccccccccccc");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -491,7 +491,7 @@ public class CourseServiceImpl implements ICourseService {
|
|||||||
String sql = "SELECT DISTINCT\n" +
|
String sql = "SELECT DISTINCT\n" +
|
||||||
"rt.course_id\n" +
|
"rt.course_id\n" +
|
||||||
"FROM\n" +
|
"FROM\n" +
|
||||||
"boe_new.student s INNER JOIN boe_new.router_task rt on s.pid=rt.router_id inner join boe_course c on c.id=rt.course_id\n" +
|
"boe.student s INNER JOIN boe.router_task rt on s.pid=rt.router_id inner join boe_course c on c.id=rt.course_id\n" +
|
||||||
"\n" +
|
"\n" +
|
||||||
"WHERE\n" +
|
"WHERE\n" +
|
||||||
"\n" +
|
"\n" +
|
||||||
@@ -514,7 +514,7 @@ public class CourseServiceImpl implements ICourseService {
|
|||||||
String sql = "SELECT DISTINCT\n" +
|
String sql = "SELECT DISTINCT\n" +
|
||||||
"pt.course_id\n" +
|
"pt.course_id\n" +
|
||||||
"FROM\n" +
|
"FROM\n" +
|
||||||
"boe_new.student s INNER JOIN boe_new.project_task pt on s.pid=pt.project_id inner join boe_course c on c.id=pt.course_id\n" +
|
"boe.student s INNER JOIN boe.project_task pt on s.pid=pt.project_id inner join boe_course c on c.id=pt.course_id\n" +
|
||||||
"\n" +
|
"\n" +
|
||||||
"WHERE\n" +
|
"WHERE\n" +
|
||||||
"\n" +
|
"\n" +
|
||||||
@@ -571,8 +571,8 @@ public class CourseServiceImpl implements ICourseService {
|
|||||||
String sql = "SELECT DISTINCT\n" +
|
String sql = "SELECT DISTINCT\n" +
|
||||||
"\tc.id \n" +
|
"\tc.id \n" +
|
||||||
"FROM\n" +
|
"FROM\n" +
|
||||||
"\tboe_new.student s\n" +
|
"\tboe.student s\n" +
|
||||||
"\tINNER JOIN boe_new.grow_task gt ON s.pid = gt.grow_id\n" +
|
"\tINNER JOIN boe.grow_task gt ON s.pid = gt.grow_id\n" +
|
||||||
"\tINNER JOIN boe_course c ON gt.course_id = c.id \n" +
|
"\tINNER JOIN boe_course c ON gt.course_id = c.id \n" +
|
||||||
"WHERE\n" +
|
"WHERE\n" +
|
||||||
"\ts.type = 14 \n" +
|
"\ts.type = 14 \n" +
|
||||||
|
|||||||
@@ -165,7 +165,7 @@ public class AloneExamServiceImpl implements IAloneExamService{
|
|||||||
query.addFilter(FieldFilters.eq("aid",aea.getAid()));
|
query.addFilter(FieldFilters.eq("aid",aea.getAid()));
|
||||||
}
|
}
|
||||||
if(StringUtils.isNotBlank(aea.getName())) {
|
if(StringUtils.isNotBlank(aea.getName())) {
|
||||||
query.addFilter(FieldFilters.eq("name",aea.getName()));
|
query.addFilter(FieldFilters.like("name",aea.getName()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return dao.findPage(query.builder());
|
return dao.findPage(query.builder());
|
||||||
|
|||||||
@@ -75,6 +75,7 @@ public class CommentsServiceImpl implements ICommentsService{
|
|||||||
c.setPraises(0);
|
c.setPraises(0);
|
||||||
c.setFavorites(0);
|
c.setFavorites(0);
|
||||||
dao.save(c);
|
dao.save(c);
|
||||||
|
callback.increase(BoedxResourceType.toEnum(c.getObjType()),c.getObjId(), BoedxHitsField.Comments);
|
||||||
if(c.getParentRead()!=null && c.getParentRead()) {
|
if(c.getParentRead()!=null && c.getParentRead()) {
|
||||||
dao.updateMultiFieldById(c.getParentId(),
|
dao.updateMultiFieldById(c.getParentId(),
|
||||||
UpdateBuilder.create("replys","replys+1",FieldUpdateType.EXPRESSION),
|
UpdateBuilder.create("replys","replys+1",FieldUpdateType.EXPRESSION),
|
||||||
@@ -87,9 +88,11 @@ public class CommentsServiceImpl implements ICommentsService{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void deleteReply(String id,String parentId) {
|
public void deleteReply(String id,String parentId) {
|
||||||
|
Comments comment=dao.get(id);
|
||||||
dao.deleteById(id);
|
dao.deleteById(id);
|
||||||
dao.updateMultiFieldById(parentId, UpdateBuilder.create("replys","replys-1",FieldUpdateType.EXPRESSION));
|
dao.updateMultiFieldById(parentId, UpdateBuilder.create("replys","replys-1",FieldUpdateType.EXPRESSION));
|
||||||
|
//需要同时回调处理,修改对应的内容的评论数量
|
||||||
|
callback.reduce(BoedxResourceType.toEnum(comment.getObjType()),comment.getObjId(),BoedxHitsField.Comments);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ public class QuestionServiceImpl implements IQuestionService {
|
|||||||
// filters.add(FieldFilters.or(FieldFilters.like("title", questionDto.getKeyword()), FieldFilters.like("content", questionDto.getKeyword())));
|
// filters.add(FieldFilters.or(FieldFilters.like("title", questionDto.getKeyword()), FieldFilters.like("content", questionDto.getKeyword())));
|
||||||
List<IFieldFilter> iFieldFilters = new ArrayList<>();
|
List<IFieldFilter> iFieldFilters = new ArrayList<>();
|
||||||
iFieldFilters.add(FieldFilters.like("title", questionDto.getKeyword()));
|
iFieldFilters.add(FieldFilters.like("title", questionDto.getKeyword()));
|
||||||
iFieldFilters.add(FieldFilters.like("content", questionDto.getKeyword()));
|
iFieldFilters.add(FieldFilters.like("title", questionDto.getKeyword()));
|
||||||
iFieldFilters.add(FieldFilters.like("sysCreateBy", questionDto.getKeyword()));
|
iFieldFilters.add(FieldFilters.like("sysCreateBy", questionDto.getKeyword()));
|
||||||
filters.add(FieldFilters.or(iFieldFilters));
|
filters.add(FieldFilters.or(iFieldFilters));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -212,6 +212,7 @@ public class StudyCourseApi extends ApiBaseController{
|
|||||||
ct.setRemark(t.getDescription());
|
ct.setRemark(t.getDescription());
|
||||||
ct.setSupplier(t.getSupplier());
|
ct.setSupplier(t.getSupplier());
|
||||||
ct.setTeacherType(t.getTeacherType());
|
ct.setTeacherType(t.getTeacherType());
|
||||||
|
ct.setPhoto(t.getPhoto());
|
||||||
}
|
}
|
||||||
if(redisTemplate.opsForValue().get(ct.getTeacherId())==null){
|
if(redisTemplate.opsForValue().get(ct.getTeacherId())==null){
|
||||||
List<String>list=new ArrayList<>();
|
List<String>list=new ArrayList<>();
|
||||||
@@ -403,6 +404,8 @@ public class StudyCourseApi extends ApiBaseController{
|
|||||||
studyService.saveStudyInfo(sci,token);
|
studyService.saveStudyInfo(sci,token);
|
||||||
//学习记录成功后处理
|
//学习记录成功后处理
|
||||||
studyService.appendStudyDuration(sci.getStudyId(),sci.getStudyItemId(),sci.getContentId(),sci.getDuration());
|
studyService.appendStudyDuration(sci.getStudyId(),sci.getStudyItemId(),sci.getContentId(),sci.getDuration());
|
||||||
|
|
||||||
|
log.info("在线课学习记录 sci.getStudyId() = "+ sci.getStudyId() + " , sci.getCourseId() = " + sci.getCourseId() );
|
||||||
List<StudyCourse> allUserList = thirdApi.getStudyCourseList(sci.getStudyId() ,sci.getCourseId(), token);
|
List<StudyCourse> allUserList = thirdApi.getStudyCourseList(sci.getStudyId() ,sci.getCourseId(), token);
|
||||||
log.info("在线课学习记录"+allUserList);
|
log.info("在线课学习记录"+allUserList);
|
||||||
//System.out.println("在线课学习记录"+allUserList);
|
//System.out.println("在线课学习记录"+allUserList);
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
package com.xboe.school.study.api;
|
package com.xboe.school.study.api;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.time.ZoneOffset;
|
import java.time.ZoneOffset;
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
@@ -10,6 +12,13 @@ import cn.hutool.core.collection.CollectionUtil;
|
|||||||
import com.xboe.module.course.entity.Course;
|
import com.xboe.module.course.entity.Course;
|
||||||
import com.xboe.module.course.service.ICourseService;
|
import com.xboe.module.course.service.ICourseService;
|
||||||
import org.apache.commons.compress.utils.Lists;
|
import org.apache.commons.compress.utils.Lists;
|
||||||
|
import cn.hutool.core.collection.CollectionUtil;
|
||||||
|
import com.alibaba.fastjson2.JSON;
|
||||||
|
import com.xboe.core.orm.FieldFilters;
|
||||||
|
import com.xboe.core.orm.QueryBuilder;
|
||||||
|
import com.xboe.module.course.dao.CourseDao;
|
||||||
|
import com.xboe.module.course.dto.RankingDto;
|
||||||
|
import com.xboe.module.course.entity.Course;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
|||||||
@@ -137,11 +137,15 @@ public class StudyCourseTask {
|
|||||||
String courseContentId = parts[5];
|
String courseContentId = parts[5];
|
||||||
String studyItemId = parts[7];
|
String studyItemId = parts[7];
|
||||||
// 7. 获取存储的时间点(示例逻辑)
|
// 7. 获取存储的时间点(示例逻辑)
|
||||||
|
|
||||||
String redisValue = redisTemplate.opsForValue().get(redisKey);
|
String redisValue = redisTemplate.opsForValue().get(redisKey);
|
||||||
|
// redisValue = 60&20&2025-07-22T16:51:40
|
||||||
log.info("-定时任务 saveStudyCourseItemLastTime ---redisValue = " + redisValue);
|
log.info("-定时任务 saveStudyCourseItemLastTime ---redisValue = " + redisValue);
|
||||||
if (redisValue == null) continue;
|
if (redisValue == null) continue;
|
||||||
String[] partValues = redisValue.split("&");
|
String[] partValues = redisValue.split("&");
|
||||||
|
// studyVideoTtime=60
|
||||||
int studyVideoTtime = Integer.parseInt(partValues[0]);
|
int studyVideoTtime = Integer.parseInt(partValues[0]);
|
||||||
|
// appendtime=20
|
||||||
int appendtime = Integer.parseInt(partValues[1]);
|
int appendtime = Integer.parseInt(partValues[1]);
|
||||||
LocalDateTime timestamp = null;
|
LocalDateTime timestamp = null;
|
||||||
if (partValues.length >= 2){
|
if (partValues.length >= 2){
|
||||||
|
|||||||
@@ -60,6 +60,7 @@ public class SysUploaderApi extends ApiBaseController{
|
|||||||
fileTypeSet.add("pptx");
|
fileTypeSet.add("pptx");
|
||||||
fileTypeSet.add("pdf");
|
fileTypeSet.add("pdf");
|
||||||
fileTypeSet.add("zip");
|
fileTypeSet.add("zip");
|
||||||
|
fileTypeSet.add("jpeg");
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(value = "/file/upload", method = RequestMethod.POST, produces = "application/json")
|
@RequestMapping(value = "/file/upload", method = RequestMethod.POST, produces = "application/json")
|
||||||
|
|||||||
Reference in New Issue
Block a user