Commit 8fd0b512 authored by Nigel McNie's avatar Nigel McNie
Browse files

i18n for HTML export view summary.

parent 6035953b
......@@ -199,10 +199,19 @@ class PluginExportHtml extends PluginExport {
}
}
$smarty->assign('views', $views);
$smarty->assign('viewcount', count($views));
if ($views) {
$stryouhaveviews = (count($views) == 1)
? get_string('youhaveoneview', 'view')
: get_string('youhaveviews', 'view', count($views));
}
else {
$stryouhaveviews = get_string('youhavenoviews', 'view');
}
$smarty->assign('stryouhaveviews', $stryouhaveviews);
return array(
'title' => 'Views',
'title' => get_string('Views', 'view'),
'description' => $smarty->fetch('export:html:viewsummary.tpl'),
);
}
......
<p>You have {$viewcount} views</p>
<p>{$stryouhaveviews}</p>
<ul>
{foreach from=$views item=view}
<li><a href="views/{$view.folder|escape}/index.html">{$view.title|escape}</a></li>
......
......@@ -72,6 +72,8 @@ $string['viewsubmittedtogroup'] = 'This View has been submitted to <a href="%sgr
$string['nobodycanseethisview2'] = 'Only you can see this View';
$string['noviews'] = 'No Views.';
$string['youhavenoviews'] = 'You have no Views.';
$string['youhaveoneview'] = 'You have 1 View.';
$string['youhaveviews'] = 'You have %s Views.';
$string['viewsownedbygroup'] = 'Views owned by this group';
$string['viewssharedtogroup'] = 'Views shared to this group';
$string['viewssharedtogroupbyothers'] = 'Views shared to this group by others';
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment