package cn.ibizlab.businesscentral.core.odoo_base.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.businesscentral.util.filter.QueryWrapperContext;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import cn.ibizlab.businesscentral.core.odoo_base.domain.Res_supplier;
/**
 * 关系型数据实体[Res_supplier] 查询条件对象
 */
@Slf4j
@Data
public class Res_supplierSearchContext extends QueryWrapperContext<Res_supplier> {

	private String n_name_like;//[名称]
	public void setN_name_like(String n_name_like) {
        this.n_name_like = n_name_like;
        if(!ObjectUtils.isEmpty(this.n_name_like)){
            this.getSearchCond().like("name", n_name_like);
        }
    }
	private String n_type_eq;//[地址类型]
	public void setN_type_eq(String n_type_eq) {
        this.n_type_eq = n_type_eq;
        if(!ObjectUtils.isEmpty(this.n_type_eq)){
            this.getSearchCond().eq("type", n_type_eq);
        }
    }
	private String n_company_type_eq;//[公司类别]
	public void setN_company_type_eq(String n_company_type_eq) {
        this.n_company_type_eq = n_company_type_eq;
        if(!ObjectUtils.isEmpty(this.n_company_type_eq)){
            this.getSearchCond().eq("company_type", n_company_type_eq);
        }
    }
	private Long n_property_supplier_payment_term_id_eq;//[采购付款条例]
	public void setN_property_supplier_payment_term_id_eq(Long n_property_supplier_payment_term_id_eq) {
        this.n_property_supplier_payment_term_id_eq = n_property_supplier_payment_term_id_eq;
        if(!ObjectUtils.isEmpty(this.n_property_supplier_payment_term_id_eq)){
            this.getSearchCond().eq("property_supplier_payment_term_id", n_property_supplier_payment_term_id_eq);
        }
    }
	private String n_property_supplier_payment_term_name_eq;//[采购付款条例]
	public void setN_property_supplier_payment_term_name_eq(String n_property_supplier_payment_term_name_eq) {
        this.n_property_supplier_payment_term_name_eq = n_property_supplier_payment_term_name_eq;
        if(!ObjectUtils.isEmpty(this.n_property_supplier_payment_term_name_eq)){
            this.getSearchCond().eq("property_supplier_payment_term_name", n_property_supplier_payment_term_name_eq);
        }
    }
	private String n_property_supplier_payment_term_name_like;//[采购付款条例]
	public void setN_property_supplier_payment_term_name_like(String n_property_supplier_payment_term_name_like) {
        this.n_property_supplier_payment_term_name_like = n_property_supplier_payment_term_name_like;
        if(!ObjectUtils.isEmpty(this.n_property_supplier_payment_term_name_like)){
            this.getSearchCond().like("property_supplier_payment_term_name", n_property_supplier_payment_term_name_like);
        }
    }

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



