package com.miekir.shibei.bean; import javax.persistence.*; /** * * * @author Miekir * @date 2020/7/5 21:50 * Description: 商品实体 */ @Entity @Table(name = "t_goods", schema = "shibei", catalog = "") public class GoodsBean { public static final int TYPE_RECOMMEND = 0; public static final int TYPE_TECHNOLOGY = 1; public static final int TYPE_LIFE = 2; public static final int TYPE_NETWORK = 3; @Id @GeneratedValue(strategy= GenerationType.AUTO) @Column(name = "id", nullable = false, insertable = true, updatable = false) public long id; /** * 封面图片地址 */ @Basic @Column(columnDefinition = "MEDIUMTEXT", name = "coverImageUrl", nullable = true, insertable = true, updatable = true) public String coverImageUrl; /** * 视频地址 */ @Basic @Column(columnDefinition = "MEDIUMTEXT", name = "videoUrl", nullable = true, insertable = true, updatable = true) public String videoUrl; /** * 标题 */ @Basic @Column(name = "title", nullable = true, insertable = true, updatable = true) public String title; /** * 商品描述 */ @Basic @Column(name = "description", nullable = true, insertable = true, updatable = true) public String description; /** * 商品推荐理由(一句话推荐、推荐者心声) */ @Basic @Column(name = "reason", nullable = true, insertable = true, updatable = true) public String reason; /** * 原价 */ @Basic @Column(name = "oldPrice", nullable = true, insertable = true, updatable = true) public long oldPrice; /** * 现价 */ @Basic @Column(name = "nowPrice", nullable = true, insertable = true, updatable = true) public long nowPrice; /** * 返利 */ @Basic @Column(name = "rebate", nullable = true, insertable = true, updatable = true) public long rebate; /** * 店名 */ @Basic @Column(name = "shopName", nullable = true, insertable = true, updatable = true) public String shopName; /** * 商店所属省份 */ @Basic @Column(name = "province", nullable = true, insertable = true, updatable = true) public String province; /** * 是否自营 */ @Basic @Column(name = "isSelfBusiness", nullable = true, insertable = true, updatable = true) public boolean isSelfBusiness; /** * 是否有券 */ @Basic @Column(name = "hasCoupon", nullable = true, insertable = true, updatable = true) public boolean hasCoupon; /** * 优惠券信息 */ @Basic @Column(name = "couponInfo", nullable = true, insertable = true, updatable = true) public String couponInfo; /** * 所属类型 */ @Basic @Column(name = "goodsType", nullable = true, insertable = true, updatable = true) public int goodsType; /** * 商品链接 */ @Basic @Column(columnDefinition = "MEDIUMTEXT", name = "goodsUrl", nullable = true, insertable = true, updatable = true) public String goodsUrl; /** * 月销量 */ @Basic @Column(name = "salesPerMonth", nullable = true, insertable = true, updatable = true) public long salesPerMonth; /** * 评论条数 */ @Basic @Column(name = "commentNum", nullable = true, insertable = true, updatable = true) public long commentNum; /** * 好评率 */ @Basic @Column(name = "goodCommentPercent", nullable = true, insertable = true, updatable = true) public double goodCommentPercent; /** * 创建时间 */ @Basic @Column(name = "createTimeMillis", nullable = true, insertable = true, updatable = true) public long createTimeMillis; /** * 更新时间 */ @Basic @Column(name = "updateTimeMillis", nullable = true, insertable = true, updatable = true) public long updateTimeMillis; @Basic @Column(name = "enable", nullable = true, insertable = true, updatable = true) public boolean enable; /**是否是本地写死的数据*/ @Basic @Column(name = "isLocal", nullable = true, insertable = true, updatable = true) public boolean isLocal; }