select * from 产品
where 1=1
${if(len(产品类别) == 0,"","and 类别ID = '" +产品类别+ "'")}
${if(len(产品名称) == 0,"","and 产品名称 = '" +产品名称+ "'")}
${if(len(产品类别) == 0,"","and 类别ID in( '" +产品类别+ "')")}
${if(len(产品名称) == 0,"","and 产品名称 in( '" +产品名称+ "')")}
---------
控件设置
---
复选框sql的语法 是用 in ,不能直接等于 https://help.fanruan.com/finereport/doc-view-4025.html