accept.xml 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  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="com.lemon.lifecenter.mapper.AcceptMapper">
  4. <select id="selectAcceptList" parameterType="AcceptDTO" resultType="AcceptDTO">
  5. <![CDATA[
  6. SELECT accept_idx AS acceptIdx,
  7. create_date AS createDate,
  8. title AS title,
  9. content AS content,
  10. sort_order AS sortOrder,
  11. necessary_yn AS necessaryYn,
  12. use_yn AS useYn,
  13. accept_type AS acceptType
  14. FROM accept_list
  15. WHERE use_yn = 'Y'
  16. ORDER BY sort_order ASC
  17. ]]>
  18. </select>
  19. <insert id="insertAcceptMemberLog" parameterType="AcceptDTO">
  20. <![CDATA[
  21. INSERT
  22. INTO accept_member_log
  23. ( id, accept_idx, accept_date )
  24. VALUES ( #{id}, #{acceptIdx}, NOW() );
  25. ]]>
  26. </insert>
  27. <insert id="insertAcceptPatientLog" parameterType="AcceptDTO">
  28. <![CDATA[
  29. INSERT
  30. INTO accept_member_log
  31. ( patientIdx, accept_idx, accept_date )
  32. VALUES ( #{patientIdx}, #{acceptIdx}, NOW() );
  33. ]]>
  34. </insert>
  35. <select id="selectMemberLogCheck" parameterType="AcceptDTO" resultType="int">
  36. <![CDATA[
  37. SELECT COUNT(*) total
  38. FROM accept_member_log
  39. WHERE accept_idx = #{acceptIdx}
  40. ]]>
  41. </select>
  42. </mapper>