
package com.tmerclub.cloud.user.dto;

import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 全部会员，请求参数
 *
 * @author cl
 * @data 2020-04-09 16:16:50
 */
@Data
@ToString
public class UserManagerDTO implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;
    @Schema(description = "用户id")
    private Long userId;

    @Schema(description = "用户昵称")
    private String nickName;

    @Schema(description = "真实姓名")
    private String realName;

    @Schema(description = "手机号码")
    private String phone;

    @Schema(description = "性别 null 不限，M男，F女")
    private String sex;

    @Schema(description = "状态 1 正常 0 无效")
    private Integer status;

    @Schema(description = "客户注册时间-条件开始时间")
    private Date userRegStartTime;
    @Schema(description = "客户注册时间-条件结束时间")
    private Date userRegEndTime;

    @Schema(description = "客户渠道 null 不限，公众号，小程序，H5，自有App")
    private Integer appType;

    @Schema(description = "客户身份 0普通会员，1付费会员")
    private Integer levelType;
    @Schema(description = "会员等级")
    private Integer level;

    // ------交易信息----------------------------------

    @Schema(description = "最近消费时间-开始时间")
    private Date reConsStartTime;
    @Schema(description = "最近消费时间-结算时间")
    private Date reconsEndTime;


    @Schema(description = "消费金额")
    private Double preConsAmount;
    @Schema(description = "消费金额")
    private Double apConsAmount;

    @Schema(description = "消费次数")
    private Integer preConsTimes;
    @Schema(description = "消费次数")
    private Integer apConsTimes;

    @Schema(description = "订单均价")
    private Double preOrderAverAmount;
    @Schema(description = "订单均价")
    private Double apOrderAverAmount;

    @Schema(description = "平均折扣")
    private Double preAverDiscount;
    @Schema(description = "平均折扣")
    private Double apAverDiscount;

    @Schema(description = "当前余额")
    private Double preCurrentBalance;

    @Schema(description = "用户ids")
    private List<Long> userIds;

    @Schema(description = "当前余额")
    private Double apCurrentBalance;


    @Schema(description = "当前积分")
    private Integer preCurrentScore;
    @Schema(description = "当前积分")
    private Integer apCurrentScore;


    @Schema(description = "充值金额")
    private Double preRechargeAmount;
    @Schema(description = "充值金额")
    private Double apRechargeAmount;

    @Schema(description = "充值次数")
    private Integer preRechargeTimes;
    @Schema(description = "充值次数")
    private Integer apRechargeTimes;

    @Schema(description = "客户标签")
    private List<Long> tagIds;

    @Schema(description = "排序字段的名称")
    private String fieldName;

    @Schema(description = "排序规则:一次只能安照一个字段排序; 升序：ascending 降序：descending 不排序: null ")
    private String sortingType;

    @Schema(description = "注册时间筛选-注册开始时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createStartTime;

    @Schema(description = "注册时间筛选-注册结束时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createEndTime;

    @Schema(description = "店铺id")
    private Long shopId;

    @Hidden
    @Schema(description = "支付系统类型")
    private Integer paySysType;

}
