StoreMapper.xml 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  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="WebsiteES.myBatis.StoreMapper">
  4. <resultMap id="BaseResultMap" type="WebsiteES.myBatis.Store">
  5. <!--
  6. WARNING - @mbggenerated
  7. This element is automatically generated by MyBatis Generator, do not modify.
  8. -->
  9. <result column="store_id" jdbcType="TINYINT" property="storeId" />
  10. <result column="manager_staff_id" jdbcType="TINYINT" property="managerStaffId" />
  11. <result column="address_id" jdbcType="SMALLINT" property="addressId" />
  12. <result column="last_update" jdbcType="TIMESTAMP" property="lastUpdate" />
  13. </resultMap>
  14. <insert id="insert" parameterType="WebsiteES.myBatis.Store">
  15. <!--
  16. WARNING - @mbggenerated
  17. This element is automatically generated by MyBatis Generator, do not modify.
  18. -->
  19. insert into store (store_id, manager_staff_id, address_id,
  20. last_update)
  21. values (#{storeId,jdbcType=TINYINT}, #{managerStaffId,jdbcType=TINYINT}, #{addressId,jdbcType=SMALLINT},
  22. #{lastUpdate,jdbcType=TIMESTAMP})
  23. </insert>
  24. <insert id="insertSelective" parameterType="WebsiteES.myBatis.Store">
  25. <!--
  26. WARNING - @mbggenerated
  27. This element is automatically generated by MyBatis Generator, do not modify.
  28. -->
  29. insert into store
  30. <trim prefix="(" suffix=")" suffixOverrides=",">
  31. <if test="storeId != null">
  32. store_id,
  33. </if>
  34. <if test="managerStaffId != null">
  35. manager_staff_id,
  36. </if>
  37. <if test="addressId != null">
  38. address_id,
  39. </if>
  40. <if test="lastUpdate != null">
  41. last_update,
  42. </if>
  43. </trim>
  44. <trim prefix="values (" suffix=")" suffixOverrides=",">
  45. <if test="storeId != null">
  46. #{storeId,jdbcType=TINYINT},
  47. </if>
  48. <if test="managerStaffId != null">
  49. #{managerStaffId,jdbcType=TINYINT},
  50. </if>
  51. <if test="addressId != null">
  52. #{addressId,jdbcType=SMALLINT},
  53. </if>
  54. <if test="lastUpdate != null">
  55. #{lastUpdate,jdbcType=TIMESTAMP},
  56. </if>
  57. </trim>
  58. </insert>
  59. </mapper>