package com.qs.mp.channel.domain;

import com.alibaba.fastjson.annotation.JSONField;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.qs.mp.common.enums.ChannelCertifyStatusEnum;
import com.qs.mp.common.enums.ChannelStatusEnum;
import com.qs.mp.common.enums.ChannelVerifyStatusEnum;
import com.qs.mp.common.enums.SiteTypeEnum;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @describe 渠道经销商实体类
 * @auther quanshu
 * @create 2022-03-02 12:22:24
 */
@TableName("mp_channel")
@Data
@ApiModel("渠道经销商实体类")
public class Channel implements Serializable {

  private static final long serialVersionUID = 1L;

  /**
   * 主键
   */
  @TableId(value = "channel_id" , type = IdType.AUTO)
  @ApiModelProperty("渠道经销商id")
  private Long channelId;

  /**
   * 渠道编码
   */
  @TableField("channel_no")
  @ApiModelProperty("渠道编码")
  private String channelNo;

  /**
   * 渠道名称
   */
  @TableField("name")
  @ApiModelProperty("渠道名称")
  private String name;

  /**
   * 父渠道ID
   */
  @TableField("parent_id")
  @ApiModelProperty("父渠道ID")
  private Long parentId;

  /**
   * 渠道级别，0:经销商；1:一级渠道；2:二级渠道
   */
  @TableField("level")
  @ApiModelProperty("渠道级别，0:经销商；1:一级渠道；2:二级渠道")
  private Integer level;

  /**
   * 经销商类型
   */
  @TableField("site_type")
  @JSONField(serialzeFeatures = SerializerFeature.WriteEnumUsingToString)
  @ApiModelProperty("经销商类型")
  private SiteTypeEnum siteType;
  
  
  /**
   * 门店名称(用于用户端优惠券的详情页，说明优惠券的适用门店)
   */
  @TableField("site_name")
  @ApiModelProperty("门店名称(用于用户端优惠券的详情页，说明优惠券的适用门店)")
  private String siteName;

  /**
   * 分佣百分比
   */
  @TableField("comm_rate")
  @ApiModelProperty("分佣百分比")
  private BigDecimal commRate;

  /**
   * 省ID
   */
  @TableField("province_id")
  @ApiModelProperty("省ID")
  private Long provinceId;

  /**
   * 省
   */
  @TableField("province")
  @ApiModelProperty("省")
  private String province;

  /**
   * 城市
   */
  @TableField("city")
  @ApiModelProperty("城市")
  private String city;

  /**
   * 城市ID
   */
  @TableField("city_id")
  @ApiModelProperty("城市ID")
  private Long cityId;

  /**
   * 区
   */
  @TableField("area")
  @ApiModelProperty("区")
  private String area;

  /**
   * 区ID
   */
  @TableField("area_id")
  @ApiModelProperty("区ID")
  private Long areaId;

  /**
   * 详细地址
   */
  @TableField("address")
  @ApiModelProperty("详细地址")
  private String address;

  /**
   * 联系人
   */
  @TableField("contact")
  @ApiModelProperty("联系人")
  private String contact;

  /**
   * 手机号
   */
  @TableField("mobile")
  @ApiModelProperty("手机号")
  private String mobile;

  /**
   * 用户ID
   */
  @TableField("user_id")
  @ApiModelProperty("用户ID")
  private Long userId;

  /**
   * 账户余额
   */
  @TableField("money")
  @ApiModelProperty("账户余额")
  private Integer money;

  /**
   * 账户冻结金额
   */
  @TableField("frozen_money")
  @ApiModelProperty("账户冻结金额")
  private Integer frozenMoney;

  /**
   * 认证状态，未认证n，已认证y
   */
  @TableField("certify_status")
  @JSONField(serialzeFeatures = SerializerFeature.WriteEnumUsingToString)
  @ApiModelProperty("认证状态，未认证n，已认证y")
  private ChannelCertifyStatusEnum certifyStatus;

  /**
   * 审核状态
   */
  @TableField("verify_status")
  @JSONField(serialzeFeatures = SerializerFeature.WriteEnumUsingToString)
  @ApiModelProperty("审核状态")
  private ChannelVerifyStatusEnum verifyStatus;

  /**
   * 营业执照
   */
  @TableField("biz_license_pic")
  @ApiModelProperty("营业执照")
  private String bizLicensePic;

  /**
   * 门头照片
   */
  @TableField("door_pic")
  @ApiModelProperty("门头照片")
  private String doorPic;

  /**
   * 备注信息
   */
  @TableField("memo")
  @ApiModelProperty("备注信息")
  private String memo;

  /**
   * 邀请码图片
   */
  @TableField("invite_pic")
  @ApiModelProperty("邀请码图片")
  private String invitePic;

  /**
   * 状态，启用、停用
   */
  @TableField("status")
  @JSONField(serialzeFeatures = SerializerFeature.WriteEnumUsingToString)
  @ApiModelProperty("状态,启用.停用")
  private ChannelStatusEnum status;

  /**
   * 创建时间
   */
  @TableField("created_time")
  @ApiModelProperty("创建时间")
  private Date createdTime;

  /**
   * 更新时间
   */
  @TableField("updated_time")
  @ApiModelProperty("更新时间")
  private Date updatedTime;


}
