package cn.cecep.talroad.vo.query;

import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import cn.cecep.talroad.domain.BStatTableZxbgHdFuelAnalysis;
import cn.cecep.talroad.common.core.domain.query.PageQuery;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;


/**
 * 固定源产排治--执行报告--火电燃料分析对象 b_stat_table_zxbg_hd_fuel_analysis
 *
 * @author szhpt
 * @date 2023-08-01*/
@ApiModel(value = "固定源产排治--执行报告--火电燃料分析")
@EqualsAndHashCode(callSuper = false)
@Data
public class BStatTableZxbgHdFuelAnalysisQuery extends PageQuery
{

    @ApiModelProperty(value = "主键id")
    private Long id;
    @ApiModelProperty(value = "企业id")
    private String factoryId;
    @ApiModelProperty(value = "执行报告类型，0：月报，1：季报，2：年报")
    private String zxbgType;
    @ApiModelProperty(value = "执行报告周期")
    private String zxbgPeriod;
    @ApiModelProperty(value = "生产单元")
    private String productionUnit;
    @ApiModelProperty(value = "燃料名称")
    private String fuelName;
    @ApiModelProperty(value = "使用量（万t/a、万m³/a）")
    private String usage;
    @ApiModelProperty(value = "灰分（%）")
    private String ashContent;
    @ApiModelProperty(value = "硫分（%）")
    private String sulfur;
    @ApiModelProperty(value = "挥发分（%）")
    private String volatileContent;
    @ApiModelProperty(value = "热值（MJ/kg、MJ/m³）")
    private String caloricValue;
    @ApiModelProperty(value = "备注")
    private String remark;
    @ApiModelProperty(value = "创建时间")
    private String createTime;
    /**
     *
     * @Title: getQueryWrapper
     * @Description: 查询参数组装
     * @param: @return
     * @return: QueryWrapper<BasIndustry>
     * @throws
     */
    public static QueryWrapper<BStatTableZxbgHdFuelAnalysis> createLambdaQueryWrapper(BStatTableZxbgHdFuelAnalysisQuery query) {
        QueryWrapper<BStatTableZxbgHdFuelAnalysis> wrapper = new QueryWrapper<>();
        wrapper.eq(ObjectUtil.isNotNull(query.getId()), "id", query.getId());
        wrapper.eq(ObjectUtil.isNotNull(query.getFactoryId()), "factory_id", query.getFactoryId());
        wrapper.eq(ObjectUtil.isNotNull(query.getZxbgType()), "zxbg_type", query.getZxbgType());
        wrapper.eq(ObjectUtil.isNotNull(query.getZxbgPeriod()), "zxbg_period", query.getZxbgPeriod());
        wrapper.eq(ObjectUtil.isNotNull(query.getProductionUnit()), "production_unit", query.getProductionUnit());
        wrapper.eq(ObjectUtil.isNotNull(query.getFuelName()), "fuel_name", query.getFuelName());
        wrapper.eq(ObjectUtil.isNotNull(query.getUsage()), "usage", query.getUsage());
        wrapper.eq(ObjectUtil.isNotNull(query.getAshContent()), "ash_content", query.getAshContent());
        wrapper.eq(ObjectUtil.isNotNull(query.getSulfur()), "sulfur", query.getSulfur());
        wrapper.eq(ObjectUtil.isNotNull(query.getVolatileContent()), "volatile_content", query.getVolatileContent());
        wrapper.eq(ObjectUtil.isNotNull(query.getCaloricValue()), "caloric_value", query.getCaloricValue());
        wrapper.eq(ObjectUtil.isNotNull(query.getRemark()), "remark", query.getRemark());
        wrapper.eq(ObjectUtil.isNotNull(query.getCreateTime()), "create_time", query.getCreateTime());
        return wrapper;
        }
}
