患者处方相关修改
parent
1df50657b0
commit
5f110bea39
@ -0,0 +1,37 @@
|
||||
package com.glxp.api.controller.basic;
|
||||
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.glxp.api.common.res.BaseResponse;
|
||||
import com.glxp.api.common.util.ResultVOUtils;
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeDiEntity;
|
||||
import com.glxp.api.req.basic.BasicSkPrescribeDiRequest;
|
||||
import com.glxp.api.res.PageSimpleResponse;
|
||||
import com.glxp.api.service.BasicSkPrescribeDiService;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
public class BasicSickPrescribeDiController {
|
||||
|
||||
@Resource
|
||||
BasicSkPrescribeDiService basicSkPrescribeDiService;
|
||||
|
||||
/**
|
||||
* 获取处方使用耗材详情
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/udiwms/basic/sk/prescribe/di/filter")
|
||||
public BaseResponse filterSicker(BasicSkPrescribeDiRequest basicSkPrescribeDiRequest) {
|
||||
List<BasicSkPrescribeDiEntity> basicSkPrescribeResponses = basicSkPrescribeDiService.filterList(basicSkPrescribeDiRequest);
|
||||
PageInfo<BasicSkPrescribeDiEntity> pageInfo = new PageInfo<>(basicSkPrescribeResponses);
|
||||
PageSimpleResponse<BasicSkPrescribeDiEntity> pageSimpleResponse = new PageSimpleResponse<>();
|
||||
pageSimpleResponse.setTotal(pageInfo.getTotal());
|
||||
pageSimpleResponse.setList(basicSkPrescribeResponses);
|
||||
return ResultVOUtils.success(pageSimpleResponse);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package com.glxp.api.dao.basic;
|
||||
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeDiEntity;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.glxp.api.req.basic.BasicSkPrescribeDiRequest;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 针对表【basic_sk_prescribe_item_detail(处方关联的耗材信息表)】的数据库操作Mapper
|
||||
*/
|
||||
public interface BasicSkPrescribeDiMapper extends BaseMapper<BasicSkPrescribeDiEntity> {
|
||||
|
||||
List<BasicSkPrescribeDiEntity> filterList(BasicSkPrescribeDiRequest basicSkPrescribeDiRequest);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -1,15 +0,0 @@
|
||||
package com.glxp.api.dao.basic;
|
||||
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeItemDetailEntity;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* 针对表【basic_sk_prescribe_item_detail(处方用药信息表)】的数据库操作Mapper
|
||||
*/
|
||||
public interface BasicSkPrescribeItemDetailMapper extends BaseMapper<BasicSkPrescribeItemDetailEntity> {
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -0,0 +1,54 @@
|
||||
package com.glxp.api.req.basic;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.glxp.api.util.page.ListPageRequest;
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class BasicSkPrescribeDiRequest extends ListPageRequest {
|
||||
|
||||
|
||||
/**
|
||||
* 项目组套外键
|
||||
*/
|
||||
@TableField(value = "pId")
|
||||
private Long pId;
|
||||
|
||||
/**
|
||||
* 患者编码
|
||||
*/
|
||||
@TableField(value = "sickerCode")
|
||||
private String sickerCode;
|
||||
|
||||
/**
|
||||
* 住院号
|
||||
*/
|
||||
@TableField(value = "adNum")
|
||||
private String adNum;
|
||||
|
||||
/**
|
||||
* 处方编码
|
||||
*/
|
||||
@TableField(value = "prescribeCode")
|
||||
private String prescribeCode;
|
||||
|
||||
/**
|
||||
* 耗材产品id
|
||||
*/
|
||||
@TableField(value = "relId")
|
||||
private Long relId;
|
||||
|
||||
/**
|
||||
* 耗材名称
|
||||
*/
|
||||
@TableField(value = "thrName")
|
||||
private String thrName;
|
||||
|
||||
/**
|
||||
* 耗材编码
|
||||
*/
|
||||
@TableField(value = "thrCode")
|
||||
private String thrCode;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package com.glxp.api.service;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.glxp.api.dao.basic.BasicSkPrescribeDiMapper;
|
||||
import com.glxp.api.dao.basic.BasicSkProjectMapper;
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeDiEntity;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.glxp.api.req.basic.BasicSkPrescribeDiRequest;
|
||||
import com.glxp.api.req.basic.BasicSkPrescribeRequest;
|
||||
import com.glxp.api.res.basic.BasicSkPrescribeResponse;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 针对表【basic_sk_prescribe_item_detail(处方使用耗材信息表)】的数据库操作Service
|
||||
*/
|
||||
public interface BasicSkPrescribeDiService extends IService<BasicSkPrescribeDiEntity> {
|
||||
|
||||
List<BasicSkPrescribeDiEntity> filterList(BasicSkPrescribeDiRequest basicSkPrescribeDiRequest);
|
||||
|
||||
}
|
@ -1,11 +0,0 @@
|
||||
package com.glxp.api.service;
|
||||
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeItemDetailEntity;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* 针对表【basic_sk_prescribe_item_detail(处方用药信息表)】的数据库操作Service
|
||||
*/
|
||||
public interface BasicSkPrescribeItemDetailService extends IService<BasicSkPrescribeItemDetailEntity> {
|
||||
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
package com.glxp.api.service.basic.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeDiEntity;
|
||||
import com.glxp.api.req.basic.BasicSkPrescribeDiRequest;
|
||||
import com.glxp.api.req.basic.BasicSkPrescribeRequest;
|
||||
import com.glxp.api.res.basic.BasicSkPrescribeResponse;
|
||||
import com.glxp.api.service.BasicSkPrescribeDiService;
|
||||
import com.glxp.api.dao.basic.BasicSkPrescribeDiMapper;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 针对表【basic_sk_prescribe_item_detail(处方关联的耗材信息表)】的数据库操作Service实现
|
||||
*/
|
||||
@Service
|
||||
public class BasicSkPrescribeDiServiceImpl extends ServiceImpl<BasicSkPrescribeDiMapper, BasicSkPrescribeDiEntity>
|
||||
implements BasicSkPrescribeDiService {
|
||||
|
||||
public List<BasicSkPrescribeDiEntity> filterList(BasicSkPrescribeDiRequest basicSkPrescribeDiRequest) {
|
||||
if (basicSkPrescribeDiRequest == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
if (basicSkPrescribeDiRequest.getPage() != null) {
|
||||
int offset = (basicSkPrescribeDiRequest.getPage() - 1) * basicSkPrescribeDiRequest.getLimit();
|
||||
PageHelper.offsetPage(offset, basicSkPrescribeDiRequest.getLimit());
|
||||
}
|
||||
List<BasicSkPrescribeDiEntity> data = super.baseMapper.filterList(basicSkPrescribeDiRequest);
|
||||
return data;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -1,20 +0,0 @@
|
||||
package com.glxp.api.service.basic.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.glxp.api.entity.basic.BasicSkPrescribeItemDetailEntity;
|
||||
import com.glxp.api.service.BasicSkPrescribeItemDetailService;
|
||||
import com.glxp.api.dao.basic.BasicSkPrescribeItemDetailMapper;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 针对表【basic_sk_prescribe_item_detail(处方用药信息表)】的数据库操作Service实现
|
||||
*/
|
||||
@Service
|
||||
public class BasicSkPrescribeItemDetailServiceImpl extends ServiceImpl<BasicSkPrescribeItemDetailMapper, BasicSkPrescribeItemDetailEntity>
|
||||
implements BasicSkPrescribeItemDetailService{
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -0,0 +1,66 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.glxp.api.dao.basic.BasicSkPrescribeDiMapper">
|
||||
<resultMap id="BaseResultMap" type="com.glxp.api.entity.basic.BasicSkPrescribeDiEntity">
|
||||
<id property="id" column="id" jdbcType="BIGINT"/>
|
||||
<result property="pId" column="pId" jdbcType="BIGINT"/>
|
||||
<result property="sickerCode" column="sickerCode" jdbcType="VARCHAR"/>
|
||||
<result property="prescribeCode" column="prescribeCode" jdbcType="VARCHAR"/>
|
||||
<result property="relId" column="relId" jdbcType="BIGINT"/>
|
||||
<result property="thrName" column="thrName" jdbcType="VARCHAR"/>
|
||||
<result property="thrCode" column="thrCode" jdbcType="VARCHAR"/>
|
||||
<result property="measureCount" column="measureCount" jdbcType="VARCHAR"/>
|
||||
<result property="measureUnit" column="measureUnit" jdbcType="VARCHAR"/>
|
||||
<result property="category" column="category" jdbcType="VARCHAR"/>
|
||||
<result property="frequency" column="frequency" jdbcType="VARCHAR"/>
|
||||
<result property="count" column="count" jdbcType="INTEGER"/>
|
||||
<result property="price" column="price" jdbcType="DECIMAL"/>
|
||||
<result property="ggxh" column="ggxh" jdbcType="VARCHAR"/>
|
||||
<result property="remark" column="remark" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="Base_Column_List">
|
||||
id,
|
||||
pId,
|
||||
sickerCode,
|
||||
prescribeCode,
|
||||
relId,
|
||||
thrName,
|
||||
thrCode,
|
||||
measureCount,
|
||||
measureUnit,
|
||||
category,
|
||||
frequency,
|
||||
count,
|
||||
price,
|
||||
ggxh,
|
||||
remark
|
||||
</sql>
|
||||
|
||||
|
||||
<select id="filterList" parameterType="com.glxp.api.req.basic.BasicSkPrescribeDiRequest"
|
||||
resultType="com.glxp.api.entity.basic.BasicSkPrescribeDiEntity">
|
||||
SELECT *
|
||||
FROM basic_sk_prescribe_item_detail
|
||||
<where>
|
||||
<if test="sickerCode != '' and sickerCode != null">
|
||||
AND sickerCode LIKE concat('%', #{sickerCode}, '%')
|
||||
</if>
|
||||
<if test="prescribeCode != null and prescribeCode != ''">
|
||||
AND prescribeCode = #{prescribeCode}
|
||||
</if>
|
||||
<if test="relId != null and relId != ''">
|
||||
AND relId = #{relId}
|
||||
</if>
|
||||
<if test="thrName != null and thrName != ''">
|
||||
AND thrName = #{thrName}
|
||||
</if>
|
||||
<if test="thrCode != null and thrCode != ''">
|
||||
AND thrCode = #{thrCode}
|
||||
</if>
|
||||
</where>
|
||||
order by prescribeDate
|
||||
</select>
|
||||
</mapper>
|
@ -1,32 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.glxp.api.dao.basic.BasicSkPrescribeItemDetailMapper">
|
||||
|
||||
<resultMap id="BaseResultMap" type="com.glxp.api.entity.basic.BasicSkPrescribeItemDetailEntity">
|
||||
<id property="id" column="id" jdbcType="BIGINT"/>
|
||||
<result property="pId" column="pId" jdbcType="BIGINT"/>
|
||||
<result property="sickerCode" column="sickerCode" jdbcType="VARCHAR"/>
|
||||
<result property="prescribeCode" column="prescribeCode" jdbcType="VARCHAR"/>
|
||||
<result property="relId" column="relId" jdbcType="BIGINT"/>
|
||||
<result property="thrName" column="thrName" jdbcType="VARCHAR"/>
|
||||
<result property="thrCode" column="thrCode" jdbcType="VARCHAR"/>
|
||||
<result property="measureCount" column="measureCount" jdbcType="VARCHAR"/>
|
||||
<result property="measureUnit" column="measureUnit" jdbcType="VARCHAR"/>
|
||||
<result property="category" column="category" jdbcType="VARCHAR"/>
|
||||
<result property="frequency" column="frequency" jdbcType="VARCHAR"/>
|
||||
<result property="count" column="count" jdbcType="INTEGER"/>
|
||||
<result property="price" column="price" jdbcType="DECIMAL"/>
|
||||
<result property="ggxh" column="ggxh" jdbcType="VARCHAR"/>
|
||||
<result property="remark" column="remark" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="Base_Column_List">
|
||||
id,pId,sickerCode,
|
||||
prescribeCode,relId,thrName,
|
||||
thrCode,measureCount,measureUnit,
|
||||
category,frequency,count,
|
||||
price,ggxh,remark
|
||||
</sql>
|
||||
</mapper>
|
Loading…
Reference in New Issue