| @@ -0,0 +1,61 @@ | |||||
| package com.iformall.domain.po.tt; | |||||
| import com.baomidou.mybatisplus.annotation.TableField; | |||||
| import com.baomidou.mybatisplus.annotation.TableName; | |||||
| import com.iformall.domain.po.base.TenantEntity; | |||||
| import lombok.Data; | |||||
| import lombok.EqualsAndHashCode; | |||||
| import lombok.ToString; | |||||
| import java.util.Date; | |||||
| @TableName(value = "tt_up_settlein") | |||||
| @Data | |||||
| @ToString(callSuper = true) | |||||
| @EqualsAndHashCode(callSuper = true) | |||||
| public class TtUpSettlein extends TenantEntity { | |||||
| protected Long id; | |||||
| private Long cuserId; | |||||
| @io.swagger.annotations.ApiModelProperty(value="邀请码",name="invitationCode") | |||||
| private String invitationCode; | |||||
| @io.swagger.annotations.ApiModelProperty(value="联系人",name="liaisonMan") | |||||
| private String liaisonMan; | |||||
| @io.swagger.annotations.ApiModelProperty(value="联系电话",name="liaisonPhone") | |||||
| private String liaisonPhone; | |||||
| @io.swagger.annotations.ApiModelProperty(value="抖音号",name="name") | |||||
| private String ttUserName; | |||||
| @io.swagger.annotations.ApiModelProperty(value="",name="ttCountFans") | |||||
| private String ttCountFans; | |||||
| @io.swagger.annotations.ApiModelProperty(value="类型",name="bussinessTypes") | |||||
| private String bussinessTypes; | |||||
| @io.swagger.annotations.ApiModelProperty(value="说明",name="explain") | |||||
| private String explain; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "处理状态0:未处理,1已处理", name = "handleStatus") | |||||
| private Integer handleStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value="备注",name="remark") | |||||
| private String remark; | |||||
| @io.swagger.annotations.ApiModelProperty(value="创建时间",name="createDate") | |||||
| private Date createDate; | |||||
| @io.swagger.annotations.ApiModelProperty(value="更新时间",name="updateDate") | |||||
| private Date updateDate; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "是否删除1是0否", name = "isDel") | |||||
| private Integer isDel; | |||||
| @TableField(exist = false) | |||||
| @io.swagger.annotations.ApiModelProperty(value="查询-起始时间",name="startdate") | |||||
| private Date startdate; | |||||
| @TableField(exist = false) | |||||
| @io.swagger.annotations.ApiModelProperty(value="查询-结束时间",name="enddate") | |||||
| private Date enddate; | |||||
| } | |||||
| @@ -0,0 +1,13 @@ | |||||
| package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | |||||
| import com.iformall.domain.po.tt.TtUpSettlein; | |||||
| import java.util.List; | |||||
| public interface TtUpSettleinMapper extends CommonMapper<TtUpSettlein, Long> { | |||||
| List<TtUpSettlein> findList(TtUpSettlein record); | |||||
| } | |||||
| @@ -7,6 +7,7 @@ import com.github.pagehelper.PageInfo; | |||||
| import com.iformall.common.ErrorCode; | import com.iformall.common.ErrorCode; | ||||
| import com.iformall.common.IdWorker; | import com.iformall.common.IdWorker; | ||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.domain.po.WxMerchant; | |||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.po.tt.TtCoupon; | import com.iformall.domain.po.tt.TtCoupon; | ||||
| import com.iformall.domain.po.tt.TtUserCollect; | import com.iformall.domain.po.tt.TtUserCollect; | ||||
| @@ -135,7 +136,7 @@ public class TtCouponServiceImpl implements TtCouponService { | |||||
| // WxMerchant author = wxMerchantService.getById(byId.getMerchantId()); | // WxMerchant author = wxMerchantService.getById(byId.getMerchantId()); | ||||
| // byId.setMerchantName(author.getName()); | // byId.setMerchantName(author.getName()); | ||||
| // byId.setMerchantPic(author.getImgUrl()); | // byId.setMerchantPic(author.getImgUrl()); | ||||
| // byId.setAuthor(wxMerchantService.getById(byId.getMerchantId())); | |||||
| byId.setAuthor(wxMerchantService.getById(byId.getMerchantId())); | |||||
| if(byId.getType().equals(EnumTtCouponType.COUPON_COLUMN.getCode())){ | if(byId.getType().equals(EnumTtCouponType.COUPON_COLUMN.getCode())){ | ||||
| TtCoupon couponQ = new TtCoupon(); | TtCoupon couponQ = new TtCoupon(); | ||||
| couponQ.setColumnId(productId); | couponQ.setColumnId(productId); | ||||
| @@ -150,12 +150,11 @@ | |||||
| and `score` = #{score} | and `score` = #{score} | ||||
| </if> | </if> | ||||
| <if test=" null != updateDate "> | |||||
| and `update_date` = #{updateDate} | |||||
| <if test="startdate != null"> | |||||
| and `create_date` >= #{startdate} | |||||
| </if> | </if> | ||||
| <if test=" null != createDate "> | |||||
| and `create_date` = #{createDate} | |||||
| <if test="enddate != null"> | |||||
| and `create_date` <= #{enddate} | |||||
| </if> | </if> | ||||
| <if test=" null != appId "> | <if test=" null != appId "> | ||||
| @@ -166,10 +165,6 @@ | |||||
| and `token` like concat('%', #{token},'%') | and `token` like concat('%', #{token},'%') | ||||
| </if> | </if> | ||||
| <if test=" null != expireTime "> | |||||
| and `expire_time` = #{expireTime} | |||||
| </if> | |||||
| <if test=" null != latitude "> | <if test=" null != latitude "> | ||||
| and `latitude` = #{latitude} | and `latitude` = #{latitude} | ||||
| </if> | </if> | ||||
| @@ -108,19 +108,19 @@ | |||||
| order by o.`update_date` desc | order by o.`update_date` desc | ||||
| </sql> | </sql> | ||||
| <select id="findList" parameterType="com.iformall.domain.po.WxOrder" resultMap="BaseResultMap"> | |||||
| <select id="findList" parameterType="com.iformall.domain.po.tt.TtOrder" resultMap="BaseResultMap"> | |||||
| select | select | ||||
| <include refid="allColumns"/> | <include refid="allColumns"/> | ||||
| from wx_order o | |||||
| from tt_order o | |||||
| left join tt_c_user u on o.c_user_id = u.id | left join tt_c_user u on o.c_user_id = u.id | ||||
| left join tt_coupon c on o.product_id = c.id | left join tt_coupon c on o.product_id = c.id | ||||
| left join wx_merchant m on c.merchant_id = m.id | left join wx_merchant m on c.merchant_id = m.id | ||||
| <include refid="dynamicWhereConditions"/> | <include refid="dynamicWhereConditions"/> | ||||
| </select> | </select> | ||||
| <select id="findListCount" parameterType="com.iformall.domain.po.WxOrder" resultType="Integer"> | |||||
| <select id="findListCount" parameterType="com.iformall.domain.po.tt.TtOrder" resultType="Integer"> | |||||
| select count(1) | select count(1) | ||||
| from wx_order | |||||
| from tt_order | |||||
| where 1 = 1 | where 1 = 1 | ||||
| <if test=" null != tenantId and '' != tenantId"> | <if test=" null != tenantId and '' != tenantId"> | ||||
| and `tenant_id` = #{tenantId} | and `tenant_id` = #{tenantId} | ||||
| @@ -0,0 +1,90 @@ | |||||
| <?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.iformall.mapper.TtUpSettleinMapper"> | |||||
| <resultMap id="BaseResultMap" type="com.iformall.domain.po.tt.TtUpSettlein"> | |||||
| <id column="id" jdbcType="BIGINT" property="id"/> | |||||
| <result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/> | |||||
| <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId"/> | |||||
| <result column="cuser_id" jdbcType="BIGINT" property="cuserId"/> | |||||
| <result column="invitation_code" jdbcType="VARCHAR" property="invitationCode"/> | |||||
| <result column="liaison_man" jdbcType="VARCHAR" property="liaisonMan"/> | |||||
| <result column="liaison_phone" jdbcType="VARCHAR" property="liaisonPhone"/> | |||||
| <result column="tt_user_name" jdbcType="VARCHAR" property="ttUserName"/> | |||||
| <result column="tt_count_fans" jdbcType="VARCHAR" property="ttCountFans"/> | |||||
| <result column="bussiness_types" jdbcType="VARCHAR" property="bussinessTypes"/> | |||||
| <result column="explain" jdbcType="VARCHAR" property="explain"/> | |||||
| <result column="remark" jdbcType="VARCHAR" property="remark"/> | |||||
| <result column="handle_status" jdbcType="INTEGER" property="handleStatus"/> | |||||
| <result column="create_date" jdbcType="TIMESTAMP" property="createDate"/> | |||||
| <result column="update_date" jdbcType="TIMESTAMP" property="updateDate"/> | |||||
| </resultMap> | |||||
| <sql id="allColumns"> | |||||
| `id`,`tenant_id`,`parent_tenant_id`,`cuser_id`,`invitation_code`,`liaison_man`,`liaison_phone`, | |||||
| `tt_user_name`,`tt_count_fans`,`bussiness_types`,`explain`, | |||||
| `remark`,`handle_status`,`create_date`,`update_date` | |||||
| </sql> | |||||
| <sql id="dynamicWhereConditions"> | |||||
| where `is_del` = 0 | |||||
| <if test=" null != id "> | |||||
| and `id` = #{id} | |||||
| </if> | |||||
| <if test=" null != tenantId and '' != tenantId"> | |||||
| and `tenant_id` = #{tenantId} | |||||
| </if> | |||||
| <if test=" null != parentTenantId and '' != parentTenantId"> | |||||
| and `parent_tenant_id` = #{parentTenantId} | |||||
| </if> | |||||
| <if test=" null != cuserId "> | |||||
| and `cuser_id` = #{cuserId} | |||||
| </if> | |||||
| <if test=" null != invitationCode and '' != invitationCode"> | |||||
| and `invitation_code` = #{invitationCode} | |||||
| </if> | |||||
| <if test=" null != liaisonMan "> | |||||
| and `liaison_man` like concat('%', #{liaisonMan},'%') | |||||
| </if> | |||||
| <if test=" null != liaisonPhone "> | |||||
| and `liaison_phone` like concat('%', #{liaisonPhone},'%') | |||||
| </if> | |||||
| <if test=" null != ttUserName "> | |||||
| and `tt_user_name` like concat('%', #{ttUserName},'%') | |||||
| </if> | |||||
| <if test=" null != handleStatus "> | |||||
| and `handle_status` = #{handleStatus} | |||||
| </if> | |||||
| <if test="startdate != null"> | |||||
| and `create_date` >= #{startdate} | |||||
| </if> | |||||
| <if test="enddate != null"> | |||||
| and `create_date` <= #{enddate} | |||||
| </if> | |||||
| <if test=" null != ids "> | |||||
| and `id` in | |||||
| <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")"> | |||||
| #{idItem} | |||||
| </foreach> | |||||
| </if> | |||||
| <if test=" null != sortColumns">order by ${sortColumns}</if> | |||||
| </sql> | |||||
| <select id="findList" parameterType="com.iformall.domain.po.tt.TtUpSettlein" resultMap="BaseResultMap"> | |||||
| select | |||||
| <include refid="allColumns"/> | |||||
| from tt_up_settlein | |||||
| <include refid="dynamicWhereConditions"/> | |||||
| </select> | |||||
| </mapper> | |||||