| | |
| | | where a.ID=#{id} |
| | | </select> |
| | | |
| | | |
| | | |
| | | <!-- 根据手机和密码查询 --> |
| | | <select id="selectVipByPhonePassWord" resultMap="SysVipInfoMap"> |
| | | <include refid="select"></include> |
| | |
| | | a.PHONE phone, |
| | | a.photo photo, |
| | | b.arriveCnt arriveCnt, |
| | | g.shop_short_name shopName |
| | | g.shop_short_name shopName, |
| | | z.level_name vipLevel |
| | | from sys_vip_info a |
| | | left join ( |
| | | select x.vip_id, count(1) arriveCnt from ( |
| | |
| | | group by date_format(datatime, '%Y-%m-%d'), vip_id |
| | | ) x group by x.vip_id |
| | | ) b on a.ID=b.vip_id |
| | | left join sys_vip_level z on a.level_id=z.id |
| | | <!-- 本月消费 --> |
| | | <if test="record.sort == 'used'"> |
| | | left join ( |