package com.bonus.canteen.core.cook.domain;

import java.math.BigDecimal;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

import com.bonus.canteen.core.common.utils.FileUrlUtil;
import com.bonus.common.core.annotation.Excel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import com.bonus.common.core.web.domain.BaseEntity;

/**
 * 菜品信息对象 cook_dishes
 * 
 * @author xsheng
 * @date 2025-05-25
 */


@EqualsAndHashCode(callSuper = true)
@Data
@ToString
public class CookDishes extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 菜品id */
    private Long dishesId;

    /** 类型(1-菜品,2-套餐) */
    @Excel(name = "类型(1-菜品,2-套餐)")
    @ApiModelProperty(value = "类型(1-菜品,2-套餐)")
    private Long mealType;

    /** 自定义id */
    @Excel(name = "自定义id")
    @ApiModelProperty(value = "自定义id")
    private Long customId;

    /** 存货id(数据同步) */
    @Excel(name = "存货id(数据同步)")
    @ApiModelProperty(value = "存货id(数据同步)")
    private String inventoryId;

    /** 菜品名称 */
    @Excel(name = "菜品名称")
    @ApiModelProperty(value = "菜品名称")
    private String dishesName;

    /** 菜品别称 */
    @Excel(name = "菜品别称")
    @ApiModelProperty(value = "菜品别称")
    private String aliasName;

    /** 条形码 */
    @Excel(name = "条形码")
    @ApiModelProperty(value = "条形码")
    private String barCode;

    /** 菜品简介 */
    @Excel(name = "菜品简介")
    @ApiModelProperty(value = "菜品简介")
    private String intro;

    /** 菜品灶类ID */
    @Excel(name = "菜品灶类ID")
    @ApiModelProperty(value = "菜品灶类ID")
    private Long cookId;

    /** 菜品类型ID */
    @Excel(name = "菜品类型ID")
    @ApiModelProperty(value = "菜品类型ID")
    private Long typeId;

    /** 菜品分类id(自定义) */
    @Excel(name = "菜品分类id(自定义)")
    @ApiModelProperty(value = "菜品分类id(自定义)")
    private Long classifyId;

    /** 菜品功效id（强筋健骨） */
    @Excel(name = "菜品功效id", readConverterExp = "强=筋健骨")
    private Long effectId;

    /** 菜系id(鲁系主食，沪系主食) */
    @Excel(name = "菜系id(鲁系主食，沪系主食)")
    @ApiModelProperty(value = "菜系id(鲁系主食，沪系主食)")
    private Long styleId;

    /** 是否本地特色(1是2否) */
    @Excel(name = "是否本地特色(1是2否)")
    @ApiModelProperty(value = "是否本地特色(1是2否)")
    private Long ifLocalFeature;

    /** 菜别(1小荤,2大荤,3素) */
    @Excel(name = "菜别(1小荤,2大荤,3素)")
    @ApiModelProperty(value = "菜别(1小荤,2大荤,3素)")
    private Long dishesDepart;

    /** 次序(1餐前,2餐后) */
    @Excel(name = "次序(1餐前,2餐后)")
    @ApiModelProperty(value = "次序(1餐前,2餐后)")
    private Long sequence;

    /** 辣度 */
    @Excel(name = "辣度")
    @ApiModelProperty(value = "辣度")
    private Long pungencyDegree;

    /** 销售方式(1按份,2称重) */
    @Excel(name = "销售方式(1按份,2称重)")
    @ApiModelProperty(value = "销售方式(1按份,2称重)")
    private Long salesMode;

    /** 规格类型(1-标准,2-大小份) */
    @Excel(name = "规格类型(1-标准,2-大小份)")
    @ApiModelProperty(value = "规格类型(1-标准,2-大小份)")
    private Long sizeType;

    /** 菜品规格 */
    @Excel(name = "菜品规格")
    @ApiModelProperty(value = "菜品规格")
    private String sizeJson;

    /** 每份重量(g) */
    @Excel(name = "每份重量(g)")
    @ApiModelProperty(value = "每份重量(g)")
    private BigDecimal weight;

    /** 大份份量 */
    @Excel(name = "大份份量")
    @ApiModelProperty(value = "大份份量")
    private BigDecimal largeWeight;

    /** 小份份量 */
    @Excel(name = "小份份量")
    @ApiModelProperty(value = "小份份量")
    private BigDecimal littleWeight;

    /** 质量偏差(g) */
    @Excel(name = "质量偏差(g)")
    @ApiModelProperty(value = "质量偏差(g)")
    private BigDecimal weightDeviation;

    /** 菜品基础单价(分) */
    @Excel(name = "菜品基础单价(分)")
    @ApiModelProperty(value = "菜品基础单价(分)")
    private Long price;

    /** 称重单位多少克(默认100g) */
    @Excel(name = "称重单位多少克(默认100g)")
    @ApiModelProperty(value = "称重单位多少克(默认100g)")
    private Long unitPrice;

    /** 大份单价 */
    @Excel(name = "大份单价")
    @ApiModelProperty(value = "大份单价")
    private Long largePrice;

    /** 小份单价 */
    @Excel(name = "小份单价")
    @ApiModelProperty(value = "小份单价")
    private Long littlePrice;

    /** 菜品图片url */
    @Excel(name = "菜品图片url")
    @ApiModelProperty(value = "菜品图片url")
    private String imageUrl;

    /** 菜品详情 */
    @Excel(name = "菜品详情")
    @ApiModelProperty(value = "菜品详情")
    private String particulars;

    /** 菜品推荐 */
    @Excel(name = "菜品推荐")
    @ApiModelProperty(value = "菜品推荐")
    private String recommend;

    /** 是否首页推荐(1-是,2-否) */
    @Excel(name = "是否首页推荐(1-是,2-否)")
    @ApiModelProperty(value = "是否首页推荐(1-是,2-否)")
    private Long indexRecommend;

    /** 点赞调查标识(1-是,2-否) */
    @Excel(name = "点赞调查标识(1-是,2-否)")
    @ApiModelProperty(value = "点赞调查标识(1-是,2-否)")
    private Long likeSurvey;

    /** 点赞调查批次号 */
    @Excel(name = "点赞调查批次号")
    @ApiModelProperty(value = "点赞调查批次号")
    private Long likeBatch;

    /** 点赞数 */
    @Excel(name = "点赞数")
    @ApiModelProperty(value = "点赞数")
    private Long likeNum;

    /** 菜品初始推荐值 */
    @Excel(name = "菜品初始推荐值")
    @ApiModelProperty(value = "菜品初始推荐值")
    private Long initialScore;

    /** 热量(千卡/份) */
    @Excel(name = "热量(千卡/份)")
    @ApiModelProperty(value = "热量(千卡/份)")
    private BigDecimal calories;

    /** 蛋白质(g/份) */
    @Excel(name = "蛋白质(g/份)")
    @ApiModelProperty(value = "蛋白质(g/份)")
    private BigDecimal protein;

    /** 脂肪(g/份) */
    @Excel(name = "脂肪(g/份)")
    @ApiModelProperty(value = "脂肪(g/份)")
    private BigDecimal fat;

    /** 碳水化合物(g/份) */
    @Excel(name = "碳水化合物(g/份)")
    @ApiModelProperty(value = "碳水化合物(g/份)")
    private BigDecimal carbohydrate;

    /** 膳食纤维(g/份) */
    @Excel(name = "膳食纤维(g/份)")
    @ApiModelProperty(value = "膳食纤维(g/份)")
    private BigDecimal dietaryFiber;

    /** 胆固醇(mg/份) */
    @Excel(name = "胆固醇(mg/份)")
    @ApiModelProperty(value = "胆固醇(mg/份)")
    private BigDecimal cholesterol;

    /** 钙(mg/份) */
    @Excel(name = "钙(mg/份)")
    @ApiModelProperty(value = "钙(mg/份)")
    private BigDecimal calcium;

    /** 钠(mg/份) */
    @Excel(name = "钠(mg/份)")
    @ApiModelProperty(value = "钠(mg/份)")
    private BigDecimal sodium;

    /** 总嘌呤含量(mg/100g) */
    @Excel(name = "总嘌呤含量(mg/100g)")
    @ApiModelProperty(value = "总嘌呤含量(mg/100g)")
    private BigDecimal purine;

    /** 铁(mg/100g) */
    @Excel(name = "铁(mg/100g)")
    @ApiModelProperty(value = "铁(mg/100g)")
    private BigDecimal iron;

    /** 碘(μg/100g) */
    @Excel(name = "碘(μg/100g)")
    @ApiModelProperty(value = "碘(μg/100g)")
    private BigDecimal iodine;

    /** 钾(mg/100g) */
    @Excel(name = "钾(mg/100g)")
    @ApiModelProperty(value = "钾(mg/100g)")
    private BigDecimal kalium;

    /** 维生素a(μg/100g) */
    @Excel(name = "维生素a(μg/100g)")
    @ApiModelProperty(value = "维生素a(μg/100g)")
    private BigDecimal vitaminA;

    /** 维生素c(mg/100g) */
    @Excel(name = "维生素c(mg/100g)")
    @ApiModelProperty(value = "维生素c(mg/100g)")
    private BigDecimal vitaminC;

    /** 维生素e(g/100g) */
    @Excel(name = "维生素e(g/100g)")
    @ApiModelProperty(value = "维生素e(g/100g)")
    private BigDecimal vitaminE;

    /** 镁(mg/100g) */
    @Excel(name = "镁(mg/100g)")
    @ApiModelProperty(value = "镁(mg/100g)")
    private BigDecimal magnesium;

    /** 锌(mg/100g) */
    @Excel(name = "锌(mg/100g)")
    @ApiModelProperty(value = "锌(mg/100g)")
    private BigDecimal zinc;

    /** 血糖生成指数(GI) */
    @Excel(name = "血糖生成指数(GI)")
    @ApiModelProperty(value = "血糖生成指数(GI)")
    private BigDecimal glycemicIndex;

    /** 优先级 */
    @Excel(name = "优先级")
    @ApiModelProperty(value = "优先级")
    private Long sort;

    /** 食堂ID */
    @Excel(name = "食堂ID")
    @ApiModelProperty(value = "食堂ID")
    private Long canteenId;

    /** 档口或店铺id */
    @Excel(name = "档口或店铺id")
    @ApiModelProperty(value = "档口或店铺id")
    private Long stallId;

    /** 隐藏标识(1隐藏,2展示) */
    @Excel(name = "隐藏标识(1隐藏,2展示)")
    @ApiModelProperty(value = "隐藏标识(1隐藏,2展示)")
    private Long hideFlag;

    /** 结果图转注册图 */
    @Excel(name = "结果图转注册图")
    @ApiModelProperty(value = "结果图转注册图")
    private Long convertFlag;

    /** 成本价 */
    @Excel(name = "成本价")
    @ApiModelProperty(value = "成本价")
    private Long materialCost;

    /** 毛利 */
    @Excel(name = "毛利")
    @ApiModelProperty(value = "毛利")
    private Long grossProfit;

    /** 毛利率 */
    @Excel(name = "毛利率")
    @ApiModelProperty(value = "毛利率")
    private BigDecimal grossProfitRate;

    /** 是否是公共菜品(1-是,2-否) */
    @Excel(name = "是否是公共菜品(1-是,2-否)")
    @ApiModelProperty(value = "是否是公共菜品(1-是,2-否)")
    private Long publicDishes;

    /** 区域id */
    @Excel(name = "区域id")
    @ApiModelProperty(value = "区域id")
    private Long areaId;

    /** 餐次id */
    @Excel(name = "餐次id")
    @ApiModelProperty(value = "餐次id")
    private String mealId;

    @ApiModelProperty(value = "菜品食材列表")
    private List<CookDishesMaterial> dishesMaterialList;

    @ApiModelProperty(value = "食堂名称")
    private String canteenName;

    @ApiModelProperty(value = "档口名称")
    private String stallName;

    @ApiModelProperty(value = "区域名称")
    private String areaName;

    @ApiModelProperty(value = "菜品类型名称")
    private String dishesTypeName;

    @ApiModelProperty(value = "菜品类型id集合")
    private List<Long> typeIds;

    private Set<String> dishesNames = new HashSet();

    public String getImageUrl() {
        return FileUrlUtil.getFileUrl(this.imageUrl);
    }
}
