package cn.cecep.talroad.vo.query;

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


/**
 * 排污许可水污染物特殊情况对象 b_main_poll_dis_water_sout
 *
 * @author szhpt
 * @date 2023-01-18*/
@ApiModel(value = "排污许可水污染物特殊情况")
@EqualsAndHashCode(callSuper = false)
@Data
public class BMainPollDisWaterSoutQuery extends PageQuery
{

    @ApiModelProperty(value = "主键id")
    private Long soutId;
    @ApiModelProperty(value = "企业id")
    private String factoryId;
    @ApiModelProperty(value = "排污许可表id")
    private String pollDisId;
    @ApiModelProperty(value = "污染物种类")
    private String pollutantType;
    @ApiModelProperty(value = "排放口编号")
    private String outletCode;
    @ApiModelProperty(value = "排放口名称")
    private String outletName;
    @ApiModelProperty(value = "污染物种类")
    private String pollutantsType;
    @ApiModelProperty(value = "许可排放时段")
    private String pollutantsTimeFrame;
    @ApiModelProperty(value = "许可排放浓度限值")
    private String pollutantsConcentration;
    @ApiModelProperty(value = "许可日排放量限值")
    private String pollutantsDis;
    @ApiModelProperty(value = "其他信息")
    private String otherDetail;
    /**
     *
     * @Title: getQueryWrapper
     * @Description: 查询参数组装
     * @param: @return
     * @return: QueryWrapper<BasIndustry>
     * @throws
     */
    public static QueryWrapper<BMainPollDisWaterSout> createLambdaQueryWrapper(BMainPollDisWaterSoutQuery query) {
        QueryWrapper<BMainPollDisWaterSout> wrapper = new QueryWrapper<>();
        wrapper.eq(ObjectUtil.isNotNull(query.getSoutId()), "sout_id", query.getSoutId());
        wrapper.eq(ObjectUtil.isNotNull(query.getFactoryId()), "factory_id", query.getFactoryId());
        wrapper.eq(ObjectUtil.isNotNull(query.getPollDisId()), "poll_dis_id", query.getPollDisId());
        wrapper.eq(ObjectUtil.isNotNull(query.getPollutantType()), "pollutant_type", query.getPollutantType());
        wrapper.eq(ObjectUtil.isNotNull(query.getOutletCode()), "outlet_code", query.getOutletCode());
        wrapper.eq(ObjectUtil.isNotNull(query.getOutletName()), "outlet_name", query.getOutletName());
        wrapper.eq(ObjectUtil.isNotNull(query.getPollutantsType()), "pollutants_type", query.getPollutantsType());
        wrapper.eq(ObjectUtil.isNotNull(query.getPollutantsTimeFrame()), "pollutants_time_frame", query.getPollutantsTimeFrame());
        wrapper.eq(ObjectUtil.isNotNull(query.getPollutantsConcentration()), "pollutants_concentration", query.getPollutantsConcentration());
        wrapper.eq(ObjectUtil.isNotNull(query.getPollutantsDis()), "pollutants_dis", query.getPollutantsDis());
        wrapper.eq(ObjectUtil.isNotNull(query.getOtherDetail()), "other_detail", query.getOtherDetail());
        return wrapper;
        }
}
