package com.sy.entity; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; import java.util.Date; @TableName(value = "category") @Data @AllArgsConstructor @NoArgsConstructor public class Category { @TableId(value = "sn", type = IdType.AUTO) private Integer sn; @TableField(value = "id") private String id; @TableField(value = "name") private String name; @TableField(value = "shop_id") private String shopId; @TableField(value = "orders") private Integer orders; @TableField(value = "status") private Integer status; @TableField(value = "create_at") private Date createAt; @TableField(value = "update_at") private Date updateAt; @TableField(value = "start_date") private String startDate; @TableField(value = "end_date") private String endDate; @TableField(value = "start_time") private String startTime; @TableField(value = "end_time") private String endTime; @TableField(value = "holiday") private Integer holiday; @TableField(value = "week_day") private String weekDay; @TableField(value = "is_datetime") private Integer isDatetime; public Category getSort(String shopId,Integer sn) { Category category = new Category(); category.setSn(sn); category.setId("0001"); category.setName("青港商品"); category.setShopId(shopId); category.setOrders(1); category.setStatus(1); category.setCreateAt(new Date()); category.setUpdateAt(new Date()); category.setHoliday(0); category.setIsDatetime(1); return category; } }