Commit 591a91b7 authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review

Merge "Bug #1017785: Empty blog should display "No entries yet." and "Add one" link Edit"

parents b5dc5a42 5e760957
......@@ -102,6 +102,11 @@ $smarty->assign('blogs', $blogs);
$smarty->assign('institutionname', $institutionname);
$smarty->assign('group', $groupid);
$smarty->assign('canedit', (!empty($group) ? $group->canedit : true));
$smarty->assign('grouphref', get_config('wwwroot') . "artefact/blog/new/index.php?group=" . $groupid);
$smarty->assign('sitehref', get_config('wwwroot') . "artefact/blog/new/index.php?institution=mahara");
$smarty->assign('institutionhref', get_config('wwwroot') . "artefact/blog/new/index.php?institution=" . $institutionname);
$smarty->assign('userhref', get_config('wwwroot') . "artefact/blog/new/index.php");
$js = '';
if ($blogs->pagination_js) {
$js .= 'jQuery(function() {' . $blogs->pagination_js . '});';
......@@ -158,9 +158,10 @@ $string['viewposts'] = 'Copied entries (%s)';
$string['postscopiedfromview'] = 'Entries copied from %s';
$string['youhavenoblogs'] = 'You have no journals.';
$string['youhavenogroupblogs'] = 'There are no journals in this group.';
$string['youhavenoinstitutionblogs'] = 'There are no journals in this institution.';
$string['youhavenositeblogs'] = 'There are no site journals.';
$string['youhavenoblogsaddone'] = 'You have no journals. <a href="%s">Add one</a>';
$string['youhavenogroupblogs1'] = 'There are no journals in this group. <a href="%s">Add one</a>';
$string['youhavenoinstitutionblogs1'] = 'There are no journals in this institution. <a href="%s">Add one</a>';
$string['youhavenositeblogs1'] = 'There are no site journals. <a href="%s">Add one</a>';
$string['youhavenblog'] = array(
'You have 1 journal.',
'You have %d journals.'
......@@ -10,13 +10,13 @@
{if !$blogs->data}
<p class="no-results">
{if $group}
{str tag=youhavenogroupblogs}
{str tag=youhavenogroupblogs1 arg1=$grouphref}
{elseif $institutionname == 'mahara'}
{str tag=youhavenositeblogs}
{str tag=youhavenositeblogs1 arg1=$sitehref}
{elseif $institutionname}
{str tag=youhavenoinstitutionblogs}
{str tag=youhavenoinstitutionblogs1 arg1=$institutionhref}
{str tag=youhavenoblogs}
{str tag=youhavenoblogsaddone arg1=$userhref}
......@@ -23,7 +23,7 @@
{if $posts}
{if $posts.count > 0}
<div id="postlist" class="postlist list-group list-group-lite">
......@@ -35,9 +35,9 @@
<div class="metadata">
<p class="no-results">
{str tag=nopostsyet} {if !$blog->get('locked')}<a href="{$WWWROOT}artefact/blog/post.php?blog={$blog->get('id')}">{str tag=addone section=mahara}</a>{/if}
{if $enablemultipleblogstext}
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