diff --git a/webapp/controller/MailController.class.php b/webapp/controller/MailController.class.php index 13a801a..a15c6a7 100644 --- a/webapp/controller/MailController.class.php +++ b/webapp/controller/MailController.class.php @@ -88,7 +88,7 @@ class MailController ' SELECT mail_id, subject, content, attachments, expiretime FROM t_mail WHERE 1=1 AND deleted=0 ' . ' AND (user_reg_start_time=0 OR user_reg_end_time=0 OR (user_reg_start_time<:createtime AND user_reg_end_time>:createtime)) ' . ' AND expiretime>:nowtime ' . - ' AND (recipients="" OR recipients LIKE "%:accountid%");', + ' AND (recipients="" OR recipients="[]" OR recipients LIKE "%:accountid%");', array( ':createtime' => $usercreate, ':nowtime' => $nowtime, @@ -209,9 +209,9 @@ class MailController $mailid = $_REQUEST['mailid']; $querystr = 'SELECT mail_id, subject, content, attachments FROM t_mail WHERE 1=1 AND deleted=0 ' . - ' AND (user_reg_start_time=0 OR user_reg_end_time=0 OR (user_reg_start_time<:createtime AND user_reg_end_time>:createtime) ' . + ' AND (user_reg_start_time=0 OR user_reg_end_time=0 OR (user_reg_start_time<:createtime AND user_reg_end_time>:createtime)) ' . ' AND expiretime>:nowtime ' . - ' AND recipients="" OR recipients LIKE "%:accountid%"'; + ' AND (recipients="" OR recipients="[]" OR recipients LIKE "%:accountid%")'; $params = array( ':createtime' => $usercreate, ':nowtime' => $nowtime,