<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ListView id="__vMXuX6SBrQTFhgDebQJ">
  <name>五级等级证旧证查询</name>
  <parentId>__xmA8P0JniFiisvoPiWM</parentId>
  <applicationid>__LgZds5MVHW3o08T7UcX</applicationid>
  <pagination>true</pagination>
  <pageLines>10</pageLines>
  <showTotalRow>false</showTotalRow>
  <refresh>false</refresh>
  <refreshAll>false</refreshAll>
  <newPage>false</newPage>
  <readonly>false</readonly>
  <displayType>relatedForm</displayType>
  <defaultShowMode>month</defaultShowMode>
  <collapsibleShowMode>normal</collapsibleShowMode>
  <showWaterMark>false</showWaterMark>
  <showActivityColumnType>0</showActivityColumnType>
  <searchFormId>__jPOUycukEj39xGLr4vE</searchFormId>
  <autoCompose>false</autoCompose>
  <relatedForm></relatedForm>
  <permissionType>public</permissionType>
  <filterScript><![CDATA[]]></filterScript>
  <sqlFilterScript><![CDATA[(function(){
  var domainId = getDomainid();
  var idCardNo = getItemValueAsString("idCard"); 
  var createStartDate = getItemValueAsDate("createStartDate"); 
  var createEndDate = getItemValueAsDate("createEndDate"); 
  var z_name = getItemValueAsString("z_name");  
  var z_idCard = getItemValueAsString("z_idCard"); 
  var z_certificate = getItemValueAsString("z_certificate"); 
  var whereStr = "";
  var queryCriteriaSql = "";   
  if(isNotNull(z_name)){                                        
    queryCriteriaSql = queryCriteriaSql + " and xm like concat('%','"+z_name+"','%')"
  }
  if(isNotNull(z_idCard)){                                        
    queryCriteriaSql = queryCriteriaSql + " and idnum like concat('%','"+z_idCard+"','%')"
  }
  if(isNotNull(z_certificate)){                                        
    queryCriteriaSql = queryCriteriaSql + " and zsbh like concat('%','"+z_certificate+"','%')"
  }
  if(isNotNull(createStartDate)){            
    queryCriteriaSql += "and fzrq >= '"+format(createStartDate,"yyyy-MM-dd")+"' ";            
  }            
  if(isNotNull(createEndDate)){            
    queryCriteriaSql += "and fzrq < DATE_FORMAT(DATE_ADD('"+format(createEndDate,"yyyy-MM-dd")+"',INTERVAL 1 DAY),'%Y-%m-%d')";             
  }
  var sql = "select id,id as item_id,xm as item_xm, trainid as domainid,idnum as item_idnum ,case certificateType when '2' then '等级证' end as item_certificateType,"+
      " zsbh as item_zsbh , fzrq as item_fzrq,fzjgmc as item_fzjgmc,csrq as item_csrq "+
      " from  obpm2.tenant_user_credential_details where trainid='"+getDomainid()+"'  and certificateType='2' "

  sql=sql+queryCriteriaSql;
  println("sql------------"+sql)
  return sql;
})()
]]></sqlFilterScript>
  <procedureFilterScript><![CDATA[]]></procedureFilterScript>
  <filterCondition><![CDATA[[]]]></filterCondition>
  <commonFilterCondition><![CDATA[[{"field":"z_name","isCommonFilter":"true","paramKey":1652949303810}]]]></commonFilterCondition>
  <authorityCondition>[]</authorityCondition>
  <openType>1</openType>
  <editMode>02</editMode>
  <width>0</width>
  <height>0</height>
</ListView>