package cn.com.ty.lift.ud.dataBank.mapper.entity;

import java.util.List;

import com.baomidou.mybatisplus.annotation.TableName;

import cn.com.ty.lift.ud.common.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
 * 资料分类 
 * 
 * @author Xson
 * @date 2020-04-23
 */
@Data
@ApiModel(description="资料分类 ")
@TableName(value= "lift_category")
public class LiftCategoryEntity extends BaseEntity {


        /**
         * 父id
         */
        @ApiModelProperty("父id")
        private Long pid;

        /**
         * 分类名
         */
        @ApiModelProperty("分类名")
        private String name;

        /**
         * 品牌
         */
        @ApiModelProperty("品牌")
        private Long brandId;
        
        /**
         * 图标
         */
        @ApiModelProperty("图标")
        private String icon;

        /**
         * 描述
         */
        @ApiModelProperty("描述")
        private String descr;

        /**
         * 状态 0:上架1:下架
         */
        @ApiModelProperty("状态 0:上架1:下架")
        private Integer statuz;

        /**
         * 排序
         */
        @ApiModelProperty("排序")
        private String sort;

        private transient String pidName;
        
        private transient String brandName;
        
        private transient List<LiftCategoryEntity> chilList;

        public static LiftCategoryEntity getStraight(Long brandId,String name,String sort){
                LiftCategoryEntity entity = new LiftCategoryEntity();
                entity.setBrandId(brandId);
                entity.setName(name);
                entity.setStatuz(0);
                entity.setPid(0L);
                entity.setSort(sort);

                return entity;
        }
}
