提交 650c2c42 authored 作者: 任建宇's avatar 任建宇

feat: 检索

1.resource
上级 06899ece
......@@ -686,31 +686,8 @@ public class ResourceLibraryController {
}
orderInfo.setCategoryCodes(categoryCodes);
//获取定价和售价,折扣
/*FgPromotionInfoOneVO pi = promotionService.getInfoByResId(id,entity.getResourceType());
if(pi != null){
orderInfo.setPrice(pi.getPrice());
orderInfo.setDiscount(pi.getDiscountOrRealPrice());
orderInfo.setRealPrice(pi.getRealPrice());
}
orderInfo.setGoodsAttr1(entity.getVideo());*/
return CallBack.success(orderInfo);
}
//直播
//if (AllResourceTypeEnum.LIVE.getCode().toString().equals(goodsType)) {
// LiveVO entity = courseLibraryService.selectLiveById(id);
// orderInfo.setGoodsid(entity.getId());
// orderInfo.setType(AllResourceTypeEnum.LIVE.getCode().toString());
// orderInfo.setResourceTypeName(AllResourceTypeEnum.LIVE.getName());
// orderInfo.setName(entity.getName());
// if (entity.getPrice() == null) {
// orderInfo.setPrice(entity.getRealPrice());
// } else {
// orderInfo.setPrice(entity.getPrice());
// }
// orderInfo.setRealPrice(entity.getRealPrice());
// orderInfo.setCover(entity.getImg());
// return CallBack.success(orderInfo);
//}
return CallBack.fail();
}
......@@ -785,7 +762,6 @@ public class ResourceLibraryController {
if (AllResourceTypeEnum.COURSE.getCode().equals(goodsType)) {
CourseLibraryPO entity = courseLibraryService.getById(id);
vo.setCover(entity.getCover());
//vo.setSource(entity.getSource());
vo.setSummary(StringUtil.regEx(entity.getSynopsis()));
//查询学习进度
Integer schedule = courseLibraryService.getSchedule(id, goodsType);
......@@ -952,8 +928,6 @@ public class ResourceLibraryController {
sq.setStart(0);
sq.setRows(Integer.MAX_VALUE);
}
if (null != pageParam && StringUtils.isNotBlank(pageParam.getOrderBy())) {
sq.set("sort", pageParam.getOrderBy());
}else{
......
......@@ -544,6 +544,13 @@ public class EbookServiceImpl extends ServiceImpl<EbookMapper, Ebook> implements
Integer maxOrderNum = projectLibraryService.getMaxOrderNum("2");
pro.setSort(maxOrderNum);
pro.setStatus("1");
if(department!=null){
pro.setDepartmentId(department.getId());
pro.setDepartmentCode(department.getCode());
}else{
pro.setDepartmentId(308);
pro.setDepartmentCode("01");
}
projectLibraryMapper.insert(pro);
ProjectModelResource obj = new ProjectModelResource();
obj.setResourceType(GoodsTypeEnum.EBOOK.getCode());
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论