健康报告上传查看功能

This commit is contained in:
limqhz
2021-03-08 22:48:38 +08:00
parent 4247ae6e12
commit bc12c4b9ca
7 changed files with 180 additions and 7 deletions

View File

@@ -1,6 +1,8 @@
package com.sv.mapper;
import com.sv.entity.HealthDoc;
import org.apache.ibatis.annotations.Param;
import java.util.List;
public interface HealthDocMapper {
@@ -17,4 +19,6 @@ public interface HealthDocMapper {
int updateByPrimaryKey(HealthDoc record);
List<HealthDoc> findMemAll();
List<HealthDoc> findDocsByMemberId(@Param("memberId") Integer memberId);
}

View File

@@ -66,5 +66,18 @@ public class MemberHealthDocService extends MemberCardCommonService {
return pagination;
}
/**
* 小程序查询用户健康报告
* @param pagination 分页信息
* @return 分页结果
*/
public Pagination findDocs(Pagination pagination,Integer memberId) {
PageHelper.startPage(pagination.getPage(), pagination.getPageSize());
PageHelper.orderBy("doc_date desc");
pagination.setQueryResult(healthDocMapper.findDocsByMemberId(memberId));
return pagination;
}
}

View File

@@ -34,6 +34,13 @@
where 1=1
</select>
<select id="findDocsByMemberId" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
select
<include refid="Base_Column_List" />
from sv_health_docs
where member_id = #{memberId,jdbcType=INTEGER}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
delete from sv_health_docs
where id = #{id,jdbcType=INTEGER}