给吴门医述官网提供接口学术传承列表

This commit is contained in:
wuchunlei
2025-08-19 09:17:39 +08:00
parent dda5ebc2e3
commit 915b57ec8f

View File

@@ -23,6 +23,7 @@ import com.peanut.modules.medical.service.CourseService;
import com.peanut.modules.sociology.service.CourseCatalogueChapterService; import com.peanut.modules.sociology.service.CourseCatalogueChapterService;
import com.peanut.modules.sociology.service.CourseSociologyService; import com.peanut.modules.sociology.service.CourseSociologyService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import java.util.*; import java.util.*;
@@ -79,6 +80,8 @@ public class VisitorController {
@Autowired @Autowired
private TaihuWelfareService taihuWelfareService; private TaihuWelfareService taihuWelfareService;
@Autowired @Autowired
private MedicaldesInheritService inheritService;
@Autowired
private VideoM3u8Dao videoM3u8Dao; private VideoM3u8Dao videoM3u8Dao;
@Autowired @Autowired
private PlayToken playToken; private PlayToken playToken;
@@ -543,6 +546,32 @@ public class VisitorController {
return R.ok().put("result",byId); return R.ok().put("result",byId);
} }
//获取吴门医述-学术传承列表
@RequestMapping(path = "/inheritListByPage")
public R inheritListByPage(String current,String limit,String type,String name) {
MPJLambdaWrapper<MedicaldesInherit> wrapper = new MPJLambdaWrapper();
wrapper.leftJoin(MedicaldesInheritRelation.class,MedicaldesInheritRelation::getInheritId,MedicaldesInherit::getId);
wrapper.leftJoin(City.class,City::getCityId,MedicaldesInherit::getCityId);
wrapper.leftJoin(Province.class,Province::getProvId,City::getProvId);
wrapper.select(MedicaldesInherit::getId,MedicaldesInherit::getName,MedicaldesInherit::getContent,MedicaldesInherit::getUrl,MedicaldesInherit::getImg);
if (StringUtils.isNotEmpty(type)){
wrapper.eq(MedicaldesInheritRelation::getTypeId,type);
}
if (StringUtils.isNotEmpty(name)){
wrapper.like(MedicaldesInherit::getName,name);
}
wrapper.orderByAsc(MedicaldesInheritRelation::getSort);
if (StringUtils.isEmpty(current)){
current = "1";
}
if (StringUtils.isEmpty(limit)){
limit = "10";
}
Page<MedicaldesInherit> page = inheritService.page(new Page<>(
Long.parseLong(current), Long.parseLong(limit)),wrapper);
return R.ok().put("result", page);
}