diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basedietinfo/BaseDietInfoController.java b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basedietinfo/BaseDietInfoController.java new file mode 100644 index 00000000..12981c08 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basedietinfo/BaseDietInfoController.java @@ -0,0 +1,91 @@ +package com.xinelu.manage.controller.basedietinfo; + +import com.xinelu.common.annotation.Log; +import com.xinelu.common.core.controller.BaseController; +import com.xinelu.common.core.domain.AjaxResult; +import com.xinelu.common.core.page.TableDataInfo; +import com.xinelu.common.enums.BusinessType; +import com.xinelu.common.utils.poi.ExcelUtil; +import com.xinelu.manage.domain.basedietinfo.BaseDietInfo; +import com.xinelu.manage.service.basedietinfo.IBaseDietInfoService; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + +/** + * 饮食知识库Controller + * + * @author xinelu + * @date 2024-05-17 + */ +@RestController +@RequestMapping("/system/baseDiet") +public class BaseDietInfoController extends BaseController { + @Resource + private IBaseDietInfoService baseDietInfoService; + + /** + * 查询饮食知识库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseDiet:list')") + @GetMapping("/list") + public TableDataInfo list(BaseDietInfo baseDietInfo) { + startPage(); + List list = baseDietInfoService.selectBaseDietInfoList(baseDietInfo); + return getDataTable(list); + } + + /** + * 导出饮食知识库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseDiet:export')") + @Log(title = "饮食知识库", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, BaseDietInfo baseDietInfo) { + List list = baseDietInfoService.selectBaseDietInfoList(baseDietInfo); + ExcelUtil util = new ExcelUtil<>(BaseDietInfo.class); + util.exportExcel(response, list, "饮食知识库数据"); + } + + /** + * 获取饮食知识库详细信息 + */ + @PreAuthorize("@ss.hasPermi('system:baseDiet:query')") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) { + return AjaxResult.success(baseDietInfoService.selectBaseDietInfoById(id)); + } + + /** + * 新增饮食知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseDiet:add')") + @Log(title = "饮食知识库", businessType = BusinessType.INSERT) + @PostMapping("/add") + public AjaxResult add(@RequestBody BaseDietInfo baseDietInfo) { + return toAjax(baseDietInfoService.insertBaseDietInfo(baseDietInfo)); + } + + /** + * 修改饮食知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseDiet:edit')") + @Log(title = "饮食知识库", businessType = BusinessType.UPDATE) + @PutMapping("/edit") + public AjaxResult edit(@RequestBody BaseDietInfo baseDietInfo) { + return toAjax(baseDietInfoService.updateBaseDietInfo(baseDietInfo)); + } + + /** + * 删除饮食知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseDiet:remove')") + @Log(title = "饮食知识库", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(baseDietInfoService.deleteBaseDietInfoByIds(ids)); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basedruginfo/BaseDrugInfoController.java b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basedruginfo/BaseDrugInfoController.java new file mode 100644 index 00000000..fbd34c5e --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basedruginfo/BaseDrugInfoController.java @@ -0,0 +1,91 @@ +package com.xinelu.manage.controller.basedruginfo; + +import com.xinelu.common.annotation.Log; +import com.xinelu.common.core.controller.BaseController; +import com.xinelu.common.core.domain.AjaxResult; +import com.xinelu.common.core.page.TableDataInfo; +import com.xinelu.common.enums.BusinessType; +import com.xinelu.common.utils.poi.ExcelUtil; +import com.xinelu.manage.domain.basedruginfo.BaseDrugInfo; +import com.xinelu.manage.service.basedruginfo.IBaseDrugInfoService; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + +/** + * 药品库Controller + * + * @author xinelu + * @date 2024-05-17 + */ +@RestController +@RequestMapping("/system/baseDrug") +public class BaseDrugInfoController extends BaseController { + @Resource + private IBaseDrugInfoService baseDrugInfoService; + + /** + * 查询药品库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseDrug:list')") + @GetMapping("/list") + public TableDataInfo list(BaseDrugInfo baseDrugInfo) { + startPage(); + List list = baseDrugInfoService.selectBaseDrugInfoList(baseDrugInfo); + return getDataTable(list); + } + + /** + * 导出药品库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseDrug:export')") + @Log(title = "药品库", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, BaseDrugInfo baseDrugInfo) { + List list = baseDrugInfoService.selectBaseDrugInfoList(baseDrugInfo); + ExcelUtil util = new ExcelUtil<>(BaseDrugInfo.class); + util.exportExcel(response, list, "药品库数据"); + } + + /** + * 获取药品库详细信息 + */ + @PreAuthorize("@ss.hasPermi('system:baseDrug:query')") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) { + return AjaxResult.success(baseDrugInfoService.selectBaseDrugInfoById(id)); + } + + /** + * 新增药品库 + */ + @PreAuthorize("@ss.hasPermi('system:baseDrug:add')") + @Log(title = "药品库", businessType = BusinessType.INSERT) + @PostMapping("/add") + public AjaxResult add(@RequestBody BaseDrugInfo baseDrugInfo) { + return toAjax(baseDrugInfoService.insertBaseDrugInfo(baseDrugInfo)); + } + + /** + * 修改药品库 + */ + @PreAuthorize("@ss.hasPermi('system:baseDrug:edit')") + @Log(title = "药品库", businessType = BusinessType.UPDATE) + @PutMapping("/edit") + public AjaxResult edit(@RequestBody BaseDrugInfo baseDrugInfo) { + return toAjax(baseDrugInfoService.updateBaseDrugInfo(baseDrugInfo)); + } + + /** + * 删除药品库 + */ + @PreAuthorize("@ss.hasPermi('system:baseDrug:remove')") + @Log(title = "药品库", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(baseDrugInfoService.deleteBaseDrugInfoByIds(ids)); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basenursinginfo/BaseNursingInfoController.java b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basenursinginfo/BaseNursingInfoController.java new file mode 100644 index 00000000..4f319b40 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basenursinginfo/BaseNursingInfoController.java @@ -0,0 +1,91 @@ +package com.xinelu.manage.controller.basenursinginfo; + +import com.xinelu.common.annotation.Log; +import com.xinelu.common.core.controller.BaseController; +import com.xinelu.common.core.domain.AjaxResult; +import com.xinelu.common.core.page.TableDataInfo; +import com.xinelu.common.enums.BusinessType; +import com.xinelu.common.utils.poi.ExcelUtil; +import com.xinelu.manage.domain.basenursinginfo.BaseNursingInfo; +import com.xinelu.manage.service.basenursinginfo.IBaseNursingInfoService; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + +/** + * 护理知识库Controller + * + * @author xinelu + * @date 2024-05-17 + */ +@RestController +@RequestMapping("/system/baseNursing") +public class BaseNursingInfoController extends BaseController { + @Resource + private IBaseNursingInfoService baseNursingInfoService; + + /** + * 查询护理知识库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseNursing:list')") + @GetMapping("/list") + public TableDataInfo list(BaseNursingInfo baseNursingInfo) { + startPage(); + List list = baseNursingInfoService.selectBaseNursingInfoList(baseNursingInfo); + return getDataTable(list); + } + + /** + * 导出护理知识库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseNursing:export')") + @Log(title = "护理知识库", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, BaseNursingInfo baseNursingInfo) { + List list = baseNursingInfoService.selectBaseNursingInfoList(baseNursingInfo); + ExcelUtil util = new ExcelUtil<>(BaseNursingInfo.class); + util.exportExcel(response, list, "护理知识库数据"); + } + + /** + * 获取护理知识库详细信息 + */ + @PreAuthorize("@ss.hasPermi('system:baseNursing:query')") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) { + return AjaxResult.success(baseNursingInfoService.selectBaseNursingInfoById(id)); + } + + /** + * 新增护理知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseNursing:add')") + @Log(title = "护理知识库", businessType = BusinessType.INSERT) + @PostMapping("/add") + public AjaxResult add(@RequestBody BaseNursingInfo baseNursingInfo) { + return toAjax(baseNursingInfoService.insertBaseNursingInfo(baseNursingInfo)); + } + + /** + * 修改护理知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseNursing:edit')") + @Log(title = "护理知识库", businessType = BusinessType.UPDATE) + @PutMapping("/edit") + public AjaxResult edit(@RequestBody BaseNursingInfo baseNursingInfo) { + return toAjax(baseNursingInfoService.updateBaseNursingInfo(baseNursingInfo)); + } + + /** + * 删除护理知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseNursing:remove')") + @Log(title = "护理知识库", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(baseNursingInfoService.deleteBaseNursingInfoByIds(ids)); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basesportinfo/BaseSportInfoController.java b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basesportinfo/BaseSportInfoController.java new file mode 100644 index 00000000..fe96e7f3 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/controller/basesportinfo/BaseSportInfoController.java @@ -0,0 +1,91 @@ +package com.xinelu.manage.controller.basesportinfo; + +import com.xinelu.common.annotation.Log; +import com.xinelu.common.core.controller.BaseController; +import com.xinelu.common.core.domain.AjaxResult; +import com.xinelu.common.core.page.TableDataInfo; +import com.xinelu.common.enums.BusinessType; +import com.xinelu.common.utils.poi.ExcelUtil; +import com.xinelu.manage.domain.basesportinfo.BaseSportInfo; +import com.xinelu.manage.service.basesportinfo.IBaseSportInfoService; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + +/** + * 运动知识库Controller + * + * @author xinelu + * @date 2024-05-16 + */ +@RestController +@RequestMapping("/system/baseSport") +public class BaseSportInfoController extends BaseController { + @Resource + private IBaseSportInfoService baseSportInfoService; + + /** + * 查询运动知识库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseSport:list')") + @GetMapping("/list") + public TableDataInfo list(BaseSportInfo baseSportInfo) { + startPage(); + List list = baseSportInfoService.selectBaseSportInfoList(baseSportInfo); + return getDataTable(list); + } + + /** + * 导出运动知识库列表 + */ + @PreAuthorize("@ss.hasPermi('system:baseSport:export')") + @Log(title = "运动知识库", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, BaseSportInfo baseSportInfo) { + List list = baseSportInfoService.selectBaseSportInfoList(baseSportInfo); + ExcelUtil util = new ExcelUtil<>(BaseSportInfo.class); + util.exportExcel(response, list, "运动知识库数据"); + } + + /** + * 获取运动知识库详细信息 + */ + @PreAuthorize("@ss.hasPermi('system:baseSport:query')") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) { + return AjaxResult.success(baseSportInfoService.selectBaseSportInfoById(id)); + } + + /** + * 新增运动知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseSport:add')") + @Log(title = "运动知识库", businessType = BusinessType.INSERT) + @PostMapping("/add") + public AjaxResult add(@RequestBody BaseSportInfo baseSportInfo) { + return toAjax(baseSportInfoService.insertBaseSportInfo(baseSportInfo)); + } + + /** + * 修改运动知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseSport:edit')") + @Log(title = "运动知识库", businessType = BusinessType.UPDATE) + @PutMapping("/edit") + public AjaxResult edit(@RequestBody BaseSportInfo baseSportInfo) { + return toAjax(baseSportInfoService.updateBaseSportInfo(baseSportInfo)); + } + + /** + * 删除运动知识库 + */ + @PreAuthorize("@ss.hasPermi('system:baseSport:remove')") + @Log(title = "运动知识库", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(baseSportInfoService.deleteBaseSportInfoByIds(ids)); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basedietinfo/BaseDietInfo.java b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basedietinfo/BaseDietInfo.java new file mode 100644 index 00000000..6a47bf7c --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basedietinfo/BaseDietInfo.java @@ -0,0 +1,100 @@ +package com.xinelu.manage.domain.basedietinfo; + +import com.xinelu.common.annotation.Excel; +import com.xinelu.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 饮食知识库对象 base_diet_info + * + * @author xinelu + * @date 2024-05-17 + */ +@Data +@AllArgsConstructor +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +@ApiModel(value = "饮食知识库对象", description = "base_diet_info") +public class BaseDietInfo extends BaseEntity { + private static final long serialVersionUID = 1L; + + /** + * $column.columnComment + */ + private Long id; + + /** + * 饮食建议名称 + */ + @ApiModelProperty(value = "饮食建议名称") + @Excel(name = "饮食建议名称") + private String dietName; + + /** + * 饮食原则 + */ + @ApiModelProperty(value = "饮食原则") + @Excel(name = "饮食原则") + private String dietPrinciple; + + /** + * 主食推荐 + */ + @ApiModelProperty(value = "主食推荐") + @Excel(name = "主食推荐") + private String mainFood; + + /** + * 蔬菜推荐 + */ + @ApiModelProperty(value = "蔬菜推荐") + @Excel(name = "蔬菜推荐") + private String vegetable; + + /** + * 水果推荐 + */ + @ApiModelProperty(value = "水果推荐") + @Excel(name = "水果推荐") + private String fruit; + + /** + * 肉类推荐 + */ + @ApiModelProperty(value = "肉类推荐") + @Excel(name = "肉类推荐") + private String meat; + + /** + * 饮食说明 + */ + @ApiModelProperty(value = "饮食说明") + @Excel(name = "饮食说明") + private String dietRemark; + + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("dietName", getDietName()) + .append("dietPrinciple", getDietPrinciple()) + .append("mainFood", getMainFood()) + .append("vegetable", getVegetable()) + .append("fruit", getFruit()) + .append("meat", getMeat()) + .append("dietRemark", getDietRemark()) + .append("createTime", getCreateTime()) + .append("createBy", getCreateBy()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .toString(); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basedruginfo/BaseDrugInfo.java b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basedruginfo/BaseDrugInfo.java new file mode 100644 index 00000000..f501bf33 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basedruginfo/BaseDrugInfo.java @@ -0,0 +1,124 @@ +package com.xinelu.manage.domain.basedruginfo; + +import com.xinelu.common.annotation.Excel; +import com.xinelu.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 药品库对象 base_drug_info + * + * @author xinelu + * @date 2024-05-17 + */ +@Data +@AllArgsConstructor +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +@ApiModel(value = "药品库对象", description = "base_drug_info") +public class BaseDrugInfo extends BaseEntity { + private static final long serialVersionUID = 1L; + + /** + * $column.columnComment + */ + private Long id; + + /** + * 药品名称 + */ + @ApiModelProperty(value = "药品名称") + @Excel(name = "药品名称") + private String drugName; + + /** + * 适用症 + */ + @ApiModelProperty(value = "适用症") + @Excel(name = "适用症") + private String purpose; + + /** + * 给药途径 + */ + @ApiModelProperty(value = "给药途径") + @Excel(name = "给药途径") + private String applyWay; + + /** + * 用药频次 + */ + @ApiModelProperty(value = "用药频次") + @Excel(name = "用药频次") + private String applyFrequency; + + /** + * 服药说明 + */ + @ApiModelProperty(value = "服药说明") + @Excel(name = "服药说明") + private String applyRemark; + + /** + * 用法用量(服法剂量) + */ + @ApiModelProperty(value = "用法用量(服法剂量)") + @Excel(name = "用法用量(服法剂量)") + private String dosage; + + /** + * 副作用(不良反应) + */ + @ApiModelProperty(value = "副作用(不良反应)") + @Excel(name = "副作用(不良反应)") + private String sideEffects; + + /** + * 禁忌症 + */ + @ApiModelProperty(value = "禁忌症") + @Excel(name = "禁忌症") + private String contraindications; + + /** + * 存储条件 + */ + @ApiModelProperty(value = "存储条件") + @Excel(name = "存储条件") + private String storage; + + /** + * 漏服或过服的处理方法 + */ + @ApiModelProperty(value = "漏服或过服的处理方法") + @Excel(name = "漏服或过服的处理方法") + private String emergency; + + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("drugName", getDrugName()) + .append("purpose", getPurpose()) + .append("applyWay", getApplyWay()) + .append("applyFrequency", getApplyFrequency()) + .append("applyRemark", getApplyRemark()) + .append("dosage", getDosage()) + .append("sideEffects", getSideEffects()) + .append("contraindications", getContraindications()) + .append("storage", getStorage()) + .append("emergency", getEmergency()) + .append("createTime", getCreateTime()) + .append("createBy", getCreateBy()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .toString(); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basenursinginfo/BaseNursingInfo.java b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basenursinginfo/BaseNursingInfo.java new file mode 100644 index 00000000..f3cf5c96 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basenursinginfo/BaseNursingInfo.java @@ -0,0 +1,84 @@ +package com.xinelu.manage.domain.basenursinginfo; + +import com.xinelu.common.annotation.Excel; +import com.xinelu.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 护理知识库对象 base_nursing_info + * + * @author xinelu + * @date 2024-05-17 + */ +@Data +@AllArgsConstructor +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +@ApiModel(value = "护理知识库对象", description = "base_nursing_info") +public class BaseNursingInfo extends BaseEntity { + private static final long serialVersionUID = 1L; + + /** + * $column.columnComment + */ + private Long id; + + /** + * 护理知识名称 + */ + @ApiModelProperty(value = "护理知识名称") + @Excel(name = "护理知识名称") + private String nursingName; + + /** + * 烟酒指导 + */ + @ApiModelProperty(value = "烟酒指导") + @Excel(name = "烟酒指导") + private String tobaccoWine; + + /** + * 睡眠指导 + */ + @ApiModelProperty(value = "睡眠指导") + @Excel(name = "睡眠指导") + private String sleep; + + /** + * 情绪指导 + */ + @ApiModelProperty(value = "情绪指导") + @Excel(name = "情绪指导") + private String emotion; + + /** + * $column.columnComment + */ + @ApiModelProperty(value = "${comment}") + @Excel(name = "居家安全指导") + private String homeSafeguard; + + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("nursingName", getNursingName()) + .append("tobaccoWine", getTobaccoWine()) + .append("sleep", getSleep()) + .append("emotion", getEmotion()) + .append("homeSafeguard", getHomeSafeguard()) + .append("createTime", getCreateTime()) + .append("createBy", getCreateBy()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .toString(); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basesportinfo/BaseSportInfo.java b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basesportinfo/BaseSportInfo.java new file mode 100644 index 00000000..ad6d26fc --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/basesportinfo/BaseSportInfo.java @@ -0,0 +1,124 @@ +package com.xinelu.manage.domain.basesportinfo; + +import com.xinelu.common.annotation.Excel; +import com.xinelu.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 运动知识库对象 base_sport_info + * + * @author xinelu + * @date 2024-05-16 + */ +@Data +@AllArgsConstructor +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +@ApiModel(value = "运动知识库对象", description = "base_sport_info") +public class BaseSportInfo extends BaseEntity { + private static final long serialVersionUID = 1L; + + /** + * $column.columnComment + */ + private Long id; + + /** + * 运动名称 + */ + @ApiModelProperty(value = "运动名称") + @Excel(name = "运动名称") + private String sportName; + + /** + * 运动类型ID(字典表) + */ + @ApiModelProperty(value = "运动类型ID") + @Excel(name = "运动类型ID", readConverterExp = "字=典表") + private Long sportTypeId; + + /** + * 运动类型名称 + */ + @ApiModelProperty(value = "运动类型名称") + @Excel(name = "运动类型名称") + private String sportTypeName; + + /** + * 运动方式 + */ + @ApiModelProperty(value = "运动方式") + @Excel(name = "运动方式") + private String sportWay; + + /** + * 运动频率 + */ + @ApiModelProperty(value = "运动频率") + @Excel(name = "运动频率") + private String sportFrequency; + + /** + * 每次运动时长 + */ + @ApiModelProperty(value = "每次运动时长") + @Excel(name = "每次运动时长") + private String sportDuration; + + /** + * 运动时间 + */ + @ApiModelProperty(value = "运动时间") + @Excel(name = "运动时间") + private String sportTime; + + /** + * 运动强度 + */ + @ApiModelProperty(value = "运动强度") + @Excel(name = "运动强度") + private String sportIntensity; + + /** + * 运动注意事项 + */ + @ApiModelProperty(value = "运动注意事项") + @Excel(name = "运动注意事项") + private String sportAttention; + + /** + * 动作说明 + */ + @ApiModelProperty(value = "动作说明") + @Excel(name = "动作说明") + private String sportRemark; + + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("sportName", getSportName()) + .append("sportTypeId", getSportTypeId()) + .append("sportTypeName", getSportTypeName()) + .append("sportWay", getSportWay()) + .append("sportFrequency", getSportFrequency()) + .append("sportDuration", getSportDuration()) + .append("sportTime", getSportTime()) + .append("sportIntensity", getSportIntensity()) + .append("sportAttention", getSportAttention()) + .append("sportRemark", getSportRemark()) + .append("createTime", getCreateTime()) + .append("createBy", getCreateBy()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .toString(); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basedietinfo/BaseDietInfoMapper.java b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basedietinfo/BaseDietInfoMapper.java new file mode 100644 index 00000000..c3962837 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basedietinfo/BaseDietInfoMapper.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.mapper.basedietinfo; + +import com.xinelu.manage.domain.basedietinfo.BaseDietInfo; + +import java.util.List; + +/** + * 饮食知识库Mapper接口 + * + * @author xinelu + * @date 2024-05-17 + */ +public interface BaseDietInfoMapper { + /** + * 查询饮食知识库 + * + * @param id 饮食知识库主键 + * @return 饮食知识库 + */ + BaseDietInfo selectBaseDietInfoById(Long id); + + /** + * 查询饮食知识库列表 + * + * @param baseDietInfo 饮食知识库 + * @return 饮食知识库集合 + */ + List selectBaseDietInfoList(BaseDietInfo baseDietInfo); + + /** + * 新增饮食知识库 + * + * @param baseDietInfo 饮食知识库 + * @return 结果 + */ + int insertBaseDietInfo(BaseDietInfo baseDietInfo); + + /** + * 修改饮食知识库 + * + * @param baseDietInfo 饮食知识库 + * @return 结果 + */ + int updateBaseDietInfo(BaseDietInfo baseDietInfo); + + /** + * 删除饮食知识库 + * + * @param id 饮食知识库主键 + * @return 结果 + */ + int deleteBaseDietInfoById(Long id); + + /** + * 批量删除饮食知识库 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteBaseDietInfoByIds(Long[] ids); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basedruginfo/BaseDrugInfoMapper.java b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basedruginfo/BaseDrugInfoMapper.java new file mode 100644 index 00000000..128bdf8b --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basedruginfo/BaseDrugInfoMapper.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.mapper.basedruginfo; + +import com.xinelu.manage.domain.basedruginfo.BaseDrugInfo; + +import java.util.List; + +/** + * 药品库Mapper接口 + * + * @author xinelu + * @date 2024-05-17 + */ +public interface BaseDrugInfoMapper { + /** + * 查询药品库 + * + * @param id 药品库主键 + * @return 药品库 + */ + BaseDrugInfo selectBaseDrugInfoById(Long id); + + /** + * 查询药品库列表 + * + * @param baseDrugInfo 药品库 + * @return 药品库集合 + */ + List selectBaseDrugInfoList(BaseDrugInfo baseDrugInfo); + + /** + * 新增药品库 + * + * @param baseDrugInfo 药品库 + * @return 结果 + */ + int insertBaseDrugInfo(BaseDrugInfo baseDrugInfo); + + /** + * 修改药品库 + * + * @param baseDrugInfo 药品库 + * @return 结果 + */ + int updateBaseDrugInfo(BaseDrugInfo baseDrugInfo); + + /** + * 删除药品库 + * + * @param id 药品库主键 + * @return 结果 + */ + int deleteBaseDrugInfoById(Long id); + + /** + * 批量删除药品库 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteBaseDrugInfoByIds(Long[] ids); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basenursinginfo/BaseNursingInfoMapper.java b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basenursinginfo/BaseNursingInfoMapper.java new file mode 100644 index 00000000..20dab98c --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basenursinginfo/BaseNursingInfoMapper.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.mapper.basenursinginfo; + +import com.xinelu.manage.domain.basenursinginfo.BaseNursingInfo; + +import java.util.List; + +/** + * 护理知识库Mapper接口 + * + * @author xinelu + * @date 2024-05-17 + */ +public interface BaseNursingInfoMapper { + /** + * 查询护理知识库 + * + * @param id 护理知识库主键 + * @return 护理知识库 + */ + BaseNursingInfo selectBaseNursingInfoById(Long id); + + /** + * 查询护理知识库列表 + * + * @param baseNursingInfo 护理知识库 + * @return 护理知识库集合 + */ + List selectBaseNursingInfoList(BaseNursingInfo baseNursingInfo); + + /** + * 新增护理知识库 + * + * @param baseNursingInfo 护理知识库 + * @return 结果 + */ + int insertBaseNursingInfo(BaseNursingInfo baseNursingInfo); + + /** + * 修改护理知识库 + * + * @param baseNursingInfo 护理知识库 + * @return 结果 + */ + int updateBaseNursingInfo(BaseNursingInfo baseNursingInfo); + + /** + * 删除护理知识库 + * + * @param id 护理知识库主键 + * @return 结果 + */ + int deleteBaseNursingInfoById(Long id); + + /** + * 批量删除护理知识库 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteBaseNursingInfoByIds(Long[] ids); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basesportinfo/BaseSportInfoMapper.java b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basesportinfo/BaseSportInfoMapper.java new file mode 100644 index 00000000..80d1dc77 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/mapper/basesportinfo/BaseSportInfoMapper.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.mapper.basesportinfo; + +import com.xinelu.manage.domain.basesportinfo.BaseSportInfo; + +import java.util.List; + +/** + * 运动知识库Mapper接口 + * + * @author xinelu + * @date 2024-05-16 + */ +public interface BaseSportInfoMapper { + /** + * 查询运动知识库 + * + * @param id 运动知识库主键 + * @return 运动知识库 + */ + BaseSportInfo selectBaseSportInfoById(Long id); + + /** + * 查询运动知识库列表 + * + * @param baseSportInfo 运动知识库 + * @return 运动知识库集合 + */ + List selectBaseSportInfoList(BaseSportInfo baseSportInfo); + + /** + * 新增运动知识库 + * + * @param baseSportInfo 运动知识库 + * @return 结果 + */ + int insertBaseSportInfo(BaseSportInfo baseSportInfo); + + /** + * 修改运动知识库 + * + * @param baseSportInfo 运动知识库 + * @return 结果 + */ + int updateBaseSportInfo(BaseSportInfo baseSportInfo); + + /** + * 删除运动知识库 + * + * @param id 运动知识库主键 + * @return 结果 + */ + int deleteBaseSportInfoById(Long id); + + /** + * 批量删除运动知识库 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteBaseSportInfoByIds(Long[] ids); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedietinfo/IBaseDietInfoService.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedietinfo/IBaseDietInfoService.java new file mode 100644 index 00000000..8b2396f3 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedietinfo/IBaseDietInfoService.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.service.basedietinfo; + +import com.xinelu.manage.domain.basedietinfo.BaseDietInfo; + +import java.util.List; + +/** + * 饮食知识库Service接口 + * + * @author xinelu + * @date 2024-05-17 + */ +public interface IBaseDietInfoService { + /** + * 查询饮食知识库 + * + * @param id 饮食知识库主键 + * @return 饮食知识库 + */ + BaseDietInfo selectBaseDietInfoById(Long id); + + /** + * 查询饮食知识库列表 + * + * @param baseDietInfo 饮食知识库 + * @return 饮食知识库集合 + */ + List selectBaseDietInfoList(BaseDietInfo baseDietInfo); + + /** + * 新增饮食知识库 + * + * @param baseDietInfo 饮食知识库 + * @return 结果 + */ + int insertBaseDietInfo(BaseDietInfo baseDietInfo); + + /** + * 修改饮食知识库 + * + * @param baseDietInfo 饮食知识库 + * @return 结果 + */ + int updateBaseDietInfo(BaseDietInfo baseDietInfo); + + /** + * 批量删除饮食知识库 + * + * @param ids 需要删除的饮食知识库主键集合 + * @return 结果 + */ + int deleteBaseDietInfoByIds(Long[] ids); + + /** + * 删除饮食知识库信息 + * + * @param id 饮食知识库主键 + * @return 结果 + */ + int deleteBaseDietInfoById(Long id); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedietinfo/impl/BaseDietInfoServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedietinfo/impl/BaseDietInfoServiceImpl.java new file mode 100644 index 00000000..8e9c0c85 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedietinfo/impl/BaseDietInfoServiceImpl.java @@ -0,0 +1,90 @@ +package com.xinelu.manage.service.basedietinfo.impl; + +import com.xinelu.manage.domain.basedietinfo.BaseDietInfo; +import com.xinelu.manage.mapper.basedietinfo.BaseDietInfoMapper; +import com.xinelu.manage.service.basedietinfo.IBaseDietInfoService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.time.LocalDateTime; +import java.util.List; + +/** + * 饮食知识库Service业务层处理 + * + * @author xinelu + * @date 2024-05-17 + */ +@Service +public class BaseDietInfoServiceImpl implements IBaseDietInfoService { + @Resource + private BaseDietInfoMapper baseDietInfoMapper; + + /** + * 查询饮食知识库 + * + * @param id 饮食知识库主键 + * @return 饮食知识库 + */ + @Override + public BaseDietInfo selectBaseDietInfoById(Long id) { + return baseDietInfoMapper.selectBaseDietInfoById(id); + } + + /** + * 查询饮食知识库列表 + * + * @param baseDietInfo 饮食知识库 + * @return 饮食知识库 + */ + @Override + public List selectBaseDietInfoList(BaseDietInfo baseDietInfo) { + return baseDietInfoMapper.selectBaseDietInfoList(baseDietInfo); + } + + /** + * 新增饮食知识库 + * + * @param baseDietInfo 饮食知识库 + * @return 结果 + */ + @Override + public int insertBaseDietInfo(BaseDietInfo baseDietInfo) { + baseDietInfo.setCreateTime(LocalDateTime.now()); + return baseDietInfoMapper.insertBaseDietInfo(baseDietInfo); + } + + /** + * 修改饮食知识库 + * + * @param baseDietInfo 饮食知识库 + * @return 结果 + */ + @Override + public int updateBaseDietInfo(BaseDietInfo baseDietInfo) { + baseDietInfo.setUpdateTime(LocalDateTime.now()); + return baseDietInfoMapper.updateBaseDietInfo(baseDietInfo); + } + + /** + * 批量删除饮食知识库 + * + * @param ids 需要删除的饮食知识库主键 + * @return 结果 + */ + @Override + public int deleteBaseDietInfoByIds(Long[] ids) { + return baseDietInfoMapper.deleteBaseDietInfoByIds(ids); + } + + /** + * 删除饮食知识库信息 + * + * @param id 饮食知识库主键 + * @return 结果 + */ + @Override + public int deleteBaseDietInfoById(Long id) { + return baseDietInfoMapper.deleteBaseDietInfoById(id); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedruginfo/IBaseDrugInfoService.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedruginfo/IBaseDrugInfoService.java new file mode 100644 index 00000000..8d8673a6 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedruginfo/IBaseDrugInfoService.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.service.basedruginfo; + +import com.xinelu.manage.domain.basedruginfo.BaseDrugInfo; + +import java.util.List; + +/** + * 药品库Service接口 + * + * @author xinelu + * @date 2024-05-17 + */ +public interface IBaseDrugInfoService { + /** + * 查询药品库 + * + * @param id 药品库主键 + * @return 药品库 + */ + BaseDrugInfo selectBaseDrugInfoById(Long id); + + /** + * 查询药品库列表 + * + * @param baseDrugInfo 药品库 + * @return 药品库集合 + */ + List selectBaseDrugInfoList(BaseDrugInfo baseDrugInfo); + + /** + * 新增药品库 + * + * @param baseDrugInfo 药品库 + * @return 结果 + */ + int insertBaseDrugInfo(BaseDrugInfo baseDrugInfo); + + /** + * 修改药品库 + * + * @param baseDrugInfo 药品库 + * @return 结果 + */ + int updateBaseDrugInfo(BaseDrugInfo baseDrugInfo); + + /** + * 批量删除药品库 + * + * @param ids 需要删除的药品库主键集合 + * @return 结果 + */ + int deleteBaseDrugInfoByIds(Long[] ids); + + /** + * 删除药品库信息 + * + * @param id 药品库主键 + * @return 结果 + */ + int deleteBaseDrugInfoById(Long id); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedruginfo/impl/BaseDrugInfoServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedruginfo/impl/BaseDrugInfoServiceImpl.java new file mode 100644 index 00000000..a47535db --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basedruginfo/impl/BaseDrugInfoServiceImpl.java @@ -0,0 +1,90 @@ +package com.xinelu.manage.service.basedruginfo.impl; + +import com.xinelu.manage.domain.basedruginfo.BaseDrugInfo; +import com.xinelu.manage.mapper.basedruginfo.BaseDrugInfoMapper; +import com.xinelu.manage.service.basedruginfo.IBaseDrugInfoService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.time.LocalDateTime; +import java.util.List; + +/** + * 药品库Service业务层处理 + * + * @author xinelu + * @date 2024-05-17 + */ +@Service +public class BaseDrugInfoServiceImpl implements IBaseDrugInfoService { + @Resource + private BaseDrugInfoMapper baseDrugInfoMapper; + + /** + * 查询药品库 + * + * @param id 药品库主键 + * @return 药品库 + */ + @Override + public BaseDrugInfo selectBaseDrugInfoById(Long id) { + return baseDrugInfoMapper.selectBaseDrugInfoById(id); + } + + /** + * 查询药品库列表 + * + * @param baseDrugInfo 药品库 + * @return 药品库 + */ + @Override + public List selectBaseDrugInfoList(BaseDrugInfo baseDrugInfo) { + return baseDrugInfoMapper.selectBaseDrugInfoList(baseDrugInfo); + } + + /** + * 新增药品库 + * + * @param baseDrugInfo 药品库 + * @return 结果 + */ + @Override + public int insertBaseDrugInfo(BaseDrugInfo baseDrugInfo) { + baseDrugInfo.setCreateTime(LocalDateTime.now()); + return baseDrugInfoMapper.insertBaseDrugInfo(baseDrugInfo); + } + + /** + * 修改药品库 + * + * @param baseDrugInfo 药品库 + * @return 结果 + */ + @Override + public int updateBaseDrugInfo(BaseDrugInfo baseDrugInfo) { + baseDrugInfo.setUpdateTime(LocalDateTime.now()); + return baseDrugInfoMapper.updateBaseDrugInfo(baseDrugInfo); + } + + /** + * 批量删除药品库 + * + * @param ids 需要删除的药品库主键 + * @return 结果 + */ + @Override + public int deleteBaseDrugInfoByIds(Long[] ids) { + return baseDrugInfoMapper.deleteBaseDrugInfoByIds(ids); + } + + /** + * 删除药品库信息 + * + * @param id 药品库主键 + * @return 结果 + */ + @Override + public int deleteBaseDrugInfoById(Long id) { + return baseDrugInfoMapper.deleteBaseDrugInfoById(id); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basenursinginfo/IBaseNursingInfoService.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basenursinginfo/IBaseNursingInfoService.java new file mode 100644 index 00000000..857c1db7 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basenursinginfo/IBaseNursingInfoService.java @@ -0,0 +1,61 @@ +package com.xinelu.manage.service.basenursinginfo; + +import com.xinelu.manage.domain.basenursinginfo.BaseNursingInfo; + +import java.util.List; + +/** + * 护理知识库Service接口 + * + * @author xinelu + * @date 2024-05-17 + */ +public interface IBaseNursingInfoService { + /** + * 查询护理知识库 + * + * @param id 护理知识库主键 + * @return 护理知识库 + */ + BaseNursingInfo selectBaseNursingInfoById(Long id); + + /** + * 查询护理知识库列表 + * + * @param baseNursingInfo 护理知识库 + * @return 护理知识库集合 + */ + List selectBaseNursingInfoList(BaseNursingInfo baseNursingInfo); + + /** + * 新增护理知识库 + * + * @param baseNursingInfo 护理知识库 + * @return 结果 + */ + int insertBaseNursingInfo(BaseNursingInfo baseNursingInfo); + + /** + * 修改护理知识库 + * + * @param baseNursingInfo 护理知识库 + * @return 结果 + */ + int updateBaseNursingInfo(BaseNursingInfo baseNursingInfo); + + /** + * 批量删除护理知识库 + * + * @param ids 需要删除的护理知识库主键集合 + * @return 结果 + */ + int deleteBaseNursingInfoByIds(Long[] ids); + + /** + * 删除护理知识库信息 + * + * @param id 护理知识库主键 + * @return 结果 + */ + int deleteBaseNursingInfoById(Long id); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basenursinginfo/impl/BaseNursingInfoServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basenursinginfo/impl/BaseNursingInfoServiceImpl.java new file mode 100644 index 00000000..d746c782 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basenursinginfo/impl/BaseNursingInfoServiceImpl.java @@ -0,0 +1,90 @@ +package com.xinelu.manage.service.basenursinginfo.impl; + +import com.xinelu.manage.domain.basenursinginfo.BaseNursingInfo; +import com.xinelu.manage.mapper.basenursinginfo.BaseNursingInfoMapper; +import com.xinelu.manage.service.basenursinginfo.IBaseNursingInfoService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.time.LocalDateTime; +import java.util.List; + +/** + * 护理知识库Service业务层处理 + * + * @author xinelu + * @date 2024-05-17 + */ +@Service +public class BaseNursingInfoServiceImpl implements IBaseNursingInfoService { + @Resource + private BaseNursingInfoMapper baseNursingInfoMapper; + + /** + * 查询护理知识库 + * + * @param id 护理知识库主键 + * @return 护理知识库 + */ + @Override + public BaseNursingInfo selectBaseNursingInfoById(Long id) { + return baseNursingInfoMapper.selectBaseNursingInfoById(id); + } + + /** + * 查询护理知识库列表 + * + * @param baseNursingInfo 护理知识库 + * @return 护理知识库 + */ + @Override + public List selectBaseNursingInfoList(BaseNursingInfo baseNursingInfo) { + return baseNursingInfoMapper.selectBaseNursingInfoList(baseNursingInfo); + } + + /** + * 新增护理知识库 + * + * @param baseNursingInfo 护理知识库 + * @return 结果 + */ + @Override + public int insertBaseNursingInfo(BaseNursingInfo baseNursingInfo) { + baseNursingInfo.setCreateTime(LocalDateTime.now()); + return baseNursingInfoMapper.insertBaseNursingInfo(baseNursingInfo); + } + + /** + * 修改护理知识库 + * + * @param baseNursingInfo 护理知识库 + * @return 结果 + */ + @Override + public int updateBaseNursingInfo(BaseNursingInfo baseNursingInfo) { + baseNursingInfo.setUpdateTime(LocalDateTime.now()); + return baseNursingInfoMapper.updateBaseNursingInfo(baseNursingInfo); + } + + /** + * 批量删除护理知识库 + * + * @param ids 需要删除的护理知识库主键 + * @return 结果 + */ + @Override + public int deleteBaseNursingInfoByIds(Long[] ids) { + return baseNursingInfoMapper.deleteBaseNursingInfoByIds(ids); + } + + /** + * 删除护理知识库信息 + * + * @param id 护理知识库主键 + * @return 结果 + */ + @Override + public int deleteBaseNursingInfoById(Long id) { + return baseNursingInfoMapper.deleteBaseNursingInfoById(id); + } +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basesportinfo/IBaseSportInfoService.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basesportinfo/IBaseSportInfoService.java new file mode 100644 index 00000000..e0aca462 --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basesportinfo/IBaseSportInfoService.java @@ -0,0 +1,62 @@ +package com.xinelu.manage.service.basesportinfo; + +import com.xinelu.manage.domain.basesportinfo.BaseSportInfo; + +import java.util.List; + + +/** + * 运动知识库Service接口 + * + * @author xinelu + * @date 2024-05-16 + */ +public interface IBaseSportInfoService { + /** + * 查询运动知识库 + * + * @param id 运动知识库主键 + * @return 运动知识库 + */ + BaseSportInfo selectBaseSportInfoById(Long id); + + /** + * 查询运动知识库列表 + * + * @param baseSportInfo 运动知识库 + * @return 运动知识库集合 + */ + List selectBaseSportInfoList(BaseSportInfo baseSportInfo); + + /** + * 新增运动知识库 + * + * @param baseSportInfo 运动知识库 + * @return 结果 + */ + int insertBaseSportInfo(BaseSportInfo baseSportInfo); + + /** + * 修改运动知识库 + * + * @param baseSportInfo 运动知识库 + * @return 结果 + */ + int updateBaseSportInfo(BaseSportInfo baseSportInfo); + + /** + * 批量删除运动知识库 + * + * @param ids 需要删除的运动知识库主键集合 + * @return 结果 + */ + int deleteBaseSportInfoByIds(Long[] ids); + + /** + * 删除运动知识库信息 + * + * @param id 运动知识库主键 + * @return 结果 + */ + int deleteBaseSportInfoById(Long id); +} diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/basesportinfo/impl/BaseSportInfoServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basesportinfo/impl/BaseSportInfoServiceImpl.java new file mode 100644 index 00000000..cf95de3e --- /dev/null +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/basesportinfo/impl/BaseSportInfoServiceImpl.java @@ -0,0 +1,90 @@ +package com.xinelu.manage.service.basesportinfo.impl; + +import com.xinelu.manage.domain.basesportinfo.BaseSportInfo; +import com.xinelu.manage.mapper.basesportinfo.BaseSportInfoMapper; +import com.xinelu.manage.service.basesportinfo.IBaseSportInfoService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.time.LocalDateTime; +import java.util.List; + +/** + * 运动知识库Service业务层处理 + * + * @author xinelu + * @date 2024-05-16 + */ +@Service +public class BaseSportInfoServiceImpl implements IBaseSportInfoService { + @Resource + private BaseSportInfoMapper baseSportInfoMapper; + + /** + * 查询运动知识库 + * + * @param id 运动知识库主键 + * @return 运动知识库 + */ + @Override + public BaseSportInfo selectBaseSportInfoById(Long id) { + return baseSportInfoMapper.selectBaseSportInfoById(id); + } + + /** + * 查询运动知识库列表 + * + * @param baseSportInfo 运动知识库 + * @return 运动知识库 + */ + @Override + public List selectBaseSportInfoList(BaseSportInfo baseSportInfo) { + return baseSportInfoMapper.selectBaseSportInfoList(baseSportInfo); + } + + /** + * 新增运动知识库 + * + * @param baseSportInfo 运动知识库 + * @return 结果 + */ + @Override + public int insertBaseSportInfo(BaseSportInfo baseSportInfo) { + baseSportInfo.setCreateTime(LocalDateTime.now()); + return baseSportInfoMapper.insertBaseSportInfo(baseSportInfo); + } + + /** + * 修改运动知识库 + * + * @param baseSportInfo 运动知识库 + * @return 结果 + */ + @Override + public int updateBaseSportInfo(BaseSportInfo baseSportInfo) { + baseSportInfo.setUpdateTime(LocalDateTime.now()); + return baseSportInfoMapper.updateBaseSportInfo(baseSportInfo); + } + + /** + * 批量删除运动知识库 + * + * @param ids 需要删除的运动知识库主键 + * @return 结果 + */ + @Override + public int deleteBaseSportInfoByIds(Long[] ids) { + return baseSportInfoMapper.deleteBaseSportInfoByIds(ids); + } + + /** + * 删除运动知识库信息 + * + * @param id 运动知识库主键 + * @return 结果 + */ + @Override + public int deleteBaseSportInfoById(Long id) { + return baseSportInfoMapper.deleteBaseSportInfoById(id); + } +} diff --git a/postdischarge-manage/src/main/resources/mapper/manage/basedietinfo/BaseDietInfoMapper.xml b/postdischarge-manage/src/main/resources/mapper/manage/basedietinfo/BaseDietInfoMapper.xml new file mode 100644 index 00000000..2a14e8b8 --- /dev/null +++ b/postdischarge-manage/src/main/resources/mapper/manage/basedietinfo/BaseDietInfoMapper.xml @@ -0,0 +1,162 @@ + + + + + + + + + + + + + + + + + + + + + select id, diet_name, diet_principle, main_food, vegetable, fruit, meat, diet_remark, create_time, create_by, update_by, update_time from base_diet_info + + + + + + + + insert into base_diet_info + + diet_name, + + diet_principle, + + main_food, + + vegetable, + + fruit, + + meat, + + diet_remark, + + create_time, + + create_by, + + update_by, + + update_time, + + + + #{dietName}, + + #{dietPrinciple}, + + #{mainFood}, + + #{vegetable}, + + #{fruit}, + + #{meat}, + + #{dietRemark}, + + #{createTime}, + + #{createBy}, + + #{updateBy}, + + #{updateTime}, + + + + + + update base_diet_info + + diet_name = + #{dietName}, + + diet_principle = + #{dietPrinciple}, + + main_food = + #{mainFood}, + + vegetable = + #{vegetable}, + + fruit = + #{fruit}, + + meat = + #{meat}, + + diet_remark = + #{dietRemark}, + + create_time = + #{createTime}, + + create_by = + #{createBy}, + + update_by = + #{updateBy}, + + update_time = + #{updateTime}, + + + where id = #{id} + + + + delete from base_diet_info where id = #{id} + + + + delete from base_diet_info where id in + + #{id} + + + \ No newline at end of file diff --git a/postdischarge-manage/src/main/resources/mapper/manage/basedruginfo/BaseDrugInfoMapper.xml b/postdischarge-manage/src/main/resources/mapper/manage/basedruginfo/BaseDrugInfoMapper.xml new file mode 100644 index 00000000..28aeb803 --- /dev/null +++ b/postdischarge-manage/src/main/resources/mapper/manage/basedruginfo/BaseDrugInfoMapper.xml @@ -0,0 +1,195 @@ + + + + + + + + + + + + + + + + + + + + + + + + select id, drug_name, purpose, apply_way, apply_frequency, apply_remark, dosage, side_effects, contraindications, storage, emergency, create_time, create_by, update_by, update_time from base_drug_info + + + + + + + + insert into base_drug_info + + drug_name, + + purpose, + + apply_way, + + apply_frequency, + + apply_remark, + + dosage, + + side_effects, + + contraindications, + + storage, + + emergency, + + create_time, + + create_by, + + update_by, + + update_time, + + + + #{drugName}, + + #{purpose}, + + #{applyWay}, + + #{applyFrequency}, + + #{applyRemark}, + + #{dosage}, + + #{sideEffects}, + + #{contraindications}, + + #{storage}, + + #{emergency}, + + #{createTime}, + + #{createBy}, + + #{updateBy}, + + #{updateTime}, + + + + + + update base_drug_info + + drug_name = + #{drugName}, + + purpose = + #{purpose}, + + apply_way = + #{applyWay}, + + apply_frequency = + #{applyFrequency}, + + apply_remark = + #{applyRemark}, + + dosage = + #{dosage}, + + side_effects = + #{sideEffects}, + + contraindications = + #{contraindications}, + + storage = + #{storage}, + + emergency = + #{emergency}, + + create_time = + #{createTime}, + + create_by = + #{createBy}, + + update_by = + #{updateBy}, + + update_time = + #{updateTime}, + + + where id = #{id} + + + + delete from base_drug_info where id = #{id} + + + + delete from base_drug_info where id in + + #{id} + + + \ No newline at end of file diff --git a/postdischarge-manage/src/main/resources/mapper/manage/basenursinginfo/BaseNursingInfoMapper.xml b/postdischarge-manage/src/main/resources/mapper/manage/basenursinginfo/BaseNursingInfoMapper.xml new file mode 100644 index 00000000..b1c01f12 --- /dev/null +++ b/postdischarge-manage/src/main/resources/mapper/manage/basenursinginfo/BaseNursingInfoMapper.xml @@ -0,0 +1,140 @@ + + + + + + + + + + + + + + + + + + + select id, nursing_name, tobacco_wine, sleep, emotion, home_safeguard, create_time, create_by, update_by, update_time from base_nursing_info + + + + + + + + insert into base_nursing_info + + nursing_name, + + tobacco_wine, + + sleep, + + emotion, + + home_safeguard, + + create_time, + + create_by, + + update_by, + + update_time, + + + + #{nursingName}, + + #{tobaccoWine}, + + #{sleep}, + + #{emotion}, + + #{homeSafeguard}, + + #{createTime}, + + #{createBy}, + + #{updateBy}, + + #{updateTime}, + + + + + + update base_nursing_info + + nursing_name = + #{nursingName}, + + tobacco_wine = + #{tobaccoWine}, + + sleep = + #{sleep}, + + emotion = + #{emotion}, + + home_safeguard = + #{homeSafeguard}, + + create_time = + #{createTime}, + + create_by = + #{createBy}, + + update_by = + #{updateBy}, + + update_time = + #{updateTime}, + + + where id = #{id} + + + + delete from base_nursing_info where id = #{id} + + + + delete from base_nursing_info where id in + + #{id} + + + \ No newline at end of file diff --git a/postdischarge-manage/src/main/resources/mapper/manage/basesportinfo/BaseSportInfoMapper.xml b/postdischarge-manage/src/main/resources/mapper/manage/basesportinfo/BaseSportInfoMapper.xml new file mode 100644 index 00000000..bf7c04ea --- /dev/null +++ b/postdischarge-manage/src/main/resources/mapper/manage/basesportinfo/BaseSportInfoMapper.xml @@ -0,0 +1,195 @@ + + + + + + + + + + + + + + + + + + + + + + + + select id, sport_name, sport_type_id, sport_type_name, sport_way, sport_frequency, sport_duration, sport_time, sport_intensity, sport_attention, sport_remark, create_time, create_by, update_by, update_time from base_sport_info + + + + + + + + insert into base_sport_info + + sport_name, + + sport_type_id, + + sport_type_name, + + sport_way, + + sport_frequency, + + sport_duration, + + sport_time, + + sport_intensity, + + sport_attention, + + sport_remark, + + create_time, + + create_by, + + update_by, + + update_time, + + + + #{sportName}, + + #{sportTypeId}, + + #{sportTypeName}, + + #{sportWay}, + + #{sportFrequency}, + + #{sportDuration}, + + #{sportTime}, + + #{sportIntensity}, + + #{sportAttention}, + + #{sportRemark}, + + #{createTime}, + + #{createBy}, + + #{updateBy}, + + #{updateTime}, + + + + + + update base_sport_info + + sport_name = + #{sportName}, + + sport_type_id = + #{sportTypeId}, + + sport_type_name = + #{sportTypeName}, + + sport_way = + #{sportWay}, + + sport_frequency = + #{sportFrequency}, + + sport_duration = + #{sportDuration}, + + sport_time = + #{sportTime}, + + sport_intensity = + #{sportIntensity}, + + sport_attention = + #{sportAttention}, + + sport_remark = + #{sportRemark}, + + create_time = + #{createTime}, + + create_by = + #{createBy}, + + update_by = + #{updateBy}, + + update_time = + #{updateTime}, + + + where id = #{id} + + + + delete from base_sport_info where id = #{id} + + + + delete from base_sport_info where id in + + #{id} + + + \ No newline at end of file