select * from daul where 1-1
${if(年="","","and year in('"+replace(年,",","','")+"')")}
${if(月="","","and month in('"+replace(月,",","','")+"')")}
这里的年和月是你的控件名称 year 和month是你的数据库字段名称