ShopMapper.xml 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  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.caimei365.user.mapper.ShopMapper">
  4. <update id="updateUserByUpdateInfo">
  5. update user set email = #{email},userName = #{userName},name = #{name}
  6. where userID = #{userId}
  7. </update>
  8. <update id="updateClubByUpdateInfo">
  9. update club set userID = #{userId}, name = #{name}, sname = #{sName}, contractEmail1 = #{contractEmail},
  10. <if test="contractPhone != null">
  11. contractPhone = #{contractPhone},
  12. </if>
  13. <if test="linkMan != null">
  14. linkMan = #{linkMan},
  15. </if>
  16. provinceID = #{provinceId}, cityID = #{cityId}, townID = #{townId}, address = #{address},
  17. <if test="shopPhoto != null and shopPhoto != 'null' and shopPhoto != ''">
  18. headpic = #{shopPhoto},
  19. </if>
  20. businessLicenseImage = #{businessLicense}, socialCreditCode = #{socialCreditCode}, firstClubType = #{firstClubType},
  21. <if test="firstClubType == 1">
  22. secondClubType = #{secondClubType}, department = #{department}, medicalPracticeLicenseImg = #{medicalPracticeLicense},
  23. </if>
  24. <if test="mainProduct != null">
  25. mainpro = #{mainProduct},
  26. </if>
  27. <if test="fax != null">
  28. fax = #{fax},
  29. </if>
  30. <if test="profile != null">
  31. info = #{profile},
  32. </if>
  33. lastModify = #{lastModifyTime}
  34. where clubID = #{clubId}
  35. </update>
  36. <select id="getShopCert" resultType="java.lang.String">
  37. SELECT image FROM shopcert WHERE shopID = #{shopId} AND shopCertTypeID = #{shopCertTypeId}
  38. </select>
  39. <select id="getShopById" resultType="com.caimei365.user.model.vo.ShopVo">
  40. select * from shop where shopID = #{shopId}
  41. </select>
  42. </mapper>