projects
/
kivitendo-erp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'b-3.6.1' of ../kivitendo-erp_20220811
[kivitendo-erp.git]
/
SL
/
Controller
/
Helper
/
ParseFilter.pm
diff --git
a/SL/Controller/Helper/ParseFilter.pm
b/SL/Controller/Helper/ParseFilter.pm
index
e1b621f
..
0f73141
100644
(file)
--- a/
SL/Controller/Helper/ParseFilter.pm
+++ b/
SL/Controller/Helper/ParseFilter.pm
@@
-125,7
+125,8
@@
sub _parse_filter {
my ($type, $op) = $key =~ m{:(.+)::(.+)};
my $is_multi = $key =~ s/:multi//;
my ($type, $op) = $key =~ m{:(.+)::(.+)};
my $is_multi = $key =~ s/:multi//;
- my @value_tokens = $is_multi ? parse_line('\s+', 0, $value) : ($value);
+ my $is_any = $key =~ s/:any//;
+ my @value_tokens = $is_multi || $is_any ? parse_line('\s+', 0, $value) : ($value);
($key, $method) = split m{::}, $key, 2;
($key, @filters) = split m{:}, $key;
($key, $method) = split m{::}, $key, 2;
($key, @filters) = split m{:}, $key;
@@
-146,7
+147,7
@@
sub _parse_filter {
next unless defined $key;
next unless defined $key;
- push @result, $is_multi ? (and => [ @args ]) : @args;
+ push @result, $is_multi ? (and => [ @args ]) :
$is_any ? (or => [ @args ]) :
@args;
}
return \@result;
}
}
return \@result;
}
@@
-297,11
+298,10
@@
customer. L<Rose::DB::Object> allows you to search for these by filtering them p
query => [
'customer.name' => 'John Doe',
query => [
'customer.name' => 'John Doe',
- 'department.description' =>
[ like => '%Sales%' ]
,
+ 'department.description' =>
{ ilike => '%Sales%' }
,
'orddate' => { lt => DateTime->today },
]
'orddate' => { lt => DateTime->today },
]
-
Unfortunately, if you specify them in your form as these strings, the form
parser will convert them into nested structures like this:
Unfortunately, if you specify them in your form as these strings, the form
parser will convert them into nested structures like this: