mirror of https://github.com/MISP/MISP
fix: [user:periodic_notification] Perform filtering on event tags only for aggregated context
This is for restSearch to stay consistent with how events are fetched by the default fetcherpull/8575/head
parent
406cda070e
commit
f23e582760
|
@ -1755,6 +1755,10 @@ class User extends AppModel
|
|||
$filtersForRestSearch['returnFormat'] = 'context';
|
||||
$filtersForRestSearch['staticHtml'] = true;
|
||||
unset($filtersForRestSearch['last']);
|
||||
if (!empty($filtersForRestSearch['tags'])) {
|
||||
$filtersForRestSearch['event_tags'] = $filtersForRestSearch['tags'];
|
||||
unset($filtersForRestSearch['tags']);
|
||||
}
|
||||
$final = $this->Event->restSearch($user, 'context', $filtersForRestSearch, false, false, $elementCounter, $renderView);
|
||||
$final = json_decode($final->intoString(), true);
|
||||
$aggregated_context = $this->__renderAggregatedContext($final);
|
||||
|
|
|
@ -56,7 +56,7 @@ echo $this->element('genericElements/Form/genericForm', [
|
|||
],
|
||||
[
|
||||
'field' => 'periodic_settings.tags',
|
||||
'label' => __('Tag list'),
|
||||
'label' => __('Event Tags'),
|
||||
'type' => 'tagsPicker',
|
||||
'placeholder' => '["tlp:red"]',
|
||||
],
|
||||
|
|
Loading…
Reference in New Issue