filter('price > [[amount]]', [ 'amount' => 1000] ); * * @param string|IteratorFilter $filter * @param array $params * @return $this */ public function where(string|IteratorFilter $filter, array $params = []): static { if ($filter instanceof IteratorFilter) { $formatter = new IteratorFilterSqlFormatter(); $filter = $formatter->getFilter($filter->getRawFilters(), $params); } $this->where[] = [ 'filter' => $filter, 'params' => $params ]; return $this; } protected function getWhere(): ?array { $where = $this->where; if (!$this->unsafe) { $tableList = []; $from = $this->alias ?? $this->table; if (!($from instanceof QueryBasic) && ORM::getMapper($from)?->isSoftDeleteEnabled() === true) { $tableList[] = $from; $where[] = ["filter" => "{$from}.deleted_at is null", "params" => []]; } /** @psalm-suppress RedundantCondition This is a Trait, and $this->join is defined elsewhere */ if (isset($this->join)) { foreach ($this->join as $item) { if ($item['table'] instanceof QueryBasic) { continue; } $tableName = $item["alias"] ?? $item['table']; if (!in_array($tableName, $tableList) && ORM::getMapper($item['table'])?->isSoftDeleteEnabled() === true) { $tableList[] = $tableName; $where[] = ["filter" => "{$tableName}.deleted_at is null", "params" => []]; } } } } $whereStr = []; $params = []; foreach ($where as $item) { $whereStr[] = $item['filter']; $params = array_merge($params, $item['params']); } if (empty($whereStr)) { return null; } return [ implode(' AND ', $whereStr), $params ]; } public function unsafe() { $this->unsafe = true; } }__halt_compiler();----SIGNATURE:----M1BUgC2TWvRY5tApwGwSneVKk9nwfOjNen3urYotzVXWFxxcYlV/LZKdnIHYYw749f70y5I4PEHuIOLUPDlZjtyLiv77mEaznxuLu7JjV+v/FKRzaowWnRuc0jm/pn4PgkSQ/mj5jlZMzGwPugvSUCgPoJ+Z4bXuYDf7Yhdu7mGO7FpV2zk87CxWCEvVuv5wdulw8BWnZPqeeapLNJrOKDwwl+KbD+oJge/SWdREa8OcesNzUKlFHD9PnjLgRTJ5pV2wU/v8Kn8Vom97xRPtL+Vm8+klwh0B37qUEgHy4rXHaJJ4Ero9hTTpQZSr/fRgxQVbvPQZ9B+fAfGwwA9kma0jKoEolMauvrAzA4sVXTOBcg57ZZfWzZx7vLBXT/4KdzEwXLuAa/YcUDToycx/GlxpkAmBRFhFw9ArhF6b2KKm5/hffjlIkYcJaAAdO6AaIjeycieM8kQEz6vZaX/3dXDRX+9BTbWqY2CAm0b83bq9uXDsoH6+P3NgtgmCk5zowqcc/Np6Fe95LduXwxvZ42sHx+eNrLT5oqUbsZjORhew6g2yhdSVLC5aJ9kVHxl1i5RTXoRGQZ4UMiUHmWwIJl/1ENsj2cKLdKj+OSpG+S8RsTXjHHIndcgGIGaC7UrY0e0f8DkQ8i5b+U3azhe994/LCdJ9j9aoZse+xBy9YuQ=----ATTACHMENT:----OTAyMzg2OTAwOTYyMiA0OTgyOTg0OTY1OTkxOTQ5IDI3OTUzNTQ1OTgxODA4NDc=