123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207 |
- <?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.caimei.modules.user.dao.CmGclubDao">
- <sql id="cmGclubColumns">
- a.gclubID AS "gclubID",
- a.name AS "name",
- a.contacts AS "contacts",
- a.cellphone AS "cellphone",
- a.telphone AS "telphone",
- a.post AS "post",
- a.address AS "address",
- a.scale AS "scale",
- a.empnum AS "empnum",
- a.mainpro AS "mainpro",
- a.remark AS "remark",
- a.image AS "image",
- a.regStatus AS "regStatus",
- a.addTime AS "addTime",
- a.loginTime AS "loginTime",
- a.provinceID AS "provinceID",
- a.cityID AS "cityID",
- a.townID AS "townID",
- a.agreement AS "agreement",
- a.flag AS "flag",
- a.userID AS "userID",
- a.clubstatus AS "clubstatus",
- a.BUSINESSLICENSEIMAGE AS "BUSINESSLICENSEIMAGE",
- a.LASTMODIFY AS "LASTMODIFY",
- a.inviterBindID AS "inviterBindID",
- a.inviterName AS "inviterName",
- a.headpic AS "headpic",
- a.mainServiceProviderID AS "mainServiceProviderID",
- a.scanTime AS "scanTime",
- a.checkTime AS "checkTime",
- a.spID AS "spID"
- </sql>
- <sql id="cmGclubJoins">
- </sql>
- <select id="get" resultType="CmGclub">
- SELECT
- <include refid="cmGclubColumns"/>
- FROM gclub a
- <include refid="cmGclubJoins"/>
- WHERE a.gclubID = #{id}
- </select>
- <select id="findList" resultType="CmGclub">
- SELECT
- <include refid="cmGclubColumns"/>
- FROM gclub a
- <include refid="cmGclubJoins"/>
- <where>
- <if test="gclubID != null and gclubID != ''">
- AND a.gclubID = #{id}
- </if>
- <if test="userID != null and userID != ''">
- AND a.userID = #{userID}
- </if>
- </where>
- <choose>
- <when test="page !=null and page.orderBy != null and page.orderBy != ''">
- ORDER BY ${page.orderBy}
- </when>
- <otherwise>
- </otherwise>
- </choose>
- </select>
- <select id="findAllList" resultType="CmGclub">
- SELECT
- <include refid="cmGclubColumns"/>
- FROM gclub a
- <include refid="cmGclubJoins"/>
- <where>
- </where>
- <choose>
- <when test="page !=null and page.orderBy != null and page.orderBy != ''">
- ORDER BY ${page.orderBy}
- </when>
- <otherwise>
- </otherwise>
- </choose>
- </select>
- <insert id="insert" parameterType="CmGclub" keyProperty="id" useGeneratedKeys="true">
- INSERT INTO gclub(
- name,
- contacts,
- cellphone,
- telphone,
- post,
- address,
- scale,
- empnum,
- mainpro,
- remark,
- image,
- regStatus,
- addTime,
- loginTime,
- provinceID,
- cityID,
- townID,
- agreement,
- flag,
- userID,
- clubstatus,
- BUSINESSLICENSEIMAGE,
- LASTMODIFY,
- inviterBindID,
- inviterName,
- headpic,
- mainServiceProviderID,
- scanTime,
- checkTime,
- spID
- ) VALUES (
- #{name},
- #{contacts},
- #{cellphone},
- #{telphone},
- #{post},
- #{address},
- #{scale},
- #{empnum},
- #{mainpro},
- #{remark},
- #{image},
- #{regStatus},
- #{addTime},
- #{loginTime},
- #{provinceID},
- #{cityID},
- #{townID},
- #{agreement},
- #{flag},
- #{userID},
- #{clubstatus},
- #{BUSINESSLICENSEIMAGE},
- #{LASTMODIFY},
- #{inviterBindID},
- #{inviterName},
- #{headpic},
- #{mainServiceProviderID},
- #{scanTime},
- #{checkTime},
- #{spID}
- )
- </insert>
- <update id="update">
- UPDATE gclub SET
- name = #{name},
- contacts = #{contacts},
- cellphone = #{cellphone},
- telphone = #{telphone},
- post = #{post},
- address = #{address},
- scale = #{scale},
- empnum = #{empnum},
- mainpro = #{mainpro},
- remark = #{remark},
- image = #{image},
- regStatus = #{regStatus},
- addTime = #{addTime},
- loginTime = #{loginTime},
- provinceID = #{provinceID},
- cityID = #{cityID},
- townID = #{townID},
- agreement = #{agreement},
- flag = #{flag},
- userID = #{userID},
- clubstatus = #{clubstatus},
- BUSINESSLICENSEIMAGE = #{BUSINESSLICENSEIMAGE},
- LASTMODIFY = #{LASTMODIFY},
- inviterBindID = #{inviterBindID},
- inviterName = #{inviterName},
- headpic = #{headpic},
- mainServiceProviderID = #{mainServiceProviderID},
- scanTime = #{scanTime},
- checkTime = #{checkTime},
- spID = #{spID}
- WHERE gclubID = #{id}
- </update>
- <delete id="delete">
- DELETE FROM gclub
- WHERE gclubID = #{id}
- </delete>
- <update id="updateByUserId">
- UPDATE gclub SET
- regStatus = #{regStatus},
- flag = #{flag},
- LASTMODIFY = #{LASTMODIFY},
- inviterBindID = #{inviterBindID},
- inviterName = #{inviterName},
- mainServiceProviderID = #{mainServiceProviderID},
- spID = #{spID}
- WHERE userID = #{userID}
- </update>
- </mapper>
|