This commit is contained in:
2020-03-20 18:23:50 +08:00
parent 14a0cb0a74
commit e4a9e1d5d7
13 changed files with 3027 additions and 395 deletions

View File

@@ -0,0 +1,62 @@
package com.lk.phr.dao.phr;
import com.lk.phr.model.phr.UserHistoryModel;
import com.lk.phr.model.phr.UserHistoryModelWithBLOBs;
public interface UserHistoryDao {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
int insert(UserHistoryModelWithBLOBs record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
int insertSelective(UserHistoryModelWithBLOBs record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
UserHistoryModelWithBLOBs selectByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(UserHistoryModelWithBLOBs record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
int updateByPrimaryKeyWithBLOBs(UserHistoryModelWithBLOBs record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table user_history
*
* @mbg.generated
*/
int updateByPrimaryKey(UserHistoryModel record);
}

View File

@@ -0,0 +1,404 @@
<?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.lk.phr.dao.phr.UserHistoryDao">
<resultMap id="BaseResultMap" type="com.lk.phr.model.phr.UserHistoryModel">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
<id column="id" jdbcType="BIGINT" property="id" />
<result column="user_id" jdbcType="BIGINT" property="userId" />
<result column="org_id" jdbcType="BIGINT" property="orgId" />
<result column="medical" jdbcType="BIT" property="medical" />
<result column="flag" jdbcType="INTEGER" property="flag" />
<result column="updated" jdbcType="TIMESTAMP" property="updated" />
<result column="created" jdbcType="TIMESTAMP" property="created" />
<result column="source" jdbcType="VARCHAR" property="source" />
<result column="seq_no" jdbcType="BIGINT" property="seqNo" />
<result column="out_no" jdbcType="VARCHAR" property="outNo" />
<result column="check_type_name" jdbcType="VARCHAR" property="checkTypeName" />
<result column="check_type_code" jdbcType="VARCHAR" property="checkTypeCode" />
<result column="score" jdbcType="DOUBLE" property="score" />
<result column="evaluate" jdbcType="VARCHAR" property="evaluate" />
<result column="check_addr" jdbcType="VARCHAR" property="checkAddr" />
<result column="check_organization" jdbcType="VARCHAR" property="checkOrganization" />
<result column="device_code" jdbcType="VARCHAR" property="deviceCode" />
<result column="device_no" jdbcType="VARCHAR" property="deviceNo" />
<result column="entropy_score" jdbcType="DOUBLE" property="entropyScore" />
<result column="phr_uid" jdbcType="BIGINT" property="phrUid" />
<result column="check_sub_type" jdbcType="VARCHAR" property="checkSubType" />
</resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.lk.phr.model.phr.UserHistoryModelWithBLOBs">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
<result column="face_url" jdbcType="LONGVARCHAR" property="faceUrl" />
<result column="tongue_url" jdbcType="LONGVARCHAR" property="tongueUrl" />
<result column="base_of_tongue_url" jdbcType="LONGVARCHAR" property="baseOfTongueUrl" />
<result column="obj_json" jdbcType="LONGVARCHAR" property="objJson" />
</resultMap>
<sql id="Base_Column_List">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
id, user_id, org_id, medical, flag, updated, created, source, seq_no, out_no, check_type_name,
check_type_code, score, evaluate, check_addr, check_organization, device_code, device_no,
entropy_score, phr_uid, check_sub_type
</sql>
<sql id="Blob_Column_List">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
face_url, tongue_url, base_of_tongue_url, obj_json
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="ResultMapWithBLOBs">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
select
<include refid="Base_Column_List" />
,
<include refid="Blob_Column_List" />
from user_history
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
delete from user_history
where id = #{id,jdbcType=BIGINT}
</delete>
<insert id="insert" parameterType="com.lk.phr.model.phr.UserHistoryModelWithBLOBs">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
insert into user_history (id, user_id, org_id,
medical, flag, updated,
created, source, seq_no,
out_no, check_type_name, check_type_code,
score, evaluate, check_addr,
check_organization, device_code, device_no,
entropy_score, phr_uid, check_sub_type,
face_url, tongue_url, base_of_tongue_url,
obj_json)
values (#{id,jdbcType=BIGINT}, #{userId,jdbcType=BIGINT}, #{orgId,jdbcType=BIGINT},
#{medical,jdbcType=BIT}, #{flag,jdbcType=INTEGER}, #{updated,jdbcType=TIMESTAMP},
#{created,jdbcType=TIMESTAMP}, #{source,jdbcType=VARCHAR}, #{seqNo,jdbcType=BIGINT},
#{outNo,jdbcType=VARCHAR}, #{checkTypeName,jdbcType=VARCHAR}, #{checkTypeCode,jdbcType=VARCHAR},
#{score,jdbcType=DOUBLE}, #{evaluate,jdbcType=VARCHAR}, #{checkAddr,jdbcType=VARCHAR},
#{checkOrganization,jdbcType=VARCHAR}, #{deviceCode,jdbcType=VARCHAR}, #{deviceNo,jdbcType=VARCHAR},
#{entropyScore,jdbcType=DOUBLE}, #{phrUid,jdbcType=BIGINT}, #{checkSubType,jdbcType=VARCHAR},
#{faceUrl,jdbcType=LONGVARCHAR}, #{tongueUrl,jdbcType=LONGVARCHAR}, #{baseOfTongueUrl,jdbcType=LONGVARCHAR},
#{objJson,jdbcType=LONGVARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.lk.phr.model.phr.UserHistoryModelWithBLOBs">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
insert into user_history
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="userId != null">
user_id,
</if>
<if test="orgId != null">
org_id,
</if>
<if test="medical != null">
medical,
</if>
<if test="flag != null">
flag,
</if>
<if test="updated != null">
updated,
</if>
<if test="created != null">
created,
</if>
<if test="source != null">
source,
</if>
<if test="seqNo != null">
seq_no,
</if>
<if test="outNo != null">
out_no,
</if>
<if test="checkTypeName != null">
check_type_name,
</if>
<if test="checkTypeCode != null">
check_type_code,
</if>
<if test="score != null">
score,
</if>
<if test="evaluate != null">
evaluate,
</if>
<if test="checkAddr != null">
check_addr,
</if>
<if test="checkOrganization != null">
check_organization,
</if>
<if test="deviceCode != null">
device_code,
</if>
<if test="deviceNo != null">
device_no,
</if>
<if test="entropyScore != null">
entropy_score,
</if>
<if test="phrUid != null">
phr_uid,
</if>
<if test="checkSubType != null">
check_sub_type,
</if>
<if test="faceUrl != null">
face_url,
</if>
<if test="tongueUrl != null">
tongue_url,
</if>
<if test="baseOfTongueUrl != null">
base_of_tongue_url,
</if>
<if test="objJson != null">
obj_json,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="userId != null">
#{userId,jdbcType=BIGINT},
</if>
<if test="orgId != null">
#{orgId,jdbcType=BIGINT},
</if>
<if test="medical != null">
#{medical,jdbcType=BIT},
</if>
<if test="flag != null">
#{flag,jdbcType=INTEGER},
</if>
<if test="updated != null">
#{updated,jdbcType=TIMESTAMP},
</if>
<if test="created != null">
#{created,jdbcType=TIMESTAMP},
</if>
<if test="source != null">
#{source,jdbcType=VARCHAR},
</if>
<if test="seqNo != null">
#{seqNo,jdbcType=BIGINT},
</if>
<if test="outNo != null">
#{outNo,jdbcType=VARCHAR},
</if>
<if test="checkTypeName != null">
#{checkTypeName,jdbcType=VARCHAR},
</if>
<if test="checkTypeCode != null">
#{checkTypeCode,jdbcType=VARCHAR},
</if>
<if test="score != null">
#{score,jdbcType=DOUBLE},
</if>
<if test="evaluate != null">
#{evaluate,jdbcType=VARCHAR},
</if>
<if test="checkAddr != null">
#{checkAddr,jdbcType=VARCHAR},
</if>
<if test="checkOrganization != null">
#{checkOrganization,jdbcType=VARCHAR},
</if>
<if test="deviceCode != null">
#{deviceCode,jdbcType=VARCHAR},
</if>
<if test="deviceNo != null">
#{deviceNo,jdbcType=VARCHAR},
</if>
<if test="entropyScore != null">
#{entropyScore,jdbcType=DOUBLE},
</if>
<if test="phrUid != null">
#{phrUid,jdbcType=BIGINT},
</if>
<if test="checkSubType != null">
#{checkSubType,jdbcType=VARCHAR},
</if>
<if test="faceUrl != null">
#{faceUrl,jdbcType=LONGVARCHAR},
</if>
<if test="tongueUrl != null">
#{tongueUrl,jdbcType=LONGVARCHAR},
</if>
<if test="baseOfTongueUrl != null">
#{baseOfTongueUrl,jdbcType=LONGVARCHAR},
</if>
<if test="objJson != null">
#{objJson,jdbcType=LONGVARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.lk.phr.model.phr.UserHistoryModelWithBLOBs">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update user_history
<set>
<if test="userId != null">
user_id = #{userId,jdbcType=BIGINT},
</if>
<if test="orgId != null">
org_id = #{orgId,jdbcType=BIGINT},
</if>
<if test="medical != null">
medical = #{medical,jdbcType=BIT},
</if>
<if test="flag != null">
flag = #{flag,jdbcType=INTEGER},
</if>
<if test="updated != null">
updated = #{updated,jdbcType=TIMESTAMP},
</if>
<if test="created != null">
created = #{created,jdbcType=TIMESTAMP},
</if>
<if test="source != null">
source = #{source,jdbcType=VARCHAR},
</if>
<if test="seqNo != null">
seq_no = #{seqNo,jdbcType=BIGINT},
</if>
<if test="outNo != null">
out_no = #{outNo,jdbcType=VARCHAR},
</if>
<if test="checkTypeName != null">
check_type_name = #{checkTypeName,jdbcType=VARCHAR},
</if>
<if test="checkTypeCode != null">
check_type_code = #{checkTypeCode,jdbcType=VARCHAR},
</if>
<if test="score != null">
score = #{score,jdbcType=DOUBLE},
</if>
<if test="evaluate != null">
evaluate = #{evaluate,jdbcType=VARCHAR},
</if>
<if test="checkAddr != null">
check_addr = #{checkAddr,jdbcType=VARCHAR},
</if>
<if test="checkOrganization != null">
check_organization = #{checkOrganization,jdbcType=VARCHAR},
</if>
<if test="deviceCode != null">
device_code = #{deviceCode,jdbcType=VARCHAR},
</if>
<if test="deviceNo != null">
device_no = #{deviceNo,jdbcType=VARCHAR},
</if>
<if test="entropyScore != null">
entropy_score = #{entropyScore,jdbcType=DOUBLE},
</if>
<if test="phrUid != null">
phr_uid = #{phrUid,jdbcType=BIGINT},
</if>
<if test="checkSubType != null">
check_sub_type = #{checkSubType,jdbcType=VARCHAR},
</if>
<if test="faceUrl != null">
face_url = #{faceUrl,jdbcType=LONGVARCHAR},
</if>
<if test="tongueUrl != null">
tongue_url = #{tongueUrl,jdbcType=LONGVARCHAR},
</if>
<if test="baseOfTongueUrl != null">
base_of_tongue_url = #{baseOfTongueUrl,jdbcType=LONGVARCHAR},
</if>
<if test="objJson != null">
obj_json = #{objJson,jdbcType=LONGVARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKeyWithBLOBs" parameterType="com.lk.phr.model.phr.UserHistoryModelWithBLOBs">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update user_history
set user_id = #{userId,jdbcType=BIGINT},
org_id = #{orgId,jdbcType=BIGINT},
medical = #{medical,jdbcType=BIT},
flag = #{flag,jdbcType=INTEGER},
updated = #{updated,jdbcType=TIMESTAMP},
created = #{created,jdbcType=TIMESTAMP},
source = #{source,jdbcType=VARCHAR},
seq_no = #{seqNo,jdbcType=BIGINT},
out_no = #{outNo,jdbcType=VARCHAR},
check_type_name = #{checkTypeName,jdbcType=VARCHAR},
check_type_code = #{checkTypeCode,jdbcType=VARCHAR},
score = #{score,jdbcType=DOUBLE},
evaluate = #{evaluate,jdbcType=VARCHAR},
check_addr = #{checkAddr,jdbcType=VARCHAR},
check_organization = #{checkOrganization,jdbcType=VARCHAR},
device_code = #{deviceCode,jdbcType=VARCHAR},
device_no = #{deviceNo,jdbcType=VARCHAR},
entropy_score = #{entropyScore,jdbcType=DOUBLE},
phr_uid = #{phrUid,jdbcType=BIGINT},
check_sub_type = #{checkSubType,jdbcType=VARCHAR},
face_url = #{faceUrl,jdbcType=LONGVARCHAR},
tongue_url = #{tongueUrl,jdbcType=LONGVARCHAR},
base_of_tongue_url = #{baseOfTongueUrl,jdbcType=LONGVARCHAR},
obj_json = #{objJson,jdbcType=LONGVARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.lk.phr.model.phr.UserHistoryModel">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update user_history
set user_id = #{userId,jdbcType=BIGINT},
org_id = #{orgId,jdbcType=BIGINT},
medical = #{medical,jdbcType=BIT},
flag = #{flag,jdbcType=INTEGER},
updated = #{updated,jdbcType=TIMESTAMP},
created = #{created,jdbcType=TIMESTAMP},
source = #{source,jdbcType=VARCHAR},
seq_no = #{seqNo,jdbcType=BIGINT},
out_no = #{outNo,jdbcType=VARCHAR},
check_type_name = #{checkTypeName,jdbcType=VARCHAR},
check_type_code = #{checkTypeCode,jdbcType=VARCHAR},
score = #{score,jdbcType=DOUBLE},
evaluate = #{evaluate,jdbcType=VARCHAR},
check_addr = #{checkAddr,jdbcType=VARCHAR},
check_organization = #{checkOrganization,jdbcType=VARCHAR},
device_code = #{deviceCode,jdbcType=VARCHAR},
device_no = #{deviceNo,jdbcType=VARCHAR},
entropy_score = #{entropyScore,jdbcType=DOUBLE},
phr_uid = #{phrUid,jdbcType=BIGINT},
check_sub_type = #{checkSubType,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>