Changed type filter to tenant filter in Address/Index

This commit is contained in:
Frank Schubert
2024-01-04 18:15:59 +01:00
parent e35e22f4c1
commit 7c98b761ba
3 changed files with 15 additions and 6 deletions

View File

@@ -267,6 +267,15 @@ class AddressModel {
}
}
if(array_key_exists("customer_or_fibu_numbers", $filter)) {
$cn = $filter["customer_or_fibu_numbers"];
if($cn === true) {
$where .= " AND (customer_number > 0 OR fibu_account_number > 0 OR fibu_supplier_number > 0)";
} elseif($cn === false || $cn === null) {
$where .= " AND customer_number IS NULL AND fibu_account_number IS NULL AND fibu_supplier_number IS NULL";
}
}
if(array_key_exists("spin", $filter)) {
$spin = FronkDB::singleton()->escape($filter["spin"]);
if($spin) {