Skip to content

Commit

Permalink
Fix filter
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Jan 2, 2025
1 parent 996f874 commit 56ff52b
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,10 @@ public function add_to_target($mailing_id)
$extrafields->fetch_name_optionals_label($tmp->table_element);

foreach($extrafields->attributes[$tmp->table_element]['label'] as $key => $label) {
if (GETPOSTISSET($key) && GETPOST($key) != '') {
if (GETPOSTISSET($key) && GETPOST($key) == '0') {
$sql .= " AND IFNULL(ase.".$this->db->sanitize($key).",0) = 0";
}
if (GETPOSTISSET($key) && GETPOST($key) == '-1' && GETPOST($key) == '1') {
$sql .= " AND ase.".$this->db->sanitize($key)." LIKE '".$this->db->escape(GETPOST($key))."'";
}
}
Expand Down

0 comments on commit 56ff52b

Please sign in to comment.