protected function buildNotificationMessage($pluginsToBeNotified, $hasThemeUpdate, $hasPluginUpdate)
{
$message = Piwik::translate('ScheduledReports_EmailHello');
$message .= "\n\n";
$message .= Piwik::translate('CoreUpdater_ThereIsNewPluginVersionAvailableForUpdate');
$message .= "\n\n";
foreach ($pluginsToBeNotified as $plugin) {
$message .= sprintf(' * %s %s', $plugin['name'], $plugin['latestVersion']);
$message .= "\n";
}
$message .= "\n";
$host = SettingsPiwik::getPiwikUrl();
if ($hasThemeUpdate) {
$message .= Piwik::translate('CoreUpdater_NotificationClickToUpdateThemes') . "\n";
$message .= $host . 'index.php?module=CorePluginsAdmin&action=themes';
}
if ($hasPluginUpdate) {
if ($hasThemeUpdate) {
$message .= "\n\n";
}
$message .= Piwik::translate('CoreUpdater_NotificationClickToUpdatePlugins') . "\n";
$message .= $host . 'index.php?module=CorePluginsAdmin&action=plugins';
}
$message .= "\n\n";
$message .= Piwik::translate('Installation_HappyAnalysing');
return $message;
}