projects
/
MojoFacets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a3ac55a
)
invalidate filters on other datasets
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Fri, 14 Jan 2011 18:39:47 +0000
(19:39 +0100)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Fri, 14 Jan 2011 18:39:47 +0000
(19:39 +0100)
lib/MojoFacets/Data.pm
patch
|
blob
|
history
diff --git
a/lib/MojoFacets/Data.pm
b/lib/MojoFacets/Data.pm
index
acf860e
..
eff5f2a
100644
(file)
--- a/
lib/MojoFacets/Data.pm
+++ b/
lib/MojoFacets/Data.pm
@@
-544,6
+544,12
@@
sub _filter_on_data {
#warn "# filter $name ",dump($filtered_items);
+ # invalidate filters on other datasets
+ foreach my $dataset ( grep { exists $loaded->{$_}->{filters}->{$name} } keys %$loaded ) {
+ delete $loaded->{$dataset}->{filters}->{$name};
+ delete $loaded->{$dataset}->{filtered};
+ }
+
$loaded->{$path}->{filters}->{$name} = $filtered_items;
warn "filter $name with ", scalar keys %$filtered_items, " items created\n";
}