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

	private String n_hrfamilyname_like;//[姓名]
	public void setN_hrfamilyname_like(String n_hrfamilyname_like) {
        this.n_hrfamilyname_like = n_hrfamilyname_like;
        if(!ObjectUtils.isEmpty(this.n_hrfamilyname_like)){
            this.getSearchCond().like("hrfamilyname", n_hrfamilyname_like);
        }
    }
	private String n_hremployeeid_eq;//[员工标识]
	public void setN_hremployeeid_eq(String n_hremployeeid_eq) {
        this.n_hremployeeid_eq = n_hremployeeid_eq;
        if(!ObjectUtils.isEmpty(this.n_hremployeeid_eq)){
            this.getSearchCond().eq("hremployeeid", n_hremployeeid_eq);
        }
    }
	private String n_hremployeename_eq;//[员工姓名]
	public void setN_hremployeename_eq(String n_hremployeename_eq) {
        this.n_hremployeename_eq = n_hremployeename_eq;
        if(!ObjectUtils.isEmpty(this.n_hremployeename_eq)){
            this.getSearchCond().eq("hremployeename", n_hremployeename_eq);
        }
    }
	private String n_hremployeename_like;//[员工姓名]
	public void setN_hremployeename_like(String n_hremployeename_like) {
        this.n_hremployeename_like = n_hremployeename_like;
        if(!ObjectUtils.isEmpty(this.n_hremployeename_like)){
            this.getSearchCond().like("hremployeename", n_hremployeename_like);
        }
    }
	private String n_relationship_eq;//[与本人关系]
	public void setN_relationship_eq(String n_relationship_eq) {
        this.n_relationship_eq = n_relationship_eq;
        if(!ObjectUtils.isEmpty(this.n_relationship_eq)){
            this.getSearchCond().eq("relationship", n_relationship_eq);
        }
    }
	private String n_certtype_eq;//[证件类型]
	public void setN_certtype_eq(String n_certtype_eq) {
        this.n_certtype_eq = n_certtype_eq;
        if(!ObjectUtils.isEmpty(this.n_certtype_eq)){
            this.getSearchCond().eq("certtype", n_certtype_eq);
        }
    }
	private String n_sex_eq;//[性别]
	public void setN_sex_eq(String n_sex_eq) {
        this.n_sex_eq = n_sex_eq;
        if(!ObjectUtils.isEmpty(this.n_sex_eq)){
            this.getSearchCond().eq("sex", n_sex_eq);
        }
    }
	private String n_political_eq;//[政治面貌]
	public void setN_political_eq(String n_political_eq) {
        this.n_political_eq = n_political_eq;
        if(!ObjectUtils.isEmpty(this.n_political_eq)){
            this.getSearchCond().eq("political", n_political_eq);
        }
    }

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



