package com.yonge.cooleshow.biz.dal.queryInfo;

import com.alibaba.fastjson.JSON;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

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

/**
 * Created by Eric.Shang on 2022/10/9.
 */
public class TeacherQueryInfo {

    /**
     * 老师粉丝数查询条件
     */
    @Data
    @Builder
    @NoArgsConstructor
    @AllArgsConstructor
    public static class FansQuery implements Serializable {

        private Long teacherId;
        private Date startTime;
        private Date endTime;
        // 昵称
        private String nickname;
        // 编号/手机号
        private Long userId;
        private String phone;

        public static FansQuery from(String recv) {

            return JSON.parseObject(recv, FansQuery.class);
        }
    }
}
