1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- <?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.caimei365.order.mapper.MessagePushMapper">
- <insert id="insertShortLink">
- INSERT INTO cm_short_link (markId, shortLink, jumpLink, createTime)
- VALUES (#{markId}, #{shortLink}, #{url}, NOW())
- </insert>
- <insert id="insertNewLink">
- INSERT INTO cm_short_link (markId, clubId, userId, shortLink, jumpLink, createTime)
- VALUES (#{markId}, #{clubId}, #{userId}, #{shortLink}, #{jumpLink}, NOW())
- </insert>
- <update id="updateSmsSendCount">
- UPDATE cm_sms_statistics
- SET sendNum = (sendNum + #{count})
- WHERE markId = #{markId}
- </update>
- <select id="findIdByShortLink" resultType="java.lang.Integer">
- SELECT id
- FROM cm_short_link
- WHERE shortLink = #{shortLink}
- </select>
- <select id="findOldUser" resultType="com.caimei365.order.model.vo.PushMessageUserVo">
- select cb.mobile as mobile,
- cb.authUserId as userId
- from cm_brand_auth ca
- left join cm_brand_club_user cb on ca.id=cb.authid
- where cb.mobile
- is not null and ca.authUserId=12
- and ca.`STATUS`=1
- group by cb.mobile
- </select>
- <select id="findOldUserTow" resultType="com.caimei365.order.model.vo.PushMessageUserVo">
- SELECT
- a.clubID AS clubID,
- u.userID AS userID,
- a.contractMobile AS mobile
- FROM club a
- LEFT JOIN USER u ON u.userID = a.userID
- WHERE u.userID IN
- (6286,6737,7076,7793,8424,9622,10464,10510,10612,10989,10992,11102,11301,11313,12665,11662,11677,
- 12817,12819,12841,12935,12938,12962,12972,12993,12996,13009,13033,13120,13132,13164,13180,13189,13216,13229,13239,13287,13308,13406,
- 13442,13454,13459,13492,13554,13764,13792,13819,13834,13856,13863,13871,13876,13882,13892,13907,13928,13929,13938,13943,13949,13954,
- 13966,14017,14058,14060,14238,14260,14295,14302,14304,14316,14374,14394,14410,14427,14434,14438,14457,14474,14477,14499,14572,14591,
- 14659,14662,14674,14701,14716,14817,14823,14828,14861,14873,14910,14943,15043,15113,15144,15164,15177,15197,15215,15217,15221,15222,
- 15299,15302,15310,15317,15365,15389,15404,15435,15487,15677,15710,15721,15786,15796,15930,15991,15999,16010,16108,16123,16128,16155,
- 16158,16179,16186,16188,16206,16271,16295,16311,16383,16386,16404,16426,16435,16478,16534,16570,16581,16615,16634,16641,16665,16682,
- 16723,16827,16828,16831,16838,16866,16880,16881,16885,16888,16912,16921,16924,16925,16927,16934,16937,16940,16941,16950,16965,16971,
- 16976,16979,16981,16989,16995,17005,17025,17036,17047,17061,17062,17070,17071,17073,17075,17086,17089,17100,17113,17122,17141,17145,
- 17149,17155,17161,17162,17201,17209,17213,17217,17238,17239,17252,17268,17279,17280,17295,17297,17305,17315,17320,17328,17331,17339,
- 17341,17348,17371,17373,17376,17388,17396,17401,17428,17431,17436,17439,17460,17474,17482,17483,17489,17490,17486,17504,17509,17512,
- 17514,17518,17534,17538,17539,17540,17568,17582,17585,17586,17603,17606,17615,17625,17627,17631,17650,17658,17660,17672,17677,17688,17706,
- 17716,17720,17725,17763,17769,17780,17793,17797,17814,17816,17822,17848,17857,17860,17868,17875,17880,17883,17884,17888,17896,17898,
- 17901,17907,17911,17929,17947,17948,17950,17956,17973,17972,17975,17986,17994,17999,18014,18026,18030,18034,18056,18067,18068,18121,
- 18122,18129,18134,18148,18157,18160,18167,18170,18171,18175,18192,18195,18208,18246,18258,18277,10101,10276,10325,10421,11023,11026)
- </select>
- </mapper>
|