Make foreign NotificationGroupItems aware of their section

This caused notifications on mobile to show notifications for
both alert|message, as the type was always "all".

Bug: T130801
Change-Id: Ice245eb407ca360d8e882c0ba48cb7b3e0ecb851
This commit is contained in:
Matthias Mullie 2016-04-01 13:33:05 +00:00
parent 722f9f58a8
commit f1c708ef9e
2 changed files with 2 additions and 0 deletions

View file

@ -313,6 +313,7 @@ class ApiEchoNotifications extends ApiQueryBase {
$output = EchoDataOutputFormatter::formatOutput( $notif, $format, $user, $this->getLanguage() ); $output = EchoDataOutputFormatter::formatOutput( $notif, $format, $user, $this->getLanguage() );
// Add cross-wiki-specific data // Add cross-wiki-specific data
$output['section'] = $section;
$output['count'] = $count; $output['count'] = $count;
$output['sources'] = $foreignNotifications->getApiEndpoints( $wikis ); $output['sources'] = $foreignNotifications->getApiEndpoints( $wikis );
// Add timestamp information // Add timestamp information

View file

@ -532,6 +532,7 @@
// For bundles that are not foreign (like regular // For bundles that are not foreign (like regular
// bundles of notifications) this flag should be false // bundles of notifications) this flag should be false
foreign: true, foreign: true,
type: notifData.section,
count: notifData.count count: notifData.count
} ) } )
); );