package com.cyksj.model.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.ejlchina.searcher.bean.DbField;
import com.ejlchina.searcher.bean.SearchBean;
import lombok.Getter;
import lombok.Setter;

import java.util.Date;

/**
 * 项目名: yhlxj
 * 文件名: UserDistributeSub
 * 创建者: JavaZou
 * 创建时间:2024/3/28 17:36
 */
@Getter
@Setter
@SearchBean(tables = "user_distribute_sub us inner join user u on u.id = us.user_id")
public class UserDistributeSub{
	@TableId(value = "id",type = IdType.AUTO)
	@DbField("us.id")
	private Long id;

	@DbField("us.distribute_id")
	private Long distributeId;

	@DbField("us.user_id")
	private Long userId;

	@DbField("u.nickname")
	@TableField(exist = false)
	private String nickname;

	/**
	 *下级渠道用户id
	 */
	@DbField("us.sub_distribute_id")
	private Long subDistributeId;


	/**
	 *下级渠道用户id
	 */
	@DbField("us.sub_user_id")
	private Long subUserId;

	/**
	 * 创建时间
	 */
	@TableField(fill = FieldFill.INSERT)
	@DbField("us.created_time")
	private Date createdTime;

	/**
	 * 修改时间
	 */
	@TableField(fill = FieldFill.INSERT_UPDATE)
	@DbField("us.update_time")
	private Date updateTime;
}
