package com.yihu.jw.entity.care.device;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.iot.gateway.IdEntity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import java.util.Date;

/**
 * 设备列表
 */
@Entity
@Table(name = "dm_device")
@SequenceGenerator(name="id_generated", sequenceName="dm_device")
public class Device extends IdEntity {

	private String categoryCode;
	private String photo;
	private String brands;
	private String model;
	private String isMultiUser;
	private String multiUser;
	private String name;
	private Date czrq;
	private String del;
	private String serviceTopic;//设备所属专题 防走失 preventLost
	private String needRegister;//设备是否注册iot(脉搏波血压计)
	private Integer deviceType;//0健康设备 1安防设备

	@Column(name="category_code")
	public String getCategoryCode() {
		return categoryCode;
	}

	public void setCategoryCode(String categoryCode) {
		this.categoryCode = categoryCode;
	}

	@Column(name="photo")
	public String getPhoto() {
		return photo;
	}

	public void setPhoto(String photo) {
		this.photo = photo;
	}

	@Column(name="brands")
	public String getBrands() {
		return brands;
	}

	public void setBrands(String brands) {
		this.brands = brands;
	}

	@Column(name="model")
	public String getModel() {
		return model;
	}

	public void setModel(String model) {
		this.model = model;
	}

	@Column(name="is_multi_user")
	public String getIsMultiUser() {
		return isMultiUser;
	}

	public void setIsMultiUser(String isMultiUser) {
		this.isMultiUser = isMultiUser;
	}

	@Column(name="multi_user")
	public String getMultiUser() {
		return multiUser;
	}

	public void setMultiUser(String multiUser) {
		this.multiUser = multiUser;
	}

	@Column(name="name")
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+08:00")
	@Column(name="czrq")
	public Date getCzrq() {
		return czrq;
	}

	public void setCzrq(Date czrq) {
		this.czrq = czrq;
	}

	@Column(name="del")
	public String getDel() {
		return del;
	}

	public void setDel(String del) {
		this.del = del;
	}

	public String getServiceTopic() {
		return serviceTopic;
	}

	public void setServiceTopic(String serviceTopic) {
		this.serviceTopic = serviceTopic;
	}

	public String getNeedRegister() {
		return needRegister;
	}

	public void setNeedRegister(String needRegister) {
		this.needRegister = needRegister;
	}

	public Integer getDeviceType() {
		return deviceType;
	}

	public void setDeviceType(Integer deviceType) {
		this.deviceType = deviceType;
	}
}
