|
@@ -126,6 +126,15 @@ public class notice extends Controller {
|
|
|
if (whereObject.containsKey("enddate") && !"".equals(whereObject.getString("enddate"))) {
|
|
if (whereObject.containsKey("enddate") && !"".equals(whereObject.getString("enddate"))) {
|
|
|
where = where + " and t1.checkdate <='" + whereObject.getString("enddate") + "'";
|
|
where = where + " and t1.checkdate <='" + whereObject.getString("enddate") + "'";
|
|
|
}
|
|
}
|
|
|
|
|
+ if (whereObject.containsKey("isread") && !"".equals(whereObject.getString("isread"))) {
|
|
|
|
|
+ if(whereObject.getBooleanValue("isread")){
|
|
|
|
|
+ where = where + " and (CASE WHEN (SELECT COUNT(*) FROM sat_notice_read WHERE siteid = t1.siteid AND sat_noticeid = t1.sat_noticeid)>0 THEN '已读' ELSE '未读' END)='已读'";
|
|
|
|
|
+ }else{
|
|
|
|
|
+ where = where + " and (CASE WHEN (SELECT COUNT(*) FROM sat_notice_read WHERE siteid = t1.siteid AND sat_noticeid = t1.sat_noticeid)>0 THEN '已读' ELSE '未读' END)='未读'";
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
SQLFactory sqlFactory = new SQLFactory(this, "通告列表查询", pageSize, pageNumber, pageSorting);
|
|
SQLFactory sqlFactory = new SQLFactory(this, "通告列表查询", pageSize, pageNumber, pageSorting);
|
|
|
sqlFactory.addParameter_SQL("where", where);
|
|
sqlFactory.addParameter_SQL("where", where);
|