<?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.ssm.manage.mapper.MemberLoginRecordingMapper">
  <resultMap id="BaseResultMap" type="com.ssm.manage.entity.MemberLoginRecording">
    <id column="id" jdbcType="BIGINT" property="id" />
    <result property="memberNum" column="member_num" jdbcType="VARCHAR"/>
    <result property="memberId" column="member_id" jdbcType="BIGINT"/>
    <result property="memberName" column="mmeber_name" jdbcType="VARCHAR"/>
    <result property="loginTime" column="login_time" jdbcType="TIMESTAMP"/>
    <result property="agreementId" column="agreement_id" jdbcType="BIGINT"/>
    <result property="content" column="cpntent" jdbcType="VARCHAR"/>
    <result property="agreementName" column="agreement_name" jdbcType="VARCHAR"/>
    <result property="loginType" column="login_type" jdbcType="INTEGER"/>
   </resultMap>
  <insert id="addMemberLogin">
      insert into member_login_recording_${tab}
      (
        id,member_id,member_num,member_name,login_time,agreement_id,content,agreement_name,login_type
      )values (#{id},#{memberId},#{memberNum},#{memberName},#{loginTime},#{agreementId},#{content},#{agreementName},#{loginType})
  </insert>
  <select id="createTable" parameterType="java.lang.String">
    create table IF NOT EXISTS member_login_recording_${tab} like member_login_recording
  </select>
</mapper>