Commit fd1eec4cad130500010fa56737b1f1d8b36f0ce8
1 parent
1ee475ae9f
Exists in
master
11
Showing 4 changed files with 154 additions and 0 deletions
- parent/base.common/src/main/java/com/lyms/base/common/dao/organ/SysOrganizationsConfMapper.xml
- parent/base.common/src/main/java/com/lyms/base/common/entity/organ/SysOrganizationsConf.java
- parent/base.common/src/main/java/com/lyms/base/common/service/organ/SysOrganizationsConfService.java
- parent/base.common/src/main/java/com/lyms/base/common/service/organ/impl/SysOrganizationsConfServiceImpl.java
parent/base.common/src/main/java/com/lyms/base/common/dao/organ/SysOrganizationsConfMapper.xml
View file @
fd1eec4
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | |
| 2 | +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | |
| 3 | +<mapper namespace="com.lyms.base.common.dao.organ.SysOrganizationsConfMapper"> | |
| 4 | + | |
| 5 | + <!-- 通用查询映射结果 --> | |
| 6 | + <resultMap id="BaseResultMap" type="com.lyms.base.common.entity.organ.SysOrganizationsConf"> | |
| 7 | + <id column="ID" property="id" /> | |
| 8 | + <result column="ORG_ID" property="orgId" /> | |
| 9 | + <result column="HIGHRISK_VERSION" property="highriskVersion" /> | |
| 10 | + <result column="DIAGNOSE_VERSION" property="diagnoseVersion" /> | |
| 11 | + </resultMap> | |
| 12 | + | |
| 13 | + <!-- 通用查询结果列 --> | |
| 14 | + <sql id="Base_Column_List"> | |
| 15 | + ID AS id, ORG_ID AS orgId, HIGHRISK_VERSION AS highriskVersion, DIAGNOSE_VERSION AS diagnoseVersion | |
| 16 | + </sql> | |
| 17 | + | |
| 18 | + <!-- 根据typecode获取字典列表--> | |
| 19 | + <select id="get" resultType="SysDict"> | |
| 20 | + SELECT id,COLORTEXT FROM HIGHRISK_CONF c WHERE id IN( | |
| 21 | + SELECT MAX(id) FROM HIGHRISK_CONF where c.VERSION_ID = #{versionId} | |
| 22 | + and c.ENABLE = 1 GROUP BY COLORTEXT) | |
| 23 | + </select> | |
| 24 | + | |
| 25 | +</mapper> |
parent/base.common/src/main/java/com/lyms/base/common/entity/organ/SysOrganizationsConf.java
View file @
fd1eec4
| 1 | +package com.lyms.base.common.entity.organ; | |
| 2 | + | |
| 3 | +import com.baomidou.mybatisplus.annotations.TableId; | |
| 4 | +import com.baomidou.mybatisplus.annotations.TableField; | |
| 5 | +import com.baomidou.mybatisplus.annotations.TableName; | |
| 6 | +import java.io.Serializable; | |
| 7 | + | |
| 8 | +/** | |
| 9 | + * <p> | |
| 10 | + * 医院机构配置表,包含高危版本、诊断版本等相关信息 | |
| 11 | + * </p> | |
| 12 | + * | |
| 13 | + * @author fangcheng | |
| 14 | + * @since 2017-03-31 | |
| 15 | + */ | |
| 16 | +@TableName("SYS_ORGANIZATIONS_CONF") | |
| 17 | +public class SysOrganizationsConf implements Serializable { | |
| 18 | + | |
| 19 | + private static final long serialVersionUID = 1L; | |
| 20 | + | |
| 21 | + /** | |
| 22 | + * | |
| 23 | + */ | |
| 24 | + @TableId(value="ID") | |
| 25 | + private String id; | |
| 26 | + /** | |
| 27 | + * 机构ID | |
| 28 | + */ | |
| 29 | + @TableField(value="ORG_ID") | |
| 30 | + private String orgId; | |
| 31 | + /** | |
| 32 | + * 高危版本 | |
| 33 | + */ | |
| 34 | + @TableField(value="HIGHRISK_VERSION") | |
| 35 | + private Integer highriskVersion; | |
| 36 | + /** | |
| 37 | + * 诊断版本 | |
| 38 | + */ | |
| 39 | + @TableField(value="DIAGNOSE_VERSION") | |
| 40 | + private Integer diagnoseVersion; | |
| 41 | + | |
| 42 | + | |
| 43 | + public String getId() { | |
| 44 | + return id; | |
| 45 | + } | |
| 46 | + | |
| 47 | + public void setId(String id) { | |
| 48 | + this.id = id; | |
| 49 | + } | |
| 50 | + | |
| 51 | + public String getOrgId() { | |
| 52 | + return orgId; | |
| 53 | + } | |
| 54 | + | |
| 55 | + public void setOrgId(String orgId) { | |
| 56 | + this.orgId = orgId; | |
| 57 | + } | |
| 58 | + | |
| 59 | + public Integer getHighriskVersion() { | |
| 60 | + return highriskVersion; | |
| 61 | + } | |
| 62 | + | |
| 63 | + public void setHighriskVersion(Integer highriskVersion) { | |
| 64 | + this.highriskVersion = highriskVersion; | |
| 65 | + } | |
| 66 | + | |
| 67 | + public Integer getDiagnoseVersion() { | |
| 68 | + return diagnoseVersion; | |
| 69 | + } | |
| 70 | + | |
| 71 | + public void setDiagnoseVersion(Integer diagnoseVersion) { | |
| 72 | + this.diagnoseVersion = diagnoseVersion; | |
| 73 | + } | |
| 74 | + | |
| 75 | +} |
parent/base.common/src/main/java/com/lyms/base/common/service/organ/SysOrganizationsConfService.java
View file @
fd1eec4
| 1 | +package com.lyms.base.common.service.organ; | |
| 2 | + | |
| 3 | +import java.io.Serializable; | |
| 4 | +import java.util.List; | |
| 5 | +import java.util.Map; | |
| 6 | + | |
| 7 | +import com.lyms.base.common.entity.organ.SysOrganizationsConf; | |
| 8 | +import com.lyms.web.service.BaseService; | |
| 9 | + | |
| 10 | +/** | |
| 11 | + * <p> | |
| 12 | + * 服务类 | |
| 13 | + * </p> | |
| 14 | + * | |
| 15 | + * @author fangcheng | |
| 16 | + * @since 2017-03-31 | |
| 17 | + */ | |
| 18 | +public interface SysOrganizationsConfService extends BaseService<SysOrganizationsConf> { | |
| 19 | + | |
| 20 | + /** | |
| 21 | + * <li>@Description:逻辑删除,ifDel = 1 为删除,否则为没有删除 | |
| 22 | + * <li>@param id 删除主键id | |
| 23 | + * <li>@return 大于0修改成功,否则为失败 | |
| 24 | + */ | |
| 25 | + public Integer deleteLogicById(Serializable id); | |
| 26 | + | |
| 27 | +} |
parent/base.common/src/main/java/com/lyms/base/common/service/organ/impl/SysOrganizationsConfServiceImpl.java
View file @
fd1eec4
| 1 | +package com.lyms.base.common.service.organ.impl; | |
| 2 | + | |
| 3 | +import com.lyms.base.common.entity.organ.SysOrganizationsConf; | |
| 4 | +import com.lyms.base.common.dao.organ.SysOrganizationsConfMapper; | |
| 5 | +import com.lyms.base.common.service.organ.SysOrganizationsConfService; | |
| 6 | +import com.baomidou.mybatisplus.service.impl.ServiceImpl; | |
| 7 | +import org.springframework.stereotype.Service; | |
| 8 | +import java.io.Serializable; | |
| 9 | +import java.util.List; | |
| 10 | +import java.util.Map; | |
| 11 | + | |
| 12 | +/** | |
| 13 | + * <p> | |
| 14 | + * 医院机构配置表,包含高危版本、诊断版本等相关信息 服务实现类 | |
| 15 | + * </p> | |
| 16 | + * | |
| 17 | + * @author fangcheng | |
| 18 | + * @since 2017-03-31 | |
| 19 | + */ | |
| 20 | +@Service | |
| 21 | +public class SysOrganizationsConfServiceImpl extends ServiceImpl<SysOrganizationsConfMapper, SysOrganizationsConf> implements SysOrganizationsConfService { | |
| 22 | + | |
| 23 | + public Integer deleteLogicById(Serializable id){ | |
| 24 | + return baseMapper.deleteLogicById(id); | |
| 25 | + } | |
| 26 | + | |
| 27 | +} |