diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthDiseasesController.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthDiseasesController.java new file mode 100644 index 0000000..a791db2 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthDiseasesController.java @@ -0,0 +1,116 @@ +package com.ruoyi.health.controller; + +import java.util.List; +import java.io.IOException; +import javax.servlet.http.HttpServletResponse; +import javax.annotation.Resource; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.ruoyi.common.log.annotation.Log; +import com.ruoyi.common.log.enums.BusinessType; +import com.ruoyi.common.security.annotation.RequiresPermissions; +import com.ruoyi.health.domain.HealthDiseases; +import com.ruoyi.health.domain.vo.HealthDiseasesVo; +import com.ruoyi.health.domain.dto.HealthDiseasesDto; +import com.ruoyi.health.service.IHealthDiseasesService; +import com.ruoyi.common.core.web.controller.BaseController; +import com.ruoyi.common.core.web.domain.AjaxResult; +import com.ruoyi.common.core.utils.poi.ExcelUtil; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.ruoyi.common.core.web.page.TableDataInfo; + +/** + * 常见疾病治疗Controller + * + * @author tianyongbao + * @date 2025-01-14 + */ +@Api(tags=" 常见疾病治疗") +@RestController +@RequestMapping("/HealthDiseases") +public class HealthDiseasesController extends BaseController +{ + @Resource + private IHealthDiseasesService healthDiseasesService; + + /** + * 查询常见疾病治疗列表 + */ + @ApiOperation(value="查询常见疾病治疗列表",response = HealthDiseasesVo.class) + @RequiresPermissions("health:HealthDiseases:list") + @GetMapping("/list") + public TableDataInfo list(HealthDiseasesDto healthDiseasesDto) + { + startPage(); + List list = healthDiseasesService.selectHealthDiseasesList(healthDiseasesDto); + return getDataTable(list); + } + + /** + * 导出常见疾病治疗列表 + */ + @ApiOperation(value="导出常见疾病治疗列表") + @RequiresPermissions("health:HealthDiseases:export") + @Log(title = "常见疾病治疗", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, HealthDiseasesDto healthDiseasesDto) + { + List list = healthDiseasesService.selectHealthDiseasesList(healthDiseasesDto); + ExcelUtil util = new ExcelUtil(HealthDiseasesVo.class); + util.exportExcel(response, list, "常见疾病治疗数据"); + } + + /** + * 获取常见疾病治疗详细信息 + */ + @ApiOperation(value="获取常见疾病治疗详细信息") + @RequiresPermissions("health:HealthDiseases:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(healthDiseasesService.selectHealthDiseasesById(id)); + } + + /** + * 新增常见疾病治疗 + */ + @ApiOperation(value="新增常见疾病治疗") + @RequiresPermissions("health:HealthDiseases:add") + @Log(title = "常见疾病治疗", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody HealthDiseases healthDiseases) + { + return toAjax(healthDiseasesService.insertHealthDiseases(healthDiseases)); + } + + /** + * 修改常见疾病治疗 + */ + @ApiOperation(value="修改常见疾病治疗") + @RequiresPermissions("health:HealthDiseases:edit") + @Log(title = "常见疾病治疗", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody HealthDiseases healthDiseases) + { + return toAjax(healthDiseasesService.updateHealthDiseases(healthDiseases)); + } + + /** + * 删除常见疾病治疗 + */ + @ApiOperation(value="删除常见疾病治疗") + @RequiresPermissions("health:HealthDiseases:remove") + @Log(title = "常见疾病治疗", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(healthDiseasesService.deleteHealthDiseasesByIds(ids)); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthMedicineTagsController.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthMedicineTagsController.java new file mode 100644 index 0000000..2b5b2f7 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthMedicineTagsController.java @@ -0,0 +1,116 @@ +package com.ruoyi.health.controller; + +import java.util.List; +import java.io.IOException; +import javax.servlet.http.HttpServletResponse; +import javax.annotation.Resource; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.ruoyi.common.log.annotation.Log; +import com.ruoyi.common.log.enums.BusinessType; +import com.ruoyi.common.security.annotation.RequiresPermissions; +import com.ruoyi.health.domain.HealthMedicineTags; +import com.ruoyi.health.domain.vo.HealthMedicineTagsVo; +import com.ruoyi.health.domain.dto.HealthMedicineTagsDto; +import com.ruoyi.health.service.IHealthMedicineTagsService; +import com.ruoyi.common.core.web.controller.BaseController; +import com.ruoyi.common.core.web.domain.AjaxResult; +import com.ruoyi.common.core.utils.poi.ExcelUtil; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.ruoyi.common.core.web.page.TableDataInfo; + +/** + * 标签管理Controller + * + * @author tianyongbao + * @date 2025-01-14 + */ +@Api(tags=" 标签管理") +@RestController +@RequestMapping("/healthTags") +public class HealthMedicineTagsController extends BaseController +{ + @Resource + private IHealthMedicineTagsService healthMedicineTagsService; + + /** + * 查询标签管理列表 + */ + @ApiOperation(value="查询标签管理列表",response = HealthMedicineTagsVo.class) + @RequiresPermissions("health:healthTags:list") + @GetMapping("/list") + public TableDataInfo list(HealthMedicineTagsDto healthMedicineTagsDto) + { + startPage(); + List list = healthMedicineTagsService.selectHealthMedicineTagsList(healthMedicineTagsDto); + return getDataTable(list); + } + + /** + * 导出标签管理列表 + */ + @ApiOperation(value="导出标签管理列表") + @RequiresPermissions("health:healthTags:export") + @Log(title = "标签管理", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, HealthMedicineTagsDto healthMedicineTagsDto) + { + List list = healthMedicineTagsService.selectHealthMedicineTagsList(healthMedicineTagsDto); + ExcelUtil util = new ExcelUtil(HealthMedicineTagsVo.class); + util.exportExcel(response, list, "标签管理数据"); + } + + /** + * 获取标签管理详细信息 + */ + @ApiOperation(value="获取标签管理详细信息") + @RequiresPermissions("health:healthTags:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(healthMedicineTagsService.selectHealthMedicineTagsById(id)); + } + + /** + * 新增标签管理 + */ + @ApiOperation(value="新增标签管理") + @RequiresPermissions("health:healthTags:add") + @Log(title = "标签管理", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody HealthMedicineTags healthMedicineTags) + { + return toAjax(healthMedicineTagsService.insertHealthMedicineTags(healthMedicineTags)); + } + + /** + * 修改标签管理 + */ + @ApiOperation(value="修改标签管理") + @RequiresPermissions("health:healthTags:edit") + @Log(title = "标签管理", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody HealthMedicineTags healthMedicineTags) + { + return toAjax(healthMedicineTagsService.updateHealthMedicineTags(healthMedicineTags)); + } + + /** + * 删除标签管理 + */ + @ApiOperation(value="删除标签管理") + @RequiresPermissions("health:healthTags:remove") + @Log(title = "标签管理", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(healthMedicineTagsService.deleteHealthMedicineTagsByIds(ids)); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthMedicineTagsRelController.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthMedicineTagsRelController.java new file mode 100644 index 0000000..e33ba35 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/controller/HealthMedicineTagsRelController.java @@ -0,0 +1,116 @@ +package com.ruoyi.health.controller; + +import java.util.List; +import java.io.IOException; +import javax.servlet.http.HttpServletResponse; +import javax.annotation.Resource; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.ruoyi.common.log.annotation.Log; +import com.ruoyi.common.log.enums.BusinessType; +import com.ruoyi.common.security.annotation.RequiresPermissions; +import com.ruoyi.health.domain.HealthMedicineTagsRel; +import com.ruoyi.health.domain.vo.HealthMedicineTagsRelVo; +import com.ruoyi.health.domain.dto.HealthMedicineTagsRelDto; +import com.ruoyi.health.service.IHealthMedicineTagsRelService; +import com.ruoyi.common.core.web.controller.BaseController; +import com.ruoyi.common.core.web.domain.AjaxResult; +import com.ruoyi.common.core.utils.poi.ExcelUtil; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.ruoyi.common.core.web.page.TableDataInfo; + +/** + * 药品标签关系Controller + * + * @author tianyongbao + * @date 2025-01-14 + */ +@Api(tags=" 药品标签关系") +@RestController +@RequestMapping("/MedicineTagsRel") +public class HealthMedicineTagsRelController extends BaseController +{ + @Resource + private IHealthMedicineTagsRelService healthMedicineTagsRelService; + + /** + * 查询药品标签关系列表 + */ + @ApiOperation(value="查询药品标签关系列表",response = HealthMedicineTagsRelVo.class) + @RequiresPermissions("health:MedicineTagsRel:list") + @GetMapping("/list") + public TableDataInfo list(HealthMedicineTagsRelDto healthMedicineTagsRelDto) + { + startPage(); + List list = healthMedicineTagsRelService.selectHealthMedicineTagsRelList(healthMedicineTagsRelDto); + return getDataTable(list); + } + + /** + * 导出药品标签关系列表 + */ + @ApiOperation(value="导出药品标签关系列表") + @RequiresPermissions("health:MedicineTagsRel:export") + @Log(title = "药品标签关系", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, HealthMedicineTagsRelDto healthMedicineTagsRelDto) + { + List list = healthMedicineTagsRelService.selectHealthMedicineTagsRelList(healthMedicineTagsRelDto); + ExcelUtil util = new ExcelUtil(HealthMedicineTagsRelVo.class); + util.exportExcel(response, list, "药品标签关系数据"); + } + + /** + * 获取药品标签关系详细信息 + */ + @ApiOperation(value="获取药品标签关系详细信息") + @RequiresPermissions("health:MedicineTagsRel:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(healthMedicineTagsRelService.selectHealthMedicineTagsRelById(id)); + } + + /** + * 新增药品标签关系 + */ + @ApiOperation(value="新增药品标签关系") + @RequiresPermissions("health:MedicineTagsRel:add") + @Log(title = "药品标签关系", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody HealthMedicineTagsRel healthMedicineTagsRel) + { + return toAjax(healthMedicineTagsRelService.insertHealthMedicineTagsRel(healthMedicineTagsRel)); + } + + /** + * 修改药品标签关系 + */ + @ApiOperation(value="修改药品标签关系") + @RequiresPermissions("health:MedicineTagsRel:edit") + @Log(title = "药品标签关系", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody HealthMedicineTagsRel healthMedicineTagsRel) + { + return toAjax(healthMedicineTagsRelService.updateHealthMedicineTagsRel(healthMedicineTagsRel)); + } + + /** + * 删除药品标签关系 + */ + @ApiOperation(value="删除药品标签关系") + @RequiresPermissions("health:MedicineTagsRel:remove") + @Log(title = "药品标签关系", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(healthMedicineTagsRelService.deleteHealthMedicineTagsRelByIds(ids)); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthDiseases.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthDiseases.java new file mode 100644 index 0000000..06b0a41 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthDiseases.java @@ -0,0 +1,90 @@ +package com.ruoyi.health.domain; + +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.core.annotation.Excel; +import com.ruoyi.common.core.web.domain.BaseEntity; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import javax.validation.constraints.*; +/** + * 常见疾病治疗对象 health_diseases + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("常见疾病治疗对象") +@Data +public class HealthDiseases extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 名称 */ + @ApiModelProperty(value="名称)") + @NotNull(message="名称不能为空") + @Excel(name = "名称") + private String name; + + /** 类型 */ + @ApiModelProperty(value="类型)") + @NotNull(message="类型不能为空") + @Excel(name = "类型") + private String type; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + /** 症状 */ + @ApiModelProperty(value="症状)") + @NotNull(message="症状不能为空") + @Excel(name = "症状") + private String symptom; + + /** 检查项目 */ + @ApiModelProperty(value="检查项目") + @Excel(name = "检查项目") + private String inspectionItems; + + /** 药物治疗 */ + @ApiModelProperty(value="药物治疗") + @Excel(name = "药物治疗") + private String medicalTreatment; + + /** 中医治疗 */ + private String tcmTreatment; + + /** 手术治疗 */ + private String surgicalTreatment; + + /** 物理治疗 */ + private String physicalTreatment; + + /** 其他方式 */ + private String otherTreatment; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("type", getType()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .append("symptom", getSymptom()) + .append("inspectionItems", getInspectionItems()) + .append("medicalTreatment", getMedicalTreatment()) + .append("tcmTreatment", getTcmTreatment()) + .append("surgicalTreatment", getSurgicalTreatment()) + .append("physicalTreatment", getPhysicalTreatment()) + .append("otherTreatment", getOtherTreatment()) + .toString(); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthMedicineTags.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthMedicineTags.java new file mode 100644 index 0000000..4df9a71 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthMedicineTags.java @@ -0,0 +1,74 @@ +package com.ruoyi.health.domain; + +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.core.annotation.Excel; +import com.ruoyi.common.core.web.domain.BaseEntity; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import javax.validation.constraints.*; +/** + * 标签管理对象 health_medicine_tags + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("标签管理对象") +@Data +public class HealthMedicineTags extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 名称 */ + @ApiModelProperty(value="名称)") + @NotNull(message="名称不能为空") + @Excel(name = "名称") + private String name; + + /** 类型,1药品标签 */ + @ApiModelProperty(value="类型,1药品标签)") + @NotNull(message="类型,1药品标签不能为空") + @Excel(name = "类型,1药品标签") + private String type; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + /** 编码 */ + @ApiModelProperty(value="编码)") + @NotNull(message="编码不能为空") + @Excel(name = "编码") + private String code; + + /** 属性 */ + @ApiModelProperty(value="属性") + @Excel(name = "属性") + private String atttibute; + + /** 额外属性 */ + @ApiModelProperty(value="额外属性") + @Excel(name = "额外属性") + private String atttibuteExtra; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("type", getType()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .append("code", getCode()) + .append("atttibute", getAtttibute()) + .append("atttibuteExtra", getAtttibuteExtra()) + .toString(); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthMedicineTagsRel.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthMedicineTagsRel.java new file mode 100644 index 0000000..29c1f7e --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/HealthMedicineTagsRel.java @@ -0,0 +1,53 @@ +package com.ruoyi.health.domain; + +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.core.annotation.Excel; +import com.ruoyi.common.core.web.domain.BaseEntity; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import javax.validation.constraints.*; +/** + * 药品标签关系对象 health_medicine_tags_rel + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("药品标签关系对象") +@Data +public class HealthMedicineTagsRel extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 标签id */ + @ApiModelProperty(value="标签id") + @Excel(name = "标签id") + private Long tagId; + + /** 药品id */ + @ApiModelProperty(value="药品id") + @Excel(name = "药品id") + private Long medicineId; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("tagId", getTagId()) + .append("medicineId", getMedicineId()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .toString(); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthDiseasesDto.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthDiseasesDto.java new file mode 100644 index 0000000..7e7b9c8 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthDiseasesDto.java @@ -0,0 +1,31 @@ +package com.ruoyi.health.domain.dto; + +import lombok.Data; +import java.io.Serializable; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +/** + * 常见疾病治疗Dto对象 health_diseases + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("常见疾病治疗Dto对象") +@Data +public class HealthDiseasesDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 名称 */ + @ApiModelProperty(value="名称") + private String name; + + /** 类型 */ + @ApiModelProperty(value="类型") + private String type; + + /** 症状 */ + @ApiModelProperty(value="症状") + private String symptom; + +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthMedicineTagsDto.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthMedicineTagsDto.java new file mode 100644 index 0000000..d7946dd --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthMedicineTagsDto.java @@ -0,0 +1,31 @@ +package com.ruoyi.health.domain.dto; + +import lombok.Data; +import java.io.Serializable; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +/** + * 标签管理Dto对象 health_medicine_tags + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("标签管理Dto对象") +@Data +public class HealthMedicineTagsDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 名称 */ + @ApiModelProperty(value="名称") + private String name; + + /** 类型,1药品标签 */ + @ApiModelProperty(value="类型,1药品标签") + private String type; + + /** 编码 */ + @ApiModelProperty(value="编码") + private String code; + +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthMedicineTagsRelDto.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthMedicineTagsRelDto.java new file mode 100644 index 0000000..d86aa28 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/dto/HealthMedicineTagsRelDto.java @@ -0,0 +1,27 @@ +package com.ruoyi.health.domain.dto; + +import lombok.Data; +import java.io.Serializable; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +/** + * 药品标签关系Dto对象 health_medicine_tags_rel + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("药品标签关系Dto对象") +@Data +public class HealthMedicineTagsRelDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 标签id */ + @ApiModelProperty(value="标签id") + private Long tagId; + + /** 药品id */ + @ApiModelProperty(value="药品id") + private Long medicineId; + +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthDiseasesVo.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthDiseasesVo.java new file mode 100644 index 0000000..cbf7793 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthDiseasesVo.java @@ -0,0 +1,17 @@ +package com.ruoyi.health.domain.vo; + +import com.ruoyi.health.domain.HealthDiseases; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 常见疾病治疗Vo对象 health_diseases + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("常见疾病治疗Vo对象") +@Data +public class HealthDiseasesVo extends HealthDiseases +{ + +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthMedicineTagsRelVo.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthMedicineTagsRelVo.java new file mode 100644 index 0000000..341c950 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthMedicineTagsRelVo.java @@ -0,0 +1,17 @@ +package com.ruoyi.health.domain.vo; + +import com.ruoyi.health.domain.HealthMedicineTagsRel; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 药品标签关系Vo对象 health_medicine_tags_rel + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("药品标签关系Vo对象") +@Data +public class HealthMedicineTagsRelVo extends HealthMedicineTagsRel +{ + +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthMedicineTagsVo.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthMedicineTagsVo.java new file mode 100644 index 0000000..e6ac1a9 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/domain/vo/HealthMedicineTagsVo.java @@ -0,0 +1,17 @@ +package com.ruoyi.health.domain.vo; + +import com.ruoyi.health.domain.HealthMedicineTags; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 标签管理Vo对象 health_medicine_tags + * + * @author tianyongbao + * @date 2025-01-14 + */ +@ApiModel("标签管理Vo对象") +@Data +public class HealthMedicineTagsVo extends HealthMedicineTags +{ + +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthDiseasesMapper.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthDiseasesMapper.java new file mode 100644 index 0000000..c97b8b7 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthDiseasesMapper.java @@ -0,0 +1,79 @@ +package com.ruoyi.health.mapper; + +import java.util.List; +import com.ruoyi.health.domain.HealthDiseases; +import com.ruoyi.health.domain.dto.HealthDiseasesDto; +import com.ruoyi.health.domain.vo.HealthDiseasesVo; + +/** + * 常见疾病治疗Mapper接口 + * + * @author tianyongbao + * @date 2025-01-14 + */ +public interface HealthDiseasesMapper +{ + /** + * 查询常见疾病治疗 + * + * @param id 常见疾病治疗主键 + * @return 常见疾病治疗 + */ + public HealthDiseasesVo selectHealthDiseasesById(Long id); + + /** + * 查询常见疾病治疗列表 + * + * @param healthDiseasesDto 常见疾病治疗 + * @return 常见疾病治疗集合 + */ + public List selectHealthDiseasesList(HealthDiseasesDto healthDiseasesDto); + + /** + * 新增常见疾病治疗 + * + * @param healthDiseases 常见疾病治疗 + * @return 结果 + */ + public int insertHealthDiseases(HealthDiseases healthDiseases); + + /** + * 修改常见疾病治疗 + * + * @param healthDiseases 常见疾病治疗 + * @return 结果 + */ + public int updateHealthDiseases(HealthDiseases healthDiseases); + + /** + * 删除常见疾病治疗 + * + * @param id 常见疾病治疗主键 + * @return 结果 + */ + public int deleteHealthDiseasesById(Long id); + + /** + * 批量删除常见疾病治疗 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteHealthDiseasesByIds(Long[] ids); + + /** + * 逻辑删除常见疾病治疗 + * + * @param id 常见疾病治疗主键 + * @return 结果 + */ + public int removeHealthDiseasesById(Long id); + + /** + * 批量逻辑删除常见疾病治疗 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeHealthDiseasesByIds(Long[] ids); +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthMedicineTagsMapper.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthMedicineTagsMapper.java new file mode 100644 index 0000000..13ba3e2 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthMedicineTagsMapper.java @@ -0,0 +1,79 @@ +package com.ruoyi.health.mapper; + +import java.util.List; +import com.ruoyi.health.domain.HealthMedicineTags; +import com.ruoyi.health.domain.dto.HealthMedicineTagsDto; +import com.ruoyi.health.domain.vo.HealthMedicineTagsVo; + +/** + * 标签管理Mapper接口 + * + * @author tianyongbao + * @date 2025-01-14 + */ +public interface HealthMedicineTagsMapper +{ + /** + * 查询标签管理 + * + * @param id 标签管理主键 + * @return 标签管理 + */ + public HealthMedicineTagsVo selectHealthMedicineTagsById(Long id); + + /** + * 查询标签管理列表 + * + * @param healthMedicineTagsDto 标签管理 + * @return 标签管理集合 + */ + public List selectHealthMedicineTagsList(HealthMedicineTagsDto healthMedicineTagsDto); + + /** + * 新增标签管理 + * + * @param healthMedicineTags 标签管理 + * @return 结果 + */ + public int insertHealthMedicineTags(HealthMedicineTags healthMedicineTags); + + /** + * 修改标签管理 + * + * @param healthMedicineTags 标签管理 + * @return 结果 + */ + public int updateHealthMedicineTags(HealthMedicineTags healthMedicineTags); + + /** + * 删除标签管理 + * + * @param id 标签管理主键 + * @return 结果 + */ + public int deleteHealthMedicineTagsById(Long id); + + /** + * 批量删除标签管理 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteHealthMedicineTagsByIds(Long[] ids); + + /** + * 逻辑删除标签管理 + * + * @param id 标签管理主键 + * @return 结果 + */ + public int removeHealthMedicineTagsById(Long id); + + /** + * 批量逻辑删除标签管理 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeHealthMedicineTagsByIds(Long[] ids); +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthMedicineTagsRelMapper.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthMedicineTagsRelMapper.java new file mode 100644 index 0000000..d878c55 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/mapper/HealthMedicineTagsRelMapper.java @@ -0,0 +1,79 @@ +package com.ruoyi.health.mapper; + +import java.util.List; +import com.ruoyi.health.domain.HealthMedicineTagsRel; +import com.ruoyi.health.domain.dto.HealthMedicineTagsRelDto; +import com.ruoyi.health.domain.vo.HealthMedicineTagsRelVo; + +/** + * 药品标签关系Mapper接口 + * + * @author tianyongbao + * @date 2025-01-14 + */ +public interface HealthMedicineTagsRelMapper +{ + /** + * 查询药品标签关系 + * + * @param id 药品标签关系主键 + * @return 药品标签关系 + */ + public HealthMedicineTagsRelVo selectHealthMedicineTagsRelById(Long id); + + /** + * 查询药品标签关系列表 + * + * @param healthMedicineTagsRelDto 药品标签关系 + * @return 药品标签关系集合 + */ + public List selectHealthMedicineTagsRelList(HealthMedicineTagsRelDto healthMedicineTagsRelDto); + + /** + * 新增药品标签关系 + * + * @param healthMedicineTagsRel 药品标签关系 + * @return 结果 + */ + public int insertHealthMedicineTagsRel(HealthMedicineTagsRel healthMedicineTagsRel); + + /** + * 修改药品标签关系 + * + * @param healthMedicineTagsRel 药品标签关系 + * @return 结果 + */ + public int updateHealthMedicineTagsRel(HealthMedicineTagsRel healthMedicineTagsRel); + + /** + * 删除药品标签关系 + * + * @param id 药品标签关系主键 + * @return 结果 + */ + public int deleteHealthMedicineTagsRelById(Long id); + + /** + * 批量删除药品标签关系 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteHealthMedicineTagsRelByIds(Long[] ids); + + /** + * 逻辑删除药品标签关系 + * + * @param id 药品标签关系主键 + * @return 结果 + */ + public int removeHealthMedicineTagsRelById(Long id); + + /** + * 批量逻辑删除药品标签关系 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeHealthMedicineTagsRelByIds(Long[] ids); +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthDiseasesService.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthDiseasesService.java new file mode 100644 index 0000000..eed64e4 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthDiseasesService.java @@ -0,0 +1,63 @@ +package com.ruoyi.health.service; + +import java.util.List; +import com.ruoyi.health.domain.HealthDiseases; +import com.ruoyi.health.domain.dto.HealthDiseasesDto; +import com.ruoyi.health.domain.vo.HealthDiseasesVo; + +/** + * 常见疾病治疗Service接口 + * + * @author tianyongbao + * @date 2025-01-14 + */ +public interface IHealthDiseasesService +{ + /** + * 查询常见疾病治疗 + * + * @param id 常见疾病治疗主键 + * @return 常见疾病治疗 + */ + public HealthDiseasesVo selectHealthDiseasesById(Long id); + + /** + * 查询常见疾病治疗列表 + * + * @param healthDiseasesDto 常见疾病治疗 + * @return 常见疾病治疗集合 + */ + public List selectHealthDiseasesList(HealthDiseasesDto healthDiseasesDto); + + /** + * 新增常见疾病治疗 + * + * @param healthDiseases 常见疾病治疗 + * @return 结果 + */ + public int insertHealthDiseases(HealthDiseases healthDiseases); + + /** + * 修改常见疾病治疗 + * + * @param healthDiseases 常见疾病治疗 + * @return 结果 + */ + public int updateHealthDiseases(HealthDiseases healthDiseases); + + /** + * 批量删除常见疾病治疗 + * + * @param ids 需要删除的常见疾病治疗主键集合 + * @return 结果 + */ + public int deleteHealthDiseasesByIds(Long[] ids); + + /** + * 删除常见疾病治疗信息 + * + * @param id 常见疾病治疗主键 + * @return 结果 + */ + public int deleteHealthDiseasesById(Long id); +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthMedicineTagsRelService.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthMedicineTagsRelService.java new file mode 100644 index 0000000..215b05c --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthMedicineTagsRelService.java @@ -0,0 +1,63 @@ +package com.ruoyi.health.service; + +import java.util.List; +import com.ruoyi.health.domain.HealthMedicineTagsRel; +import com.ruoyi.health.domain.dto.HealthMedicineTagsRelDto; +import com.ruoyi.health.domain.vo.HealthMedicineTagsRelVo; + +/** + * 药品标签关系Service接口 + * + * @author tianyongbao + * @date 2025-01-14 + */ +public interface IHealthMedicineTagsRelService +{ + /** + * 查询药品标签关系 + * + * @param id 药品标签关系主键 + * @return 药品标签关系 + */ + public HealthMedicineTagsRelVo selectHealthMedicineTagsRelById(Long id); + + /** + * 查询药品标签关系列表 + * + * @param healthMedicineTagsRelDto 药品标签关系 + * @return 药品标签关系集合 + */ + public List selectHealthMedicineTagsRelList(HealthMedicineTagsRelDto healthMedicineTagsRelDto); + + /** + * 新增药品标签关系 + * + * @param healthMedicineTagsRel 药品标签关系 + * @return 结果 + */ + public int insertHealthMedicineTagsRel(HealthMedicineTagsRel healthMedicineTagsRel); + + /** + * 修改药品标签关系 + * + * @param healthMedicineTagsRel 药品标签关系 + * @return 结果 + */ + public int updateHealthMedicineTagsRel(HealthMedicineTagsRel healthMedicineTagsRel); + + /** + * 批量删除药品标签关系 + * + * @param ids 需要删除的药品标签关系主键集合 + * @return 结果 + */ + public int deleteHealthMedicineTagsRelByIds(Long[] ids); + + /** + * 删除药品标签关系信息 + * + * @param id 药品标签关系主键 + * @return 结果 + */ + public int deleteHealthMedicineTagsRelById(Long id); +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthMedicineTagsService.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthMedicineTagsService.java new file mode 100644 index 0000000..fdedbfa --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/IHealthMedicineTagsService.java @@ -0,0 +1,63 @@ +package com.ruoyi.health.service; + +import java.util.List; +import com.ruoyi.health.domain.HealthMedicineTags; +import com.ruoyi.health.domain.dto.HealthMedicineTagsDto; +import com.ruoyi.health.domain.vo.HealthMedicineTagsVo; + +/** + * 标签管理Service接口 + * + * @author tianyongbao + * @date 2025-01-14 + */ +public interface IHealthMedicineTagsService +{ + /** + * 查询标签管理 + * + * @param id 标签管理主键 + * @return 标签管理 + */ + public HealthMedicineTagsVo selectHealthMedicineTagsById(Long id); + + /** + * 查询标签管理列表 + * + * @param healthMedicineTagsDto 标签管理 + * @return 标签管理集合 + */ + public List selectHealthMedicineTagsList(HealthMedicineTagsDto healthMedicineTagsDto); + + /** + * 新增标签管理 + * + * @param healthMedicineTags 标签管理 + * @return 结果 + */ + public int insertHealthMedicineTags(HealthMedicineTags healthMedicineTags); + + /** + * 修改标签管理 + * + * @param healthMedicineTags 标签管理 + * @return 结果 + */ + public int updateHealthMedicineTags(HealthMedicineTags healthMedicineTags); + + /** + * 批量删除标签管理 + * + * @param ids 需要删除的标签管理主键集合 + * @return 结果 + */ + public int deleteHealthMedicineTagsByIds(Long[] ids); + + /** + * 删除标签管理信息 + * + * @param id 标签管理主键 + * @return 结果 + */ + public int deleteHealthMedicineTagsById(Long id); +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthDiseasesServiceImpl.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthDiseasesServiceImpl.java new file mode 100644 index 0000000..7b32e7b --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthDiseasesServiceImpl.java @@ -0,0 +1,104 @@ +package com.ruoyi.health.service.impl; + +import com.ruoyi.common.core.utils.DateUtils; +import com.ruoyi.common.core.utils.IdWorker; +import com.ruoyi.common.security.utils.SecurityUtils; +import com.ruoyi.health.domain.HealthDiseases; +import com.ruoyi.health.domain.dto.HealthDiseasesDto; +import com.ruoyi.health.domain.vo.HealthDiseasesVo; +import com.ruoyi.health.mapper.HealthDiseasesMapper; +import com.ruoyi.health.service.IHealthDiseasesService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 常见疾病治疗Service业务层处理 + * + * @author tianyongbao + * @date 2025-01-14 + */ +@Service +public class HealthDiseasesServiceImpl implements IHealthDiseasesService +{ + @Resource + private HealthDiseasesMapper healthDiseasesMapper; + + /** + * 查询常见疾病治疗 + * + * @param id 常见疾病治疗主键 + * @return 常见疾病治疗 + */ + @Override + public HealthDiseasesVo selectHealthDiseasesById(Long id) + { + return healthDiseasesMapper.selectHealthDiseasesById(id); + } + + /** + * 查询常见疾病治疗列表 + * + * @param healthDiseasesDto 常见疾病治疗 + * @return 常见疾病治疗 + */ + @Override + public List selectHealthDiseasesList(HealthDiseasesDto healthDiseasesDto) + { + return healthDiseasesMapper.selectHealthDiseasesList(healthDiseasesDto); + } + + /** + * 新增常见疾病治疗 + * + * @param healthDiseases 常见疾病治疗 + * @return 结果 + */ + @Override + public int insertHealthDiseases(HealthDiseases healthDiseases) + { + healthDiseases.setCreateBy(SecurityUtils.getUsername()); + healthDiseases.setCreateTime(DateUtils.getNowDate()); + healthDiseases.setId(IdWorker.getId()); + return healthDiseasesMapper.insertHealthDiseases(healthDiseases); + } + + /** + * 修改常见疾病治疗 + * + * @param healthDiseases 常见疾病治疗 + * @return 结果 + */ + @Override + public int updateHealthDiseases(HealthDiseases healthDiseases) + { + healthDiseases.setUpdateBy(SecurityUtils.getUsername()); + healthDiseases.setUpdateTime(DateUtils.getNowDate()); + return healthDiseasesMapper.updateHealthDiseases(healthDiseases); + } + + /** + * 批量删除常见疾病治疗 + * + * @param ids 需要删除的常见疾病治疗主键 + * @return 结果 + */ + @Override + public int deleteHealthDiseasesByIds(Long[] ids) + { + return healthDiseasesMapper.removeHealthDiseasesByIds(ids); + } + + /** + * 删除常见疾病治疗信息 + * + * @param id 常见疾病治疗主键 + * @return 结果 + */ + @Override + public int deleteHealthDiseasesById(Long id) + { + return healthDiseasesMapper.removeHealthDiseasesById(id); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthMedicineTagsRelServiceImpl.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthMedicineTagsRelServiceImpl.java new file mode 100644 index 0000000..94b8643 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthMedicineTagsRelServiceImpl.java @@ -0,0 +1,104 @@ +package com.ruoyi.health.service.impl; + +import com.ruoyi.common.core.utils.DateUtils; +import com.ruoyi.common.core.utils.IdWorker; +import com.ruoyi.common.security.utils.SecurityUtils; +import com.ruoyi.health.domain.HealthMedicineTagsRel; +import com.ruoyi.health.domain.dto.HealthMedicineTagsRelDto; +import com.ruoyi.health.domain.vo.HealthMedicineTagsRelVo; +import com.ruoyi.health.mapper.HealthMedicineTagsRelMapper; +import com.ruoyi.health.service.IHealthMedicineTagsRelService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 药品标签关系Service业务层处理 + * + * @author tianyongbao + * @date 2025-01-14 + */ +@Service +public class HealthMedicineTagsRelServiceImpl implements IHealthMedicineTagsRelService +{ + @Resource + private HealthMedicineTagsRelMapper healthMedicineTagsRelMapper; + + /** + * 查询药品标签关系 + * + * @param id 药品标签关系主键 + * @return 药品标签关系 + */ + @Override + public HealthMedicineTagsRelVo selectHealthMedicineTagsRelById(Long id) + { + return healthMedicineTagsRelMapper.selectHealthMedicineTagsRelById(id); + } + + /** + * 查询药品标签关系列表 + * + * @param healthMedicineTagsRelDto 药品标签关系 + * @return 药品标签关系 + */ + @Override + public List selectHealthMedicineTagsRelList(HealthMedicineTagsRelDto healthMedicineTagsRelDto) + { + return healthMedicineTagsRelMapper.selectHealthMedicineTagsRelList(healthMedicineTagsRelDto); + } + + /** + * 新增药品标签关系 + * + * @param healthMedicineTagsRel 药品标签关系 + * @return 结果 + */ + @Override + public int insertHealthMedicineTagsRel(HealthMedicineTagsRel healthMedicineTagsRel) + { + healthMedicineTagsRel.setCreateBy(SecurityUtils.getUsername()); + healthMedicineTagsRel.setCreateTime(DateUtils.getNowDate()); + healthMedicineTagsRel.setId(IdWorker.getId()); + return healthMedicineTagsRelMapper.insertHealthMedicineTagsRel(healthMedicineTagsRel); + } + + /** + * 修改药品标签关系 + * + * @param healthMedicineTagsRel 药品标签关系 + * @return 结果 + */ + @Override + public int updateHealthMedicineTagsRel(HealthMedicineTagsRel healthMedicineTagsRel) + { + healthMedicineTagsRel.setUpdateBy(SecurityUtils.getUsername()); + healthMedicineTagsRel.setUpdateTime(DateUtils.getNowDate()); + return healthMedicineTagsRelMapper.updateHealthMedicineTagsRel(healthMedicineTagsRel); + } + + /** + * 批量删除药品标签关系 + * + * @param ids 需要删除的药品标签关系主键 + * @return 结果 + */ + @Override + public int deleteHealthMedicineTagsRelByIds(Long[] ids) + { + return healthMedicineTagsRelMapper.removeHealthMedicineTagsRelByIds(ids); + } + + /** + * 删除药品标签关系信息 + * + * @param id 药品标签关系主键 + * @return 结果 + */ + @Override + public int deleteHealthMedicineTagsRelById(Long id) + { + return healthMedicineTagsRelMapper.removeHealthMedicineTagsRelById(id); + } +} diff --git a/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthMedicineTagsServiceImpl.java b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthMedicineTagsServiceImpl.java new file mode 100644 index 0000000..678141e --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/java/com/ruoyi/health/service/impl/HealthMedicineTagsServiceImpl.java @@ -0,0 +1,104 @@ +package com.ruoyi.health.service.impl; + +import com.ruoyi.common.core.utils.DateUtils; +import com.ruoyi.common.core.utils.IdWorker; +import com.ruoyi.common.security.utils.SecurityUtils; +import com.ruoyi.health.domain.HealthMedicineTags; +import com.ruoyi.health.domain.dto.HealthMedicineTagsDto; +import com.ruoyi.health.domain.vo.HealthMedicineTagsVo; +import com.ruoyi.health.mapper.HealthMedicineTagsMapper; +import com.ruoyi.health.service.IHealthMedicineTagsService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 标签管理Service业务层处理 + * + * @author tianyongbao + * @date 2025-01-14 + */ +@Service +public class HealthMedicineTagsServiceImpl implements IHealthMedicineTagsService +{ + @Resource + private HealthMedicineTagsMapper healthMedicineTagsMapper; + + /** + * 查询标签管理 + * + * @param id 标签管理主键 + * @return 标签管理 + */ + @Override + public HealthMedicineTagsVo selectHealthMedicineTagsById(Long id) + { + return healthMedicineTagsMapper.selectHealthMedicineTagsById(id); + } + + /** + * 查询标签管理列表 + * + * @param healthMedicineTagsDto 标签管理 + * @return 标签管理 + */ + @Override + public List selectHealthMedicineTagsList(HealthMedicineTagsDto healthMedicineTagsDto) + { + return healthMedicineTagsMapper.selectHealthMedicineTagsList(healthMedicineTagsDto); + } + + /** + * 新增标签管理 + * + * @param healthMedicineTags 标签管理 + * @return 结果 + */ + @Override + public int insertHealthMedicineTags(HealthMedicineTags healthMedicineTags) + { + healthMedicineTags.setCreateBy(SecurityUtils.getUsername()); + healthMedicineTags.setCreateTime(DateUtils.getNowDate()); + healthMedicineTags.setId(IdWorker.getId()); + return healthMedicineTagsMapper.insertHealthMedicineTags(healthMedicineTags); + } + + /** + * 修改标签管理 + * + * @param healthMedicineTags 标签管理 + * @return 结果 + */ + @Override + public int updateHealthMedicineTags(HealthMedicineTags healthMedicineTags) + { + healthMedicineTags.setUpdateBy(SecurityUtils.getUsername()); + healthMedicineTags.setUpdateTime(DateUtils.getNowDate()); + return healthMedicineTagsMapper.updateHealthMedicineTags(healthMedicineTags); + } + + /** + * 批量删除标签管理 + * + * @param ids 需要删除的标签管理主键 + * @return 结果 + */ + @Override + public int deleteHealthMedicineTagsByIds(Long[] ids) + { + return healthMedicineTagsMapper.removeHealthMedicineTagsByIds(ids); + } + + /** + * 删除标签管理信息 + * + * @param id 标签管理主键 + * @return 结果 + */ + @Override + public int deleteHealthMedicineTagsById(Long id) + { + return healthMedicineTagsMapper.removeHealthMedicineTagsById(id); + } +} diff --git a/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthDiseasesMapper.xml b/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthDiseasesMapper.xml new file mode 100644 index 0000000..3d36f94 --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthDiseasesMapper.xml @@ -0,0 +1,128 @@ + + + + + + + + + + + + + + + + + + + + + + + + + select a.id, a.name, a.type, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.remark, a.symptom, a.inspection_items, a.medical_treatment, a.tcm_treatment, a.surgical_treatment, a.physical_treatment, a.other_treatment from health_diseases a + + + + + + + + insert into health_diseases + + id, + name, + type, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + symptom, + inspection_items, + medical_treatment, + tcm_treatment, + surgical_treatment, + physical_treatment, + other_treatment, + + + #{id}, + #{name}, + #{type}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + #{symptom}, + #{inspectionItems}, + #{medicalTreatment}, + #{tcmTreatment}, + #{surgicalTreatment}, + #{physicalTreatment}, + #{otherTreatment}, + + + + + update health_diseases + + name = #{name}, + type = #{type}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + symptom = #{symptom}, + inspection_items = #{inspectionItems}, + medical_treatment = #{medicalTreatment}, + tcm_treatment = #{tcmTreatment}, + surgical_treatment = #{surgicalTreatment}, + physical_treatment = #{physicalTreatment}, + other_treatment = #{otherTreatment}, + + where id = #{id} + + + + delete from health_diseases where id = #{id} + + + + delete from health_diseases where id in + + #{id} + + + + update health_diseases set del_flag='1' where id = #{id} + + + + update health_diseases set del_flag='1' where id in + + #{id} + + + diff --git a/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthMedicineTagsMapper.xml b/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthMedicineTagsMapper.xml new file mode 100644 index 0000000..83bd58c --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthMedicineTagsMapper.xml @@ -0,0 +1,112 @@ + + + + + + + + + + + + + + + + + + + + + select a.id, a.name, a.type, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.remark, a.code, a.atttibute, a.atttibute_extra from health_medicine_tags a + + + + + + + + insert into health_medicine_tags + + id, + name, + type, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + code, + atttibute, + atttibute_extra, + + + #{id}, + #{name}, + #{type}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + #{code}, + #{atttibute}, + #{atttibuteExtra}, + + + + + update health_medicine_tags + + name = #{name}, + type = #{type}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + code = #{code}, + atttibute = #{atttibute}, + atttibute_extra = #{atttibuteExtra}, + + where id = #{id} + + + + delete from health_medicine_tags where id = #{id} + + + + delete from health_medicine_tags where id in + + #{id} + + + + update health_medicine_tags set del_flag='1' where id = #{id} + + + + update health_medicine_tags set del_flag='1' where id in + + #{id} + + + diff --git a/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthMedicineTagsRelMapper.xml b/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthMedicineTagsRelMapper.xml new file mode 100644 index 0000000..d68cf6d --- /dev/null +++ b/ruoyi-modules/intc-health/src/main/resources/mapper/health/HealthMedicineTagsRelMapper.xml @@ -0,0 +1,99 @@ + + + + + + + + + + + + + + + + + + select a.id, a.tag_id, a.medicine_id, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.remark from health_medicine_tags_rel a + + + + + + + + insert into health_medicine_tags_rel + + id, + tag_id, + medicine_id, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + + + #{id}, + #{tagId}, + #{medicineId}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + + + + + update health_medicine_tags_rel + + tag_id = #{tagId}, + medicine_id = #{medicineId}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + + where id = #{id} + + + + delete from health_medicine_tags_rel where id = #{id} + + + + delete from health_medicine_tags_rel where id in + + #{id} + + + + update health_medicine_tags_rel set del_flag='1' where id = #{id} + + + + update health_medicine_tags_rel set del_flag='1' where id in + + #{id} + + +