package cn.ibizlab.assetmanagement.core.asset.filter;

import java.math.BigDecimal;
import java.math.BigInteger;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.HashMap;

import lombok.*;
import lombok.extern.slf4j.Slf4j;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField;

import org.springframework.util.ObjectUtils;
import org.springframework.util.StringUtils;


import cn.ibizlab.assetmanagement.util.filter.QueryWrapperContext;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import cn.ibizlab.assetmanagement.core.asset.domain.EAMAsset;
/**
 * 关系型数据实体[EAMAsset] 查询条件对象
 */
@Slf4j
@Data
public class EAMAssetSearchContext extends QueryWrapperContext<EAMAsset> {

	private String n_assetname_like;//[资产名称]
	public void setN_assetname_like(String n_assetname_like) {
        this.n_assetname_like = n_assetname_like;
        if(!ObjectUtils.isEmpty(this.n_assetname_like)){
            this.getSearchCond().like("assetname", n_assetname_like);
        }
    }
	private String n_eamassettypeid_eq;//[资产类型标识]
	public void setN_eamassettypeid_eq(String n_eamassettypeid_eq) {
        this.n_eamassettypeid_eq = n_eamassettypeid_eq;
        if(!ObjectUtils.isEmpty(this.n_eamassettypeid_eq)){
            this.getSearchCond().eq("eamassettypeid", n_eamassettypeid_eq);
        }
    }
	private String n_eamlocationid_eq;//[功能位置标识]
	public void setN_eamlocationid_eq(String n_eamlocationid_eq) {
        this.n_eamlocationid_eq = n_eamlocationid_eq;
        if(!ObjectUtils.isEmpty(this.n_eamlocationid_eq)){
            this.getSearchCond().eq("eamlocationid", n_eamlocationid_eq);
        }
    }
	private String n_passetid_eq;//[上级资产标识]
	public void setN_passetid_eq(String n_passetid_eq) {
        this.n_passetid_eq = n_passetid_eq;
        if(!ObjectUtils.isEmpty(this.n_passetid_eq)){
            this.getSearchCond().eq("passetid", n_passetid_eq);
        }
    }
	private String n_eamassettypename_eq;//[资产类型]
	public void setN_eamassettypename_eq(String n_eamassettypename_eq) {
        this.n_eamassettypename_eq = n_eamassettypename_eq;
        if(!ObjectUtils.isEmpty(this.n_eamassettypename_eq)){
            this.getSearchCond().eq("eamassettypename", n_eamassettypename_eq);
        }
    }
	private String n_eamassettypename_like;//[资产类型]
	public void setN_eamassettypename_like(String n_eamassettypename_like) {
        this.n_eamassettypename_like = n_eamassettypename_like;
        if(!ObjectUtils.isEmpty(this.n_eamassettypename_like)){
            this.getSearchCond().like("eamassettypename", n_eamassettypename_like);
        }
    }
	private String n_eamlocationname_eq;//[功能位置]
	public void setN_eamlocationname_eq(String n_eamlocationname_eq) {
        this.n_eamlocationname_eq = n_eamlocationname_eq;
        if(!ObjectUtils.isEmpty(this.n_eamlocationname_eq)){
            this.getSearchCond().eq("eamlocationname", n_eamlocationname_eq);
        }
    }
	private String n_eamlocationname_like;//[功能位置]
	public void setN_eamlocationname_like(String n_eamlocationname_like) {
        this.n_eamlocationname_like = n_eamlocationname_like;
        if(!ObjectUtils.isEmpty(this.n_eamlocationname_like)){
            this.getSearchCond().like("eamlocationname", n_eamlocationname_like);
        }
    }
	private String n_eamassetstateid_eq;//[资产状态标识]
	public void setN_eamassetstateid_eq(String n_eamassetstateid_eq) {
        this.n_eamassetstateid_eq = n_eamassetstateid_eq;
        if(!ObjectUtils.isEmpty(this.n_eamassetstateid_eq)){
            this.getSearchCond().eq("eamassetstateid", n_eamassetstateid_eq);
        }
    }
	private String n_eamassetstatename_eq;//[资产状态]
	public void setN_eamassetstatename_eq(String n_eamassetstatename_eq) {
        this.n_eamassetstatename_eq = n_eamassetstatename_eq;
        if(!ObjectUtils.isEmpty(this.n_eamassetstatename_eq)){
            this.getSearchCond().eq("eamassetstatename", n_eamassetstatename_eq);
        }
    }
	private String n_eamassetstatename_like;//[资产状态]
	public void setN_eamassetstatename_like(String n_eamassetstatename_like) {
        this.n_eamassetstatename_like = n_eamassetstatename_like;
        if(!ObjectUtils.isEmpty(this.n_eamassetstatename_like)){
            this.getSearchCond().like("eamassetstatename", n_eamassetstatename_like);
        }
    }
	private String n_passetname_eq;//[上级资产]
	public void setN_passetname_eq(String n_passetname_eq) {
        this.n_passetname_eq = n_passetname_eq;
        if(!ObjectUtils.isEmpty(this.n_passetname_eq)){
            this.getSearchCond().eq("passetname", n_passetname_eq);
        }
    }
	private String n_passetname_like;//[上级资产]
	public void setN_passetname_like(String n_passetname_like) {
        this.n_passetname_like = n_passetname_like;
        if(!ObjectUtils.isEmpty(this.n_passetname_like)){
            this.getSearchCond().like("passetname", n_passetname_like);
        }
    }
	private String n_assetnumber_like;//[资产编号]
	public void setN_assetnumber_like(String n_assetnumber_like) {
        this.n_assetnumber_like = n_assetnumber_like;
        if(!ObjectUtils.isEmpty(this.n_assetnumber_like)){
            this.getSearchCond().like("assetnumber", n_assetnumber_like);
        }
    }

    /**
	 * 启用快速搜索
	 */
	public void setQuery(String query)
	{
		 this.query=query;
		 if(!StringUtils.isEmpty(query)){
            this.getSearchCond().and( wrapper ->
                     wrapper.like("assetname", query)   
            );
		 }
	}
}



