From be2bda8e5300efcb60ae2c0353e365812029ad17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=BF=A0=E6=9E=97?= <170083662@qq.com> Date: Wed, 29 Oct 2025 14:40:57 +0800 Subject: [PATCH] =?UTF-8?q?feat(clinic):=20=E6=B7=BB=E5=8A=A0=E5=8C=BB?= =?UTF-8?q?=E7=94=9F=E8=81=8C=E4=BD=8D=E5=AD=97=E6=AE=B5=E5=B9=B6=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E6=96=87=E7=AB=A0=E5=86=85=E5=AE=B9=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?-=20=E5=9C=A8=20ClinicAppointment=20=E5=AE=9E=E4=BD=93=E4=B8=AD?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=20doctorPosition=20=E5=AD=97=E6=AE=B5-=20?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=20ClinicAppointmentMapper.xml=20=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E8=AF=AD=E5=8F=A5=E4=BB=A5=E5=8C=85=E5=90=AB=E5=8C=BB?= =?UTF-8?q?=E7=94=9F=E8=81=8C=E4=BD=8D=E4=BF=A1=E6=81=AF=20-=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=20CmsArticleContentServiceImpl=20=E4=B8=AD=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E8=AE=BE=E7=BD=AE=E9=94=99=E8=AF=AF=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98=20-=20=E5=9C=A8=20CmsArticleController=20=E4=B8=AD?= =?UTF-8?q?=E5=A2=9E=E5=BC=BA=E6=96=87=E7=AB=A0=E5=86=85=E5=AE=B9=E8=8E=B7?= =?UTF-8?q?=E5=8F=96=E9=80=BB=E8=BE=91=20-=20=E5=9C=A8=20HjmViolation=20?= =?UTF-8?q?=E5=AE=9E=E4=BD=93=E4=B8=AD=E6=96=B0=E5=A2=9E=20image=20?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E7=94=A8=E4=BA=8E=E5=AD=98=E5=82=A8=E8=BD=A6?= =?UTF-8?q?=E8=BE=86=E5=A4=B4=E5=83=8F-=20=E6=9B=B4=E6=96=B0=20HjmViolatio?= =?UTF-8?q?nMapper.xml=20=E6=9F=A5=E8=AF=A2=E8=AF=AD=E5=8F=A5=E4=BB=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gxwebsoft/clinic/entity/ClinicAppointment.java | 4 ++++ .../clinic/mapper/xml/ClinicAppointmentMapper.xml | 2 +- .../cms/controller/CmsArticleController.java | 11 ++++++++++- .../service/impl/CmsArticleContentServiceImpl.java | 2 +- .../java/com/gxwebsoft/hjm/entity/HjmViolation.java | 5 +++++ .../gxwebsoft/hjm/mapper/xml/HjmViolationMapper.xml | 3 ++- 6 files changed, 23 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/gxwebsoft/clinic/entity/ClinicAppointment.java b/src/main/java/com/gxwebsoft/clinic/entity/ClinicAppointment.java index 462dcf7..c38ae8d 100644 --- a/src/main/java/com/gxwebsoft/clinic/entity/ClinicAppointment.java +++ b/src/main/java/com/gxwebsoft/clinic/entity/ClinicAppointment.java @@ -43,6 +43,10 @@ public class ClinicAppointment implements Serializable { @TableField(exist = false) private String doctorName; + @Schema(description = "医生职位") + @TableField(exist = false) + private String doctorPosition; + @Schema(description = "患者") private Integer userId; diff --git a/src/main/java/com/gxwebsoft/clinic/mapper/xml/ClinicAppointmentMapper.xml b/src/main/java/com/gxwebsoft/clinic/mapper/xml/ClinicAppointmentMapper.xml index c4ba8bb..5aee909 100644 --- a/src/main/java/com/gxwebsoft/clinic/mapper/xml/ClinicAppointmentMapper.xml +++ b/src/main/java/com/gxwebsoft/clinic/mapper/xml/ClinicAppointmentMapper.xml @@ -4,7 +4,7 @@ - SELECT a.*, b.nickname, b.phone, c.real_name as doctorName + SELECT a.*, b.nickname, b.phone, c.real_name as doctorName, c.position as doctorPosition FROM clinic_appointment a LEFT JOIN gxwebsoft_core.sys_user b ON a.user_id = b.user_id LEFT JOIN clinic_doctor_user c ON a.doctor_id = c.user_id diff --git a/src/main/java/com/gxwebsoft/cms/controller/CmsArticleController.java b/src/main/java/com/gxwebsoft/cms/controller/CmsArticleController.java index 98419cc..46478af 100644 --- a/src/main/java/com/gxwebsoft/cms/controller/CmsArticleController.java +++ b/src/main/java/com/gxwebsoft/cms/controller/CmsArticleController.java @@ -83,7 +83,10 @@ public class CmsArticleController extends BaseController { public ApiResult get(@PathVariable("id") @NotNull Integer id) { final CmsArticle article = cmsArticleService.getByIdRel(id); if (ObjectUtil.isNotEmpty(article)) { - return success(article); + final CmsArticleContent item = articleContentService.getByIdRel(article.getArticleId()); + if (ObjectUtil.isNotEmpty(item)) { + article.setContent(item.getContent()); + } } return fail("文章ID不存在",null); } @@ -92,6 +95,12 @@ public class CmsArticleController extends BaseController { @GetMapping("/getByCode/{code}") public ApiResult getByCode(@PathVariable("code") String code) { final CmsArticle article = cmsArticleService.getByIdCode(code); + if (ObjectUtil.isNotEmpty(article)) { + final CmsArticleContent item = articleContentService.getByIdRel(article.getArticleId()); + if (ObjectUtil.isNotEmpty(item)) { + article.setContent(item.getContent()); + } + } return success(article); } diff --git a/src/main/java/com/gxwebsoft/cms/service/impl/CmsArticleContentServiceImpl.java b/src/main/java/com/gxwebsoft/cms/service/impl/CmsArticleContentServiceImpl.java index a2a0faf..36f47c6 100644 --- a/src/main/java/com/gxwebsoft/cms/service/impl/CmsArticleContentServiceImpl.java +++ b/src/main/java/com/gxwebsoft/cms/service/impl/CmsArticleContentServiceImpl.java @@ -61,7 +61,7 @@ public class CmsArticleContentServiceImpl extends ServiceImpl - SELECT a.* + SELECT a.*,b.image FROM hjm_violation a LEFT JOIN hjm_car b ON a.code = b.code LEFT JOIN gxwebsoft_core.sys_organization c ON b.organization_id = c.organization_id @@ -57,6 +57,7 @@ AND (a.comments LIKE CONCAT('%', #{param.keywords}, '%') + OR a.code = #{param.keywords} )