PushClientInfo.java 1.01 KB
package com.brframework.commonapppush.entity;

import com.alibaba.fastjson.annotation.JSONField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.persistence.*;
import java.time.LocalDateTime;

/**
 * 客户端信息
 *
 * @author xu
 * @date 2019/11/18 18:21
 */
@Data
@Entity
@Table(name = "pus_client_info")
@ApiModel
public class PushClientInfo {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @ApiModelProperty(value = "id", required = true, example = "1")
    Long id;

    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间", required = true, example = "2019-04-24 16:23:19")
    @Column(updatable = false, nullable = false)
    LocalDateTime createDate;

    @ApiModelProperty(value = "客户端标识")
    @Column(unique = true, nullable = false)
    String deviceTokens;

    @ApiModelProperty(value = "系统用户标识")
    @Column(unique = true, nullable = false)
    String userTokens;
}